Specialized Topics: Bandits, Transformers, LLMs, Reward Modeling, RLHF Questions
Advanced topics within Machine Learning & AI covering bandit algorithms, transformer architectures, large language models (LLMs), reward modeling, and reinforcement learning from human feedback (RLHF). This topic explores both theoretical concepts and practical considerations for deploying and fine-tuning modern ML systems, including exploration-exploitation strategies, attention mechanisms, scalable training, and human-in-the-loop optimization.
EasyTechnical
60 practiced
What is chain-of-thought prompting? Explain how it encourages LLMs to produce intermediate reasoning steps and give examples of tasks where chain-of-thought improves performance. Also describe downsides (latency, exposing incorrect steps) in production systems.
MediumTechnical
44 practiced
Implement Thompson Sampling for Bernoulli rewards in Python. Function signature: def thompson_sampling(arms: int, trials: int, reward_fn) -> List[int]. Use Beta(1,1) priors and update per-arm alpha/beta counts after each observed 0/1 reward. Return the sequence of arm choices.
EasyTechnical
48 practiced
Provide an intuitive explanation of the Upper Confidence Bound (UCB) algorithm for stochastic bandits. Describe how adding an optimism-based confidence bonus to empirical means encourages exploration and how the bonus shrinks as arms are sampled.
EasyTechnical
81 practiced
Explain the exploration–exploitation trade-off in multi-armed bandits. Give concrete production examples where exploration should be prioritized (e.g., cold-start product recommendations) and where exploitation dominates (e.g., revenue-critical checkout). How would you quantify and instrument the cost of exploration in production (business metrics, user impact, and monitoring)?
EasyTechnical
54 practiced
Implement an epsilon-greedy multi-armed bandit policy in Python. Function signature: def epsilon_greedy(arms: int, trials: int, epsilon: float, reward_fn) -> List[int]. reward_fn(arm) returns a numeric reward. Maintain counts and estimated values; at each trial pick a random arm with probability epsilon otherwise pick argmax estimate. Return chosen-arm sequence.
Unlock Full Question Bank
Get access to hundreds of Specialized Topics: Bandits, Transformers, LLMs, Reward Modeling, RLHF interview questions and detailed answers.
Sign in to ContinueJoin thousands of developers preparing for their dream job.