[Paper Review] Themisto: Towards Automated Documentation Generation in Computational Notebooks.
Themisto is an automated documentation system for computational notebooks that combines deep learning, query-based API retrieval, and user prompting to reduce documentation time, improve completeness, and increase user satisfaction. Evaluated with 24 practitioners, it significantly reduced effort and reminded users to document overlooked code.
Computational notebooks allow data scientists to express their ideas through a combination of code and documentation. However, data scientists often pay attention only to the code, and neglect creating or updating their documentation during quick iterations, which leads to challenges in sharing their notebooks with others and future selves. Inspired by human documentation practices from analyzing 80 highly-voted Kaggle notebooks, we design and implement Themisto, an automated documentation generation system to explore the Human-AI Collaboration opportunity in the code documentation scenario. Themisto facilitates the creation of different types of documentation via three approaches: a deep-learning-based approach to generate documentation for source code (fully automated), a query-based approach to retrieve the online API documentation for source code (fully automated), and a user prompt approach to motivate users to write more documentation (semi-automated). We evaluated Themisto in a within-subjects experiment with 24 data science practitioners, and found that automated documentation generation techniques reduced the time for writing documentation, reminded participants to document code they would have ignored, and improved participants' satisfaction with their computational notebook.
Motivation & Objective
- To address the challenge of inconsistent and incomplete documentation in computational notebooks despite their widespread use in data science.
- To explore human-AI collaboration in automating code documentation by analyzing 80 highly-voted Kaggle notebooks.
- To design and implement a system that supports multiple documentation generation approaches: fully automated deep learning, automated API retrieval, and semi-automated user prompting.
- To evaluate the impact of automated documentation on time efficiency, documentation completeness, and user satisfaction in real-world data science workflows.
Proposed method
- Themisto uses a deep-learning model to generate natural language documentation directly from source code, enabling fully automated documentation creation.
- It employs a query-based approach to retrieve relevant online API documentation for code snippets, automatically linking to external resources.
- A user prompt mechanism encourages data scientists to write their own documentation by highlighting gaps, supporting semi-automated authoring.
- The system integrates all three approaches into a single interface within computational notebooks, enabling seamless documentation generation.
- The design is informed by analysis of 80 highly-voted Kaggle notebooks to reflect real-world documentation practices.
- Evaluation was conducted via a within-subjects experiment with 24 data science practitioners to assess usability and impact.
Experimental results
Research questions
- RQ1How does automated documentation generation affect the time required to document code in computational notebooks?
- RQ2To what extent do automated techniques remind users to document code they would otherwise omit?
- RQ3How does user satisfaction with notebook documentation change when using automated tools?
- RQ4What is the comparative effectiveness of deep learning, query-based retrieval, and user prompting in improving documentation quality?
- RQ5How do data scientists perceive and interact with AI-assisted documentation in real-world notebook workflows?
Key findings
- Automated documentation generation significantly reduced the time required for writing documentation compared to manual authoring.
- The system reminded participants to document code they would have otherwise neglected, improving completeness.
- Participants reported higher satisfaction with their notebooks when using Themisto, particularly due to reduced cognitive load.
- The deep-learning and query-based approaches were effective in generating relevant documentation without requiring user input.
- The user prompt approach successfully encouraged participants to write additional documentation, especially for complex or non-obvious code.
- Overall, Themisto demonstrated strong potential for improving documentation quality and workflow efficiency in data science.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.