GitHub CoPilot Is Ruining Code Quality | Prime Reacts

Поділитися
Вставка
  • Опубліковано 30 лип 2024
  • Recorded live on twitch, GET IN
    / theprimeagen
    Become a backend engineer. Its my favorite site
    boot.dev/?promo=PRIMEYT
    This is also the best way to support me is to support yourself becoming a better backend engineer.
    GitClear PDF: www.gitclear.com/coding_on_co...
    MY MAIN YT CHANNEL: Has well edited engineering videos
    / theprimeagen
    Discord
    / discord
    Have something for me to read or react to?: / theprimeagenreact
    Kinesis Advantage 360: bit.ly/Prime-Kinesis
    Hey I am sponsored by Turso, an edge database. I think they are pretty neet. Give them a try for free and if you want you can get a decent amount off (the free tier is the best (better than planetscale or any other))
    turso.tech/deeznuts
  • Наука та технологія

КОМЕНТАРІ • 616

  • @ew8016
    @ew8016 5 місяців тому +410

    It was trained on an internet full of meh code

    • @handsanitizer2457
      @handsanitizer2457 5 місяців тому +6

      The phi model is much better at code vs copilot

    • @McZsh
      @McZsh 5 місяців тому +8

      This is why they push it to companies. To train it on high quality codebases. And to get backpropagation through developer adaptions.

    • @101Mant
      @101Mant 5 місяців тому +27

      There have been studies showing AI trained on AI output deteriorates rapidly in quality.
      The more it's used the more its own output goes into GitHub.

    • @sarjannarwan6896
      @sarjannarwan6896 5 місяців тому

      Companies have very strict data rules, enterprise solutions aren't trained on ​@@McZsh

    • @isaacingleby8771
      @isaacingleby8771 5 місяців тому +2

      ​@101Mant yeah was going to say the same thing

  • @RickGladwin
    @RickGladwin 5 місяців тому +421

    Me: Know what’s _not_ my favourite thing? Debugging other people’s code.
    Copilot: Hey, how would you like to spend most of your dev time debugging other people’s code?

    • @UrsaFrank
      @UrsaFrank 5 місяців тому +6

      truth

    • @adam7802
      @adam7802 5 місяців тому +1

      lol 😂

    • @magfal
      @magfal 5 місяців тому +24

      It's even worse it's synthesized from several people's code so it's not even consistent.

    • @shawnington
      @shawnington 5 місяців тому +6

      I love when you know what you are doing and its just suggesting clearly wrong things the entire time, and it's like stop trying to jbait me copilot!

    • @TehKarmalizer
      @TehKarmalizer 5 місяців тому +4

      @@shawningtoneven trying to use it to learn something totally new, you can catch obvious mistakes, and sometimes it will continue to repeat them ad nauseum.

  • @nexovec
    @nexovec 5 місяців тому +359

    "Github copilot better than junior"
    Dude who the f did you hire?

    • @felixjohnson3874
      @felixjohnson3874 5 місяців тому +110

      A 22 year old college graduate who just spent the latter half of their degree using Copilot and ChatGPT to complete their assignments.

    • @mariansalam
      @mariansalam 5 місяців тому

      @@felixjohnson3874more like 3 month boot camp grad with 2 more months of “self teaching (TM)”

    • @trappedcat3615
      @trappedcat3615 5 місяців тому

      ​​@@felixjohnson3874 That's one smart kid. Not wasting brain cells is a virtue. Should qualify for lead product manager.

    • @Kane0123
      @Kane0123 5 місяців тому +5

      @nexovec is 100% right.

    • @untalentedwebdev
      @untalentedwebdev 5 місяців тому +6

      me

  • @sdi87hhk
    @sdi87hhk 5 місяців тому +193

    we did it guys, we secured our future in the industry!

    • @MatichekYoutube
      @MatichekYoutube 5 місяців тому +2

      we will be replaced, it is just a matter of time. Coding will be done in visual composers and templates will be generated on demand

    • @rj7250a
      @rj7250a 5 місяців тому +9

      Cybetsecurity bros are partying.

    • @johnjimenez7692
      @johnjimenez7692 5 місяців тому

      @user-lw5wm2hg7s Ironically, it seems that marketing people will be the first in line to be replaced by AI. Both of them works on numbers and statistics anyway

    • @johnjimenez7692
      @johnjimenez7692 5 місяців тому

      @user-lw5wm2hg7s Ironically, marketing people might be the first in line to be replaced by AI. Both of them works on numbers and statistics anyway

    • @overloader7900
      @overloader7900 5 місяців тому +22

      @@MatichekUA-cam The difference between visual composers and text code is that a single visual node is ~equivalent to a single line of code. If visual was so much better, programmers would have used it themselves.

  • @NullMello
    @NullMello 5 місяців тому +70

    "You live in a bubble of 0 application users" 🔥🔥🔥

  • @rosmaraldimanagitalibi246
    @rosmaraldimanagitalibi246 5 місяців тому +146

    8:52 Don't worry about that, only like 40% of students in my class of just completed Computer Science education used ChatGPT and co-pilot exclusively to crawl through the education.

    • @jamespae7019
      @jamespae7019 5 місяців тому +36

      I suddenly feel very 'I guess I'm alright' about myself.

    • @7th_CAV_Trooper
      @7th_CAV_Trooper 5 місяців тому +47

      Imagine not loving CS enough to do your own work. Why even take CS classes if you're not interested in the subject?

    • @Capero20
      @Capero20 5 місяців тому +64

      @@7th_CAV_Trooper Money, the 6 fig salary as a junior myth has flooded CS with many unpassionate people sadly

    • @xavi_6767
      @xavi_6767 5 місяців тому +22

      ​@@7th_CAV_Trooper false hope and brain damage.
      The CS field is filled with 6 fig dreams.

    • @JohnKerbaugh
      @JohnKerbaugh 5 місяців тому +5

      iPad kids?

  • @kwisatzsawyer
    @kwisatzsawyer 5 місяців тому +178

    Got my first car around '95. It had a manual transmission. It was awesome, my car felt like an extension of my body. Bought my first car with an automatic transmission in 2012. While the experience wasn't as fun, it was still awesome because I no longer dreaded my 45m+ commute in stop and go traffic. Bought my first car with some AI self driving in 2022. It was awesome because after a long drive I didn't feel drained. I strongly think I'm a better AI supervisor because I have decades of experience driving without it. I worry about people getting into any skill or craft using automation without first understanding the older, manual processes. A few months ago I almost got into a head on collision in a wonky intersection. By the time I knew what had happened, I had already overridden the AI, swerved out of the path of the oncoming car, and came to a safe stop all on instinct. Don't think a teenager using my car would've been able to do the same. I think developers will see the same.

    • @jevandezande
      @jevandezande 5 місяців тому +16

      Absolutely! There is no replacement (yet) for years of reasoning through code. I use Copilot to help me with coding, but find that it occasionally takes me down the wrong path. My years of experience coding allow me to notice this and redirect it, were I less experienced, I would end up letting it write me code that can run, but has dangerous corner cases.

    • @Jmcgee1125
      @Jmcgee1125 5 місяців тому +8

      Exactly my thoughts on it. It's similar to the argument about resources during exams and stuff in schools: students are going to have those resources in the workplace, why not give them those during tests? Problem is now they rely on regurgitating from the resources and have no genuine knowledge for themselves. The resources act as a crutch, rather than a reference.
      An AI programming assistant is great when you know what you're looking for: it can hopefully get something close enough that you just need to tweak it a bit to make it work for your specific situation. But if it's wrong? Well, you better be able to tell.

    • @7th_CAV_Trooper
      @7th_CAV_Trooper 5 місяців тому +3

      Yeah, I think copilot is only useful for experts who can recognize the code as good or trash.

    • @BusinessWolf1
      @BusinessWolf1 5 місяців тому +5

      I think companies are gonna start forbidding copilot and AI for any non senior users. You are super right about experience.

    • @davidlamar4816
      @davidlamar4816 5 місяців тому +4

      ​@@BusinessWolf1Mine already does -- more for security reasons than bad code quality, though

  • @zzeck431
    @zzeck431 5 місяців тому +49

    If you work in a large legacy system, with not much documentation, and a ton of business rules enforced through copied and pasted code, and need to interact with it respecting existing rules, you do end up reading 10x more than you write, because no function or other abstraction sums up what you need done, separated from details of the most user facing part of the old system. (could be UI forms, could be http controllers etc). It takes even more reading to decide the least damaging place (or if you're lucky it feels like a search for the most appropriate place) to make changes.

    • @melski9205
      @melski9205 5 місяців тому +6

      Man, do you work with me?! Also, finding the best place to put your change to ensure the least amount of testing resources are needed... even more important than how it performs lol. got to love it.

    • @TehKarmalizer
      @TehKarmalizer 5 місяців тому

      @@melski9205 70% of the time it just goes in the nearest util file.

    • @devforfun5618
      @devforfun5618 5 місяців тому +1

      he also read that line wrong, ironically, it didnt say "people spend more time reading" it said "code spends more time being read", because multiple people will need to read that code

  • @retagainez
    @retagainez 5 місяців тому +57

    More CoPilot code means MORE NEED FOR ENTRY LEVEL JOBS TO FIX UNMAINTAINABLE CODE PROBLEMS!! WOO!!

    • @starmechlx
      @starmechlx 5 місяців тому +12

      Job listing: Junior Dev Position for helping fix unmaintainable code problem! Experience requirement: 6 years

    • @gloowacz
      @gloowacz 4 місяці тому

      @@starmechlxPrOmPt EnGiNeEr

  • @woolfel
    @woolfel 5 місяців тому +23

    I work in consulting world and I spent 90% of my time reading code. On a good day, I might spend 3 productive hours coding if there isn't a ton of meetings. If there's 2-4 meetings that day, I might get 1 hour to code. More important than writing code is making code easy to maintain and well documented.

  • @bogdyee
    @bogdyee 5 місяців тому +20

    When AI tools get better, less people understand what they are doing when they use it. Sounds like a catastrophe waiting to a happen.

    • @abdelrahmankhalil
      @abdelrahmankhalil 5 місяців тому +1

      Sounds like a good opportunity to shine

    • @rudypieplenbosch6752
      @rudypieplenbosch6752 4 місяці тому +2

      Exactly, I have seen someone demonstrating generating a spectrogram to find some audio anomaly, instead of analysing the spectrogram's values in a normal way and come to some conclusion, he passed the image through a Convolutional neural network (analysing pixels) and tries to explain how great his solution was.... he has no clue what he is doing, I'm afraid we will see more of these "solutions" in the future..

  • @jjfuentes6535
    @jjfuentes6535 5 місяців тому +80

    "I hate to break this to you but you live in a bubble of zero user applications." 12:15
    Best comment

    • @cherry-55
      @cherry-55 5 місяців тому +2

      facts, cause most projects are legacy, be it 20 year legacy or 6 month legacy (when vite was not popular yet) :)

  • @swannie1503
    @swannie1503 5 місяців тому +80

    17:07 For every line of code written at my office at least 2 people need to read it during review. Then an additional 2 people need to read it for testing and review. So I kinda believe that in general a lot more time is spent on reading code compared to writing it.

    • @BusinessWolf1
      @BusinessWolf1 5 місяців тому +20

      You're right but there's a caveat. A lot more time is spent thinking about code than reading or writing it.

    • @justinarmijo5958
      @justinarmijo5958 5 місяців тому +8

      Yeah, and I'd be surprised if you didn't re-read your code and the surrounding code it interacts with as you're writing. Maybe 10 to 1 is too high, but it is undeniable that you read more than you write.

    • @ConernicusRex
      @ConernicusRex 5 місяців тому +2

      No, two people need to read every line. Not two readers for every line. That’s 200 reviewers for 100 lines of code. It’s still just 2.

    • @redpepper74
      @redpepper74 5 місяців тому

      @@ConernicusRexOk but have you considered they might be building voyager 3?

    • @lcarsos
      @lcarsos 5 місяців тому +1

      so nobody puts an LGTM on code reviews? Nobody reads code. Nobody spends time thinking "what if this implementation is wrong?" or "what if I have to maintain this code in 6 months, when the requirements change?" Doesn't matter if your branch protections requires 4 code reviewers and an affidavit from management that this code is free and clean of bugs.

  • @garanceadrosehn9691
    @garanceadrosehn9691 5 місяців тому +23

    Writing code vs reading code: When I'm in the middle of developing something, I can write hundreds of lines a day. That does not happen often. But then I have to come back to that code, say a month later, and need to fix some bug. In that situation I'll spend an hour or two reading code (and maybe writing a bunch of _printf_ commands to figure out the edge-cases), and at the end of the day I'll write maybe 10 lines of code. The bug fix was a *lot* of reading and relatively little writing. And the nature of my job is I'll spend much more of my time fixing bugs than writing brand new code.

  • @n4bb12
    @n4bb12 5 місяців тому +13

    Sometimes, it's burning obvious what you're about to write. Sometimes, nobody except you knows what you're about to write. Based on this, Copilot's suggestion will be somewhere in the range of convenient to not at all useful. As long as the obvious lines are frequent and as long as reading a suggestion is faster than typing it, Copilot is useful. If you're a zombie and you just complete everything, you have a problem.

  • @KayOScode
    @KayOScode 5 місяців тому +11

    I’d like to mention is that for me, churn is much higher at the start of a project when I haven’t established the patterns I’d like to use. Often I’ll implement things one way, then realize it won’t fully fit my requirements, so I refactor. As a project matures, the established patterns have proven effective, and existing code doesn’t need to be changed to fit new ones as frequently. So maybe there are just more new projects entering the GitHub space causing an increase in churn that’s probably typical of new projects

  • @Evilanious
    @Evilanious 5 місяців тому +8

    As a learner AI mainly serves a the role of docs + stack overflow. It immediately gives an answer without belittling me and it knows utility functions off-hand that I didn't know exist or couldn't find. I don't let it write code that I don't understand. If it does I either delete it or look up whatever function I don't understand. It can also explain what's wrong with my code. I feel the follow up is important here. If you ask questions until your problem is resolved it's a crutch that hampers learning. If you prompt it until you understand it speeds along learning.

    • @Muskar2
      @Muskar2 5 місяців тому

      Not my experience with CoPilot in my limited time using it, but my exp with ChatGPT-4 is close to what you said. Albeit I don't think it teaches very well - it often hallucinates ideas that fit your bias, rather than actually teach you valuable insights like a senior could (or tinkering with debugger or reading good documentation). It's very dogmatic and can often waste your time leading you astray - and waste case let your problem solving skills become rusty. Mind you, so can SO very often. With experience, I've found SO to be an incredibly unreliable source except for quick help with a poor library needed for prototyping in something terrible like Android.

    • @devforfun5618
      @devforfun5618 5 місяців тому

      yeah i think the most helpfull tool i would need is something where i say the language im using, and what im trying to do and it just lists the libraries i need to import

    • @Muskar2
      @Muskar2 5 місяців тому +1

      I've never had an AI teach me something above college-level. I tried, but I simply haven't been able to make it useful. Maybe I'm a bad "prompt engineer", but I just don't see how it can come close to replacing reading real documentation and mentorship from real experts. I mostly use it for boilerplate stuff.

  • @the_derpler
    @the_derpler 5 місяців тому +8

    Sadly I am in the season of "spend hours reading some guys massive project to find one weird bug and then make a 1 line change." I hope to get back to adding features soon because it is more satisfying for me.

  • @bcfuerst
    @bcfuerst 5 місяців тому +8

    I am a TA for for software development for bussines informatics students and the quality of assignment submissions has skyrocketed while the exam quality has become abysmal. Copilot is a real hazard when yo uare learning the basics. The stuff we teach goes up to basic patterns in Java so it's pretty much only the ground work you need to later be able to read code. You should be able to produce a simple Java class, some loops etc. without having to resort to pseudo code or reading anything at all will be much more of a struggle.
    AI won't replace senior devs in quite some time but for juniors and beginners it is a real danger. Not only in terms of employment opportunities but also in when it comes to learning the fundamental skills.

    • @nickwoodward819
      @nickwoodward819 5 місяців тому

      Aren't you saying here that it's not good enough to teach but it is good enough to replace junior devs?
      Not sure both can be true. Why are we so quick to assume LLMs can replace devs? Devs who get fired, sure...

    • @cameron7374
      @cameron7374 5 місяців тому

      @@nickwoodward819 Having a tool do a thing for you doesn't mean you also learn how to do it yourself.
      A calculator is great at replacing someone whose main task was crunching numbers. It is awful at teaching someone how to do that number crunching in their head.
      Similarly an AI might be great at comprehending and working on simple assignment code for you, but not good at teaching you how to do so yourself. And you'll need those basic skills once you work on code that's too complex for the AI to handle.

    • @nickwoodward819
      @nickwoodward819 5 місяців тому

      ​@@cameron7374 Lucky then that I didn't say that :)
      Like you said, they're good tools - I never said they weren't. But ultimately they can't teach juniors for the exact same reason they aren't good enough to be juniors: They're pretty rigid, frequently wrong and need constant supervision. Granted that's *similar* to a junior, but not the same. For some reason we've been superficially wow'd into thinking otherwise.

  • @bepamungkas
    @bepamungkas 5 місяців тому +6

    That "55%" faster is somewhat true to me although I'd say only for specific case. For most case, Copilot autocomplete felt like distraction because it infer too much context that might not available at the time of us writing the code.
    One way that's valid (without even considering typing speed) is that for some intermediate/ common algo, Copilot could "feed" you a good boilerplate based on publicly available implementations. E.g I couldn't remember imperative detail of some case-specific quicksort variant (quickselect, mo3, pivot+cache) but with a proper hinting I could get some starting point to work with.
    The tricky part, however, is that if you don't really understand the underlying algo you might end up botched the implementation.

    • @jkhsjdhjs
      @jkhsjdhjs 4 місяці тому

      The "55% faster" number is actually not really representative. This number is based on a short study where people were asked to implement an HTTP server in JavaScript. The group with AI assistance completed this task 55% faster. arxiv.org/pdf/2302.06590.pdf

  • @magfal
    @magfal 5 місяців тому +21

    AI assitance vas so far been an accellerated technical debt generator in my experience.

  • @neko6
    @neko6 5 місяців тому +3

    We definitely read much more code than we write, because
    1. Most work is around existing code, e.g. bug fixes, writing tests, small changes in behavior, refactors, enhacements (e.g adding a new field to an API)
    2. Before adding new code we have to look at existing code for reference, or at the minimum find the right place for our code
    3. In any reasonable professional context (job or open source) someone has to review the code we wrote - this alone means half our code interaction is spent reading
    Consider a team setting where half the work is maintenance and six devs have to review all code submitted just to stay on top of their team codebase, that's already over 90% reading

  • @azrielsatan8693
    @azrielsatan8693 5 місяців тому +4

    16:23 My hands shake a lot so being able to tab just to complete the sentience I was already going to type is really useful.

  • @exoZelia
    @exoZelia 5 місяців тому +2

    As a general rule, statistics on any company's sales page shouldn't be taken seriously, especially when one of them is an abstract thing like "fulfilled"

  • @shaunpatrick8345
    @shaunpatrick8345 5 місяців тому +3

    Am I right to parse "helps you write code 50% faster" as "makes you think half as much"?

  • @robgrainger5314
    @robgrainger5314 5 місяців тому +4

    Another confounding factor is that over the time period in question Covid happened. A lot of devs would have changed to work from home. It may be the case that junior devs who would ask another dev questions weren't able to as easily, so were more likely to check in code and ask someone to look over it or for other advice.

  • @qeqsiquemechanical9041
    @qeqsiquemechanical9041 5 місяців тому +188

    who would've thought that stealing code from the web and automating a plagiarism bot would result in garbage code, amiright? /s
    modern techbro world is truly backwards 😂

    • @yds6268
      @yds6268 5 місяців тому +21

      Thank you. "Plagiarism bot" is exactly the term I've been looking for to describe the modern "generative AI"

    • @matt-dx1jo
      @matt-dx1jo 5 місяців тому +6

      glad that all coders only write their own code

    • @kevgoeswoof
      @kevgoeswoof 5 місяців тому +11

      ​@@matt-dx1jo At least Stack Overflow has a voting system where you can downvote stupid answers. Copilot doesn't.

    • @thomassynths
      @thomassynths 5 місяців тому +13

      "stealing". Despite basically all open source licenses prior to 2023 permitting it. Despite highly transformative usage of the data. Despite it being explicitly legal in countries like Japan. Etc.

    • @felixjohnson3874
      @felixjohnson3874 5 місяців тому

      You're only getting a pass on calling it "stealing" because it's copilot which *_does,_* for some reason, have a memory of its training data. Your above water, but not by much.

  • @teamadostamine9657
    @teamadostamine9657 5 місяців тому +1

    So, some time ago, I read a blog or somerhong that said that when you download vscode from the "installer" you implicitly accept to share some data with vscode while if you build it from the open source repo, there is no such data gathering. Dont know if it was rlly true but seems to kinda make sens ?

    • @bepamungkas
      @bepamungkas 5 місяців тому +1

      Yes, telemetry is the sole reason we have VSCodium as "clean" alternate build. Even the name is a hint (homage to Chrome vs Chromium that strip Google's telemetry as much as possible).
      You can disable extended telemetry in settings. But I can't remember whether it stop all telemetry or strill send context-free data.

    • @XxZeldaxXXxLinkxX
      @XxZeldaxXXxLinkxX 5 місяців тому

      Classic if something is free (and not FOSS) then you're the product classic

  • @JohnTube2K
    @JohnTube2K 4 місяці тому

    just subscribed after watching a few of your videos. very entertaining and informative. long time tech geek here

  • @todd.mitchell
    @todd.mitchell 4 місяці тому +1

    I describe Copilot as a senior dev with an eidetic memory who is an outstanding teammate as long as he's sober, but you gotta watch it when he's on the sauce.

  • @MorningNapalm
    @MorningNapalm 3 місяці тому

    Why does Prime always select text from the second-last character to the second character? Is there some issue with selecting it all?

  • @bartech101
    @bartech101 5 місяців тому +2

    Not being DRY has consequaces, especially in js and CSS shipped to the client, but not only, also server side can be affected at scale, more code to parse, more files to read from disk. That said as you stated many times being too DRY is the issue of premature bad abstractions.

  • @Selendeki
    @Selendeki 5 місяців тому +17

    Copilot saved me a lot of time when I was writing opcodes for my emulator. But, I'll be honest, it fucking blows for anything else. I've never seen a useful solution, and it needed a ton of context and handholding to be useful for the opcodes. GPT-4 on the other hand is extremely useful.

    • @DominikGuzowski
      @DominikGuzowski 5 місяців тому +2

      literally my experience too. usually I write first pattern of something that just requires repetition to some degree and let it finish that, but even that fails often. (like switch statements on enums for example). it has almost never given a solution that is correct and does what I want it to unless it's some to String function that's there mainly for debugging

    • @Indonesia_Emas_
      @Indonesia_Emas_ 5 місяців тому

      yeah GPT is badass, it even understand contex more better than google's gemini (previously named bard), both use transformer model but i feel gpt can undertand better than google one. the only downside of its free version is its only know knowledge of desember 2021 below if i remember correctly, where google one has up to date information because he has many data because he is the most popular search engine but also he will need to filter the data to only use the high quality one but i dont know if google do it or not.

  • @triplea657aaa
    @triplea657aaa 5 місяців тому +4

    Copilot is pretty bad outside of boilerplate code, but i was pleasantly surprised by GPT 4 last night. I still had to make some suggestions which significantly improved the code quality, but it was definitely faster than writing it myself.

  • @gladoseus
    @gladoseus 5 місяців тому +2

    I get so used to prime reacts I can't react to anything by myself anymore.

  • @cosmic3689
    @cosmic3689 5 місяців тому +1

    pearson correlation coeff is between -1 and 1, so 0.98 is an insane correlation if there's enough (reliable) data. basically means increasing the % of copilot use increases the amount of mistake code, in almost a straight line.
    it doesn't say how steep that line is though, just that e.g. the median copilot usage data point is also (very close to) the median mistake code point. the actual increase could be tiny, and again its correlation not causation, or whatever.

  • @ObsidianJai
    @ObsidianJai 5 місяців тому +1

    As a web developer I really only use Copilot for basic frontend shit to quickly implement design ideas and build rough layouts. But %90 of the generated code never makes production.

  • @brandonpearman9218
    @brandonpearman9218 5 місяців тому +1

    the read write ratio depends on the code base. tools, greenfield, etc is mostly writing. legacy applications that has turned into a big ball of mud and the devs are new is mostly reading.

  • @abeidiot
    @abeidiot 5 місяців тому +2

    It feels like something I finally have an advantage on. People seem to be trying to use it the wrong way. My code is still my code, just accelerated in being complete

  • @furukura
    @furukura 5 місяців тому

    is there any influence from employee churn at tech companies? I see news about swaths of people getting fired, could that not have a similar impact? Perhaps someone can explain if this is a factor.

  • @somenameidk5278
    @somenameidk5278 5 місяців тому +4

    I can cartainly relate to the reading 10x more code thing, at least when i do Don't Starve Togther modding, which as a hobby coder is probably the closest thing to working on a big project i've done. Certainly tons of legacy code, with the bonus that you can't even modify the code directly and also no debugger, just a dev console to type print(whatever) into.

  • @ChrisTbilisi
    @ChrisTbilisi 5 місяців тому +1

    Copilot is like Monsanto insisting you destroy your heirloom seeds and farm with their GMO. Duh.

  • @MattMcQueen1
    @MattMcQueen1 5 місяців тому +6

    Best course I ever did in my programming journey was a touchtyping course.

  • @Exilum
    @Exilum 5 місяців тому +4

    I am doing some CS studies rn, because I needed a line on my resume to actually get a dev job in France, and I swear I am worried about my fellow students.
    I haven't spoken a word about copilot due to this worry, and I still see some of them using chat gpt, and I wonder if they'll ever even get half the knowledge and competency they're supposed to acquire.
    To top it off, they're about 4 years younger than me, and they're the generation that got not only the new highschool reform (thus went through a fresh, unproved system) but also covid during their highschool time.
    Some of them are smart, capable of things, but I don't know if they'll reach half of their capacities.
    16:40 One of the first thing I told them was to train to type faster, I don't think they did even a minute, it's been around 6 months.

    • @dreri3738
      @dreri3738 5 місяців тому

      I feel very similarly, every day in CS classes I'm overwhelmed by amount of people who so openly talk how their code was all AI generated. I had a group partner on a lab where we were doing WiFi socket programming and he generated code for the server in few seconds during the class, while it took me dozen of minutes to write code for the client. Then we spent an hour debugging his code to make it work, while it became clear he got no idea how sockets work. All he tried to do was to paste code errors into ChatGPT as well while I went looking for documentation. It makes me seriously worried about IT field.

  • @kevinfleischer2049
    @kevinfleischer2049 5 місяців тому +1

    Uncle Bob said that the influx of new developers was for years so, that the number of devs doubled every 5 years. So the experience level of devs is in average 2,5 years - a new "Senior".
    This, and the quick change of tools/technologies is constantly eating away on any mastery that the older devs are building up.
    Btw: Yes, you also read more code than you write. Everytime you go and check what a method you call actually does, or how something handles something or where to place a new piece of code. All that time you are reading the existing code. Still you feel like actively editing/adding code, but mostly you need to find the right spots. So clear/clean and understandable code is important.

  • @Griffolion0
    @Griffolion0 5 місяців тому +2

    The CS graduates coming out of colleges in the coming years are going to be a disaster.

  • @flogginga_dead_horse4022
    @flogginga_dead_horse4022 5 місяців тому +1

    I have found it great for writing C#/.Net code. Sometimes needs tweaks but saves a huge amount of typing and boilerplate.

  • @Kabodanki
    @Kabodanki 5 місяців тому +1

    My colleague are pushing broken code, the pipelines failed, and they ask us for help. What the F

  • @griof
    @griof 5 місяців тому +2

    I think that a recent paper has shown that LLM suffer from fix point problems: i.e. a LLM is less accurate when its input data was generated with an other LLM. So as internet gets full of non-human text, this text is used to feed LLMs which performance is worse than before... I am trying to find the reference.

    • @AlexB-px3lc
      @AlexB-px3lc 5 місяців тому

      This is the story about how many bears soviets launched into the space. That llms producing disinformation faster that human can correct it.

  • @peacefuldragonn
    @peacefuldragonn 5 місяців тому +2

    This and chat gpt 4 only makes me write my code 100% slower. The amount of time I have spent explaining the problem to it, with examples, and then cross checking it vs the documentation is actually more than what I could have looked up myself. It sometimes adds unexplained complexicity and doesn't even consider nulls in data unless I tell it to consider that while making code snippets

  • @JohnDoe-sq5nv
    @JohnDoe-sq5nv 5 місяців тому +4

    I often find myself agreeing more with blue Theo than with yellow Theo. This video is no exception.

  • @awanen
    @awanen 5 місяців тому

    I didn't know Ninja made a guest appearance. I appreciate this. Thank you Ninja

  • @SvetlinNikolovPhx
    @SvetlinNikolovPhx 4 місяці тому

    Possible reasons you read 10x more code than writing:
    - Bad modularity - no matter what you change, even the most distant and seemingly unrelated parts of a big project could break because of it
    - You are using a game engine or some other huge proprietary piece of code. Some game companies even have teams to write the tools everyone else uses and sometimes they never pick back any bugfixes, so every team around the world keeps fixing the same bugs again and again.
    - You've joined a very old product and you need to learn a lot about it before you can extend it. The older it is, the higher the changes the other devs already left the company, or maybe even already died by natural causes. Also, the older it is, the more bugs you inherit.
    - Even a newer project can be mismanaged to such an extent, that it's a mess and nothing can be added without needing to fix half the project first

  • @klnmn3722
    @klnmn3722 5 місяців тому +1

    16:42 I think the quote is about the code that’s written, not the person writing it. I can easily imagine if you write a new feature, you spent 90%+ of your time writing rather than reading. But over the lifetime of the code itself, I would totally believe 10x more hours were spent *by others* reading over it as needed.

  • @joshuaevans4301
    @joshuaevans4301 5 місяців тому +1

    As far as percentage of time reading vs writing code... It's just a difference of style! When I code, I will think very deeply about what I'm doing and not really start writing until I know pretty much exactly what I am going to do - then it takes like, 2 seconds to actually write out (assuming all my assumptions are correct, which they often aren't 😉). While others (like yourself, no doubt) are more about getting in and writing code as soon as possible to experiment and tinker and find the solution - I have a colleague who is the exact same way. It's a whole spectrum, I imagine
    This is a good thing, though! Different styles of coding are better suited to different kinds of tasks and having a diversity of coding styles available to a team will better ensure they are always best suited to deal with whatever issues might come up :)

  • @thekinoreview1515
    @thekinoreview1515 5 місяців тому +1

    My fav thing about copilot is not the code. I'm writing a game mod and sometimes it will just know IDs for mobs and NPCs, saving me writing out a long list where I have to look up each and every one. If someone made a copilot which only autocompleted constants from various games I would be the happiest man alive.

  • @slavicradko9846
    @slavicradko9846 5 місяців тому +2

    17:00 - "code is being 10x more read than written" is not about you, it's about code. If you write code that lives for 10 years, then people read this code 10 years, but it is written only once. If your code lives for 30 years oh boy people will read it 1million more times than it is written.

  • @GackFinder
    @GackFinder 5 місяців тому +1

    Remember just a few months ago when devs without any understanding of AI thought AI would take their dev jobs and I was like the only person in the world that said the opposite because AI mostly produces trash because there's no ACTUAL intelligence in there?

  • @Nellak2011
    @Nellak2011 5 місяців тому +2

    I am in College right now and they heavily advertise copilot and how it is free to use.
    These brain dead kids in class don't know how to code, and they think they know something when they make a half baked website with copilot.
    On the software engineering project, my team was the only one to actually deliver on what we promised. The reason why is because I have been coding since 2017. These kids probably started coding last year. 😂

  • @westoncox910
    @westoncox910 5 місяців тому

    “What do you do dog? Look at your cursor to blink until the GitHub Copilot results come in?” Lmfaooo

  • @JoelJosephReji
    @JoelJosephReji 5 місяців тому +1

    The treesitter thing that Prime said is basically plagarism checker algorithms, right?

  • @thekwoka4707
    @thekwoka4707 5 місяців тому +2

    I agree that the study doesn't seem to explore what other pressures exist around the same time. It just points to it being AI as the issue.

  • @br3nto
    @br3nto 5 місяців тому

    3:59 is code changing more frequently because it’s wrong and needs fixing or because it’s not easier to iterate and change??

    • @br3nto
      @br3nto 5 місяців тому

      27:04 it could also be a more iterative paradigm is taking hold.

  • @adaptivedeveloper
    @adaptivedeveloper 5 місяців тому

    Lol. I feel you. My team is always scared when I type and forced limit of the size of PRs I produce before they just approve it on a leap of faith xD

  • @ConernicusRex
    @ConernicusRex 5 місяців тому +1

    None of these tools write usable code. It’s making a huge gulf between entry level guys who can’t code much at all and working professionals.

  • @SyntaxSeed
    @SyntaxSeed 5 місяців тому +1

    Keep in mind, we are in the honeymoon period where the people using & overseeing the code that Copilot is generating, are usually competent & experienced devs themselves. They can catch the bugs & security problems because they recognize them.
    What happens in 1 generation when we have vastly fewer senior devs who understand code in a deep way?
    And what happens when Copilot trains on older copilot generated code?
    Quality is going to degrade over time & the ability to debug & catch mess in review will be a fading skill. Yikes.

    • @Indonesia_Emas_
      @Indonesia_Emas_ 5 місяців тому

      then we should create an open source ai that only be trained with high quality code 😅😅😅

  • @user-yy1td9rf4f
    @user-yy1td9rf4f 5 місяців тому +4

    Was getting déjà vu watching this video, then I remembered Theo did a video on the same topic😅

    • @awtodor
      @awtodor 5 місяців тому

      The theo prime loop

  • @Thomas-sv6jr
    @Thomas-sv6jr 4 місяці тому +1

    I don't know how I stumbled upon this channel, but I am fascinated about this view into world of computers and math which I am both very bad at, but envy the skilled.
    I am curious as to how software translates to what hardware is actually doing. Like I am guessing all code translates to zero and one which zero and one means an open or closed circuit?

    • @umer_rs
      @umer_rs 3 місяці тому

      Code gets translated into cpu instructions, which are implemented by the cpu with 0s and 1s, as well as logic gates.

  • @RandomGeometryDashStuff
    @RandomGeometryDashStuff 5 місяців тому

    is that gradient in ↘️ corner just to waste ink?

  • @syriuszb8611
    @syriuszb8611 5 місяців тому +2

    The more copilot is used, the more code in github is made by copilot, so it learns on worse and worse data set, producing worse code and becoming worse with each cycle. At least there is a risk that this could happen.

  • @Mastahiro
    @Mastahiro 5 місяців тому +1

    From someone with 4yrs of exp, Copilot is very good at repetitive tasks like wiriting something similar to what you've already written (i.e. DB access layer of a program), it's also good at writing base documentation to build upon.
    For actual code it's: 5% amazing code, 10% serviceable, 20% a little bug in there that you won't notice until you've read it 10 times 50% not really what I want and 15% "go home you're drunk"

  • @jestempies
    @jestempies 4 місяці тому +1

    About the code being read 10x more than being written, imagine what percentage of code you change when you open a file. Sometimes it's going to be 100%, but usually it's going to be very little. You open a file to see what that function does. You open a file to add a line to it. I write a lot of code too, sometimes, but usually I'll be editing a file, not creating a file, and in those existing files I'll be scanning a lot of names and structure.

  • @josefpharma4714
    @josefpharma4714 5 місяців тому

    Btw:
    When using feature branches:
    Committing and pushing in small
    Steps happens with modifications of already pushed code.
    This could lead to false positive “churn” I guess.

  • @nickgotvyak5890
    @nickgotvyak5890 5 місяців тому

    I was trying to make a small thing yo automate a config format conversion and used bing ai assistant, which is basically co-pilot (it's even what they write when you ask it programming questions). I asked a question about Yaml class in a java lib and it was clear that it completely did not understand how that class worked.

  • @Heater-v1.0.0
    @Heater-v1.0.0 5 місяців тому

    Well, when I was contracting for two years on one huge project my whole was task go though hundreds of bug reports and fix the ones that were actually bugs. I spent orders of magnitude of time searching around and reading the code to figure out the best way to fix the bug than actually writing the code that was the fix. That's after having run the code and observed the symptoms. Only after all that time was I trusted to actually build new features for that thing.

  • @VudrokWolf
    @VudrokWolf 5 місяців тому +1

    To me, AI-assisted is like a drunk senior friend with a bit of bad memory but it is very good at reading and seeking references in documentation and reading large sets of output for debugging.

  • @voidvector
    @voidvector 4 місяці тому

    DRY should be a promotion process:
    * start by DRY in same file that use the logic
    * keep copy/paste until at least 3+ use cases
    * promote to DRY in a common file after enough files are using it
    * keep copy/paste between packages/modules/projects until at least 3+ distinct packages/modules/projects are using it
    * promote to DRY in importable packages/modules/projects after enough packages/modules/projects are using it
    * keep promoting through hierarchy (e.g. organization repo)

  • @TheHannelorian
    @TheHannelorian 5 місяців тому +1

    I'll spend days writing 1.5k new net lines and get a rubber stamp approval in like 30 seconds...how many shops out there actually budget for devs to do quality reviews? Cause the push for new features is constant from what I've done in 7 years as a dev.

  • @RealGrandFail
    @RealGrandFail 5 місяців тому +1

    As a student, I only used notepad and paper, no IDEs.

  • @thomasr22272
    @thomasr22272 5 місяців тому +2

    The future is looking sad for people learning to program imo. Im not that old but I remember learning to program 10 years ago by reading books and written tutorials online and it was amazing

    • @cameron7374
      @cameron7374 5 місяців тому

      Personally, I really dislike having to read learning material. Most of the time I'm not actually interested in the learning part itself, I'm interested in building stuff and having the skills I need for that.
      So if people are able to do that, I don't think it'll be all that bad.

  • @EmbeddedSorcery
    @EmbeddedSorcery 5 місяців тому

    lol a coworker just today told us (and the boss) that we should get Copilot because it's just so darn helpful. The part about junior developers made me laugh out loud because it makes so much more sense now.

  • @mahmoud1737
    @mahmoud1737 5 місяців тому +1

    when i first saw it in my second year college i was like that's good but untill i get enough experience to know what it is typing while on other hand a friend of mine was just installing anycool extensions and using copilot and when i asked him what's it doing answered no

  • @zivkobabz
    @zivkobabz 5 місяців тому +1

    Students where i live at least isn't allowed to use co-pilot while learning , whatever it would be. But then on bigger projects they're allowed to turn on co-pilot, also co-pilot not allowed during exams. So all it does it help them create bigger projects where i live which i think is kind of nice. Could be different at other schools of course.

    • @andresmartinezramos7513
      @andresmartinezramos7513 5 місяців тому +1

      A professor of mine who also teaches in the CS faculty told me that projects now are better than ever but people are eating shit in the exams at a rate never before seen. He believed it was because of AI assistance when doing projects.

    • @zivkobabz
      @zivkobabz 5 місяців тому

      @@andresmartinezramos7513 Interesting i would have thought it would help the students. Since you have to learn the basics and understand everything before you are allowed to use AI. We'll i guess you find out a lot of problems during a project where AI solves it for you. But honestly thought it helped with learning process not hurt it.

    • @andresmartinezramos7513
      @andresmartinezramos7513 5 місяців тому +1

      @@zivkobabz The thing is that he suspected that his students were using the AI without knowing the basics. There is nothing to stop them from using AI at home, but there is in an exam setting.

    • @zivkobabz
      @zivkobabz 5 місяців тому +1

      @@andresmartinezramos7513 Ah that is correct they could be cheating themselves on purpose, even if the teacher says it's going to hurt them if they use it for while learning basics.

  • @codecae2
    @codecae2 5 місяців тому

    I wonder how many BSL or GPL repos were scanned to train this stuff...

  • @Discount-Stonks
    @Discount-Stonks 5 місяців тому

    0:19 yesn’t - these sorts of papers should really have a DOI number that would outlive whatever medium it was distributed through and their corresponding URL, whether it be blog posts or PDFs

  • @calmhorizons
    @calmhorizons 5 місяців тому +2

    Today's crappy code is tomorrow's job security.

  • @w3dd1e
    @w3dd1e 5 місяців тому +2

    I us GitHub Co-Pilot but not for code. Only to write my Git Commit Messages. I hate that part.

  • @MarstonConner
    @MarstonConner 5 місяців тому

    Honestly, I use it for “advanced rubber ducking” at work. Maybe it generates some worth while code or boilerplate but ultimately I fall back to reading vendor docs or peeking the class. Sometimes it’s good for quickly summarizing your code in a comment…sometimes!

  • @andreilucasgoncalves1416
    @andreilucasgoncalves1416 5 місяців тому +1

    I started to learn go three days ago and Copilot in GO is amazing, in typescript it give you shit code all the time, but in GO is like the opposite.
    Perhaps is because GO code is usually very repetitive and simple

  • @Sam-qn4ly
    @Sam-qn4ly 5 місяців тому +2

    a boilerplate only setting would be nice

  • @FireStormOOO_
    @FireStormOOO_ 5 місяців тому

    As far as fulfillment, the thing that makes me want to stop and work on something else is consistently the most boring 20% of a project; either boilerplate or uninteresting glue that should've been a library function. Copilot does great with that (because I'm probably the 10,000th person to ask...), which is huge. Also does great if you need a minimum implementation of something unrelated to what you're working on to make things compile and run - copilot makes it cheap to slap some throwaway code there while you working that you fully know you're going to blow away later.

  • @ueberraschungstuete
    @ueberraschungstuete 5 місяців тому

    I would like to add to the discussion, that you might think Copilot code is good code when learning. And once you have learned wrong patterns is might be hard to get rid of them. Therefore for beginners I would suggest, that reading seeing well written code is really important.
    It's like the paper where they tested how many code from bad or outdated tutorials/stack overflow articles went into some project. Those multiply with each new developer seeking information.

  • @Gennys
    @Gennys 5 місяців тому +1

    No the 55% faster claim can easily be inferred from typing speed and how much code you're letting co-pilot write for you instead. That one's not hard at all. If they wanted to account how much less r&D or rewrites that number would probably be much higher actually.

  • @suede__
    @suede__ 5 місяців тому +1

    Our company has copilot and it's total garbage. Am I expecting incorrectly that it should recognize a function I have just written and auto complete it in the function I'm using it in? I've never had it successfully do that.

  • @MindBlowerWTF
    @MindBlowerWTF 5 місяців тому

    What was the bet with chat btw.?

  • @jefferymuter4659
    @jefferymuter4659 5 місяців тому

    I'm a Jr web dev. I use it for writing annoying things like css utility styles. But I generally turn it off as the time to do just enough, then wait, then check if its correct, then tab, I could've written it myself and not felt a weird limbo and forced decision of checking the accuracy.

  • @rossbagley9015
    @rossbagley9015 5 місяців тому

    It speeds up boilerplate, but it also speeds up producing all repeated code. Making it so easy to write repeated code is a serious downside.
    I hope that it doesn't take long to add first order refactoring assistance to extract common code and push back on copypasta, that will be a big improvement.

  • @makhmudjonjamoldinov3554
    @makhmudjonjamoldinov3554 5 місяців тому

    How come you are reading in light mode? Broo!?

  • @MartinsTalbergs
    @MartinsTalbergs 5 місяців тому

    Who did that to your hair? Hey, nobody touches my man!

  • @petrus4
    @petrus4 5 місяців тому +1

    Scrubs are using Copilot to produce bad code? I'm shocked, Prime! Shocked speechless! How could anyone possibly have anticipated such a thing?!