1---2name: pseudonymization-field-mapper3description: Vendor-neutral skill to generate a consistent pseudonymization field map and implementation plan for datasets.4---56## When to invoke7- You need to share or analyze datasets while reducing re-identification risk.8- You need a clear, reviewable mapping from original fields to pseudonymized outputs.9- You are preparing a de-identified extract for analytics, QA, or vendor handoff.1011## Inputs needed12- A JSON dataset schema describing fields (name, type, examples, sensitivity tags).13- Optional policy settings:14 - Whether mapping must be reversible (tokenization) or irreversible (hashing).15 - Join requirements (which identifiers must remain linkable across tables).16 - Environment (dev/test/prod) and key management constraints.1718## Workflow191. Parse schema and classify fields into categories: direct identifiers, quasi-identifiers, sensitive attributes, operational metadata.202. For each field, choose a transformation:21 - drop, redact, generalize, hash, tokenize, mask, shift, bucket.223. Ensure consistency constraints:23 - Stable linkage for join keys.24 - No derived direct identifiers (e.g., full name from first+last).25 - Date shifting coherence across related date fields.264. Emit a pseudonymization plan with:27 - Per-field mapping (input -> output name, transformation, parameters).28 - Keying strategy notes (salt/pepper guidance; tokenization vault requirement).29 - Residual risk notes and review checklist.3031## Output format32- JSON report containing:33 - `summary` with counts by category.34 - `field_map[]` list with transformation decisions.35 - `notes[]` for key management and joinability.3637## Guardrails38- Do not output real secrets, salts, keys, or reversible mapping tables.39- Treat free-text fields as high risk; default to drop/redact unless explicitly allowed.40- Prefer irreversible approaches unless reversibility is explicitly required.4142## Reference code43- `pseudonymization_field_mapper.py` reads a schema JSON and outputs a mapping plan JSON.