forked from kent/consciousness
Claude Code doesn't create new session files on context compaction —
a single UUID can accumulate 170+ conversations, producing 400MB+
JSONL files that generate 1.3M token prompts.
Split at compaction markers ("This session is being continued..."):
- extract_conversation made pub, split_on_compaction splits messages
- experience_mine takes optional segment index
- daemon watcher parses files, spawns per-segment jobs (.0, .1, .2)
- seg_cache memoizes segment counts across ticks
- per-segment dedup keys; whole-file key when all segments complete
- 150K token guard skips any remaining oversized segments
- char-boundary-safe truncation in enrich.rs and fact_mine.rs
Backwards compatible: unsegmented calls still write content-hash
dedup keys, old whole-file mined keys still recognized.
|
||
|---|---|---|
| .. | ||
| bin | ||
| neuro | ||
| store | ||
| audit.rs | ||
| config.rs | ||
| consolidate.rs | ||
| daemon.rs | ||
| digest.rs | ||
| enrich.rs | ||
| fact_mine.rs | ||
| graph.rs | ||
| knowledge.rs | ||
| lib.rs | ||
| llm.rs | ||
| lookups.rs | ||
| main.rs | ||
| migrate.rs | ||
| query.rs | ||
| search.rs | ||
| similarity.rs | ||
| spectral.rs | ||
| util.rs | ||