Expand description
Transcript → candidate memory extractor.
从 Claude Code / Codex 的会话消息里启发式地挖出“值得变成记忆“的片段,
产出 TranscriptCandidate;上层再把它转成 ProposeMemoryRequest 走
LifecycleService::propose_ai,入库后以 Candidate 状态进入审核队列。
启发式目前刻意保守:宁可漏掉模糊的东西,也不要产生一堆噪音候选。 覆盖三类信号:
- 用户反馈 / 纠正(“不要每次都”/“always”/“don’t”/“记住”/“prefer”) → memory_type=“preference”
- 决策 / 方案敲定(“决定”/“就这么”/“decided to”/“chose”) → memory_type=“decision”
- 事故 / 踩坑回顾(“出过”/“曾经”/“之前”+“bug|incident|regression”) → memory_type=“incident”
Structs§
Enums§
Functions§
- extract_
from_ messages - 构建一次 session 的候选集合。
- import_
session - 驱动一次 session → candidate 流水。