Ask HN: Should I be using GitHub Copilot (and other AI Products)?

  • I felt similarly about using ChatGPT until a few months ago.

    I took some pride in having almost 20 years of (on-and-off) programming experience, I felt that it was one of my strengths as an older CS graduate student, and I didn't look forward to trading my traditional programming workflow for "prompt engineering." I also generally avoid adopting more complex tools because I think it can lead to spending more time figuring out the tools than using them to accomplish things (i.e. "yak shaving").

    But a few months ago my advisor showed me how other people are using ChatGPT to accelerate their work, like having a research assistant, and he basically said that we're falling behind if we're not using it too. Within a month of starting to use it this summer, I knew he was right. Tasks that would previously take me a week to do now take a day or even just an hour. I do worry that it's making me lazier in some cases, but I haven't stopped learning either. I mostly use the output of ChatGPT like I'd use example code from tutorials or StackOverflow; it's less copying-and-pasting exact code and more taking the examples and rewriting or modifying them to do exactly what I want.

    The ability to get instant answers to my questions when I don't understand how something works, or when I'm debugging / troubleshooting, has absolutely increased my learning rather than stunting it.

  • I use copilot all the time, it’s really useful, but I do also think it’s overhyped a bit.

    It’s quite good at boilerplate, simple functions and repetitive things (let’s say you need to write all fields of a struct).

    Another scenario where I’ve found it useful is writing in a language I don’t know well. It will write a lot of the basic stuff for you, which can really speed things up. Even in languages I know well it has occasionally shown me things I wasn’t aware of. So in my experience I’ve learned more, quicker, using using copilot.

    It’s not going to write anything complex and it will hallucinate and write bs code somewhat frequently, other times it writes inefficient code, so I still have to read docs. It also lacks the full context of the project limiting its utility. It’s not going to build your project for you.

    That said it’s an amazing tool, like a really powerful autocomplete.

    I would recommend to try it, that’s the best way to see for yourself if it brings you anything. I was skeptical as well, tried it, and have been using it for months.

  • I have been programming for almost 30 years. I am extremely delighted that with one line of clear prompting I can generate 10+ lines of completely accurate code. It is very good at replicating patterns. IMO, this is the greatest advance in IDEs since intellisense. I estimate I am about 2x faster at programming than before. I would never want to go back to a world without it. Why not use it? Because all of your code has to go over the internet to a large corp who promises not to use your software against you? That risk will be solved over time with open-source, local LLMs.

  • IMO co pilot has been great for writing boilerplate code much faster. But GPT4 has saved me much more time, it’s much better at generating code, debugging problems, bouncing ideas off of etc.

  • Note that if you do consulting/project work for other companies, you have to be careful how you use Copilot or other cloud-based AI services, due to NDAs regarding the contents of your work.