# Eduction Grammar Reference

The following tables describe the grammar files that are available in the IDOL PII Package, and the entities that each provides.

Some grammars are available in two formats, ECR and EJR. For more information about which to use, see ECR and EJR Grammars.

In the entity names:

- the abbreviation CC refers to a two-letter country code. For a list of available country codes, see Country Codes.
- the abbreviation LLL refers to a three-letter language code. For a list of available languages, see Languages.

TIP: You can use the Eduction parameter `EntityN` to specify which entities you want to extract. This parameter accepts wildcards, so you can extract entities of a specific type for all supported countries or languages. For example, to match postal addresses for all countries specify a value of `pii/address/??`. To match dates of birth in all languages, specify `pii/date/dob/context/???`.

Some grammars have a CJVTK (Chinese, Japanese, Korean, Vietnamese, and Thai) version, for matching entities in Japanese. This grammar is separate for performance reasons. CJKVT languages do not have spaces in the text to separate words, so additional processing is required for sentence breaking.

The CJKVT grammars generally match Kanji and Romanized versions of the text where appropriate, as well as half-width and full-width characters (in the output, full-width forms are normalized to half-width).

NOTE: The IDOL PII Package is backwards-compatible with the IDOL GDPR package. You can continue to use existing configurations that use entity names such as `gdpr/address/CC` or `gdpr/telephone/CC`. These entities are similar to the corresponding `pii/*` entity, but are limited to countries in the GDPR region. However, Micro Focus recommends that you use the `pii/*` entities instead, so that Eduction extracts matches for all supported countries.

## address.ecr

Entity | Description
--- | ---
pii/address/CC | A postal address. In general, a score of one is given to an address that includes a numbered, common format street address (for example "23 North Road"), a known city (for example "London"), and a postal code in a viable format for the country (for example "SW1A 2AA"). Deviations from this form lead to score penalties. The ordering of these elements varies by country. Micro Focus recommends that you use pre-filtering to improve the performance for this grammar. See Configure Pre-Filtering. Example matches: "Schlosshoferstrasse 20, 1210 Vienna", "Avenida Juan Xxiii 20, 41006, Sevilla", "Abidei Hurriyet Cd Taner Palas Han 9 Kat:7 Dayre 9, 34437 Istanbul", "162-168 Regent Street, London, W1B 5TG". This entity returns the addresses in a normalized format by default. The normalized form standardizes apartment and house numbers, removes additional punctuation, and converts the text to uppercase. For example ABIDEI HURRIYET CD TANER PALAS APT 9, KAT:7, D:9, 34437 ISTANBUL. The exact order depends on the country. You can turn off normalization by setting `normalize_addresses=false` in the `address_stoplist.lua` script. This option can improve performance when you do not need normalization. This entity returns components. See Components.
pii/address/landmark/CC | A postal address landmark. For example "Address".
pii/address/streetlocation/context/CC | A street location (house number and street name), with context. For example "Address: 123, Mill Road".
pii/address/streetlocation/nocontext/CC | A street location (house number and street name), without context. For example "123, Mill Road".
pii/address/streetlocation/landmark/CC | A street location landmark. For example "Address"
pii/address/city/context/CC | A city or town, with context. For example "City: London".
pii/address/city/nocontext/CC | A city or town, without context. For example "London".
pii/address/city/landmark/CC | A city or town landmark. For example "City".
pii/address/postcode/context/CC | A postal code, with context. For example "Postcode: CB4 0WZ".
pii/address/postcode/nocontext/CC | A postal code, without context. For example "CB4 0WZ".
pii/address/postcode/landmark/CC | A postal code landmark. For example "Postcode".
pii/address/country/context/CC | A country, with context. For example "Country: United Kingdom".
pii/address/country/nocontext/CC | A country, without context. For example "United Kingdom".
pii/address/country/landmark/CC | A country landmark. For example "Country".

## address_cjkvt.ecr

