feat(generation): persist summary outcomes without articles
Record generation outcomes and summaries for history while keeping article content transient. Refs #7 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@ -0,0 +1,8 @@
|
||||
CREATE TABLE summary_generations (
|
||||
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
|
||||
user_id UUID NOT NULL REFERENCES users(id) ON DELETE CASCADE,
|
||||
summary_id UUID REFERENCES summaries(id) ON DELETE SET NULL,
|
||||
outcome JSONB NOT NULL CHECK (jsonb_typeof(outcome) = 'object'),
|
||||
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
|
||||
);
|
||||
CREATE INDEX summary_generations_user_created_idx ON summary_generations (user_id, created_at DESC);
|
||||
Reference in New Issue
Block a user