> ## Documentation Index
> Fetch the complete documentation index at: https://offthepace.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# fct_driver_skill_features

> Race-grain driver skill feature table for the driver skill extraction model.

<Note>Part of the [Marts](/transform/families/marts) family.</Note>

Race-grain driver skill feature table for the driver skill extraction model. One row per (race\_year, race\_id, driver\_id). Aggregates clean-lap residuals, synthetic-teammate deltas, constructor pace indices, and circuit context. Clean-lap filter: correction\_weight = 1.0 AND anomaly\_class NOT IN ('mistake','conditions') AND is\_rain\_lap = FALSE.

<Warning>Breaking a column type on this model fails the dbt build  -  this is the enforced handoff contract with `ml/`.</Warning>

## Lineage

```mermaid theme={null}
flowchart LR
  dim_circuits --> fct_driver_skill_features
  dim_constructors --> fct_driver_skill_features
  dim_drivers --> fct_driver_skill_features
  int_constructor_structural_pace --> fct_driver_skill_features
  int_lap_anomaly_flags --> fct_driver_skill_features
  int_lap_residual_decomposed --> fct_driver_skill_features
  int_synthetic_teammate --> fct_driver_skill_features
  style fct_driver_skill_features fill:#e40404,stroke:#e40404,color:#fff
```

## Overview

| Property          | Value                                                                                                                                                                                                                                                                                                                                                                                           |
| ----------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Layer             | `marts`                                                                                                                                                                                                                                                                                                                                                                                         |
| Family            | [Marts](/transform/families/marts)                                                                                                                                                                                                                                                                                                                                                              |
| Contract enforced | ✅ Yes                                                                                                                                                                                                                                                                                                                                                                                           |
| Upstream          | [`int_lap_residual_decomposed`](../int/int_lap_residual_decomposed), [`int_lap_anomaly_flags`](../int/int_lap_anomaly_flags), [`int_synthetic_teammate`](../int/int_synthetic_teammate), [`int_constructor_structural_pace`](../int/int_constructor_structural_pace), [`dim_circuits`](../dim/dim_circuits), [`dim_drivers`](../dim/dim_drivers), [`dim_constructors`](../dim/dim_constructors) |
| Model-level tests | `expect_column_values_to_be_between`                                                                                                                                                                                                                                                                                                                                                            |

**1 tests** [guard](/transform/ci/overview) this model  -  1 generic, 0 singular.

## Columns

| Column                               | Type      | Nullable | Tests | Description                                                                                                      |
| ------------------------------------ | --------- | -------- | ----- | ---------------------------------------------------------------------------------------------------------------- |
| `driver_race_id`                     | `varchar` | No       |       | Surrogate PK   hash of (race\_year, race\_id, driver\_id)                                                        |
| `driver_id`                          | `varchar` | No       |       | FastF1 three-letter driver code (e.g. VER, HAM)                                                                  |
| `race_year`                          | `integer` | No       |       | Season year                                                                                                      |
| `race_id`                            | `varchar` | No       |       | Race identifier (e.g. 2021\_19)                                                                                  |
| `constructor_id`                     | `varchar` | Yes      |       | Team name as used in FastF1                                                                                      |
| `circuit_key`                        | `varchar` | Yes      |       | Stable circuit identifier matching dim\_circuits                                                                 |
| `pu_family`                          | `varchar` | Yes      |       | Power unit family (e.g. mercedes\_pu, honda\_pu)                                                                 |
| `driver_debut_year`                  | `integer` | Yes      |       | First season in the dataset                                                                                      |
| `driver_residual_mean_s`             | `double`  | Yes      |       | Mean driver skill residual over clean laps. Negative = faster than field.                                        |
| `driver_residual_stddev_s`           | `double`  | Yes      |       | Stddev of driver skill residual over clean laps                                                                  |
| `driver_residual_median_s`           | `double`  | Yes      |       | Median driver skill residual over clean laps                                                                     |
| `clean_lap_count`                    | `bigint`  | No       |       | Number of laps passing the clean-lap filter                                                                      |
| `driver_skill_proxy_mean_s`          | `double`  | Yes      |       | Weighted mean of synthetic-teammate delta over clean laps. Positive = ego driver faster than synthetic teammate. |
| `pair_quality_weight_mean`           | `double`  | Yes      |       | Mean pair quality weight (higher = more consistent comparison)                                                   |
| `teammate_available_flag`            | `boolean` | No       |       | TRUE if a teammate comparison was available for at least one lap                                                 |
| `strategic_divergence_share`         | `double`  | No       |       | Fraction of clean laps where strategic\_divergence\_flag = TRUE                                                  |
| `constructor_power_pace_index_final` | `double`  | Yes      |       | EW-smoothed constructor power-sector pace index at race end                                                      |
| `constructor_aero_pace_index_final`  | `double`  | Yes      |       | EW-smoothed constructor aero-sector pace index at race end                                                       |
| `constructor_index_confidence_final` | `double`  | Yes      |       | Confidence score (0–1) for constructor pace index at race end                                                    |
| `race_wet_flag`                      | `boolean` | No       |       | TRUE if any rainfall was detected during the race                                                                |
| `circuit_energy_index`               | `double`  | Yes      |       | Track energy index from dim\_circuits (proxy for power sensitivity)                                              |
| `circuit_abrasiveness_index`         | `integer` | Yes      |       | Track abrasiveness index from dim\_circuits (proxy for tyre wear)                                                |
| `total_race_laps`                    | `bigint`  | No       |       | Total laps recorded for this driver in this race                                                                 |
| `ml_eligible_lap_share`              | `double`  | No       |       | Fraction of driver's laps with usable\_for\_modelling = TRUE                                                     |
