There are six layers to a working agentic system.
Most companies spend their time debating which model to pick. The model sits inside a larger operating system, and almost every production failure happens in the six layers wrapped around it.
> Layer one: experience and trigger. Stop defaulting to a chat box. Real business agents fire on an event: a file arrival, an incoming invoice, a ticket status change, or a schedule. When the agent needs a human, it routes to an exception queue or inbox, not a raw chat transcript nobody on the ops team has time to read.
> Layer two: orchestration and state. Stop treating agents like scripts sitting on someone's laptop. An agent definition should be versioned, bounded, and governed like any other code artifact, with rollback. Store execution history and checkpoints in a database like Postgres so an interrupted run resumes where it left off instead of restarting from scratch.
> Layer three: tools and deterministic logic. The guarantees live in plain, unit-tested code, not in the prompt. Wrap your proven business logic and system-of-record APIs behind one connector service as named tools with stable interfaces. Let deterministic rules handle the fixed steps, and call the model only where judgment is actually required.
> Layer four: trusted context. Do not dump your whole wiki or repo into a giant prompt. Give each domain its own scoped knowledge graph or data catalog that the agent queries mid-run as a tool. When documentation drifts from reality, agents hallucinate. The fix is not a longer prompt. It is authoritative, permission-aware context.
> Layer five: evaluation and human control. Before an agent touches a customer or moves money, build a golden set of real past cases that your domain experts agree are right. Run deterministic checks and LLM-as-a-judge evaluations on every change, and keep a human approval gate on any high-impact or irreversible action. Operators stop pressing buttons and start judging.
> Layer six: runtime and control plane. Every model call goes through one LLM gateway inside your own cloud perimeter. Direct calls to a vendor API are a production defect. Enforce virtual keys per tenant and service, hard spend caps, prompt-injection guardrails, full traces, and internal model aliases so swapping providers is a configuration change, not a rewrite.
Models and frameworks will keep changing. The durable assets are your workflow rules, evaluation sets, context boundaries, and operational ownership.