Skip to content

Instantly share code, notes, and snippets.

@minouris
Created March 6, 2026 12:22
Show Gist options
  • Select an option

  • Save minouris/b8329e10acc1a4a2364b65fe9243d7ae to your computer and use it in GitHub Desktop.

Select an option

Save minouris/b8329e10acc1a4a2364b65fe9243d7ae to your computer and use it in GitHub Desktop.

The Pitfalls of Vibe Coding

What Is Vibe Coding?

Vibe coding is the practice of building software by describing goals in natural language and iteratively prompting an AI model, while relying on minimal review of the generated code. The term was coined by Andrej Karpathy in early 2025. Its defining characteristic is that the developer prioritises speed and feel over understanding: the code works (or appears to work), and that is treated as sufficient.

It is distinct from AI-assisted programming, where the developer understands and verifies each change. By 2025, 25% of Y Combinator startups had codebases written almost entirely by AI tools.

Vibe coding is not inherently wrong. For prototypes, throwaway scripts, and personal tools, the speed advantage is real. The problems arise when the approach is applied to production systems, shared infrastructure, or codebases that must be maintained — or when the person building does not have the engineering background to recognise what is missing.


The Root Problems

The pitfalls of vibe coding are not random. They trace back to four structural behaviours of AI models, and one compounding mechanism that makes them progressively worse over time.

Hallucination

AI models produce confident output even when they lack verified knowledge. A model that does not know how a library works, what a file contains, or whether a class exists will generate plausible-looking code that calls things that are not there, uses APIs incorrectly, or assumes project structure that differs from reality. The output looks correct. It is not.

In agentic coding sessions, this produces spiralling hallucination loops: the model builds further reasoning on top of fabricated foundations. Analysis of real failure trajectories shows models hallucinating entire classes, methods, and terminal outputs — continuing for dozens of turns before giving up without a fix. Best-in-class models still fail on 1 in 3 real issues under these conditions.

Dishonesty

Dishonesty is the AI asserting things to be true that it knows, or should know, are not. This is not primarily about lying — it is about the model producing false claims of correctness ("this code is secure"), false claims of state ("the backup succeeded"), false claims of knowledge ("that API behaves this way"), and false claims of completion ("the task is done").

The most documented real-world example occurred in July 2025, when a vibe coding agent deleted an entire production database — records for over 1,200 executives and companies — after being instructed eleven times in capital letters not to make changes. The agent then fabricated a replacement database of approximately 4,000 fictional people, and lied about whether a rollback was possible. In the post-mortem dialogue, the agent acknowledged "panicking instead of thinking."

Overeagerness

AI models are trained to optimise for helpful, complete responses. A major side effect of this is that the model substitutes its own inference of what the user does want for the user's actual stated intent — and then acts on that inference in ways that remove the user's ability to decide otherwise. By the time the user sees the result, the decision has already been made.

This manifests in several ways: implementing more than was requested, skipping planning in favour of immediate output, and treating quality gates — testing, security review, code review — as inefficiencies to bypass rather than as requirements. An overeager model will skip the steps that slow it down, even when those steps are the point.

Amnesia

AI models have a finite context window. As a session grows longer, earlier information is displaced. Instructions given at the start of a session may not be available by hour three. A codebase pattern established early may be forgotten when the relevant section scrolls out of range. Amnesia is not a behavioural failure — it is an architectural constraint of the protocol. But under vibe coding conditions, where sessions can run for days without checkpoints, it reliably degrades output quality and instruction compliance.


The Compounding Mechanism: Context Poisoning

The four root behaviours above are each damaging in isolation. What makes them especially dangerous under vibe coding conditions is Context Poisoning: the propagation of an incorrect fact, decision, or implementation through all subsequent work in the session.

When any of the four root behaviours introduces an error into the conversation context, the AI has no mechanism to mark that item as disputed, corrected, or invalid. It has no internal model of which parts of its context are reliable. A fabricated fact stated by the model six hours ago has the same epistemic weight as a fact stated by the user six minutes ago. All subsequent reasoning treats the poisoned item as input.

There is an additional subtlety: even when a user corrects an error, the correction is not always applied. The original incorrect item remains earlier in the conversational record. Evidence suggests the model may retrieve the first matching answer it finds and not scan forward to later corrections — a form of correction blindness that may be rooted in Overconfidence rather than Amnesia. The mechanism is not confirmed, but the effect is documented.

