原文:Deep Learning On Code with an Unbounded Vocabulary
作者:Milan Cvitkovic
單位:加州理工學院(Caltech, California Institute of Technology)、Amazon AI
會議:EasyChair 2018
模型
- 講源代碼轉成AST
- 在AST的基礎上加各種邊,如數據流,控制流
- (本文重點)變量的結點和
subtoken
之間加邊
- 用GGNN訓練
效果
FILL-IN-THE-BLANK
Unseen files from seen repos Entirely unseen repos AST Augmented AST AST Augmented AST Fixed Vocab 0.580.800.360.59CharCNN Only 0.600.900.480.84Graph Vocab (ours) 0.890.970.800.92
Variable Naming
Unseen files from seen repos Entirely unseen repos AST Augmented AST AST Augmented AST Fixed Vocab 0.23(7.22)0.19(7.64)0.05(8.66)0.04(8.34)CharCNN Only 0.22(8.67)0.20(7.46)0.06(8.82)0.06(8.16)Graph Vocab (ours) 0.49(3.87)0.53(3.68)0.38(4.81)0.41(4.28)
小結
又一個加邊狂魔。
論文裏掛的GitHub,點開是沒有的,所以看不了代碼。
在subtoken
和ast node
之間加個邊也是很不錯的
這個論文要是數據集用的是微軟的那個java-small
就好了,可以好好比一下,可惜是自己爬的。
參考
數據集