import re


def expand_sgml(text: str) -> str:
    """Replaces &#...; SGML entities to their Unicode character equivalents.

    :param text: HTML to transform
    :return: transformed text
    """
    return re.sub(r"&#(\d+);", lambda m: chr(int(m.group(1))), text)