dkhati56 commited on
Commit
e78a394
·
1 Parent(s): 5af89b5

Updated readme

Browse files
Files changed (1) hide show
  1. README.md +60 -0
README.md CHANGED
@@ -1,3 +1,63 @@
1
  ---
2
  license: mit
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: mit
3
  ---
4
+
5
+ ### Dataset is imported from CodeXGLUE and pre-processed using their script.
6
+
7
+ # Where to find in Semeru:
8
+ The dataset can be found at /nfs/semeru/semeru_datasets/code_xglue/code-to-code/CodeCompletion-token/dataset/javaCorpus in Semeru
9
+
10
+
11
+ # CodeXGLUE -- Code Completion (token level)
12
+
13
+ **Update 2021.07.30:** We update the code completion dataset with literals normalized to avoid sensitive information.
14
+
15
+ Here is the introduction and pipeline for token level code completion task.
16
+
17
+ ## Task Definition
18
+
19
+ Predict next code token given context of previous tokens. Models are evaluated by token level accuracy.
20
+
21
+ Code completion is a one of the most widely used features in software development through IDEs. An effective code completion tool could improve software developers' productivity. We provide code completion evaluation tasks in two granularities -- token level and line level. Here we introduce token level code completion. Token level task is analogous to language modeling. Models should have be able to predict the next token in arbitary types.
22
+
23
+
24
+ ## Dataset
25
+
26
+ The dataset is in java.
27
+
28
+
29
+ ### Dependency
30
+
31
+ - javalang == 0.13.0
32
+
33
+
34
+
35
+
36
+ ### Github Java Corpus
37
+
38
+ We use java corpus dataset mined by Allamanis and Sutton, in their MSR 2013 paper [Mining Source Code Repositories at Massive Scale using Language Modeling](https://homepages.inf.ed.ac.uk/csutton/publications/msr2013.pdf). We follow the same split and preprocessing in Karampatsis's ICSE 2020 paper [Big Code != Big Vocabulary: Open-Vocabulary Models for Source Code](http://homepages.inf.ed.ac.uk/s1467463/documents/icse20-main-1325.pdf).
39
+
40
+
41
+
42
+ ### Data Format
43
+
44
+ Code corpus are saved in txt format files. one line is a tokenized code snippets:
45
+ ```
46
+ <s> from __future__ import unicode_literals <EOL> from django . db import models , migrations <EOL> class Migration ( migrations . Migration ) : <EOL> dependencies = [ <EOL> ] <EOL> operations = [ <EOL> migrations . CreateModel ( <EOL> name = '<STR_LIT>' , <EOL> fields = [ <EOL> ( '<STR_LIT:id>' , models . AutoField ( verbose_name = '<STR_LIT>' , serialize = False , auto_created = True , primary_key = True ) ) , <EOL> ( '<STR_LIT:name>' , models . CharField ( help_text = b'<STR_LIT>' , max_length = <NUM_LIT> ) ) , <EOL> ( '<STR_LIT:image>' , models . ImageField ( help_text = b'<STR_LIT>' , null = True , upload_to = b'<STR_LIT>' , blank = True ) ) , <EOL> ] , <EOL> options = { <EOL> '<STR_LIT>' : ( '<STR_LIT:name>' , ) , <EOL> '<STR_LIT>' : '<STR_LIT>' , <EOL> } , <EOL> bases = ( models . Model , ) , <EOL> ) , <EOL> ] </s>
47
+ ```
48
+
49
+
50
+ ### Data Statistics
51
+
52
+
53
+ Data statistics of Github Java Corpus dataset are shown in the below table:
54
+
55
+ | Data Split | #Files | #Tokens |
56
+ | ----------- | :--------: | :---------: |
57
+ | Train | 12,934 | 15.7M |
58
+ | Dev | 7,176 | 3.8M |
59
+ | Test | 8,268 | 5.3M |
60
+
61
+
62
+
63
+