Appearance
Entity Types
The following entity types are detected by the PII and NER models.
PII Entities
| Name | Description | Example |
|---|---|---|
PERSON_NAME | People's names (first, last, full) | John Doe, Sarah J. Parker |
NATIONAL_ID | National IDs: SSN, driver's license, passport numbers | 123-45-6789 |
EMAIL_ADDRESS | Email addresses | john@example.com |
PHONE_NUMBER | Phone numbers (landline, mobile, international) | +1-555-1234 |
ADDRESS | Street addresses, cities, states, ZIP codes | 123 Main St, New York, NY 10001 |
DATE | Dates (absolute and relative) | 2024-01-15 |
CREDIT_CARD | Credit/debit card numbers (PAN) | 4111-1111-1111-1111 |
IBAN | International Bank Account Numbers | GB82 WEST 1234 5698 7654 32 |
VAT_NUMBER | Tax registration IDs (VAT, GST, EIN, ITIN) | GB123456789 |
USERNAME | Usernames and account identifiers | johndoe |
ZIP_CODE | US ZIP codes (5 or 9 digit) | 10001 |
LICENSE_KEY | Software license keys | XXXXX-XXXXX-XXXXX-XXXXX |
API_KEY | API keys for SaaS services | sk-abc..., qa_live_xxx |
NER Entities
| Name | Description | Example |
|---|---|---|
ORGANIZATION | Companies, agencies, institutions | Acme Corp, Stanford University |
LOCATION | Geographic locations, landmarks | Eiffel Tower, Grand Canyon |
GPE | Geo-political entities (countries, cities, states) | France, California, London |
How Detection Works
The PII recognizer (iiiorg/piiranha-v1-detect-personal-information) and the NER recognizer (elastic/distilbert-base-uncased-finetuned-conll03-english) run in parallel. Results are merged, deduplicated, and sorted by position in the original text.
Specifying Entities
By default, all entity types are detected. Use the entities parameter with a comma-separated string of entity names to filter:
json
{
"text": "My name is John Doe and my SSN is 123-45-6789.",
"entities": "PERSON_NAME,NATIONAL_ID"
}List available entities at runtime:
bash
curl https://demo.questa-ai.online/anonymize/entitiesNext: Custom Entities