Entity | Description
--- | ---
pii/address/CC | A postal address. In general, for Japan, a score of one is given to an address that includes a numbered, common format street address (for example "四丁目１番２-３４号"), a city or ward (for example 津島市), and a postal code in a viable format for the country (for example "１２３-４５６７"). For Taiwan, a score of one is given to an address that includes a numbered street address, a known township, district, city, or county, and a valid postal code. Deviations from these forms lead to score penalties. Micro Focus recommends that you use pre-filtering to improve the performance for this grammar. See Configure Pre-Filtering Example matches: "日本、〒１２３-４５６７神奈川県津島市城南区月形町八重洲四丁目１番２-３４号", "1-2-34, Yaesu 4-Chome, Nanae, Atsuta, Hekinan, Kagoshima, 123-4567, Japan", "１０６０３台北市大安區金山南路２段５５號", "No.55, Sec. 2, Jinshan S. Rd., Daan Dist., Taipei City 10603". This entity returns the addresses in a normalized format. The normalized form standardizes apartment and house numbers, removes additional punctuation, and for Romanized text, it converts the text to uppercase. CJKVT native script is not normalized to ASCII, and Romanized text is not normalized to CJKVT native script. You can turn off normalization by setting `normalize_addresses=false` in the `address_stoplist.lua` script. This option can improve performance when you do not need normalization. This entity returns components. See Components.
pii/address/landmark/CC | A postal address landmark. For example "住所".
pii/address/streetlocation/contextCC | An address first line, with context. For example "住所: 八重洲 四丁目１番２ -３４号" or "Address: No.55, Sec. 2, Jinshan S. Rd.".
pii/address/streetlocation/nocontext/cjkvt/CC | An address first line in CJKVT native script, without context. For example "八重洲四丁目１番２-３４号", or "金山南路２段５５號".
pii/address/streetlocation/nocontext/latin/CC | An address first line in romanized text, without context. For example "1-2-34, Yaesu 4-Chome", or "No.55, Sec. 2, Jinshan S. Rd.".
pii/address/streetlocation/nocontext/CC | An address first line in CJKVT native script or romanized text, without context. For example 八重洲四丁目１番２-３４号" or "1-2-34, Yaesu 4-Chome".
pii/address/streetlocation/landmark/CC | An address first line landmark. For example "住所", "住址", or "Address".
pii/address/settlement/context/CC | A settlement, with context. For example, in Japan a town or city, or in Taiwan a district (區 qū) or township (鎮 zhèn/鄉 xiāng). For example "市区町村: 津島市城南区月形町", "鄉鎮市區:板橋區", or "City/Ward/Town/Village: Nanae, Atsuta, Hekinan".
pii/address/settlement/nocontext/cjkvt/CC | A settlement in CJKVT native script, without context. For example "津島市城南区月形町", or "板橋區".
pii/address/settlement/nocontext/latin/CC | A settlement in romanized text, without context. For example "Nanae, Atsuta, Hekinan", or "Banqiao District".
pii/address/settlement/nocontext/CC | A settlement in CJKVT native script or romanized text, without context. For example "津島市城南区月形町", "板橋區", or "Nanae, Atsuta, Hekinan".
pii/address/settlement/landmark/CC | A settlement landmark. For example "市区町村", "鄉鎮市區", or "City/Ward/Town/Village".
pii/address/region/context/CC | A region, with context. For Taiwan, this is a county (縣 xiàn) or municipality (市 shì). For example "都道府県: 神奈川県", 縣市:宜蘭縣", or "Prefecture: Kagoshima".
pii/address/region/nocontext/cjkvt/CC | A region in CJKVT native script, without context. For example "神奈川県", or "宜蘭縣".
pii/address/region/nocontext/latin/CC | A region in romanized text, without context. For example "Kagoshima", or "Yilan County".
pii/address/region/nocontext/CC | A region in CJKVT native script or romanized text, without context. For example "神奈川県", "新北市", or "Kagoshima".
pii/address/region/landmark/CC | A region landmark. For example "都道府県", "縣市", or "Prefecture".
pii/address/postcode/context/CC | A postal code, with context. For example "郵便番号: １２３-４５６７", "Postcode: 1234567", or "郵遞區號106-409".
pii/address/postcode/nocontext/CC | A postal code, without context. For example "１２３-４５６７", or "106-409".
pii/address/postcode/landmark/CC | A postal code landmark. For example "郵便番号", "郵遞區號", or "Postcode".
pii/address/country/context/CC | A country, with context. For example "国: 日本", "国:中華民國", or "Country: Japan".
pii/address/country/nocontext/cjkvt/CC | A country in CJKVT native script, without context. For example "日本", or "中華民國".
pii/address/country/nocontext/latin/CC | A country in romanized text, without context. For example "Japan".
pii/address/country/nocontext/CC | A country in CJKVT native script or romanized text, without context. For example "日本" or "Japan".
pii/address/country/landmark/CC | A country landmark. For example "国" or "Country".

