Skip to content

feat(agent-sessions): read the gateway's usage buckets and llm-call marker - #1149

Closed
JeremyFunk wants to merge 6 commits into
mainfrom
feat/agent-sessions-read-usage-buckets
Closed

JeremyFunk wants to merge 6 commits into
mainfrom
feat/agent-sessions-read-usage-buckets

test(agent-sessions): build the gateway-stamp fixture without a condi…

09f070c
Select commit
Loading
Failed to load commit list.
Maple Review Bot / Maple / review succeeded Sep 29, 2026 in 2m 34s

Confidence 5/5 · No issues found

Confidence 5/5 · safe to merge
A test-fixture-only edit whose output is provably unchanged; the production code it exercises was reviewed at e5adc02.
quality 100/100 · no findings · tests not needed · risk low

The only change since the last review rebuilds the e2e fixture's modelCall helper with a single Object.fromEntries instead of an object literal with a conditional spread. It produces identical attrs, so it is safe to merge.

  • modelCall builds its attr record with one Object.fromEntries over MAPLE_AI_LLM_CALL_ATTR, the non-zero buckets and the cost
What was checked
  • modelCall emits the same keys in the same order as the literal it replaced: the marker first, zero buckets omitted, cost last (ai-trace-index-materialization.clickhouse.e2e.test.ts:106)
  • USAGE_BUCKET_KEYS order still matches the bucket order the seeds pass (input, cache read, cache write, output, reasoning)

09f070c · Updated on every push. Reply "won't fix" to dismiss a finding, or mention @maple to ask about one.