Three Roles, One Model: Role Orchestration at Inference Time to Close the Performance Gap Between Small and Large Agents
Organizations: Aimpoint Digital Labs, Atlanta, GA, USA · New York University, New York, NY, USA
Abstract
Large language model (LLM) agents show promise on realistic tool-use tasks, but deploying capable agents on modest hardware remains challenging. We study whether inference-time scaffolding alone, without any additional training compute, can improve the performance of a small model in complex multi-step environments. Operating on a single 24GB GPU, we evaluate Qwen3-8B on the AppWorld benchmark under both full-precision and 4-bit quantized configurations. Without any intervention, the raw model achieves just 5.4% (FP16) and 3.0% (AWQ) task goal completion. Guided by a systematic failure mode analysis, we introduce a three-tier inference scaffolding pipeline that deploys the same frozen model in three distinct roles: (1) a summarization model that preserves critical artifacts (tokens, credentials, API responses) while compressing dialogue history; (2) the main agent model that reasons over the compressed context; and (3) an isolated correction model that reviews and revises the agent's code output without access to conversation history, breaking repetitive failure loops. Applied to the same unmodified model, this scaffolding yields 8.9% (FP16) and 5.9% (AWQ) task goal completion, roughly doubling performance in both settings, with particularly strong gains on difficulty-1 tasks (15.8% to 26.3% FP16; 5.3% to 14.0% AWQ). On full-precision inference, our scaffolded 8B model surpasses DeepSeek-Coder 33B Instruct (7.1%) from the original AppWorld evaluation, demonstrating that structured inference-time interventions can make small models competitive with systems 4 times their size. We formalize the approach as a scaffolded policy over a frozen base model, three invocations of the same weights with different conditioning, drawing connections to test-time compute scaling and action-space shaping in reinforcement learning.
Figures & tables
| Failure Category | Count | Conf.-Weighted |
|---|---|---|
| Authentication / credential issue | 46 | 39.45 |
| Reasoning / planning error | 43 | 35.30 |
| Wrong API params / schema mismatch | 29 | 25.05 |
| Other | 24 | 20.05 |
| Missing API call / wrong API name | 13 | 11.45 |
| Repetition / loop | 3 | 2.55 |
| Difficulty | Failure Category | Count |
|---|---|---|
| 1 | Auth / credentials | 13 |
| Reasoning / planning | 11 | |
| Other | 11 | |
| 2 | Reasoning / planning | 13 |
| API params / schema | 12 | |
| Auth / credentials | 11 |
| FP16 (12K ctx) | AWQ (32K ctx) | |||
|---|---|---|---|---|
| Difficulty | Baseline | Scaffold | Baseline | Scaffold |
| Aggregate | 5.4 [2.8, 9.9] | 8.9 [5.5, 14.2] | 3.0 [1.3, 6.8] | 5.9 [3.3, 10.6] |
| Difficulty 1 | 15.8 | 26.3 | 5.3 | 14.0 |
| Difficulty 2 | 0.0 | 0.0 | 2.1 | 4.2 |
| Difficulty 3 | 0.0 | 0.0 | 1.6 | 0.0 |
| Model | Parameters | task goal completion (%) | 95% CI |
|---|---|---|---|
| GPT-4o | — | 48.8 | — |
| Claude 3.5 Sonnet | — | 33.2 | — |
| LLaMA-3-70B-Instruct | 70B | 20.8 | — |
| Qwen3-8B + Scaffold (FP16) | 8B | 8.9 | [5.5, 14.2] |
| DeepSeek-Coder 33B Instruct | 33B | 7.1 | [4.1, 12.0] |
| Qwen3-8B Baseline (FP16) | 8B | 5.4 | [2.8, 9.9] |
| Difficulty | Baseline | Correction Only | Full Scaffold |
|---|---|---|---|
| Aggregate | 3.0 | 4.8 | 5.9 |
| Difficulty 1 | 5.3 | 12.3 | 14.0 |
| Difficulty 2 | 2.1 | 2.1 | 4.2 |
| Difficulty 3 | 1.6 | 0.0 | 0.0 |
| Baseline (AWQ) | Scaffolded (AWQ) | |||
|---|---|---|---|---|
| Failure Category | Count | % | Count | % |
| Auth / credentials | 46 | 28.2 | 43 | 27.2 |
| Reasoning / planning | 43 | 26.4 | 54 | 34.2 |
| API params / schema | 29 | 17.8 | 15 | 9.5 |
| Other | 24 | 14.7 | 19 | 12.0 |
| Missing API / wrong name | 13 | 8.0 | 17 | 10.8 |
| Difficulty | Failure Category | Count |
|---|---|---|
| 1 | Reasoning / planning | 18 |
| Auth / credentials | 8 | |
| API params / schema | 8 | |
| 2 | Auth / credentials | 15 |
| Reasoning / planning | 14 | |
| Missing API / wrong name | 8 |
Tool-Using Language Agents
Tool-using language agents combine language models with APIs, code, and other tools to answer questions and carry out multi-step tasks.
See all 59 papers