[0.25.0] - 2026-04-26
Added
tool_result_eventsarchive table is now populated (#101).buildArchive()materializesToolResultEventLineledger lines into the previously-emptytool_result_eventstable during incremental builds, keyed on (source,session_id,message_id,tool_use_id,event_index). Columns mirror the canonicalToolResultEventRecord:status,content_length,content_hash,subagent_session_id,agent_id,event_source,ts,call_index. Cursor uses the samearchive_state.ledger_offset_bytesas turns / stamps / compactions, so no parallel cursor and no extra disk read.rebuildArchive()replays tool-result events alongside the other line kinds and yields the same row count deterministically. Newidx_tool_result_events_use_id/_session/_subagentindexes for the obvious join paths.BuildResult.toolResultEventsAppliedandArchiveStatus.rowCounts.toolResultEventsexpose the new counts. Closes #101, refs #40, #42, #77.
Changed
- Bumped
ARCHIVE_VERSIONto 2 to pick up the newtool_result_eventsindexes on existing archives. The nextbuildArchive()call detects the version mismatch and rebuilds from scratch — safe because the archive is derived state.