RunStatsAccumulator
Defined in: packages/core/src/core/runStats.ts:99
Mutable tally behind finalizeRunStats; see createRunStatsAccumulator.
Properties
Section titled “Properties”input:
number
Defined in: packages/core/src/core/runStats.ts:101
Running sum of input/prompt tokens.
output
Section titled “output”output:
number
Defined in: packages/core/src/core/runStats.ts:103
Running sum of output/completion tokens.
sawUsage
Section titled “sawUsage”sawUsage:
boolean
Defined in: packages/core/src/core/runStats.ts:105
Whether ANY message reported usage_metadata — gates whether tokens are recorded at all.
toolResults
Section titled “toolResults”toolResults:
GthToolResult[]
Defined in: packages/core/src/core/runStats.ts:109
BATCH-21 — one record per executed tool result (ToolMessage), in arrival order, un-deduped.
tools:
Set<string>
Defined in: packages/core/src/core/runStats.ts:107
Deduplicated set of invoked tool names.