anomalyco / anomalyco/opencode

Feature: Show context/output limits in /models command

Open
#40,792 0 comments 0 reactions 1 assignee View on GitHub

@kommander is already working on this.

Since Aug 6, 2026.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
PR merge metrics
PR metrics pending

Description

Feature Request

Problem

The /models command in the TUI currently only lists model names. There is no way to see the maximum context length or output token limit for each model without manually opening the config file or querying the provider API.

This makes it difficult to:

  • Know which models support longer conversations
  • Compare context windows when switching models
  • Verify that config limits match the actual provider limits
Proposal

Enhance the /models command to display context and output token limits alongside each model name, e.g.:

litellm/glm-5.2-local    context: 300,000    output: 128,000
litellm/qwen3.6-plus     context: 1,000,000   output: 64,000
litellm/claude-sonnet-5  context: 1,000,000   output: 128,000

These values are already configured in opencode.json(c) under models.<name>.limit.context and models.<name>.limit.output, so the data is available locally without additional API calls.

Use Case

When working with long conversations or large codebases, users need to quickly identify which models have sufficient context capacity. Having this info inline in the /models picker would save time and avoid hitting context limits unexpectedly.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.