← Gemini Interview Insights

Gemini·Data Scientist·Onsite - Multi Round·Senior

SeniorPrefer not to say
Sep 2025Remote

Summary

Gemini DS interview that was basically a full fraud modeling case study compressed into one session. They handed you a real ACH dataset scenario and expected you to walk through everything from labeling to experiment design to slide deck structure. Pretty intense scope for a single round.

Questions Asked (8)

Q1

How would you define fraud labels using ACH return data, and how do you handle look-ahead bias, late returns, and partial reversals within a 5-business-day label window?

Data ModelingProduct Analytics & Metrics
Author's notes

This is where I spent too much time second-guessing myself.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by defining the fraud label as a binary outcome based on ACH return codes within a 5-business-day window, then address the temporal challenges by using only data available at prediction time and handling late returns and partial reversals through conservative labeling rules. Emphasize that the label must be constructed to avoid look-ahead bias by aligning the observation window with the prediction point and incorporating a buffer for settlement delays.

Pro tip: Use a 'label maturity' concept: only include transactions where the full 5-business-day window has elapsed, and treat any returns after that as censored or separate events. This prevents leakage and ensures your model reflects real-time decisioning.

1. Define the label window and return codes

Specify that the label is based on ACH return codes (e.g., R01, R02, R05, R07, R10, R29) that indicate fraud or unauthorized transactions, and set a 5-business-day window from the transaction date. Clarify that the window starts after the transaction settles, not at initiation, to account for processing time.

2. Handle look-ahead bias

Ensure that only information available at the time of prediction is used to construct features, and that the label is determined solely by events within the 5-day window. Avoid using future data by strictly separating feature engineering from label generation and using point-in-time snapshots.

3. Address late returns

Decide on a cutoff for late returns: either exclude transactions without a return by day 5 (censoring) or treat them as non-fraud, but acknowledge that some may return later. Consider using a grace period or survival analysis to model the probability of late returns.

4. Handle partial reversals

Define whether partial reversals (e.g., partial amount returned) count as fraud. Typically, any return indicating unauthorized activity should be labeled as fraud, but if the reversal is partial and due to non-fraud reasons (e.g., insufficient funds), it may not be fraud. Establish clear rules based on return codes and amounts.

5. Validate and monitor label quality

Backtest the labeling logic on historical data to ensure it captures known fraud cases and doesn't introduce bias. Monitor label distribution over time and adjust for seasonality or changes in return code usage.

Key Points to Mention

  • ACH return codes relevant to fraud (e.g., R01, R02, R05, R07, R10, R29) and their meanings.
  • The importance of aligning the label window with the prediction point to avoid look-ahead bias.
  • Strategies for handling late returns: censoring, grace periods, or survival analysis.
  • Treatment of partial reversals: whether to label as fraud based on return code and amount.
  • The need for point-in-time data and avoiding leakage from future information.
  • Validation of label quality through backtesting and monitoring.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q2

Propose 3 to 5 interpretable fraud detection rules for ACH transactions, including exact definitions and thresholds.

Product Analytics & MetricsTechnical Trade-offs
Author's notes

I went with 24-hour velocity on credit count per user, shared device fingerprint across more than two distinct user accounts within 7 days, and a first-transaction amount above some threshold like $2,000.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by framing the goal: interpretable rules that balance fraud detection with false positives. Then propose 3-5 rules with clear thresholds derived from data distributions or domain knowledge, and explain how each rule maps to known fraud patterns. Finally, discuss how to validate and monitor these rules in production.

Pro tip: Anchor thresholds in percentiles of historical data (e.g., 99th percentile) rather than arbitrary numbers, and always mention the trade-off between false positives and false negatives—this shows you understand business impact.

1. Understand ACH fraud patterns

Briefly outline common ACH fraud types (e.g., account takeover, unauthorized debits, velocity attacks) to ground your rules in real-world risks.

2. Define rules with precise thresholds

Propose 3-5 rules, each with a clear condition and threshold (e.g., 'more than 5 transactions in 24 hours'). Ensure thresholds are data-driven or industry-standard.

3. Explain interpretability and rationale

For each rule, explain why it's interpretable (simple, human-readable) and how it relates to fraud patterns, making it easy for stakeholders to understand.

4. Discuss validation and trade-offs

Mention how you would validate rules (e.g., backtesting on historical data) and the trade-off between catching fraud and minimizing false positives.

5. Suggest monitoring and iteration

Propose a plan to monitor rule performance and adjust thresholds over time as fraud patterns evolve.

