3 Problems with AI-Generated Code
Key Takeaways
The video discusses the problems with AI-generated code, including its tendency to be buggy, insecure, and unreliable, and highlights the importance of understanding the reasoning behind code and investing in learning fundamentals, with tools such as GitHub co-pilot and YouTube Premium mentioned
Full Transcript
a while back some big Tech leaders made some bold claims about AI Jensen hang the CEO of Nvidia actually said that kids wouldn't even need to learn to code anymore because according to him everyone in the world is now a programmer it is our job to create Computing technology such that nobody has to program everybody in the world is now a programmer this is the miracle this is the miracle of artificial intelligence yeah he said everyone in the world is now a program and then there is emad mushak CEO of stability AI who said that in just 5 years there wouldn't be any human programmers left sounds wild right but here's the reality AI isn't exactly living up to that hype instead of taking over programming it's causing a whole new set of issues studies are showing that AI generated code is often buggy insecure and honestly not very reliable in this video we're going to dive into to why this AI hype bubble might be popping we'll check out some numbers talk about why certain AI companies might be overvalued and see why some investors are starting to lose that initial excitement if you actually had to talk about the thing he selling today you go well it's a calculator of sorts well it doesn't always work but when it does it's sort of good so what happened how did we go from AI is going to replace programmers to AI is making things more complicated let's look at the research let's start with a recent study by up level that looks at the reality of AI in coding they studied over 800 developers using AI coding tools like GitHub co-pilot and the results not exactly what you would expect first they found that developers using AI saw a 41% increase in bugs yeah while AI might help you write code faster it's also adding a lot more errors meaning more time spent fixing those errors so in instead of spitting things up AI can actually slow you down in the end and even though you would think that AI tools would help developers complete tasks faster the study didn't show any real improvements in task completion or issue resolution basically ai's Promises of efficiency don't quite hold up also developers using these tools didn't feel any less stressed or burned out their workload and stress levels stayed pretty much the same even though AI was supposed to take over some of those rep competitive tasks so yeah it sounds great in theory but in practice not so much next up let's talk about a study from get clear they analyzed millions of lines of code to see how AI tools actually affect developer productivity if you thought AI was making things more efficient think again one big takeaway was that AI generated code has a 39% higher churn rate meaning a lot of it gets Rewritten or removed shortly after it's created so nearly 40% of that AI generated code ends up being redone which is basically waste of time and that's not all this study found about 11% more duplicated code when developers used AI tools instead of generating efficient reusable code AI tends to spit out new code unnecessarily which just clutters your code base now duplicated code isn't just ugly it can also introduce bugs in multiple places and make your software harder to debug and scale so yeah AI might help you pump out code faster but it also creates a ton of instability more churn more duplicated code it all adds up to less Reliable Software and more effort spent maintaining a clean code base in the end it's more work not less not exactly the game changer we were promised right oh it it thinks that BofA is a real protocol and it's like I don't know how to do that hey I wanted to tell you about something that's been improving my YouTube experience a ton and that's YouTube premium have you ever been watching a video and at the best part and ad pops up well YouTube premium gets rid of that you can watch all your favorite content without a single ad I've been using YouTube premium for the past few years and it's the best experience especially when I'm in bed I love listening to podcasts and I hate those annoying ads popping up but thanks to YouTube premium I never get them but there's more with YouTube premium you can also download your favorite videos this is great if you're traveling or don't have access to high-speed internet you can download videos ahead of time and watch them offline another great benefit is that you can keep your videos playing in the background when you switch to other apps ever been watching a video and then you get a text from a friend when you switch to the other app the video usually stops right with YouTube premium your videos keep playing in the background while you switch to other apps so how do you get all these perks YouTube premium is a paid monthly subscription service you can pay a very low monthly fee and get all these benefits no commitments you can cancel anytime but here's the best part if you subscribe through the link in the description or the banner in this video you will get two months free and I may earn a commission you will not only get an amazing atree experience but you will also support my channel so if you want 2 months of YouTube premium for free subscribe using the link in the description now let's talk about security because when you're writing code it's not just about getting it done it's about getting it right and this is where AI coding assistants start to fall short a study from Stanford found that the developers using an AI assistant wrote significantly less secure code than those working without one what's worse is that developers who had access to an AI assistant were actually more likely to believe their code was Secure even when it wasn't this suggests that AI tools might be giving developers a false sense of confidence AI generated code often looks right which makes developers trust it too easily and this false sense of security is a big deal in fields like healthcare Finance or infrastructure places where security really can't be compromised now don't get me wrong I'm not saying AI is useless or we should stop using it as a developer I can tell you that AI has definitely boosted my productivity I use it all the time for repetitive tasks it's great for generating boilerplate code like the stuff that nobody wants to write from scratch it's great for translating code from one language to another or quickly throwing together a prototype so yes AI is a powerful tool but it's just that a to the future of coding is an AI replacing developers it's developers working with AI anyone telling you otherwise probably has never built real enterprise software in their life or they're trying to sell you something look coding isn't even the hardest part of being a software engineer we spend a ton of time in meetings Gathering requirements setting up environments and digging through old code bases to understand what's really going on coding is only one piece of the puzzle so think of AI like spell checker for writers it makes us more productive but it's not replacing us anytime soon if ever and this brings us to a big takeaway education AI might help with some coding but you still need to understand what's going on behind the scenes you can just trust it blindly companies have learned this the hard way AI can give you code that looks great at first but if you don't fully understand it you're opening the door to bugs instability and security risks on top of that just copy pasting AI generated code can lead to technical death code that's so messy and complex that no one can work with without breaking something that's why in my courses I focus on teaching you to write clean maintainable code that solves real problems I don't just show you what to write I explain why we are doing it this way knowing the reasoning behind your code is key to becoming a great developer someone who can create software that is functional scalable and sustainable in the long run so AI is awesome and it can definitely spit things up but don't use it blindly don't skip learning the fundamentals best practices or the reasoning behind your code just because AI can generate it for you because here's the truth if you don't understand what your code is doing you're not making yourself more valuable you're actually putting yourself at risk of being left behind you won't lose your job to AI you will lose it to the developer who has solid programming skills and knows how to use AI to be even better AI is here to help not to replace us so invest in yourself learn the fundamentals understand the details and then use AI to level up if you found this video helpful please like And subscribe for more coding advice
Original Description
AI was supposed to change coding forever, but it's creating new problems no one saw coming. Let’s break down what this means for developers and why the AI hype bubble might be popping.
Get 2 month's of YouTube Premium Free: youtube.com/premium?cc=programmingwithmosh&utm_campaign=ytpcreator
Monthly paid subscription. Price per month varies. First 2 months free. Terms apply. Cancel anytime. If you subscribe through the link in this post or the banner appearing in this video, I may get a commission.
🔗 Related Videos:
https://youtu.be/4gX44uyGSHo?si=oMV6zLiFlGLEnt-Z
https://youtu.be/HXH4yu227EQ?si=4-f1ba7v6PRCQ6lz
https://youtu.be/XKkoVpupYdw?si=IeiBMEjtPT3k7lii
✋ Stay connected:
- Twitter: https://twitter.com/moshhamedani
- Facebook: https://www.facebook.com/programmingwithmosh/
- Instagram: https://www.instagram.com/codewithmosh.official/
- LinkedIn: https://www.linkedin.com/school/codewithmosh/
#ai #coding #programming
Watch on YouTube ↗
(saves to browser)
Sign in to unlock AI tutor explanation · ⚡30
Playlist
Uploads from Programming with Mosh · Programming with Mosh · 0 of 60
← Previous
Next →
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
6 Visual Studio Tips to Increase Your Productivity | Mosh
Programming with Mosh
Visual Studio Keyboard Shortcuts that Speed Up Debugging Applications | Mosh
Programming with Mosh
Backbone.js Tutorial Part 2 - Backbone.js Models: Working with Model Attributes
Programming with Mosh
Backbone.js Tutorial Part 3 - Backbone.js Models: Model Validation
Programming with Mosh
Backbone.js Tutorial Part 4 - Backbone.js Models: Model Inheritance
Programming with Mosh
Backbone.js Tutorial Part 1 - Backbone.js Models: Creating Models
Programming with Mosh
Backbone.js Tutorial Part 5 - Backbone.js Models: Syncing Models with the Server
Programming with Mosh
Backbone.js Tutorial Part 6 - Backbone.js Collections: Creating Collections
Programming with Mosh
Backbone.js Tutorial Part 7 - Backbone.js Collections: Working with Collections
Programming with Mosh
Backbone.js Tutorial Part 8 - Backbone.js Collections: Fetching Collections from the Server
Programming with Mosh
Backbone.js Tutorial Part 9 - Backbone.js Views: Creating Views
Programming with Mosh
Backbone.js Tutorial Part 10 - Backbone.js Views: Passing Data to Views
Programming with Mosh
Backbone.js Tutorial Part 11 - Backbone.js Views: Handling the DOM Events
Programming with Mosh
Backbone.js Tutorial Part 12 - Backbone.js Views: Handling the Model Events
Programming with Mosh
Backbone.js Tutorial Part 13 - Backbone.js Views: Handling Collection Events
Programming with Mosh
Backbone.js Tutorial Part 14 - Backbone.js Views: Templating
Programming with Mosh
Clean Code: Learn to write clean, maintainable and robust code
Programming with Mosh
C# Events and Delegates Made Simple | Mosh
Programming with Mosh
C# Generics Tutorial: Whats and Whys | Mosh
Programming with Mosh
Debugging C# Code in Visual Studio | Mosh
Programming with Mosh
Repository Pattern with C# and Entity Framework, Done Right | Mosh
Programming with Mosh
Angular 2 Tutorial for Beginners: Learn Angular 2 from Scratch | Mosh
Programming with Mosh
Architecture of Angular 2+ Apps
Programming with Mosh
Working with Components in Angular
Programming with Mosh
C# Tutorial For Beginners - Learn C# Basics in 1 Hour
Programming with Mosh
Difference between Junior and Senior Developers
Programming with Mosh
Step-by-step ASP.NET MVC Tutorial for Beginners | Mosh
Programming with Mosh
[Pluralsight]: Become a Full-stack .NET Developer
Programming with Mosh
Xamarin Forms Tutorial: Build Native Mobile Apps with C#
Programming with Mosh
Value Types and Reference Types in JavaScript
Programming with Mosh
Using Redux in Angular 2+ Apps | Mosh
Programming with Mosh
Testing Angular 2+ Apps with Jasmine and Karma | Mosh
Programming with Mosh
Profile and optimize your Angular 2 apps
Programming with Mosh
Build a Real-world App with ASP.NET Core and Angular 2
Programming with Mosh
Entity Framework 6 Tutorial: Learn Entity Framework 6 from Scratch
Programming with Mosh
Two-way Binding and ngModel in Angular 4
Programming with Mosh
Udemy Live 2017: Teaching Tech Panel
Programming with Mosh
Demo of An E-commerce App Built with Angular, Firebase and Bootstrap 4
Programming with Mosh
My Brand New Angular Course
Programming with Mosh
TypeScript Tutorial - TypeScript for React - Learn TypeScript
Programming with Mosh
Access Modifiers in TypeScript
Programming with Mosh
TypeScript Interfaces
Programming with Mosh
TypeScript Classes
Programming with Mosh
TypeScript Constructors
Programming with Mosh
TypeScript Properties
Programming with Mosh
Angular Tutorial for Beginners: Learn Angular & TypeScript
Programming with Mosh
AngularJS vs Angular 2 vs Angular 4 | Mosh
Programming with Mosh
Angular Material Tutorial | Mosh
Programming with Mosh
Angular Animations Tutorial | Mosh
Programming with Mosh
Firebase in Angular Applications | Mosh
Programming with Mosh
Deploying Angular Applications | Mosh
Programming with Mosh
Building Forms in Angular Apps | Mosh
Programming with Mosh
Directives in Angular Applications
Programming with Mosh
Routing and Navigation in Angular | Mosh
Programming with Mosh
Angular 4 in 40 Minutes
Programming with Mosh
[NEW COURSE] Unit Testing for C# Developers
Programming with Mosh
Unit Testing C# Code - Tutorial for Beginners
Programming with Mosh
C# Classes Tutorial | Mosh
Programming with Mosh
C# Object Initializers Tutorial
Programming with Mosh
C# Constructors Tutorial | Mosh
Programming with Mosh
More on: Systems Design Basics
View skill →Related AI Lessons
⚡
⚡
⚡
⚡
The Hardest Part Of Microservices Is Undoing What Already Succeeded
Medium · Programming
What OOP Actually Buys You (And Why “Real World Modeling” Is a Lie)
Medium · Programming
Data Partitioning in System Design: Why Every Scalable Application Depends on It
Medium · Programming
Why Realtime Collaboration Is Harder Than It Looks?
Medium · JavaScript
🎓
Tutor Explanation
DeepCamp AI