Function Assistant: A Tool for NL Querying of APIs

Kyle Richardson, Jonas Kuhn


Abstract
In this paper, we describe Function Assistant, a lightweight Python-based toolkit for querying and exploring source code repositories using natural language. The toolkit is designed to help end-users of a target API quickly find information about functions through high-level natural language queries, or descriptions. For a given text query and background API, the tool finds candidate functions by performing a translation from the text to known representations in the API using the semantic parsing approach of (Richardson and Kuhn, 2017). Translations are automatically learned from example text-code pairs in example APIs. The toolkit includes features for building translation pipelines and query engines for arbitrary source code projects. To explore this last feature, we perform new experiments on 27 well-known Python projects hosted on Github.
Anthology ID:
D17-2012
Volume:
Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing: System Demonstrations
Month:
September
Year:
2017
Address:
Copenhagen, Denmark
Editors:
Lucia Specia, Matt Post, Michael Paul
Venue:
EMNLP
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
67–72
Language:
URL:
https://aclanthology.org/D17-2012
DOI:
10.18653/v1/D17-2012
Bibkey:
Cite (ACL):
Kyle Richardson and Jonas Kuhn. 2017. Function Assistant: A Tool for NL Querying of APIs. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 67–72, Copenhagen, Denmark. Association for Computational Linguistics.
Cite (Informal):
Function Assistant: A Tool for NL Querying of APIs (Richardson & Kuhn, EMNLP 2017)
Copy Citation:
PDF:
https://aclanthology.org/D17-2012.pdf
Code
 additional community code