Conversation
WorkerService assembled the EdgeWorker config field by field and omitted cursorDefaultModel and cursorDefaultFallbackModel, so values set in config.json never reached RunnerSelectionService. Every Cursor session fell back to the built-in default model regardless of configuration. Mirror the existing codex/claude passthrough (env var takes precedence over config file) so the Cursor runner honors the configured model. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Setting
cursorDefaultModel(andcursorDefaultFallbackModel) in~/.cyrus/config.jsonhad no effect — every Cursor runner session used the built-in default model (composer-2) regardless of configuration.Root cause
WorkerService.startEdgeWorker()assembles theEdgeWorkerConfigobject field by field. It passesclaudeDefaultModel,geminiDefaultModel,codexDefaultModel, anddefaultRunnerfromedgeConfig, but omitscursorDefaultModelandcursorDefaultFallbackModel. So although these fields exist in the config schema, inConfigManager, and are consumed byRunnerSelectionService.getDefaultModelForRunner("cursor"), the value never reaches the runtime —this.config.cursorDefaultModelis alwaysundefinedand the resolver falls back to"composer-2".The description-tag workaround (
[model=...]) does not help either: aclaude-*model string is inferred as theclauderunner, conflicts with thecursorrunner, and gets reset — so Claude-family Cursor models can only be set via config, which was the broken path.Fix
Add
cursorDefaultModelandcursorDefaultFallbackModelto the config assembly, mirroring the existing codex/claude passthrough (env var takes precedence over config file). IntroducesCYRUS_CURSOR_DEFAULT_MODELfor parity withCYRUS_CODEX_DEFAULT_MODEL.Testing
pnpm buildandpnpm typecheckpass across the monorepo (also enforced by the pre-commit hook).pnpm --filter cyrus-edge-worker test:run— 733 passed.pnpm --filter cyrus-ai test:run— 94 passed.Note on coverage
WorkerService.startEdgeWorker()has no unit coverage today — the config object is built inline within a large method with git/oauth closures, so no existing test asserts the codex/claude passthrough either. A regression test would require extracting the config assembly into a pure function; I kept this PR surgical and did not add a resolver-level test that would pass regardless of the bug. Flagging the gap for maintainers.🤖 Generated with Claude Code