Evaluate: Tree-structured session storage (Pi pattern) for terraphim_persistence
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
Direzione di ricerca
Start with terraphim_persistence (#637) and ADF session persistence (#639), then read the linked Pi session format. Prototype the id/parentId JSONL approach and compare parsing and storage for 1000+ entries against the current linear format. Document trade-offs and finish with an adopt, adapt, or reject decision.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Parent Epic
#682 -- Evaluate Pi architectural patterns
Pattern
Pi (badlogic/pi-mono) uses tree-structured JSONL for session storage. Each entry has id and parentId fields, enabling in-place branching without creating new files. A visual /tree navigator lets users jump to any point and continue from there. All branches are preserved in a single file.
Current State
- terraphim_persistence (#637-#642) plans to use Persistable trait + DeviceStorage with SQLite/redb backends
- Claude Code uses linear JSONL with lossy auto-compaction (no branching within a session)
- ADF session persistence (#639) captures Claude Code's
--output-format stream-jsonoutput as linear JSONL - terraphim-agent sessions import reads linear JSONL from
~/.claude/projects/
Evaluation Questions
- Does tree-structured JSONL improve debugging and replay for ADF agent sessions? Current linear format loses context on compaction. Tree format preserves all branches.
- Is the id/parentId overhead justified? Each entry gains two fields. Measure storage and parse overhead for typical 500-2000 message sessions.
- Can tree structure coexist with Claude Code's linear format? terraphim-agent imports Claude Code sessions. If we adopt tree format internally, we need a conversion layer.
- Does the tree structure enable new capabilities? E.g., comparing different agent approaches on the same prompt, replaying from a checkpoint with different models.
Acceptance Criteria
- Document trade-offs (storage overhead, parsing complexity, tooling requirements)
- Prototype tree-structured session format for terraphim_persistence
- Benchmark parse performance vs linear JSONL for 1000+ entry sessions
- Decision: adopt, adapt, or reject with rationale
References
- Pi session format: https://github.com/badlogic/pi-mono/blob/main/packages/coding-agent/docs/session.md
- terraphim_persistence: #637
- ADF session persistence: #639
- Lingua principale
- Rust
- Stelle
- 62
- Fork
- 5
- Merge medio
- 2h 27m
- PR unite (30g)
- 1
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di terraphim/terraphim-ai
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
terraphim/terraphim-ai#885 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 55/100
terraphim/terraphim-ai#871 ·
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
terraphim/terraphim-ai#810 · 2 commenti ·
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
terraphim/terraphim-ai#729 ·
-
enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
terraphim/terraphim-ai#728 ·
Tutte le issue di terraphim/terraphim-ai
Issue simili
-
Browser (wasm) relay client cannot connect to relays whose URL has a trailing-dot FQDN hostname Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
n0-computer/iroh#4550 ·
-
impl detach for native Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
paritytech/zombienet-sdk#591 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
farion1231/cc-switch#7638 · 1 commento ·
-
onnx-ir re-exports ModelProto and GraphProto but not NodeProto, AttributeProto and AttributeType Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100