Skip to main content

Module ontology

Module ontology 

Source
Expand description

Ontology module for bridging anaphora and sort compatibility checking.

This module provides:

  • Part-whole relationship lookup for bridging anaphora resolution
  • Predicate sort requirements for metaphor detection

Statics§

WORD_TABLES
Every word table this module generates, by name, with its sorted, duplicate-free keys.
WORD_TABLE_CONFLICTS
Every key a table was written with twice, answering differently: (table, key, kept, dropped) — the first answer is the one the table gives.

Functions§

check_sort_compatibility
Check if a predicate is compatible with a subject’s sort. Returns true if compatible or no sort requirement exists.
find_bridging_wholes
Find possible whole objects for a given part noun. Returns None if the noun is not a known part of any whole.
get_possible_wholes
Get possible whole objects for a given part noun.
get_predicate_sort
Get the required sort for a predicate (adjective or verb).
required_sort
Get the required sort for a predicate, if any.