zysszy / TreeGen

A Tree-Based Transformer Architecture for Code Generation. (AAAI'20)
MIT License
90 stars 27 forks source link

How are general identifiers predicting e.g. functions from an available library? (besides the NL pointer net) #15

Open brando90 opened 3 years ago

brando90 commented 3 years ago

I was wondering in real programming we have usually a library of programs we have at our disposal. Generating new programs for each part sounds hopeless so I was wondering how tree gen solves this problem.

Is it that the tasks that tree gen was applied to has a small library it can choose from? (note I am not asking about the things in the NL that the pointer net is used for, I had more in mind like say we have the function zip or for a specific library say pandas we have a bunch of function the model could use etc how to choose those)

Is it that for GEO & HS the set of available function is always given and we could also just point to them with a pointer net?

I am trying to understand how much this question is a limitation of the model vs a limitation of the task.

Thanks again for all the useful responses! :)

zysszy commented 3 years ago

In our approach, we only collect identifiers from the training set rather than from a library.

Is it that the tasks that tree gen was applied to has a small library it can choose from?

Maybe generating java programs from the commit message (commit message generation dataset).

Is it that for GEO & HS the set of available function is always given and we could also just point to them with a pointer net?

HS dataset is collected from an open-source repository. Maybe you can find the functions from that repository.

Zeyu