def _is_short_sequence(sequence, threshold):
    """
    Return true if the provided sequence is shorter than the provided
    threshold.

    Parameters
    ----------
    sequence : Sequence object
        The sequence you wish to consider.
    threshold : int
        Minimum number of positions allowed in sequence.

    Returns
    -------
    True of False
        True if the sequence length is shorter than the provided threshold.
    """
    return len(sequence.ungapped()) < threshold
