def truncate(text: str, maxlen: int = 1024) -> str:
    """Truncate a paragraph to a specific length.

    Args:
        text: The paragraph to truncate.
        maxlen: The maximum length of the paragraph.

    Returns:
        The truncated paragraph.
    """
    etc = "[…]"
    return f"{text[:maxlen - len(etc)]}{etc}" if len(text) > maxlen - len(etc) else text