AI-assisted development: this pipeline and report were developed with GitHub Copilot and the Anthropic Claude API (
claude-sonnet-4-6), with human review.
⚠️ Automated extraction — verification required. Case counts are extracted by an AI vision model without systematic manual verification. Values should be checked against the original INSP DRC PDFs before any operational or clinical use. For research and situational awareness only.
Extracts key epidemiological tables from INSP DRC Ebola SitRep PDFs with Claude, then builds standardised CSV outputs and an HTML report, including cross-source validation against INRB-UMIE manual extraction (local fallback: outputs/sitrep_report.html).
Figure: Cross-source validation of cumulative confirmed cases, suspect/probable cases, and outbreak deaths by health zone, comparing automated extraction with INRB-UMIE manual extraction.
Author: Billy J Quilty (Charité Berlin, LSHTM & MSF Epicentre)
Prerequisites:
- Python 3.10+
- R (for report generation)
- Quarto CLI (for rendering HTML report)
- Anthropic API key
Setup:
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .envAdd your key to .env (ANTHROPIC_API_KEY or CLAUDE_API_KEY).
source .env
python3 scripts/fetch_sitreps.py
python3 scripts/extract_sitrep.py --updateWhat this does:
- Downloads new SitRep PDFs to
data/raw/<sitrep_name>/ - Skips already processed files using
data/processed/processed.json - Appends new rows to
data/processed/master_combined_counts.csv
Single PDF:
source .env
python3 scripts/extract_sitrep.py path/to/SitRep.pdfBatch PDFs:
python3 scripts/extract_sitrep.py SitRep_001.pdf SitRep_002.pdf SitRep_006.pdfRender report:
quarto render sitrep_report.qmdRun tests:
pytest tests/ -vPer SitRep (data/processed/epicentre_format/<sitrep_name>/):
new_cases_counts.csvcumulative_counts.csvcombined_counts.csv
Raw extraction JSONs and PDFs (data/raw/<sitrep_name>/, gitignored):
raw_extraction.json<sitrep_name>.pdfmanifest.json(atdata/raw/root)
Master aggregate files (data/processed/):
master_combined_counts.csvmaster_response_counts.csvmaster_poe_counts.csvprocessed.json
INRB-UMIE format files (data/processed/insp_format/):
insp_sitrep__*.csv(20 per-metric files)
Report (outputs/):
sitrep_report.html
ANTHROPIC_API_KEY(preferred)CLAUDE_API_KEY(fallback)ANTHROPIC_MODEL(optional, default:claude-sonnet-4-6)
count_typevalues in combined tables areNouveauxandCumules.NDvalues from source PDFs are stored as blanks.- Subtotals/totals are preserved when present in source tables.
- SitReps 015 and 016 (29–30 May 2026) were not published on the INSP website at the time of extraction. Their PDFs were sourced from the INRB-UMIE/Ebola_DRC_2026 repository and are recorded in
data/raw/manifest.jsonwith asource_notefield. These entries will be replaced with direct INSP downloads once the PDFs are published.
This feature is experimental. It requires VS Code with GitHub Copilot and the
agentchat mode.
The pipeline can be orchestrated end-to-end via a custom GitHub Copilot agent defined in .github/agents/sitrep-orchestrator.agent.md. The agent calls the same underlying scripts but handles fetch, extract, INRB-UMIE submodule update, render, and deploy autonomously — with reactive error diagnosis at each stage.
Setup: no additional installation is required beyond the standard prerequisites above. The agent uses the skills in .github/skills/ for domain-specific guidance.
Usage: open GitHub Copilot Chat in VS Code, switch to Agent mode, select sitrep-orchestrator, and send a prompt such as:
check for updates
run full pipeline
render report
compare against INRB data
The agent runs fetch_sitreps.py, extract_sitrep.py --update, updates the INRB-UMIE submodule, renders the Quarto report, and pushes to origin/main — prompting you before any destructive step.
MIT. See LICENSE.