## date and date_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/date/dob/context/LLL | A date of birth, written numerically or using words. For example "date of birth 1/1/2018", "GEBOORTEDATUM: 01/01/2018"
pii/date/nocontext/LLL | A calendar date, written numerically or using words, without context. For example "01.03.1918", "2018_01_01", "вторник, 30 октомври 2018".
pii/date/dob/landmark/LLL | A date of birth landmark, such as "DOB" or "Fecha de nacimiento".

## device_id (ECR and EJR available)

Entity | Description
--- | ---
pii/device_id/ip/nocontext | An IP address, without context.
pii/device_id/imei/nocontext | An IMEI (International Mobile Equipment Identity), without context.
pii/device_id/imeisv/nocontext | An IMEISV (International Mobile Equipment Identity software version) , without context.
pii/device_id/mac_address/nocontext | A MAC address, without context.
pii/device_id/meid/nocontext | A MEID (Mobile Equipment Identifier), without context.
pii/device_id/iccid/nocontext | An ICCID (Integrated Circuit Card Identifier), without context.
pii/device_id/imsi/nocontext | An IMSI (International Mobile Subscriber Identity), without context.
pii/device_id/msisdn/nocontext | A MSISDN (Mobile Station International Subscriber Directory Number)

## driving and driving_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/driving/context/CC | A driving license number with context. For example: "australian automobile association: 103 805 501", or "driver's license: A234567890". This entity matches both the driving license number, and the personal number or driver number, if present. On the standard European driving license, these are fields 5 and 4d.
pii/driving/nocontext/CC | A driving license number, without context.
pii/driving/landmark/CC | A driving license landmark, such as "Driver's license" or "Driving Licence".

## health (ECR and EJR available)

Entity | Description
--- | ---
pii/health/ehic/context/CC | An EHIC personal identification number with context. For example "EHIC: UK 1234 5678 " or "TSE: 123456789012".
pii/health/ehic/nocontext/CC | An EHIC personal identification number without context. For example "123456-789A".
pii/health/ehic/landmark/CC | An EHIC landmark, such as "EHIC" or "EHIC PIN".
pii/health/ehic/context/all | An EHIC personal identification number with context, for EU countries and Switzerland.
pii/health/ehic/nocontext/all | An EHIC personal identification number without context, for EU countries and Switzerland.
pii/health/ehic/landmark/all | An EHIC landmark, such as "EHIC" or "EHIC PIN", for EU countries and Switzerland.
pii/health/id/context/au | An Australian Medicard (card) number or Individual Healthcare Identifier (IHI) with context. For example "Medicare Card Number: 3501 80315 1-6".
pii/health/id/context/br | A Brazilian Cartão Nacional de Saúde (CNS, also known as SUS) number with context, for example "CNS: 190129759240018".
pii/health/id/context/ca | A Canadian health insurance (card) number with context. For example "health insurance: 12345-6789", or "assurance-maladie: 12345-6789".
pii/health/id/context/ch | A Swiss health insurance card number with context. For example "Schweizerische Krankenversicherungskarte: 12345678901234567890".
pii/health/id/context/es | A Spanish health insurance card number with context. For example "CatSalut: ABCD 1 123456 12 1".
pii/health/id/context/fr | A French Carte Vitale number with context. For example "INSEE: 187090100100141".
pii/health/id/context/gb | A British NHS number with context. For example "NHS Number: 943 476 5919".
pii/health/id/context/nz | A New Zealand National Health Index (NHI) number with context. For example "NHI Number: CGC2720".
pii/health/id/context/us | A US health insurance number with context. For example "Medicare ID: 1EG4-TE5-MK72".
pii/heath/id/nocontext/CC | A health number, such as a British NHS number or French Carte Vitale number, without context.
pii/health/id/landmark/CC | A health number landmark, such as "NHS number" or "Medicare ID".

