Skip to content

fix(config): accept 'model' key as alias for 'default' in config.yaml model section#3544

Closed
ygd58 wants to merge 1 commit into
NousResearch:mainfrom
ygd58:fix/config-model-key-alias
Closed

fix(config): accept 'model' key as alias for 'default' in config.yaml model section#3544
ygd58 wants to merge 1 commit into
NousResearch:mainfrom
ygd58:fix/config-model-key-alias

Conversation

@ygd58

@ygd58 ygd58 commented Mar 28, 2026

Copy link
Copy Markdown
Contributor

Fixes #3535

Problem

model.model in config.yaml was silently ignored. _get_model_config() only read cfg.get("default"), causing fallback to hardcoded anthropic/claude-opus-4.6 for providers like kimi-coding.

Fix

Two places updated:

  1. _get_model_config(): normalize "model" → "default" early, so all downstream code benefits automatically
  2. Line 85: added model_cfg.get("model") fallback alongside model_cfg.get("default")

Both spellings now work:

  • model: { default: moonshot-v1-auto } ✅ (documented)
  • model: { model: moonshot-v1-auto } ✅ (now fixed)

@teknium1

Copy link
Copy Markdown
Contributor

Merged via #3603. Your fix was salvaged onto current main and extended to cover all three config consumers (runtime_provider, CLI, and gateway) plus docs. Authorship preserved. Thanks for the contribution!

@teknium1 teknium1 closed this Mar 28, 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.

[Bug]: config.yaml model.model key is silently ignored — falls back to hardcoded default

2 participants