A new "AI pair programmer" represents a breakthrough in the third revolution of software development: the use of AI in coding.
Microsoft and OpenAI have collaborated to build an AI pair-programming system called GitHub Copilot. Copilot, now available in preview as a Visual Studio Code extension, is meant to help programmers write code faster and with less work, Microsoft officials said on June 29.
Copilot is powered by OpenAI Codex, a new AI system. Microsoft and OpenAI have been working together for the past few years on various projects; Copilot is their latest collaboration.
"If the technical preview is successful, our plan is to build a commercial version of GitHub Copilot in the future. We want to use the preview to learn how people use GitHub Copilot and what it takes to operate it at scale," GitHub officials said in a frequently asked questions (FAQ) document published today.
Since GitHub Copilot is available as a Visual Studio Code extension, working wherever Visual Studio Code works, on the developer’s machine or in the cloud on GitHub Codespaces. With access currently limited to a small group of testers, persons interested in trying Copilot can sign up for the Copilot waiting list.
While GitHub Copilot works with a broad set of frameworks and languages, the technical preview works “particularly well” with JavaScript, Python, TypeScript, Ruby, and Go, GitHub said. GitHub cautioned that Copilot does not always write “perfect” code, and that sometimes the suggested code will not work. Code suggested by the tool should be tested, reviewed, and vetted, like any other code, GitHub said.
Codex was trained on billions of publicly available source code lines -- including code in public repositories on GitHub -- and on natural language, which means it can understand both programming and human languages. The Copilot editor extension sends comments and code to the Copilot service. The service uses OpenAI Codex to synthesize and then suggest both individual lines of code and whole functions, Microsoft officials explained in the FAQ.
Copilot is meant to try to discern intent and generate the best code it can. However, it doesn't test the code it suggests, and Microsoft cautions that it may suggest old or deprecated uses of libraries and languages.
Copilot is meant to improve with time and use. Microsoft advises developers to divide their code into small functions, use meaningful names for functions parameters and write good docstrings and comments as they go. They also said Copilot "seems to do best when it's helping you navigate unfamiliar libraries or frameworks."
Top comments (3)
can't seem to install it on vs code, it says it's incompatible with version 1.47.2 though it's the latest one...
Try upgrade ur vscode to 1.57 or later @shadowx99
thanks for the heads up! i resolved the problem earlier.. i was working with both vscode and insider, and one of them was not latest version..that's why i was getting the error... anyways good looking out :)