## health_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/health/id/context/CC | A heath number with context. For example "記号２１７０００２３". This entity gives a lower score to matches with more ambiguous landmarks (such as 番号 and "Number"). However, if two matches occur together (for example "記号 21700023 番号 21"), the entity can match both with a higher score.
pii/heath/id/nocontext/CC | A health number, such as a Japanese Health Insurance Card number, without context.
pii/health/id/landmark/CC | A health number landmark, such as "保険者番号" or "Insurer number".

## medical_terms.ecr

Entity | Description
--- | ---
pii/medical_terms/LLL | A medical condition or procedure. For example "abdominal hernia". This entity is available for all GDPR languages.

## mrtd (ECR and EJR available)

Entity | Description
--- | ---
pii/mrtd/mrp | A machine readable passport. For example "`P<GBRUK<SPECIMEN<<ANGELA<ZOE<<<<<<<<<<<<<<<< 5333244280GBR8812049F2509286<<<<<<<<<<<<<<00`"
pii/mrtd/mrotd/td1 | A machine readable TD1-size travel document. For example "`IDD<<T220001293<<<<<<<<<<<<<<< 6408125<2010315D<<<<<<<<<<<<<4 MUSTERMANN<<ERIKA<<<<<<<<<<<<<`"

## mrtd_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/mrtd/mrp_cjkvt | A CJKVT machine readable passport line. For example "`P<JPN<<<<<<<KEIKO<INOUE<<<<<<<<<<<<<<<<<<<<<`"
pii/mrtd/mrotd/td1_cjkvt | A CJKVT machine readable TD1-size travel document line. For example "`KEIKO<<INOUE<<<<<<<<<<<<<<<<<<`"

## name.ecr

Entity | Description
--- | ---
pii/name/CC | A full personal name, in title case or upper case. This entity returns the names in a normalized format, in the form `GIVEN NAME SURNAME`, for example JOHN SMITH. You can turn off normalization by setting `normalize_names=false` in the `name_stoplist.lua` script. You can also turn off score adjustment, by setting `rescore_names=false` in the `name_stoplist.lua` script. This option can improve performance when you do not need the normalization or score refinement.
pii/name/landmark/CC | A full name landmark. For example "name".
pii/name/given_name/context/CC | A given name, with context. For example "Forename: John".
pii/name/given_name/nocontext/CC | A given name, without context. For example "John".
pii/name/given_name/landmark/CC | A given name landmark. For example "Forename".
pii/name/surname/context/CC | A surname with context. For example "Surname: Smith".
pii/name/surname/nocontext/CC | A surname without context. For example "Smith".
pii/name/surname/landmark/CC | A surname landmark. For example "Surname".
pii/name/pre_title/CC | A title that precedes a name. For example "Ms".
pii/name/post_title/CC | A title that follows a name. For example "Esq".

## name_cjkvt.ecr

