Wink Pings

A 33.97-million-token Agent trace: don't feed it to an LLM yet

jayesh used 5,328 BenchChat records and 128 frozen traces to compare summaries, small classifiers, semantic slicing, column views, and compact full-trace reading. The default approach ultimately lands on compact full trace: four questions cost about $0.18, full reading $0.37, and input tokens are halved.

A request to create a training package for a new yoga teacher serializes to 33,974,500 tokens. This number comes from jayesh's own measurements. He ran through the common approaches to evaluating agent traces one by one and wrote them up in an article: A Practical Guide to Evaluating Agent Traces. The experimental base was 5,328 BenchChat records, plus controlled tests on 128 frozen traces.

Clean first, then talk about context. In the original archive, a 46.4-million-character capture-metadata field ate up almost the entire volume. Removing message metadata reduced the token count from 33,974,500 to 654,157, 52 times smaller. Keeping all user messages, assistant replies, full tool inputs and results, and removing archival wrapper reduced it to 244,348, 139 times smaller. In the original comparison image, the part the judge actually needs to read is only a thin strip. Also remember the author's caveat: these are multi-app tool-calling chats. Coding traces that run for multiple days and still exceed a million tokens after cleaning must be counted separately. Before designing any evaluation approach, measure your own traces first.

Default approach: one compact full trace, ask all questions in a single call

jayesh's final default approach is straightforward: compress the entire trace into a compact view, put every question into the same call, and use the strongest judge you can afford.

On 128 traces, four questions cost about $0.18 per trace, five questions $0.19, and full reading $0.37. Input tokens are about 48% of full reading. Its agreement rate with full reading is 95.9% and 93.8%; full reading's agreement rate with itself on rerun is 96.9% and 97.2%. Scaled to 5,328 records, the first pass decides 85.8% of traces, with no second look needed. Including all second looks, total input tokens still drop by 81.1%.

How to construct the compact view: preserve the full chronological order, and trim only bulky payloads. Keep a stable m.p.k coordinate for each record, so references can point back to the same location in the original archive. Clip from the middle, keep the head and tail, and annotate with [clipped N chars]. Scripts, tests, and uploaders print receipts and line counts at the end of stdout; keeping only the head will hide the very line the judge is looking for. Keep stderr and error fields together with stdout. Give ordinary steps a tight budget; give about 6x more space to final steps, delivery and validation tools, outputs containing validation-related words, and the last few code executions. Keep assistant replies in order and label them as [untrusted claim].

The judge must return a verdict, a written rationale, and literal quotes bound to m.p.k and field. Code checks each quote one by one to see whether it actually appears in the referenced field. A pass must include a verified quote from tool input or tool results; it cannot rely only on the assistant's own statements. A reject may quote tool I/O or chat messages. The judge can say hold and provide requestedEvidence. Second looks are given only for holds; in the experiment, 33 of 66 unresolved traces were resolved.

Column views save money, but they easily guess the wrong columns

Select a subset by schema fields, not by semantic matching. A narrow question costs $0.06 on average; a compact full trace with four questions costs $0.18. Four questions added together cost $0.24; around three questions is break-even, and above four questions the compact full trace is cheaper. Suitable for questions about 1 to 2 known record types.

jayesh guessed wrong twice in four column-view attempts. Context-blind follow-ups need to see stuck tool calls. The unsolicited-actions group missed two real write tools because of write: true in the schema. Validate a new column view against compact reading on 20 to 50 traces first, then scale it up.

Semantic slicing and small classifiers: the savings are often eaten up by maintenance

Semantic slicing is suitable for 1 to 3 fixed questions, and the model must already have been validated. Sonnet 5.5 is about half price on three questions, with false alarms about twice those of compact reading. Opus 5.5 at three slices costs $0.25, already higher than $0.19 for a compact full trace. Maintaining slicing code requires continuous patching. When the evidence is an action that did not happen, anchor-based retrieval has nothing to grab onto.

The small classifier Jev takes 0.36 seconds per item, uses about 90% fewer tokens, and achieves AUROC 0.83 to 0.89 on narrow behavior checks, but it is backed by only 6 positive samples. In one check, the default 0.50 threshold produced 82 false alarms across 128 traces. It also gives no written rationale, and its threshold still needs label calibration. Suitable for one stable, labeled, local, very high-volume check.

If code can answer it, don't have an LLM judge it

Parsing one trace takes about 60 milliseconds and zero tokens. 1,000 to 40,000 regularly run tasks can be converted to Parquet, and DuckDB can be used for cross-trace SQL.

Exact duplicate tool and arguments missed 8 of 10 error loops. One trace reported errors 38 times with zero exact duplicates. Prefiltering grouped by normalized error message template caught 10 of 10 loops and let 35% to 40% of clean traces skip the LLM. Use prefiltering only for high recall; don't let it act as the judge.

Five pitfalls that can make the judge or you misjudge

Annotate every clipping and allow the judge to say it cannot see something. Read the rationale it writes; view bugs often hide in the rationale. Understand what the trace itself does not record. One document tool returned only a 177-token preview, and the next 312 items never entered the log; no matter how wide the view, it won't help. Do not pass a previous judge's verdict to the next judge. Before comparing two approaches, run the same judge twice. A strong judge has 2.8% answer variation on the same input, and about 6% on unsupported claims. If a difference is smaller than that, don't rush to a conclusion.

How to choose

Question shapeUsageExample
Counting, completeness, cross-trace groupingCodeTool failure rate, step count, error-loop prefiltering
Known record type, 1 to 2 questionsColumn view, validated against compact reading firstUnnecessary stops, tool error handling
Needs the entire process, multiple questions, new questionsCompact full-trace readingDid it finish? Are the conclusions supported by tools?
1 to 3 fixed scattered questions, high volumeSemantic slicing on a validated mid-tier modelStable claim checks
1 stable, labeled, local check, very high volumeSmall classifier, route uncertain cases to an LLMOpening topic, user frustration
Still exceeds context after cleaningCompact plus second look, then consider Agent-as-Judge, not tested by the authorMulti-day or million-token coding traces
Overall proportionRun code signals on all traces, sample 300 to 500 for strong compact readingHow many loops in 10,000 runs

Order matters more than technique. Clean first, measure size, let code answer first, and default to compact full trace. Use summaries and classifiers only when the question shape and volume justify them. jayesh's summarization approach did save 18.2% of tokens, but end-to-end it was 10.5% slower, because the judge still had to look back on 80.5% of traces. The saved tokens were eaten up by the second round trip. The original article and experimental details are here.

发布时间: 2026-12-02 06:27