nltk.sem.root_semrep

nltk.sem.root_semrep(syntree, semkey='SEM')[source]

Find the semantic representation at the root of a tree.

Parameters
  • syntree – a parse Tree

  • semkey – the feature label to use for the root semantics in the tree

Returns

the semantic representation at the root of a Tree

Return type

sem.Expression