Entity | Description
--- | ---
pii/name/CC | A full personal name, in romanized text or CJKVT native script. Romanized names can be in title case or upper case, and can be in the order given name surname or surname given name. CJKVT native script names must be surname given name. For Japanese, either form can include honorifics. This entity returns the names in a normalized format, in the form `GIVEN NAME SURNAME`, for example KEIKO NAKAMURA. You can turn off normalization by setting `normalize_names=false` in the `name_stoplist.lua` script. You can also turn off score adjustment, by setting `rescore_names=false` in the `name_stoplist.lua` script. This option can improve performance when you do not need the normalization or score refinement.
pii/name/cjkvt/CC | A full personal name in CJKVT native script. For example "山田恵".
pii/name/latin/CC | A romanized full personal name. For example "Shinzo Abe".
pii/name/landmark/CC | A full name landmark. For example "名前".
pii/name/given_name/context/cjkvt/CC | A given name in CJKVT native script, with context. For example "名前: 直樹 ".
pii/name/given_name/nocontext/cjkvt/CC | A given name in CJKVT native script, without context. For example "直樹 ".
pii/name/given_name/context/latin/CC | A romanized given name, with context. For example "Given Name: Keiko".
pii/name/given_name/nocontext/latin/CC | A romanized given name, without context. For example "Keiko".
pii/name/given_name/context/CC | A given name in romanized text or CJKVT native script, with context. For example "名前: 直樹 ".
pii/name/given_name/nocontext/CC | A given name in romanized text or CJKVT native script, without context. For example "直樹 ".
pii/name/given_name/landmark/CC | A given name landmark in CJKVT native script. For example: "名前"
pii/name/surname/context/cjkvt/CC | A surname in CJKVT native script, with context. For example "名字: 山田".
pii/name/surname/nocontext/cjkvt/CC | A surname in CJKVT native script, without context. For example "山田".
pii/name/surname/context/latin/CC | A romanized surname, with context. For example "Surname: Nakamura".
pii/name/surname/nocontext/latin/CC | A romanized surname, without context. For example "Nakamura".
pii/name/surname/context/CC | A surname in romanized text or CJKVT native script, with context. For example "名字: 山田".
pii/name/surname/nocontext/CC | A surname in romanized text or CJKVT native script, without context. For example "山田".
pii/name/surname/landmark/jp | A surname landmark in CJKVT native script. For example "名字".
pii/name/pre_title/nocontext/CC | A title that precedes a name in romanized text. For example "Ms".
pii/name/post_title/nocontext/latin/jp | A title that follows a name in romanized text. For example "Esq".
pii/name/post_title/nocontext/cjkvt/jp | A title that follows a name in Japanese script. For example "さん".
pii/name/post_title/nocontext/jp | A title that follows a name in romanized text or Japanese script. For example "Esq" or "さん".

## national_id and national_id_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/id/context/CC | A national identity number with context. For information about the supported ID numbers, see Supported National ID Numbers. NOTE: By default, when there are multiple possible matches, post-processing returns only one country, which is the most efficient option. You can enable ambiguous entity matching by setting `ambiguous_tin_id_entities=true` in the `pii_postprocessing.lua` script. This option returns multiple possible country matches.
pii/id/nocontext/CC | A national identity number without context. For information about the supported ID numbers, see Supported National ID Numbers. NOTE: By default, when there are multiple possible matches, post-processing returns only one country, which is the most efficient option. You can enable ambiguous entity matching by setting `ambiguous_tin_id_entities=true` in the `pii_postprocessing.lua` script. This option returns multiple possible country matches.
pii/id/landmark/CC | A national identity number landmark, such as "National insurance number" or "Social security number".

## nationality and nationality_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/nationality/adj/context/CC | A nationality adjective with context. For example, "Nationality: British".
pii/nationality/adj/nocontext/CC | A nationality adjective without context. For example, "British".
pii/nationality/adj/landmark/CC | A nationality adjective landmark. For example, "Nationality".
pii/nationality/noun/context/CC | A nationality noun with context. For example, "Country: Britain".
pii/nationality/noun/nocontext/CC | A nationality noun without context. For example: "Britain".
pii/nationality/noun/landmark/CC | A nationality noun landmark. For example, "Country".
pii/nationality/any/context/CC | Any combination of nationality adjective and noun landmark and value. For example, "Country: British", or "Nationality: British".
pii/nationality/any/nocontext/CC | Any nationality adjective or noun. For example, "Britain" or "British".
pii/nationality/any/landmark/CC | Any nationality adjective or landmark. For example, "Nationality" or "Country".

