mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-28 04:59:52 +01:00
fix: aipet 记忆不设为默认(保持可用,默认恢复 nomem)
202606211000.sql:aipet 实例 is_default=0(is_enabled=1 仍可在智控台选用), 去掉「把所有 Memory 置为非默认」的全局 UPDATE,保留各部署自己的默认选择。 默认记忆回到 nomem,需要 aipet 时在智控台手动切换。 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
ea5ccf5d40
commit
54b9ca18b5
1 changed files with 3 additions and 7 deletions
|
|
@ -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`);
|
||||
|
|
|
|||
Loading…
Reference in a new issue