Repository navigation
Conversation
- Preserves trace provenance while consolidating related span records - Keeps degraded and crashed invocations usable for diagnostics
- Verifies coding-agent digests and AgentHarness sequence bounds while streaming session files - Preserves partial evidence with explicit integrity and ordering diagnostics
- Prevents transcript facts from being duplicated into invocation traces - Documents deterministic ordering, digest verification, and partial recovery behavior
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
Build a deterministic, self-contained evidence document from each complete or partially recoverable invocation trace.
The materializer validates trace structure, resolves referenced session segments, and preserves source provenance without duplicating transcript content into trace records.
Reasoning
Invocation traces contain execution facts while session JSONL remains authoritative for messages, tool calls, tool results, usage, and compactions.
Keeping those ownership boundaries explicit avoids competing copies and lets missing or changed session data surface as diagnostics instead of silently producing unsupported conclusions.
The normalized model is runtime-neutral, so coding-agent v3 entry cursors and AgentHarness durable sequence cursors produce the same evidence shape without coupling either runtime to the other's internal types.
Developers gain a bounded, LLM-ready diagnostic document that remains useful when an invocation or one of its referenced sessions is incomplete.
Changes
MaterializedInvocationmodel and stable JSON serialization.Testing
node ../../node_modules/vitest/dist/cli.js --run test/harness-trace.test.ts test/materializer.test.tsnpm run checkgit diff --check feat/invocation-trace-lifecycle...HEAD