Skip to content
back to the archive page
#AI4SDLC

How Cursor picks a model for the agent’s next turn (Series #AI4SDLC)

“Figure out why the test failed” and “now commit the fix” could easily be consecutive messages in one chat. Why pay the same rate for both? With its router and Auto mode for model selection, Cursor suggests we don’t have to. When we discussed this on the latest episode of 3 AImigo, we talked about how hard it is to build a router that can pick the right model automatically. Cursor’s posts show how the team put that idea into practice and what it costs to switch models halfway through a conversation. In its July 22 announcement, Cursor says it trained the router on more than 600,000 live requests, then ran A/B tests on millions of requests. In an August 6 technical post, the team explains how the router picks a model before each response.

How does the router know a turn is hard? Compass looks at the request, the conversation so far, and recent tool calls. During training, the developer’s next message provides a clue. Having to correct the agent is a negative signal. Moving on to another task is a positive one. That gives Cursor an estimate of how satisfied the developer was with the response. The test could still be failing.

When is a pricier model worth it? A low-cost model can handle a simple turn. For a harder one, the router considers where the work is happening and what needs doing. Even within a single database, changing a schema and investigating a slow query are different jobs. A pricier model makes the shortlist only if it shows a convincing advantage over the low-cost model on Cursor’s metric for similar turns. Each mode then has its own budget for the average cost per turn. That gives Auto Intelligence room to pick expensive models more often than Auto Balance.

There’s a detail here that’s easy to miss when comparing prices per million tokens. The previous model may already have part of the conversation in its cache. After a switch, you may pay to process those same tokens again. Cursor’s measurements on live traffic include those cache misses. As of August 6, the team reported that Auto Balance cost 41% less than Opus 4.8 and scored higher on that same proxy for developer satisfaction.

Why come back to the harness papers here? In the harness design study, switching to Bash alone helped one model on SWE-bench and made another noticeably worse. And in Beyond the Model, the benefit of a more elaborate harness for stronger models depended even on whether they were fixing bugs or reconstructing a program from its behavior. That gives me a question I’d test after changing an agent’s tools. If the router learned yesterday to send debugging tasks to a particular model, is that model still the best choice with the new toolset? (Cursor bases its routing decisions on statistics from live user requests.)

#AI4SDLC #Agents #DevTools #Evals #Engineering