## passport and passport_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/passport/context/CC | A passport number with context. For example "Passport number: 533324428", "Passport Number: P4366918", or "italian passaporti AA5275702".
pii/passport/nocontext/CC | A passport number without context. For example "533324428", "C015918", or "14CV28142".
pii/passport/landmark/CC | A passport landmark, such as "Passport" or "Pasaporte". For information about cases where the landmark and passport number do not match or have an ambiguous match, see Ambiguous Entities.

## postcode and postcode_cjkvt

Entity | Description
--- | ---
pii/postcode/context/CC | A postal code with context. For example "PLZ: 1210", "Poštanski broj: 10000", or "Cod poştal: 235200".
pii/postcode/nocontext/CC | A postal code without context. For example "2700-439 AMADORA", "75018", or "W1B 5TG".
pii/postcode/landmark/CC | A postal code landmark, such as "Postcode" or "Postleitzahl".

## telephone.ecr, telephone_cjkvt.ecr and telephone_cjkvt.ejr

Entity | Description
--- | ---
pii/telephone/context/CC | A telephone number with context. For example "Tel: +44 1234 224050", "Telephone: (204)-243-9955", or "numéro de téléphone: +1-902-861-7000". For the `telephone_cjkvt` grammar, numbers can be ASCII or full-width numbers. NOTE: To ensure that this entity performs correctly, set your `TangibleCharacters` configuration to include the following characters: `(` `)+-`. For more information, see Configure Tangible Characters. This entity returns the telephone number in the normalized format `+NNNNN`, starting with the country code. For example +12042439955.
pii/telephone/nocontext/CC | A telephone number without context. For example: "(204)-243-9955", "+39 055 326 43 11", or "44 20 7499 9000". For the `telephone_cjkvt` grammar, numbers can be ASCII or full-width numbers. NOTE: To ensure that this entity performs correctly, set your `TangibleCharacters` configuration to include the following characters: `()+-`. For more information, see Configure Tangible Characters. This entity returns the telephone number in the normalized format `+NNNNN`, starting with the country code. For example +12042439955.
pii/telephone/landmark/CC | A telephone number landmark, such as "Tel:" or "Telefon No". For the `telephone_cjkvt` grammar, landmarks are available only in CJKVT native script.

## tin and tin_cjkvt (ECR and EJR available)

Entity | Description
--- | ---
pii/tin/context/CC | A tax identification number with context. For example "ITIN: 911-92-3333", or "TIN-numre: 101111113". For more examples, see Example Tax Identification Numbers. NOTE: By default, when there are multiple possible matches, post-processing returns only one country, which is the most efficient option. You can enable ambiguous entity matching by setting `ambiguous_tin_id_entities=true` in the `pii_postprocessing.lua` script. This option returns multiple possible country matches.
pii/tin/nocontext/CC | A tax identification number without context. For example "756.3047.5009.62", or "Z1234567R". For more examples, see Example Tax Identification Numbers. NOTE: By default, when there are multiple possible matches, post-processing returns only one country, which is the most efficient option. You can enable ambiguous entity matching by setting `ambiguous_tin_id_entities=true` in the `pii_postprocessing.lua` script. This option returns multiple possible country matches.
pii/tin/landmark/CC | A tax identification number landmark, such as "ITIN" or "TIN-numre".

## travel (ECR and EJR available)

Entity | Description
--- | ---
pii/travel/context/us | A US passport card number with context. For example "Passport card number: C12345678".
pii/travel/nocontext/us | A US passport card number without context. For example "C12345678".
pii/travel/landmark/us | A US passport card number landmark. For example "Passport card number".

_FT_HTML5_bannerTitle.htm