I trialed GitHub Copilot and used ChatGPT for a bit, but recently I found myself using them less and less.

I’ve found them valuable when doing something new(at least to me), but for most of my day-to-day it seems to have lost it’s luster.

  • Dave Copeland
    link
    fedilink
    English
    arrow-up
    3
    ·
    edit-2
    2 years ago

    I set up CoPilot with neovim and am using it on a few projects. The domain and architectural style of these projects isn’t common. Asking it to generate entire functions seems not very useful.

    But, when asked to either suggest the next line of code or complete a partially-typed line, it has been pretty useful if it is following a pattern established in the code already. Here are two examples:

    Testing:

    test "record creation" do
    
      record = create_record("Pat", "This is a description of Pat")
    
      expect(record.name).to eq("Pat") # I typed this
      expect(record.description).to eq("This is a description of Pat") # CoPilot suggested this
    end
    

    It’s pretty good at this part of it as long as there is a pattern

    Repetitive stuff based on common things:

    COLORS = [
      "red", # I typed this
      "orange", # CoPilot suggested this
      "yellow", # CoPilot suggests this after I accept the previous line
    
      # and so forth
    

    So, asking it to come up with something out of thin air is usually worthless, but it has been helpful at automating repetitive tasks that are somewhat small and not really places where a library or abstraction would be better.