Concepts
Prompting, retrieval, evaluation and cost. The newest part of the interview, and the part with the least settled ground.
Free Generative AI interview preparation
A focused bank for Generative AI interviews. Every answer is written for Iterlivo so you can prepare without leaving the page or paying for another interview-prep service.
Work through the sections in order. Open a question when you are ready to practise saying the answer out loud.
120
questions
0
practiced
11
sections
Sections
Jump to a section
Search by question or section, then practise at your pace.
Start at the top and work down. Open each prompt, say your answer before revealing the explanation, then continue.
Section 01 / 11
Answer you can say
An LLM estimates the next-token distribution from the tokens already in context, samples or selects one token, appends it, and repeats. It is not performing a database lookup by default, so fluent output can still be unsupported or wrong.
Answer you can say
A token is a piece of text chosen by the model tokenizer; it may be a word, part of a word, punctuation, or code fragment. Token counts affect context limits, latency, billing, batching, and how much conversation or evidence can fit in one request.
Answer you can say
The context window is the bounded amount of tokenized input and output a model can process for one request. System instructions, conversation history, retrieved documents, tool results, and the new answer all compete for that budget, so a larger window does not remove the need for selection and summarisation.
Answer you can say
They are optimised to produce likely continuations, not to verify every claim against reality. Missing context, ambiguous prompts, outdated training data, weak retrieval, and pressure to answer can produce confident inventions. Grounding, refusal rules, citations, tool checks, and evaluation reduce the risk but do not make it zero.
Answer you can say
Temperature changes how sharply or broadly the model samples from its next-token distribution. Lower values usually make extraction and classification more repeatable; higher values can increase variety for brainstorming. The useful setting must be measured because some models or reasoning modes expose different sampling controls.
Answer you can say
Top-k keeps only the k most likely next tokens, while top-p keeps the smallest probability mass whose cumulative probability reaches p. Both restrict sampling to plausible candidates, but they should be tuned with temperature and evaluated for consistency, diversity, and failure rate on the actual task.
Answer you can say
A base model is trained primarily to continue text. An instruction-tuned or chat model receives additional training to follow requests, use conversational roles, and behave according to preference or safety objectives. The distinction affects prompting, tool use, refusal behaviour, and expected output format.
Answer you can say
More context increases cost and gives the model more distractors, duplicates, conflicts, and irrelevant passages to process. Models can also miss details buried in the middle of a long input. Selecting, ordering, compressing, and citing the smallest sufficient context is usually more reliable than sending everything.
Answer you can say
Reasoning models are trained or configured to spend more computation on multi-step problems such as planning, mathematics, or code. They can be wasteful for simple extraction or rewriting, and their visible reasoning should not be treated as a guaranteed proof. Choose by measured quality, latency, cost, and reliability.
Answer you can say
Model knowledge is information encoded in learned parameters and may be stale or incomplete. Retrieved knowledge is evidence selected at request time from a controlled source. Retrieval can improve freshness and citations, but it introduces its own failures: parsing, chunking, search, permissions, ranking, and evidence assembly.
Answer you can say
Define the task, quality bar, latency budget, context needs, data restrictions, tool or structured-output requirements, traffic, and cost ceiling. Shortlist models, then run the same representative evaluation set, inspect failures and variance, and pin the selected version rather than choosing only from a public leaderboard.
Answer you can say
The system converts visual information into model-consumable representations, often with image or document encoders and token-like inputs. Digital PDFs may expose text and layout, while scans need OCR or vision. Exact tables, tiny text, counting, page order, and visual grounding remain common failure cases.
Section 02 / 11
Answer you can say
The application stores conversation state and decides which parts to send on each request. It can trim old turns, summarise them, retrieve relevant memories, or keep durable facts separately. What is stored, what is sent, and what the model remembers are three different design decisions.
Answer you can say
The application declares a tool name, description, and input schema. The model returns a structured tool request rather than pretending it executed the action; application code validates and authorises the arguments, runs the tool, sends the result with its call identifier, and lets the model continue or answer.
Answer you can say
Use the provider or framework structured-output mechanism with a schema, validate every response, reject or retry malformed data, and validate business rules separately. Valid JSON only proves syntax; it does not prove that values are grounded, complete, safe, or logically correct.
Answer you can say
A good tool has a narrow purpose, a precise name and description, typed inputs, predictable results, useful errors, and no unnecessary overlap with other tools. It should enforce permissions and limits in code. Tool descriptions are part of the model context, but they are not a security boundary.
Answer you can say
Retry temporary rate limits, provider errors, and timeouts with exponential backoff, jitter, a timeout, and a cap. Do not blindly retry invalid requests, bad credentials, schema errors, or non-idempotent actions. Save partial progress and use a safe fallback when a retry cannot succeed.
Answer you can say
Streaming sends generated output incrementally so the user sees the first tokens sooner. It improves perceived responsiveness, not necessarily total generation time. The application still needs to handle cancellation, partial output, tool-call boundaries, moderation, persistence, and a broken connection.
Answer you can say
Direct calls are often clearer for a small number of stable operations. A framework helps when you need standard integrations, tracing, providers, retrievers, tools, or graph orchestration. The trade-off is abstraction and debugging complexity, so choose the smallest layer that solves the problem.
Answer you can say
Estimate cost and throughput first, partition the work into resumable jobs, use bounded concurrency and batch endpoints where appropriate, cache deterministic steps, persist each result, retry only failed items, and validate samples. Design for pause, resume, deduplication, rate limits, and reprocessing after a parser or prompt change.
Answer you can say
Record the model and version, prompt version, token usage, latency, cost, retries, errors, tool calls, retrieval identifiers, user or tenant context where safe, and a trace identifier. Redact personal data and secrets, define retention, and make logs useful without turning them into another data-leak surface.
Answer you can say
A chain has application-defined steps and predictable control flow. An agent lets a model choose among tools or next steps at runtime. Chains are usually faster, cheaper, and easier to test; agents are justified when the path genuinely depends on intermediate information and cannot be written as a stable workflow.
Section 03 / 11
Answer you can say
State the application role, task, boundaries, output contract, treatment of missing information, and important safety rules. Keep it short and testable. Put request-specific facts in the user or context message, version the prompt, and never assume prompt wording can replace permissions enforced by code.
Answer you can say
Examples help when the desired format, style, or judgment is difficult to describe in rules. Choose varied examples, include a difficult case, keep labels consistent, and measure whether the added tokens improve held-out performance. Examples can also anchor the model to a narrow pattern and hurt generalisation.
Answer you can say
Keep a versioned test set, run old and new prompts on the same cases, score task quality and failure types, repeat stochastic tasks, and compare cost and latency. Hold out some cases for confirmation and inspect regressions rather than accepting one impressive answer as evidence.
Answer you can say
Give the objective, relevant evidence, constraints, tools, and success criteria without trying to dictate every hidden reasoning step. Ask for a concise result or structured summary when appropriate, then evaluate accuracy, consistency, latency, and cost on the real task.
Answer you can say
Prompt caching reuses a provider or application representation of a repeated prompt prefix or request so repeated instructions and documents cost or compute less. Put stable content before changing content, measure cache-hit behaviour, and ensure cached material respects tenant permissions and data freshness.
Answer you can say
Prompt injection is untrusted text that attempts to change the model’s instructions, reveal secrets, or trigger unsafe actions. It can arrive directly from a user or indirectly through documents, webpages, tool results, or memory. Use least-privilege tools, isolation, validation, and approvals; a prompt-only defence is insufficient.
Answer you can say
Store prompts as versioned artefacts, review them like code, record the version with every trace, run regression and safety tests before release, roll out gradually, and keep a rollback path. Separate prompt content from user data and avoid hidden changes through unpinned templates.
Answer you can say
Context engineering is the deliberate selection, ordering, compression, and presentation of instructions, history, evidence, tool outputs, memory, and schemas for each model call. It treats context as a limited working set rather than dumping every available fact into the prompt.
Answer you can say
Keep the goal, constraints, decisions, open tasks, and important evidence in a compact state; summarise or archive old turns; truncate noisy tool output; retrieve only relevant memory; and store durable notes outside the prompt. Rebuild context intentionally at each step instead of endlessly appending history.
Answer you can say
Yes, a model can propose prompt variants, critique outputs, or generate test cases, but it is not automatically a reliable judge. Use a labelled or human-checked evaluation set, compare against a baseline, detect judge bias, and keep humans in the loop for high-impact decisions.
Section 04 / 11
Answer you can say
Embeddings are numeric representations learned so that items with useful semantic relationships tend to be near one another in a vector space. They support retrieval and similarity tasks, but the geometry is task- and model-dependent; an embedding is not a universal database of meaning.
Answer you can say
Evaluate candidate models on representative queries, languages, document types, chunk sizes, and relevance labels. Compare retrieval quality, dimensions, latency, cost, licensing, privacy, and migration effort. Keep the model identity with every index because changing models requires compatible re-embedding.
Answer you can say
Cosine compares vector direction, dot product combines direction and magnitude, and Euclidean distance measures geometric separation. The correct choice depends on how the embedding model is trained and normalised. Use the metric expected by the model and verify it empirically instead of swapping metrics casually.
Answer you can say
Dense retrieval compares learned vectors and handles semantic similarity. Sparse retrieval, such as term-based scoring, is strong for exact words, identifiers, names, and rare terms. Dense search can miss exact constraints, while sparse search can miss paraphrases, so real systems often combine them.
Answer you can say
Hybrid search combines sparse lexical retrieval with dense semantic retrieval, then merges or reranks the candidate lists. It is useful when a query contains both meaning and exact tokens such as product codes, legal phrases, error messages, or names. Measure the benefit on your own query mix.
Answer you can say
Approximate nearest-neighbour search trades a small amount of exactness for much lower latency at scale. Indexes such as graph- or cluster-based structures reduce the candidates that must be compared. Tune recall, latency, memory, build time, and update behaviour together.
Answer you can say
HNSW builds navigable layers of connected vector points and searches from coarse upper layers toward a local neighbourhood in lower layers. More connections and search effort often improve recall but increase memory and latency. The exact tuning names vary by database, so evaluate the index on your workload.
Answer you can say
Inverted-file indexes partition vectors into coarse regions so search visits only selected regions. Product quantization compresses vectors into smaller codes to reduce memory and improve scale, usually with some recall loss. They are useful when storage and throughput matter more than exact comparison.
Answer you can say
Metadata filters restrict candidates by fields such as tenant, language, date, or document type. Applying them during retrieval is safer and more efficient than retrieving unauthorised content and filtering after generation. Index design must support the filter pattern or vector recall and latency may suffer.
Answer you can say
Maximum marginal relevance balances similarity to the query against redundancy among selected results. It can improve context diversity when a vector search returns many near-duplicate chunks, but too much diversity may remove the most useful repeated evidence. Tune it against answer quality, not variety alone.
Answer you can say
A reranker examines the query and each retrieved candidate together, often with a more expensive relevance model, and produces a better ordering than the initial fast retriever. Retrieve a wider candidate set, rerank it, keep a small context set, and measure whether quality justifies the extra cost and latency.
Answer you can say
They represent a document or query with multiple token- or passage-level vectors and compare finer-grained interactions instead of compressing everything into one vector. This can improve matching for detailed text, but storage, indexing, and serving are more complex than single-vector retrieval.
Answer you can say
Build a new versioned index, re-embed the corpus, validate retrieval against the old baseline, and switch traffic deliberately. Do not mix incompatible vectors in one similarity space. Keep the old index until the new one passes quality, freshness, permission, and rollback checks.
Answer you can say
Check parsing and metadata first, then chunk boundaries, embedding model and metric, query rewriting, filters, index freshness, candidate count, and reranking. Search the exact phrase and the semantic query separately. Store retrieval traces so you can identify whether the miss happened before or after ranking.
Section 05 / 11
Answer you can say
RAG retrieves relevant evidence at request time and places it into a model prompt so the answer can use private, current, or cited information. The system has an indexing path and a query path; errors in parsing, retrieval, permissions, context assembly, or generation can each affect the result.
Answer you can say
Use RAG when knowledge is private, changing, large, or needs source citations. Use fine-tuning mainly for behaviour, format, style, or a narrow repeated task. They can be combined, but fine-tuning is not a reliable way to keep frequently changing facts current.
Answer you can say
Load and parse documents, preserve useful metadata, split them into retrievable units, embed and index them, retrieve candidates at query time, optionally rerank or filter them, assemble a bounded context, generate a grounded answer, and expose citations or refusal behaviour when evidence is insufficient.
Answer you can say
Start from document structure such as headings, paragraphs, code blocks, or table boundaries. Small chunks improve precision but can lose context; large chunks preserve context but add noise and tokens. Preserve parent titles and metadata, then compare strategies on labelled retrieval and answer cases.
Answer you can say
Fixed-size chunking splits by token or character limits and is simple and predictable. Semantic or structure-aware chunking uses headings, paragraphs, topic shifts, or document elements to keep coherent units. A hybrid approach often works best, with hard limits to prevent pathological chunks.
Answer you can say
Overlap repeats boundary text so a fact is less likely to be split away from its context, but too much overlap creates duplicates and cost. Parent-child retrieval indexes small children for precision while returning a larger parent section for context. Both need evaluation because more text is not always better.
Answer you can say
Use format-aware parsing, OCR or vision for scans, and preserve page, heading, table, and source metadata. Keep table headers with values and validate extraction on representative pages. Route complex documents through more expensive processing rather than assuming plain text extraction is correct.
Answer you can say
Route structured questions to a read-only database or analytics tool, provide the schema and business definitions, validate generated queries, restrict tables and rows, and show the calculation or source. Combine database results with documents only when the question needs both facts and policy context.
Answer you can say
Conversational RAG rewrites or interprets a follow-up question using conversation context, retrieves evidence for the resolved query, and answers with the relevant history. Keep the retrieval query separate from the visible response, control history growth, and avoid carrying irrelevant or unauthorised context between turns.
Answer you can say
Multi-hop RAG decomposes a question or follows a chain of evidence across multiple documents or entities. The system retrieves one step, extracts a useful intermediate fact, and uses it to guide the next step. It needs limits, traceability, and checks against compounding early retrieval errors.
Answer you can say
Citation-aware RAG preserves source identifiers during retrieval and asks the model to attach claims to supporting evidence. A citation is useful only when the cited passage actually entails the claim, so validate citation coverage and support instead of displaying source links without checking them.
Answer you can say
Attach tenant and access metadata to every retrievable unit, enforce filters during retrieval, isolate caches and memory, and test cross-tenant and revoked-access cases. Do not rely on the model to hide unauthorised passages after they have entered its context.
Answer you can say
GraphRAG combines extracted entities or relationships with document retrieval so the system can navigate connections and summarise a collection. It can help with relationship-heavy or global questions, but graph construction and freshness are expensive; add it when measured failures justify the complexity.
Answer you can say
Multimodal RAG retrieves and reasons over text, images, tables, audio, or video representations instead of reducing everything to plain text. It requires modality-aware parsing, embeddings or indexes, evidence references, and evaluation for visual or temporal details that text-only retrieval misses.
Section 06 / 11
Answer you can say
Hybrid RAG combines multiple retrieval strategies or knowledge sources, such as sparse search, dense vectors, metadata, databases, graphs, and APIs. A router or fusion step decides how evidence is combined. The design should be driven by query types and measured failure modes, not by adding every retriever.
Answer you can say
Query rewriting transforms a vague, conversational, or underspecified request into a retrieval-friendly query. It can resolve references, add missing terms, or produce several variants, but it can also change the user’s intent. Log original and rewritten queries and evaluate both retrieval gain and semantic preservation.
Answer you can say
Multi-query retrieval generates several related search formulations, retrieves for each, and merges or reranks the candidates. RAG-Fusion adds ranking aggregation to favour evidence that appears useful across formulations. It improves recall at the cost of extra calls, duplicates, latency, and more complex traces.
Answer you can say
HyDE asks a model to draft a hypothetical answer or document, embeds that generated text, and uses it to search for real evidence. It can bridge a mismatch between a short question and longer documents, but generated text may introduce wrong assumptions, so compare it with direct and rewritten retrieval.
Answer you can say
Contextual compression removes or rewrites irrelevant parts of retrieved documents before generation, often using a model or extractor conditioned on the query. It can reduce noise and token cost, but introduces another failure point and should be checked for dropped evidence and altered meaning.
Answer you can say
For retrieval, measure whether the expected evidence appears in the candidate set and how highly it ranks. For generation, provide controlled evidence and score correctness, relevance, faithfulness, refusal, and citation support. Separate tests help identify whether the main failure is search or synthesis.
Answer you can say
Faithfulness asks whether the answer is supported by the retrieved evidence rather than merely sounding plausible. You can use claim extraction, evidence entailment checks, human review, or calibrated judges, but each method needs validation. A relevant document can still fail to support a particular claim.
Answer you can say
Relevance asks whether the response addresses the user’s question; completeness asks whether it covers the required parts without omitting important constraints. Use labelled examples with expected points or criteria, include unanswerable and multi-part cases, and score concise correct answers fairly.
Answer you can say
Collect real questions, expected answers, supporting source IDs, and acceptable refusal cases. Include easy, ambiguous, adversarial, multi-hop, permission-sensitive, stale, and unanswerable examples. Use synthetic generation to expand coverage only after human review and retain production failures as regression cases.
Answer you can say
Compare judge decisions with labelled human examples, define a narrow rubric, test position and verbosity bias, check agreement across domains, and monitor drift. Use judges for scalable signals, not as unquestioned truth, and keep a human-reviewed calibration set.
Answer you can say
Inspect context ordering, duplicate or conflicting passages, prompt instructions, claim extraction, model behaviour with the correct evidence directly, citations, and output truncation. Run component tests to isolate whether the failure is assembly, instruction following, synthesis, or evidence interpretation.
Answer you can say
Define what counts as insufficient evidence, use retrieval and confidence signals carefully, instruct the model to abstain, and validate the answer against evidence. Test false confidence and false refusal separately; a system that refuses everything is safe but not useful.
Answer you can say
Version documents, store effective and expiry times, update or delete index entries, filter by temporal validity, and test historical versus current questions. Caches, summaries, graph edges, and long-term memory need freshness policies too; updating the vector index alone may not be enough.
Answer you can say
Treat documents and search results as untrusted data, separate evidence from instructions, constrain tool permissions, validate actions in application code, scan for suspicious content, and require approval for sensitive operations. Test malicious documents, webpages, citations, and poisoned memory.
Section 07 / 11
Answer you can say
An agent is a model-driven loop that observes a goal and context, chooses an action or tool, receives a result, and decides whether to continue or finish. The application still owns state, permissions, limits, execution, and validation; autonomy is not a substitute for engineering controls.
Answer you can say
Do not use an agent when the steps are known, the task is safety-critical and deterministic control is required, or a simple retrieval or workflow is sufficient. Agents add latency, cost, nondeterminism, and debugging surface. Start with a fixed chain and add autonomy only when the measured problem requires it.
Answer you can say
ReAct interleaves reasoning or planning with actions and observations: the model selects a tool, sees the result, and chooses the next step. In production, keep internal reasoning private as appropriate, expose useful action traces, define stopping conditions, and validate every action outside the model.
Answer you can say
Set limits on steps, time, retries, tokens, tool calls, and money; detect repeated actions; define completion conditions; persist progress; and hand over when the agent is stuck. Enforce budgets in application code rather than asking the model to police itself.
Answer you can say
Pause before irreversible, external, financial, or sensitive actions. Show the proposed action, arguments, evidence, and expected consequence; let a person approve, reject, or edit it; persist state; and resume safely. The approval step should be auditable and idempotent.
Answer you can say
Tool calling is a model interaction in which the model proposes a named action with arguments. MCP is a protocol for exposing tools, resources, and prompts through a standard server-client arrangement so compatible applications can connect to capabilities consistently. Both still require authorisation and validation.
Answer you can say
Expose a small set of focused, typed capabilities; return compact, useful results and actionable errors; authenticate the client; enforce least privilege and tenant boundaries; version contracts; log calls safely; and test malformed arguments, slow dependencies, revoked access, and partial failure.
Answer you can say
Separate thread memory from durable application memory. Keep current task state in checkpoints, store selected user preferences or facts separately, retrieve only relevant memories, attach provenance and timestamps, and support correction, expiry, deletion, and tenant isolation. Never treat the whole chat transcript as a memory strategy.
Answer you can say
It is the design of the agent’s working context at every step: goal, state, plan, tools, evidence, memory, errors, and output constraints. Good context is minimal but sufficient, refreshed after actions, and structured so the model can distinguish trusted instructions from untrusted results.
Answer you can say
Use multiple agents when tasks need genuinely different tools, permissions, expertise, or parallel context, and the coordination cost is justified by measured quality or throughput. A supervisor, sequential handoff, parallel specialists, and team-of-teams designs have different failure and observability trade-offs.
Answer you can say
Measure task success, tool selection, argument correctness, path efficiency, recovery, safety, cost, latency, and human handoffs. Read traces, classify failure modes, test tool and environment failures, and validate any automated judge against human-labelled tasks.
Answer you can say
Run generated code outside the application in an isolated environment with restricted files, network, credentials, time, memory, and processes. Treat code, shell commands, SQL, and package requests as untrusted; return only necessary outputs and destroy the workspace after use.
Answer you can say
Review their code, permissions, dependencies, data handling, and update process; pin versions where possible; give each server narrow credentials; isolate tenants; validate results; and test tool-description and tool-result injection. Treat an external tool as a privileged integration, not a harmless plugin.
Answer you can say
Compare production traces, inputs, tool results, context size, latency, model versions, permissions, and user goals with the test environment. Reproduce the smallest failing trace, identify whether planning, retrieval, execution, or recovery failed, then add the case to regression and safety evaluation.
Section 08 / 11
Answer you can say
LangChain provides reusable abstractions and integrations for models, prompts, tools, retrievers, structured output, and application composition. It can speed up common patterns, but it does not remove the need to understand the underlying API, inspect traces, control permissions, and test each component.
Answer you can say
A runnable or chain composes model calls, prompts, parsers, retrievers, and other steps into a callable pipeline with a common execution shape. The benefit is composition and observability; the risk is hiding important data transformations or errors behind abstraction unless the trace is inspected.
Answer you can say
Use explicit ingestion, splitting, embedding, and storage components; compose query retrieval, optional reranking, prompt assembly, generation, and output parsing; attach metadata and citations; then evaluate retriever and generator separately. Keep provider-specific assumptions visible and version the chain.
Answer you can say
Avoid it when a direct provider call and a few explicit functions are clearer, when abstraction makes debugging or latency unacceptable, or when a dependency adds more surface than value. The decision should consider integrations, team familiarity, upgrade risk, tracing, and the cost of replacing it later.
Answer you can say
LangGraph is designed for stateful, multi-step agent and workflow execution represented as nodes and transitions over shared state. It is useful when you need branches, loops, persistence, interrupts, human approval, resumability, or explicit control rather than a single opaque agent loop.
Answer you can say
A checkpointer saves thread or run state so a graph can continue, resume after interruption, support human review, or recover from failure. A store holds application-defined durable information such as preferences or knowledge across threads. They solve related but different scopes of persistence.
Answer you can say
A graph can pause before or during a sensitive step, persist its state, present the proposed action to a person, and resume with an approval, rejection, or edited value. The node must be safe to resume and external side effects need idempotency or a confirmation record.
Answer you can say
CrewAI models collaborative work through agents, tasks, crews, and flows. It can be useful when roles, delegation, sequential work, or event-driven business workflows make the team structure easy to communicate. You still need explicit limits, state, observability, permissions, and evaluation.
Answer you can say
A crew represents agents collaborating on a task or process, while a flow represents a more explicit application workflow driven by events, state, and controlled transitions. Use a crew for role-based collaboration and a flow when reliability, routing, persistence, and business control matter more than open delegation.
Answer you can say
Compare the control model, state and persistence, tool integration, human approval, observability, deployment model, team familiarity, and failure handling. LangChain is broad composition, LangGraph is explicit durable graphs, and CrewAI emphasises role-based crews and flows; the task should decide the tool.
Answer you can say
Test the underlying tools and nodes independently, then run deterministic fixtures through the chain or graph, followed by scenario and failure tests. Capture framework traces, assert state transitions and permissions, inject tool failures, and evaluate the final task outcome and cost.
Answer you can say
Pin compatible versions, isolate framework code behind small application interfaces, record prompts and state schemas, avoid leaking framework objects through the whole codebase, test upgrades against traces and evaluations, and keep a direct fallback for critical provider calls where practical.
Section 09 / 11
Answer you can say
Fine-tune when you need repeatable behaviour, style, structure, or a narrow high-volume capability that prompting cannot reliably deliver. Do not use it as the default way to add changing factual knowledge; retrieval or a tool is usually better for that.
Answer you can say
LoRA trains small low-rank adapter parameters while freezing most of the base model. QLoRA combines adapter training with a quantised base model to reduce memory requirements. Both can make customisation cheaper, but data quality, held-out evaluation, and deployment compatibility still determine success.
Answer you can say
Define the task and output contract, remove sensitive or duplicated examples, represent conversations consistently, include diverse and difficult cases, check label quality, split by user or source to avoid leakage, and keep a held-out set that reflects deployment rather than random near-duplicates.
Answer you can say
Compare it with a prompted or RAG baseline on held-out task cases, safety tests, and regression cases from other capabilities. Measure quality, consistency, latency, cost, and failure types; inspect whether the model memorised examples or lost general usefulness.
Answer you can say
Captioning converts an image into a text description, while multimodal RAG retrieves and reasons over visual or mixed evidence for a question. Captioning can lose table layout, exact values, or spatial relationships, so the representation should match the task and evidence requirement.
Answer you can say
Speech recognition, turn detection, model generation, tool calls, and speech synthesis all sit on the conversational path. Stream each stage where possible, support interruption, use short responses, parallelise safe work, and design a fallback when a dependency misses the response-time budget.
Answer you can say
Evaluate transcription or visual extraction separately from reasoning and action success. Include accents, noise, interruptions, poor images, small text, timing, refusal, accessibility, and end-to-end task completion. Measure user correction rate and latency as well as answer quality.
Answer you can say
Distillation trains a smaller model using outputs or preferences from a stronger teacher for a constrained task. It can reduce cost and latency, but the student may copy teacher mistakes or lose edge-case capability. Compare it with prompt routing and smaller off-the-shelf models before committing.
Section 10 / 11
Answer you can say
Define the quality bar and failure policy, version prompts and indexes, secure secrets and data, add timeouts and limits, persist state where needed, instrument traces, evaluate before release, roll out gradually, and prepare fallbacks and human escalation. Production is the whole system, not just the model call.
Answer you can say
Monitor errors, latency distributions, time to first token, token usage, cost, provider rate limits, retrieval quality, tool failures, refusals, user feedback, safety incidents, and sampled answer quality. Link all steps with trace IDs and alert on changes in both technical and task-level metrics.
Answer you can say
Measure cost by task and stage, then cache stable prefixes or results, route simple work to cheaper models, shorten context and outputs, batch offline jobs, parallelise safely, compress retrieval, and fine-tune or distil only when the measured workload supports it. Re-run quality and safety evaluations after each change.
Answer you can say
Measure each stage first. Stream output, parallelise independent retrieval or tool work, remove unnecessary sequential model calls, use faster models for routing or extraction, cache repeated work, limit output, and degrade gracefully. Never trade latency for an unmeasured quality loss.
Answer you can say
Semantic caching reuses a result for a new request judged similar to an earlier one. A false match can return the wrong answer, stale knowledge, or another user’s private data. Use strict similarity and scope rules, freshness controls, permission-aware keys, and bypasses for personalised or high-risk actions.
Answer you can say
Separate instructions from untrusted content, minimise tool permissions, validate arguments and outputs in code, isolate credentials, redact secrets, restrict network access, filter retrieval by authorisation, require approval for sensitive actions, and red-team direct, indirect, tool, memory, and multimodal injection paths.
Answer you can say
Use a tested provider or model fallback where contracts are compatible, fail gracefully, queue or retry temporary work, show clear user status, preserve resumable state, and alert operators. Fallback quality, safety, cost, and tool behaviour must be evaluated before the outage rather than improvised during it.
Answer you can say
Pin versions, run regression and safety suites, compare cost and latency, test shadow or canary traffic, monitor task-level failures, keep the old path available, and roll back quickly. Include retrieval, tool, and permission tests because model changes can alter action choices, not only text.
Section 11 / 11
Answer you can say
Clarify users, data boundaries, freshness, citations, and escalation. Build ingestion with document versions and permissions, hybrid retrieval with tenant filters, reranking and bounded context, a model gateway, citation checks, audit traces, feedback, evaluation, deletion workflows, and a human fallback. Explain cost and failure trade-offs.
Answer you can say
Use a planner or controlled workflow to create sub-questions, parallel retrieval or browsing workers with bounded permissions, evidence records with source IDs, synthesis with citation validation, a final factuality check, progress state, cost and time budgets, and human review for publication. Do not let the agent treat its draft as evidence.
Answer you can say
Start with the simplest baseline, name the measured problem it failed to solve, explain the chosen mechanism and alternatives, quantify the quality, cost, latency, and operational trade-offs, and describe what you would remove if the constraints changed. A good defence shows judgment, not tool-name recall.
Answer you can say
Compare traces and evaluation slices across versions, identify changes in documents, queries, prompts, models, embeddings, index freshness, tools, permissions, and traffic. Separate retrieval, context assembly, generation, and action failures; reproduce a small case; fix the cause; and add the incident to regression and red-team tests.