TasksSotADatasetsPapersMethodsSubmitAbout
Papers With Code 2

A community resource for machine learning research: papers, code, benchmarks, and state-of-the-art results.

Explore

Notable BenchmarksAll SotADatasetsPapersMethods

Community

Submit ResultsAbout

Data sourced from the PWC Archive (CC-BY-SA 4.0). Built by the community, for the community.

Papers/Retrieval Augmented Code Generation and Summarization

Retrieval Augmented Code Generation and Summarization

Md Rizwan Parvez, Wasi Uddin Ahmad, Saikat Chakraborty, Baishakhi Ray, Kai-Wei Chang

2021-08-26Findings (EMNLP) 2021 11Code SummarizationCode GenerationRetrieval
PaperPDFCodeCode(official)

Abstract

Software developers write a lot of source code and documentation during software development. Intrinsically, developers often recall parts of source code or code summaries that they had written in the past while implementing software or documenting them. To mimic developers' code or summary generation behavior, we propose a retrieval augmented framework, REDCODER, that retrieves relevant code or summaries from a retrieval database and provides them as a supplement to code generation or summarization models. REDCODER has a couple of uniqueness. First, it extends the state-of-the-art dense retrieval technique to search for relevant code or summaries. Second, it can work with retrieval databases that include unimodal (only code or natural language description) or bimodal instances (code-description pairs). We conduct experiments and extensive analysis on two benchmark datasets of code generation and summarization in Java and Python, and the promising results endorse the effectiveness of our proposed retrieval augmented framework.

Results

TaskDatasetMetricValueModel
Code GenerationCodeXGLUE - CodeSearchNetJava/BLEU28.98Redcoder-ext
Code GenerationCodeXGLUE - CodeSearchNetJava/CodeBLEU33.18Redcoder-ext
Code GenerationCodeXGLUE - CodeSearchNetJava/EM10.21Redcoder-ext
Code GenerationCodeXGLUE - CodeSearchNetPython/BLEU24.43Redcoder-ext
Code GenerationCodeXGLUE - CodeSearchNetPython/CodeBLEU30.21Redcoder-ext
Code GenerationCodeXGLUE - CodeSearchNetPython/EM9.61Redcoder-ext
Code GenerationCONCODEBLEU42.5Redcoder-ext
Code GenerationCONCODECodeBLEU43.4Redcoder-ext
Code GenerationCONCODEExact Match23.4Redcoder-ext

Related Papers

CUDA-L1: Improving CUDA Optimization via Contrastive Reinforcement Learning2025-07-18Towards Formal Verification of LLM-Generated Code from Natural Language Prompts2025-07-17From Roots to Rewards: Dynamic Tree Reasoning with RL2025-07-17HapticCap: A Multimodal Dataset and Task for Understanding User Experience of Vibration Haptic Signals2025-07-17A Survey of Context Engineering for Large Language Models2025-07-17MCoT-RE: Multi-Faceted Chain-of-Thought and Re-Ranking for Training-Free Zero-Shot Composed Image Retrieval2025-07-17MERA Code: A Unified Framework for Evaluating Code Generation Across Tasks2025-07-16Scaling Up RL: Unlocking Diverse Reasoning in LLMs via Prolonged Training2025-07-16