Lune

EMNLP Findings2021

HAConvGNN: Hierarchical Attention Based Convolutional Graph Neural Network for Code Documentation Generation in Jupyter Notebooks

Xuye Liu, Dakuo Wang, April Yi Wang, Yufang Hou, Lingfei Wu

Abstract

Jupyter notebook allows data scientists to write machine learning code together with its documentation in cells. In this paper, we propose a new task of code documentation generation (CDG) for computational notebooks. In contrast to the previous CDG tasks which focus on generating documentation for single code snippets, in a computational notebook, one documentation in a markdown cell often corresponds to multiple code cells, and these code cells have an inherent structure. We proposed a new model (HAConvGNN) that uses a hierarchical attention mechanism to consider the relevant code cells and the relevant code tokens information when generating the documentation. Tested on a new corpus constructed from well-documented Kaggle notebooks, we show that our model outperforms other baseline models.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

5 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Slide4N: Creating Presentation Slides from Computational Notebooks with Human-AI Collaboration cites What's Wrong with Computational Notebooks? Pain Points, Needs, and Design Opportunities
  • Slide4N: Creating Presentation Slides from Computational Notebooks with Human-AI Collaboration cites Telling Stories from Computational Notebooks: AI-Assisted Presentation Slides Creation for Presenting Data Science Work
  • Slide4N: Creating Presentation Slides from Computational Notebooks with Human-AI Collaboration cites How do Data Science Workers Collaborate? Roles, Workflows, and Tools
  • Telling Stories from Computational Notebooks: AI-Assisted Presentation Slides Creation for Presenting Data Science Work cites What's Wrong with Computational Notebooks? Pain Points, Needs, and Design Opportunities
  • Telling Stories from Computational Notebooks: AI-Assisted Presentation Slides Creation for Presenting Data Science Work cites How do Data Science Workers Collaborate? Roles, Workflows, and Tools
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers5

  1. Telling Stories from Computational Notebooks: AI-Assisted Presentation Slides Creation for Presenting Data Science WorkChengbo Zheng, Dakuo Wang, April Yi Wang, Xiaojuan MaCHI 2022 · 53 citations
  2. Slide4N: Creating Presentation Slides from Computational Notebooks with Human-AI CollaborationFengjie Wang, Xuye Liu, Oujing Liu, Ali Neshati et al.CHI 2023 · 37 citations
  3. Developer-Intent Driven Code Comment GenerationFangwen Mu, Xiao Chen, Lin Shi, Song Wang et al.ICSE 2023 · 25 citations
  4. Python Code Generation by Asking Clarification QuestionsHaau-Sing Li, Mohsen Mesgar, André F. T. Martins, Iryna GurevychACL 2023 · 3 citations
  5. MACEDON : Supporting Programmers with Real-Time Multi-Dimensional Code Evaluation and OptimizationXuye Liu, Yuzhe You, Xinrong Qiu, Tengfei Ma et al.UIST 2025

Builds on4

  1. Unsupervised Translation of Programming LanguagesBaptiste Rozière, Marie-Anne Lachaux, Lowik Chanussot, Guillaume LampleNeurIPS 2020 · 606 citations
  2. How do Data Science Workers Collaborate? Roles, Workflows, and ToolsAmy X. Zhang, Michael J. Muller, Dakuo WangCSCW 2020 · 260 citations
  3. Reinforcement Learning Based Graph-to-Sequence Model for Natural Question GenerationYu Chen, Lingfei Wu, Mohammed J. ZakiICLR 2020 · 167 citations
  4. What's Wrong with Computational Notebooks? Pain Points, Needs, and Design OpportunitiesSouti Chattopadhyay, Ishita Prasad, Austin Z. Henley, Anita Sarma et al.CHI 2020 · 162 citations

Related papers

  1. Cell2Doc: ML Pipeline for Generating Documentation in Computational NotebooksTamal Mondal, Scott Barnett, Akash Lal, Jyothi VeduradaASE 2023 · 4 citations
  2. NB2P: Generating Data Science Pipelines from Computational NotebooksHaotian Gao, Quang Trung Ta, Tien Tuan Anh Dinh, Nhut-Minh Ho et al.ICSE 2026
  3. Eliciting Best Practices for Collaboration with Computational NotebooksLuigi Quaranta, Fabio Calefato, Filippo LanubileCSCW 2022 · 29 citations
  4. NBDESCRIB: A Dataset for Text Description Generation from Tables and Code in Jupyter Notebooks with GuidelinesXuye Liu, Tengfei Ma, Yimu Wang, Fengjie Wang et al.ACL Findings 2025
  5. Contextualized Data-Wrangling Code Generation in Computational NotebooksJunjie Huang, Daya Guo, Chenglong Wang, Jiazhen Gu et al.ASE 2024 · 5 citations
Dusk over the sea between two cliffs drawn in fine vertical lines