The secret isn't treating the AI as a "genius" partner, but rather as a high-speed "word calculator" or the ultimate intern. LLMs are consistently 100x worse than a senior architect at handling software design tradeoffs, but they are incredibly fast at execution. If you defer your thinking to the model, you'll end up with "AI slop"—a tangled mess that becomes impossible to maintain once you cross the 60k LOC threshold.
To maintain this level of output without sacrificing quality, I've implemented a specific AI workflow:
Frontload Design to Eliminate Ambiguity #
I completely separate the "thinking" phase from the "coding" phase. Before an agent touches a single line of code, I create a rigorous design spec and an implementation spec. By resolving every ambiguity upfront, I can essentially "turn off" the AI's tendency to overthink or hallucinate alternative paths. When the AI doesn't have to guess my intent, it stops revisiting decisions I've already made, which is critical when managing a codebase of 350k+ LOC with complex layered abstractions.
Active Alignment Monitoring #
I don't "set it and forget it." I read almost every word of the chat output in real-time. The moment the AI says something incongruent with my mental model, I stop it immediately. A single wrong assumption in the chat is a leading indicator that the LLM's context is unaligned. Correcting it the second it happens prevents a cascade of errors that would otherwise take hours to untangle.
Strategic Prioritization and Validation #
I map out the feature development order exactly as I would manually to minimize architectural risk. I tackle the unknowns first and let the project take shape before adding complexity. To keep the AI on track, I build harnesses and use external "oracle" references—such as pixel-perfect font tests against Skia—rather than just eyeballing the results. This puts the LLM in a position where it can actually succeed.
Ultimately, LLMs can't intuit the right tradeoffs for a specific business need or decide which parts of a system need flexibility versus raw practicality. The most valuable skill in the current era of prompt engineering is the ability to read and audit code faster than the AI can generate it. If you can spot the difference between excellent execution and confident drivel, you can scale your output exponentially.
Next Pharmacy AI Workflow: Lessons from a Vermont Chain →