Skip to main navigation Skip to search Skip to main content

Don't Complete It! Preventing Unhelpful Code Completion for Productive and Sustainable Neural Code Completion Systems

  • Zhensu Sun
  • , Xiaoning Du
  • , Fu Song
  • , Shangwen Wang
  • , Mingze Ni
  • , Li Li
  • ShanghaiTech University
  • Monash University
  • National University of Defense Technology
  • University of Technology Sydney

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

Abstract

Currently, large pre-trained language models are widely applied in neural code completion systems. Though large code models significantly outperform their smaller counterparts, around 70% of displayed code completions from Copilot are not accepted by developers. Being reviewed but not accepted, their help to developer productivity is considerably limited. Even worse, considering the high cost of the large code models, it is a huge waste of computing resources and energy. To fill this significant gap, we propose an early-rejection mechanism to turn down low-return prompts by foretelling the code completion qualities without sending them to the code completion system. Furthermore, we propose a lightweight Transformer-based es-timator to demonstrate the feasibility of the mechanism. The experimental results show that the proposed estimator helps save 23.3% of computational cost measured in floating-point operations for the code completion systems, and 80.2% of rejected prompts lead to unhelpful completion.

Original languageEnglish
Title of host publicationProceedings - 2023 IEEE/ACM 45th International Conference on Software Engineering
Subtitle of host publicationCompanion Proceedings, ICSE-Companion 2023
PublisherIEEE Computer Society
Pages324-325
Number of pages2
ISBN (Electronic)9798350322637
DOIs
StatePublished - 27 Jul 2023
Externally publishedYes
Event45th IEEE/ACM International Conference on Software Engineering: Companion Proceedings, ICSE-Companion 2023 - Melbourne, Australia
Duration: 15 May 202316 May 2023

Publication series

NameProceedings - International Conference on Software Engineering
ISSN (Print)0270-5257

Conference

Conference45th IEEE/ACM International Conference on Software Engineering: Companion Proceedings, ICSE-Companion 2023
Country/TerritoryAustralia
CityMelbourne
Period15/05/2316/05/23

Fingerprint

Dive into the research topics of 'Don't Complete It! Preventing Unhelpful Code Completion for Productive and Sustainable Neural Code Completion Systems'. Together they form a unique fingerprint.

Cite this