feat(ECR-027): AICoreConfig KnowledgeChunk 只读并 Closed
KnowledgeChunk catalog (000028) · Loop continuous.
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
-- ECR-027 KnowledgeChunk (read catalog)
|
||||
|
||||
CREATE TABLE IF NOT EXISTS knowledge_chunks (
|
||||
id uuid PRIMARY KEY DEFAULT gen_random_uuid(),
|
||||
code varchar(64) NOT NULL UNIQUE,
|
||||
source_code varchar(64) NOT NULL,
|
||||
title varchar(128) NOT NULL,
|
||||
body text NOT NULL,
|
||||
active boolean NOT NULL DEFAULT true,
|
||||
system boolean NOT NULL DEFAULT false,
|
||||
created_at timestamptz NOT NULL DEFAULT now(),
|
||||
updated_at timestamptz NOT NULL DEFAULT now()
|
||||
);
|
||||
|
||||
CREATE INDEX IF NOT EXISTS idx_knowledge_chunks_active ON knowledge_chunks(active);
|
||||
|
||||
INSERT INTO knowledge_chunks(code, source_code, title, body, active, system)
|
||||
VALUES ('ask_grounding_intro', 'ask_grounding', '问答 grounding 引言块', '愈心谷提供陪伴式成长对话,非医疗诊断。', true, true)
|
||||
ON CONFLICT (code) DO NOTHING;
|
||||
Reference in New Issue
Block a user