Description
Open Interpreter runs code locally with full internet access, but provides no token usage visibility. Unlike cloud-based code interpreters (ChatGPT Code Interpreter, Claude Code), users have no way to see how many tokens each assistant message consumed or estimate the cost.
OI already uses readline for history (per issue #1697). Adding token/cost tracking would complement that infrastructure.
Suggested implementation
Track tokens per assistant response and display after each message:
- Add a %tokens on/off magic command to toggle (persists in session)
- Show always-on when --verbose flag is set
- Add --track-cost CLI flag
Use Case
Developers testing different models and budget-conscious users want to monitor token usage and estimated costs in real-time, especially when iterating on prompts or processing large datasets.
Additional Information
This could be gated behind a config flag track_usage: true in ~/.config/open-interpreter/config.yaml for users who want it enabled by default.
Description
Open Interpreter runs code locally with full internet access, but provides no token usage visibility. Unlike cloud-based code interpreters (ChatGPT Code Interpreter, Claude Code), users have no way to see how many tokens each assistant message consumed or estimate the cost.
OI already uses readline for history (per issue #1697). Adding token/cost tracking would complement that infrastructure.
Suggested implementation
Track tokens per assistant response and display after each message:
Use Case
Developers testing different models and budget-conscious users want to monitor token usage and estimated costs in real-time, especially when iterating on prompts or processing large datasets.
Additional Information
This could be gated behind a config flag track_usage: true in ~/.config/open-interpreter/config.yaml for users who want it enabled by default.