From 54b9ca18b581bee4dbeeb5d26add6847408fb09f Mon Sep 17 00:00:00 2001 From: SerenNoble Date: Sun, 21 Jun 2026 19:00:48 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20aipet=20=E8=AE=B0=E5=BF=86=E4=B8=8D?= =?UTF-8?q?=E8=AE=BE=E4=B8=BA=E9=BB=98=E8=AE=A4=EF=BC=88=E4=BF=9D=E6=8C=81?= =?UTF-8?q?=E5=8F=AF=E7=94=A8=EF=BC=8C=E9=BB=98=E8=AE=A4=E6=81=A2=E5=A4=8D?= =?UTF-8?q?=20nomem=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 202606211000.sql:aipet 实例 is_default=0(is_enabled=1 仍可在智控台选用), 去掉「把所有 Memory 置为非默认」的全局 UPDATE,保留各部署自己的默认选择。 默认记忆回到 nomem,需要 aipet 时在智控台手动切换。 Co-Authored-By: Claude --- .../src/main/resources/db/changelog/202606211000.sql | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/main/manager-api/src/main/resources/db/changelog/202606211000.sql b/main/manager-api/src/main/resources/db/changelog/202606211000.sql index c510804ea..099c09aa2 100644 --- a/main/manager-api/src/main/resources/db/changelog/202606211000.sql +++ b/main/manager-api/src/main/resources/db/changelog/202606211000.sql @@ -1,16 +1,12 @@ --- 注册 aipet 记忆实例并设为默认(FTS5 本地记忆,运行时由 core/providers/memory/aipet 自动加载 xiaozhi-memory 框架) --- 先把其他 Memory 配置置为非默认 -UPDATE `ai_model_config` SET `is_default` = 0 WHERE `model_type` = 'Memory'; - --- 插入 aipet 实例(config_json 字段对齐 aipet.py:db_path / retrieval_mode) +-- 注册 aipet 记忆实例(可用,不设为默认;默认记忆由各部署自行选择) +-- config_json 字段对齐 aipet.py:db_path / retrieval_mode INSERT INTO `ai_model_config` (`id`, `model_type`, `model_code`, `model_name`, `is_default`, `is_enabled`, `config_json`, `sort`, `creator`, `create_date`, `updater`, `update_date`) VALUES ( - 'Memory_aipet', 'Memory', 'aipet', 'AIPet本地记忆(FTS5)', 1, 1, + 'Memory_aipet', 'Memory', 'aipet', 'AIPet本地记忆(FTS5)', 0, 1, JSON_OBJECT('type', 'aipet', 'db_path', './data/xiaozhi_memory.db', 'retrieval_mode', 'fts5'), 10, 1, NOW(), 1, NOW() ) ON DUPLICATE KEY UPDATE - `is_default` = VALUES(`is_default`), `is_enabled` = VALUES(`is_enabled`), `config_json` = VALUES(`config_json`);