This AI translates code from a programming language to another | Facebook TransCoder Explained

--

This new model converts code from a programming language to another without any supervision! It can take a Python function and translate it into a C++ function, and vice-versa, without any prior examples! It understands the syntax of each language and can thus generalize to any programming language! Let’s see how they did that.

To understand this new model by Facebook, called the Transcoder, we first need to introduce what it is. In short, it’s a transcompiler. Meaning that it is a source-to source translater, which converts a source code from a high-level programming language (such as C++ or Python) to another one.

Currently, this type of translation requires manual modifications to work properly because of the complexity of the task. It is hard to respect the target language conventions when changing from programming language A to a programming language B. Plus, since it is a complex task, it requires a lot of knowledge in…

--

--

Louis-François Bouchard
What is Artificial Intelligence

I try to make Artificial Intelligence accessible to everyone. Ex-PhD student, AI Research Scientist, and YouTube (What’s AI). https://www.louisbouchard.ai/