Session Tokens
OpenCode TUI sidebar plugin for session token totals and per-model breakdown
61
+7 in 30 days
184
35 in 7 days
53.7
Multi-signal model
1 day ago
2026-10-19
Install and configure
opencode.jsonWrites to this project's opencode.json — applies to this repository only.
opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["@streetturtle/opencode-session-tokens@2.0.0"]
}Writes to ~/.config/opencode/opencode.json — applies to every project.
~/.config/opencode/opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["@streetturtle/opencode-session-tokens@2.0.0"]
}If you want to modify the plugin locally, install it into the project and reference the local path.
shell
pnpm add -D @streetturtle/opencode-session-tokensOpenCode loads npm dependencies through its embedded runtime on startup and caches them locally — no manual global install needed.
Small, focused OpenCode sidebar plugins that make daily coding sessions faster.
If this helps your workflow, please star the repo.
Install
Requires OpenCode 2.0 or newer.
opencode plugin add @streetturtle/opencode-open-in
opencode plugin add @streetturtle/opencode-context-progress
opencode plugin add @streetturtle/opencode-recap
opencode plugin add @streetturtle/opencode-session-tokens
opencode plugin add @streetturtle/opencode-current-prompt
or from OpenCode, press ctrl+p -> "Install Plugin" -> "@streetturtle/opencode-open-in"
Plugin Pack
@streetturtle/opencode-open-in- quick buttons to open the current session folder in Zed, VS Code, or Cursor.@streetturtle/opencode-context-progress` - context usage progress bar with token usage, window limit, and spend.@streetturtle/opencode-recap- one-click AI recap for the current session.@streetturtle/opencode-session-tokens- collapsible session token totals with per-model breakdown.@streetturtle/opencode-current-prompt- keeps the latest user prompt visible in the sidebar.
Similar plugins
Sidebar Token Metrics
opencode-sidebar-token-metrics
OpenCode sidebar plugin showing generation speed (tok/s), cache hit rate, and average time-to-first-token (TTFT).
Tui Context
opencode-tui-context
OpenCode TUI plugin that renders session context-window usage as a segmented bar in the sidebar
Context Progress
@streetturtle/opencode-context-progress
OpenCode TUI sidebar plugin for context usage progress