Hi GitHub CoPilot! -Chatting with the AI pair programmer

Shantanu Agarwal
2 min readJul 22, 2021

--

OpenAI has released into this world an incredible AI — The GitHub CoPilot. An AI powered programming assistant that is much more capable than the usual IDE autocomplete features. This has to be one of the coolest AI systems. Check it out here.

CoPilot is still in testing and you can apply to be a tester. As mentioned on the website, OpenAI plans to eventually monetise this system (Oh NO!). I was lucky enough to get accepted as a tester. Here is how you go on chatting with it.

Note: GitHub CoPilot is trained on billions of lines of code, and is not intended for chatting. This feature might be discontinued in the feature. This is just an experiment to see what kind of information and biases are encoded in the system.

How to setup a chat with CoPilot?

  1. Apply for the technical preview here
  2. After you get accepted as a tester, install the CoPilot extension on Visual Studio Code
  3. Open a new file with .yaml extension
  4. Start asking questions in the below format
    Me: <Question>
    AI:

    and CoPilot with autocomplete it for you!

If the replies gets repetitive, open a new file, or use prompts for CoPilot to complete like below.
Note that I didn’t use any suggestive prompts for the 2 snippets in this article.

Example of using prompts for CoPilot to complete

Below are some fun snippets.

We have the solution to the chicken-egg problem! CoPilot understands it’s limitations and delegates science questions to the ‘Science AI’.

In this simple test, CoPilot seems to be quite smart. It refused to show any preference between John or Mary in the first few questions and simply picked the first option.
Due to my frequent questions about programmers, it learned to produce that output frequently. Does that suggest CoPilot will mimic the user?
Lastly, CoPilot just refused to suggest anything in the last question. Is that a smart AI move? We’ll see.

Chatting with CoPilot did get repetitive after a while, I guess I should stick to coding.

The team behind CoPilot has done a lot to tackle biased, discriminatory or offensive output. As mentioned on their website, they have taken appropriate measures to be preventive and asked the testers to flag any such instances.

--

--

Shantanu Agarwal
Shantanu Agarwal

Written by Shantanu Agarwal

Artist and Geek playing with cutting edge Machine Learning

No responses yet