Repository navigation
Description
Summary
OpenCode 2.0 has no UI plugin support in the desktop app, so session telemetry that is baseline in competing agents — token throughput, prompt-cache hit rate, and session token/cost totals — can only ever come from the app itself. Right now the desktop app ships none of it, and because 2.0 deliberately removed the UI extension path, this can no longer be filled in by the community. It has to be built in.
Why this is 2.0-critical (not a plugin gap)
In OpenCode 2.0 the plugin surface is split: server plugins add tools/hooks, and only CLI/TUI plugins (@opencode/plugin/tui, OpenTUI renderables) can draw UI, in the terminal. The desktop app is a separate client with no UI extension points at all. Every existing metrics plugin — oc-tps, the cache-hit sidebar panels, usage panels — is TUI-only and cannot render in desktop. So the usual "someone will make a plugin" answer does not apply here: if the app does not build it, desktop users never get it.
Baseline in comparable tools
Token and cache visibility is table stakes in this category:
- Claude Code:
/contextbreakdown and a statusline that surfaces tokens, cost, and session data. - Codex CLI: token usage in
/statusand the footer. - Cursor: per-session token and cost meter.
- OpenCode's own TUI: built-in per-response t/s in the assistant footer, plus an ecosystem of live TUI panels.
Desktop is the only OpenCode surface — and effectively the only client in this class — without it.
What the desktop app is missing
- Tokens per second: live while streaming, settled per response.
- Prompt-cache hit rate, cache read, cache write.
- Session-level input / output / reasoning / cache totals.
- Context saturation beyond the current on-hover numbers.
The desktop context/usage indicator already shows cost, context %, and token counts on hover, so this is an extension of an existing surface, not new chrome.
Proposal
- Add live and settled t/s to the desktop context/usage indicator. Use the same math as the TUI: estimate from output + reasoning deltas during streaming, settle to an exact rate from reported usage over the stream span when the step ends.
- Add prompt-cache hit rate and cache read/write to the same hover/panel.
- Optional session metrics panel: in/out/reasoning/cache totals, cost, context %, and t/s folded across the session family (parent + subagents).
An opt-in display setting is fine; the default should match what other agents show.
Related
- [FEATURE]: tokens-per-second in the desktop app (context usage indicator) #49380 — tokens-per-second in the desktop app (context usage indicator), open, label
2.0. This request is broader: cache hit rate and session totals in addition to t/s. - [FEATURE]:Show context usage in OpenCode Desktop, including for local OpenAI-compatible models #34900 — desktop context usage incl. cached tokens (closed as not planned).
- [FEATURE]: Show context usage in OpenCode Desktop #5892, [FEATURE]: Session context usage (similar to /context in Claude) #6152, Add /context command to display session token usage #10575 — desktop / context usage requests.
- [FEATURE]: Display token usage information in the TUI #13003, [FEATURE]: Show cached token count inline in TUI context panels #23109 — TUI token and cache display requests.
- TUI built-in t/s: Feature request: show token throughput (tok/s) in the TUI #43857, [FEATURE]: Real-time token generation speed (tok/s) in TUI status bar, like Hermes #47914; accuracy follow-ups tui: tok/s excludes reported reasoning tokens in V2 #48705, PR fix(tui): include reasoning tokens in throughput #48689.
Additional context
Filed because 2.0 closed the plugin route for desktop UI. Without a built-in implementation there is no path for desktop users to see this data in-app; the only workaround today is running a separate TUI instance alongside the desktop app.
Activity
github-actions commentedon Sep 29, 2026
This issue doesn't fully meet our contributing guidelines.
What needs to be fixed:
Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of existing issues. Please check:
If you believe this was flagged incorrectly, please let a maintainer know.
github-actions commentedon Sep 29, 2026
This issue has been automatically closed because it was not updated to meet our contributing guidelines within the 2-hour window.
Feel free to open a new issue that follows our issue templates.