Your GitHub Copilot friend | HCLTech
Digital Business

Your GitHub Copilot friend

How GitHub Copilot is helping the developer community boost enterprise productivity
4 minutes read
Tapan  Samanta


Tapan Samanta
Senior Technical Architect, Digital Business
4 minutes read

If you are associated directly or indirectly with software development, you are certainly aware of the current buzz across industries around “developer productivity.” Even if you are not, keep reading to learn more.

Developer productivity can be defined as a team’s ability to produce high-quality code efficiently, to deliver business value for the customers. The goal of developer productivity is to increase “developer velocity,” which is a sum of all effort points (e.g., coding and testing hours, completed story points and completed user stories) required to build the final feature in one sprint. Increasing developer productivity ensures faster go-to-market for an organization, amongst other benefits. Now if we were to guess what is enabling developer productivity, there would be no prizes for getting it right. It is generative AI. According to a recent McKinsey study, there is a significant productivity gain of up to 30% for simple tasks and of up to 15% for medium-complexity tasks from generative AI.

In keeping with the above, just over a couple of years ago, Microsoft and GitHub came together to launch a joint research initiative called Developer Velocity Lab (DVL) for improving developer productivity and the overall well-being of developers around the world. What is interesting here is that apart from the productivity perspective, DVL also explores socio-technology angles, namely in areas of developer community building, knowledge sharing, sustainability and the well-being of developers - including their happiness and satisfaction.

Am I happy about it? You bet. I have always felt that software development has traditionally followed the legacy industrial model of production and lacked empathy for the developers. But I am digressing. This blog is meant to focus on Microsoft’s offering on GitHub Copilot and how it is helping organizations increase developer productivity using generative AI. So, let me jump right into it.

Microsoft’s GitHub Copilot is an AI pair programmer that helps developers write code faster, and with less work. Microsoft has rolled out Copilots for other tracks like Dynamics 365, Power Platform and others. So, you might guess that these Copilots are designed to act as assistants to software developers.

GitHub Copilot is powered by Open AI Codex, a generative pretrained language model created by Open AI. It is trained on billions of lines of code already written and available on the internet. It helps developers reduce the time spent on writing boilerplate code by generating suggestions based on the context of the code they are writing. For example, if you are creating a new class in C#, GitHub Copilot can suggest the basic structure of the class, including the constructor and any necessary imports. This not only saves time, but also reduces the likelihood of errors due to typos or other mistakes that can occur when you are writing the same boilerplate code manually. GitHub Copilot also understands the comments written in natural languages and suggests code completion. Let us take, for example, a Razor component of a BlazorServer application in Visual Studio. The Copilot has suggested the complete Razor code snippet to display a list of questions (the model) in a HTML table from the commented instruction in natural language.

Like all machine learning models and AI services, effectiveness and usage have a symbiotic relationship. By the same token, the more you use the large language models, the better they get at what they do. In GitHub Copilot, too, the quality of suggestions depends on the volume and diversity of training data for that language. GitHub Copilot is trained on all programming languages that are publicly available. With higher popularity of the language, the effectiveness of Copilot increases. For example, JavaScript is well-represented in public repositories and is one of GitHub Copilot's best supported languages. Conversely, languages with less representation in public repositories may produce fewer or less robust suggestions.

The GitHub team provides extensions for some of the popular IDEs like Visual Studio Code, Visual Studio, Vim and the IDEs from JetBrains. To get started with GitHub Copilot, subscribe to GitHub Copilot, install the extension in your favorite IDE and add the GitHub account into the IDE.

Everything makes sense so far, right? Does that mean you don't need to consider anything else? Not really. GitHub Copilot is not free. At least, not at the time of writing this blog. It is only available to developers who have subscribed to it. Also, Copilot may not always suggest the most secure code and it may have bugs. Symbolically, as well, it is the pilot’s responsibility to fly the plane. The copilot is second in command. Similarly, it is the developer’s responsibility to verify the authenticity of the code that Copilot suggests. It is for the developer to decide whether to accept the suggestion from the Copilot or decline it. The good part is that we have a great learner in our Copilot. It learns immediately and rectifies itself. Thankfully, it will not repeat the same mistake. Copilot does not always fully understand the context of the code for which it is generating suggestions, so developers (the pilots) must write a few initial lines of code on the commented instruction so that Copilot gathers more information about the context and can make suggestions according to it. Also, Copilot may not be able to generate code for very specific or niche use cases on which developers are working.


How GitHub Copilot is helping the developer community boost enterprise productivity


Now that I have covered how GitHub Copilot can help organizations increase developer productivity, let me add that it can also improve code quality through suggesting code snippets and guidance on best practices. This not only enables enterprises to standardize code across the enterprise, but also helps developers reduce their mental fatigue, especially while trying to meet tough deadlines. To support developers, administrators can enable GitHub Copilot for their teams and select which organizations, teams and developers receive licenses. They can easily set policy controls to enforce user settings for public code matching on behalf of your organization. With Copilot for business, GitHub will not retain code snippets, store or share your code regardless of whether the data is from public repositories, private repositories, non-GitHub repositories or local files.

At HCLTech, we are working with multiple customers to help them understand where and how GitHub Copilot could be used best. It is in the nascent stage, but there are exciting times ahead, both for service providers like us and for our customers from across a broad spectrum of industries around the globe. My sense is that if artificial intelligence has already made deep inroads into natural language processing, it is not very far when computer languages, which are by nature artificial, will be the next bastion to fall. While it is true that we are seeing benefits when the tasks are simple, I am sure the inflection point is some years ahead when even some of the domain knowledge needed for producing complex code will also start getting delivered by GitHub Copilot.

The possibilities are endless, and I cannot wait to see what the future has in store for you and me.

Share On