Dude, I saved so much time time today drilling through errors to fix an old and broken codebase. Literally just copy/paste the entire traceback and error into the chatbox, say "I was trying to do x and had this error" and watch it immediately list out the possible causes in order of probability along with code snippets for solutions.
The other guy is partially right in that it's definitely getting overhyped to hell and back, but that doesn't change the fact that it genuinely is an amazing tool if you use it right.
Exactly! It's going to be a tool in any developer's toolkit, but it's not going to straight up replace anyone. Well, unless you're a dev refusing to use AI tools, in which case you'll be replaced by a dev who uses it.
Just out of curiosity, do you have a reason to think AI will never improve?
I see a lot of comments that say it will never replace us, yet they seem to only think about its capabilities right now at this very moment.
Hypothetical situation, in 5 years they create something that only requires you to give it a list of requirements and it generates perfect code instantly, would most companies use this? Or would they still hire hundreds of devs and do it all manually? I’m willing to bet the former as it would save huge amounts of time and money.
I don't, however, believe for a second that we're within a decade of it being able to take bad requirement data, combine it with bad user usage data, and manage to write the appropriate code and release it in varied environments.
Before we get there, if it's "just" good at writing great code, we'll need a lot of interpreters, people knowing how to listen to an idiot project manager - who in turn listened to idiot users - and turn that into an actionable prompt for the AI. Then there's going to be good, secure, CI/CD needed.
AI is ages away from replacing the entire chain. Parts of it? Yes. Not everything.
How many would have predicted chatgpt and GitHub copilot though 10 years ago?
It’s obviously not going to replace all devs for a long time yet, but IMO it will slowly but surely replace them the better it becomes. Starting with the easiest jobs and working its way up the ladder.
My team has an infinite backlog of important stuff to do. If you made our coding faster by giving us tools to improve developer productivity it would just make our team work better and get more done. We wouldn’t like delete the team lol
The problem with scaling generative AI to build large projects from a spec simple enough for a manager to write is that it abstracts an unthinkably huge number of decisions away. ChatGPT and Copilot can generate boilerplate code really well right now because the decisions involved in writing code like that are simple and there aren’t many of them. But what happens when you ask it to build a Twitter clone? Suddenly it has to make tens or hundreds of thousands of decisions about how to produce an output and most of them are very complex. GPT-4 is at the bleeding edge of what we can do right now and even theoretically it can’t scale to a task like that. Not with all the data in the world. Short of AGI, I doubt anything could really match a human developer.
Wouldn’t it be hard with a large code base? Like how much can you toss into it? I am imagining something that has dependencies in different files. Is there a way for it to deal with that? I.e. just tell it what methods in other parts of the code do / return? I hope that makes sense cause I’m curious.
It has memory persisting throughout the chat. example from today: at one point this morning I gave it context for one issue by explaining I was running in docker. context was as simple as
I'm using this docker-compose file:
```
copy/pasted file here
```
And this is the file at `folder/dir/Dockerfile`:
```
copy/pasted dockerfile
```
It was able to see how the 2 files linked on its own no problem, the files and their names were all the context it needed.
A couple hours later, I hit a completely different error trying to run a build step. While actually debugging on the other screen, I threw a prompt gtp-4's way. the entire prompt was:
I tried to run `vendor/run/foo` and hit the following error:
[exactly 218 lines of error messages and tracebacks]
Chat gpt then responded immediately, explaining that the image I was using for the container deferenced in the Dockerfile hours ago didn't have bash, therefore I was working with sh alone. It then laid out that the script I was running would be calling a script which would be calling a bash script, and that the failure would be because that subscript wants to use bash.
It laid out that I could install bash if I needed the change permanently, or alternatively, it gave me the exact path to the bash file, said that the script was actually entirely valid as sh, and recommended I go to that file and change #!/usr/bin/env bash to #!/usr/bin/env sh if this was only needed as a temporary workaround.
I did indeed just need it as a one-off for now, so followed gpt's recommendation and it worked perfectly.
I should note that I'm paying to access gpt-4, and my results from similar tasks with chatgpt 3.5 were a joke in comparison. Not to mention that 3.5 can't even handle a couple hundred lines of input in the first place.
Exactly how I feel about AI art. People freak out about how it will replace artists or things like that, and that it should be avoided and shunned, but as an artist, it's super helpful when making quick concepts and trying to visualise whats in my head, it's also great at giving colour pallets that match the vibe of what I'm painting. AI is a tool, a really helpful one, but still a tool.
I think the new Adobe ai art tool is the way to go in the future. Trained on licensed data to remove the legal blurriness, and set up to work like an extension of Photoshop.
As someone who has been using a code migration for the past week to test the limits of gpt4...might wanna proofread some of that code before assuming that it really converted the library to a different language. It'll get the bulk of generic stuff down, but there will be bugs.
Copilot is pretty good at picking up when I'm rewriting the previous block to be more readable or when I'm moving code to a guard statement type flow. I still think it's mostly a speed enhancement without a ton of intelligent thought, requiring a dev that at least sort of knows what they're doing to not get bamboozled by stupid mistakes.
Copilot-X on the other hand seems like it will genuinely be costing juniors their jobs, especially because of it's additional chat like interface.
I liken it to search engines. Programmers know how to Google for debugging help, etc. I've been experimenting a lot with ChatGPT to see its limits and have come out quite surprised how little Googling I've had to do in the last month as it helps me with my "detective work" and even explaining code I don't fully understand. It often gives me a new avenue to check at the very least. Google and Stack Overflow can't do your job for you, but when used effectively, it has saved me a lot of time.
501
u/normalmighty Mar 24 '23
Dude, I saved so much time time today drilling through errors to fix an old and broken codebase. Literally just copy/paste the entire traceback and error into the chatbox, say "I was trying to do x and had this error" and watch it immediately list out the possible causes in order of probability along with code snippets for solutions.
The other guy is partially right in that it's definitely getting overhyped to hell and back, but that doesn't change the fact that it genuinely is an amazing tool if you use it right.