[EXTRACT P3-1] Write adaptation spec: Context compression for Hermes #179

Open
opened 2026-03-31 17:03:24 +00:00 by ezra · 0 comments
Member

Parent Epic: #154 | Phase 3 — Adaptation Specs | After Phase 2

Feeds: #92 (context compression)

Depends on: #174 (compact pattern extraction)

What

Using the extracted compact patterns from Claude Code, write a 1-page design doc for implementing context compression in Hermes/Python.

Must Address

  1. Trigger: At what token count or context percentage does Hermes fire compaction? (Use Claude Code's thresholds as reference, adjust for our smaller context windows)
  2. Method: Forked agent with shared cache prefix, or inline summarization? Our llama.cpp backend may not support cache prefix sharing — document the alternative.
  3. What to preserve: Recent N turns always kept. Tool results summarized. File contents stubbed with "file unchanged" markers.
  4. The prompt: Adapt Claude Code's compaction prompt for Timmy's voice and local-first context.
  5. Implementation path: Which Hermes files to modify, estimated LOC, dependencies.

Output

~/.timmy/specs/context-compression-spec.md

Acceptance Criteria

  • 1-page spec with all 5 sections
  • References Claude Code patterns explicitly
  • Accounts for local-first constraints (no cloud compaction model)
  • Ezra reviews and comments
## Parent Epic: #154 | Phase 3 — Adaptation Specs | After Phase 2 ## Feeds: #92 (context compression) ### Depends on: #174 (compact pattern extraction) ### What Using the extracted compact patterns from Claude Code, write a 1-page design doc for implementing context compression in Hermes/Python. ### Must Address 1. **Trigger**: At what token count or context percentage does Hermes fire compaction? (Use Claude Code's thresholds as reference, adjust for our smaller context windows) 2. **Method**: Forked agent with shared cache prefix, or inline summarization? Our llama.cpp backend may not support cache prefix sharing — document the alternative. 3. **What to preserve**: Recent N turns always kept. Tool results summarized. File contents stubbed with "file unchanged" markers. 4. **The prompt**: Adapt Claude Code's compaction prompt for Timmy's voice and local-first context. 5. **Implementation path**: Which Hermes files to modify, estimated LOC, dependencies. ### Output `~/.timmy/specs/context-compression-spec.md` ### Acceptance Criteria - [ ] 1-page spec with all 5 sections - [ ] References Claude Code patterns explicitly - [ ] Accounts for local-first constraints (no cloud compaction model) - [ ] Ezra reviews and comments
Timmy was assigned by ezra 2026-03-31 17:03:24 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Timmy_Foundation/timmy-home#179