from typing import List


def split_train_in_sentences(lines: List[str]) -> List[List[str]]:
    """
    Receives the data in the expected format (one token per line, empty line to separate sentences) and returns a list of sentences (lists of lines)
    :param lines:
    :return:
    """
    sentences = []
    current_sentence = []
    for line in lines:
        if line.strip() == '' and len(current_sentence) > 0:
            sentences.append(current_sentence)
            current_sentence = []
        elif len(line.strip()) > 0:
            current_sentence.append(line)
    # last sentence in case the file ends with no empty line
    if len(current_sentence) > 0:
        sentences.append(current_sentence)
    return sentences