CoChat

Distilled GPT for source code summarization

Open access
Su, Chia-Yi, McMillan, Collin · 2024 · Automated Software Engineering

The DOI matches its Crossref record; 59 of the 59 references it cites were found in a registry or an index.

Abstract

A code summary is a brief natural language description of source code. Summaries are usually only a single sentence long, and yet form the backbone of developer documentation. A short descriptions such as “changes all visible polygons to the color blue” can give a programmer a high-level idea of what code does without the effort of reading the code itself. Recently, products based on Large Language Models such as ChatGPT have demonstrated a strong ability to write these descriptions automatically. However, to use these tools, programmers must send their code to untrusted third parties for processing (e.g., via an API call). This loss of custody is not acceptable to many organizations. In this paper, we present an alternative: we train an open source model using sample output generated by GPT $$-$$ - 3.5 in a process related to knowledge distillation. Our model is small enough (350 m parameters) to be run on a single 16gb GPU, yet we show in our evaluation that it is large enough to mimic GPT $$-$$ - 3.5 on this task.

Overview

The claims and statistics of this paper haven’t been checked yet.

Free: it reads the open-access text and checks the first 5 claims that cite a source we can check. Create a free account to check every claim.

A few free checks a day · papers already verified open instantly · results are public

Integrity signals

Registry

Crossref · 10.1007/s10515-024-00421-4

Cites

59 of 59 references verified0 citation errors · 0 not checkable

Statistics

Figures

Image 1
CC-BY-NC-ND · From the PDF
Fig. 2 Comparison of human reference summaries to GPT-3.5, along the four questions we discuss in Section 3.1, followed by a statistical summary of the RQ1 results in Figure 2 with Mann-Whitney tests showing statistical significance.
Fig. 2 Comparison of human reference summaries to GPT-3.5, along the four questions we discuss in Section 3.1, followed by a statistical summary of the RQ1 results in Figure 2 with Mann-Whitney tests showing statistical significance.CC-BY-NC-ND · From the PDF
Fig. 3 Comparison of human reference summaries to GPT-3.5 in terms of overall preference and the number of convergence and divergence functions on the duplicate studies
Fig. 3 Comparison of human reference summaries to GPT-3.5 in terms of overall preference and the number of convergence and divergence functions on the duplicate studiesCC-BY-NC-ND · From the PDF
Fig. 4 Comparison of summaries generated by models trained with human reference summaries to summaries generated by models trained with GPT-3.5, along the four questions we discuss in Section 3.1, followed by a statistical summary of the RQ1 results in Figure 4 with Mann-Whitney tests.
Fig. 4 Comparison of summaries generated by models trained with human reference summaries to summaries generated by models trained with GPT-3.5, along the four questions we discuss in Section 3.1, followed by a statistical summary of the RQ1 results in Figure 4 with Mann-Whitney tests.CC-BY-NC-ND · From the PDF
Fig. 5 Comparison of jam to GPT-3.5 followed by a statistical summary of the RQ3 results with Mann-Whitney tests showing statistical significance.
Fig. 5 Comparison of jam to GPT-3.5 followed by a statistical summary of the RQ3 results with Mann-Whitney tests showing statistical significance.CC-BY-NC-ND · From the PDF
Image 6
CC-BY-NC-ND · From the PDF

Verification

Claims the paper makes

The claims and statistics of this paper haven’t been checked yet.

Free: it reads the open-access text and checks the first 5 claims that cite a source we can check. Create a free account to check every claim.

A few free checks a day · papers already verified open instantly · results are public

Claims other papers make about this one

Each is checked against this paper’s own text: does it say what the citing paper says it does?

Self-check

Percentages, sums and reported differences re-computed from the paper’s own numbers.

The self-check needs the paper’s full text.

Citations

Cites

Show all 59 references

