Scientists have presented a new AI-based model that quickly finds errors in code. It will speed up development by at least 30%.

Microsoft researchers have developed an artificial intelligence (AI) solution to help you write code faster and better. AI called BugLab is based on the hide and seek game model and works on the principle of generative adversarial networks (GANs).

In a blog post, researchers Miltos Allamanis and Mark Brokschmidt shared how they created the two networks and how they trained each other when they were set up to be adversarial.

“To measure performance, we manually annotated a small set of buggy data from packages in the Python Package Index and showed that models trained with our method performed 30% better than the alternatives. For example, detectors trained on accidentally inserted errors”, – noted in the blog.

One web is for creating bugs in your code, and the other is for finding them. As the game goes on, both algorithms get better. The AI ​​then learns to the point where it is accurate enough to find bugs in real code.

Both models were trained together, without using tagged data, in a self-controlled way on millions of code snippets, the researchers explain. Although the idea was to create a program capable of detecting arbitrarily complex errors, they are still “beyond the reach of modern AI methods,” the scientists say.