nltk.DiscourseTester.expand_threads

DiscourseTester.expand_threads(thread_id, threads=None)[source]

Given a thread ID, find the list of logic.Expression objects corresponding to the reading IDs in that thread.

Parameters:
  • thread_id (str) – thread ID
  • threads (dict) – a mapping from thread IDs to lists of reading IDs
Returns:

A list of pairs (rid, reading) where reading is the logic.Expression associated with a reading ID

Return type:

list of tuple