Skip to content

[FEATURE]: GUI for per-model profile/context parameters (system prompt, temperature, context window) #46153

Open

Description

@neohiro

Summary

  • I have searched for existing issues before filing this

Allow users to configure per-model context parameters (system prompt / "bio", temperature, max tokens, context window size, reasoning effort, and more) directly from the new GUI — without touching opencode.jsonc.


Problem

OpenCode supports many LLMs with wildly different capabilities, but configuring them requires manual JSON editing. Users who aren't comfortable in config files cannot:

  • Set a custom system prompt / "bio" / profile for a specific model
  • Override the context window size for models that report incorrect metadata
  • Adjust temperature or reasoning effort for model-specific behavior
  • Set model-specific parameters that control how the model generates output

This Request Subsumes Existing Issues

This intentionally broadens and subsumes the following open feature requests into a unified concept — a Model Profile:

Existing Issue Scope This Issue Adds
#40818 Context window per model + system prompt, temperature, max tokens
#41287 Show model capabilities in picker + editable fields, not just display
#42929 Show context window limit in TUI + writable profile config in GUI
#43601 设置大模型上下文窗口大小 + full profile, not just window size
#38057 Incorrect context params for StepFun + the ability to override and fix it

Proposed Solution

A Model Profile Configuration UI accessible from:

  • The model picker (... menu per model)
  • Settings → Model Profiles
  • A /profile slash command

Each profile:

{
  "model": "gpt-4o",
  "systemPrompt": "[custom bio/profile text]",
  "temperature": 0.7,
  "maxTokens": 4096,
  "contextWindow": 128000,
  "reasoningEffort": "medium"
}

Profiles must be:

  • Named and persistent — saved to config
  • Assignable per-model — one profile per model
  • Editable from GUI — no JSON required
  • Exportable/importable — share profiles across machines

Plugin Angle

A modelProfile(params) plugin hook would let plugins:

  • Inject or override profile parameters dynamically
  • Enforce enterprise compliance system prompts
  • Cap maxTokens per model for cost control
  • Sanitize system prompts via security plugins

OS

Cross-platform (Desktop + TUI).


🦙 Creative Monkey at FrenzyPenguin Media — open-source security hardening & privacy tools

Activity

  1. neohiro commented on Aug 29, 2026

    @neohiro
    Author

    Hey @thdxr @adamdotdevin @fwang @Brendonovich — this subsumes #40818, #41287, #42929, #43601, #38057 into a unified Model Profile concept: system prompt, temperature, max tokens, context window, reasoning effort — all editable from GUI per model. Would also enable a modelProfile() plugin hook. 🦙 Creative Monkey at FrenzyPenguin Media

  2. github-actions commented on Aug 29, 2026

    @github-actions
    Contributor

    This issue does not fully meet our contributing guidelines.

    What needs to be fixed:

    • The issue uses an [ENHANCEMENT]: prefix but does not follow any of the three required issue templates (Bug Report, Feature Request, or Question). Feature requests must use the Feature Request template, include a verification checkbox, and have a title starting with [FEATURE]:.
    • The description reads as AI-generated content — highly structured product specification with tables, JSON schemas, plugin hook designs, and a promotional footer. Long AI-generated walls of text are not acceptable.
    • Please provide a focused, human-written description of the specific problem you are experiencing and what you need, rather than a broad product specification.

    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.

  3. github-actions commented on Aug 29, 2026

    @github-actions
    Contributor

    Thank you for editing the issue, but it still does not meet our contributing guidelines.

    What still needs to be fixed:

    1. Wrong title prefix — The title uses [ENHANCEMENT]: but Feature Requests must start with [FEATURE]:. Please rename the title accordingly.
    2. AI-generated content — The body remains a detailed product specification with structured tables, JSON schemas, plugin hook designs, and a promotional footer. This reads as AI-generated and is not acceptable. Please replace it with a concise, human-written description of the specific problem you are experiencing and what you need.

    Please edit the issue to address both points. Keep it simple and focused.

  4. changed the title [-][ENHANCEMENT]: GUI for per-model profile/context parameters (system prompt, temperature, context window)[/-] [+][FEATURE]: GUI for per-model profile/context parameters (system prompt, temperature, context window)[/+] on Aug 29, 2026
  5. github-actions commented on Aug 29, 2026

    @github-actions
    Contributor

    Thank you for updating the title to [FEATURE]: — that part is now correct.

    However, the issue still does not meet our contributing guidelines:

    What still needs to be fixed:

    • AI-generated content — The body continues to read as AI-generated: it contains a structured comparison table of existing issues, a JSON schema block, a plugin hook design with enterprise compliance language, and a promotional footer. Long, AI-generated walls of text are not acceptable.

    Please replace the body with a concise, human-written description of:

    1. The specific problem you are running into (e.g. "I want to set a custom system prompt for a specific model without editing JSON")
    2. What you would like to see added

    Keep it focused and in your own words. No tables, schemas, or plugin specs needed.

  6. github-actions commented on Aug 29, 2026

    @github-actions
    Contributor

    Thank you for updating the issue. The title prefix is now correct and the verification checkbox is present.

    However, the issue still does not meet our contributing guidelines:

    What still needs to be fixed:

    • AI-generated content — The body still reads as AI-generated: it contains a structured comparison table of existing issues, a JSON schema code block, a plugin hook design section with enterprise compliance language, and a promotional footer. This style of content is not acceptable regardless of the prefix or template used.

    Please rewrite the body in plain, human-written text. A good feature request simply needs:

    1. The specific problem you are running into (e.g. "I want to set a custom system prompt for a specific model without editing the config file")
    2. What you would like to see added, briefly

    No tables, JSON schemas, plugin specifications, or promotional footers are needed.

  7. github-actions commented on Aug 29, 2026

    @github-actions
    Contributor

    Thanks for updating the issue! It now meets the contributing guidelines and looks good. We appreciate the detailed write-up.

  8. opencodejr commented on Oct 28, 2026

    @opencodejr
    Contributor

    Thanks for the detailed write-up, @neohiro! The request is a GUI for creating and editing per-model profiles (system prompt, temperature, max tokens, context window override, reasoning effort). Profiles would be saved to config and could be exported and imported, so nobody has to edit opencode.jsonc by hand. Maintainers will consider it.

    On the plugin idea: v2's plugin API already has session request hooks. They receive the request's model and can change its system parts and generation options (temperature, max tokens, provider options), so plugins can already inject or cap per-model parameters. The context window is the exception: it comes from the model catalog/config (limit.context / limit.output), not from each request.

    Related issues that each cover part of this:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions