4

Sequence-to-sequence models have achieved good performance in natural language translation. Could these models also be applied to convert source code written in one programming language to source code written in another language? Could they also be used to convert JSON to XML? Has this been done?

There are plenty of models that generate source code (which looks like real source code) using RNNs, although the generated source code doesn't make logical sense. I haven't been able to find any models or examples that take valid existing code and convert it into different valid code.

nbro
  • 39,006
  • 12
  • 98
  • 176
pfds2222
  • 41
  • 1
  • 1
    I don't think common techniques would work very well for this. The reason being (currently) most models perform poorly at *perfect* results. By that I mean, they are prone to very small mistakes. Like in translating french to english, if done well, you might find a word containing one extra vowel, a small mistake any human would have no problem with. However, as you know, this would not pass in a programming language. – Recessive Dec 17 '19 at 14:38

0 Answers0