$nlp.parseMorph
Executes a morphological analysis of Russian words.
Morphological analysis is performed using PyMorphy.
Syntax
- ECMAScript 5
- ECMAScript 6
$nlp.parseMorph("яблочки"); // => {"score":0.5,"normalForm":"яблочко","tags":["inan","neut","NOUN","plur","nomn"]}
In the ECMAScript 6 runtime, the method is asynchronous:
await $nlp.parseMorph("яблочки"); // => {"score":0.5,"normalForm":"яблочко","tags":["inan","neut","NOUN","plur","nomn"]}
How to use
Call example:
- ECMAScript 5
- ECMAScript 6
script:
$temp.res = $nlp.parseMorph("яблочки");
a: {{ $temp.res.normalForm }}
scriptEs6:
$temp.res = await $nlp.parseMorph("яблочки");
a: {{ $temp.res.normalForm }}
The bot’s response is яблочко
.