DependEval: Benchmarking LLMs for Repository Dependency Understanding

Junjia Du, Yadi Liu, Hongcheng Guo, Jiawei Wang, Haojian Huang, Yunyi Ni, Zhoujun Li

TL;DR

DependEval is a new hierarchical, multilingual benchmark designed to evaluate how well Large Language Models (LLMs) comprehend repository-level code dependencies. By testing over 25 major LLMs across eight programming languages, the study reveals that while models are decent at mapping simple file relationships, they severely struggle with complex, coordinated multi-file editing and directory structure design.

What Problem Does This Paper Address?

While LLMs excel at generating isolated functions or single-file code snippets (as measured by traditional benchmarks like HumanEval or MBPP), real-world software engineering happens at the repository scale. Developing software requires an intricate understanding of how files interact, how project architectures are structured, and how a change in one module ripples across multiple dependencies.

Existing repository-level benchmarks either focus narrowly on end-to-end bug fixing (like SWE-bench) or lack fine-grained, isolated metrics to evaluate why a model fails. To bridge this gap, the authors introduce DependEval, a benchmark specifically built to assess an LLM's structural and architectural reasoning across complex codebases.

Methods

DependEval evaluates LLMs using a hierarchical framework consisting of three progressively challenging tasks:

  1. Dependency Recognition (DR): Tests the model's ability to infer the correct invocation order of a set of interdependent code files.
  2. Repository Construction (RC): Evaluates whether a model can generate a coherent, modular project layout and dependency graph given natural language requirements and functional file descriptions.
  3. Multi-file Editing (ME): Challenges the model to implement new features across multiple files simultaneously. This includes both In-place Edits (modifying existing files) and Expansion Edits (creating new files and updating existing ones to call them) while maintaining strict cross-file consistency.
Figure 1: Overview of DEPENDEVAL. It contains 3 tasks including Repository Construction, Dependency Recognition, and Multi-file Editing. The first task analyzes the project description to generate a structure showing the dependencies between files. The second task identifies the content of the files to determine the relationships between them. Finally, the third task modifies the code to add functionality for saving displayed images to disk.

To ensure rigorous evaluation, the authors use distinct metrics for each task: Exact Match Rate (EMR) for Dependency Recognition; a custom Graph Match F1-Score (combining node and edge accuracy) for Repository Construction; and a multi-aspect LLM-as-a-judge framework (evaluating Correctness, Purpose Alignment, Functionality Accuracy, Completeness, and Code Quality) for Multi-file Editing.

Datasets

The benchmark was constructed using a rigorous data curation pipeline:

  • Source: 15,576 high-quality, real-world public GitHub repositories created before December 16, 2024, filtered for popularity (over 50 stars) and activity.
  • Languages: Eight major programming languages: C, C++, C#, TypeScript, JavaScript, Java, PHP, and Python.
  • Final Benchmark Size: 2,683 meticulously curated test cases containing invocation chains of varying lengths (2, 3, and 4 files).
  • Human-in-the-Loop: A team of human annotators manually reviewed, corrected, and verified the LLM-generated requirements and code modifications to establish reliable gold-standard labels.
Figure 2: Pipeline for data curation of DEPENDEVAL. It consists of four steps: data crawling and filtering (Step 1), dependency snippet generation (Step 2), test sample generation for dependency recognition (Step 3), and evaluation using metrics like Exact Match and Graph Match F1 Score (Step 4).

Key Insights and Ideas

  • Domain Specific Tuning Beats Raw Scale: One of the most notable findings is that code-specific models like Qwen2.5-Coder-32B frequently outperform much larger general-purpose models (such as Llama-3.3-70B-Instruct and Qwen-2.5-72B-Instruct). This demonstrates that targeted pre-training on high-quality code repositories is more effective than simply scaling parameter size.
  • The Static vs. Dynamic Language Divide: LLMs perform significantly better at dependency recognition and repository construction in languages with explicit, clean import structures like Python, JavaScript, and TypeScript. Conversely, they struggle with languages like PHP (due to flexible file inclusions) and C# (due to complex project configurations).
  • Multi-File Editing is the Ultimate Bottleneck: While many models achieve decent scores in recognizing dependencies, their performance plummets when forced to execute coordinated edits across multiple files. Maintaining global state and pointer tracking (especially in C/C++) remains a massive hurdle for current architectures.
  • Directory Structure Blind Spot: LLMs consistently score lower on Repository Construction than on Dependency Recognition, indicating they lack the inherent prior knowledge required to organize hierarchical project directories logically.

Key Results

The authors evaluated more than 25 open-source and closed-source LLMs.

Figure 4: Results of different tasks in DEPENDEVAL. The radar charts show the performance of various models across Dependency Recognition(a), Repository Construction(b), and Multi-file Editing(c) tasks. Each line represents a different model, with performance measured for different programming languages.
  • Top Performers: DeepSeek-V3 and Claude-3.5-Sonnet emerged as the clear leaders.
  • Task Specialization: DeepSeek-V3 dominated the simpler Dependency Recognition tasks, showcasing incredible static analysis capabilities. However, Claude-3.5-Sonnet proved superior in architectural reasoning, leading the pack in Repository Construction and Multi-file Editing.
  • Open vs. Closed Source: While top-tier open-source models (like DeepSeek-V3 and Qwen2.5-Coder) are highly competitive in structural tasks, closed-source commercial APIs still maintain a slight edge in complex multi-file reasoning and generalization.

Limitations and Future Work

The authors openly acknowledge a few limitations in DependEval's current iteration:

  1. Language Scope: While 8 languages cover a massive footprint, emerging languages (like Rust or Go) are not yet included.
  2. Task Scope: The benchmark focuses heavily on structural dependencies but does not yet evaluate other crucial repository-level tasks like multi-file debugging, code refactoring, or performance optimization.
  3. Evolving Model Pool: As the LLM landscape shifts rapidly, keeping the benchmark updated with the latest frontier models will be an ongoing requirement.

The authors have open-sourced their dataset and curation scripts on GitHub to allow the community to expand the benchmark to new languages and tasks.

Summary updated

BibTeX
@inproceedings{du2025dependeval,
  author = {Junjia Du and Yadi Liu and Hongcheng Guo and Jiawei Wang and Haojian Huang and Yunyi Ni and Zhoujun Li},
  title = {{DependEval: Benchmarking LLMs for Repository Dependency Understanding}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2025},
}
Figure