fix: count reasoning tokens (#2187)

pull/2191/head
Aiden Cline 2025-08-22 18:21:39 -05:00 committed by GitHub
parent 004f53f741
commit 1f57b9a70f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -1680,7 +1680,7 @@ export namespace Session {
const tokens = {
input: usage.inputTokens ?? 0,
output: usage.outputTokens ?? 0,
reasoning: 0,
reasoning: usage?.reasoningTokens ?? 0,
cache: {
write: (metadata?.["anthropic"]?.["cacheCreationInputTokens"] ??
// @ts-expect-error