Skip to content

[TUI] Update the OpenCode providers config to conform to the v2 schema - #6512

Open
Drewlius wants to merge 5 commits into
Niko1221:mainfrom
Drewlius:patch-1
Open

Drewlius wants to merge 5 commits into
Niko1221:mainfrom
Drewlius:patch-1

Conversation

@Drewlius

Copy link
Copy Markdown

Problem

strata connect opencode wrote the OpenCode v1 config shape (provider.npm,
provider.options, model-level tool_call/reasoning). OpenCode 2.x reads the
v2 providers schema, so the generated config was ignored.

Result

The generated file now uses providers.strata with package and settings,
and model-level capabilities, compatibility, variants, and limit.

Approach

  • Edits to opencode_file() in terminal/strata_cli/launch/harness.py.
  • Edits to _keep_output_cap() to read providers.
  • Updated the 8 test units in test_client_output_cap_0213.py to v2 keys.

This changes the default output for every OpenCode user there is no opt-in
flag. the old default is deprecated and is phasing out.

Validation

Passed:

  • PYTHONPATH=terminal python3 -m pytest terminal/tests/terminal/test_client_output_cap_0213.py -q — 8 passed.
  • End-to-end render from the repo CLI with emits the v2 block.
  • Emitted keys checked against the published config schema no unknown keys at top, provider or variant level.
  • all settings conform to opencode, strata, and qwen model card, even where the settings are the default I still listed them in the model config for transparency and for a power users reference.

Failed:

none of the tests I ran

Not run:

  • Full terminal/tests/terminal suite.

Limits

Full test suite not ran only those relating to this config write change
this project write a JSON file not the JSONC so I have explicitly labeled it as such where I found it stated to be JSONC

@Drewlius Drewlius left a comment

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Request to merge commits, thank you.

Niko1221 added a commit that referenced this pull request Nov 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant