Files
story/migrations/000064_subject_voice_agent.up.sql
T

13 lines
598 B
SQL
Raw Normal View History

CREATE TABLE subject_voice_agent (
subject_id uuid PRIMARY KEY REFERENCES subject_profile(id),
bot_name text NOT NULL UNIQUE,
bot_id text UNIQUE,
status text NOT NULL DEFAULT 'PENDING' CHECK (status IN ('PENDING','READY','FAILED')),
config jsonb NOT NULL DEFAULT '{}',
agent_config jsonb NOT NULL DEFAULT '{}',
last_error text NOT NULL DEFAULT '',
created_at timestamptz NOT NULL DEFAULT now(),
updated_at timestamptz NOT NULL DEFAULT now()
);
COMMENT ON TABLE subject_voice_agent IS 'One Volcano S2S bot per elder. Provider configuration stays on the server.';