LLMOps on AWS: From Prototype to Production
A complete playbook for deploying, monitoring, and scaling LLM applications on AWS with best practices.
A GenAI prototype on AWS can be built in a day. Getting it to production — with deployment discipline, observability, evaluation gates, and cost control — is where most teams stall. This is the playbook I use to take LLM applications from notebook to production on AWS.
The Reference Stack
- Amazon Bedrock for managed model access (Claude, Titan, Llama) with IAM-scoped invocation
- Lambda / ECS for stateless inference services, Step Functions for long-running workflows
- OpenSearch for hybrid retrieval, S3 for documents and artifacts
- CloudWatch + X-Ray / OpenTelemetry for tracing and metrics
- CodePipeline or GitHub Actions for CI/CD
Stage 1: Make the Prototype Deployable
Wrap model calls behind a single internal interface (your own gateway module) so prompts, model IDs, and providers are configuration, not code. Store prompts in versioned templates. Pin model versions explicitly — "latest" is how silent regressions happen.
Stage 2: Add an Evaluation Gate to CI
Every deploy should run a golden dataset through the pipeline and fail the build if quality drops:
- name: Run evaluation suite
run: python -m evals.run --suite golden --min-faithfulness 0.85Keep the suite small enough to run in minutes (100–300 cases), and grow it from real production failures.
Stage 3: Private Networking and Guardrails
For enterprise workloads: VPC endpoints for Bedrock and OpenSearch, no public egress from inference services, KMS encryption at rest, and PII detection/redaction before context reaches the model. Bedrock Guardrails (or your own filter stage) belongs in the request path, not in a slide deck.
Stage 4: Observability That Answers Questions
Dashboards should answer: What is P95 latency per stage? What is cost per request per tenant? Which prompts/model versions are serving traffic? What is today's faithfulness score vs. last week's? If a metric can't help you decide something, don't ship it.
Stage 5: Progressive Delivery
Canary new prompts and models to 5% of traffic with automatic rollback on evaluation-metric regression. LLM changes are behavioral, not just functional — treat every prompt edit like a schema migration.
Cost Controls That Actually Work
- Token budgets per tenant with hard caps
- Response caching for repeated queries
- Model routing: small models for classification/extraction, large models for reasoning
- Batch and async paths for non-interactive workloads
The Maturity Checklist
- Prompts and model versions in source control
- Golden-dataset evaluation in CI
- Tracing across every pipeline stage
- Canary deploys with auto-rollback
- Per-tenant cost dashboards
- Incident runbook for quality regressions
LLMOps is mostly normal platform engineering pointed at an unusual workload. The teams that win treat model behavior as something to version, test, observe, and roll back — exactly like code.