Interface: DeidProfileSpec
The spec accepted by defineDeidProfile: a name, an optional base profile (default SAFE_HARBOR_PROFILE), per-category transform overrides, and an optional default redactor.
Example
import { type DeidProfileSpec, SAFE_HARBOR_CATEGORIES } from "@cosyte/deid";
const spec: DeidProfileSpec = {
name: "site-a",
transforms: { [SAFE_HARBOR_CATEGORIES.MRN]: "redact" }, // tighten MRN from pseudonymize to redact
};
Properties
base?
readonlyoptionalbase?:DeidProfile
The base profile to derive from. Defaults to SAFE_HARBOR_PROFILE.
description?
readonlyoptionaldescription?:string
An optional human description; a default is synthesized from the base when omitted.
name
readonlyname:string
The profile name. Must not be a reserved standard label unless it genuinely matches it.
redactor?
readonlyoptionalredactor?:FreeTextRedactor
An optional default free-text redactor the derived profile carries.
transforms?
readonlyoptionaltransforms?:Partial<Readonly<Record<SafeHarborCategory,TransformName>>>
Per-category transform overrides. Each may only move a category to an equal-or-stronger transform than the base (widen-never-narrow); a weakening override is rejected.