# ezztheanalyst/f1_2026_predictions architecture

> Architecture diagram of the GitHub repository ezztheanalyst/f1_2026_predictions, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ezztheanalyst/f1_2026_predictions
- Repository: https://github.com/ezztheanalyst/f1_2026_predictions

## Overview

This repository is a collection of standalone, race-specific F1 2026 prediction scripts, not a shared application or reusable package. The documented workflow collects FastF1 session data, combines it with qualifying and weather inputs, engineers features, trains an XGBoost regressor, ranks predicted race times, and evaluates error. The sampled excerpts support the session-processing and weather-request stages; later model and output details come from the README. The scripts appear largely duplicated, so the graph shows the documented Melbourne run and the distinct race-specific variants without assuming they call one another.

Main entry points: [`1_melbourne_prediction.py`](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py) (Melbourne predictor)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workflow["Prediction workflow"]
  node_melbourne["Melbourne predictor"]
  node_fastf1["FastF1 sessions"]
  node_qualifying["Qualifying inputs"]
  node_weather["Weather forecast"]
  node_features["Feature engineering"]
  node_model["XGBoost model"]
  node_ranking["Race ranking"]
  node_evaluation["MAE evaluation"]
end

subgraph group_races["Race scripts"]
  node_shanghai["Shanghai predictor"]
  node_suzuka["Suzuka predictor"]
  node_miami["Miami predictor"]
  node_montreal["Montreal predictor"]
  node_monaco["Monaco predictor"]
  node_barcelona["Barcelona predictor"]
  node_austria["Austria predictor"]
  node_britain["Britain predictor"]
  node_spa["Spa predictor"]
  node_hungary["Hungary predictor"]
  node_netherlands["Netherlands predictor"]
  node_italy["Italy predictor"]
  node_madring["Madrid predictor"]
  node_baku["Baku predictor"]
  node_malaysia["Malaysia predictor"]
  node_singapore["Singapore predictor"]
  node_mexico["Mexico predictor"]
  node_brazil["Brazil predictor"]
end

node_user(("Runner"))
node_weatherapi["WeatherAPI"]

node_user -->|"runs"| node_melbourne
node_melbourne -->|"loads sessions"| node_fastf1
node_melbourne -->|"uses times"| node_qualifying
node_melbourne -->|"requests forecast"| node_weather
node_weather -->|"fetches data"| node_weatherapi
node_melbourne -->|"engineers features"| node_features
node_melbourne -->|"trains"| node_model
node_melbourne -->|"ranks times"| node_ranking
node_melbourne -->|"measures error"| node_evaluation

click node_melbourne "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_fastf1 "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_qualifying "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_weather "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_features "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_model "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_ranking "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_evaluation "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py"
click node_shanghai "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/2_shanghai_prediction.py"
click node_suzuka "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/3_suzuka_prediction.py"
click node_miami "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/4_miami_prediction.py"
click node_montreal "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/5_montreal_prediction.py"
click node_monaco "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/6_monaco_prediction.py"
click node_barcelona "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/7_barcelona_prediction.py"
click node_austria "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/8_austria_prediction.py"
click node_britain "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/9_britain_prediction.py"
click node_spa "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/10_spa_prediction.py"
click node_hungary "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/11_hungary_prediction.py"
click node_netherlands "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/12_netherlands_prediction.py"
click node_italy "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/13_italy_prediction.py"
click node_madring "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/14_madring_prediction.py"
click node_baku "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/15_baku_prediction.py"
click node_malaysia "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/16_malasyia_prediction.py"
click node_singapore "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/17_singapore_prediction.py"
click node_mexico "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/19_mexico_prediction.py"
click node_brazil "https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/20_brazil_prediction.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_melbourne,node_fastf1,node_qualifying,node_weather,node_features,node_model,node_ranking,node_evaluation toneBlue
class node_shanghai,node_suzuka,node_miami,node_montreal,node_monaco,node_barcelona,node_austria,node_britain,node_spa,node_hungary,node_netherlands,node_italy,node_madring,node_baku,node_malaysia,node_singapore,node_mexico,node_brazil toneAmber
class node_user toneIndigo
class node_weatherapi toneMint
```

## Components

### Prediction workflow

- [Melbourne predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [FastF1 sessions](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [Qualifying inputs](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [Weather forecast](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [Feature engineering](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [XGBoost model](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [Race ranking](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`
- [MAE evaluation](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/1_melbourne_prediction.py): `1_melbourne_prediction.py`

### Race scripts

- [Shanghai predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/2_shanghai_prediction.py): `2_shanghai_prediction.py`
- [Suzuka predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/3_suzuka_prediction.py): `3_suzuka_prediction.py`
- [Miami predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/4_miami_prediction.py): `4_miami_prediction.py`
- [Montreal predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/5_montreal_prediction.py): `5_montreal_prediction.py`
- [Monaco predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/6_monaco_prediction.py): `6_monaco_prediction.py`
- [Barcelona predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/7_barcelona_prediction.py): `7_barcelona_prediction.py`
- [Austria predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/8_austria_prediction.py): `8_austria_prediction.py`
- [Britain predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/9_britain_prediction.py): `9_britain_prediction.py`
- [Spa predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/10_spa_prediction.py): `10_spa_prediction.py`
- [Hungary predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/11_hungary_prediction.py): `11_hungary_prediction.py`
- [Netherlands predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/12_netherlands_prediction.py): `12_netherlands_prediction.py`
- [Italy predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/13_italy_prediction.py): `13_italy_prediction.py`
- [Madrid predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/14_madring_prediction.py): `14_madring_prediction.py`
- [Baku predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/15_baku_prediction.py): `15_baku_prediction.py`
- [Malaysia predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/16_malasyia_prediction.py): `16_malasyia_prediction.py`
- [Singapore predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/17_singapore_prediction.py): `17_singapore_prediction.py`
- [Mexico predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/19_mexico_prediction.py): `19_mexico_prediction.py`
- [Brazil predictor](https://github.com/ezztheanalyst/f1_2026_predictions/blob/main/20_brazil_prediction.py): `20_brazil_prediction.py`

### Other components

- **Runner**
- **WeatherAPI**

## Connections

- Runner → Melbourne predictor: runs (evidence: `README.md`)
- Melbourne predictor → FastF1 sessions: loads sessions (evidence: `README.md`)
- Melbourne predictor → Qualifying inputs: uses times (evidence: `README.md`)
- Melbourne predictor → Weather forecast: requests forecast (evidence: `1_melbourne_prediction.py`)
- Weather forecast → WeatherAPI: fetches data
- Melbourne predictor → Feature engineering: engineers features (evidence: `README.md`)
- Melbourne predictor → XGBoost model: trains (evidence: `README.md`)
- Melbourne predictor → Race ranking: ranks times (evidence: `README.md`)
- Melbourne predictor → MAE evaluation: measures error (evidence: `README.md`)
