extracting-pii-entities
便于在去标识化前审计或自定义脱敏策略,支持查看而非直接删除。
识别可能不完美,误判或漏检均有合规风险;处理时注意权限控制。
使用openmed.extract_pii检测临床文本中的PII/PHI并返回偏移与标签,不改变文本。
仅检测并返回文本里 PHI/PII 的位置和标签,不修改原文,便于审计或把结果交给自定义的脱敏器处理。用在你想先看哪些字段会被识别(姓名、日期、病历号、地址等)再决定如何脱敏或路由时。同样在本地运行,可按置信度和语言过滤,清楚知道会被去掉或替换的精确偏移。
▸ 展开 SKILL.md 英文原文
Detect PHI/PII spans in clinical text with OpenMed's extract_pii without altering the text. Use when the user wants to find names, dates, MRNs, phone numbers, addresses, SSNs, or other identifiers and get their offsets and labels (not redact them), inspect what would be removed before de-identifying, route spans to a custom redactor, normalize labels to a canonical taxonomy, or filter by confidence and language. Covers extract_pii, the PIIEntity fields, CANONICAL_LABELS / normalize_label, and how it differs from deidentify. Pairs before reidentifying-text and deidentifying-clinical-text.
帮我安装这个 skill:https://raw.githubusercontent.com/maziyarpanahi/openmed/master/skills/extracting-pii-entities/SKILL.mdcurl -fsSL "https://raw.githubusercontent.com/maziyarpanahi/openmed/master/skills/extracting-pii-entities/SKILL.md"# Extracting PII Entities `openmed.extract_pii` finds PHI/PII spans and **returns them without changing the text**. Use it when you need to *see* the identifiers — to audit, route to a custom redactor, or decide a policy — rather than produce redacted output. It runs on-device. ## When to use - You want the **spans and labels** of identifiers, with the original text intact. - You need a **preview** of what `deidentify` would act on before committing. - You are feeding detected spans into a **downstream redactor** (your own, Presidio, or `deidentify`). - You want to **normalize** model labels to a stable canonical taxonomy. If you instead want redacted/masked output directly, use `deide