Fix Claude JSONL parallel tool turn metrics#243
Conversation
|
Event: Handoff |
48b0214 to
6ad2fa3
Compare
Quality Gatekeeper ReviewVerdict: PASS (post-merge verification)
Validation commands:
Process note: this PR was merged while still observed as draft + |
Quality Gatekeeper Post-Merge AuditVerdict: PASS_POST_MERGE
|
Summary
Why
A curator flagged parser durability as the real reliability signal for agenttrace. The risky case is a modern Claude Code JSONL assistant turn that mixes thinking blocks and a parallel tool_use batch, followed by user-role tool_result blocks where is_error lives on the block. The previous parser handled those blocks, but split a multi-block assistant message into multiple assistant events, which could inflate assistant-turn metrics for parallel batches.
Validation
go test ./internal/enginego test ./...