The proliferation of Large Language Models (LLMs) has catalyzed the development of autonomous web agents capable of navigating complex user interfaces. However, the prevailing paradigm—Continuous-Loop Action generation (e. g. , Think-Act-Observe) —suffers from severe inference latency, context window degradation, and prohibitive token costs at scale. In this paper, we identify the "Rerun Crisis" facing modern agentic automation and propose a highly optimized "Compile-and-Execute" implementation that fundamentally decouples LLM reasoning from physical browser execution. We introduce a DOM Sanitization Module (DSM) that compresses web page topology into a token-efficient semantic skeleton. A single LLM inference call acts as an autonomous planner, compiling this skeleton and user intent into a deterministic JSON workflow blueprint. We present a cost-evaluation framework demonstrating that continuous agents scale in inference cost at O (M N) per rerun, whereas our One-Shot Compiler scales at O (1). Execution is subsequently offloaded to a local engine, eliminating continuous AI inference overhead. By integrating a Human-in-the-Loop (HITL) gate for Supervised Autonomy and predictable failure halting for dynamic UIs, this architecture provides a highly scalable, safe, and cost-bounded framework for the next generation of enterprise AI automation.
Jagadeesh Chundru (Fri,) studied this question.