Research map / Architectures and efficiency / Attention and transformers
Towards Context-Aware Code Comment Generation
Xiaohan Yu, Quzhe Huang, Zheng Wang, Yansong Feng, Dongyan Zhao
Peking University · University of Leeds
Read the paperPlace an idea next to itCheck your own paper ↗
12measured effects
10improved
1no clear effect
1hurt
AI-extracted. The measured effects below were read by AI from the paper's full text (no summary yet). Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.
Measured effects reported in the paper
| What was changed | Where | Measured | Effect |
|---|---|---|---|
| add local encoder (ablation) | full model · Java method comments | BLEU: 15.15 -> 23.78 | Improved |
| add global encoder (C-Graph + GAT) (ablation) | full model · Java method comments | BLEU: 19.30 -> 23.78 | Improved |
| add graph attention in decoder (ablation) | full model · Java method comments | BLEU: 20.47 -> 23.78 | Improved |
| add local attention and pointer (ablation) | full model · Java method comments | BLEU: 20.09 -> 23.78 | Improved |
| add pointer mechanism (ablation) | full model · Java method comments | BLEU: 23.46 -> 23.78 | Improved |
| use C-Graph instead of attention over class functions or flattened class | GraphAttn / GraphFlatten · Java method comments | BLEU: 19.38 / 20.24 -> 23.78 | Improved |
| restrict C-Graph to function-call neighbors vs random same-class functions (ablation) | Call vs Random · Java method comments | BLEU: 19.13 -> 21.06 | Improved |
| use functions from other classes as C-Graph neighbors (ablation) | Seq2Seq-level baseline · Java method comments | BLEU: 18.74 -> 18.86 | No clear effect |
| use full C-Graph model instead of Code2Seq (AST-based) | Code2Seq · Java method comments | BLEU: 22.07 -> 23.78 | Improved |
| use full C-Graph model instead of Code2Seq on BLEU-4 | Code2Seq · Java method comments | BLEU-4: 15.77 -> 14.98 | Hurt |
| add C-Graph to Seq2Seq | Seq2Seq · Java method comments | Pc (comment words found only in neighbor functions): 19.1% -> 25.1% | Improved |
| add C-Graph to Seq2Seq | Seq2Seq · Java method comments | Po (words in both target and neighbors): 51.6% -> 53.1% | Improved |
Closest papers by meaning
- Automatic Generation of Text Descriptive Comments for Code Blocks (AAAI 2018 · similarity 0.87)
- Associating Natural Language Comment and Source Code Entities (AAAI 2020 · similarity 0.87)
- Deep Just-In-Time Inconsistency Detection Between Comments and Source Code (AAAI 2021 · similarity 0.86)
- ConvCodeWorld: Benchmarking Conversational Code Generation in Reproducible Feedback Environments (ICLR 2025 · similarity 0.84)
- AST-T5: Structure-Aware Pretraining for Code Generation and Understanding (ICML 2024 · similarity 0.83)
- CoRNStack: High-Quality Contrastive Data for Better Code Retrieval and Reranking (ICLR 2025 · similarity 0.83)
Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.
