The Problem & The Framework
The Plausibility Trap, meet SCRUB, and a deep dive on every one of the five elements — with the reasoning behind each.


Generative AI writes code that compiles, looks idiomatic, and passes its tests — and is wrong in a way only domain knowledge catches. It's not a bug you can patch or wait out. SCRUB is the discipline that closes the gap. Five elements, every prompt, every time.
A Field Guide to Disciplined Prompt Engineering for Production .NET Code — using the SCRUB Framework.
A tip calculation defaulted to 20% instead of the 18% the business runs on. It compiled. It passed its tests. Nobody flagged it in review — because the code looked right. It ran for six months across a hundred and eighty thousand receipts before a customer noticed. That's not a skill bug. It's a context bug — and it's the default outcome when you let an AI fill a gap you never defined.
Vague scope produced something other than what you needed. Fixed by S.
Correct output, foreign patterns — the drift that quietly makes a codebase inconsistent. Fixed by C.
Compiles, looks idiomatic, passes its tests, and is silently wrong in a way only domain knowledge catches. Fixed by R.
Correct in isolation, wrong for its operational context — no audit log, no jurisdiction, no compliance. Fixed by U.
You asked for one change and got ten. Renamed a method, changed a default, broke the callers. Fixed by B.
“In prompt engineering for production code, what you EXCLUDE matters more than what you include.”
SCRUB is not a template you install or a script you run. It's a checklist you practice — one that names, for each element you skip, exactly which class of bug you just invited.
Name the exact deliverable. List the methods, the signatures, the file paths. If it takes more than three sentences, split the prompt.
Framework versions, architecture, naming, DI, conventions. Match YOUR codebase — not the generic average of the training data.
The most important element. Start every line with "Do NOT," explain WHY, and say what to do INSTEAD. This is what defeats the Plausibility Trap.
The star of the frameworkCallers, compliance regime, audit expectations, concurrency, latency. The domain context the AI cannot infer and will otherwise invent.
The star of Edit Mode. All existing callers compile. All existing tests pass. State it positively AND negatively. Only ADD what you asked for.
The printed companion to a 105-minute conference session — expanded with the context, the anecdotes, the code, and the "I tried it the dumb way first and here's what happened" stories. Eight parts, thirty-six chapters, one runnable reference application.
The Plausibility Trap, meet SCRUB, and a deep dive on every one of the five elements — with the reasoning behind each.
The same framework across Inline, Chat, Agent Mode, and Edit Mode. Same discipline, shifting syntax.
Prompt chaining, tiered restrictions, and layered SCRUB — how the framework earns its keep on real work.
.NET 10, Aspire, EF Core 10, Angular 20 — every pick defended against the alternative it rejects.
A real, runnable cafe POS built end-to-end with ~30 SCRUB prompts. Clone it Monday morning.
The Diagnostic Card, the five-step refinement loop, and custom instructions that shrink every prompt.
Build a prompt library, extend the codebase, and treat prompts like the code they generate.
The SCRUB cheat sheet, the full Diagnostic Card, a glossary, and the complete index of AspireCafe prompts.
AspireCafe is a fully-runnable cafe point-of-sale built across three .NET 10 microservices, an Angular 20 POS, an Aspire AppHost, and a SQL Server backend — every line produced with SCRUB and documented prompt by prompt.
[S] Create IOvertimeCalculator scaffold — SIGNATURES ONLY.
[C] .NET 10, primary constructors, existing IPayrollAudit sink.
[R] Do NOT implement the calculation — leave // TODO.
Do NOT default to federal 1.5x — jurisdiction resolves first.
Do NOT use double / float — decimal math only.
Do NOT log SSN, DOB, or bank routing — EmployeeId only.
[U] Called by the HR admin portal. SOC 2 audit on every write.
[B] All existing callers compile unchanged. Only ADD.You write code for a living. You ship it to production. This book is for you.
Engineers who ship AI-assisted code to production and have felt — or are about to feel — the cold-sweat panic of code that compiles and quietly does the wrong thing.
Architects who have to sign off on systems built by a mix of developers and three different generative AI tools.
Team leads onboarding juniors who will lean hard on Copilot and Claude Code from day one.
Engineering managers who want to know what disciplined AI-assisted development actually looks like before they defend their tooling to a board.
Every "AI-generated code is unreliable" complaint is a complaint about an unwritten prompt. SCRUB is how you write it.
Start a Conversation