OKR icon indicating copy to clipboard operation
OKR copied to clipboard

prepositional phrase of nouns is not captured as predicates

Open kleinay opened this issue 7 years ago • 1 comments

According to OKR V1 spec, a prepositional phrase that modifies a noun should be considered as (explicit) proposition, where the preposition is the predicate. E.g., for "A mail from John lies on the desk.", we should have a proposition: P1: [A1] from [A2] which in turn is the argument of the main verb: P2: [P1] lies on [A3].

In the props_wrapper code we can see lines that should deal with these cases (lines 274-300), but in the test, the behaviour is different. For example;

{'Entities': {'A1': ('mail', (1,)), 'A2': ('desk', (7,)), 'A3': ('John', (3,))}, 'Predicates': {'P1': {'Arguments': ['A1', 'A2'], 'Bare predicate': ('lies on', (4, 5)), 'Head': {'Lemma': u'lie', 'POS': 'VBZ', 'Surface': ('lies', [4])}, 'Template': '{A1} lies on {A2}'}, 'P2': {'Arguments': ('A1', 'A3'), 'Bare predicate': ('IMPLICIT', (-1,)), 'Head': {'Lemma': 'IMPLICIT', 'POS': 'IMPLICIT', 'Surface': 'IMPLICIT'}, 'Template': '{A1} {A3}'}}, 'Sentence': 'a mail from John lies on the desk .'}

kleinay avatar Dec 20 '17 09:12 kleinay

@OriShapira , take a look.

kleinay avatar Dec 20 '17 09:12 kleinay