TL;DR
While AI code assistants excel at writing command-line scripts, they struggle with Graphical User Interfaces (GUIs) because they cannot "see" layout flaws or interact with event-driven elements. This paper introduces InteractGUI Bench, a benchmark of 984 desktop application tasks, and VF-Coder, a multi-agent system that uses visual feedback and real-time screen interaction to detect and repair GUI code bugs just like a human developer.
What Problem Does This Paper Address?
Large Language Models (LLMs) have become remarkably good at generating code, powering popular tools like Copilot and Cursor. However, generating and debugging GUI code remains a massive hurdle.
Traditional code agents rely entirely on textual feedback—such as compilation logs, error messages, or abstract syntax trees—to self-repair. But GUIs present two unique challenges that text cannot capture:
- Functional Logic Modeling: GUIs are event-driven. Code correctness depends on how the interface responds to dynamic user sequences (clicks, text inputs, focus changes).
- Visual Structural Alignment: A program might compile perfectly without errors, yet be completely unusable because elements overlap, text is misaligned, or colors violate design specifications.
Furthermore, existing benchmarks focus almost exclusively on static web pages, leaving the complex world of multi-page desktop applications largely unaddressed.
Methods
The authors propose VF-Coder, a vision-feedback-based multi-agent framework designed to bridge the gap between code generation and visual execution. It breaks down the debugging process into a closed loop of "visual perception, dynamic interaction, and code refactoring" using three specialized agents:
- Task Planner: Acts as the central controller. It analyzes the user's instructions and reference screenshots, decomposes the project into subtasks, coordinates the other agents, and maintains a high-level workflow memory.
- GUI Operator: The "eyes and hands" of the system. It launches the generated PySide6 desktop application inside an isolated sandbox environment. By observing real-time screenshots and terminal logs, it executes step-by-step interactions (like clicking buttons or typing text) to actively probe for runtime anomalies and visual glitches.
- Code Fixer: The "editor." When the GUI Operator flags a bug, the Code Fixer localizes the faulty code segments and applies precise, incremental patches using SEARCH/REPLACE blocks.
Datasets
To evaluate their approach, the authors introduced InteractGUI Bench, a high-quality benchmark consisting of 984 real-world desktop GUI application tasks curated from Flathub (a popular Linux app store).
To automate the evaluation of these interactive apps, they designed an Interactive Evaluation Script (IES) protocol that utilizes:
- AT-SPI (Assistive Technology Service Provider Interface): A Linux accessibility framework used to programmatically inspect the application's internal widget tree and simulate user interactions.
- A Custom Visual Evaluation Model: Because accessibility trees don't expose style attributes, the authors trained a dual-stream ResNet-50 model on 25,000 synthesized GUI pairs to score layout similarity and catch global rendering deviations like disproportionate scaling or overlapping text.
Key Insights and Ideas
- Visual feedback matters most during debugging, not just fixing: Ablation studies revealed that giving the agent visual capabilities during the interaction/error-detection phase yielded a significant performance jump. Conversely, providing screenshots to the code-patching agent provided only marginal gains, showing that "seeing" the bug is critical for understanding what went wrong, but text descriptions are often enough to fix it.
- Textual logs hide silent visual failures: Traditional text-based agents can successfully minimize "Fail-to-Start" errors by fixing syntax, but they remain completely blind to severe layout collapses.
- Desktop apps are uniquely challenging: Unlike web pages with flexible DOM structures, desktop GUI frameworks (like PySide6) enforce rigid layout hierarchies, making them an excellent stress test for LLM spatial reasoning.
Key Results
The authors evaluated several state-of-the-art models on InteractGUI Bench, revealing that desktop GUI generation is far from solved:
- Even the top-performing baseline model, GPT-5.2, only achieved a 26.99% task success rate, highlighting the benchmark's difficulty.
- When applied to Gemini-3-Flash, the VF-Coder framework boosted the task success rate from 21.68% to 28.29% (a 6.61% absolute improvement), significantly outperforming text-only command-line agents like Cursor CLI.
- VF-Coder raised the average visual similarity score from 0.4284 to 0.5584, proving its effectiveness at aligning generated layouts with original design drafts.
Limitations and Future Work
Despite the improvements, a large gap remains between AI-generated GUIs and real-world reference screenshots. The authors note that VF-Coder's performance is still heavily bounded by the inherent capability limits of the underlying MLLMs. Additionally, while visual feedback is highly effective at resolving layout and rendering flaws, it offers limited utility for fixing deep, complex functional logic errors that do not manifest visually on the screen. Future work will likely focus on tighter integration between visual perception and complex logical reasoning.
Summary updated