auto-sync: 2026-05-29 07:56:05

This commit is contained in:
cfdaily
2026-05-29 07:56:05 +08:00
parent df2b718663
commit 1b737518bd
+14
View File
@@ -289,6 +289,20 @@ _SCHEMA_STATEMENTS = [
"CREATE INDEX IF NOT EXISTS idx_comments_type ON comments(task_id, comment_type)",
"CREATE INDEX IF NOT EXISTS idx_comments_author ON comments(author)",
# mention_queue
"""CREATE TABLE IF NOT EXISTS mention_queue (
id INTEGER PRIMARY KEY AUTOINCREMENT,
comment_id INTEGER NOT NULL REFERENCES comments(id),
task_id TEXT NOT NULL REFERENCES tasks(id),
mentioned_agent TEXT NOT NULL,
status TEXT NOT NULL DEFAULT 'pending' CHECK (status IN ('pending', 'notified', 'failed')),
retry_count INTEGER DEFAULT 0,
created_at TEXT NOT NULL DEFAULT (datetime('now')),
notified_at TEXT
)""",
"CREATE INDEX IF NOT EXISTS idx_mention_queue_status ON mention_queue(status)",
"CREATE INDEX IF NOT EXISTS idx_mention_queue_agent ON mention_queue(mentioned_agent, status)",
# outputs
"""CREATE TABLE IF NOT EXISTS outputs (
id INTEGER PRIMARY KEY AUTOINCREMENT,