What our team has learned about the new AI pair programmer that would help them write better code.
If you’re a programmer, you might have rejoiced or freaked out at the news of Github Copilot, and if you haven’t heard about it, here’s all you need to know. Developed by Github, Copilot is a new plugin that assists programmers to write code with autocompletion; it auto-generates code based on the contents of a current file and the current cursor location. A technical preview of this new AI was launched in June 2021 and is said to work especially well for Python, JavaScript, TypeScript, Ruby and Go.
About Github Copilot: Is It Magic?
Developed in collaboration with OpenAI, GitHub Copilot is powered by the latter’s new AI system, OpenAI Codex.
To skip the search for answers on the internet that is crucial for most developers, this new technology allows them to explore suggested solutions to problems as they write tests and discover new APIs. The technology adapts to the way the code is being written for faster completion of the required tasks and understands significantly more context than most code assistants.
OpenAI Codex has wider knowledge of code usage and generates code more efficiently because of its data set that is more concentrated in public source code. What is truly impressive about Github Copilot is that it’s not inserting snippets of code, it is in fact utilizing the data it has along with the input of the developers to generate novel code matching the one already written. It can also show programmers a list of solutions they can use as is or edit to meet their needs.
Auto-Generated Code: Is It Truly Reliable?
While the idea of auto-generated code that is relatively custom to the code being written seems ideal, Github Copilot suggestions are based on the most suitable code included in its archive. This was explained in OpenAI’s Codex paper:
“As with other large language models trained on a next-token prediction objective, Codex will generate code that is as similar as possible to its training distribution. One consequence of this is that such models may do things that are unhelpful for the user”
Github Copilot tries to understand a programmer’s intent and to generate the best code it can, but the code it suggests may not always work.
Will It Replace Developers and Undermine Their Experience?
Github Copilot can minimize the time developers spend on Google and Stack Overflow, it is a helpful tool that can optimize performance, save time and minimize errors. While relatively new, Github Copilot is getting better and with the help of developers around the world it can continue to grow and become more efficient. However, a capable and skilled pilot is crucial when being assisted by a copilot. Developers need to evaluate suggestions, revise their options and make the definitive decisions; for now, they’re here to stay.
Shoutout to our amazing pilots at AddBloom! Drop us a hello today if you want to launch your next project.