MCPcopy Index your code
hub / github.com/clips/pattern / related

Method related

pattern/text/tree.py:358–362  ·  view source on GitHub ↗

Yields a list of all chunks in the sentence with the same relation id.

(self)

Source from the content-addressed store, hash-verified

356 return ch
357 @property
358 def related(self):
359 """ Yields a list of all chunks in the sentence with the same relation id.
360 """
361 return [ch for ch in self.sentence.chunks
362 if ch != self and intersects(unzip(0, ch.relations), unzip(0, self.relations))]
363
364 @property
365 def prepositional_phrase(self):

Callers

nothing calls this directly

Calls 2

intersectsFunction · 0.85
unzipFunction · 0.85

Tested by

no test coverage detected