slowlp
← Blog
Lesson 2026.06.11 · 5 min read

The Agent Control Code I Wrote Myself Was Already in Claude Code

If you miss AI tool updates, you'll reinvent the wheel twice

Lesson

The Agent Control Code I Wrote Myself Was Already in Claude Code

If you miss AI tool updates, you’ll reinvent the wheel twice

I once stuffed over 20 agent behavior rules into CLAUDE.md. In practice, maybe half of them were actually followed. My first thought was “the model is being weird.” Turns out it was a structural problem. As the context grew longer, the rules at the top just got diluted.

So I started writing custom orchestration scripts myself. It was an attempt to “control” the agent. I carefully set up an allowlist too, but permission prompts kept firing — and I had no idea why for a while.

Then I was skimming the Claude 4.8 release notes and stumbled on Dynamic Workflows. When I read “orchestrates hundreds of parallel sub-agents,” I stopped. The concept was almost identical to the custom script I’d been running. It already existed, and it was built better than mine.

The same was true for the CLAUDE.md overload problem. The solution had already been designed in. Heavy procedures belong in skills, and deterministic rules belong in hooks. Skills get injected right next to the task at the moment they’re triggered, so compliance goes up. Hooks bypass model judgment entirely via exit code 2 — pure deterministic enforcement. And the allowlist that kept firing? Turned out to be a known bug where security heuristics are designed to override the allowlist.

These four levers — CLAUDE.md, skills, commands, hooks — each carry different levels of trust and cost. Once you have a feel for which axis each lever lives on — “always / conditional / manual / deterministic” — you can look up the syntax as you go. Before I understood this, I was dumping everything into CLAUDE.md and wondering why it kept forgetting things.

The lesson is simple. Agent tooling abstracts up a layer every six months. What required custom engineering last year becomes a config value this year. What builders actually need isn’t a fancy custom harness — it’s the habit of checking updates regularly and staying close to the built-in features.

Open the recent update notes for whatever AI tool you’re using right now. There’s a good chance something you built yourself or hacked around last month has already shipped as a native feature.


Deep dive: When your agent won’t listen — the 4-lever method · The secret of skills — when natural language becomes logic See also: When implementation is free — the bottleneck has moved up · Cutting dev time with the build-plan skill

Related
All posts →
COMMENTS