Files
Kokorone/apps/api/package.json
T
Jeffery e6f25008d1 feat: 完成 C 群組 — 記憶子系統
- WorkingMemoryService:session 對話上下文緩衝,token 溢位時優先裁切最舊的低情緒段落
- JobQueue 抽象層(now/schedule(at)/every(cron))與 InProcessJobQueue 實作(node-cron),
  R-6 會換成 BullMQ 但呼叫端介面不變
- MemoryConsolidationService:睡眠固化,只有高情緒或重複提及的內容才寫入 EpisodicMemory
- ForgettingSweepService:低情緒且長期未提取的記憶逐次降權、weight 過低後刪除,
  已掛上每小時一次的 JobQueue.every 排程
- KeywordMemoryRetriever:關鍵字+時間近因+情緒權重排序,提取命中即更新提取次數/時間
- apps/api 新增 /memory/* 端點作為引擎驗證介面(H 群組會決定併入正式對話管線後的去留)
- scripts/smoke/C.mjs:端到端驗證溢位裁切、只寫工作記憶、固化篩選、檢索排序、
  提取即改寫、schedule(at) 準時觸發、遺忘衰減與刪除

npm run restart && npm run smoke -- C 皆通過(C-V),A/B 群組冒煙測試無回歸。
2026-08-13 09:54:29 +08:00

27 lines
602 B
JSON
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{
"name": "@kokorone/api",
"version": "0.1.0",
"private": true,
"description": "心音後端服務(NestJS)",
"type": "module",
"main": "dist/main.js",
"scripts": {
"build": "tsc -b",
"start": "node dist/main.js"
},
"dependencies": {
"@kokorone/db": "*",
"@kokorone/shared": "*",
"@nestjs/common": "^11.1.29",
"@nestjs/core": "^11.1.29",
"@nestjs/platform-express": "^11.1.29",
"dotenv": "^17.4.2",
"node-cron": "^4.6.0",
"reflect-metadata": "^0.2.2",
"rxjs": "^7.8.2"
},
"devDependencies": {
"@types/node-cron": "^3.0.11"
}
}