Hello everyone, I am your yard farmer eldest brother – stack long.
Since Microsoft acquired GitHub three years ago, there has been a lot of movement. Just over two years ago, Microsoft made GitHub’s private repository free. , later also launched a GitHub for Mobile Mobile version, these I have been in the public number Java technology stack for sharing, did not see you can look back.
Recently, GitHub has made a big deal out of it, with the release of a new AI programming tool called GitHub Copilot.
Introduction to the
Website: https://copilot.github.com/
Copilot is a collaboration between GitHub and OpenAI. Seeing this reminds me of Codota, the AI coding tool I shared earlier. Codota automatically analyzes code and provides intelligent hints, which can greatly improve development efficiency.
GitHub Copilot, your AI companion programmer, can be thought of as your shadow programmer, who trains on billions of lines of open source code and quietly advises you behind the scenes, whether it’s the entire line or the entire method. It does it for you.
Brilliant, some code, such as the tool class, no longer need to find online, GitHub Copilot can complete the entire method code.
Website sample
Simply put, Copilot can automatically match the entire method based on the context information you provide, such as comments, method names, and code itself.
Take a look at a few examples provided on the website to see how awesome it is!
Automate the entire method:
Complete the entire method according to the comments:
Automatically populate similar code:
Automatically generate matching unit test code:
A variety of different solutions can be switched:
Get up to speed on new languages and frameworks:
To apply for trial
Unfortunately, Copilot is still a preview version and does not support Java. It only supports Python, JavaScript, TypeScript, Ruby, and Go programming languages, otherwise the stack manager would really like to try it out.
In addition, Copilot is currently only available in Visual Studio Code. If you want to experience the above languages, you can apply for a trial preview version at:
https://github.com/features/c…
Here the stack length is not demonstrated, interested can study, and so on the back if support Java, the stack length must experience, do not go away, pay attention to the public number: Java technology stack, the first time to push Oh.
The working principle of
Copilot is so awesome? How does it work?
Take a look at the interaction diagram provided on the website:
1) The GitHub Copilot programmer sends context information to the GitHub Copilot service, including comments, code and other information;
2) The GitHub Copilot service uses the OpenAI Codex model, which trains on hundreds of millions of open source and natural languages, then makes recommendations to the GitHub Copilot programmer, and finally returns a single line of code or an entire method that matches;
3) The GitHub Copilot programmer continuously provides suggestions to improve the GitHub Copilot service;
conclusion
Having the GitHub Copilot tool automatically complete the code really relived the pain of programmers looking for examples and helped us avoid the risk of copying bugs or potential bugs as much as possible.
As good as GitHub Copilot is, there are two other things we should be aware of!!
1. Safety
From the above schematic, we know that to get code suggestions, we must first send the comments, code and other trusted information in the editor to the GitHub Copilot server, which leads to the risk of code leakage.
At present, the security is unknown, only the preview version, but for the financial, payment type of sensitive business scenario is probably to think about.
2. Copyright issues
GitHub Copilot is trained on hundreds of millions of dollars of open source code, but if a commercial company gives it away for free, then it’s not for free.
The copyright issue is still very controversial. If so, do you have the same concerns? Will your open source projects still be hosted on GitHub?
Well, today’s share here, the subsequent stack leader will always share the most hardcore Java technology, small partners can continue to pay attention to the public number Java technology stack, the public number first time push Oh.
Finally, what do you have to say about the Copilot tool at GitHub? Please leave a comment and share
Copyright statement: this article is the public number “Java technology stack “original, original is not easy, reprint, quote the content of this article please indicate the source, prohibit plagiarism, manuscript wash, please respect yourselves, respect everyone’s work and intellectual property rights, plagiarism will be prosecuted.
Recent hot article recommended:
1.1,000+ Java interview questions and answers (latest version of 2021)
2. I finally got the IntelliJ IDEA activation code through open source project. How nice!
3. Ali Mock tool officially open source, kill all the Mock tools in the market!
4.Spring Cloud 2020.0.0 is officially released, a new and disruptive version!
5. “Java development manual (Songshan edition)” the latest release, fast download!
Feel good, don’t forget with thumb up + forward oh!