AI Engineer Interview & Real Codebase Arena
Click any company below to open its full dedicated interview page with pre-flight setup instructions, downloadable Web+AI, Classic ML, Enterprise RAG, or Agentic MCP starter codebases, With-AI vs No-AI guidelines, and a complete 5-round hiring loop.
OpenAI
Staff Applied AI / Inference Systems Engineer
Anthropic
Staff Claude Code / Agent Infrastructure Engineer
Google DeepMind
L6 Staff Multimodal RAG & Distributed Inference Lead
Meta AI (FAIR)
E6 Staff Open-Weights Serving & Post-Training Engineer
Microsoft Azure AI
Principal Applied AI / GraphRAG Architect
Amazon AWS AI
Principal Bedrock Agents & FinOps Engineer
Databricks Mosaic
Staff Compound AI & Lakehouse Vector Engineer
NVIDIA AI Systems
Principal TensorRT-LLM / NIM Inference Architect
Snowflake Cortex
Staff Cortex Search & AI Gateway Engineer
Scale AI
Staff AI Evaluation & Adversarial Red-Teaming Engineer
Accenture India
Enterprise GenAI Cloud & RAG Architect
Deloitte USI
GenAI Assurance, Tax & Audit Systems Lead
TCS AI.Cloud
Mission-Critical Banking LLM & COBOL Modernization Architect
Infosys Topaz
Principal Topaz Autonomous Workflow Architect
Wipro ai360
Lead AIOps & Log Observability Architect
Cognizant Neuro AI
Principal Healthcare HIPAA RAG Architect
Capgemini AI
Principal Multimodal Vision RAG & Edge AI Architect
EY India AI
Staff Responsible AI & Compliance Architect
JPMorgan Chase AI
VP Applied Quant RAG & Low-Latency Risk Systems
Morgan Stanley AI
VP Wealth Advisor Copilot & Hallucination Defense
120 Most-Asked AI, ML, System Design & Codebase Audit Questions (4 Pages)
Every company above tests non-obvious bugs, security flaws, Technical SEO/GEO failures, RAG failure modes, and FinOps guardrails. Once you pass 4 full company interviews, all 4 consolidated revision pages unlock permanently with staff-level answers, runnable snippets, and interviewer red flags. First 2 questions on each page (8 total) are open as free previews right now.
Complete & pass 4 company loops above to reveal 112 locked answers + code.
Core AI, LLMs, Prompt Engineering & Agentic Loops (30 Q&As + Code)
Prefix KV caching math, reasoning latency vs TTFT, LoRA/QLoRA, MCP stdio/HTTP tooling, indirect prompt injection, idempotency, state checkpoints, and context compaction.
Classic ML Debugging, Data Leakage, Metrics & Production Evals (30 Q&As + Code)
Target/temporal leakage, training-serving skew, NaN edge crashes, ROC-AUC vs PR-AUC under class imbalance, LLM-as-a-Judge bias calibration, Recall@k / MRR / nDCG, and trajectory CI gates.
AI System Design, Enterprise RAG & 5-Lever FinOps Scaling (30 Q&As + Code)
5-Lever LLM cost reduction, Hybrid Search (BM25 + HNSW + RRF), ColPali Vision RAG, GraphRAG, Contextual Retrieval, MRL/Binary quantization, vLLM PagedAttention & Disaggregated Prefill/Decode.
Production Codebase Audits: Full-Stack Errors, Security, SEO/GEO & Scaling (30 Q&As + Code)
Hardcoded secret leaks, SSRF cloud metadata defense, reflected XSS & CSP, concurrency quota locks, SQLi in MCP tools, Technical SEO/GEO crawlability (robots/noindex/SSR/JSON-LD/llms.txt), CLS, and OOM/N+1 scaling.
4 Downloadable Web+AI, Classic ML, RAG & Agentic Starter Codebases
Every codebase runs locally on Windows/Mac/Linux in 10 seconds with zero paid API keys. Download the ZIP, launch it in your browser, find the planted security/SEO/ML-leakage/RAG/concurrency defects, and verify inside any company page above.
Codebase 1: Full-Stack Web + AI SaaS Audit
Audit a live AI Storefront (HTML/CSS/JS frontend + Node HTTP backend). Catch hardcoded secrets & /api/debug-env leaks, reflected XSS, SSRF preview risk, robots.txt/noindex SEO blocks, CLS shifts, N+1 loops, and uncached AI endpoints.
unzip buggy-ai-storefront.zip cd buggy-ai-storefront node server.js # Then open http://localhost:3100 in Chrome/Edge and audit UI + server!
Codebase 2: Classic ML Pipeline & Train-Serving Skew Audit
Audit a real payment fraud ML training pipeline and live serving API. Offline metrics claim 0.99+ accuracy, yet live production fails silently because of target leakage, time-series shuffle leakage, preprocessing fit over train+test combined, stale serving constants, and unguarded NaN crashes.
unzip classic-ml-pipeline.zip cd classic-ml-pipeline python test_ml_pipeline.py python serving_api.py # Open http://localhost:8150 to compare offline training vs live checkout scoring!
Codebase 3: Enterprise Policy RAG & Salary-Leak Audit
Inspect a company HR & Policy RAG chatbot over Leave Policy Markdown and Payroll JSON. Trigger both real-world failures: (1) hallucinating intern leave carry-forward rules from cut tables, and (2) leaking Priya Sharma's confidential salary to interns due to missing RBAC pre-filtering + bloated FP64 linear scan.
unzip enterprise-policy-rag.zip cd enterprise-policy-rag python app.py # Open http://localhost:8100, keep Role = intern, and click Test 1 & Test 2!
Codebase 4: Agentic AI, MCP Safety, Concurrency & CI Evals
Inspect a multi-tenant AI Support Agent & MCP Tool Dispatcher. Reproduce real OpenAI/Anthropic interview failure patterns: (1) unbounded `while True` loops, (2) indirect prompt injection inside ticket notes triggering unauthorized SQL & refunds without Human-in-the-Loop, (3) non-atomic multi-tenant quota race conditions, and (4) skipped CI eval gates.
unzip agentic-mcp-ops.zip cd agentic-mcp-ops python quota_limiter.py python agent_loop.py # Open http://localhost:8200 and click Run Agent Trace & Quota Race Probe!
What Real Companies Test Today (In Simple Language)
Modern interviews at Google, Bloomberg, OpenAI, Anthropic, and enterprise GCCs go far beyond trick LeetCode puzzles. Here is the exact map of what happens in each interview format so you walk in prepared.
What is a “Codebase Interview”?
A codebase is simply a full multi-file project folder (like a GitHub repo containing frontend pages, backend APIs, configs, and scripts). Instead of staring at a blank editor, companies like Bloomberg, Google, and top startups give you an existing project and ask:
- Errors & Bugs: What breaks at runtime or leaks memory under traffic?
- Security Leaks: Are `.env` keys, SQL injections, XSS, SSRF, or unauthorized salary records exposed?
- SEO, GEO & UX: Can Google, Bing, and AI Search read the page cleanly, or did `robots.txt` / client-only JS / bad layout contrast ruin it?
- Scalability: How do caching, rate limits, HNSW indexes, and RBAC keep it fast at 100x load?
Using AI Tools in Interviews (With-AI vs No-AI)
Companies like Meta (AI-enabled multi-file CoderPad rounds), Canva, Stripe, Bloomberg, and Anthropic take-homes increasingly permit Claude, Gemini, or DeepSeek — making interviews HARDER, not easier. Evaluators grade Problem Scoping, catching LLM hallucinations/security flaws, Total Ownership (never say "the AI wrote it"), and Reproduce -> Isolate -> Minimal Fix verification.
Core infrastructure loops (Google DeepMind, OpenAI core coding, NVIDIA systems) still include No-AI coding & debugging rounds to verify raw mastery of concurrency locks, feature leakage, tokenizers, KV-cache math, and architecture trade-offs.
4 Different System Design Interviews (By Role POV)
1. Web & Full-Stack AI Product Systems
Fast user experience, multi-file debugging, security, crawlability (SEO/GEO), streaming UI, and backend reliability.
- Server-Rendered HTML (SSR/RSC) + Canonical SEO + JSON-LD + `llms.txt`
- Edge Rate Limiting + Auth (JWT/HttpOnly) + CSP / XSS / SSRF Defense
- SSE / WebSocket Token Streaming + Idempotency Keys + Redis Cache
- Core Web Vitals (LCP <= 2.5s, CLS <= 0.1, INP <= 200ms)
2. Classic ML & Data Systems
Zero data/time leakage, identical train-serving feature parity, NaN input validation, drift alerts, and sub-50ms scoring.
- Chronological `TimeSeriesSplit` + Pipeline-Scoped Scaling (zero fold leakage)
- Shared `FeatureTransformer` / Feature Store (zero training-serving skew)
- Offline PR-AUC / Calibration / Drop-Feature Ablations vs Online Shadow Tests
- Data Drift & Concept Drift Monitors triggering controlled retraining
3. GenAI & Enterprise RAG Systems
Zero hallucinations, strict salary/PII access control (RBAC), fast hybrid search, and compressed vector storage.
- Structure-Aware / Parent-Child Chunking (preserves Markdown tables & PDFs)
- Hybrid Retrieval (BM25 + Dense Vector + RRF) + Cross-Encoder Reranking
- Document-Level RBAC Pre-Filtering + PII Redaction + Strict NOT_FOUND Abstention
- Vector Compression (Matryoshka MRL + int8/Binary Quantization) + RAGAS Evals
4. Agentic AI & Distributed Inference
Safe MCP tool schemas, concurrency quota locks, bounded agent loops, GPU serving (vLLM/KV Cache), and CI eval gates.
- MCP Tool Registry + Least-Privilege Sandboxing + Human-in-the-Loop Gates
- Atomic Rate/Token Quota Locks + Hard `max_steps` / Cycle Stop Conditions
- vLLM Continuous Batching + PagedAttention + Prefix Caching + Tiered Routing
- OpenTelemetry Agent Traces + Golden Dataset CI Regression Gates
Real Enterprise RAG & AI Cost Failures (Exact Terms to Know)
Company RAG & AI Systems interviews test these exact 4 production disasters — including hallucinations, salary leaks, bloated vector indexes, and exploding LLM API bills.
Why Your Policy Bot Hallucinates ("Invents fake leave rules")
Root Cause: Fixed 500-character slicing cuts Markdown tables in half, weak dense-only search misses exact policy IDs, and permissive prompts tell the model "be helpful" instead of "refuse if missing".
- Structure-Aware / Parent-Child Chunking
- Hybrid Search (BM25 + Dense Vector + Reciprocal Rank Fusion)
- Cross-Encoder Reranking
- Grounded Citations + Strict NOT_FOUND Abstention
- RAGAS Faithfulness & Context Precision Evals
Why Your Bot Leaks Employee Salaries ("Confidential PII exposure")
Root Cause: HR payroll files were indexed into the same flat vector store as public handbooks, or permissions were checked AFTER retrieval (or only asked politely in the system prompt).
- Access Control in RAG (Document-Level RBAC)
- Metadata Pre-Filtering (`WHERE role IN allowed_roles` BEFORE Top-K)
- Separate Tenant / Classification Namespaces
- PII Redaction & Output Guardrails
Why Your Vector DB Is Huge, Expensive & Slow ("How to optimize")
Root Cause: Storing raw 1536–3072 dim FP32/FP64 vectors for millions of chunks without index compression, and re-running full LLM calls for identical repeated questions.
- Matryoshka Dimension Reduction (MRL: 1536 -> 256/512 dims)
- Scalar Quantization (int8 = 4x smaller) & Binary Quantization (32x smaller + oversample rescore)
- HNSW Index Tuning (`M`, `ef_construction`, `ef_search`)
- Semantic Caching (Redis vector hit for repeat FAQs) & Prefix Caching
Why Company AI / LLM API Bills Explode ("Cut Money Without Losing Accuracy")
Root Cause: Sending every simple chat/bot request to expensive frontier models with bloated uncached prompts, verbose outputs (3x–6x costlier), zero batching, and zero token monitoring.
- Prefix Caching + Tenant-Scoped Semantic Caching (50–90% savings)
- Cascade Model Routing (send easy queries to Mini/Flash, hard ones to Frontier)
- Prompt & Output Optimization (concise schemas + strict max_tokens)
- Batch Processing APIs (50% discount for async/offline jobs)
- Constant Monitoring (OTel / Langfuse Cost-per-Request) + Evals so Accuracy stays >= 95%!
2026–2027 AI Interview & Codebase FAQs
What is a "Codebase Interview" at companies like Bloomberg, Google, Meta, or OpenAI in 2026–2027?
Instead of only solving isolated whiteboard puzzles, interviewers give you a multi-file repository (frontend + backend + data/RAG/ML/agent scripts) with planted security leaks, blocked SEO/GEO rules, data leakage, or concurrency races. You reproduce the bug, isolate root cause, apply a minimal fix—sometimes with Claude/Gemini/DeepSeek allowed—and defend every line.
Are interviews different for Full-Stack Web+AI, Classic ML, GenAI/RAG, and Agentic AI?
Yes. DataArena gives you 4 separate runnable codebases—one for each track: Web+AI (XSS/SSRF, SEO/GEO, CLS, caching), Classic ML (target leakage, temporal split leakage, train-serving skew, NaN safety), GenAI/RAG (chunking, RBAC salary-leak prevention, vector quantization), and Agentic AI (MCP schemas, prompt injection, concurrency quota races, loop stop conditions, CI evals).
Why does an enterprise RAG chatbot hallucinate company policies or leak employee salaries?
Hallucinations happen when naive fixed-size chunking slices policy tables apart and weak prompts guess instead of returning NOT_FOUND. Salary leaks happen when confidential payroll docs are indexed without Document-Level RBAC Metadata Pre-Filtering (`WHERE role IN allowed_roles`) before Top-K vector search or PII output redaction.
How do companies shrink and speed up massive multi-million vector databases?
Teams combine Matryoshka (MRL) dimension truncation (e.g., 1536 down to 256 dims), Scalar (int8, 4x smaller) or Binary Quantization (32x smaller with float32 rescoring), tuned HNSW parameters (`M`, `ef_search`), plus Semantic Caching and Prefix Caching for repeat queries.
Why are "With-AI" coding interviews (Meta, Canva, Stripe, Anthropic) often harder than No-AI rounds?
Because writing syntax is cheap with Claude, Gemini, or DeepSeek—so interviewers raise the bar on problem scoping, catching subtle security/concurrency hallucinations before tests fail, and demanding total ownership of every line you ship.
How do AI teams cut huge LLM API bills without hurting answer accuracy?
Use the 5-lever FinOps stack: (1) Prefix + Tenant Semantic Caching, (2) Difficulty Model Routing to mini/Flash models, (3) Prompt & Output token trimming, (4) 50%-off Batch Processing for offline jobs, and (5) Constant Monitoring with Golden Dataset Evals so cost savings never sacrifice answer accuracy.