Certablo
← Knowledge Base

GenAI Observability

Observe the complete GenAI request path across tokens, latency, errors, model identity, retrieval, safety, agents, tools, cost, and quality—with Bedrock invocation logs, CloudWatch, traces, and actionable SLOs.

AIP-C01

Visual overview

GENAI OPERATIONSOptimize only after measuring quality, tokens, latency, throughput, errors, and cost together
01MeasureTokens · latency · quality
02DiagnosePrompt · model · retrieval
03OptimizeCache · prune · batch · route
04ValidateGolden set · alarms · SLOs
Cost and latency optimizations are valid only when the quality target still holds. Re-run evaluation after changing model, prompt, context, cache policy, or retrieval.
AWS SERVICE MAPEnd-to-end GenAI telemetry

Bedrock emits model usage evidence, CloudWatch aggregates operational signals, and X-Ray connects supported application dependencies across a request path.

Amazon BedrockModel invocation and usage signals
Amazon CloudWatchMetrics, logs, dashboards, alarms
AWS X-RayDistributed application tracing
EXAM-RELEVANT MECHANICS

Technical reference

A useful GenAI telemetry model connects infrastructure health to model usage and semantic quality without leaking sensitive content unnecessarily.

UsageInput + output tokens / call

Attribute model consumption by model/profile, feature, release, or safe request metadata.

LatencyEnd-to-end + stage percentiles

Separate API/queue, retrieval, model, tool, and post-processing time when diagnosing slow requests.

ReliabilityErrors · throttles · backlog

Watch both direct failures and accumulating asynchronous work that predicts a future SLO breach.

QualityTask-specific score / feedback

Define groundedness, correctness, task completion, or acceptance criteria that can be trended over releases.

Agent telemetrySteps · tools · stop reason

Trace tool selection, arguments after redaction, duration, status, handoffs, and bounded termination.

LoggingCloudWatch Logs / S3

Invocation logging is configurable and can contain sensitive original content; apply least privilege and retention.

Service limits and capabilities can change. Values shown here reflect the current AWS documentation; use the linked official sources below as the source of truth.

Observe four layers: transport, model, retrieval/tools, and quality

A healthy HTTP status does not mean a healthy GenAI application. Transport metrics cover request rate, queue depth, errors, throttling, and latency. Model metrics cover model/profile identity, token counts, time to first output where available, total generation latency, and guardrail interventions. RAG/agent metrics cover retrieval latency/relevance, tool selection, tool error rate, step count, and stop reason. Quality metrics cover groundedness, factuality, task completion, user feedback, and domain-specific acceptance.

Correlate these layers with one safe request or trace identity. A high-latency complaint can then be attributed to API queueing, retrieval, model generation, or a slow agent tool rather than appearing as one opaque duration. Dashboards should preserve both percentiles and segmentation by model, prompt version, tenant/feature, Region/profile, and release where those dimensions are operationally useful.

Bedrock invocation logging exposes request-level model evidence

Amazon Bedrock model invocation logging can publish supported invocation records to CloudWatch Logs and/or S3. AWS documents request/response metadata plus fields such as input and output token counts; large or binary content can be delivered to S3 according to the logging configuration. Invocation logging is disabled by default and should be enabled only with an explicit sensitive-data and retention design.

Request metadata can help attribute traffic to a team, environment, feature, or workflow without parsing prompt contents. Query logs to find top token consumers, throttled workloads, unexpected model IDs, or sudden response-size changes. Treat raw prompt/output logging as sensitive because it can contain customer, confidential, or adversarial content; use redaction/data-protection controls and tight access.

Quality needs operational indicators and sampled evaluation

Quality cannot usually be inferred from CPU or latency. Maintain online signals such as user feedback, citation/grounding checks, safety intervention rate, tool success, and task completion. Periodically sample production-like requests into offline evaluation, respecting privacy, to detect regressions that a simple average rating can miss. Segment by scenario because a model may improve general writing while degrading a critical domain task.

Hallucination rate should be defined by a measurable rubric instead of a vague label. For RAG, distinguish unsupported claim, missing retrieval, stale source, and citation mismatch. For agents, distinguish wrong tool selection, invalid arguments, tool execution failure, and incorrect synthesis. These classifications connect telemetry to the component that needs remediation.

Alerts should point to an operator action

Create alarms for conditions that imply a decision: sustained error/throttle rate, queue backlog, latency percentile, token-cost anomaly, safety-event spike, tool failure, or missing telemetry. Use baselines/anomaly detection where static thresholds are poor, but keep clear runbooks for what an operator should inspect next. An alarm that always fires during normal traffic becomes noise and reduces incident response quality.

After a deployment, compare golden-dataset results and production indicators to the previous release. A diff of outputs can reveal behavioral changes even when aggregate scores appear stable. Retain release identifiers in telemetry so an incident can be tied to the exact model, prompt, retrieval, guardrail, or agent configuration.

Key takeaways

  1. 01

    Observe transport, model, retrieval/tools, and quality as separate but correlated layers.

  2. 02

    Bedrock invocation logging can expose token and request/response evidence to CloudWatch Logs and/or S3 but requires explicit privacy controls.

  3. 03

    Quality telemetry must be defined with task-specific rubrics; a successful API response is not a quality signal.

  4. 04

    Agent and RAG failures should be classified by stage so the responsible component can be fixed.

  5. 05

    Alerts need actionable thresholds, segmentation, release identifiers, and a runbook.

Official AWS sources

Use these primary AWS resources for the source material behind this article and for deeper reference.