← Capital One Interview Insights

Capital One·Data Scientist·Technical Phone Screen·Senior

Senior
May 2026

Summary

Capital One data scientist interview with a deep-dive case question on airline on-time data. The whole thing was basically one long problem about auditing a messy dataset before modeling, which sounds manageable until you realize how many edge cases they actually want you to enumerate.

Questions Asked (3)

Q1

You're given an airline on-time dataset with a metadata spec. Before building any model, what are at least 8 concrete data quality issues you'd proactively test for, and what exact checks would you run to detect each one?

Data ModelingRoot Cause AnalysisTechnical Trade-offs
Author's notes

This is where I started rambling a bit.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by acknowledging the importance of data quality before modeling, then systematically list at least 8 concrete issues, pairing each with a specific check. Organize your answer by data quality dimensions (completeness, consistency, validity, etc.) to ensure coverage and demonstrate structured thinking.

Pro tip: Tie each data quality issue to its potential impact on model performance or business decisions—this shows you understand the 'why' behind the checks and aligns with Capital One's focus on actionable insights.

1. Understand the dataset and metadata

Review the metadata spec to identify expected fields, types, ranges, and relationships. This baseline helps you spot deviations and prioritize checks.

2. Categorize data quality dimensions

Group potential issues into dimensions like completeness, consistency, validity, accuracy, timeliness, and uniqueness. This ensures comprehensive coverage.

3. List concrete issues and checks

For each dimension, enumerate specific issues (e.g., missing values, duplicates) and define exact checks (e.g., count nulls, check uniqueness). Aim for at least 8 issues.

4. Prioritize by impact

Rank issues based on their potential to affect model outcomes or business metrics, and mention which checks you'd run first.

5. Summarize and link to modeling

Conclude by explaining how addressing these issues prevents downstream problems and improves model reliability.

Key Points to Mention

  • Missing values: check null counts and patterns (e.g., missing arrival delays for cancelled flights).
  • Duplicates: check for duplicate flight records using composite keys (e.g., date, flight number, origin, destination).
  • Outliers: detect unrealistic values (e.g., negative delays, extreme speeds) using statistical methods or domain rules.
  • Inconsistencies: verify that categorical fields (e.g., airline codes) match metadata and are consistently formatted.
  • Validity: ensure values fall within expected ranges (e.g., departure delay between -60 and 1440 minutes) and types match spec.
  • Timeliness: check if data is up-to-date and covers the required time period without gaps.
  • Referential integrity: validate that airport codes exist in a reference table and that flight dates align with schedules.
  • Business rule violations: e.g., arrival time before departure time, or flight duration inconsistent with route.

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

Q2

For each data quality issue you identify, how would you quantify its impact on the dataset, and what mitigation would you apply without introducing target leakage?

Data ModelingTechnical Trade-offsA/B Testing & Experimentation
Author's notes

The leakage angle is the actual trap here.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by categorizing data quality issues (e.g., missing values, outliers, duplicates) and for each, define a metric to quantify its prevalence and impact on model performance or business outcomes. Then, propose mitigation strategies that are applied only to training data or via cross-validation to avoid target leakage, ensuring any transformation is fit without using target information.

Pro tip: Emphasize that mitigation should be part of a pipeline that is fit on training folds only, and use techniques like target encoding with smoothing and cross-validation to prevent leakage. Also, quantify impact using business metrics (e.g., expected loss) to show you understand the broader context.

1. Identify and categorize data quality issues

List common issues such as missing values, outliers, duplicates, inconsistent formats, and label noise. For each, note how they might affect model training and predictions.

2. Quantify impact on dataset and model

For each issue, compute metrics like percentage of affected records, distribution shifts, or correlation with target. Assess impact via model performance (e.g., cross-validated AUC drop) or business cost (e.g., expected loss from errors).

3. Design leakage-safe mitigation strategies

Propose mitigations like imputation, winsorizing, or deduplication, ensuring they are fit only on training data. Use cross-validation or holdout sets to simulate real-world application and avoid target leakage.

4. Validate mitigation effectiveness

Evaluate the mitigated pipeline using cross-validation, comparing performance to baseline. Check for leakage by ensuring no target information is used in transformations.

5. Monitor and iterate

Implement monitoring for data quality issues in production and set up alerts. Continuously refine mitigations as data drifts.

Key Points to Mention

  • Target leakage: avoid using target statistics in imputation or encoding; use cross-validation or smoothing.
  • Quantification metrics: missing rate, outlier proportion, duplicate count, and their correlation with target.
  • Impact assessment: model performance metrics (AUC, RMSE) and business metrics (expected loss, revenue impact).
  • Mitigation techniques: imputation (mean, median, model-based), winsorizing, deduplication, and target encoding with smoothing.
  • Pipeline design: use scikit-learn pipelines or similar to ensure transformations are fit only on training data.
  • Validation: use cross-validation and holdout sets to estimate real-world performance and detect leakage.

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

Q3

How would you define a data contract for the upstream producers of this dataset, and how would you enforce it automatically in a CI pipeline?

System DesignData Modeling
Author's notes

Honestly the part I felt best about.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by defining a data contract as a formal agreement between upstream producers and consumers, specifying schema, semantics, quality, and SLAs. Then describe how to enforce it automatically in CI by integrating schema validation, data quality checks, and contract tests into the pipeline, with clear failure and alerting mechanisms.

Pro tip: Emphasize that data contracts should be versioned and backward-compatible, and that enforcement should shift left by validating producer changes in their CI before deployment. Also mention the importance of monitoring and alerting for contract violations in production.

1. Define the Data Contract

Specify the schema (field names, types, nullability), data quality rules (e.g., range checks, uniqueness), semantics (business meaning), and SLAs (freshness, latency). Include versioning and ownership.

2. Codify the Contract

Represent the contract in a machine-readable format such as JSON Schema, Avro, Protobuf, or a YAML specification. Store it in a central repository for version control and easy access.

3. Integrate Validation into CI

Add steps in the CI pipeline to validate that the producer's output conforms to the contract. Use tools like Great Expectations, dbt tests, or custom scripts to run schema and quality checks on sample data or generated artifacts.

4. Enforce and Fail Fast

Configure the CI pipeline to fail if contract violations are detected, preventing incompatible changes from being deployed. Provide clear error messages to help producers fix issues quickly.

5. Monitor and Evolve

Continuously monitor data in production for contract adherence, alert on violations, and establish a process for updating contracts with versioning and backward compatibility.

Key Points to Mention

  • Schema definition and versioning (e.g., Avro, Protobuf, JSON Schema)
  • Data quality dimensions: completeness, accuracy, consistency, timeliness
  • CI integration: automated tests, contract testing, shift-left approach
  • Tools: Great Expectations, dbt tests, Apache Griffin, custom validators
  • Failure handling: pipeline failure, notifications, rollback strategies
  • Governance: ownership, SLAs, change management, backward compatibility

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