Documentation
¶
Overview ¶
Package entity provides a detector-agnostic canonical representation of PII entities for use by the semantic enricher and placeholder renderer. This abstraction allows the enrichment pipeline to work with either the current custom detector or a future Presidio adapter.
Index ¶
Constants ¶
View Source
const ( SourceCustom = "custom" SourcePresidio = "presidio" )
Source identifies the detector that produced the entity.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CanonicalEntity ¶
type CanonicalEntity struct {
Id int `json:"id"`
Type string `json:"type"`
Raw string `json:"raw"`
Start int `json:"start"`
End int `json:"end"`
Source string `json:"source"`
Confidence float64 `json:"confidence"`
Sensitivity int `json:"sensitivity"` // 1-3 from recognizer; used for overlap resolution
Attributes map[string]string `json:"attributes,omitempty"`
}
CanonicalEntity is a detector-agnostic PII entity used by the enrichment pipeline and renderer. Attributes are filled by the semantic enricher and governed by Rego policy before rendering.
Click to show internal directories.
Click to hide internal directories.