AI-assisted engineering • 3 minute read •

AI Can Write the Change. Who Controls the Release?

Let AI build. Keep production behind a boundary.

AI coding agents can write code, build tests and review one another's work. That makes them useful engineering tools. It does not make them reliable production operators.

Their behaviour is nondeterministic. An agent can misinterpret a request, act beyond its scope, or describe an action differently from what it actually did. A confident explanation is insufficient grounds for granting production access.

The engineering response is to bound their authority. AI can prepare a change and inspect permitted evidence. Direct production writes, deployment commands and production-pipeline dispatches should stay outside its reach. That boundary belongs in access controls and tooling, beyond the instructions in a prompt.

Put the human at the handoff

Keeping AI away from production does not require a person to run every deployment step.

The human belongs at the point where the agent's authority ends. The agent submits its finished change, test results and independent review. A person reviews that evidence and decides whether to authorize the handoff.

Approval should identify the work being accepted. If the code changes afterward, the previous approval and test results cannot simply follow along.

Once an approved change is merged to main, deterministic automation can take over; the agent does not press the production button. The Worker release workflow runs only when the resulting push changes chat-worker/src/**, chat-worker/wrangler.toml, chat-worker/package.json, or chat-worker/package-lock.json. Static pages, knowledge documents, documentation, or test-only changes alone do not trigger this Worker release. See the workflow path filter.

PREPAREAI coding agentPrepares code and tests
REVIEWIndependent AIReviews the proposed change
DECIDEHumanApproves and merges
EXECUTEWorkflow verifies and deploys
ALL CHECKS PASSVerified result and release record
A CHECK FAILSStop and record evidence

AI prepares; the human authorizes; the workflow executes defined checks. A failure after deployment can leave production changed, so stopping must preserve evidence for recovery.

What this looks like in Ask Mantosh

Ask Mantosh, the assistant on this engineering portfolio, uses this division of responsibility.

For its automatic-release test, Codex prepared and self-reviewed the change, Claude reviewed it independently, and Mantosh made the merge decision. Neither agent had merge or deployment authority. The test change was deliberately small: one comment, with no application behaviour change.

After the merge, GitHub Actions verified and released that specific source. Before writing, the workflow checked that production matched the latest matching release record. That record had to show success: a failed latest attempt blocked progress until reconciled, rather than being hidden behind an older green result.

After deployment, the workflow checked the observed version, service health, a public-profile answer and a completed streaming response. A final observation confirmed the new version served all traffic.

The successful run produced a release record tying the source, deployed version and checks together. That record supports both the next release decision and a later audit.

Automate the work after authorization

The reusable pattern is a controlled handoff: AI delivers a reviewable change; a human authorizes it; a predictable system executes the release and records what happened.

Deterministic automation can still contain bugs. Human approval can still miss defects. The value of this design is that each has a defined responsibility, and the evidence can be inspected when something goes wrong.

Give AI room to do the engineering work. Give production a boundary the AI cannot authorize itself to cross.

Try Ask Mantosh or read the release runbook.

Evidence boundary

The Ask Mantosh test demonstrated one complete release. It did not prove every answer, recovery scenario or private access setting. The release record describes what was observed then, rather than promising future reliability.