anomalyco / anomalyco/opencode

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

Open
#46,153 6 comments 1 reaction 1 assignee View on GitHub

@Hona is already working on this.

Since Aug 29, 2026.

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

Description

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

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.