openrewrite / rewrite

Automated mass refactoring of source code.

Home Page:https://docs.openrewrite.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Recipe to produce datatable with method invocation and docstrings

justine-gehring opened this issue · comments

What problem are you trying to solve?

A recipe which produces a data table such that one of the columns is "method invocations", and the other is the docstrings for the methods being called. There will be duplicated docstring, which is expected. This recipe will be used for AI research, both for testing and possibly training.

method invocation                                   docstring
------------------------------------------------------------------------
foo("hello")                                       foo is a method which .... 
foo("hi!")                                         foo is a method which .... 
bar("123")                                         bar is a method that .....

If possible, the datatable would contain path to method invocation and maybe line number. It can be any way such that one can find the method invocation if needed.

What precondition(s) should be checked before applying this recipe?

In Java