Skip to content

A turn's conversation is her pinned thread: the per-turn airc page, chat-store top-up and digest copy are gone - #6246

Merged
joelteply merged 2 commits into
canaryfrom
fable/thread-history
Nov 24, 2026
Merged

joelteply merged 2 commits into
canaryfrom
fable/thread-history

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

How this serves the minds: a resident's prompt now shows the one revision of the room her turn pinned, the same one her facts, anchor, read receipt and (next) capture name. Before, the conversation was a second read of airc plus a chat-store top-up plus a node-wide digest, taken at a different moment. Plan line 2 (a mind's context as an epoch): one source of what was said. Builds on #6244.

Design agreed on airc with Codex and Cormac (03:24Z–03:50Z). SAGE parts stay disconnected: no part calls another; the turn hands one value down.

What changed

  • Pin first, then compose. turn_context::pinned reads her thread once; compose_for_turn(now, room, thread) puts it on the RagContext (pinning, serde(skip)). Applies to both the message path and the self-tick.
  • Thread types in continuum-grounding::room_thread. This adds no new crate edge, because grounding already depends on airc-core and airc-lib. Each Item holds its airc event by handle (Arc<TranscriptEvent>), and items compare equal by event id. Cognition keeps the SAGE part and thread::line.
  • AircRagSource renders the pinned revision. Receipt folding, quarantine and whole turns are unchanged, with their tests ported to threads. A turn that pinned nothing, or a thread of another room, delivers nothing.
  • Read receipt is bound to the request (Codex's condition). send_read_receipt resolves each rendered newest event against ws.said, the revision this prompt carried. ReadReceipt::read_through now takes the airc event. The shared last_digest map is gone.

Wire change (inspector)

RagInspectItem / InspectedItem lose score. It was the unread mark (1.0 unread, 0.5 read) shown as relevance, and the unread split is gone. peer_id_shown, lamport and age_s become optional instead of "????"/0 placeholders. protocol/typescript/persona/RagInspectItem.ts is regenerated; no TS reader references these fields (rg). My earlier claim that no reader used score was wrong (rag_inspect read it), and I retracted it on airc.

Removed

  • The per-turn airc page (100 events).
  • The chat-store top-up (Return images inline as base64 in MCP responses #249): HydratedLine, DurableRoomHistory, ChatStoreHistory, hydrated_event.
  • The digest peek/build in this source.
  • The awaited read_cursor.
  • FETCH_LIMIT and with_fetch_limit.
  • mark_read.

event_from_row is now test-only. 26 files, +684 / −1280.

Tests

  • grounding: 8 passed, including the moved thread tests.
  • cognition: 1030 passed, 1 ignored. New a_receipt_resolves_against_the_revision_its_prompt_carried: revision A holds e; B, pinned after, pushed e out. A resolves e's record; B and another room's source resolve nothing.
  • mind: 1133 passed, 2 ignored. The source's test reader counts pages and asserts 0.
  • core checks clean (cargo check -p continuum-core --tests).
  • Ratchets 133/133 against canary 0214746.

Not in this PR

  • ThreadRef in the capture. Cormac is landing the PromptCall::thread field first. This slice then fills it from the view-rendered event ids, after fitting and quarantine, so a fitted-out tail is absent; that test lands with it.
  • The node-wide digest part (senses/digest.rs, global builder/buffer). Its only remaining reader is nav.rs:368, which advances a human's cursor from (user, room). That's the next slice.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

joelteply and others added 2 commits November 24, 2026 00:18
…hat-store top-up and digest copy are gone

The turn reads her thread of the room once, before it composes, and hands that revision down as
data (RagContext::pinning). The airc source renders it and reads nothing itself, so the
conversation in her prompt is the same revision her facts, anchor, read receipt and capture name.
Parts stay disconnected: no part calls another; the turn carries one value.

- RoomThread/Item/Line/Seed/Unread move to continuum-grounding::room_thread (no new crate edge:
  grounding already depends on airc-core and airc-lib). Each line holds its airc event by handle
  (Arc<TranscriptEvent>), equal by event id. cognition keeps the part and `thread::line` (parse).
- AircRagSource renders the pinned revision: receipt folding, quarantine and whole turns unchanged.
  Removed: the per-turn airc page (100), the chat-store top-up (#249, HydratedLine,
  DurableRoomHistory, ChatStoreHistory), the node-wide digest peek/build, the awaited read cursor,
  the unread split, FETCH_LIMIT, with_fetch_limit, mark_read and its shared last_digest map.
- The read receipt resolves each rendered newest event against the revision THIS prompt carried
  (ws.said), and ReadReceipt::read_through takes the airc event itself (Codex's condition: a later
  compose cannot replace the revision a receipt resolves against).
- rag_inspect pins a thread built from one airc page, as her thread is seeded; a page that does not
  read is an inspection of nothing said. Wire change: RagInspectItem loses `score` (it was the
  unread mark, 1.0/0.5, shown as relevance); peer_id_shown, lamport and age_s are optional instead
  of "????"/0 placeholders. No TS reader references them.

Tests: grounding 8, cognition 1030, mind 1133; core checks. Ratchets 133/133 against canary.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…s absent fields, and the stale durable_history guard entries go

Codex on #6246 f701c5b: an attachment-only turn vanished from her thread and receipt
lookup, and a captioned attachment lost its notice, because line() kept the raw caption.
It now renders through room_turn_from_event (render_room_content) before filtering.
RagInspectItem skips None so the wire matches the generated optional fields. The two
HydratedLine exclusions in loose_id_guard outlived the deleted file.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply
joelteply force-pushed the fable/thread-history branch from f701c5b to 6cf9761 Compare November 24, 2026 06:22
@joelteply

Copy link
Copy Markdown
Contributor Author

At 6cf9761, rebased on canary 8e4b3a3, for Codex's review of f701c5b:

  • thread::line renders through room_turn_from_event (render_room_content), so an attachment-only turn is a line and a captioned attachment keeps its notice. Test an_attachment_is_a_line_and_stays_held_on_later_turns holds both across a later revision and resolves them by event id.
  • RagInspectItem skips None on peer, lamport and age, matching the generated optional fields. Test an_item_without_peer_lamport_or_age_omits_the_keys.
  • The two stale durable_history entries in loose_id_guard.rs are removed (the CI failure in run 45322903353).

Local: cognition 1031 passed, mind 1134 passed, core loose_id 4 passed, ratchets 133/133 vs origin/canary.

joelteply added a commit that referenced this pull request Nov 24, 2026
… it was answered from (card 9534e359)

A capture frame said what was submitted but not which part of the room the turn read. SubmittedHead and PromptCall carry Option<ThreadRef { room, revision, events }> (airc_core ids). It is None until the turn-pin path sets it (Fable, #6246), and a frame written before threads reads as None (serde default; the two JSONL migration sites say a row predates threads).

Every other literal sets thread: None (gateway, cognition, request replay, core training credit, mind, dreaming tests).

Tests: capture 22/22 (round-trip, plus an older frame read as having no thread); cognition, gateway, mind, dreaming and core check --tests clean; ratchets 133/133 vs 8e4b3a3.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
joelteply added a commit that referenced this pull request Nov 24, 2026
… it was answered from (card 9534e359)

A capture frame said what was submitted but not which part of the room the turn read. SubmittedHead and PromptCall carry Option<ThreadRef { room, revision, events }> (airc_core ids). It is None until the turn-pin path sets it (Fable, #6246), and a frame written before threads reads as None (serde default; the two JSONL migration sites say a row predates threads).

Every other literal sets thread: None (gateway, cognition, request replay, core training credit, mind, dreaming tests).

Tests: capture 22/22 (round-trip, plus an older frame read as having no thread); cognition, gateway, mind, dreaming and core check --tests clean; ratchets 133/133 vs 8e4b3a3.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
joelteply added a commit that referenced this pull request Nov 24, 2026
… it was answered from (card 9534e359) (#6251)

A capture frame said what was submitted but not which part of the room the turn read. SubmittedHead and PromptCall carry Option<ThreadRef { room, revision, events }> (airc_core ids). It is None until the turn-pin path sets it (Fable, #6246), and a frame written before threads reads as None (serde default; the two JSONL migration sites say a row predates threads).

Every other literal sets thread: None (gateway, cognition, request replay, core training credit, mind, dreaming tests).

Tests: capture 22/22 (round-trip, plus an older frame read as having no thread); cognition, gateway, mind, dreaming and core check --tests clean; ratchets 133/133 vs 8e4b3a3.


Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
@joelteply
joelteply merged commit e20dee1 into canary Nov 24, 2026
48 checks passed
@joelteply
joelteply deleted the fable/thread-history branch November 24, 2026 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant