13

How GitHub Copilot will Change Developers’ Life

 3 years ago
source link: https://blog.bitsrc.io/how-github-copilot-will-change-developers-life-c0b35b7be7e3
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

How GitHub Copilot will Change Developers’ Life

Virtual pair programmer that helps you save time and stay focused

GitHub Copilot is a next-generation, AI-powered pair programmer that allows you to write code faster while avoiding common mistakes. As a developer, I found this very interesting since it brings a new set of features compared to existing tools.

However, it’s only been days since Copilot was introduced, and it is still at the technical preview stage. So in this article, I will explore the features of GitHub Copilot and discuss how it will change the way we code.

GitHub Copilot — Your AI-Powered Pair Programmer

GitHub Copilot Demo

GitHub Copilot is built on top of an AI-based language generating algorithm — Codex, created by OpenAI. This research company is well known for its powerful language-generating AI models such as GPT-3.

Whether you’re working on a new language or just learning to code, GitHub Copilot helps you find your way without continuously searching for answers on the Internet.

Be it a set of comments or an existing code, as you type, GitHub Copilot adapts to the way you write code and auto-complete the code snippet or the entire function.

It helps you quickly discover alternative ways to solve problems, write tests, and explore new APIs by putting the knowledge you need at your fingertips.

The suggestions given by the GitHub Copilot are backed by billions of lines of code that users have publicly contributed to GitHub.

When it comes to features, there are 3 things that make it stand out from other similar tools. So, let’s have a look at those 3 features in detail.

Features of Copilot

Speaks all the Languages You Love

GitHub Copilot is designed to work with a large set of frameworks and languages.

The current technical preview works exceptionally well for Python, JavaScript, TypeScript, Ruby, and Go languages.

Furthermore, We can expect that this language and framework support will be increased in the subsequent releases making this a universal tool.

You’re the Pilot

Whatever the GitHub Copilot suggests, you will always be in charge as the developer. If you don’t like the first suggestion it gives, it will provide you with more alternatives.

You can go through the alternative suggestions, decide on what to accept and reject, and do manual edits to the suggested code. And as you use it understands your style and adapts to you.

Extends Your Editor

GitHub Copilot is currently available as a Visual Studio Code extension and works wherever the VS Code works.

Be it your machine or in the Cloud on GitHub Codespaces, when you provide a docstring, comment, function name, or an entire code, GitHub Copilot will give multiple suggestions to your fingertips.

Note: During the technical preview, it is offering free only to a limited number of testers. If you’re lucky enough, you’ll be able to grab one of the free spots from here.

1*SnQby9TvYoa8h7yD6lua0A.png?q=20
how-github-copilot-will-change-developers-life-c0b35b7be7e3
Under the hood of the VS Code GitHub Copilot extension. Credit: GitHub

Under the hood, this extension sends your editor context to the GitHub Copilot service, which uses the Codex algorithm to synthesize and provide suggestions. Then, as you type, Copilot will suggest snippets of code that you can add or reject with a click of a button.

The Good & the Bad About Copilot

Having a virtual pair programmer that helps you to save time and stay focused sounds fantastic, right? However, the reception received by the GitHub Copilot was not wholly satisfying. Let’s take a look at the reasons for that.

Pros of GitHub Copilot

  • More than just autocomplete — GitHub Copilot powered by Codex is not the first of its kind. Whether your context is in a docstring, comment, function name, or code itself,Copilot uses the context you’ve provided and synthesizes code to match, making it understand more context than most of the code assistants exist.
  • Auto-fills for repetitive code — Tired of writing repetitive code patterns? GitHub Copilot works great for quickly producing repetitive code patterns. You just need to provide a few examples, and Copilot will take care and generate the rest.
  • Generates alternative — When you write a code line, Copilot will show you a list of alternatives. You can choose one from them or stick to your code if you think it is better. Either way, Copilot will learn and try to adapt to your style.
  • Helps to conduct tests without much effort — Software testing is the backbone of any robust software project. Import a unit test package, and GitHub Copilot will suggest tests that match your code.
  • Speaks all the languages you love — Although, in the technical preview of Github, Copilot works exceptionally well for Python, TypeScript, JavaScript, Ruby, and Go, it understands a lot more languages. It can assist you in finding your way around almost anything.

Cons of GitHub Copilot

  • Dubious nature in terms of quality — GitHub Copilot generates suggestions based on the current file using it as a context. But, it cannot test its own code meaning it may not even run or compile.

Moreover, since Copilot is trained using the publicly available code on GitHub for years, the suggestions can contain depreciated versions of libraries and frameworks.

  • Violates the copyright issues — GitHub Copilot is using billions of publicly available code to train the tool. GitHub declares that the suggestions may contain verbatim from the training set in about 0.1% of the time. One of the significant concerns regarding the Copilot is that it could breach the copyright or launder open-source code into commercial use without proper licensing.
Armin Ronacher highlighted the GitHub Copilot’s copyright infringements
  • Not going to make you a good developer — This is like the two sides of a coin. While from one side, the tool will help you boost productivity and get recommendations to learn from. But from the other, this is similar to copy-pasting from the Stackoverflow. At least in Stackoverflow, you should put some actual effort into finding the thing you need, where you will learn more about by searching.

Final Thoughts

GitHub Copilot will open the door to the many changes in the industry, but the degree to which those changes will be favorable or detrimental is still unknown.

It will get better over time.

Recently, the performance of the Copilot was benchmarked against a set of Python functions, which has a good test coverage in the open-source repos. The team cleared the function bodies and kept only the function names and docstrings. Copilot could fill them in correctly 43% of the time in the first attempt, and the accuracy increased to 57% after ten attempts. Similar to most AI tools, Copilot also gets smarter over time based on the data it collects from users.

CNBC states that when a user accepts or rejects a Copilot’s suggestion, Copilot’s machine learning model will use that feedback to enhance its future suggestions.

As GitHub suggests, Copilot is truly your pair programmer. It helps you write code faster and with less work, and in return, it learns from your feedback to improve its suggestions. Who knows, maybe as it learns, the GitHub Copilot will become more human alike in the future.

Our jobs are not at stake.

In addition, I’ve seen that many have raised concerns that there’s a risk that GitHub Copilot can affect the developers’ jobs in the future.

Personally, I don’t believe that AI, no matter how advanced it is, will be able to replace humans, at least in the near future.

AI will become more reliable and effective at quality code writing, and it will become a better coding partner one day. Still, developers will remain important as their actual value contributes to both building things and knowing what to build.

There are many unanswered questions.

In this early version, the code suggestions given by the GitHub Copilot may contain bugs, unfitting, offensive content, or maybe the code might not even makes any sense. But GitHub promises to fix its flaws as it improves with time. Following the launch of the GitHub Copilot, it has received mixed reviews from the experts, and many questions have been arising, and many more will keep coming.

Will GitHub Copilot will manage to overcome its current flaws? Will companies adopt Copilot despite its security issues and copyright infringement? Is this the beginning of AI overtaking the programmer’s job?

Well, all of your answers will have to wait. So instead, let’s keep an eye on where technology will take us in the future. However, despite the problems I’ve highlighted, GitHub Copilot will be an important milestone and will play a vital role in millions of programmers’ day-to-day life in the future.

Thank you for reading!!!

Build & share independent JS components with Bit

Bit is an extensible tool that lets you create truly modular applicationswith independently authored, versioned, and maintained components.

Use it to build modular apps & design systems, author and deliver micro frontends, or simply share components between applications.

A React ‘card’ component independently developed and source-controlled with an auto-generated dependency tree.

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK