Pointing to Subwords for Generating Function Names in Source Code

Shogo Fujita, Hidetaka Kamigaito, Hiroya Takamura, Manabu Okumura


Abstract
We tackle the task of automatically generating a function name from source code. Existing generators face difficulties in generating low-frequency or out-of-vocabulary subwords. In this paper, we propose two strategies for copying low-frequency or out-of-vocabulary subwords in inputs. Our best performing model showed an improvement over the conventional method in terms of our modified F1 and accuracy on the Java-small and Java-large datasets.
Anthology ID:
2020.coling-main.28
Volume:
Proceedings of the 28th International Conference on Computational Linguistics
Month:
December
Year:
2020
Address:
Barcelona, Spain (Online)
Editors:
Donia Scott, Nuria Bel, Chengqing Zong
Venue:
COLING
SIG:
Publisher:
International Committee on Computational Linguistics
Note:
Pages:
316–327
Language:
URL:
https://aclanthology.org/2020.coling-main.28
DOI:
10.18653/v1/2020.coling-main.28
Bibkey:
Cite (ACL):
Shogo Fujita, Hidetaka Kamigaito, Hiroya Takamura, and Manabu Okumura. 2020. Pointing to Subwords for Generating Function Names in Source Code. In Proceedings of the 28th International Conference on Computational Linguistics, pages 316–327, Barcelona, Spain (Online). International Committee on Computational Linguistics.
Cite (Informal):
Pointing to Subwords for Generating Function Names in Source Code (Fujita et al., COLING 2020)
Copy Citation:
PDF:
https://preview.aclanthology.org/nschneid-patch-4/2020.coling-main.28.pdf