Fork von Microsoft Presidio spezialisiert auf die Anonymisierung deutscher klinischer Freitexte.
Dieses Projekt entstand um die Komplexität von PII-Erkennung in deutschen klinischen Texten praktisch zu erkunden: Tradeoffs zwischen Erkennungsmethoden verstehen, Design-Entscheidungen und ihre Auswirkungen dokumentieren, Herausforderungen der Domäne kennenlernen.
📊 Demo-Report (8b) | 📊 Demo-Report (14b) - Interaktiver Vergleich: Pattern vs. GLiNER vs. LLM
📝 Findings & Learnings - Dokumentierte Erkenntnisse aus der Entwicklung
📁 Deutsche Demo - Vollständige Anleitung, Testdaten und Skripte
13 Recognizer für deutsche Identifier in presidio-analyzer/presidio_analyzer/predefined_recognizers/country_specific/germany/:
Klinisch/Medizintechnik:
- KVNR (Krankenversichertennummer)
- LANR (Lebenslange Arztnummer)
- BSNR (Betriebsstättennummer)
- Telematik-ID (Gesundheits-ID und eHBA)
Persönliche Dokumente:
- Personalausweis, Reisepass, Führerschein
- Steuer-ID, Sozialversicherungsnummer
Weitere:
- PLZ, Kfz-Kennzeichen, Handelsregisternummer, USt-IdNr
Alle Pattern-Recognizer nutzen Regex mit Prüfsummenvalidierung wo möglich.
Diese Recognizer konnten als PR dem Upstream-Presidio Repository beigetragen werden.
| Recognizer | Beschreibung |
|---|---|
| NvidiaGLiNERPIIRecognizer | Zero-shot PII-Erkennung mit 55+ Entity-Typen, automatisches Chunking für 384-Token-Limit |
| OllamaNERecognizer | LLM-basierte Erkennung via lokalem Ollama, deutsche Prompt-Erweiterungen, Pydantic-Validierung |
Beide ML-basierten Recognizer sind über conf/default_recognizers.yaml konfigurierbar.
anoner/
├── deutsche-demo/ # Demo mit Testdaten und Report
│ ├── eingabe/ # Beispiel-Entlassungsbrief
│ ├── ausgabe/ # Generierter Report + Findings
│ └── demo_skript.py # Ausführbares Vergleichsskript
├── presidio-analyzer/
│ └── presidio_analyzer/
│ └── predefined_recognizers/
│ ├── country_specific/germany/ # 13 deutsche Recognizer
│ └── ner/ # GLiNER + Ollama Integration
└── ...
Context aware, pluggable and customizable PII de-identification service for text and images.
| Component | Downloads | Coverage |
|---|---|---|
| Presidio Analyzer | ||
| Presidio Anonymizer | ||
| Presidio Image-Redactor | ||
| Presidio Structured |
Presidio (Origin from Latin praesidium ‘protection, garrison’) helps to ensure sensitive data is properly managed and governed. It provides fast identification and anonymization modules for private entities in text such as credit card numbers, names, locations, social security numbers, bitcoin wallets, US phone numbers, financial data and more.
💭 Demo
🛫 Examples
Please help us improve by taking this short anonymous survey.
- Allow organizations to preserve privacy in a simpler way by democratizing de-identification technologies and introducing transparency in decisions.
- Embrace extensibility and customizability to a specific business need.
- Facilitate both fully automated and semi-automated PII de-identification flows on multiple platforms.
- Predefined or custom PII recognizers leveraging Named Entity Recognition, regular expressions, rule based logic and checksum with relevant context in multiple languages.
- Options for connecting to external PII detection models.
- Multiple usage options, from Python or PySpark workloads through Docker to Kubernetes.
- Customizability in PII identification and de-identification.
- Module for redacting PII text in images (standard image types and DICOM medical images).
- Getting started
- Setting up a development environment
- PII de-identification in text
- PII de-identification in images
- Usage samples and example deployments
- Before you submit an issue, please go over the documentation.
- For general discussions, please use the GitHub repo's discussion board.
- If you have a usage question, found a bug or have a suggestion for improvement, please file a GitHub issue.
- For other matters, please email presidio@microsoft.com.
For details on contributing to this repository, see the contributing guide.
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.
When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.
