Part II · Foundations

Coding

Agents can plan, write, test and improve software. How reliable the result is depends on how the work is set up: the size of the task, the context the agent gets, how work is split between agents, and where people keep control.

Foundational patterns

An agent given a vague job produces a lot of output that nobody can check. "Improve the login page" has no end, while "show a clear error when the password is wrong, with a test that proves it" does. A second agent can challenge the result, but its agreement is not proof, so tests and a person's review still follow.

Task sizing
Give each task a clear outcome, manageable scope and acceptance checks.
Agent customization
Set reusable instructions for the repository, team and kind of work.
Try and try again, but eventually stop
Retry with new evidence, within explicit attempt, time and cost limits. Stop and ask when those limits are reached.
Packaged skills
Package a repeatable procedure with its examples and checks, so that it can be reused.
AI-augmented debugging
Use agents to form hypotheses and investigate; reproduce the issue and test the fix.
Few-shot prompting
Show a few representative examples of the expected change or output, so that the agent can follow the same pattern.
Cross-agent verification
Ask another agent to challenge the work, then verify it with tests and human review. Agreement alone is not proof.
Environmental sandboxing
Constrain execution and access in a safe, task-appropriate environment.

Workflow patterns

The way from idea to change depends on the consequences. To explore an idea, a conversation is enough, and that is what vibe coding is. Consequential work starts from an explicit specification, and a person reviews the agent's plan before it changes anything.

Spec-driven development
Make intent, constraints and acceptance criteria explicit before implementation.
Plan mode
Review the approach before authorising changes.
Async development
Let bounded work progress separately, with clear handovers and review points.
Vibe coding
Explore ideas conversationally; production readiness still requires engineering checks.
Remote agent execution
Run work in a controlled remote environment with scoped access.
Multiple modes of interaction
Move between conversation, editor, terminal and review as the task needs.
Event triggered coding
Start scoped work from an issue, event or check; a trigger is not permission to release.

Context patterns

An agent writes code that fits the system only as far as it knows the system, so these patterns describe what it receives before it starts. Tools and data reach it through MCP, the Model Context Protocol, a standard way to offer data and tools to a model. The protocol alone does not make access safe.

Structured markdown
Keep requirements, conventions and task context in readable, organised files.
Architectural context
Explain boundaries, dependencies and design decisions, not just individual files.
MCP tools
Connect the tools and data a task needs, with explicit access controls, because the protocol alone does not make access safe.
Multi-model prompting
Use different models where each is useful, and give them the same task context and checks.
Agent event hooks
Run a controlled check or add context when something happens in the agent's lifecycle, such as before a tool runs or when a task ends.
Design-to-code
Bring design intent, component rules and visual references into implementation.

The same idea applies to any agent, and is treated in Context engineering.

Orchestration patterns

One focused agent is often enough, so the question is when to add more. The longer an agent runs, the more it needs a defined finish, which is why the long-running patterns come with checkpoints, budgets and a stop condition.

Long running agents
Let agents work across longer tasks with checkpoints and a defined finish.
Forced long running agent loops
Continue deliberately only while acceptance checks remain unmet, within explicit iteration, time and cost budgets. Stop on completion, a blocker or any safety limit; never bypass safeguards.
Subagent delegation
Delegate bounded work with inputs, ownership and a verifiable handover.
Role-scoped agents
Give each agent a defined responsibility and permission boundary.
Task-scoped agents
Create focused agents for a specific deliverable, then close the task.
Non-deterministic agent roles
Choose or adapt roles as the work evolves instead of fixing them in advance, and keep ownership and controls explicit.

The team shapes for any agent, and when to use each, are treated in One agent or a team.

Governance patterns

The earlier groups make an agent more capable, and this one decides how far that capability reaches. The change itself carries a short record of its rationale and verification, so a reviewer can see later why it was made. Permissions per agent are covered in Identity & Access.

Commit context summary
Record a concise rationale, the decisions and the verification with the change. Private internal reasoning stays out.
User-selected agent modes
Let people choose how much the agent may do and when review is required.
Distinct agent permission scopes
Separate read, edit, execute and release permissions by role and task.
Model cost management
Choose suitable models, set budgets and monitor usage; stop or escalate at agreed limits.
Workspace isolation
Keep parallel work and its dependencies separate to avoid unintended interference.

Let’s talk about the agentic enterprise.

Message me on LinkedIn with your challenge, audience and timing to explore a talk, workshop or advisory engagement.

Discuss your challenge on LinkedIn