Should SLMs be in the Driver's Seat? A Study of Local Models as Interpreters in Cloud-Written Agent Programs
Organizations: King Abdullah University of Science and Technology · University of Ljubljana, Faculty of Computer and Information Science
Abstract
The most accurate agents executing user-provided tasks are driven by large, cloud-hosted models, which solve them by reading the private data of the user. Agents powered by models small enough to run on edge devices keep that data local, but yield far worse results. A third option is to have cloud models write a program that devices execute: the data stays local, but as the program is written before any data is seen, it fails whenever a step depends on interpreting content that appears only at run time. We explore an intermediate architecture, in which the cloud-written program defers bounded questions over user data to a small local model through an ordinary function call. On AppWorld this improves the success rate of a code-only agent in all six combinations of backbone model and test partition we evaluate, by up to 14.9pp, recovering a substantial part of the gap to a cloud-hosted ReAct loop while keeping user data on the device.
Figures & tables
| Agent | Interprets run-time data | Local LM cost | User data to cloud | Cloud tokens | Cloud-device round trips |
| Cloud ReAct | ✓ | none | every observation | high | one per step |
| Edge ReAct | ✓ | high | none | none | none |
| Full-Code (FC) | ✗ | none | request, traceback | moderate | |
| Ours | ✓ | low | request, traceback | moderate |
| SLM size | Qwen-coder | Qwen-122B | Qwen-27B |
| None (FC) | |||
| 0.8B | |||
| 2B | |||
| 9B |
Appendix figures & tables1 asset
Supplementary material from the paper’s appendix.
Appendix
| Model | Quantization | GPU |
| Qwen-27B (Qwen3.6-27B) | UD-Q8_K_XL | A100-80GB |
| Qwen-122B (Qwen3.5-122B-A10B) | UD-Q4_K_XL | A100-80GB |
| Qwen-coder (Qwen3-Coder-Next) | Q6_K | A100-80GB |
| Qwen3.5-0.8B/2B/4B/9B | UD-Q8_K_XL | V100 |
| Gemma-4 E2B–31B | UD-Q8_K_XL | A100-80GB |
LLM Agent Reliability
Large language model (LLM) agent reliability concerns dependable, safe, and verifiable behavior across tools, multi-step tasks, and changing environments.
See all 843 papers