Back to Coding

DRYP -- Don't Repeat Your Prompt

DRYP -- Don't Repeat Your Prompt

I copy-pasted the same prompt into three different agents. Then I realized I was making the exact mistake I’d never make in code.

I build agentic systems in Claude Code - agents that call other agents, each with their own instructions. Think: specialized AI workers with a playbook.

Last week I was wiring up a new workflow and kept writing the same block: “Read the design guide, check the color palette, verify typography hierarchy, then critique the layout.”

Those three agents all needed that exact sequence. I copy-pasted it. Tweaked each copy slightly. Moved on.

Then it hit me.

In traditional engineering, this has a name. DRY — Don’t Repeat Yourself. The moment you write the same logic twice, you extract it into a shared function. Every developer knows this instinctively.

DRY has always been my favorite principle in software engineering. Not just because it reduces duplication — but because it’s the starting point for the best refactoring. Refactoring simplifies code, but it also creates opportunities where abstracted functions stack on each other like LEGO blocks.

But I wasn’t applying it to my prompts.

So I built a skills-creator agent: it turns repeated prompt blocks into a reusable skill file. These are shared instructions other agents can import. When I spot a repeated prompt pattern, I hand it off. Standardized instructions. Consistent behavior. One source of truth.

That design-review sequence? Now it’s a single skill that three different agents import. When I update how design critiques work, I change one file. Not three.

The shift was bigger than I expected.

Once instructions became modular, agents started composing like functions. My ui-specialist calls my react-specialist. My design-dialogue routes to two design critics through shared evaluation skills. The system grows by stacking, not by rewriting.

I started calling it DRYP for Don’t Repeat Your Prompt. DRYP is just DRY, applied to agent instructions.

The surprising part: the agents got better. Repeated prompts drift. You tweak one copy, forget the others, and suddenly your agents behave inconsistently. A single shared skill eliminates that drift entirely.

If you’re copy-pasting instructions between AI agents, you have a refactoring opportunity. The same instinct that makes you extract a helper function should fire when you duplicate a prompt.

What repeated patterns are hiding in your AI workflows?