PiiEntity Class

PiiEntity contains information about a Personally Identifiable Information (PII) entity found in text.

Inheritance
azure.ai.textanalytics._dict_mixin.DictMixin
PiiEntity

Constructor

PiiEntity(**kwargs: Any)

Methods

get
has_key
items
keys
update
values

get

get(key: str, default: Any | None = None) -> Any

Parameters

Name Description
key
Required
default
default value: None

has_key

has_key(k: str) -> bool

Parameters

Name Description
k
Required

items

items() -> Iterable[Tuple[str, Any]]

keys

keys() -> Iterable[str]

update

update(*args: Any, **kwargs: Any) -> None

values

values() -> Iterable[Any]

Attributes

category

Entity category, such as Financial Account Identification/Social Security Number/Phone Number, etc.

category: str

confidence_score

Confidence score between 0 and 1 of the extracted entity.

confidence_score: float

length

The PII entity text length. This value depends on the value of the string_index_type parameter specified in the original request, which is UnicodeCodePoints by default.

length: int

offset

The PII entity text offset from the start of the document. This value depends on the value of the string_index_type parameter specified in the original request, which is UnicodeCodePoints by default.

offset: int

subcategory

Entity subcategory, such as Credit Card/EU Phone number/ABA Routing Numbers, etc.

subcategory: str | None = None

text

Entity text as appears in the request.

text: str