Automatically detecting and describing high level actions within methods
Proceedings of the 33rd International Conference on Software Engineering, 2011•dl.acm.org
One approach to easing program comprehension is to reduce the amount of code that a
developer has to read. Describing the high level abstract algorithmic actions associated with
code fragments using succinct natural language phrases potentially enables a newcomer to
focus on fewer and more abstract concepts when trying to understand a given method.
Unfortunately, such descriptions are typically missing because it is tedious to create them
manually. We present an automatic technique for identifying code fragments that implement …
developer has to read. Describing the high level abstract algorithmic actions associated with
code fragments using succinct natural language phrases potentially enables a newcomer to
focus on fewer and more abstract concepts when trying to understand a given method.
Unfortunately, such descriptions are typically missing because it is tedious to create them
manually. We present an automatic technique for identifying code fragments that implement …
One approach to easing program comprehension is to reduce the amount of code that a developer has to read. Describing the high level abstract algorithmic actions associated with code fragments using succinct natural language phrases potentially enables a newcomer to focus on fewer and more abstract concepts when trying to understand a given method. Unfortunately, such descriptions are typically missing because it is tedious to create them manually.
We present an automatic technique for identifying code fragments that implement high level abstractions of actions and expressing them as a natural language description. Our studies of 1000 Java programs indicate that our heuristics for identifying code fragments implementing high level actions are widely applicable. Judgements of our generated descriptions by 15 experienced Java programmers strongly suggest that indeed they view the fragments that we identify as representing high level actions and our synthesized descriptions accurately express the abstraction.