Context-Aware Parse Trees

03/24/2020
by   Fangke Ye, et al.
7

The simplified parse tree (SPT) presented in Aroma, a state-of-the-art code recommendation system, is a tree-structured representation used to infer code semantics by capturing program structure rather than program syntax. This is a departure from the classical abstract syntax tree, which is principally driven by programming language syntax. While we believe a semantics-driven representation is desirable, the specifics of an SPT's construction can impact its performance. We analyze these nuances and present a new tree structure, heavily influenced by Aroma's SPT, called a context-aware parse tree (CAPT). CAPT enhances SPT by providing a richer level of semantic representation. Specifically, CAPT provides additional binding support for language-specific techniques for adding semantically-salient features, and language-agnostic techniques for removing syntactically-present but semantically-irrelevant features. Our research quantitatively demonstrates the value of our proposed semantically-salient features, enabling a specific CAPT configuration to be 39% more accurate than SPT across the 48,610 programs we analyzed.

READ FULL TEXT
research
04/02/2020

Software Language Comprehension using a Program-Derived Semantic Graph

Traditional code transformation structures, such as an abstract syntax t...
research
08/28/2020

On the Performance of Bytecode Interpreters in Prolog

The semantics and the recursive execution model of Prolog make it very n...
research
06/05/2020

MISIM: An End-to-End Neural Code Similarity System

Code similarity systems are integral to a range of applications from cod...
research
08/09/2019

Functional programming with lambda-tree syntax

We present the design of a new functional programming language, MLTS, th...
research
03/22/2021

ast2vec: Utilizing Recursive Neural Encodings of Python Programs

Educational datamining involves the application of datamining techniques...
research
07/27/2018

A Hierarchical Approach to Neural Context-Aware Modeling

We present a new recurrent neural network topology to enhance state-of-t...
research
02/16/2022

Code Search based on Context-aware Code Translation

Code search is a widely used technique by developers during software dev...

Please sign up or login with your details

Forgot password? Click here to reset