Key Points to Mention

  • Use of percentiles (e.g., 99th) or domain knowledge to set thresholds
  • Rules should be simple and human-readable (e.g., if-then statements)
  • Consider both transaction-level and account-level aggregations
  • Address false positive rate and its impact on customer experience
  • Mention how rules can be combined or prioritized
  • Highlight the need for regular review and adaptation to new fraud tactics

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q3

How would you design an offline backtest for this fraud policy, including sampling strategy, time-split validation, leakage checks, and counterfactual estimation?

A/B Testing & ExperimentationData Modeling
Author's notes

Time-split was obvious, I said use June-July for training and August for eval.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by framing the backtest as a simulation of the policy's real-world impact, emphasizing the need to avoid common pitfalls like temporal leakage and selection bias. Then walk through a structured design covering sampling, time-split validation, leakage checks, and counterfactual estimation, highlighting trade-offs and validation metrics.

Pro tip: Always simulate the policy's decision-making process as it would occur in production, including any delays or data availability constraints, to avoid over-optimistic estimates. Use a holdout set that mimics the future deployment period to validate the counterfactual model's stability.

1. Define the Backtest Objective and Metrics

Clarify the policy's goal (e.g., reduce fraud loss while minimizing false positives) and select evaluation metrics such as precision, recall, F1, or expected cost. Ensure metrics align with business impact.

2. Design Sampling Strategy

Choose a sampling method that reflects the production distribution, such as stratified sampling by time, user segment, or fraud type. Consider oversampling rare fraud cases to ensure robust evaluation, but reweight to maintain representativeness.

3. Implement Time-Split Validation

Split data chronologically into training, validation, and test periods to mimic real deployment. Use expanding or rolling windows to account for temporal drift and avoid look-ahead bias.

4. Perform Leakage Checks

Identify and eliminate features that leak future information (e.g., post-outcome data) or are influenced by the policy itself. Use techniques like time-based feature availability checks and correlation analysis with future outcomes.

5. Estimate Counterfactuals

Apply methods like inverse propensity weighting, doubly robust estimation, or causal forests to estimate what would have happened under the new policy. Validate using synthetic data or A/B test results if available.

Key Points to Mention

  • Temporal validation to prevent look-ahead bias and account for concept drift
  • Stratified sampling to handle class imbalance and ensure representative evaluation
  • Leakage detection techniques such as feature availability timelines and target leakage checks
  • Counterfactual estimation methods (e.g., IPW, doubly robust) and their assumptions
  • Evaluation metrics that align with business costs (e.g., expected fraud loss vs. customer friction)
  • Sensitivity analysis to test robustness of results under different assumptions

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q4

What primary and secondary metrics would you use to evaluate the fraud control policy, and what guardrail metrics would you track to avoid unintended harm?

Product Analytics & MetricsA/B Testing & Experimentation
Author's notes

Loss per 1,000 credits as primary was given in the prompt essentially, so I restated it and explained why it captures both fraud rate and dollar severity better than raw counts.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the fraud control policy's objective and the business context (e.g., reducing fraud losses while maintaining user experience). Then, define primary metrics tied to the policy's direct goal, secondary metrics that provide additional insight, and guardrail metrics to monitor unintended consequences. Structure your answer around a balanced scorecard that considers both fraud prevention and customer impact.

Pro tip: Emphasize the importance of aligning metrics with business KPIs and using a combination of leading and lagging indicators. Also, mention that guardrail metrics should be monitored continuously during A/B tests to catch negative effects early.

1. Clarify the policy objective and scope

