AI5 min read10 interview questionsNew · November
AI observability: seeing what your AI app is doing
Traces, cost, speed and quality checks that show why an AI feature behaves as it does.
In one sentenceAI observability means recording each step of an AI request, including prompts, answers, cost and time, so you can find and fix problems.
Think of it like thisIt is a flight recorder for your AI feature: when something odd happens, you can replay what led to it.
The big picture
Tap any step to see where to use it, how to use it and an example result.
Why normal monitoring is not enough
A normal server can be healthy while the AI gives bad answers. You need to see the actual prompts, retrieved documents and model replies, not only CPU and error counts.
What to record
A trace is one request from start to finish, made of steps called spans. For each model call record:
- The prompt and the answer (with sensitive data removed).
- Model name and settings such as temperature.
- Input and output tokens, and the cost.
- Time taken and any error.
- Which documents or tools were used.
Quality signals
Add automatic checks, such as a judge model or simple rules, plus user feedback like thumbs up and down. Watch these over time to catch quality drifting after a model or prompt change.
Privacy and cost
Prompts can contain personal data, so redact it, limit who can view logs and set retention periods. Logging every detail also costs money, so sample high-volume traffic.
Common mistakes
- Logging nothing until something breaks.
- Storing raw prompts that contain personal data or secrets.
- Watching speed and errors but not answer quality.
- Changing a prompt or model without comparing before and after.
Quick recap
- Record a trace for every AI request.
- Track tokens, cost, speed and errors per step.
- Measure quality, not only uptime.
- Protect personal data in logs.
Try it yourself
Pick any AI feature and sketch its steps on paper. Mark where you would record time, tokens and a quality score.
Top 10 interview questions
Ordered from basic to advanced. Try answering out loud first, then open the answer.
What is AI observability?Basic
The practice of collecting and examining data about how an AI application runs, such as prompts, responses, cost, speed and quality, to understand and improve its behaviour.
How is it different from normal application monitoring?Basic
Normal monitoring shows whether the system is up and fast. AI observability also shows what the model was asked and said, because wrong answers do not cause errors.
What is a trace and what is a span?Basic
A trace follows one request through the whole system. A span is one step inside it, such as a retrieval, a model call or a tool call, with its own timing and details.
Why track token usage?Basic
Tokens drive cost and limits. Tracking them per request and per feature shows where money goes and catches prompts that grow too long.
What should you log for each model call?Intermediate
Model and settings, prompt and response (with sensitive data redacted), token counts, latency, errors, and identifiers that link it to the user session and the trace.
How do you detect quality problems in production?Intermediate
Run automatic evaluations such as a judge model or rule checks on a sample, collect user feedback, and watch the trends. A sudden drop after a release points to the change.
How do you debug a wrong answer in a RAG system using traces?Intermediate
Open the trace and check what was retrieved. If the right document was missing, fix retrieval. If it was present but ignored, fix the prompt or the model step.
What is OpenTelemetry and why does it matter here?Intermediate
An open standard for traces, metrics and logs. Using it for AI calls avoids lock-in and lets AI data flow into the same tools you already use for other services.
How do you handle privacy when logging prompts?Advanced
Redact personal data before storing, restrict access, encrypt the logs, keep them only as long as needed and let customers opt out where required. Consider storing metadata only for sensitive features.
How would you set alerts for an AI feature?Advanced
Alert on error rate, latency and sudden cost jumps, plus quality scores falling below a threshold or feedback turning negative. Tie alerts to a runbook so someone knows what to check first.
Guides are simplified on purpose. Tool names and details change, so check the official documentation before relying on a detail.