AI · LESSON 21 / 25 · English
Deploying AI in Production
A notebook result is only the beginning of a service.
Content reviewed: 22 October 2026 · தமிழில் படிக்க ↗
Understand it in plain language
Production AI includes input validation, versioned models and prompts, evaluation gates, deployment, monitoring, and recovery. Track quality as well as latency, failures, and cost. Start with a limited rollout and a clear fallback. A provider or model name is not an architecture decision; selection depends on measured requirements, data handling, licences, and operating constraints.
How the AI approach works
A production AI system includes the model and everything that makes its behavior usable: input handling, preprocessing, retrieval, tool boundaries, output validation, serving, monitoring, and recovery. A notebook result is evidence about an experiment, not a complete operating system. Define who owns failures and what users see when the model cannot produce a reliable result.
Version the model, tokenizer, prompts, datasets, retrieval index, and relevant code together. A change in one component can alter quality even if the model name stays the same. Use an offline evaluation gate, then a limited rollout or shadow evaluation suited to the task. Keep a tested rollback path and a deterministic fallback where possible.
Monitor quality along with latency, throughput, errors, and cost. Quality labels may arrive later, so combine reviewed samples, user feedback, and appropriate task outcomes. Data drift means inputs changed; concept drift means the relationship relevant to the target changed. A drift alert is a reason to investigate, not an automatic instruction to retrain.
Protect operational boundaries: validate structured output, use least-privilege tool access, limit retries, handle timeouts, and prevent duplicate side effects. Log enough to debug while minimizing sensitive content. A provider outage, retrieval failure, and unsupported user request need different recovery paths.
Break the idea into steps
- Version the dataset, prompt, model configuration, and evaluation set.
- Define release gates and test failures before exposing the service widely.
- Monitor drift and regressions, and keep a rollback path.
Worked example: connect the method to the task
A new support model improves English answers but drops Tamil policy accuracy. A release gate based only on the overall average could miss the regression. Require acceptable performance on important language slices and unsupported-question handling, then run a limited rollout.
If the provider times out after an access-restoration action, retrying the entire agent blindly could repeat the change. Use an operation identifier and verify the action state before retrying. This is software reliability around AI, not something a stronger language model automatically supplies.
Apply the idea: check your reasoning
Think before revealing the answer
Is low API error rate sufficient to conclude an AI assistant is healthy?
Reveal the answer and reasoning
No. It may return fluent but incorrect answers successfully. Monitor task quality and critical slices as well as infrastructure health, and keep a recovery path.
A common mistake: Avoid logging sensitive prompts and outputs by default; define retention, access, and redaction deliberately.
Before you move on
- Explain the main idea without repeating the technical label.
- Identify the approach, its assumptions, and the evidence needed to trust the result.
- Complete the challenge, then compare your reasoning with the answer.
Sources & a deeper next step
The refresh uses primary papers and official documentation. These optional links are in English; you can understand this lesson without reading them first. Product versions and availability can change.