def chunks(sentences, number_of_sentences):
    """
    Split a list into N sized chunks.
    """
    number_of_sentences = max(1, number_of_sentences)
    return [sentences[i:i+number_of_sentences]
            for i in range(0, len(sentences), number_of_sentences)]