1. The Direct Answer
An AI prototype is ready for production only when its failure handling is tested, observable, and commercially bounded. It is never ready simply because a model generated five impressive answers during an internal demo.
Before you authorize customer-facing deployment or commit to service SLAs around an AI workflow, the architecture must pass four core criteria:
- Multi-Step Error Compounding: In multi-step or agentic workflows, does the end-to-end compound accuracy meet your business domain's tolerance for errors?
- Blast Radius Isolation: Is the probabilistic model separated from dangerous mutations (such as debited balances, modified production databases, or unreviewed emails) by deterministic software gates?
- Unit Economic Viability: Does the worst-case token consumption cost per session leave a healthy gross margin against your customer subscription price?
- Graceful Degradation: When the upstream model API experiences latency spikes or service outages, does your application fail gracefully with a helpful fallback experience, or does it hang and crash?
2. What I Investigate First
When an executive brings me in to review an AI initiative prior to rollout, I inspect the software surrounding the model rather than the model itself:
- Sequential Step Reliability: We map every step in the agent or retrieval-augmented generation (RAG) pipeline. Under the simplifying assumption of independent step probabilities, if each of three sequential steps operates at a 90% individual success rate, the compound probability of complete end-to-end success is:
P(success) = 0.90 × 0.90 × 0.90 ≈ 72.9%
By five sequential steps, compound reliability falls below 60%. A system that looks dependable in isolated single-turn prompts can degrade significantly in multi-turn execution without automated evaluation datasets. - Defensive Schema Enforcement: Does downstream application code accept unstructured text responses from the model, or is every generation parsed and validated through rigid data schemas (such as Pydantic or Zod) before state changes occur?
- Token & Latency Ceilings: What happens when a user submits an adversarial prompt or a lengthy unstructured document? Is there an enforced token budget and timeout threshold that safely terminates runaway loops?
Never evaluate an AI system by what it does when everything goes right. Evaluate an AI system by how safely and predictably it behaves when inputs are messy and upstream APIs fail.
3. The 4-Pillar Go / No-Go Decision Framework
Pillar 1: Mathematical Accuracy vs. Workflow Complexity
Single-prompt workflows (such as summarizing an article or translating a paragraph) carry minimal failure compounding. However, autonomous agents that repeatedly plan, fetch data, call external APIs, and make decisions compound errors quickly.
Decision Criterion: If your workflow requires multiple autonomous sequential steps without human review, and the business cost of an error is high (legal compliance, financial accounting, or direct client outreach), the project is NO-GO for full autonomy. Restructure the system into a human-in-the-loop workflow where the model prepares a structured proposal and an operator confirms execution.
Pillar 2: Blast Radius & Defensive Output Schemas
A severe vulnerability in early prototypes is granting an LLM direct database write access or permission to trigger external webhooks without an intermediary software layer.
Decision Criterion: Foundation model outputs must always be treated as untrusted input. Every output must pass through a defensive schema: typed validation, domain whitelists, and circuit breakers. If an agent can alter production state without passing through standard validation barriers, it is NO-GO.
Pillar 3: Unit Economics & Token FinOps
During prototyping, testing frontier reasoning models costs a few dollars across an internal team. In production, customers will submit large documents, trigger retry loops, and conduct long context-heavy sessions.
Decision Criterion: Model your Peak Session Cost. If an un-cached session can consume substantial token spend while the customer pays a flat monthly fee, unit economics can quickly become unviable. Implement prompt caching, semantic caching, small-model routing (delegating classification to lightweight models), and hard session token ceilings.
Pillar 4: Observability & Traceability
When a customer reports an erroneous or hallucinated response, can your engineering team inspect a privacy-filtered record of the prompt, the retrieved document chunks, the model configuration, and the latency trace for that specific session?
Decision Criterion: Without distributed tracing and structured logs, debugging non-deterministic systems in production is impractical. If you cannot trace inputs to outputs, the release is NO-GO.
4. An Illustrative Architectural Scenario
The following scenario illustrates a common architectural pattern in enterprise diagnostic tooling:
The Operational Friction: A SaaS company builds an AI workflow to review incoming customer configuration issues, query documentation, and propose automated remediation patches. In internal testing on clean tickets, the system performs accurately.
The Architectural Audit: When tested against malformed tickets with conflicting error logs, the model occasionally misidentifies customer identifiers, creating a severe risk of applying configuration patches to the wrong client environment if granted direct database write permissions.
The Remediation Pattern: Direct write permissions are removed. The system is restructured into a two-tier architecture: the model synthesizes the issue and generates a validated JSON diff; the diff is presented on an internal dashboard; a support engineer reviews and applies the patch with a single click.
The Business Outcome: The company captures the operational speed of automated synthesis while reducing the risk of unauthorized mutations. Authorization and tenant isolation still require independent enforcement.
5. The Pre-Launch Verification Checklist
- [ ] Do you have an automated evaluation suite of realistic, messy, and adversarial test cases running in CI?
- [ ] Are model generations strictly validated against typed schemas before any database or API execution?
- [ ] Is there an enforced token ceiling and timeout budget on every user session?
- [ ] Does the system feature a deterministic fallback when third-party AI APIs time out or return rate-limit errors?
- [ ] Can your team reconstruct a privacy-safe trace (prompt, context, generation) for any customer interaction?
For a detailed technical post-mortem on why prototypes fail in live environments, read our architectural analysis: Why AI Projects Work in Demos but Fail in Production. To schedule a fixed-scope technical evaluation of your AI pipeline, explore our Production Architecture Pre-Mortem.
What production agent work taught me
In multi-agent system design, validation, schema enforcement, and clarification paths need explicit workflow ownership rather than prompt-only instructions. Separately, offloading blocking model or database work to asynchronous queues after tracing hot paths reduces tail latency significantly compared to synchronous execution. Streaming a plausible answer is not evidence that downstream state completed cleanly.
Evaluate each transition separately: retrieval evidence, tool authorization, output validation, and recovery. A confidence score is not a calibrated probability unless tested against representative outcomes. Below a validated threshold, abstain, clarify, or route to human review rather than silently proceeding.
Need an Objective Pre-Launch Architecture Review?
Before deploying an AI system to live customers, ensure your operational risk, token economics, and error boundaries are verified. Request a structured Production Architecture Pre-Mortem.
Explore The Architecture Pre-MortemInspect a concrete public Production RAG engineering reference for lexical retrieval, evaluation gates and operational boundaries. It documents the local fixture results and deployment limitations, not customer accuracy or production certification.