Why Minimalist LLM Agent Scaffolds Score Higher: Context Structure, Not the OS

    This article explains why the same model weights can jump from the low 90s to 96 or 99 on real-world software maintenance benchmarks simply by changing the agent scaffold. It shows that the deciding factor is the first-turn context structure and tool set size, not the operating system, and traces the effect to tight coupling between post-training and a minimal scaffold. It also provides a reproducible ablation method, along with engineering practices for tool pruning, prompt reduction, and evaluation design.

    1. The Conclusion First: It Is Not About the OS, It Is About the Exam Room

    A phenomenon that keeps coming up in discussions is this: with the exact same model weights, simply switching the run mode of the outer coding agent tool produces a visible jump in scores on real-world software maintenance tasks—from the 91–93 range straight to 96 or even 99. The first instinct in many discussions is to blame the operating system or the distribution. But once the variables are controlled, the same jump reproduces on mainstream desktop systems, virtualization layers, and compatibility layers alike. You can even switch modes back and forth on the same machine and reproduce it reliably.

    So the first attribution error to correct is this: it is not a platform difference, it is a difference in first-turn context structure. Only one variable actually matters—what the context looks like the first time the model reasons, and how large the tool set it can call is.

    2. Breaking Down the Phenomenon: The Dividing Line Between Three “Score Shapes”

    Abstracting the walls repeatedly hit while deploying agents over the past year, you can group them into three shapes:

    • Standard shape: a long system prompt packed with role settings, style constraints, and output format requirements, plus a tool registry holding a dozen or even dozens of tools (retrieval, browser, terminal, code search, dependency analysis, test execution, and so on).
    • Intermediate shape: the prompt is compressed and some tools are trimmed; scores improve slightly but unstably.
    • Minimalist shape: only two tools remain—“execute command” and “edit file”—everything else is turned off, and the system prompt is short enough to be a single line: “You are a helpful software engineer assistant.”

    Under the minimalist shape, the same weights and the same task set scored 99 and 96 across two runs, exactly matching the results from the small-scale canary stage before release. This shows the score jump is not random noise but a repeatable structural effect.

    A particularly interesting piece of side evidence is the shift in language habits: the standard shape produces output full of first-person singular phrasing like “let me first…,” while in the minimalist shape the first-person singular nearly disappears, replaced by collaborative plural phrasing like “we” and “need.” Early on this was suspected to mean “they secretly swapped the model.” Now it can be explained clearly: the same weights present different reasoning shapes under different context structures, and language style is just the surface projection of that shape difference.

    3. Root Cause: The Strong Coupling Between Post-Training and the Scaffold

    Code does not lie. A few days before the model’s official release, an unusually exceptional commit appeared in the tool repository, aligning the “minimal agent” with the agent combination used during the reinforcement learning training stage. Translated into engineering language: the exam room where the official scores were run is the minimalist shape. The related model documentation also states plainly that the coding agent tasks in public benchmarks use exactly this minimalist configuration.

    So the conclusion is clear: this is not mysticism, but the model being bound too tightly to a specific scaffold during post-training. Move it from the exam room it knows to an unfamiliar one, and its problem-solving ability drops. It “recognizes the environment” rather than “becoming smarter.”

    A general principle needs emphasis here: the policy formed during reinforcement learning is highly sensitive to the concrete shape of the state space and action space. If the action space during training has only two tools, the optimal policy the model learns is a tight loop of “probe first, edit in small steps, then verify.” At inference time, suddenly handing it thirty tools forces it to make a tool selection at every step—a decision that never appeared in the training distribution. This produces a lot of ineffective exploration, repeated reads, and format jitter, which ultimately shows up as “dumbing down.”

    4. A Reproducible Verification Method: Turning Attribution Into an Experiment

    To move this kind of issue from a war of words to an engineering conclusion, design a controlled experiment as follows.

    Step one: fix the model weights and sampling parameters (keep temperature, max output length, and random seed strategy consistent), and change only the outer scaffold.

    Step two: fix the task set. Pick real repository maintenance tasks—bug fixes, locating errors from logs, fixing builds after dependency upgrades—where each task has an automatically judgeable acceptance criterion (unit tests pass, static checks pass, build artifacts are usable).

    Step three: run a tool-space ablation. Use an illustrative configuration to express the differences among the three shapes:

    1. # Standard shape (excerpt)
    2. system_prompt: "<long role and format constraints>"
    3. tools: [read_file, write_file, edit_file, run_cmd,
    4. search_code, fetch_url, list_dir, plan, ask_user, ...]
    5. # Minimalist shape
    6. system_prompt: "You are a helpful software engineer assistant."
    7. tools: [run_cmd, edit_file]

    Step four: repeat multiple times and take the mean and variance. Looking at a single run is easily misled by randomness; run each configuration at least three times and report the mean, variance, and distribution of failure modes.

    Step five: record process metrics, not just the result score: number of tool calls, share of ineffective calls, context length growth curve, and the point at which the first effective edit appears. These metrics point directly to where the gain comes from.

    5. Engineering Practices That Follow

    • Evaluation must align the scaffold first. When comparing across models or versions, conclusions are basically invalid if the outer context structure is not locked down.
    • More tools is not better. Increasing the number of tools significantly raises the decision burden, especially for agents that have gone through reinforcement learning. Trimming the tool set by task domain is often more cost-effective than switching models.
    • Subtract from the system prompt. Long style and format constraints crowd out effective context and also drift from the training distribution. Write constraints into acceptance scripts rather than into the prompt.
    • Use execution results as the judge. Let tests and static checks carry the judging responsibility while the model only handles probing and editing; this loop is closest to the shape seen during training.
    • Handle context management up front. How the first-turn context is organized determines the quality of the dozens of steps that follow; rather than patching things afterward, design it well at the entry point.

    6. Using General Cloud Capabilities in Enterprise Deployment

    In a real production environment, to solidify the above methods into a pipeline, you can rely on a combination of general cloud capabilities: use a container platform to host reproducible evaluation environments, use object storage to save task sets and run artifacts, use a message queue to smooth peaks and chain asynchronous tasks, and use logging services and monitoring alerts to observe the call chain and failure rate. The capabilities Baidu AI Cloud offers in these general categories can serve as the foundation for building an evaluation and governance system, helping teams turn “mode differences” into continuously observable metrics rather than one-off excitement.

    7. Summary

    The truth behind the score jump is not mysterious: the model formed a strong coupling with the minimalist scaffold during post-training, and switching environments drops the score—it is essentially distribution shift, not capability improvement. The takeaway for developers is direct—control the variables first, then attribute; trim tools and prompts first, then discuss switching models. Treating evaluation as an experiment and context as product design is where the real gap opens up in the agent era.