def default_collate(batch):
    """
        Default collate function, used for ParlAIDataset and StreamDataset
    """
    new_batch = []
    for b in batch:
        idx = b[0]
        if type(b[1]) is list:
            ep = b[1][0]
        else:
            ep = b[1]
        new_batch.append((idx, ep))
    return new_batch