Ask clarifying questions to understand the specific fraud control policy, its goals (e.g., reduce fraudulent transactions), and the business context (e.g., Gemini's risk appetite).

2. Define primary metrics

Identify the main metric(s) that directly measure the policy's success, such as fraud rate reduction or fraud loss amount prevented.

3. Define secondary metrics

Select additional metrics that provide deeper insight into the policy's performance, such as precision/recall of fraud detection, false positive rate, or customer friction metrics.

4. Define guardrail metrics

Choose metrics to monitor unintended harm, such as customer satisfaction, legitimate transaction approval rate, or support ticket volume related to fraud controls.

5. Explain measurement and experimentation

Describe how you would track these metrics (e.g., via A/B testing) and ensure statistical validity, including sample size and duration considerations.

Key Points to Mention

  • Primary metric: fraud rate or fraud loss reduction (e.g., percentage of fraudulent transactions blocked).
  • Secondary metrics: false positive rate, precision/recall, customer friction (e.g., time to complete transaction), and operational efficiency (e.g., manual review rate).
  • Guardrail metrics: customer satisfaction (CSAT/NPS), legitimate transaction approval rate, customer support contacts, and revenue impact.
  • Trade-off between fraud prevention and customer experience: minimizing false positives while catching fraud.
  • Use of A/B testing to measure incremental impact and ensure guardrails are not violated.
  • Alignment with business goals: metrics should reflect Gemini's risk tolerance and growth objectives.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q5

How would you analyze heterogeneous treatment effects across subgroups like user tenure, country, and device cluster, and how would you control for false discovery?

A/B Testing & ExperimentationProduct Analytics & Metrics
Author's notes

Talked through pre-specifying the three cuts before looking at data, then using something like Benjamini-Hochberg correction across the subgroup tests.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by framing the analysis as a pre-specified subgroup analysis to avoid data dredging, then describe a hierarchical approach: first test for overall treatment effect, then use interaction terms or a causal forest to estimate heterogeneous effects. Finally, apply multiple testing corrections like Benjamini-Hochberg to control false discovery rate, and validate findings with sensitivity analyses.

Pro tip: Emphasize that you would pre-register subgroups and use a holdout set to confirm discoveries, because post-hoc subgroup hunting is a common pitfall that leads to false positives. Also, mention that you'd prioritize practical significance over statistical significance when interpreting subgroup effects.

1. Pre-specify subgroups and hypotheses

Define subgroups (e.g., user tenure buckets, countries, device clusters) and the expected direction of effects before analysis to avoid p-hacking. Document these in the experiment plan.

2. Estimate heterogeneous treatment effects

Use methods like interaction terms in regression, causal forests, or meta-learners to model treatment effect variation across subgroups. Check for sufficient sample size and overlap in each subgroup.

3. Control for multiple comparisons

Apply false discovery rate (FDR) control (e.g., Benjamini-Hochberg) or family-wise error rate (e.g., Bonferroni) across all subgroup tests. Consider hierarchical testing if subgroups are nested.

4. Validate and interpret findings

Use a holdout set or cross-validation to confirm discovered effects. Assess practical significance and business impact, and check for confounding or Simpson's paradox.

5. Communicate results with caveats

Present effect sizes with confidence intervals, clearly state limitations, and recommend follow-up experiments for promising subgroups rather than immediate rollout.

Key Points to Mention

  • Pre-registration of subgroups to avoid false discoveries
  • Use of interaction terms or causal forests for heterogeneous treatment effects
  • Multiple testing correction methods: Benjamini-Hochberg (FDR) vs. Bonferroni (FWER)
  • Power analysis for subgroup detection and minimum detectable effect
  • Validation with holdout data or cross-validation
  • Practical significance and business impact over mere statistical significance

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q6

Walk through your online experiment design for launching this fraud policy, covering randomization unit, power analysis, ramp schedule, spillover handling, and rollback criteria.

A/B Testing & ExperimentationSystem Design
Author's notes

User-level sticky randomization was my answer for the unit, mostly because ACH fraud is user-level behavior and session-level would create weird inconsistencies.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Structure your answer as a coherent experimental plan, starting with the randomization unit and power analysis, then detailing the ramp schedule, spillover handling, and rollback criteria. Emphasize how each choice mitigates risks specific to fraud policy, such as interference and false positives. Conclude by tying the design to business metrics and safety.

Pro tip: For fraud policies, consider using a cluster-randomized design to account for spillover and include guardrail metrics to quickly detect harmful effects. Also, pre-register your analysis plan to avoid p-hacking and ensure stakeholder alignment.

1. Define Randomization Unit and Metrics

Choose the unit of randomization (e.g., user, session, or cluster) based on the fraud policy's scope and potential interference. Define primary success metrics (e.g., fraud reduction) and guardrail metrics (e.g., false positive rate, user experience).

2. Conduct Power Analysis and Determine Sample Size

Estimate the minimum detectable effect (MDE) for key metrics, considering baseline rates and variance. Calculate required sample size and experiment duration, accounting for any clustering or stratification.

3. Design Ramp Schedule and Spillover Handling

Plan a phased rollout (e.g., 1%, 5%, 20%, 50%, 100%) to monitor early signals and limit blast radius. Address spillover by using cluster randomization, geo-based splits, or washout periods if interference is likely.

4. Establish Rollback Criteria and Monitoring

Define clear thresholds for rollback (e.g., significant increase in false positives or drop in key business metrics) and set up real-time monitoring with alerts. Include a pre-specified analysis plan for interim looks.

Key Points to Mention

  • Randomization unit: user-level vs. cluster-level to handle spillover
  • Power analysis: MDE, alpha, beta, and sample size calculation
  • Ramp schedule: phased rollout with holdback groups
  • Spillover handling: cluster randomization, geo experiments, or switchback tests
  • Rollback criteria: guardrail metrics, statistical significance, and business impact
  • Monitoring: real-time dashboards, sequential testing, and pre-registration

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q7

How would you build monitoring for this fraud policy and separate seasonal effects like end-of-month payroll cycles from actual treatment effects?

Product Analytics & MetricsRoot Cause Analysis
Author's notes

Honestly the seasonal piece is the part I found most interesting.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by framing monitoring as a continuous evaluation system that tracks both policy outcomes and potential confounders. Then, propose a decomposition approach that isolates seasonal patterns (e.g., end-of-month payroll cycles) from treatment effects using time-series methods or control groups. Emphasize the importance of aligning metrics with business objectives and iterating on the monitoring design.

Pro tip: Use a difference-in-differences or synthetic control design to create a counterfactual, and always validate your seasonal adjustment with historical data to avoid overfitting. This shows you understand both causal inference and practical implementation.

1. Define success metrics and guardrails

Identify key performance indicators (e.g., fraud detection rate, false positive rate) and guardrail metrics (e.g., customer friction) that the policy aims to improve. Ensure they are measurable and aligned with business goals.

2. Establish a baseline and control group

Select a pre-policy period and a comparable control group (e.g., similar regions or customers not exposed to the policy) to serve as a counterfactual for measuring treatment effects.

3. Model and remove seasonal effects

Use time-series decomposition (e.g., STL), regression with seasonal dummies, or Fourier terms to capture recurring patterns like end-of-month payroll cycles. Validate the model on historical data to ensure it generalizes.

4. Estimate treatment effect and monitor continuously

Apply causal inference methods (e.g., difference-in-differences, synthetic control) to isolate the policy's impact. Set up automated dashboards and alerts to track metrics over time and detect anomalies.

5. Iterate and validate

Regularly review the monitoring system, conduct sensitivity analyses, and adjust for new confounders. Use A/B tests or holdout groups to validate findings and refine the policy.

Key Points to Mention

  • Causal inference techniques (difference-in-differences, synthetic control) to separate treatment effects from confounders.
  • Time-series decomposition methods (STL, Fourier terms, seasonal dummies) to model and remove seasonal patterns.
  • Importance of control groups and pre/post analysis to establish counterfactuals.
  • Automated monitoring with dashboards and alerts for real-time detection of anomalies.
  • Validation of seasonal adjustments using historical data to prevent overfitting.
  • Alignment of metrics with business objectives and consideration of guardrail metrics.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.

Q8

Outline the three slides you would present to stakeholders covering problem and baseline, proposed controls and risks, and expected value and ramp plan.

Stakeholder ManagementProduct Strategy
Author's notes

Slide structure questions always feel a little soft but this one had real teeth because they wanted exact readouts.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Structure your answer around the three slides as a narrative arc: establish the problem and baseline with data, propose controls with risk mitigation, and quantify expected value with a phased ramp plan. Emphasize how each slide answers a key stakeholder question and ties to business impact. Keep the focus on decision-making, not technical details.

Pro tip: Anchor every slide to a single decision the stakeholders need to make, and pre-empt the toughest objection on each slide to show you understand their priorities. Use a consistent metric (e.g., revenue lift, cost savings) across all three slides to make the value story coherent.

1. Slide 1: Problem & Baseline

Define the problem in business terms, quantify the current baseline with data, and show the cost of inaction. Use a clear metric that will be tracked throughout.

2. Slide 2: Proposed Controls & Risks

Outline the proposed solution (e.g., model, process change) and the controls to mitigate key risks. Address trade-offs and how you'll monitor for unintended consequences.

3. Slide 3: Expected Value & Ramp Plan

Quantify the expected value (e.g., ROI, lift) with assumptions and confidence intervals. Present a phased ramp plan with milestones, success criteria, and go/no-go decision points.

4. Tie It Together

Summarize how the three slides form a cohesive story: from problem to solution to value, with clear asks and next steps for stakeholders.

Key Points to Mention

  • Quantify the baseline with a clear metric (e.g., conversion rate, cost per acquisition) and show the gap to target.
  • Include a risk register with likelihood/impact and mitigation strategies for each proposed control.
  • Use a phased ramp plan (e.g., pilot, A/B test, full rollout) with explicit success criteria and rollback triggers.
  • Estimate expected value with sensitivity analysis or confidence intervals to show rigor.
  • Align the value story with company OKRs or strategic priorities (e.g., Gemini's focus on user growth or efficiency).
  • End with a clear ask: what decision or resource you need from stakeholders.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.