You can tell an agent that AI-DLC is not needed and still watch it spend half an hour installing a binary nobody asked for.

I watched an agent do it on CohesionStack. We had just wrapped the AI-DLC hooks so Cloud Agents would not lock up without the aidlc binary. The hooks stopped blocking. The agent still kept trying to "fix" AI-DLC until I told it directly to not use it for that task.
Skipping a hook does not make a framework opt-in. Opt-in also needs to be written into the always-on instructions, the skill flags, and the rules for what the agent is allowed to chase.
I spent part of November turning CohesionStack into a Cursor and Codex shop model that other teams can copy. The model rests on one task file for handing work between tools and on path gates before any code changes. Local verification records the exact commit SHA. Always-on context is smaller, and AI-DLC runs only when someone asks for it. I wanted two things from it. Efficiency meant fewer tokens and less re-explaining. Correctness meant agents that stop inventing processes.
Leaders who sell AI-assisted delivery or pay for AI seats face the question from "Your Bots Are Busy". Are the bots busy, or is the rework still landing on you?
What broke along the way
Three problems showed up while we set up the model:
- Fail-closed hooks with no binary. Cursor Cloud Agents locked up because the AI-DLC adapters ran on every turn. We pinned a Cloud install. We also wrapped the hooks so ordinary tasks skip them.
- Silent passes. Missing tools passed quietly. Scripts stopped at the first failure, so we never saw the second broken suite. My post "My AI Agents Said It Was Ready" covered the same lesson: a passing check did not mean the work was ready.
- Too much always-on context. Codex was loading about 15 KB of AI-DLC onboarding into every session. Skills could start the lifecycle on their own. An old journey log still looked like current guidance.
None of these problems came from how smart the model was. They came from the defaults.
What we built (phases A to F, one PR each)
| Phase | What it fixed |
|---|---|
| A: Task file and resume | .tasks/<branch>.md is the handoff. Chat history is not. |
| B: Path allowlist and spec gate | Cursor, Codex (when trusted), and pre-commit all give the same deny reason. No app edits happen before status: accepted. |
| C: verify_changed and exact SHA | One local command maps the diff to test suites, prints every failure, refuses a dirty tree or a missing tool, and records verified_sha. We merge when that SHA matches the PR head. |
| D: Token cut | Codex gets a short pointer instead of the embedded onboarding. AI-DLC skills run only when called by name. |
| E: Hook opt-in (shipped early for Cloud) | AI-DLC hook commands run only when the task says lifecycle: aidlc. |
| F: Replication and cleanup | A paste-ready guide for a client or greenfield repo. We deleted JOURNEY_LOG.md so agents stop treating it as always-on process. |
Here is the task file from phase A, trimmed from the template in the repo:
# Task: <short title>
issue: https://github.com/irahulsawhney/cohesionstack/issues/N
lifecycle: direct # direct | aidlc
status: draft # draft | accepted | implementing | verified
allowed_paths:
- path/to/allowed/**
acceptance:
- id: AC1
text: Observable behavior that must hold
evidence: test.or.command.or.path that proves it
verified_sha:
verified_clean: false
commands: []
next: First concrete step for the next session.
What I learned
- Opt-in needs three layers. Hooks do nothing on ordinary tasks. Skills cannot start on their own. Instructions tell the agent not to install, debug, or chase AI-DLC unless someone asks or the task says
lifecycle: aidlc. If one layer is missing, the agent fills the gap with well-meant work nobody asked for. - The task file matters more than the chat transcript. Switching between Cursor and Codex in the middle of a task works only when the issue,
allowed_paths, acceptance,verified_sha, and next step are written down in git. Resume means continue from next. The agent does not start planning again from scratch. - Proof needs an exact commit, and a dirty tree is not proof.
verify_changed.shrefuses a dirty worktree, keeps going after the first failure, and fails when a tool is missing. The script applies the closet check from "My AI Agents Said It Was Ready" to handing work between agents on a local machine. - Less context also means more correct work. A smaller always-on context costs less to run. The cut also removes conflicting schedules, old journey logs, and deploy rules that load whenever their description seems relevant. Setting path patterns (globs) on rules matters.
- A process you cannot hand over is not a consulting product. Phase F exists so another repo, or another agent, can get started without my chat history. If the setup only works while I am in the room, it is not yet a shop model other teams can use.
When AI-DLC is worth using
AI-DLC is great for building complicated features with design and architecture implications. Our mistake was running it by default on every ordinary bug fix. To opt in, someone asks for AI-DLC by name or the task file says lifecycle: aidlc.
Use it when:
- You are building a complicated feature with design or architecture implications.
- You want the work to move from requirements to design to code in ordered steps.
- You want a written record of what was decided and why, along with the design and the code.
Skip it when:
- The task is an ordinary bug fix or a small change with no design impact.
- The task file says
lifecycle: direct.
Questions for leaders putting AI into delivery
- When you call a framework optional, does the agent leave it alone without being told twice?
- Can someone pick up the branch in the other IDE from a file in git, without a DM?
- Does local verification name the commit it ran on, and fail when a tool is missing?
- How much conflicting onboarding gets loaded into every session?
- If you brought in a consulting agent tomorrow, is there one brief you could paste in, or only knowledge in people's heads?
Closing
Faster coding is easy to buy. Lead time and token spend improve when agents take fewer wrong turns.
This month I built the shop rules I want on client work. Work runs direct by default, and AI-DLC runs when someone chooses it. Proof is tied to a commit SHA. The next agent gets a guide, so I do not explain everything again.
As a fractional technology leader, I help teams going AI first put these shop rules in place: one task file shared across tools, process only when someone opts in, and agents that stop inventing process. If you want them on your team, the work sits inside Execution and Transformation Leadership.