Evaluating Complex Frontend AI Agents: Speed, Stability, and Retry Costs
This article explores how the actual production efficiency of large language models in complex frontend agent tasks cannot be measured solely by first-round generation speed. It details a unified horizontal test where multiple general-purpose LLMs were tasked with building a creative studio collaboration system, analyzing their differences in delivery time, retry costs, and context management. By evaluating visual quality versus engineering stability, it introduces comprehensive evaluation metrics and practical development strategies to help assess and improve AI agent performance.
In complex frontend development tasks, a model’s first-round generation speed does not represent its actual production efficiency. One model might generate a page quickly but repeatedly fail during interaction validation, state persistence, or mobile adaptation. Another model might have a slower single response time but reduces tool calls and reworks, ultimately resulting in a shorter delivery time. This article focuses on a horizontal test conducted under unified conditions. Our goal was not to compare brand influence but to observe the practical performance of different general-purpose large models in complex agent tasks and to analyze the key variables affecting agent efficiency.
1. Test Objective: Evaluating Complete Delivery, Not Single Generation
We used the same agent execution framework. The tasks, materials, context window, browser environment, and acceptance rules remained unchanged; only the underlying model was replaced. The tested models are common large-scale general models, focusing on their abilities to:
- Understand complex product requirements;
- Break down requirements into pages, states, and interactions;
- Correctly invoke browsers and related tools;
- Continuously fix issues based on page feedback;
- Complete acceptance within a limited number of retries;
- Ensure quality across desktop, mobile, and data persistence.
The task was to build a creative studio collaboration system. This is not a simple static page but a comprehensive frontend application involving multiple roles, pages, states, and interactive relationships. Therefore, the final result could not be judged solely by “how much code was generated.” We also considered the total time consumed from first execution to passing acceptance, along with retries, rollbacks, manual interventions, and context consumption.
2. Unified Test Environment and Task Scope
To minimize environmental differences, the four test groups adopted identical conditions:
- Context window: ~262K
- Single task budget: ~200K
- Browser automation protocol: Unified browser control interface
- Desktop check dimensions: 1440×1000
- Mobile check dimensions: 390×844
- First-version screenshots retained for each group
- Only one round of centralized fixing allowed
- Final submission required: code, screenshots, execution logs, review records, and metric data.
Initial data included six openly licensed city art images, along with seed data for project members, assets, versions, and comments. The models could not reference an existing page; they had to design and implement the system based solely on text requirements, data structures, and acceptance criteria.
The system needed to cover five core states:
- Project Overview: Displaying project progress, members, delivery milestones, and current status;
- Inspiration Board: For viewing, organizing, and managing visual assets;
- Asset Comments: Supporting comments and positioning for specific assets;
- Version Approval: Supporting version switching, approval, and rejection;
- Release Preview: Simulating the display page before final delivery.
Additionally, the system involved three roles: Creative Lead, Designer, and Client, each with different operational permissions. For instance, designers could submit versions, creative leads could approve them, and clients could view deliverables and provide feedback.
Interaction requirements were equally strict, including asset dragging, comment positioning, version switching, approval transitions, and state preservation upon refresh. The pages had to not only “look complete” but also possess basic state management and business loops.
3. Test Results: Significant Differences in Total Duration
All four models eventually completed the task, but their execution processes varied greatly.
- Group 1 completed all tasks in about 17 minutes. The overall process was the most compact, with fewer tool calls and relatively restrained page structure. It did not overly pursue complex visual effects but prioritized the availability of core processes.
- Group 2 failed the first execution and completed it after a rerun, taking a cumulative 1 hour and 12 minutes. Its final page had a good brand feel and visual unity, but the first execution showed obvious deviations in interaction details and state handling.
- Group 3 did not completely rerun the task but triggered three internal automatic retries during execution, ultimately taking about 88 minutes. The generated system had the highest information density and fairly complete functional coverage, but the complex structure increased the cost of state synchronization and browser verification.
- Group 4 failed twice consecutively under the default retry strategy and succeeded only after adjusting the backoff strategy, taking a cumulative 1 hour and 4 minutes. Its page style was relatively mature, but execution stability was affected by tool call failures and inefficient context recovery.
The gap between the fastest and slowest models was more than several times. More notably, the difference did not entirely stem from code generation speed, but mainly from the following factors:
- Whether it could understand the task structure at once;
- Whether it could promptly detect errors;
- Whether it repeatedly invoked the same failing tool;
- Whether it could control page complexity;
- Whether it could maintain goal consistency after context growth;
- Whether it had a reasonable retry and backoff mechanism.
4. Page Quality Comparison: Visual Style Does Not Equal Engineering Completeness
1. Lightweight Editorial Style
The fastest solution adopted a light visual theme with a relatively simple page structure. Project status, assets, members, and version relationships were clearly laid out, allowing users to quickly understand project progress. Its advantage lies in stable information hierarchy and short navigation paths, preventing users from getting lost. For tasks requiring quick delivery, this design reduces the model’s consumption on visual details, allocating more resources to state logic and acceptance. The downside is that the visual presentation is relatively conservative, with limited display depth for complex scenarios.
2. Dark High-End Editorial Style
Group 2’s solution used a dark background, gold accents, and an off-white content area, reinforcing the visual impression of a cultural institution through serif titles, permission matrices, and approval statuses. This solution had strong brand expression and unified mobile adaptation. Different pages maintained good rules for fonts, colors, and spacing, indicating that the model could maintain a design system over a long context. However, the first execution failure showed that visual consistency does not equate to engineering stability. The more a page emphasizes visual expression, the more it needs to constrain component counts, state counts, and interaction paths during the design phase. Otherwise, it is prone to situations where “the screenshot looks good, but the operational path is incomplete.”
3. Dark Professional Workbench Style
Group 3’s solution adopted a dark professional workbench design, integrating navigation, project progress, roles, delivery, approval, and asset canvas into a complete system. It had the highest information density and most comprehensive functional coverage, making it suitable for users needing to centrally process a large amount of project material. However, high information density also brought higher verification costs. The more page elements there are, the more state combinations the model needs to handle. For example, whether comments update synchronously after version switching; whether the preview page reflects the latest results after approval status changes; whether dragging and buttons remain available after mobile layout compression. These issues significantly increase the number of browser operation rounds.
4. Art Gallery Archive Style
Group 4’s solution featured black serif titles, an off-white background, thin-line tables, and artwork thumbnails, resembling an archive management system overall. The advantage of this solution is its clear visual identity and stable data display, making the relationship between assets and versions easy to understand. It emphasizes artwork materials and historical records rather than high-density operations. However, archival design usually requires more page switching and state confirmation. If the model does not design a unified data state layer in advance, display synchronization issues may occur across multiple pages, triggering multiple rounds of retries.
5. Why “Fastest Completion” Does Not Mean “Strongest Capability”
Judging solely by the final screenshots makes it difficult to explain the actual differences among the four models. Complex agent tasks are closer to small software projects, where efficiency is determined by at least five dimensions.
1. Task Decomposition Capability
The model needs to first break down requirements into pages, components, data structures, permissions, and acceptance paths. If a reasonable task graph is not formed initially, it is easy to write and modify simultaneously later, leading to duplicated work. A better execution approach should first clarify:
Requirements├─ Page Structure├─ Core Data Model├─ Role Permissions├─ State Transitions├─ Browser Acceptance Path└─ Mobile Adaptation Strategy
Establishing the structure first and then implementing details is usually more stable than directly generating a large amount of page code.
2. Tool Call Efficiency
Every time an agent invokes a browser, reads a page, takes a screenshot, or executes a script, it consumes time and context. If the model cannot extract sufficient information from a single feedback, it will fall into an “operate-fail-repeat” loop. Therefore, tool calls should be batched as much as possible. For instance, checking page load, core buttons, console errors, and key dimensions in one go, rather than executing multiple similar operations separately.
3. Retry Strategy
Retries are not always bad, but ineffective retries rapidly amplify costs. An ideal retry mechanism needs to distinguish between:
- Temporary environment unavailability;
- Page logic errors;
- Selector positioning failures;
- Data state anomalies;
- Context deviation from the goal.
Different errors should be handled differently. Environment issues can be retried after a delay; logic issues should prompt code modifications first; context deviation requires summarizing the current state again rather than continuously appending instructions.
4. Context Management
The more complex the task and the longer the execution time, the more historical operations accumulate. If the model retains all details, context bloat may occur; if compressed too much, critical constraints may be lost. A better approach is to periodically generate stage summaries, including:
- Pages currently completed;
- Interactions already verified;
- Unresolved issues;
- Current data state;
- The single next-step goal;
- Functions that must not be broken.
This is equivalent to establishing a continuously updatable project status table for the agent.
5. Design Trade-off Capability
Complex pages should not infinitely increase visual elements. Every component brings new state, layout, and acceptance costs. Models capable of proactively controlling scope and prioritizing core processes are often better suited for time-constrained production tasks.
6. Recommended Comprehensive Evaluation Metrics
When evaluating code agents, enterprises are advised not to record only the first-screen generation time. The following metrics can be used:
Completion Duration
The total time from task start to passing all acceptance criteria, including waiting, failures, retries, and manual recovery.
Effective Operation Ratio
The number of effective tool calls divided by total tool calls. A higher ratio indicates fewer meaningless explorations by the model.
First-Pass Rate
The proportion of core processes completed during the first execution. This reflects the model’s planning ability better than the final success rate.
Fixing Cost
The code modifications, reruns, and context length required to pass acceptance after completing the first version.
Functional Coverage
Separately accepting functions like pages, roles, approvals, dragging, versions, and refresh persistence to avoid judging results based solely on visual screenshots.
Cross-Platform Consistency
Simultaneously checking desktop and mobile, focusing on layout, button visibility, text overflow, touch areas, and state synchronization.
Stability Cost
Recording the extra time spent due to tool failures, service backoff, repeated calls, and environment recovery.
7. Implications for Actual Development Processes
First, complex tasks should define the acceptance path before coding begins. The clearer the acceptance path, the easier it is for the model to form a closed loop.
Second, page state should be centrally managed. Projects, members, assets, versions, comments, and approval results should ideally share a unified data structure, avoiding separate copies maintained by individual pages.
Third, the first version should prioritize the business loop. Visual details can be optimized during the centralized fixing phase, but permissions, state transitions, and refresh preservation cannot be delayed.
Fourth, automatic retries must have boundaries. During consecutive failures, execution should be paused to re-analyze the cause rather than infinitely repeating the same operation.
Fifth, test records should be fully preserved. Code, screenshots, logs, review results, and metric data together constitute a reproducible evidence chain; a single final screenshot is insufficient to prove system quality.
Conclusion
This horizontal test demonstrates that the true efficiency of complex frontend agents cannot be explained solely by a model’s response speed or parameter scale. Whether a model is suitable for production environments depends on its ability to stably complete task decomposition, code generation, tool operation, error recovery, state management, and cross-platform acceptance.
Under unified conditions, the fastest solution may not have the richest visual effects, and the most information-dense solution may not have the highest delivery efficiency. What truly matters is how much effective work is completed per unit of time and whether it can recover quickly after a failure. Therefore, subsequent evaluations of agents should shift from “who generates faster” to “who completes full delivery with fewer action rounds, lower retry costs, and more stable state management.” This is the measurement standard closer to actual production in complex software development scenarios.
