Extract
Extract entities from text. Configure entities in the Extract Tab.
{{ extract }}
Returns
- JSON representation of the extracted entities.
Example Usage
Input:
My phone number is 555-555-5555=>{{ extract }}
Output: (You may see more entities than shown below - this is only an example)
{
"phone-number": [
"555-555-5555"
]
}
Extract Keywords
Extracts keywords from input text.
{{ keywords | nouns: true }}
Parameters
- Nouns: If true, return all nouns. If false, only return proper nouns.
Returns
The resulting keywords.
Example Usage 1
I have 20 cats and 40 dogs
{{ keywords|nouns:true }}
Will yield:
20 cats, 40 dogs
Example Usage 2
Howard has 20 cats and 40 dogs
{{ keywords|nouns:false }}
Will yield:
Howard
If the nouns: true
is used, the following below is returned:
Howard, 20 cats, 40 dogs
Extract Grammar
Extracts grammar from input text, grouping by type of word.
{{ grammar }}
Returns
- This sets environment variables from the text given, classifying words into buckets like dates, nouns, determiners, etc
Example Usage
Howard has 20 cats and 40 dogs.
He took them to the vet last week.
{{ grammar }}
Will yield in the environment (see the Inspector):
grammar.year: [2024]
grammar.context:
grammar.dates: ["last","week"]
grammar.propernouns: ["Howard"]
grammar.nouns: ["20 cats","40 dogs","vet","week"]
grammar.preps: ["He","them"]
grammar.determiners: []