paper-with-me

홈 › Papers

Code-Craft: Hierarchical Graph-Based Code Summarization for Enhanced Context Retrieval

2025-04-11 · David Sounthiraraj, Jared Hancock, Yassin Kortam, Ashok Javvaji, Prabhat Singh, Shaila Shankar

Understanding and navigating large-scale codebases remains a significant challenge in software engineering. Existing methods often treat code as flat text or focus primarily on local structural relationships, limiting their ability to provide holistic, context-aware information retrieval. We present Hierarchical Code Graph Summarization (HCGS), a novel approach that constructs a multi-layered representation of a codebase by generating structured summaries in a bottom-up fashion from a code graph. HCGS leverages the Language Server Protocol for language-agnostic code analysis and employs a parallel level-based algorithm for efficient summary generation. Through extensive evaluation on five diverse codebases totaling 7,531 functions, HCGS demonstrates significant improvements in code retrieval accuracy, achieving up to 82 percentage relative improvement in top-1 retrieval precision for large codebases like libsignal (27.15 percentage points), and perfect Pass@3 scores for smaller repositories. The system's hierarchical approach consistently outperforms traditional code-only retrieval across all metrics, with particularly substantial gains in larger, more complex codebases where understanding function relationships is crucial.

📄 PDF Abstract BibTeX arXiv:2504.08975

Code (0)

등록된 구현이 없습니다.

Tasks

Code SummarizationInformation RetrievalRetrieval

Methods 이 논문이 사용한 방법론

Focus 설명 없음

Similar Papers 제목 키워드 기반

Modeling Hierarchical Syntax Structure with Triplet Position for Source Code Summarization

2021-11-16 · ACL ARR November 2021 11 · Anonymous

Automatic code summarization, which aims to describe the source code in natural language, has become an essential task in software maintenance. Our fellow researchers have attempted to achieve such a purpose through vari…

Code SummarizationGraph Neural NetworkPositionSource Code Summarization+1

Modeling Hierarchical Syntax Structure with Triplet Position for Source Code Summarization

2022-05-01 · ACL 2022 5 · Juncai Guo, Jin Liu, Yao Wan, Li Li 외

Automatic code summarization, which aims to describe the source code in natural language, has become an essential task in software maintenance. Our fellow researchers have attempted to achieve such a purpose through vari…

Code SummarizationGraph Neural NetworkPositionSource Code Summarization+1

Hierarchical Learning for Generation with Long Source Sequences

2021-04-15 · Tobias Rohde, Xiaoxia Wu, Yinhan Liu

One of the challenges for current sequence to sequence (seq2seq) models is processing long sequences, such as those in summarization and document level machine translation tasks. These tasks require the model to reason a…

DecoderDocument Level Machine TranslationDocument SummarizationDocument Translation+6

Hierarchical Attention Graph for Scientific Document Summarization in Global and Local Level

2024-05-16 · Chenlong Zhao, Xiwen Zhou, Xiaopeng Xie, Yong Zhang

Scientific document summarization has been a challenging task due to the long structure of the input text. The long input hinders the simultaneous effective modeling of both global high-order relations between sentences …

Document SummarizationExtractive SummarizationScientific Document SummarizationSentence

Commenting Higher-level Code Unit: Full Code, Reduced Code, or Hierarchical Code Summarization

2025-03-13 · Weisong Sun, Yiran Zhang, Jie Zhu, Zhihui Wang 외

Commenting code is a crucial activity in software development, as it aids in facilitating future maintenance and updates. To enhance the efficiency of writing comments and reduce developers' workload, researchers has pro…

Code Summarization