# HSEQ Intelligence Monitor - Changelog ## [0.2-DRAFT] - 2026-04-04 ### Toegevoegd - **Compliance Tracker Module** (v1.0) - Nieuwe database tabel `compliance_items` met 15 BRZO 2015 seed items - CRUD API routes: GET/POST/PUT/DELETE `/api/compliance` - Statistieken API: `/api/compliance/stats` - Compliance Tracker pagina: `/compliance` (⚖️ icoon in navigatie) - Status badges: compliant (groen), in_progress (geel), overdue (rood), open (grijs) - Priority badges: critical (rood), high (oranje), medium (geel), low (grijs) - Filtering op category, status, priority, zoekveld - Inline editing voor status, owner, notes - Responsive design consistent met bestaand dashboard ### Gewijzigd - Navigatie uitgebreid met "⚖️ Compliance" link - CSS uitgebreid met compliance badge styling - `ensure_db()` functie initieert nu ook compliance tabel en seed data --- *EA_04 — HSEQ Specialist | 4 april 2026* *Compliance Tracker module voltooid om 09:45 UTC* ## [0.1-DRAFT] - 2026-04-01 ### Toegevoegd - Initële projectstructuur aangemaakt - `sources.json` (v0.1) - 20 HSEQ-bronnen gedefinieerd - Compliance Gap Analysis (v0.1) - Analyse 91 PDF's - Consultancy Kansen (v0.1) - Marktanalyse ### Analyse Resultaten - **Totaal PDF's in kennisbank:** 91 bestanden - **Tier 1 (procedures/):** LEEG - Kritieke gap - **Tier 2 (regulations/):** LEEG - Kritieke gap - **Tier 3 (Scraped_Data/):** 2 bestanden (actief) ### Geïdentificeerde Gaps - Ontbrekende PGS-richtlijnen (PGS 1-37) - DGS-reeks niet aanwezig - Seveso-III uitvoeringsregels ontbreken - ISO 45001:2018 implementatiehandleidingen ### Bronnen Verificatie - SodM URL stabiel (www.sodm.nl) - NOGEPA naam ongewijzigd - NLA site traag (rate limiting aanbevolen) ### Deliverables - `working/sources.json` — 20 HSEQ-bronnen gedefinieerd - `deliverables/compliance-gap-analysis-v0.1.html` — Compleet rapport - `deliverables/consultancy-kansen-v0.1.html` — Marktanalyse ### Bronnen Verificatie Resultaten | Bron | Status | Opmerking | |------|--------|-----------| | Overheid.nl | ✅ ACTIEF | Wettendatabase stabiel | | Inspectie SZW | ✅ ACTIEF | Nieuwe naam, URL stabiel | | SodM | ✅ ACTIEF | URL ongewijzigd | | NLA | ⚠️ TRAAG | Rate limiting aanbevolen | | NOGEPA | ✅ ACTIEF | Naam ongewijzigd, geen rebrand | | TNO | ✅ ACTIEF | Kennisinstelling | | RIVM | ✅ ACTIEF | BRZO-pagina beschikbaar | | NEN | ✅ ACTIEF | Betaalde normen tracking | | PGS | ✅ ACTIEF | Alle richtlijnen online | | EU-OSHA | ✅ ACTIEF | EU-niveau bron | --- *EA_04 — HSEQ Specialist | 1 april 2026* *Bronnenanalyse voltooid om 21:35 UTC* --- ## Fase 5 — Professionalisatie (13 april 2026) **Versie**: v5.0.0 ### Nieuwe modules - **module_auth.py** — Authenticatie & autorisatie - Login pagina (/login) met e-mail + wachtwoord - Rollen: admin, hseq_manager, readonly - Multi-tenant bedrijfsisolatie (companies, users tabellen) - Admin bedrijvenbeheer (/admin/companies) - Admin gebruikersbeheer (/admin/users) - Seed: jorick@jvgconsultancy.nl / HSEQ2026! (admin) - Seed: JvG Consultancy B.V. (BRZO-classificatie) - **module_notification.py** — Notificaties & rapportages - In-app notificatie feed (bell icon in header) - API: /api/notifications, /api/notifications//read - Wekelijks compliance rapport: /reports/weekly (print-vriendelijk) - API: /api/reports/weekly (JSON) ### UI Polish - **Dark mode**: toggle knop in header, CSS variables, localStorage persistentie - **Navigatie opgeschoond**: dubbele entries verwijderd, logische structuur: - Overview → VBS → Tools & Scans → Kennisbank → BRZO Diensten → Admin - **Notification bell**: header toont unread count badge + dropdown panel - **Logout**: sidebar logout knop ### Technische wijzigingen - Flask session support (SECRET_KEY via env var) - CSS variables voor dark mode thema - app.py: secret_key, session import, module registrations ## v2.1.0 — 2026-04-13 — Agent Task Executor Backend ### Toegevoegd - **module_agent_executor.py**: Background thread executor die pending tasks oppakt en via OpenRouter API uitvoert - Pollt elke 5 seconden `agent_tasks` tabel op status='pending' - Serieel: max 1 task tegelijk - Status flow: pending → running → completed/failed - SQLite locking met `BEGIN IMMEDIATE` voor writes - API timeout: 120 seconden - Graceful shutdown via daemon thread + stop event - **Agent personalities**: 10 gespecialiseerde prompt templates per agent type - **Workflow prompts**: 6 workflow-specifieke prompt templates (RI&E, TRA, Training, Compliance, Audit, Incident) - **API endpoints**: - `GET /api/agents/executor/status` — Executor status + queue size - `POST /api/agents/executor/restart` — Herstart executor thread - `POST /api/agents/task//retry` — Failed/completed task opnieuw uitvoeren - `POST /api/agents/task//cancel` — Pending/running task annuleren ### UI Updates (module_agents.py) - Executor status indicator (🟢/🔴) op Taak Historie sectie met live polling elke 5 seconden - Task status live-updates in tabel (pending → running → completed/failed) - Retry knop (🔄) bij failed tasks - Cancel knop (✖) bij pending/running tasks - Resultaat weergave met retry optie bij failed tasks ### Techniek - Threading (geen multiprocessing — SQLite thread-safety) - Kennisbank context automatisch toegevoegd via metadata - App.py integratie: executor.start() bij app startup, daemon thread stopt automatisch bij PM2 stop ## [v1.1] — 2026-04-16 ### HSEQ Dashboard Gebruikershandleiding v1.1 - **Toegevoegd**: Sectie 9.3 HSEQ Compliance Hub — overzicht van het intelligence-platform - **Toegevoegd**: Sectie 9.4 Intelligence Feed — volledige documentatie van insight card elementen (actietype badge, impact indicator, regulatory deadline, actie-aanmaak knop, bron link, consultant take, voorgestelde actie) - **Toegevoegd**: Sectie 9.4.2 Impact Indicator Kleurcodering referentietabel (HOOG/MIDDEL/LAAG met kleurcodes) - **Toegevoegd**: Sectie 9.5 Intelligence Feed — Acties aanmaken (6-stappen workflow documentatie) - **Toegevoegd**: Sectie 9.6 Live Scraper Feed (automatische scrape, actie-aanmaak MONITOR/MIDDEL/SCRAPE) - **Toegevoegd**: Sectie 9.7 Acties tabblad (statussen, velden, sorteer- en sluitfunctionaliteit) - **Toegevoegd**: Tabel 9.2 Acties Overzicht Velden - **Bijgewerkt**: Inhoudsopgave uitgebreid met secties 9.3–9.7 - **Archief**: v1.0 gearchiveerd naar /docs/archive/ | v2.1.0 | 2026-04-19 | Agent Launchpad MASTER_SOP Compliance Fix | software_architect | ## v2.1.0 — MASTER_SOP Compliance Fix (2026-04-19) ### P0 — CRITICAL 1. **AI Call Timeout**: max_tokens 16000→8000, API_TIMEOUT 180→300s 2. **JSON compacted**: Removed elearning_pages, kennisdossier_sections, tables_for_html from AI JSON output. Backend generates these from docx_content. 3. **Deliverables Matrix (§3.5)**: All 30 agents now have correct deliverable_note 4. **SST Protocol (§14.2)**: Strengthened in system prompt — mandatory activation 5. **Cancel endpoint**: Already present in register_executor_routes (confirmed working) ### P1 — HIGH 6. **MASTER_STYLEGUIDE §1.2 colors**: Agent cards border #3B82F6→#003366, workflow cards #10B981→#00A859 7. **Agent Register (§2.1)**: AGENTS expanded from 10→30 agents with division field (all 5 divisions) 8. **SCORM generation**: Skipped (not critical), logged warning 9. **AGENT_PERSONALITIES**: Expanded to cover all 30 agents 10. **Backups**: .bak.pre-sop-compliance-20260419 created for both files