Commit a34d925973a8e44ca90869254a561b28ed8d699f

Authored by cherishsince
1 parent d37c1c4e

【更新】sql文件

yudao-module-ai/yudao-module-ai-biz/src/main/resources/chat.sql
1   -DROP TABLE IF EXISTS chat_role;
2   -CREATE TABLE chat_role(
3   - `id` bigint COMMENT '编号' ,
4   - `user_id` bigint COMMENT '用户id' ,
5   - `model_id` VARCHAR(255) COMMENT '模型编号' ,
6   - `role_name` VARCHAR(32) COMMENT '角色名' ,
7   - `role_introduce` VARCHAR(255) COMMENT '介绍' ,
8   - `role_source` VARCHAR(32) COMMENT '角色来源(system、customer)' ,
9   - `classify` VARCHAR(32) COMMENT '分类(娱乐、创作)' ,
10   - `publish` tinyint COMMENT '发布(0、自己可见 1、公开 2、禁用)' ,
11   - `top_k` DECIMAL(4,2) COMMENT '生成时,采样候选集的大小' ,
12   - `top_p` DECIMAL(24,6) COMMENT '生成时,核采样方法的概率阈值。' ,
13   - `temperature` DECIMAL(24,6) COMMENT '用于控制随机性和多样性的程度' ,
14   - `use_count` INT COMMENT '使用次数' ,
15   - `CREATED_BY` bigint COMMENT '创建人' ,
16   - `CREATED_TIME` DATETIME COMMENT '创建时间' ,
17   - `UPDATED_BY` bigint COMMENT '更新人' ,
18   - `UPDATED_TIME` DATETIME COMMENT '更新时间'
19   -) COMMENT = 'chat角色;';
  1 +/*
  2 + Navicat Premium Data Transfer
20 3  
21   -DROP TABLE IF EXISTS chat_history;
22   -CREATE TABLE chat_history(
23   - `id` bigint COMMENT '编号' ,
24   - `chat_id` bigint COMMENT '聊天id' ,
25   - `user_id` VARCHAR(32) COMMENT '角色名' ,
26   - `message` TEXT COMMENT '消息' ,
27   - `message_type` DECIMAL(4,2) COMMENT 'system、user、assistant' ,
28   - `top_k` DECIMAL(4,2) COMMENT '生成时,采样候选集的大小' ,
29   - `top_p` DECIMAL(24,6) COMMENT '生成时,核采样方法的概率阈值。' ,
30   - `temperature` DECIMAL(24,6) COMMENT '用于控制随机性和多样性的程度' ,
31   - `CREATED_BY` bigint COMMENT '创建人' ,
32   - `CREATED_TIME` DATETIME COMMENT '创建时间' ,
33   - `UPDATED_BY` bigint COMMENT '更新人' ,
34   - `UPDATED_TIME` DATETIME COMMENT '更新时间'
35   -) COMMENT = '聊天记录;';
  4 + Source Server : localhost
  5 + Source Server Type : MySQL
  6 + Source Server Version : 80034 (8.0.34)
  7 + Source Host : localhost:3306
  8 + Source Schema : ruoyi-vue-pro
36 9  
37   -DROP TABLE IF EXISTS user;
38   -CREATE TABLE user(
39   - `id` bigint COMMENT '编号' ,
40   - `username` VARCHAR(32) COMMENT '用户名' ,
41   - `nickname` VARCHAR(32) COMMENT '昵称' ,
42   - `mobile` VARCHAR(32) COMMENT '手机号' ,
43   - `avatar_url` VARCHAR(128) COMMENT '头像' ,
44   - `password` VARCHAR(32) COMMENT '密码' ,
45   - `publish` tinyint COMMENT '发布(0、未发布 1、已发布)' ,
46   - `disable` VARCHAR(255) COMMENT '禁用(0、正常 1、禁用)' ,
47   - `CREATED_BY` bigint COMMENT '创建人' ,
48   - `CREATED_TIME` DATETIME COMMENT '创建时间' ,
49   - `UPDATED_BY` bigint COMMENT '更新人' ,
50   - `UPDATED_TIME` DATETIME COMMENT '更新时间'
51   -) COMMENT = '用户;';
  10 + Target Server Type : MySQL
  11 + Target Server Version : 80034 (8.0.34)
  12 + File Encoding : 65001
52 13  
53   -DROP TABLE IF EXISTS chat;
54   -CREATE TABLE chat(
55   - `id` bigint COMMENT '编号' ,
56   - `user_id` bigint COMMENT '用户id' ,
57   - `chat_role_id` VARCHAR(255) COMMENT '模型id' ,
58   - `chat_title` VARCHAR(128) COMMENT '聊天标题' ,
59   - `chat_count` INT COMMENT '聊天次数' ,
60   - `CREATED_BY` bigint COMMENT '创建人' ,
61   - `CREATED_TIME` DATETIME COMMENT '创建时间' ,
62   - `UPDATED_BY` bigint COMMENT '更人' ,
63   - `UPDATED_TIME` DATETIME COMMENT '更新时间'
64   -) COMMENT = '聊天;';
  14 + Date: 28/04/2024 11:50:47
  15 +*/
