Switch-SWE: Do Coding Agents Hold Focus When Switching Between Unfinished Tasks?

Shuochen Chang, Qianli Ma, Yibo Miao, Qingyang Liu, Bingjie Gao, Haonan Zhao, Siyu Sun, Yulin Sun and 2 others

Shanghai Jiao Tong University · Tongji University

Published November 1, 2026 · on the feed November 4, 2026 · ▲ 10 · arXiv 2611.02017

The abstract

Software development sessions often involve several unfinished tasks rather than one issue carried through to completion. As coding agents take on repository-level development, they need to recover an earlier task's requirements and partial progress after intervening work. Existing repository-level benchmarks typically score one issue-to-patch episode and do not directly measure whether an agent can resume a task after advancing other unfinished work in the same repository. We introduce \ourmethod, a benchmark for focus-task resumption in sessions that interleave unfinished tasks drawn from the same source repository, with a persistent checkout for each task. Each focus task is evaluated in matched uninterrupted and switched sessions with identical focus requirements and executable verifiers. The switched session interleaves ordered stages from other unfinished tasks in the same repository, while only the final focus patch is scored. \ourmethod~contains 200 focus tasks from 19 Python repositories, reconstructed from issue, pull-request, and review histories and rendered as 400 matched session specifications. Across 7 coding agents, interleaved unfinished work produces an average focus-task resolution gap of 11.5 percentage points, ranging from 6.0 to 15.0 percentage points. Trajectory analysis identifies cross-task requirement confusion and loss of task state as recurrent resumption behaviors. We introduce a plug-in context-management module that selects task-relevant history and maintains concise task-state summaries. On OpenCode, the module improves focus-task completion under same-repository task switching by 5.5 to 15.5 percentage points across the evaluated models. Code is available at github.com/Miraclecsc/Switch-SWE.

The Brief

2:43

A short podcast summary of the paper. Written and voiced by AI.

Transcript

Switch-SWE. Do Coding Agents Hold Focus When Switching Between Unfinished Tasks?. By Shuochen Chang and nine others, from Shanghai Jiao Tong University and Tongji University. Published on the first of November.

A real development session rarely carries one issue cleanly through to completion. More often several tasks sit unfinished at once. As coding agents take on work at the level of a whole repository, they have to pick an earlier task back up: recover its requirements and its partial progress after other work has intervened. That is a different skill from solving a fresh issue. The agent has to hold on to what one task needed while working on another, then return and finish the first. Existing repository-level benchmarks typically score a single episode from issue to patch. They do not directly measure whether an agent can resume a task after advancing other unfinished work in the same repository, so this skill goes unmeasured.

Switch-SWE is a benchmark for exactly that: resuming a focus task in a session that interleaves unfinished tasks from the same source repository, with a persistent checkout kept for each task. The other tasks in the session are real work, advanced in stages, but they are not what gets graded. What is scored is the focus task, and only its final patch. The question is simply whether the agent, after all the switching, still delivers what the focus task asked for.

Each focus task is evaluated twice, in matched sessions. One is uninterrupted. The other is switched, interleaving ordered stages from other unfinished tasks in the same repository. Both carry identical focus requirements and executable verifiers, so any difference comes from the interruption. The benchmark holds two hundred focus tasks from nineteen Python repositories, reconstructed from issue, pull-request, and review histories, and rendered as four hundred matched session specifications.

Across seven coding agents, interleaved unfinished work opens an average gap in focus-task resolution of eleven point five percentage points. The smallest gap is six points, the largest fifteen. Analysis of trajectories identifies two recurring behaviors in resumption. One is confusion of requirements across tasks, where what one task asked for bleeds into another. The other is loss of task state, where the agent no longer has hold of where the focus task stood.

The authors also introduce a plug-in context-management module. It selects the history relevant to a task and maintains concise summaries of task state. On OpenCode, the module improves focus-task completion under same-repository task switching by between five point five and fifteen point five percentage points, depending on the model.

The matched design is what gives the headline its weight. Because the requirements and verifiers are the same in both sessions, the gap reads as the cost of having been interrupted. And a module that keeps relevant history and a running summary of task state is one way, on OpenCode, to pay less of it.

More with an account

Listen to every day’s papers

Daily playlists, deep dives, quests for the papers, and quizzes on their key terms.

Join free
KipQuest: the day’s AI research, as podcasts and quests. All papers Android app Privacy Contact Episodes are written and voiced by AI from each paper. Summaries can contain mistakes: the paper is the source.