WebDesignIter: Co-Evolving Design Knowledge for Repository-Level Front-End Code Generation
Summary
WebDesignIter is a novel framework designed for repository-level front-end code generation, addressing the limitations of current LLM coding agents in handling complex, evolving codebases with cross-file dependencies. It introduces a persistent knowledge graph, WebAppArchKG, which synchronizes repository structure with design knowledge, including architectural principles and module responsibilities. The framework operates in two stages: design-informed planning, which generates an implementation plan and test scripts from historical context and architectural overviews, and design-aware generation, which executes this plan via targeted diff-based patches, validated by sandbox execution and automatic syntax repair. On Web-Bench, WebDesignIter achieved an average Pass@2 gain of 9.55 percentage points across nine foundation models, outperforming general-purpose agents like Claude Code and SWE-Agent while consuming 25–30× fewer input tokens. Ablation studies confirmed design knowledge as the most impactful component, with its removal causing an 11.40 percentage point drop in Pass@1.
Key takeaway
For AI Engineers developing LLM-based coding agents for complex front-end repositories, you should integrate explicit design knowledge and architectural context. This approach, exemplified by WebDesignIter's WebAppArchKG, significantly improves code generation quality and maintainability while drastically reducing token consumption. Consider implementing persistent knowledge graphs and diff-based patching to manage cross-file dependencies and prevent regressions in evolving systems.
Key insights
Integrating persistent design knowledge via a knowledge graph significantly enhances LLM performance for repository-level front-end code generation.
Principles
- Design knowledge is critical for maintainable code.
- Persistent knowledge graphs improve LLM context.
- Incremental diff patches prevent regressions.
Method
WebDesignIter uses WebAppArchKG for design-informed planning and design-aware generation via diff-based patches, validated in a sandbox, with rule-based refactoring and syntax repair.
In practice
- Implement a knowledge graph for architectural context.
- Use diff-based patches for incremental updates.
- Integrate sandbox validation for code changes.
Topics
- Front-End Code Generation
- Large Language Models
- Knowledge Graphs
- WebAppArchKG
- Design Knowledge
- Repository-Level Development
- Web-Bench
Best for: Research Scientist, AI Scientist, Machine Learning Engineer, AI Engineer
Related on AIssential
See Counsel's argued verdicts on the open AI decisions leaders are weighing →
Editorial summary, takeaway, and curation by AIssential. Original article published by cs.SE updates on arXiv.org.