mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-02 12:50:23 +00:00
fix: use transcript usage as fallback for /status token display
When using custom providers like LM Studio, Ollama, or DashScope, token counts in /status show as 0 because the agent meta store does not always have usage data populated for these providers. Fix: set includeTranscriptUsage: true in both /status command and the session_status tool. This enables the existing fallback path that reads usage from the session transcript JSONL file when the meta store has zero/missing token counts. The merge logic already guards against overwriting valid data: - totalTokens: only updated when zero or transcript value is larger - inputTokens/outputTokens: only filled when zero/missing - model/contextTokens: only filled when missing Fixes #54995
This commit is contained in:
committed by
Peter Steinberger
parent
b601c7cb8f
commit
97a8ba89fd
@@ -345,7 +345,7 @@ export async function buildStatusText(params: {
|
||||
subagentsLine,
|
||||
taskLine,
|
||||
mediaDecisions: params.mediaDecisions,
|
||||
includeTranscriptUsage: false,
|
||||
includeTranscriptUsage: true,
|
||||
});
|
||||
|
||||
return statusText;
|
||||
|
||||
Reference in New Issue
Block a user