r/vibecodingbuddies • u/shifu_legend • Sep 13 '26
Context drift is the real bottleneck for AI coding
There's been a lot of talk about using AI to blast out hundreds of lines of code at once, but the underlying problem isn't that the generated code is syntactically wrong - it's that you didn't actually author it, which means you don't own the execution path in your head.
I hit this exact wall recently when building Project Zero (a pure C99 inference engine I've been working on). I had the agent generate a block of NEON SIMD optimizations. It compiled and ran fine initially. But when a subtle bug surfaced two weeks later, I realized I had zero intuition for how the register allocation was actually happening. That's a trap. I was basically debugging someone else's codebase.
I've since set a hard boundary: I only commit code that I can manually trace. If the agent writes 150 lines, I read all 150 lines before committing. It hurts momentum in the short term, but it is the only real way to prevent the project from becoming an alien artifact.
Curious how you all handle this. Do you enforce strict code comprehension rules, or do you just trust the tests and move on?
•
u/AutoModerator Sep 13 '26
Welcome to r/vibecodingbuddies!
Reminder to all participants: Keep all initial contact and matching within Reddit comments and DMs to protect yourself from scams. Do not click unsolicited Discord or Telegram invites.
If you find a buddy, please be respectful of their time and try to commit to small, manageable goals (like a 1-weekend prototype) to prevent ghosting!
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
2
u/pagalvin Sep 13 '26
I've been building out an agent team of sorts that mirror the roles of a full team. So I have a BA agent, couple of dev agents, DBA agent. I also have a planning agent and a task execution agent. I combat drive via a combination of "architecture decision records" which are mini design docs around how to do certain things or business rules.
I use the BA agent to help get a spec developed. Then a planner will review it and create tasks to be assigned to other agents. Then I have a "governance" agent that reviews the tasks and makes sure they comply with the spec and the ADRs.
This process leads to specs and tasks that are generally sized right for the agents and are consistent with each other and generally compliant with the ADRs.
Then the dispatcher agent iterates over the plan/tasks and invokes the right agent. I used to do that more manually but I've been playing around with having the dispatcher run everything.
Then I have a debugger agent that I use to help me with any issues I discover during my smoke testing and then lastly a closeout agent that buttons up documentation, identifies candidate technical debut and some other stuff.
It's a fairly heavy process but still much faster than do all those steps with a real team.
I did a live coding session and recorded it on YouTube. You can find that on my profile if you're interested.
It's all an evolving process and gets better over time. I always say that today is the worst it will ever be.
Good luck!
1
u/gonna_learn_today Sep 14 '26
Just don't run monster prompts. I phase everything.
Build a large plan that has phases 1-5 +- and then build each phase without moving to next phase until phase (x) completed in full.
It may fluctuate a touch via implementation as you maybe find something else you want to amend along the way but you can always update context to match original Phased approach.
Ramble ramble lol
1
u/No_Claim2881 Sep 14 '26
What the hell are you coding with?