def _crossproduct(template: CheckListTemplate):
    """
    Takes the output of editor.template and does the cross product of contexts and qas
    """
    ret = []
    ret_labels = []
    for instance in template.data:
        cs = instance["contexts"]
        qas = instance["qas"]
        d = list(itertools.product(cs, qas))
        ret.append([(x[0], x[1][0]) for x in d])
        ret_labels.append([x[1][1] for x in d])
    template.data = ret
    template.labels = ret_labels
    return template
Takes the output of editor.template and does the cross product of contexts and qas
allennlp/confidence_checks/task_checklists/question_answering_suite.py