Skip to content

Latest commit

 

History

History
29 lines (19 loc) · 1.13 KB

README.md

File metadata and controls

29 lines (19 loc) · 1.13 KB

Source code of the paper "Don't Complete It! Preventing Unhelpful Code Completion for Productive and Sustainable Neural Code Completion Systems"

Datasets

Download CSN and COFIC into the datasets folder. The datasets are available at CSN(python) and COFIC

The HumanAccept dataset is available at HumanAccept

Run

Generate training dataset for estimators

We first generate a dataset for training estimators. The dataset is generated by querying the LCMs with the training dataset. Please refer to scripts/gen_score.sh. An example for starcoder:

bash scripts/gen_score.sh 0 starcoder python

Train estimators

The scripts for training estimators are in the scripts/train_est folder.

Generate estimation

The scripts for evaluating estimators are in scripts/eval_estimators.sh

Scripts for processing the results

compute_flops: energy_analysis.py compute_results: eval_estimator.py