artenschutz-router/sources/README.md
m2 (AI Agent) 6da874b2e6 Initial commit — phase 1 + 2 of artenschutz-digest concept
Phase 1: router skeleton + Qdrant read path
- FastAPI app with /health, /search/generic, /ingest endpoints
- Qdrant reader (hybrid dense+sparse w/ RRF, plus payload scroll)
- BGE-M3 TEI client for query-side embedding
- memory-api client proxying writes to /memory/store (m2-memory untouched)
- Pydantic Fact + Exemplar payloads, discriminated by `kind`
- Dockerfile + docker-compose joining the coolify Docker network

Phase 2: authoritative-source ingest pipeline
- PDF text extraction + paragraph-aware (§ N) and size chunkers
- Loaders for bnatschg, mhbasp, biotopwertliste, state-<slug>
- CLI: artenschutz-ingest --source <name> [--states ...] [--dry-run]
- Helper script to fetch BNatSchG from gesetze-im-internet.de
- End-to-end smoke script (scripts/smoke.sh) for Coolify validation

22/22 unit tests pass. Real-world dry-runs verified against mhbasp Anhang 4,
biotopwertlisteNEU and Berlin Kartierstandards PDFs from GST-DATA.

See COOLIFY-DEPLOY.md for staging deploy + smoke procedure.
2026-05-14 16:36:00 +02:00

22 lines
1.7 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Authoritative source files
The ingest pipeline reads from this tree. Files are git-ignored (large + may
have licensing constraints) — keep originals here on each operator's machine.
| Subdir | Expected files | Notes |
|---|---|---|
| `bnatschg/` | `bnatschg.txt` (current consolidated text of §44, §45b, Anlagen) | Fetch from <https://www.gesetze-im-internet.de/bnatschg_2009/> — paste as UTF-8 plain text. One `§ N ...` per heading line. Cross-reference: a `.webloc` link to <https://www.buzer.de/Anlage_1_BNatSchG.htm> already lives in `GST-DATA/xx_GS_VORLAGEN_FachGA/`. |
| `mhbasp/` | `mhbasp_anhang4.pdf` | "Methodische Hinweise und Behandlungsempfehlungen ASP" Anhang 4 — species × method matrix |
| `biotopwertliste/` | `biotopwertliste.pdf` | A biotope value list — **always state-specific**. Pass `--states BE` (or BB, BY, …) when ingesting. State-specific lists are also welcome under `states/<slug>/`; the generic slot here is for one-off cases. |
| `states/berlin/` | One or more state-specific PDFs (Kartierstandards, methodische Hinweise) | First state implemented as proof-of-concept |
| `states/brandenburg/`<br>`states/bayern/`<br>`states/baden_wuerttemberg/`<br>`states/sachsen/` | TODO | Add as ingest support is implemented per state |
A copy of `mhbasp_anhang4_artspezifisch geeignete kartiermethoden.pdf` already
lives under `GST-DATA/xx_GS_VORLAGEN_FachGA/`. Symlinking is fine:
```bash
ln -s "/home/m2/clients/SDJS/GST-DATA/xx_GS_VORLAGEN_FachGA/mhbasp_anhang4_artspezifisch geeignete kartiermethoden.pdf" \
sources/mhbasp/mhbasp_anhang4.pdf
ln -s "/home/m2/clients/SDJS/GST-DATA/xx_GS_VORLAGEN_FachGA/biotopwertlisteNEU.pdf" \
sources/biotopwertliste/biotopwertliste.pdf
```