Skip to content

fix(config): resolve model defaults per agent provider - #22

Merged
niranjan94 merged 1 commit into
release/v2from
fix/provider-aware-model-defaults
Jun 15, 2026
Merged

fix(config): resolve model defaults per agent provider#22
niranjan94 merged 1 commit into
release/v2from
fix/provider-aware-model-defaults

Conversation

@niranjan94

Copy link
Copy Markdown
Owner

Problem

Codex runs with no explicit model override failed every stage with a 400:

The 'claude-opus-4-7[1m]' model is not supported when using Codex with a ChatGPT account.

The model input defaults were hard-coded Claude ids in action.yml, which the Actions runtime injects before our code runs. So even when a consumer set agent_provider: codex and left the model inputs unset, a Claude model id reached the Codex SDK.

Fix

  • action.yml: blank all eight *_model defaults (default: "").
  • src/config/inputs.ts: parseConfig resolves an empty model input to a provider-aware default via a DEFAULT_MODELS table:
    • claudeclaude-opus-4-8[1m] for spec/plan/implement/review, claude-sonnet-4-6 for triage (existing cheaper triage tier preserved; opus bumped 4-7 → 4-8).
    • codexgpt-5.5 for every stage.
  • An explicit model input always overrides the default.

Notes

  • Patch version bumped to 2.0.2; dist/index.cjs rebuilt.
  • Tags left untouched (released separately).
  • Added parseConfig tests for claude defaults, codex defaults, and explicit-override precedence. Full suite: 281 passing.

The model input defaults were hard-coded Claude ids in action.yml, so a
Codex run with no explicit model override sent a Claude model name to the
Codex SDK and failed with a 400 ("model not supported when using Codex
with a ChatGPT account").

Blank the action.yml model defaults and resolve a provider-aware default
in parseConfig: claude-opus-4-8[1m] (claude-sonnet-4-6 for triage) for
claude, gpt-5.5 for every codex stage. An explicit model input still wins.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Shopfloor agent review: clean across 4/4 reviewers.

  • No coding-standard or agent-convention violations: the only convention file is CLAUDE.md, the dist bundle is included/rebuilt as required, and the diff introduces nothing that contradicts documented commands, file-placement, package-manager, or formatting rules.
  • Provider-aware model-default substitution is logically correct; agent_provider is enum-constrained so the DEFAULT_MODELS lookup is always defined, empty inputs fall through to defaults, and explicit values override.
  • Model-default resolution refactor only; no exploitable security patterns introduced.
  • Provider-aware model-default change is well-structured with explanatory comments and matching tests; no maintainability smells worth flagging.

@niranjan94
niranjan94 merged commit af885ff into release/v2 Jun 15, 2026
6 checks passed
@niranjan94
niranjan94 deleted the fix/provider-aware-model-defaults branch June 15, 2026 11:10
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