Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • dictionary (string, required) - The dictionary resource which holds the names and to be located in the text.
    • This is specified as "provider:name" in the standard resource format (INSERT LINK HERE).
  • requiredFlags (string array, optional) - Only process the tokens with the specified flags.
    • A JSON array of strings, such as ["TOKEN", "ALL_LOWER_CASE"]
  • skipFlags (string array, optional) - Flags to be skipped by this stage
    • Tokens marked with this flags will be ignore by this stage, and no process will be performed.


Code Block
languagejs
themeEclipse
titleExample Configuration
{
 "type":"DictionaryTagger",
 "dictionary":"dict-provider:people-lowercase",
 "requiredFlags":["TOKEN", "ALL_LOWER_CASE"],
 "skipFlags": ["SKIP"]
}

...

In the following example, "abraham lincoln" is in the dictionary as a person, "lincoln" as a place,  and "macaroni", "cheese" and "macaroni and cheese" are all specified as foods:

Code Block
languagetext
themeFadeToGrey
V--------------[abraham lincoln likes macaroni and cheese]--------------------V

...


^--[abraham]--V--[lincoln]--V--[likes]--V--[macaroni]--V--[and]--V--[cheese]--^

...


              ^---{place}---^           ^----{food}----^         ^---{food}---^

...


^----------{person}---------^           ^-----------------{food}--------------^



Output Flags

Lex-Item Flags:

...

Each JSON record represents an entity. The format is as follows:

Code Block
languagejs
themeEclipse
titleEntity JSON Format
{
  "id":"Q28260",
  "tags":["{city}", "{administrative-area}", "{geography}"],
  "patterns":[
    "Lincoln", "Lincoln, Nebraska", "Lincoln, NE"
  ],
  "confidence":0.95
  
  . . . additional fields as needed go here . . . 
}

...