# srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline architecture

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

- Interactive diagram: https://gitdiagram.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline
- Repository: https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline

## Overview

Chronos is a local batch feature-engineering demonstration, not a model-training or deployed serving system. Its main workflow reads customer, transaction, and prediction-request CSVs; validates and quarantines rows; builds point-in-time features and separate future labels; publishes results to SQLite; then reconciles and exports run artifacts. The Streamlit dashboard exposes execution and result inspection, while deterministic data generation and a point-in-time demo are separate capabilities. Relationships follow the README and the sampled orchestrator; unsampled implementation details are not inferred.

Main entry points: [`src/pipeline.py`](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/pipeline.py) (Pipeline orchestrator), [`src/features.py`](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/features.py) (Feature builder), [`src/publish.py`](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/publish.py) (SQLite store), [`src/ingest.py`](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/ingest.py) (CSV ingestion)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["User entry points"]
  node_dashboard["Streamlit dashboard<br/>[app.py]"]
end

subgraph group_pipeline["Batch pipeline"]
  node_orchestrator["Pipeline orchestrator<br/>[pipeline.py]"]
  node_ingestion["CSV ingestion<br/>[ingest.py]"]
  node_validation["Validation and quarantine<br/>[validate.py]"]
  node_feature_builder["Feature builder<br/>[features.py]"]
  node_label_builder["Label builder<br/>[labels.py]"]
  node_run_metrics["Run metrics<br/>[metrics.py]"]
end

subgraph group_contracts["Shared semantics"]
  node_config["Feature configuration<br/>[config.py]"]
  node_schemas["Data contracts<br/>[schemas.py]"]
  node_time_utils["UTC time utilities<br/>[timeutil.py]"]
end

subgraph group_persistence["Persistence and outputs"]
  node_sqlite[("SQLite store<br/>[publish.py]")]
  node_reconciliation["Reconciliation<br/>[reconcile.py]"]
  node_artifacts["CSV exports and reports"]
end

subgraph group_capabilities["Supporting capabilities"]
  node_generator["Synthetic data generator<br/>[generate_data.py]"]
  node_demo["Point-in-time demo<br/>[demo.py]"]
end

node_operator(("Operator"))
node_csv_sources["Input CSVs"]

node_operator -->|"opens"| node_dashboard
node_operator -->|"runs"| node_orchestrator
node_dashboard -->|"runs pipeline"| node_orchestrator
node_csv_sources -->|"provides CSVs"| node_ingestion
node_orchestrator -->|"invokes"| node_ingestion
node_orchestrator -->|"invokes"| node_validation
node_orchestrator -->|"invokes"| node_feature_builder
node_orchestrator -->|"invokes"| node_label_builder
node_orchestrator -->|"publishes through"| node_sqlite
node_orchestrator -->|"runs checks"| node_reconciliation
node_orchestrator -->|"records timings"| node_run_metrics
node_ingestion -->|"passes raw rows"| node_validation
node_validation -->|"passes valid rows"| node_feature_builder
node_validation -->|"quarantines rejects"| node_sqlite
node_feature_builder -->|"publishes features"| node_sqlite
node_label_builder -->|"publishes labels"| node_sqlite
node_sqlite -->|"checks stored data"| node_reconciliation
node_orchestrator -->|"exports results"| node_artifacts
node_sqlite -->|"exports tables"| node_artifacts
node_generator -->|"generates data"| node_csv_sources
node_operator -->|"runs"| node_generator
node_operator -->|"runs"| node_demo
node_ingestion -->|"uses contracts"| node_schemas
node_validation -->|"uses contracts"| node_schemas
node_feature_builder -->|"uses contracts"| node_schemas
node_feature_builder -->|"reads settings"| node_config
node_label_builder -->|"reads settings"| node_config
node_ingestion -->|"parses timestamps"| node_time_utils
node_feature_builder -->|"converts timestamps"| node_time_utils
node_label_builder -->|"converts timestamps"| node_time_utils
node_reconciliation -->|"audits parity"| node_feature_builder

