You are viewing an old version of this page. View the current version.
Compare with Current
View Page History
« Previous
Version 15
Next »
Analyzes the case of every token (adds additional flags) and optionally adds a lower-case normalized token to the interpretation graph.
Operates On: Lexical Items with TOKEN flag
Configuration Parameters
- normalize (boolean, optional) - If true, all tokens are normalized to all lower case. (default = true)
- 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.
- requireFlags (string array, optional)
- Tokens need to have all the specified flags, in order to be processed
- debug (boolean, optional)
- Enable all debug log functionality of the stage, if any.
{
"type":"CaseAnalysis",
"normalize":false
}
Output Flags
Note that flags are placed on every token as appropriate to the current token:
- If the token is "President" then that token will have the TITLE_CASE flag.
- If a new lower-case normalized interpretation, "president" is added as an alternative, this alternative will have the "ALL_LOWER_CASE" flag.
Lex-Item Flags:
- ALL_LOWER_CASE - All of the characters in the token are lower-case characters.
- ALL_UPPER_CASE - All of the characters in the token are upper-case characters (for example, acronyms).
- TITLE_CASE - The first character is upper case, all of the other characters are lower case.
- MIXED_CASE - Handles any mixed upper & lower case scenario not covered above.
Vertex Flags:
Example
With Defaults
V--[Sentence]--V--[with]--V--[UPPER]--V--[and]--V--[LoWer]--V--[Words!]--V
^--[sentence]--^ ^--[upper]--^ ^--[lower]--^--[words!]--^