Readable session layout, folded raw traces, prune-raw (0.10.0) - #82
Merged
Conversation
Implements design/designs/session-layout-and-ids.md for new sessions; legacy timestamp-style sessions and mirror traces stay readable through their lifetime via the centralized sessions.py helpers. - Session dirs are ordinal+slug (001_ship-the-ultimate-memory-program, children/01_phase-0-foundations); timestamp, goal hash, and uuid move into session.json. IDs derive once at creation; nothing re-parses paths or re-hashes content to reconstruct them. - The traces mirror tree is gone for new sessions: per-attempt raw artifacts live under sessions/<id>/raw/<NNNN>_<workflow>/ with no two-level hash nesting, no trace_manifest.json, no trace_seals/, no finalization outbox. trace_ref.json carries a plain relative path. Evidence documents belong in the durable tree; both stock preambles now state the placement rule. - Git and delivery receipts merge into receipts/ with self-describing names (0026_outer_git_after.json). Eval receipts keep their dir -- their raw-report provenance binding is load-bearing and is now folded-layout aware. - raw/ is gitignored per session (plus template ignore lines); new `loopy prune-raw [--older-than] [--session] [--legacy-traces]` deletes raw planes without ever touching the durable tree. - docs/session-layout.md rewritten for the folded layout with a legacy appendix. Deferred per the design's own escape hatch: collapsing the four frozen roster/contract files into session.json (45+ references across the frozen-state machinery; separate change if still wanted). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EPYwF6cRYs2mfsfHF1hibc
The rewritten outer/planner prompts described handoff.json as "summary,
status, open_work, risks, and refs", but LayerHandoff is extra="forbid"
and has no status or refs fields -- an orchestrator following the prompt
produces a handoff the engine rejects, which then invalidates its
terminal control ("cited handoff observation is invalid") and blocks
layer completion indefinitely. Observed live in the ultimate-memory-cloud
program (4 rejected control publications). Prompts now state the exact
schema: schema_version, session_id, goal_sha256, revision, producer,
summary, accepted_outcomes, open_work, risks, decision_refs,
evidence_refs, delivery_refs, eval_refs, updated_at.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EPYwF6cRYs2mfsfHF1hibc
Member
Author
|
Rode along on this branch: fix(templates) commit correcting the handoff contract in the outer/planner prompts — the wave-1 rewrite described handoff.json with |
Three consecutive live children each burned one rejected terminal-control cycle guessing the evidence-ref format (a URL + bare git SHA, repo:path without the slash, absolute filesystem paths). The control example now states the grammar: <scope>:/<path> with scopes repo, session, parent, root; URLs/SHAs/absolute paths belong inside a referenced file. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EPYwF6cRYs2mfsfHF1hibc
fazpu
changed the base branch from
single-goal-assignments-and-prompt-diet
to
main
July 19, 2026 11:10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Wave 2 of the simplification designs (
design/designs/session-layout-and-ids.md), stacked on #81. New sessions get a reviewable tree; legacy sessions keep working unchanged.NNN_<slug>(slug from the goal), childrenNN_<slug>(slug from the request id):sessions/001_ship-the-ultimate-memory-program/children/01_phase-0-foundations/. Timestamp/goal-hash/uuid becomesession.jsonfields. IDs derive exactly once at creation — the truncated-hash trace-dir bug class is gone by construction.traces/mirror tree is retired for new sessions. Per-attempt raw artifacts live insessions/<id>/raw/<NNNN>_<workflow>/(git/, harness/, protocol/, eval/, service/) with no hash nesting, notrace_manifest.json, notrace_seals/, no finalization outbox.trace_ref.jsonis a plain relative path. Both stock preambles now carry the placement rule: scratch → raw/, anything citable as evidence → durable tree.receipts/named by iteration (0026_outer_git_after.json). Eval receipts keep their dir — their raw-report provenance binding is load-bearing v3 machinery and is now folded-layout aware.raw/is gitignored per session; newloopy prune-raw [--older-than DAYS] [--session ID] [--legacy-traces]deletes raw planes and never touches durable files. Deletingraw/leaves every plan/handoff/receipt ref resolvable.docs/session-layout.mdrewritten (it was stale against v0.8) with a legacy appendix. Version: 0.10.0.Deferred, per the design's own escape hatch: collapsing the four frozen roster/contract files into
session.json— 45+ references across hash-pinned frozen-state machinery; worth its own change if still wanted.Test plan
🤖 Generated with Claude Code
https://claude.ai/code/session_01EPYwF6cRYs2mfsfHF1hibc