File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed
spring-ai-alibaba-nl2sql/spring-ai-alibaba-nl2sql-management/src/main/resources/sql Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -182,3 +182,20 @@ CREATE TABLE IF NOT EXISTS chat_message (
182
182
INDEX idx_create_time (create_time),
183
183
FOREIGN KEY (session_id) REFERENCES chat_session(id) ON DELETE CASCADE
184
184
) ENGINE = InnoDB COMMENT = ' 聊天消息表' ;
185
+
186
+ -- 用户Prompt配置表
187
+ CREATE TABLE IF NOT EXISTS user_prompt_config (
188
+ id VARCHAR (36 ) NOT NULL COMMENT ' 配置ID(UUID)' ,
189
+ name VARCHAR (255 ) NOT NULL COMMENT ' 配置名称' ,
190
+ prompt_type VARCHAR (100 ) NOT NULL COMMENT ' Prompt类型(如report-generator, planner等)' ,
191
+ system_prompt TEXT NOT NULL COMMENT ' 用户自定义系统Prompt内容' ,
192
+ enabled TINYINT DEFAULT 1 COMMENT ' 是否启用该配置:0-禁用,1-启用' ,
193
+ description TEXT COMMENT ' 配置描述' ,
194
+ create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP COMMENT ' 创建时间' ,
195
+ update_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT ' 更新时间' ,
196
+ creator VARCHAR (255 ) COMMENT ' 创建者' ,
197
+ PRIMARY KEY (id),
198
+ INDEX idx_prompt_type (prompt_type),
199
+ INDEX idx_enabled (enabled),
200
+ INDEX idx_create_time (create_time)
201
+ ) ENGINE = InnoDB COMMENT = ' 用户Prompt配置表' ;
You can’t perform that action at this time.
0 commit comments