def tokenize(s, keep_punctuation=(), drop_punctuation=(), delimiter=' ',
             add_start=True, add_end=True):
    """Tokenizes a sentence

    Args:
        s (str): the sentence
        keep_punctuation (tuple): contains the punctuation to keep
        drop_punctuation (tuple): contains the punctuation to drop
        delimiter (str): the delimiter between tokens
        add_start (bool): whether to add a <START> token
        add_end (bool): whether to add a <END> token

    Returns:
        list: A list of tokens.
    """
    for kp in keep_punctuation:
        s = s.replace(kp, '{0}{1}{0}'.format(delimiter, kp))
    for rp in drop_punctuation:
        s = s.replace(rp, '')
    tokens = s.lower().split(delimiter)
    tokens = [t.strip() for t in tokens if len(t.split()) > 0]
    if add_start:
        tokens.insert(0, '<START>')
    if add_start:
        tokens.append('<END>')

    return tokens