Skip to content

fix(code): honor configured preset instead of hardcoding flash#824

Merged
esengine merged 1 commit into
mainfrom
fix/code-preset-model-from-rokyplay-pr820
May 14, 2026
Merged

fix(code): honor configured preset instead of hardcoding flash#824
esengine merged 1 commit into
mainfrom
fix/code-preset-model-from-rokyplay-pr820

Conversation

@esengine
Copy link
Copy Markdown
Owner

Summary

reasonix code was passing opts.model ?? "deepseek-v4-flash" into both chatCommand and the system-prompt builder. A user with preset: pro or preset: auto in their config was silently downgraded to flash whenever they ran reasonix code without an explicit --model flag. Resolve the preset (loadPreset()resolvePreset()) and use its model id instead — mirrors the fix #819 landed on the desktop path.

Attribution

Original implementation by @rokyplay in #820 (their PR bundles this fix with a separate typeahead/steer feature). Splitting it out here so it can land independently — the preset fix is unambiguous and small, while the typeahead work needs tests + cleanup before it's ready (see review on #820).

Test plan

  • npm run typecheck
  • Pre-push npm run verify
  • Manual: with preset: pro in config, run reasonix code and confirm the status bar / first-turn cost reflects pro pricing

`reasonix code` was passing `opts.model ?? "deepseek-v4-flash"` into
chatCommand + the system-prompt builder, so a user with preset=pro or
preset=auto in their config was silently downgraded to flash. Resolve
the preset (`loadPreset()` → `resolvePreset()`) and use its model id
instead — mirrors the same fix #819 landed on the desktop path.

Original implementation by @rokyplay in #820; cherry-picked here as a
standalone fix so it can land independently of the typeahead/steer
work in that PR.
@esengine esengine merged commit 2284d32 into main May 14, 2026
3 checks passed
@esengine esengine deleted the fix/code-preset-model-from-rokyplay-pr820 branch May 14, 2026 08:54
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.

2 participants