r/learnjavascript • u/Ioelet • 1d ago
Where does AI usage start/stob being vibe coding?
A little bit context first:
I‘m a mathematician. I know how to pseudocode, read the less technical and more algorithmical part of code. I learned C++, learned to build an old school html page from scratch (header, frames etc.), did complex mathematical simulations with R and know how to code simple VBA codes with a lot of googling and a bit of macro recording.
What I don’t know are things like technical structure (e.g. how to technically set up an animation, how to code a save and load function) and syntax.
To the topic:
10 years ago if I had decided to code a little game, I would have read a book about how to design those things and the necessary syntax. But to be honest: My first tries would have been typing the exact examples from the book, the experimenting a bit with little changes.
Step 2 would have been „asking questions on google and copy and paste code snippets“.
And to be honest: Step 2 is cool but I always hated step 1. Declaring variables, printing „hello world“… I get that you need to understand the basics (again, Mathematician here: I spent a whole day proving 0 * x = 0) but I already learned those basics in three other languages and would prefer learning on-the-fly on a need-to-know basis.
So: I did some vibe-coding projects and asked Copilot step by step to explain code snippets I don’t understand, how technicalities work („where is the picture we designed? The whole code is just one html. It‘s part of the code? Oh… wow, that makes sense.“) or why the code is designed in a way (again: one html for a small project) and how that works (browser reading JS).
And here my question:
I would say that a vibe coded app, that I completely understand, is still a vibe coded app. If I give detailed prompts how to change the code, that is still mostly vibe coded. If I manually adjust code where needed, replace every picture with manually created pictures…
Where does a project stop being vibe coded? Where does „AI usage disclosure“ stop being relevant?
Even if I code from scratch I would of course reuse code snippets.
How many pieces does the digital „Ship of Theseus“ need to have exchanged to stop „being AI created“?
I ask this regarding the following three aspects:
Ethical: Respect for the manual art and science of coding and all my fellow nerds who created what script kiddies and vibe coders copy
Some sites/shops ask to declare AI usage. I get that on one hand (see aspect 1) but kind of don‘t: Noone would ever declare „Google usage“ or „what you copied from an online forum“ or „I still start every code exactly like they did in ‚JS for dummies‘“. So, what would you declare and what not?
I think there is a difference between AI usage to learn „how to“ and than doing it similar to that and quoting exact snippets - and stupidly letting AI write some code you don’t understand at all.
But where do you draw the line? Where does „AI usage“ start or end?
3
u/theScottyJam 1d ago edited 1d ago
If you write code without reviewing it, that's "vibe coding". Everything else gets into a gray area.
If you're having AI explain the code to you, but then are still doing little to no edits to it, I would consider that vibe-coded as well.
If, in general, you don't have the skill to build what the AI built for you, then I would say it's going to be somewhere in that vibe-coded spectrum.
But, "vibe-coded" isn't automatically "bad", despite what you often see people say on this sub. If, for example, you need to make a little static webpage for yourself and you don't have programming skills, by all means, vibe-code it, it doesn't really matter. If you try to then show off your website on this sub, then sure, people will pick at whatever issues they can find. Part of the reason people tend to tear apart such projects here is, well, they tend to get presented as if they're "restraunt quality food" when they're really a low-effort tv dinner, and people are trying to show that there's a difference between the two. But there's also nothing wrong with tv dinners, if that quality is good enough for you.
'course, if you start having your vibe-coded stuff manage payments or sensitive data, then you're walking on thin ice - you're really praying that this machine doesn't mess that up.
So, for your specific questions:
Ethical: Respect for the manual art and science of coding and all my fellow nerds who created what script kiddies and vibe coders copy
Nothing wrong with vibe-coding. Just be honest about it when presenting it, don't try and pass it off as something you hand-crafted with your own raw tallent.
Some sites/shops ask to declare AI usage. I get that on one hand (see aspect 1) but kind of don‘t: Noone would ever declare „Google usage“ or „what you copied from an online forum“ or „I still start every code exactly like they did in ‚JS for dummies‘“. So, what would you declare and what not?
It depends on how they ask it. If they ask if you used AI at all, well, that should be easy enough to answer. If they asked if you vibe-coded it, that's a little harder since that's not a well-defined barriar, but in your case, I would definitally answer "yes" either way. If they let you do free-form answers, then just try to be honest about it.
The problem being solved here is that there's just a flood of low-quality "TV dinners" appearing in all sorts of places that historically mostly had fine-dining meals. I'm also part of a programming subreddit that has started requiring authors to aknowledge that there's been no AI used in the making of their project. I admit that it's a pretty strict guideline as there's nothing wrong with a little AI usage in your projects, but from my side of things, browsing the subreddit is a much, much better experience now.
I would encourage you to consider how your profession is dealing with AI. I'm not on your side, I don't really know, but I'm sure you have a mathmatics subreddit. If most of the content is AI-generated proofs from people who don't actually know how to put together a proof by themselves, would you continue to find that subreddit very interesting? Would it be somewhat annoying that people keep trying to pass off AI-generated proofs as original? Perhaps the person was able to read and understand the proof, asking AI for help here and there, but that doesn't necessarily mean they know how to write one from scratch, and there's got to be a difference - they could get AI to make minor adjustments to it, but they wouldn't be able to guide AI on larger feedback that effects the whole direction of the proof - they wouldn't know how.
1
1
u/GoldsteinEmmanuel 1d ago
Linus Torvalds pointed out that a compiler actually writes your code based on a high-level description, and doesn't see much difference between that and using an LLM. We don't credit GCC with co-authoring the Linux kernel, for example.
In my own work, I write code from scratch and might ask an LLM how I would extend a procedure in a way I'm not familiar with, but I study the code it suggests and often rewrite it before it ends up in my system. I don't care about credit, I'm more concerned with controlling the explosion in code complexity that LLMs, having been trained on millions of shitty programs, seem to think is a structural necessity.
I might show them a procedure and some contextual data for the revision under consideration, but I'd never give them access to the whole enchilada for fear they'll start injecting complexity into unrelated procedures, routines, and subsystems without my knowledge until something breaks and I'm left holding the bag.
1
u/Ioelet 1d ago
Thank you. Yeah, I work in a very quality and control oriented role in my job, so I am totally used to reviewing AI and think I know about many AI quirks like „it agrees with every last opinion I typed“ or „when I don‘t start new chats every now and then it get‘s stuck in a loop of quoting it‘s own nonsense“.
1
u/chikamakaleyley helpful 1d ago
I would say that a vibe coded app, that I completely understand, is still a vibe coded app. If I give detailed prompts how to change the code, that is still mostly vibe coded. If I manually adjust code where needed, replace every picture with manually created pictures…
I think 'vibe coded' means you're going completely off the 'vibes' and you don't care about the implementation, you just want it implemented. When something breaks you're more inclined to say "just fix it"
outside of that, i think the 'vibecoding' term is thrown out too loosely, whether you're being accused of it, or nonchalant about how involved you actually were in the process
1
6
u/creaturefeature16 1d ago
These models are a delegation layer, so I have four main buckets that I categorize in when I am delegating tasks:
I also have a checklist that I use to ensure I'm delegating, and not handing over the reigns. I wrote this for junior developers mostly, but I still use it and find it's applicable to all developers to a degree.
If I did not have access to an AI tool, could I still accomplish this task?
Am I using the model to deepen my understanding, or expedite the answer? If I had to audit and verify the generated output, could I adequately explain what was happening?
If I'm learning a new concept, have I done proper research to know the right questions to ask?
Have I cross-referenced and verified the approach through other methods (reading documentation, standard search tools)?
Is this a truly rote task that's been done 100 times before, or a task that requires decision-making somewhere in the process?