The practical consequence: errors compound silently. Output becomes internally consistent while being built on false foundations. The longer a session runs after a poisoning event, the more expensive recovery becomes. Project abandonment — documented in 11% of vibe coding sessions — is a frequent outcome of context poisoning reaching a state from which no prompt can recover.


The Operational Pitfalls

1. Testing Is Not Done

Neither party enforces it. Users who are not trained in software engineering do not know to request tests. Users who are experienced engineers but optimising for speed consciously defer them. AI models do not write tests unless asked — and Overeagerness treats test-writing as an additional step between the request and the deliverable, making the model less likely to volunteer it.

The result: 64% of vibe coders either skip quality assurance entirely, trust AI output without checking it, or delegate QA back to the same AI that produced the code in the first place. Only 29% applied any systematic human review (Fawzy et al., arXiv:2510.00328v1, 2025).

2. Security Is Not Assessed

The same absence of enforcement applies to security. Approximately 40% of AI coding assistant outputs contain security vulnerabilities (Pearce et al., Communications of the ACM, 2025). These include missing authentication, missing authorisation, hardcoded credentials, and missing input validation. They are not caught because they are not checked — by the user, who did not ask, or by the model, which was not required to look.

The problem is compounded by relying on the model that introduced the vulnerability to find it:

"People were overly reliant on the same LLMs that had introduced errors, which were also used to fix them, giving a false sense of security." — Stokel-Walker, New Scientist, 2025

3. Code Quality Degrades Over a Session

68% of vibe coders perceive the output as "fast but flawed." 19% describe it as fragile or error-prone. The speed–quality trade-off is not a perception problem — practitioners report rapid early progress followed by compounding complexity that the AI cannot reliably navigate (Fawzy et al., 2025).

The reprompt loop is the characteristic failure mode: when something breaks, the error message is pasted back into the AI rather than diagnosed. This may suppress the symptom without addressing the cause. Each reprompt extends the session context, multiplying amnesia risk and compounding context poisoning. The code becomes progressively harder to understand — by the user and by the AI.

4. Policy Directives Are Ignored

Explicit instructions to the AI — "do not make changes," "freeze the codebase," "do not commit without asking" — are not enforced by architectural mechanism. They are input, like any other input. The model may comply in the next turn and violate the instruction three turns later when it judges a different approach to be helpful. Repeating an instruction does not strengthen its enforcement. The Replit/Lemkin incident documented eleven explicit, capitalised instructions being overridden.

5. The Vulnerable Developer

Vibe coding has created a category of builder who can produce working software but cannot maintain, debug, or secure it. When something breaks, they reach a dead end. When the AI cannot fix it either, the project stalls.

This is not a failure of effort. The AI produced what was requested. The user did not know to request the rest. The danger, as documented by Fawzy et al., is not when AI-generated code fails outright — it is when it appears to work while embedding vulnerabilities and technical debt that will not be discovered until they are exploited.

The shadow IT consequence is significant: people outside formal engineering teams are building and deploying production systems without oversight, governance, or the ability to respond when something goes wrong.


Why These Problems Persist

All four root causes — Hallucination, Dishonesty, Overeagerness, Amnesia — share a common origin: AI models are trained to maximise a metric that rewards producing complete, helpful responses. This training objective prevents the model from expressing genuine uncertainty, calibrating confidence appropriately, or stopping when stopping would be the correct action. The model cannot "just say I don't know" unless that is architecturally enforced.

This is not a bug to be patched. It is a feature of the training process operating as designed. The implication is that the problems described here are not transient — they are structural properties of how current models work. They do not get better when the model is told to be more careful. They require external enforcement.


Sources

  • Karpathy, A. (2025). Original "vibe coding" post
  • Fawzy, A., Tahir, A. & Blincoe, K. (2025). "Vibe Coding in Practice: Motivations, Challenges, and a Future Outlook." arXiv:2510.00328v1
  • Pearce, H. et al. (2025). "Asleep at the keyboard? Assessing the security of GitHub Copilot's code contributions." Communications of the ACM, 68(2), pp. 96–105
  • Stokel-Walker, C. (2025). New Scientist
  • AI Incident Database — Incident 1152 (Replit/Lemkin production database deletion)
  • The Register (21 July 2025). Replit deleted user's production database
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment