
Many of us have used things like Chat GPT for help with a range of things and in some cases it does a good job with making mundane tasks relating to text generation and summation quickly.
This also translates across to software development where these assistants can help with programming, whether it’s generation, checking things over or debugging. I’ve asked about the occasional snippet from Chat GPT but I’ve not really used it extensively while programming. Recently I started a personal project with the specific intention of using an AI programming assistant to see how things go with the hope that it would accelerate things. This post covers my initial experience working with it.
Getting started
VS Code is my IDE of choice which has an assistant called copilot built in. It’s developed by Microsoft and requires a Github login in order to use it. Copilot appears well integrated to VS code and it can make changes to files without having to manually copy and paste from the chat and can read in files for context when making requests.
What it like?
It becomes apparent early on, it’s a bit like having a junior developer that can write very quickly. The key word here being ‘junior’ because it can generate code requested in the prompt but at the same time it does not seem to have any context for a larger project where multiple files are involved. It was somewhat like reviewing pull requests when considering the ability for the response to be merged directly into a file.
I found that the assistant always needs to be herded in the right direction. An analogy would be I’m the farmer and the prompt is my new sheepdog and the sheep are the output of the assistant. This equates to things going vaguely in the right direction but you’ve got to constantly observe and adjust and correct in order for things not to spiral out of control.
The assistant appears well suited for making initial classes and basic methods but once things got a bit more complex, I seemed to rely on it less once a class matured, slipping back into programming as I have done previously. Then, once a new class is required, I dive back to the assistant for initial generation.
Guidelines I currently work towards
Make sure you understand what it outputs. If you don’t understand what was generated, don’t include it or work to understand it before you include if it seems useful.
Make sure you approve of the aesthetics. Things like single responsibility, understanding the rest of the project is class based etc seems beyond the assistant’s ability at the moment.
Use its strengths, avoid the weaknesses. If I was making a completely new file and class, I started with the prompt to fill in the bulk and then fine tuned from there.
Overall, in its current state the assistant is a useful multiplier in certain situations but a bit of a frustration and hindrance in others. I’ll continue to use it and look forward to improvements regarding the assistants ability to gain further context when generating code. I’ll also work to understand if there are ways to improve my prompt writing.
Key Question – Can you use the assistant to make a program without knowing anything about programming?
I’ve been asked this a few times. From what I’ve seen, I think it can be done to an extent. If you’re making a simpler one file program that does a single task such as parsing a file and outputting xyz for example, then yes – that should be no problem at all.
However, as the project get bigger, the ability to develop the software without knowledge of programming becomes increasingly difficult because without having an underlying knowledge, there are difficulties in identifying rubbish code, structuring the project and debugging.