I handle this like all other issues, generate all possibilities. Then concept instantiation discriminates based on word meanings, selecting the most likely parse tree.
This will be CPU intensive though, since if a sentence had:
A’s B blah blah blah C’s D
I will need 4 permutations:
A is B, C is D
A is B, C’s D
A’s B, C is D
A’s B, C’s D
And of course in general, 2^n permutations.
Grrrr!... Why did they have to do this in English? Making the same punctuation mark do two different things !
My earlier example, of “The street was littered with paper, thrown from the windows”, in case your wondering, here is CLUES’ output…
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
]The street was littered with paper, thrown from the windows.
*Processing time: 1 seconds (for 11 word input, 39 parse trees generated in ./gis:).
pos = simple-sentence
subject.noun1.adjective1.val = the
subject.noun1.num-adjective = 1
subject.noun1.val = street
subject.num-noun = 1
predicate1.num-verb = 1
predicate1.verb1.auxiliary-verb1.val = was
predicate1.verb1.num-auxiliary-verb = 1
predicate1.verb1.num-prep-phrase = 1
predicate1.verb1.prep-phrase-list-type = space
predicate1.verb1.prep-phrase1.num-object = 1
predicate1.verb1.prep-phrase1.num-prep = 1
predicate1.verb1.prep-phrase1.object1.num-past-participle-phrase = 1
predicate1.verb1.prep-phrase1.object1.past-participle-phrase-list-type = single
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.comma-prefix = true
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.num-object = 1
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.num-past-participle-verbal = 1
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.num-prep = 1
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.object1.adjective1.val = the
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.object1.num-adjective = 1
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.object1.val = windows
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.past-participle-verbal1.val = thrown
predicate1.verb1.prep-phrase1.object1.past-participle-phrase1.prep1.val = from
predicate1.verb1.prep-phrase1.object1.val = paper
predicate1.verb1.prep-phrase1.prep1.val = with
predicate1.verb1.val = littered