65 16  
66   -DROP TABLE IF EXISTS chat_model;
67   -CREATE TABLE chat_model(
68   - `id` bigint COMMENT '编号' ,
69   - `model_name` bigint COMMENT '模型名字' ,
70   - `model_type` VARCHAR(32) COMMENT '模型类型(qianwen、yiyan、xinghuo、openai)' ,
71   - `model_config` TEXT(128) COMMENT '模型配置JSON' ,
72   - `model_image` VARCHAR(255) COMMENT '模型图片' ,
73   - `disable` tinyint COMMENT '禁用 0、正常 1、禁用' ,
74   - `CREATED_BY` bigint COMMENT '创建人' ,
75   - `CREATED_TIME` DATETIME COMMENT '创建时间' ,
76   - `UPDATED_BY` bigint COMMENT '更新人' ,
77   - `UPDATED_TIME` DATETIME COMMENT '更新时间'
78   -) COMMENT = '聊天模型;';
  17 +SET NAMES utf8mb4;
  18 +SET FOREIGN_KEY_CHECKS = 0;
79 19  
  20 +-- ----------------------------
  21 +-- Table structure for ai_chat_conversation
  22 +-- ----------------------------
  23 +DROP TABLE IF EXISTS `ai_chat_conversation`;
  24 +CREATE TABLE `ai_chat_conversation` (
  25 + `id` bigint NOT NULL AUTO_INCREMENT,
  26 + `user_id` bigint DEFAULT NULL COMMENT '用户id',
  27 + `chat_role_id` bigint DEFAULT NULL COMMENT '聊天角色',
  28 + `chat_role_name` varchar(128) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '聊天角色名称',
  29 + `title` varchar(256) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '标题',
  30 + `type` varchar(16) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '对话类型',
  31 + `chat_count` int DEFAULT NULL COMMENT '聊天次数',
  32 + `create_time` datetime DEFAULT NULL COMMENT '创建时间',
  33 + `update_time` datetime DEFAULT NULL COMMENT '更新时间',
  34 + `creator` bigint DEFAULT NULL COMMENT '创建用户',
  35 + `updater` bigint DEFAULT NULL COMMENT '更新用户',
  36 + `deleted` bit(1) DEFAULT b'0' COMMENT '删除',
  37 + PRIMARY KEY (`id`)
  38 +) ENGINE=InnoDB AUTO_INCREMENT=1781604279872581645 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_bin;
  39 +
  40 +-- ----------------------------
  41 +-- Records of ai_chat_conversation
  42 +-- ----------------------------
  43 +BEGIN;
  44 +INSERT INTO `ai_chat_conversation` (`id`, `user_id`, `chat_role_id`, `chat_role_name`, `title`, `type`, `chat_count`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (1781604279872581644, 1, NULL, NULL, '中国好看吗?', 'userChat', 32, '2024-04-20 16:59:32', '2024-04-20 16:59:32', 1, 1, b'0');
  45 +COMMIT;
  46 +
  47 +-- ----------------------------
  48 +-- Table structure for ai_chat_message
  49 +-- ----------------------------
  50 +DROP TABLE IF EXISTS `ai_chat_message`;
  51 +CREATE TABLE `ai_chat_message` (
  52 + `id` bigint NOT NULL AUTO_INCREMENT,
  53 + `chat_conversation_id` bigint DEFAULT NULL COMMENT '对话id',
  54 + `user_id` bigint DEFAULT NULL COMMENT '用户id',
  55 + `message` text COLLATE utf8mb4_0900_bin COMMENT '对话message',
  56 + `message_type` varchar(16) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '对话类型system、user、assistant\n',
  57 + `top_k` float DEFAULT NULL COMMENT '在生成消息时采用的Top-K采样大小',
  58 + `top_p` float DEFAULT NULL COMMENT 'Top-P核采样方法的概率阈值',
  59 + `temperature` float DEFAULT NULL COMMENT '用于调整生成回复的随机性和多样性程度',
  60 + `create_time` datetime DEFAULT NULL COMMENT '创建时间',
  61 + `update_time` datetime DEFAULT NULL COMMENT '更新时间',
  62 + `creator` bigint DEFAULT NULL COMMENT '创建用户',
  63 + `updater` bigint DEFAULT NULL COMMENT '更新用户',
  64 + `deleted` bit(1) DEFAULT b'0' COMMENT '删除',
  65 + PRIMARY KEY (`id`) USING BTREE
  66 +) ENGINE=InnoDB AUTO_INCREMENT=33 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_bin;
  67 +
  68 +-- ----------------------------
  69 +-- Records of ai_chat_message
  70 +-- ----------------------------
  71 +BEGIN;
  72 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (1, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-20 18:22:41', '2024-04-20 18:22:41', 1, 1, b'0');
  73 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (2, 1781604279872581644, 1, '作为一个AI助手,我没有个人感受和偏好。但是,中国是一个拥有丰富历史、文化和自然景观的国家,有许多令人惊叹的地方,如长城、故宫、西湖、张家界、九寨沟等著名景点,吸引了无数国内外游客的喜爱。每个人对于\"好看\"的定义可能不同,但中国无疑有着独特的魅力和多样性。', 'system', NULL, NULL, NULL, '2024-04-20 18:22:44', '2024-04-20 18:22:44', 1, 1, b'0');
  74 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (3, 1781604279872581644, 1, '苹果是什么颜色?', 'user', NULL, NULL, NULL, '2024-04-20 18:23:05', '2024-04-20 18:23:05', 1, 1, b'0');
  75 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (4, 1781604279872581644, 1, '苹果的颜色可以根据品种的不同而有所差异。常见的苹果颜色有红色、黄色和青绿色。除了这些基本颜色,苹果还可能呈现出淡红色、深红色等不同的红色调。\n\n这些颜色只是影响苹果的外观,对苹果的口感和营养价值没有影响。苹果口感酸甜,营养丰富,深受人们喜爱。', 'system', NULL, NULL, NULL, '2024-04-20 18:23:11', '2024-04-20 18:23:11', NULL, NULL, b'0');
  76 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (5, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-23 10:46:48', '2024-04-23 10:46:48', 1, 1, b'0');
  77 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (6, 1781604279872581644, 1, '作为一个AI助手,我没有个人感受和偏好。但是,中国是一个拥有丰富历史、文化和自然景观的国家,有许多令人惊叹的地方,如长城、故宫、西湖、张家界、九寨沟等著名景点,吸引了无数国内外游客的喜爱。每个人对于\"好看\"的定义可能不同,但中国无疑有着独特的魅力和多样性。', 'system', NULL, NULL, NULL, '2024-04-23 10:46:52', '2024-04-23 10:46:52', 1, 1, b'0');
  78 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (7, 1781604279872581644, 1, '苹果是什么颜色?', 'user', NULL, NULL, NULL, '2024-04-23 10:46:55', '2024-04-23 10:46:55', 1, 1, b'0');
  79 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (8, 1781604279872581644, 1, '苹果的颜色因品种和成熟度的不同而异。常见的苹果颜色有红色、黄色和青绿色。除此之外,还有一些苹果品种可能呈现出淡红色、深红色等不同的红色调,或者带有条纹或斑点。总的来说,苹果的颜色非常多样化,但最常见的是红色、黄色和青绿色。', 'system', NULL, NULL, NULL, '2024-04-23 10:47:03', '2024-04-23 10:47:03', NULL, NULL, b'0');
  80 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (9, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-23 13:49:16', '2024-04-23 13:49:16', 1, 1, b'0');
  81 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (10, 1781604279872581644, 1, '作为一个AI助手,我没有个人感受和偏好。但是,中国是一个拥有丰富历史、文化和自然景观的国家,有许多令人惊叹的地方,如长城、故宫、西湖、张家界、九寨沟等著名景点,吸引了无数国内外游客的喜爱。每个人对于\"好看\"的定义可能不同,但中国无疑有着独特的魅力和多样性。', 'system', NULL, NULL, NULL, '2024-04-23 13:49:19', '2024-04-23 13:49:19', 1, 1, b'0');
  82 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (11, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-25 17:55:39', '2024-04-25 17:55:39', 1, 1, b'0');
  83 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (12, 1781604279872581644, 1, 'NoSuchBeanDefinitionException: No qualifying bean of type \'cn.iocoder.yudao.framework.ai.chatqianwen.QianWenChatClient\' available', 'system', NULL, NULL, NULL, '2024-04-25 17:55:39', '2024-04-25 17:55:39', 1, 1, b'0');
  84 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (13, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-25 17:56:12', '2024-04-25 17:56:12', 1, 1, b'0');
  85 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (14, 1781604279872581644, 1, 'NoSuchBeanDefinitionException: No qualifying bean of type \'cn.iocoder.yudao.framework.ai.chatqianwen.QianWenChatClient\' available', 'system', NULL, NULL, NULL, '2024-04-25 17:56:12', '2024-04-25 17:56:12', 1, 1, b'0');
  86 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (15, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-25 17:56:24', '2024-04-25 17:56:24', 1, 1, b'0');
  87 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (16, 1781604279872581644, 1, 'NoSuchBeanDefinitionException: No qualifying bean of type \'cn.iocoder.yudao.framework.ai.chatqianwen.QianWenChatClient\' available', 'system', NULL, NULL, NULL, '2024-04-25 17:56:24', '2024-04-25 17:56:24', 1, 1, b'0');
  88 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (17, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-25 17:56:41', '2024-04-25 17:56:41', 1, 1, b'0');
  89 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (18, 1781604279872581644, 1, 'NoSuchBeanDefinitionException: No qualifying bean of type \'cn.iocoder.yudao.framework.ai.chatqianwen.QianWenChatClient\' available', 'system', NULL, NULL, NULL, '2024-04-25 17:56:59', '2024-04-25 17:56:59', 1, 1, b'0');
  90 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (19, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-25 17:58:15', '2024-04-25 17:58:15', 1, 1, b'0');
  91 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (20, 1781604279872581644, 1, '作为一个AI助手,我没有个人感受和偏好。但是,中国是一个拥有丰富历史、文化和自然景观的国家,有许多令人惊叹的地方,如长城、故宫、西湖、张家界、九寨沟等著名景点,吸引了无数国内外游客的喜爱。每个人对于\"好看\"的定义可能不同,但中国无疑有着独特的魅力和多样性。', 'system', NULL, NULL, NULL, '2024-04-25 17:58:19', '2024-04-25 17:58:19', 1, 1, b'0');
  92 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (21, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-26 18:27:13', '2024-04-26 18:27:13', 1, 1, b'0');
  93 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (22, 1781604279872581644, 1, 'ClassCastException: class com.alibaba.dashscope.aigc.generation.models.QwenParam cannot be cast to class cn.iocoder.yudao.framework.ai.chatqianwen.api.QianWenChatCompletionRequest (com.alibaba.dashscope.aigc.generation.models.QwenParam and cn.iocoder.yudao.framework.ai.chatqianwen.api.QianWenChatCompletionRequest are in unnamed module of loader \'app\')', 'system', NULL, NULL, NULL, '2024-04-26 18:27:13', '2024-04-26 18:27:13', 1, 1, b'0');
  94 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (23, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-26 18:28:12', '2024-04-26 18:28:12', 1, 1, b'0');
  95 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (24, 1781604279872581644, 1, 'ClassCastException: class com.alibaba.dashscope.aigc.generation.models.QwenParam cannot be cast to class cn.iocoder.yudao.framework.ai.chatqianwen.api.QianWenChatCompletionRequest (com.alibaba.dashscope.aigc.generation.models.QwenParam and cn.iocoder.yudao.framework.ai.chatqianwen.api.QianWenChatCompletionRequest are in unnamed module of loader \'app\')', 'system', NULL, NULL, NULL, '2024-04-26 18:30:31', '2024-04-26 18:30:31', 1, 1, b'0');
  96 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (25, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-27 09:39:56', '2024-04-27 09:39:56', 1, 1, b'0');
  97 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (26, 1781604279872581644, 1, 'ClassCastException: class com.alibaba.dashscope.aigc.generation.models.QwenParam cannot be cast to class cn.iocoder.yudao.framework.ai.chatqianwen.api.QianWenChatCompletionRequest (com.alibaba.dashscope.aigc.generation.models.QwenParam and cn.iocoder.yudao.framework.ai.chatqianwen.api.QianWenChatCompletionRequest are in unnamed module of loader \'app\')', 'system', NULL, NULL, NULL, '2024-04-27 09:39:56', '2024-04-27 09:39:56', 1, 1, b'0');
  98 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (27, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-27 09:41:02', '2024-04-27 09:41:02', 1, 1, b'0');
  99 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (28, 1781604279872581644, 1, 'AiException: 没有找到apiKey!Can not find api-key.', 'system', NULL, NULL, NULL, '2024-04-27 09:41:02', '2024-04-27 09:41:02', 1, 1, b'0');
  100 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (29, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-27 09:41:58', '2024-04-27 09:41:58', 1, 1, b'0');
  101 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (30, 1781604279872581644, 1, 'AiException: 没有找到apiKey!Can not find api-key.', 'system', NULL, NULL, NULL, '2024-04-27 09:41:58', '2024-04-27 09:41:58', 1, 1, b'0');
  102 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (31, 1781604279872581644, 1, '中国好看吗?', 'user', NULL, NULL, NULL, '2024-04-27 09:42:41', '2024-04-27 09:42:41', 1, 1, b'0');
  103 +INSERT INTO `ai_chat_message` (`id`, `chat_conversation_id`, `user_id`, `message`, `message_type`, `top_k`, `top_p`, `temperature`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (32, 1781604279872581644, 1, 'ApiException: {\"statusCode\":400,\"message\":\"parameter incremental_output only support stream call\",\"code\":\"InvalidParameter\",\"isJson\":true,\"requestId\":\"9edd3968-6eec-901d-8194-15f497ca0d3a\"}', 'system', NULL, NULL, NULL, '2024-04-27 09:42:42', '2024-04-27 09:42:42', 1, 1, b'0');
  104 +COMMIT;
  105 +
  106 +-- ----------------------------
  107 +-- Table structure for ai_chat_modal
  108 +-- ----------------------------
  109 +DROP TABLE IF EXISTS `ai_chat_modal`;
  110 +CREATE TABLE `ai_chat_modal` (
  111 + `id` bigint NOT NULL AUTO_INCREMENT,
  112 + `model_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '模型名字\n',
  113 + `model_type` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '模型类型(自己定义qianwen、yiyan、xinghuo、openai)\n',
  114 + `modal_image` varchar(256) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '模型照片\n',
  115 + `config` json DEFAULT NULL COMMENT 'Ai配置文件',
  116 + `disable` tinyint DEFAULT NULL COMMENT '禁用 0、正常 1、禁用\n',
  117 + `create_time` datetime DEFAULT NULL COMMENT '创建时间',
  118 + `update_time` datetime DEFAULT NULL COMMENT '更新时间',
  119 + `creator` bigint DEFAULT NULL COMMENT '创建用户',
  120 + `updater` bigint DEFAULT NULL COMMENT '更新用户',
  121 + `deleted` bit(1) DEFAULT b'0' COMMENT '删除',
  122 + PRIMARY KEY (`id`)
  123 +) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_bin;
  124 +
  125 +-- ----------------------------
  126 +-- Records of ai_chat_modal
  127 +-- ----------------------------
  128 +BEGIN;
  129 +INSERT INTO `ai_chat_modal` (`id`, `model_name`, `model_type`, `modal_image`, `config`, `disable`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (1, '小红书Ai写作大模型', 'yiyan', '', NULL, 0, '2024-04-25 18:10:32', '2024-04-25 18:10:32', 1, 1, b'0');
  130 +COMMIT;
  131 +
  132 +-- ----------------------------
  133 +-- Table structure for ai_chat_role
  134 +-- ----------------------------
  135 +DROP TABLE IF EXISTS `ai_chat_role`;
  136 +CREATE TABLE `ai_chat_role` (
  137 + `id` bigint NOT NULL AUTO_INCREMENT,
  138 + `user_id` bigint DEFAULT NULL,
  139 + `model_id` bigint DEFAULT NULL COMMENT '模型编号,关联到角色使用的特定模型\n',
  140 + `role_name` varchar(128) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '角色名,角色的显示名称\n',
  141 + `role_introduce` varchar(256) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '角色介绍,详细描述角色的功能或用途\n',
  142 + `role_source` varchar(16) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '角色来源,如 system(系统预置)、customer(用户自定义)\n',
  143 + `classify` varchar(32) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '分类,角色所属的类别,如娱乐、创作等\n',
  144 + `visibility` varchar(16) COLLATE utf8mb4_0900_bin DEFAULT NULL COMMENT '发布状态,private 表示仅自己可见,public表示公开,disable表示禁用\n',
  145 + `top_k` float DEFAULT NULL COMMENT '生成时的Top-K采样候选集大小\n',
  146 + `top_p` float DEFAULT NULL COMMENT '生成时使用的核采样方法的概率阈值\n',
  147 + `temperature` float DEFAULT NULL COMMENT '用于控制随机性和多样性的温度参数\n',
  148 + `use_count` int DEFAULT NULL COMMENT '角色的使用次数统计\n',
  149 + `create_time` datetime DEFAULT NULL COMMENT '创建时间',
  150 + `update_time` datetime DEFAULT NULL COMMENT '更新时间',
  151 + `creator` bigint DEFAULT NULL COMMENT '创建用户',
  152 + `updater` bigint DEFAULT NULL COMMENT '更新用户',
  153 + `deleted` bit(1) DEFAULT b'0' COMMENT '删除',
  154 + PRIMARY KEY (`id`)
  155 +) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_bin;
  156 +
  157 +-- ----------------------------
  158 +-- Records of ai_chat_role
  159 +-- ----------------------------
  160 +BEGIN;
  161 +INSERT INTO `ai_chat_role` (`id`, `user_id`, `model_id`, `role_name`, `role_introduce`, `role_source`, `classify`, `visibility`, `top_k`, `top_p`, `temperature`, `use_count`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (1, 1, 1, '小红书写作v1---hh😄', '采用gpt3.5模型,拥有小红书优质作者写作经验。', 'system', 'writing', 'private', 0.2, 0.4, 0.7, 0, '2024-04-24 19:21:42', '2024-04-24 19:37:49', 1, 1, b'1');
  162 +INSERT INTO `ai_chat_role` (`id`, `user_id`, `model_id`, `role_name`, `role_introduce`, `role_source`, `classify`, `visibility`, `top_k`, `top_p`, `temperature`, `use_count`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (2, 1, 1, '小红书写作v2', '采用gpt3.5模型,拥有小红书优质作者写作经验。', 'system', 'writing', 'public', 0.2, 0.4, 0.7, 0, '2024-04-24 19:22:05', '2024-04-24 19:22:05', 1, 1, b'0');
  163 +INSERT INTO `ai_chat_role` (`id`, `user_id`, `model_id`, `role_name`, `role_introduce`, `role_source`, `classify`, `visibility`, `top_k`, `top_p`, `temperature`, `use_count`, `create_time`, `update_time`, `creator`, `updater`, `deleted`) VALUES (3, 1, 1, '小红书写作v1---', '采用gpt3.5模型,拥有小红书优质作者写作经验。', 'system', 'writing', 'public', 0.2, 0.4, 0.7, 0, '2024-04-24 19:29:38', '2024-04-24 19:29:38', 1, 1, b'0');
  164 +COMMIT;
  165 +
  166 +SET FOREIGN_KEY_CHECKS = 1;
... ...