docs: CHANGELOG + PROJECT.md for group_key grouping + report PDF

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Deeman
2026-02-27 07:56:34 +01:00
parent 2325e9b51e
commit ce2171614b
2 changed files with 15 additions and 1 deletions

View File

@@ -16,6 +16,18 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
- **Opportunity Score supply gap ceiling raised 4→8/100k** (`location_opportunity_profile.sql`) — gentler gradient for partially-served markets; accounts for ~87% data undercount vs FIP real-world totals. Documents discovered formula behaviour: DuckDB `LEAST(1.0, NULL)=1.0` means NULL catchment already yields full 15 pts; income PPS saturates for all EU countries; tennis courts data currently empty (formula correct, data pending)
### Added
- **group_key static article grouping** — admin articles list now groups EN/DE static cornerstone articles into one row with language chips, matching the existing pSEO grouping behavior:
- Migration 0020: `group_key TEXT` column + index on `articles` table
- `_sync_static_articles()` auto-upserts `data/content/articles/*.md` on every admin articles page load; reads `cornerstone` frontmatter → `group_key`
- `_get_article_list_grouped()` uses `COALESCE(group_key, url_path)` as group key; pSEO articles unchanged (group_key NULL falls back to url_path)
- **Email-gated State of Padel Q1 2026 report PDF**:
- `data/content/reports/` — new directory for market intelligence reports; state-of-padel .md files moved here from articles/
- `reports/` blueprint: `GET/POST /<lang>/reports/<slug>` (email capture gate), `GET /<lang>/reports/<slug>/download` (PDF serve)
- Premium WeasyPrint PDF: full-bleed navy cover, Padelnomics wordmark watermark at 3.5% opacity repeated every page via `position:fixed`, gold/teal accents, Georgia headings, running headers/footers via CSS named strings
- `make report-pdf` target builds EN + DE PDFs from the .md files
- 26 new `report_q1_*` i18n keys in EN + DE (native German via linguistic-mediation)
- `/reports` added to `RESERVED_PREFIXES`; `data/content/reports/_build/` gitignored
- **Opportunity Score integration** — second scoring dimension (`Marktpotenzial`) now visible in city and country articles:
- **SQL chain**: `dim_cities` now carries `geoname_id` (from the existing GeoNames LEFT JOIN); threaded through `city_market_profile``pseo_city_costs_de` which LEFT JOINs `location_opportunity_profile` on `(country_code, geoname_id)`; `pseo_country_overview` gains `avg_opportunity_score`, `top_opportunity_score`, `top_opportunity_slugs`, `top_opportunity_names`
- **71.4% match rate** — 3,350 of 4,693 cities matched to a GeoNames `geoname_id`; unmatched cities gracefully show no Opportunity Score