Files
PTSRaiAgent/app/core/privacy.py
T
ElebobaandClaude Opus 5.5 f8b1fa561b
CI / ruff · pytest (pull_request) Successful in 18s
style(core): wrap long docstrings
Refs #2

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 14:50:47 +03:00

17 lines
547 B
Python

"""PII scrubbing and pseudonymisation (issue #2). Contract stub — implementation lands in #2."""
from app.core.types import ScrubbedText
def scrub(text: str) -> ScrubbedText:
"""Replace personal data (phones, emails, SNILS, names, addresses...) with placeholders."""
raise NotImplementedError
def pseudo_id(snils: str, key: str | None = None) -> str:
"""HMAC-SHA256(PSEUDO_KEY, normalised SNILS) as 32 hex chars.
The token is the only link between the identity and clinical databases.
"""
raise NotImplementedError