# bilalbouchroub/bilalbouchroub architecture

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

- Interactive diagram: https://gitdiagram.com/bilalbouchroub/bilalbouchroub
- Repository: https://github.com/bilalbouchroub/bilalbouchroub

## Overview

This repository is a GitHub profile README with scripts that generate its contribution heatmap and profile card, plus a separate photo-to-ASCII portrait utility. The documented contribution workflow fetches public GitHub activity, saves normalized data, and renders the heatmap displayed in the README. The profile card is generated independently. Source excerpts also show the photo preparation and ASCII conversion steps; that portrait is not referenced in the README. The graph covers these utilities rather than the separate projects listed in the profile.

Main entry points: [`scripts/fetch_contributions.py`](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/fetch_contributions.py) (Fetch contributions), [`data/contributions.json`](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/data/contributions.json) (Contribution data), [`scripts/render_heatmap_svg.py`](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/render_heatmap_svg.py) (Heatmap renderer), [`scripts/prep_photo.py`](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/prep_photo.py) (Photo preparation)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_contrib["Contribution display"]
  node_fetch["Fetch contributions"]
  node_data[("Contribution data<br/>[contributions.json]")]
  node_heatmap["Heatmap renderer"]
end

subgraph group_profile["Profile presentation"]
  node_card["Info card generator<br/>[make_info_card.py]"]
  node_readme["GitHub profile README<br/>[README.md]"]
end

subgraph group_portrait["ASCII portrait"]
  node_photo["Source photo"]
  node_prep["Photo preparation<br/>[prep_photo.py]"]
  node_ascii["ASCII portrait renderer<br/>[make_ascii_svg.py]"]
end

node_github(("GitHub contributions"))

node_github -->|"provides HTML"| node_fetch
node_fetch -->|"writes data"| node_data
node_data -->|"reads data"| node_heatmap
node_heatmap -->|"displayed in"| node_readme
node_card -->|"displayed in"| node_readme
node_photo -->|"reads image"| node_prep
node_prep -->|"writes input"| node_ascii

click node_fetch "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/fetch_contributions.py"
click node_data "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/data/contributions.json"
click node_heatmap "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/render_heatmap_svg.py"
click node_card "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/make_info_card.py"
click node_photo "https://github.com/bilalbouchroub/bilalbouchroub/tree/main/assets"
click node_prep "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/prep_photo.py"
click node_ascii "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/make_ascii_svg.py"
click node_readme "https://github.com/bilalbouchroub/bilalbouchroub/blob/main/README.md"

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_fetch,node_data,node_heatmap toneBlue
class node_card,node_readme toneAmber
class node_photo,node_prep,node_ascii toneMint
class node_github toneIndigo
```

## Components

### Contribution display

- [Fetch contributions](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/fetch_contributions.py): `scripts/fetch_contributions.py`
- [Contribution data](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/data/contributions.json): `data/contributions.json`
- [Heatmap renderer](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/render_heatmap_svg.py): `scripts/render_heatmap_svg.py`

### Profile presentation

- [Info card generator](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/make_info_card.py): `scripts/make_info_card.py`
- [GitHub profile README](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/README.md): `README.md`

### ASCII portrait

- [Source photo](https://github.com/bilalbouchroub/bilalbouchroub/tree/main/assets): `assets`
- [Photo preparation](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/prep_photo.py): `scripts/prep_photo.py`
- [ASCII portrait renderer](https://github.com/bilalbouchroub/bilalbouchroub/blob/main/scripts/make_ascii_svg.py): `scripts/make_ascii_svg.py`

### Other components

- **GitHub contributions**

## Connections

- GitHub contributions → Fetch contributions: provides HTML (evidence: `scripts/fetch_contributions.py`)
- Fetch contributions → Contribution data: writes data (evidence: `scripts/fetch_contributions.py`)
- Contribution data → Heatmap renderer: reads data (evidence: `scripts/render_heatmap_svg.py`)
- Heatmap renderer → GitHub profile README: displayed in (evidence: `README.md`)
- Info card generator → GitHub profile README: displayed in (evidence: `README.md`)
- Source photo → Photo preparation: reads image (evidence: `scripts/prep_photo.py`)
- Photo preparation → ASCII portrait renderer: writes input (evidence: `scripts/prep_photo.py`)
