You need to agree to share your contact information to access this dataset

This repository is publicly accessible, but you have to accept the conditions to access its files and content.

Log in or Sign Up to review the conditions and access this dataset content.

Meddies PII v2 Dataset

Meddies PII v2 model ONNX model Try the browser demo CC BY-NC 4.0

Character-level PII annotations for training and evaluating multilingual de-identification systems across 17 languages and nine entity families.

This is a research artifact for privacy and healthcare AI teams. It is not medical advice, not a redaction tool, and not a substitute for local validation before any clinical deployment, compliance workflow, or high-stakes privacy claim. If you want to use this dataset in commercial work, please contact us at contact@meddies.ai.

Meddies PII v2 provides exact character spans for nine PII entity families across 17 languages

Why this dataset

PII datasets often stop at names, addresses, and contact details. Clinical text also carries hospital identifiers, signed portal links, credentials, local date formats, and language-specific boundary cases. Those gaps become brittle rules or silent misses in a de-identification pipeline.

Meddies PII v2 keeps the source annotation simple. Each identifier is stored as an exact character span that remains readable across tokenizers. Training code derives BIOES tags later without changing the original text or boundaries.

What is inside

The repository has 17 language-specific training configs and three evaluation configs. Every config uses the physical split name train. The config name tells you whether the rows belong to training or evaluation.

Config group Purpose Rows
17 language configs Training and domain adaptation 317,846
eval Pinned checkpoint selection 1,700
eval-challenge Harder boundary and formatting cases 3,400
eval-v2 Fresh-form development evidence 850

eval-v2 contains 50 synthetic documents per language across referral letters, discharge summaries, invoices, lab reports, HL7 messages, and chat transcripts. It is published development evidence, so use a separate blinded corpus for headline claims.

The nine labels are address, company_name, date, email_address, human_name, id_number, phone_number, private_url, and secret.

A private_url is an access-bearing link such as a signed patient portal URL. A secret is a credential, token, password, or key.

Training distribution

Training-only distributions for language rows, document types, and entity spans in Meddies PII v2

This figure uses only the 317,846 rows in the 17 language-specific training configs. It excludes eval, eval-challenge, and eval-v2.

Three things matter when reading it.

  • Vietnamese and English are the largest language configs. The other 15 stay within a narrower range of roughly 15,000 to 20,500 rows.
  • The training set spans 45 document-type values. Pharmacy refill requests, discharge summaries, lab notifications, triage notes, and portal logs are the largest groups.
  • Secrets and ID numbers are intentionally common. The entity mix is shaped for model learning and does not estimate clinical prevalence.

Row format

Each row contains the source text, its character spans, and generation metadata.

{
  "text": "Patient Nguyễn Văn A called 0912 345 678",
  "label": [
    {
      "category": "human_name",
      "start": 8,
      "end": 20,
      "text": "Nguyễn Văn A"
    }
  ],
  "info": {
    "language": "Vietnamese",
    "document_type": "telehealth triage note",
    "split_purpose": "train"
  }
}

The recorded span must reproduce the source text exactly with text[start:end].

Where it fits

Character spans remain the source of truth between data generation and model-specific tokenization. Rows pass schema, boundary, and label checks before publication. Training code then derives tokenizer-specific BIOES tags.

Meddies PII v2 dataset pipeline from generation through span validation to training and evaluation configs

The release contains Meddies-generated data. External public corpora used by the model are rebuilt from their original sources and are not rehosted here.

Quick start

Load one config explicitly.

from datasets import load_dataset

training = load_dataset(
    "Meddies/meddies-pii-v2",
    "vietnamese",
    split="train",
    token=True,
)

row = training[0]
print(row["text"])
print(row["label"])

Load evaluation data by config name and keep it separate from training.

control = load_dataset(
    "Meddies/meddies-pii-v2",
    "eval",
    split="train",
    token=True,
)

Good fits

  • Training span-based PII detectors for multilingual clinical and general text.
  • Deriving tokenizer-specific BIOES labels while keeping character spans auditable.
  • Testing annotation tools, constrained decoders, and redaction interfaces.
  • Studying hard labels and boundary cases before collecting local evaluation data.

Limits

  • Machine-generated text does not behave exactly like real clinical records.
  • Language coverage does not equal hospital coverage. Local names, identifiers, templates, and optical character recognition errors will differ.
  • The training distribution is deliberately shaped for learning and is not a prevalence estimate.
  • The nine-label taxonomy is closed. Downstream teams must decide how to handle unsupported identifiers.
  • A held-out, human-reviewed evaluation from the intended deployment environment is still required.
  • CC BY-NC 4.0 does not permit commercial use without separate permission.

Feedback

Found an invalid offset, ambiguous label, duplicated pattern, or language-specific boundary problem? Include the config name and row ID when possible. Never post real patient data or credentials.

Open a thread in the Community tab or email contact@meddies.ai.

Collaboration

We are looking for hospitals, research groups, and privacy teams that can contribute safe failure patterns, independent audits, or language review. Email contact@meddies.ai to work with us.

Citation

@misc{meddies-pii-v2-dataset,
  title={Meddies PII v2 multilingual character-span annotations for PII detection},
  author={MeddiesAI},
  year={2026},
  url={https://huggingface.co/datasets/Meddies/meddies-pii-v2}
}
Downloads last month
173

Models trained or fine-tuned on Meddies/meddies-pii-v2

Collection including Meddies/meddies-pii-v2