DEV Community

Cover image for Right way to vibe code that actually works
SinghDevHub
SinghDevHub

Posted on

Right way to vibe code that actually works

📍 Engineering's current situation

You might have heard this already a ton of times that software engineers are gonna get replaced with AI systems, agents and tools.

Software engineers meme

Well, We will not comment too much on this particular thing as no one is clear about this. But few predictions/things already happening in the industry:-

1️⃣ small teams are getting really really effective/productive
2️⃣ people with agency and intent are getting preferred over people who are very skilled or smart
3️⃣ companies will move even faster than before
4️⃣ softwares building themselves

😳 Examples:-

But there is one common thing in every organisation that it is not about:-
should you use AI or not? It is about:- how you should use AI.

A lot of people don't know if they are doing vibe coding or doing AI Assisted coding. Yep, there is a huge difference in Vibe Coding & AI Assisted coding.

📍 Usual way of vibe coding

Vibe coding workflow generally looks like this:-

  • You have an agentic IDE (cursor, windsurf) or CLI agents like (claude code, gemini cli)
  • You put a prompt in the chat window
  • Your agent reads the prompt, plans and then start generating code

This method works on very small features or when you are starting afresh, because:-

  • starting with fresh context or instance of agent, works for some time
  • as you keep on generating code, agents starts drifting from the actual intent that human asked the agent to code for
  • small & simple features can be implemented by most of the LLM models like claude, grok etc

📍 When things actually break ?

But as soon as someone starts working on larger codebases, complex features or end to end products, Agents struggle a lot because:-

  • they start drifting away from human given prompt or intent
  • they start coding worse as context window fills up
  • they start hallucinations with confidence with no verification loops

👉 Because of which, users generate thousands of lines of code and realise nothing works. And then refactoring that codebase is a very tedious task and a lot of iterations comes into the play.

And this struggle is causing developers a pseudo productivity boost, a lot of iterations and headaches.

So how should we vibe code then ??

vibe coding meme

No, above picture doesn't refer to how you should code 🤪

Coding is still a fundamental problem solving method where structure wins even after so many code generation LLM models. Catching it up using first principles it is:-

  • writing a PRD (product/feature requirement doc)
  • dividing a PRD into Specs
  • making Tech docs and then sub-tasks
  • assigning sub tasks to your team so that they can finally code
  • verification of the implementations

And this is where Inner loop solves your problem, which is code generation.

But have you noticed which part is missing ???

Yes, exactly the outer loop.

📍 The Outer Loop

Missing pieces because of which LLMs are still not capable of coding are:-
1️⃣ writing a PRD (product/feature requirement doc)
2️⃣ dividing a PRD into Specs
3️⃣ making Tech docs and then sub-tasks
⚠️ - assigning sub tasks to your team so that they can finally code (using Inner loop or LLMs here)
4️⃣ verification of the implementations

This is where a new field shines:- Spec Driven Development.

A lot of products are trying to solve Spec driven development which does generate PRDs, plan really well, verifies each agent's code step and prevent agents drifting away from user' intent.

Products which are in this space are:- Traycer, Kiro, Spec-kit

But my friends are obsessed with Traycer because of their features like EPIC mode which is highly intuitive.

Traycer solved few problems which no one is able to solve yet:-

  • capturing human intent from a normal simple prompt
  • prevents agents from deviating from the intent
  • consume less tokens and prevents context bloating
  • verifies your each change so that you dont ship hallucinations with confidence

Here is a sneak peak how TraycerAI EPIC mode looks like:-

Traycer EPIC mode

TraycerAI is my partner nowadays because it acts my senior engineer instead of just an agent. Highlighting few features:-

  • It starts with a simple prompt
  • Then it interviews you around problem statement, tech stack, edge cases and other high level questions
  • Then it generates PRDs, Specs, Tech flow, Wireframes, Sequence and user flow diagrams
  • And finally, it breaks the plan into smaller tickets so that you can handover these tickets to any AI agent like claude, grok, cursor IDE etc
  • and then it verifies each and every change and prevents your agents to drift/deviate in false direction

📍 Recently we shipped products like:-

  • building your own redis
  • building my own whatsapp that supports semantic search across messages

And many more projects we are building and loving the EPIC mode ❤️

Top comments (2)

Collapse
 
arpitpatel25 profile image
Arpit Patel

Traycer’s approach to vine coding is actually amazing and intuitive 🙌

Collapse
 
yk_dhawan_519349b771d0dba profile image
YK DHAWAN

It's been 4-5 days using it as an upcoming PM this is something that will make me standout in the crowd. Sometime I think if the team can give me the access of the backend to push the change to 1% of the TG, the PMs will be the developers and then they will see the results. EPIC mode is EPIC.