Quality assurance · Production
Cursor improves Tab code completion with online reinforcement learning
The problem
The Tab model showed too many incorrect suggestions, disrupting coding flow; the core challenge was not just improving model accuracy but knowing when to suggest and when to stay silent.
Workflow diagram · grounded in source
1
User action triggers Tab
trigger
“Whenever you type a character or move your cursor within the editor, our Tab model tries to predict what you'll do next”
2
Model generates suggestion
ai_action
“if it has sufficient confidence, we'll display its prediction as a suggestion that you can accept by pressing Tab”
3
Reward assigned from accept/reject
feedback_loop
“we could assign a reward of 0.75 for accepted suggestions, a reward of -0.25 for rejected suggestions, and a reward of 0 if no suggestion is shown”
4
Policy gradient model update
ai_action
“positively reinforcing the actions that led to high reward, while negatively reinforcing the actions that led to low reward”
5
Checkpoint deployed to users
integration
“Currently, it takes us 1.5 to 2 hours to roll out a checkpoint and collect the data for the next step”
Reported outcome
The new Tab model makes 21% fewer suggestions while achieving a 28% higher accept rate, and has become the new default in Cursor.
Reported metrics
daily Tab requestsover 400 million
Suggestions shown reduction21% fewer
Accept rate improvement28% higher
Checkpoint rollout and data collection time1.5 to 2 hours
Reported stack
PyTorch
Frequently asked questions
What did this team achieve with this AI workflow?
The new Tab model makes 21% fewer suggestions while achieving a 28% higher accept rate, and has become the new default in Cursor.
What tools did this team use?
PyTorch.
What results were reported?
daily Tab requests: over 400 million; Suggestions shown reduction: 21% fewer; Accept rate improvement: 28% higher; Checkpoint rollout and data collection time: 1.5 to 2 hours (source-reported, not independently verified).
How is this quality assurance AI workflow structured?
User action triggers Tab → Model generates suggestion → Reward assigned from accept/reject → Policy gradient model update → Checkpoint deployed to users.