LUMIA-Group/rasat

Inadvertently removing question-question-generic relations?

tonyzhao6 opened this issue · 1 comments

if edge[2] in ["question-question-generic"]:

This line explicitly removes question-question-generic relations. Is there a reason why this is done?

Ok, I see that this is intended due to the following logic:

  1. If use_dependency is False, then we are using relations_ generated from preprocess_question. relations_ consists of question-question relationships.

  2. If use_dependency is True, then we are using tree_relations_ generated from preprocess_question. tree_relations_ consists of Forward-Syntax, Backward-Syntax, and None-Syntax relationships.

  3. If use_dependency is False, then the question-question-generic relations are first built in generate_relations_between_questions and thus, they don't need to be added to the relation matrix again.

  4. If use_dependency is True, then the question-question-generic relations that are built in generate_relations_between_questions have to be overwritten with tree_relations_ in the relation matrix.