Research works printed but not linked: 13

  1. Allamanis M, Barr ET, Devanbu P, et al (2018a) A survey of machine learning for big code and naturalness. ACM Comput Surv 51(4). https://doi.org/10.1145/3212695 · DOI · Paper page
  2. Allamanis M, Brockschmidt M, Khademi M (2018b) Learning to represent programs with graphs. In: International Conference on Learning Representations, URL https: //openreview.net/forum?id=BJOFETxR-
  3. Alon U, Zilberstein M, Levy O, et al (2019b) code2vec: Learning distributed representations of code. Proceedings of the ACM on Programming Languages 3(POPL):1-29. https://doi.org/10.1145/3290353 · DOI · Paper page
  4. Banerjee S, Lavie A (2005) Meteor: An automatic metric for mt evaluation with improved correlation with human judgments. In: Proceedings of the acl work- shop on intrinsic and extrinsic evaluation measures for machine translation and/or summarization, pp 65-72, URL https://aclanthology.org/W05-0909
  5. Chang TA, Bergen BK (2023) Language model behavior: A comprehensive survey. arXiv preprint arXiv:230311504
  6. Chen Z, Jiang F, Chen J, et al (2023) Phoenix: Democratizing chatgpt across languages. arXiv preprint arXiv:230410453
  7. Derner E, Batistič K (2023) Beyond the safeguards: Exploring the security risks of chatgpt. arXiv preprint arXiv:230508005
  8. Gudibande A, Wallace E, Snell C, et al (2023) The false promise of imitating proprietary llms. arXiv preprint arXiv:230515717
  9. Ma W, Liu S, Wang W, et al (2023) The scope of chatgpt in software engineering: A thorough investigation. arXiv preprint arXiv:230512138
  10. Robillard MP, Marcus A, Treude C, et al (2017) On-demand developer documenta- tion. In: 2017 IEEE International conference on software maintenance and evolution (ICSME), IEEE, pp 479-483, https://doi.org/10.1109/ICSME.2017. · doi:10.1109/icsme.2017
  11. Schaeffer R, Miranda B, Koyejo S (2023) Are emergent abilities of large language models a mirage? arXiv preprint arXiv:230415004
  12. Sun W, Fang C, You Y, et al (2023) Automatic code summarization via chatgpt: How far are we? arXiv preprint arXiv:230512865
  13. Yu Y, Zhuang Y, Zhang J, et al (2023) Large language model as attributed training data generator: A tale of diversity and bias. arXiv preprint arXiv:230615895

Cited by

See all 49

Metadata

Authors
Su, C.-Y., & McMillan, C.
Affiliations
University of Notre Dame (US)
Corresponding author
Su, Chia-Yi
Venue
Automated Software Engineering
Published
2024-03-01
Volume
31
Issue
1
ISSN
  • 0928-8910 (ISSN-L)
  • 1573-7535
OpenAlex
W4392365769
Cited by
49
References
58
Citations by year
2026: 15 · 2025: 21 · 2024: 13
FWCI
12.94
Type
journal article
Language
en
Open access
Licence
Locations
  • Automated Software Engineering (publishedVersion)
  • arXiv (Cornell University) (submittedVersion, cc-by-nc-nd)
  • arXiv (Cornell University)
Funders
National Science Foundation (CCF-2100035)
Topics
  • Physical Sciences › Computer Science › Information Systems › Software Engineering Research
  • Physical Sciences › Computer Science › Artificial Intelligence › Topic Modeling
  • Physical Sciences › Computer Science › Artificial Intelligence › Natural Language Processing Techniques
Keywords
code summarization, knowledge distillation, large language models, GPT-3.5, open-source language models, developer documentation, model compression

About these checks

Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.

Statistics and arithmetic are recomputed, not judged.

Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.

What counts as a claim ›How we measure confidence ›How we check this ›

Are you an author, or do you see a problem with this page? Request a review

How to cite

Cite CoChat for the checks on this page, and the paper for its own findings.

This page
CoChat. (2026). Citation check: Distilled GPT for source code summarization. https://app.cochat.ai/papers/10.1007/s10515-024-00421-4
The paper
Su, C.-Y., & McMillan, C. (2024). Distilled GPT for source code summarization. Automated Software Engineering. https://doi.org/10.1007/s10515-024-00421-4

Data sources

Bibliographic data: Semantic Scholar, OpenAlex, Crossref.

Contains information from the Semantic Scholar Academic Graph Datasets, made available under the ODC Attribution License (ODC-BY 1.0).

Semantic Scholar’s data is described in: Kinney, R., et al. (2023). The Semantic Scholar Open Data Platform. arXiv:2301.10140.