Chapter 67
AI ইন্টারভিউ প্রস্তুতি
AI Interview Preparation
🎯 AI Interview-এর গঠন
সাধারণত ৫ stage: (1) Recruiter screen → (2) Technical coding → (3) ML breadth/depth → (4) ML system design → (5) Behavioral। প্রতি stage-এ আলাদা প্রস্তুতি দরকার।
Stage 1: Coding (DSA + ML)
- LeetCode Top 150 — easy/medium-এ fluent হন।
- NumPy/Pandas — vectorized solution।
- "Implement X from scratch" — k-means, logistic regression, attention।
- PyTorch live coding — DataLoader, training loop।
# Classic: scaled dot-product attention from scratch
import torch, math
def attention(Q, K, V, mask=None):
d_k = Q.size(-1)
scores = Q @ K.transpose(-2,-1) / math.sqrt(d_k)
if mask is not None: scores = scores.masked_fill(mask==0, -1e9)
return torch.softmax(scores, dim=-1) @ VStage 2: ML Breadth
Quick-fire concept question — ১-৩ মিনিটে clear উত্তর।
- Bias-variance tradeoff।
- Overfit vs underfit — symptom ও remedy।
- Regularization — L1/L2, dropout, early stop।
- Precision/Recall/F1, ROC-AUC, PR-AUC কখন কোনটা।
- Cross-validation strategy (stratified, group, time-series)।
- Gradient descent variants।
- Batch norm vs layer norm vs RMS norm।
- Encoder vs decoder vs encoder-decoder transformer।
- LoRA, QLoRA, PEFT।
- RAG vs fine-tuning কখন কী।
Stage 3: ML Depth
একটা topic-এ deep dive — paper details, math, trade-off।
- "Transformer-এ positional encoding কেন লাগে? RoPE vs ALiBi?"
- "BERT pretraining objective derive করুন।"
- "Diffusion forward/reverse process explain করুন।"
- "DPO vs PPO RLHF-এ?"
Stage 4: ML System Design (সবচেয়ে গুরুত্বপূর্ণ)
Senior role-এ এটাই deciding factor। Framework:
- Clarify — user, scale, latency, budget।
- Metric — online (CTR, retention) + offline (AUC, NDCG)।
- Data — source, labeling, leakage, freshness।
- Feature — feature store, online/offline parity।
- Model — baseline → complex, candidate gen + ranker।
- Training — schedule, retraining frequency।
- Serving — batch/online, cache, fallback।
- Monitor — drift, performance, A/B test।
💡 প্রচলিত ML System Design Q
- Design YouTube recommendation।
- Design Uber ETA prediction।
- Design ChatGPT (multi-turn LLM serving)।
- Design fraud detection।
- Design search ranking।
- Design ad CTR prediction।
Stage 5: Behavioral (STAR)
প্রতিটি story-তে: Situation → Task → Action → Result। নিজের ৬-৮টি story আগেই তৈরি রাখুন।
- "একটা challenging project বলুন।"
- "Conflict কীভাবে handle করেছেন?"
- "Failed project থেকে কী শিখেছেন?"
- "কেন এই company?"
Resource Stack
- Book: Designing ML Systems (Chip Huyen), ML Interviews (Khang Pham)।
- Course: Educative "Grokking the ML Interview", Stanford CS329S।
- Mock: interviewing.io, Pramp, friend pair।
- Blog: Eugene Yan, Chip Huyen, Vicki Boykis।
⚠️ Red Flag যা avoid করবেন
- "I don't know" বলে চুপ — instead বলুন কীভাবে approach নিতেন।
- Buzzword spam ("we used LangChain") — depth ছাড়া।
- Metric ছাড়া project বর্ণনা।
- Trade-off না বলা।
সারসংক্ষেপ
✨ এই অধ্যায়ে যা শিখলাম
- ৫-stage interview pipeline।
- Coding, breadth, depth, system design, behavioral।
- ML System Design 8-step framework।
- STAR + ৬-৮টি pre-baked story।