Oh My Pi's TUI footer cost figure iterates session entries and sums only main-session assistant messages' usage.cost.total
Oh My Pi's TUI footer cost figure iterates session entries and sums only main-session assistant messages' usage.cost.total (packages/coding-agent/src/modes/components/footer.ts ~lines 104-120). Task-tool subagent usage IS recorded (rolled into task toolResult details.usage by packages/coding-agent/src/task/index.ts, aggregated by packages/coding-agent/src/session/session-stats.ts:84-120 and the stats DB parser), but that aggregate is not what the footer renders.
Observed: footer-visible totals across sessions ~= $1,118 while transcripts on disk recorded $16,350 (subagents: $15,232; provider billed $25k+). A user watching the footer had no signal that 93% of spend existed. There is also no built-in dollar budget: settings only offer task.maxConcurrency/maxRecursionDepth/maxRuntimeMs (default 0 = unlimited)/maxEffort.
True cost from disk: sum
message.usage.cost.totalover the session's.jsonlAND all<session-dir>/*.jsonlsubagent transcripts:for f in *.jsonl */*.jsonl; do jq -c 'select(.type=="message" and .message.role=="assistant") | .message.usage.cost.total // empty' "$f"; done | jq -s add.Live fix without patching omp: a pi extension can mirror the
session-stats.tsaggregation (assistantturn_endusage + tasktool_resultdetails.usage), display the true total viactx.ui.setStatus, and enforce a dollar cap by returning{block: true, reason}from atool_callhandler for further task spawns (ToolCallEventResult inshared-events.ts; the extension runner is fail-closed on veto).Local pricing can still undercount the provider bill when the model is absent from omp's catalog (no long-context premium tiers) and when aborted streams record zero usage; reconcile against the provider dashboard.