# kavurubuvanesh/flyrank-ml-workspace architecture

> Architecture diagram of the GitHub repository kavurubuvanesh/flyrank-ml-workspace, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/kavurubuvanesh/flyrank-ml-workspace
- Repository: https://github.com/kavurubuvanesh/flyrank-ml-workspace

## Overview

FlyRank ML Internship is an educational starter repo for applied search discoverability, with a runnable refresh-opportunity modeling example. The principal workflow is to prepare the anonymized page data, compare a transparent baseline with trained classifiers, evaluate and rank review opportunities, then produce reports for human review. The README also documents Colab notebooks and a gated full-data notebook path. Script relationships are supported by the sampled code and README; notebook internals were not sampled, so their data wiring is not inferred.

Main entry points: [`scripts/04_evaluate_and_export.py`](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/04_evaluate_and_export.py) (Queue evaluation), [`scripts/run_all.py`](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/run_all.py) (Pipeline runner), [`scripts/01_prepare_features.py`](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/01_prepare_features.py) (Prepare features), [`scripts/02_baseline_score.py`](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/02_baseline_score.py) (Baseline scorer)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_learning["Learning entry points"]
  node_firstnotebook["First-win notebooks"]
  node_fullnotebook["Full-release notebook"]
end

subgraph group_pipeline["Modeling pipeline"]
  node_runner["Pipeline runner<br/>[run_all.py]"]
  node_prepare["Prepare features"]
  node_baseline["Baseline scorer"]
  node_train["Model training<br/>[03_train_model.py]"]
  node_evaluate["Queue evaluation"]
  node_utils["ML utilities<br/>[ml_utils.py]"]
end

subgraph group_results["Review outputs"]
  node_pdf["PDF report builder"]
  node_queue["Ranked review queue"]
  node_reports["Charts and reports"]
end

subgraph group_data["Data sources"]
  node_sample["Anonymized sample"]
  node_features["Feature vector"]
  node_baselinefile["Baseline queue"]
  node_predictions["Model predictions"]
  node_warehouse[("Gated dataset")]
end

node_intern(("Intern"))

node_intern -->|"runs pipeline"| node_runner
node_runner -->|"dispatches"| node_prepare
node_runner -->|"dispatches"| node_baseline
node_runner -->|"dispatches"| node_train
node_runner -->|"dispatches"| node_evaluate
node_runner -->|"dispatches"| node_pdf
node_prepare -->|"reads"| node_sample
node_prepare -->|"writes"| node_features
node_baseline -->|"reads"| node_features
node_baseline -->|"writes"| node_baselinefile
node_train -->|"reads"| node_features
node_train -->|"reads"| node_baselinefile
node_train -->|"writes"| node_predictions
node_evaluate -->|"reads"| node_features
node_evaluate -->|"reads"| node_baselinefile
node_evaluate -->|"reads"| node_predictions
node_evaluate -->|"writes"| node_queue
node_evaluate -->|"writes"| node_reports
node_pdf -->|"writes"| node_reports
node_prepare -->|"uses helpers"| node_utils
node_baseline -->|"uses helpers"| node_utils
node_evaluate -->|"uses helpers"| node_utils
node_intern -->|"opens"| node_firstnotebook
node_intern -->|"opens"| node_fullnotebook
node_fullnotebook -.->|"queries full release"| node_warehouse

click node_runner "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/run_all.py"
click node_prepare "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/01_prepare_features.py"
click node_baseline "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/02_baseline_score.py"
click node_train "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/03_train_model.py"
click node_evaluate "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/04_evaluate_and_export.py"
click node_pdf "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/05_build_pdf_report.py"
click node_utils "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/ml_utils.py"
click node_sample "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/data/raw/content_refresh_anonymized.csv"
click node_queue "https://github.com/kavurubuvanesh/flyrank-ml-workspace/tree/main/outputs"
click node_reports "https://github.com/kavurubuvanesh/flyrank-ml-workspace/tree/main/outputs"
click node_firstnotebook "https://github.com/kavurubuvanesh/flyrank-ml-workspace/tree/main/notebooks"
click node_fullnotebook "https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/notebooks/03_working_with_the_full_release.ipynb"

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_firstnotebook,node_fullnotebook toneBlue
class node_runner,node_prepare,node_baseline,node_train,node_evaluate,node_utils toneAmber
class node_pdf,node_queue,node_reports toneMint
class node_sample,node_features,node_baselinefile,node_predictions,node_warehouse toneRose
class node_intern toneIndigo
```

## Components

### Learning entry points

- [First-win notebooks](https://github.com/kavurubuvanesh/flyrank-ml-workspace/tree/main/notebooks): `notebooks`
- [Full-release notebook](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/notebooks/03_working_with_the_full_release.ipynb): `notebooks/03_working_with_the_full_release.ipynb`

### Modeling pipeline

- [Pipeline runner](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/run_all.py): `scripts/run_all.py`
- [Prepare features](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/01_prepare_features.py): `scripts/01_prepare_features.py`
- [Baseline scorer](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/02_baseline_score.py): `scripts/02_baseline_score.py`
- [Model training](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/03_train_model.py): `scripts/03_train_model.py`
- [Queue evaluation](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/04_evaluate_and_export.py): `scripts/04_evaluate_and_export.py`
- [ML utilities](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/ml_utils.py): `scripts/ml_utils.py`

### Review outputs

- [PDF report builder](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/scripts/05_build_pdf_report.py): `scripts/05_build_pdf_report.py`
- [Ranked review queue](https://github.com/kavurubuvanesh/flyrank-ml-workspace/tree/main/outputs): `outputs`
- [Charts and reports](https://github.com/kavurubuvanesh/flyrank-ml-workspace/tree/main/outputs): `outputs`

### Data sources

- [Anonymized sample](https://github.com/kavurubuvanesh/flyrank-ml-workspace/blob/main/data/raw/content_refresh_anonymized.csv): `data/raw/content_refresh_anonymized.csv`
- **Feature vector**
- **Baseline queue**
- **Model predictions**
- **Gated dataset**

### Other components

- **Intern**

## Connections

- Intern → Pipeline runner: runs pipeline
- Pipeline runner → Prepare features: dispatches
- Pipeline runner → Baseline scorer: dispatches
- Pipeline runner → Model training: dispatches
- Pipeline runner → Queue evaluation: dispatches
- Pipeline runner → PDF report builder: dispatches
- Prepare features → Anonymized sample: reads
- Prepare features → Feature vector: writes
- Baseline scorer → Feature vector: reads
- Baseline scorer → Baseline queue: writes
- Model training → Feature vector: reads
- Model training → Baseline queue: reads
- Model training → Model predictions: writes
- Queue evaluation → Feature vector: reads
- Queue evaluation → Baseline queue: reads
- Queue evaluation → Model predictions: reads
- Queue evaluation → Ranked review queue: writes
- Queue evaluation → Charts and reports: writes
- PDF report builder → Charts and reports: writes
- Prepare features → ML utilities: uses helpers
- Baseline scorer → ML utilities: uses helpers
- Queue evaluation → ML utilities: uses helpers
- Intern → First-win notebooks: opens
- Intern → Full-release notebook: opens
- Full-release notebook → Gated dataset: queries full release
