# vaso-1234/daily-news architecture

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

- Interactive diagram: https://gitdiagram.com/vaso-1234/daily-news
- Repository: https://github.com/vaso-1234/daily-news

## Overview

The World Today is a static news briefing: an hourly refresh collects BBC and WSJ headlines, enriches and summarizes stories, and publishes a JSON payload for a browser-based site. The main path runs from scheduled refresh through feed selection, article enrichment, summary generation, and payload storage to client rendering. The site also supports source filters, freshness status, manual refresh, and periodic polling. The README documents deployment and cadence; source excerpts show client-side loading and parts of the fetcher, but not every internal implementation detail.

Main entry points: [`site/app.js`](https://github.com/vaso-1234/daily-news/blob/main/site/app.js) (Briefing client), [`.github/workflows/refresh-news.yml`](https://github.com/vaso-1234/daily-news/blob/main/.github/workflows/refresh-news.yml) (Refresh workflow), [`scripts/fetch_news.py`](https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py) (Feed fetcher), [`site/index.html`](https://github.com/vaso-1234/daily-news/blob/main/site/index.html) (Page shell)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_refresh["News refresh"]
  node_workflow["Refresh workflow<br/>[refresh-news.yml]"]
  node_fetcher["Feed fetcher<br/>[fetch_news.py]"]
end

subgraph group_content["Story processing"]
  node_selection["Story selection<br/>[fetch_news.py]"]
  node_article["Article enrichment<br/>[fetch_news.py]"]
  node_summary["Summary composition<br/>[fetch_news.py]"]
  node_payload[("Briefing payload<br/>[data.json]")]
end

subgraph group_site["Briefing site"]
  node_shell["Page shell<br/>[index.html]"]
  node_client["Briefing client<br/>[app.js]"]
  node_filters["Source filters<br/>[app.js]"]
  node_cards["Story cards<br/>[app.js]"]
  node_status["Freshness status<br/>[app.js]"]
  node_theme["Magazine theme<br/>[styles.css]"]
end

subgraph group_delivery["Publishing"]
  node_commit["Commit and push<br/>[refresh-news.yml]"]
end

node_schedule(("Hourly schedule"))
node_rss[("BBC and Bing RSS")]
node_articlepages["Publisher article pages"]
node_pages["GitHub Pages"]
node_reader(("Reader browser"))

node_schedule -->|"triggers hourly"| node_workflow
node_workflow -->|"runs refresh"| node_fetcher
node_fetcher -->|"fetches feeds"| node_rss
node_fetcher -->|"selects stories"| node_selection
node_selection -->|"enriches items"| node_article
node_article -->|"fetches pages"| node_articlepages
node_article -->|"supplies article text"| node_summary
node_summary -->|"writes summaries"| node_payload
node_workflow -->|"commits updates"| node_commit
node_commit -->|"redeploys site"| node_pages
node_reader -->|"opens briefing"| node_pages
node_pages -->|"serves page"| node_shell
node_client -->|"fetches JSON"| node_payload
node_client -->|"renders filters"| node_filters
node_client -->|"renders stories"| node_cards
node_client -->|"updates status"| node_status
node_client -->|"binds page elements"| node_shell
node_shell -.->|"uses styling"| node_theme

click node_workflow "https://github.com/vaso-1234/daily-news/blob/main/.github/workflows/refresh-news.yml"
click node_fetcher "https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py"
click node_selection "https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py"
click node_article "https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py"
click node_summary "https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py"
click node_payload "https://github.com/vaso-1234/daily-news/blob/main/site/data.json"
click node_commit "https://github.com/vaso-1234/daily-news/blob/main/.github/workflows/refresh-news.yml"
click node_shell "https://github.com/vaso-1234/daily-news/blob/main/site/index.html"
click node_client "https://github.com/vaso-1234/daily-news/blob/main/site/app.js"
click node_filters "https://github.com/vaso-1234/daily-news/blob/main/site/app.js"
click node_cards "https://github.com/vaso-1234/daily-news/blob/main/site/app.js"
click node_status "https://github.com/vaso-1234/daily-news/blob/main/site/app.js"
click node_theme "https://github.com/vaso-1234/daily-news/blob/main/site/styles.css"

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_workflow,node_fetcher,node_reader toneBlue
class node_selection,node_article,node_summary,node_payload,node_rss toneAmber
class node_shell,node_client,node_filters,node_cards,node_status,node_theme toneMint
class node_commit toneRose
class node_schedule,node_articlepages,node_pages toneIndigo
```

## Components

### News refresh

- [Refresh workflow](https://github.com/vaso-1234/daily-news/blob/main/.github/workflows/refresh-news.yml): `.github/workflows/refresh-news.yml`
- [Feed fetcher](https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py): `scripts/fetch_news.py`

### Story processing

- [Story selection](https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py): `scripts/fetch_news.py`
- [Article enrichment](https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py): `scripts/fetch_news.py`
- [Summary composition](https://github.com/vaso-1234/daily-news/blob/main/scripts/fetch_news.py): `scripts/fetch_news.py`
- [Briefing payload](https://github.com/vaso-1234/daily-news/blob/main/site/data.json): `site/data.json`

### Briefing site

- [Page shell](https://github.com/vaso-1234/daily-news/blob/main/site/index.html): `site/index.html`
- [Briefing client](https://github.com/vaso-1234/daily-news/blob/main/site/app.js): `site/app.js`
- [Source filters](https://github.com/vaso-1234/daily-news/blob/main/site/app.js): `site/app.js`
- [Story cards](https://github.com/vaso-1234/daily-news/blob/main/site/app.js): `site/app.js`
- [Freshness status](https://github.com/vaso-1234/daily-news/blob/main/site/app.js): `site/app.js`
- [Magazine theme](https://github.com/vaso-1234/daily-news/blob/main/site/styles.css): `site/styles.css`

### Publishing

- [Commit and push](https://github.com/vaso-1234/daily-news/blob/main/.github/workflows/refresh-news.yml): `.github/workflows/refresh-news.yml`

### Other components

- **Hourly schedule**
- **BBC and Bing RSS**
- **Publisher article pages**
- **GitHub Pages**
- **Reader browser**

## Connections

- Hourly schedule → Refresh workflow: triggers hourly (evidence: `README.md`)
- Refresh workflow → Feed fetcher: runs refresh (evidence: `README.md`)
- Feed fetcher → BBC and Bing RSS: fetches feeds (evidence: `README.md`)
- Feed fetcher → Story selection: selects stories (evidence: `README.md`)
- Story selection → Article enrichment: enriches items (evidence: `README.md`)
- Article enrichment → Publisher article pages: fetches pages (evidence: `README.md`)
- Article enrichment → Summary composition: supplies article text (evidence: `README.md`)
- Summary composition → Briefing payload: writes summaries (evidence: `README.md`)
- Refresh workflow → Commit and push: commits updates (evidence: `README.md`)
- Commit and push → GitHub Pages: redeploys site (evidence: `README.md`)
- Reader browser → GitHub Pages: opens briefing (evidence: `README.md`)
- GitHub Pages → Page shell: serves page (evidence: `README.md`)
- Briefing client → Briefing payload: fetches JSON (evidence: `site/app.js`)
- Briefing client → Source filters: renders filters (evidence: `site/app.js`)
- Briefing client → Story cards: renders stories (evidence: `site/app.js`)
- Briefing client → Freshness status: updates status (evidence: `site/app.js`)
- Briefing client → Page shell: binds page elements (evidence: `site/app.js`)
- Page shell → Magazine theme: uses styling
