Reproduce “LLM-Assisted Repository-Level Generation with Structured Spec-Driven Engineering” on OpenResearch

Turn your favorite coding agents into research agents that review literature, develop hypotheses, and run experiments.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

Shuzhao Feng, Boqi Chen, Brett H Meyer, Gunter Mussbacher

Structured spec-driven engineering (SSDE) gives an LLM structured behavior examples and model-layer descriptions to generate controller code. In a pilot generating Python MVC controllers for three systems, signatures versus domain models raised average test-pass rate by 7.82% and lowered standard deviation by 2.47%, across five LLMs, two modeling tools, and repeated runs. This result is limited to the pilot’s test setup, not repository-wide reliability.

Key insights

  • The inclusion of any structured specification consistently and significantly improves the quality of LLM-generated code for repository-level tasks compared to using natural language specifications alone.
  • Providing explicit API definitions (Signature Models) of the model layer enhances LLM performance more effectively than abstract domain models, suggesting better processing of concrete function signatures.
  • Over 70% of the identified errors in LLM-generated code, such as invoking non-existent APIs or data type mismatches, are detectable by static code analysis, indicating potential for automated feedback loops.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.