click node_dashboard "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/app.py"
click node_orchestrator "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/pipeline.py"
click node_ingestion "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/ingest.py"
click node_validation "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/validate.py"
click node_feature_builder "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/features.py"
click node_label_builder "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/labels.py"
click node_run_metrics "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/metrics.py"
click node_config "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/config.py"
click node_schemas "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/schemas.py"
click node_time_utils "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/timeutil.py"
click node_sqlite "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/publish.py"
click node_reconciliation "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/reconcile.py"
click node_artifacts "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/tree/main/outputs"
click node_generator "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/generate_data.py"
click node_demo "https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/demo.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_dashboard toneBlue
class node_orchestrator,node_ingestion,node_validation,node_feature_builder,node_label_builder,node_run_metrics toneAmber
class node_config,node_schemas,node_time_utils toneMint
class node_sqlite,node_reconciliation,node_artifacts toneRose
class node_generator,node_demo,node_operator,node_csv_sources toneIndigo
```

## Components

### User entry points

- [Streamlit dashboard](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/app.py): `app.py`

### Batch pipeline

- [Pipeline orchestrator](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/pipeline.py): `src/pipeline.py`
- [CSV ingestion](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/ingest.py): `src/ingest.py`
- [Validation and quarantine](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/validate.py): `src/validate.py`
- [Feature builder](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/features.py): `src/features.py`
- [Label builder](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/labels.py): `src/labels.py`
- [Run metrics](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/metrics.py): `src/metrics.py`

### Shared semantics

- [Feature configuration](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/config.py): `src/config.py`
- [Data contracts](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/schemas.py): `src/schemas.py`
- [UTC time utilities](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/timeutil.py): `src/timeutil.py`

### Persistence and outputs

- [SQLite store](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/publish.py): `src/publish.py`
- [Reconciliation](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/reconcile.py): `src/reconcile.py`
- [CSV exports and reports](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/tree/main/outputs): `outputs`

### Supporting capabilities

- [Synthetic data generator](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/generate_data.py): `src/generate_data.py`
- [Point-in-time demo](https://github.com/srilekhaejnavarjala/yottaflex-chronos-ml-feature-pipeline/blob/main/src/demo.py): `src/demo.py`

### Other components

- **Operator**
- **Input CSVs**

## Connections

- Operator → Streamlit dashboard: opens (evidence: `README.md`)
- Operator → Pipeline orchestrator: runs (evidence: `README.md`)
- Streamlit dashboard → Pipeline orchestrator: runs pipeline (evidence: `README.md`)
- Input CSVs → CSV ingestion: provides CSVs (evidence: `README.md`)
- Pipeline orchestrator → CSV ingestion: invokes (evidence: `src/pipeline.py`)
- Pipeline orchestrator → Validation and quarantine: invokes (evidence: `src/pipeline.py`)
- Pipeline orchestrator → Feature builder: invokes (evidence: `src/pipeline.py`)
- Pipeline orchestrator → Label builder: invokes (evidence: `src/pipeline.py`)
- Pipeline orchestrator → SQLite store: publishes through (evidence: `src/pipeline.py`)
- Pipeline orchestrator → Reconciliation: runs checks (evidence: `src/pipeline.py`)
- Pipeline orchestrator → Run metrics: records timings (evidence: `README.md`)
- CSV ingestion → Validation and quarantine: passes raw rows (evidence: `README.md`)
- Validation and quarantine → Feature builder: passes valid rows (evidence: `README.md`)
- Validation and quarantine → SQLite store: quarantines rejects (evidence: `README.md`)
- Feature builder → SQLite store: publishes features (evidence: `README.md`)
- Label builder → SQLite store: publishes labels (evidence: `README.md`)
- SQLite store → Reconciliation: checks stored data (evidence: `README.md`)
- Pipeline orchestrator → CSV exports and reports: exports results (evidence: `README.md`)
- SQLite store → CSV exports and reports: exports tables (evidence: `README.md`)
- Synthetic data generator → Input CSVs: generates data (evidence: `README.md`)
- Operator → Synthetic data generator: runs (evidence: `README.md`)
- Operator → Point-in-time demo: runs (evidence: `README.md`)
- CSV ingestion → Data contracts: uses contracts (evidence: `src/ingest.py`)
- Validation and quarantine → Data contracts: uses contracts (evidence: `src/validate.py`)
- Feature builder → Data contracts: uses contracts (evidence: `src/features.py`)
- Feature builder → Feature configuration: reads settings (evidence: `src/features.py`)
- Label builder → Feature configuration: reads settings (evidence: `src/labels.py`)
- CSV ingestion → UTC time utilities: parses timestamps (evidence: `src/ingest.py`)
- Feature builder → UTC time utilities: converts timestamps (evidence: `src/features.py`)
- Label builder → UTC time utilities: converts timestamps (evidence: `src/labels.py`)
- Reconciliation → Feature builder: audits parity (evidence: `src/reconcile.py`)
