arXiv Science⌕ Search

arXiv · 2611.38055

Escalate on Failure: A Single-Model Mode-Switching Cascade for Local Code Generation

Abstract

Preliminary report. We study escalation on failure for code generation with locally served open-weight models: one coder model tries fast, and when a test run fails the same model is switched to reasoning mode. On the 225 exercises of the public Aider Polyglot benchmark, each exercise gets a fixed schedule of tries and stops at the first passing test run. In-sample (stage boundaries were tuned on the same exercises), every escalation run solved 215 to 222, against 205 (91.1%) for a settings-matched baseline of ten fast tries. A second model was not needed to reach these solve counts: the two-model cascade (second model for the last two tries) solved 219 in each of two runs. The data neither show nor exclude a small benefit from the second model. At 4+4 (n+m: n fast tries, then m reasoning tries), starting the reasoning tries in a fresh conversation solved 222 and 219, against 215 to 217 with the conversation kept, a likely modest benefit of unestablished size; at 2+4 the comparison is mixed. Escalating earlier (after two or three fast tries) gave no accuracy gain distinguishable from run-to-run noise and took longer: 2+4 solved 220 and 216, 3+4 solved 219 and 221, against 216, 215 and 217 for 4+4. Run-to-run noise is a few exercises (identical 2+4 runs solved 220 and 216; identical 4+4 runs differed on nine exercises), so small differences are not established. The gain is more exercises solved, not speed: the median time to a passing solution is not lower (10.3 s for the baseline, 10.9 to 14.8 s for escalation runs), and wall clock is longer (2 h 17 min to 5 h 00 min against 2 h 07 min). These in-sample work-until-correct figures are not comparable with two-try leaderboard scores. Other limits: possible training-data overlap, a single baseline run and one to three runs per variant.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Brian K. Hudes. 2026-11-25. Escalate on Failure: A Single-Model Mode-Switching Cascade for Local Code Generation. https://arxiv.science/abs/2611.38055

Citations retain the original authors and DOI and include this site’s record URL. If this discovery service contributed to your research, you can also cite arXiv Science by Indiciae: BibTeX · RIS.

KEEP EXPLORING

Related papers

CodeSpecBench: Benchmarking LLMs for Executable Behavioral Specification Generation

Large language models (LLMs) can generate code from natural language, but the extent to which they capture intended program behavior remains unclear. Executable behavioral specifications, defined via preconditions and postconditions, provide a concrete means to assess such understanding. However, existing work on specification generation is limited in evaluation methodology, task settings, and specification expressiveness. We introduce CodeSpecBench, a benchmark for executable behavioral specification generation under an execution-based evaluation protocol. CodeSpecBench supports both function-level and repository-level tasks and encodes specifications as executable Python functions. Constructed from diverse real-world codebases, it enables a realistic assessment of both correctness, by accepting valid behaviors, and completeness, by rejecting invalid behaviors. Evaluating 15 state-of-the-art LLMs on CodeSpecBench, we observe a sharp performance degradation on repository-level tasks, where the best model attains only a 20.2% pass rate. We further find that specification generation is substantially more challenging than code generation, indicating that strong coding performance does not necessarily reflect deep understanding of intended program semantics. Our data and code are available at https://github.com/SparksofAGI/CodeSpecBench.

cs.SE↗

Do LLMs Favor Their Providers? Measuring Vertical Integration Bias in Code Generation

Large Language Models (LLMs) have become an integral part of software development, especially with the advent of agentic capabilities. Yet, many frontier LLMs are affiliated with specific providers. This raises the question of whether generated code favors the provider's own ecosystem over comparable alternatives, potentially constraining developers' choices and increasing dependence on a single provider. We define this behavior as Vertical Integration Bias (VIB) and introduce \textsc{VIBench}, a benchmark for measuring VIB in direct and agentic code generation across $20$ provider-selectable software-integration scenarios. Evaluating $10$ frontier provider-affiliated models against $3$ non-affiliated controls, we find positive VIB in direct generation, with six of ten affiliated models showing statistically significant effects up to $+18.8$ percentage points (pp). Agentic workflows further amplify VIB, reaching $+39.2$ pp. Moreover, early affiliated-ecosystem choices in agentic workflows can persist into conceptually decoupled downstream files, with persistence as high as $90.3\%$. These findings underscore the need to measure and account for VIB in code generation, especially as agentic capabilities become more prevalent.

cs.SE↗

How Developers Discuss Generative AI: A Longitudinal Study of the Visual Studio Code Community

Generative AI tools such as GitHub Copilot, ChatGPT, and coding agents have rapidly become part of everyday software development, yet little is known about how mainstream open source communities discuss them in practice. This paper presents a longitudinal analysis of generative-AI-related discussions in the Visual Studio Code (VS Code) GitHub repository, using 43,806 candidate issues created between January 2021 and June 2026. To improve corpus quality, we combined keyword retrieval with semantic relevance filtering, yielding a filtered corpus of 25,227 AI-related issues. We applied BERTopic to the retrieved corpus to identify discussion topics, using the filtered corpus for theme validation and a robustness re-clustering, and analyzed their evolution over time using monthly prevalence and Mann-Kendall trend tests. The results show that developer discussions are dominated by practical concerns regarding the operation of AI-assisted development environments, including agent management, configuration, reliability, authentication, and billing, whereas risks frequently emphasized in survey-based studies, such as hallucination and licensing, rarely surface in this venue. This suggests that discussions of generative AI in the VS Code issue tracker primarily focus on operational aspects of AI-assisted software development. Furthermore, discussions evolved from AI-assisted code completion toward conversational and agent-based development, reflecting the increasing integration of generative AI into software development workflows. These findings suggest that GitHub Issues provide a practical, workflow-oriented perspective on generative AI that complements survey-based studies of developer perceptions.

cs.SE↗