human
Complete this python program:
def _unescape_token(escaped_token):
assistant
#Here is the Python program you requested.

    """Inverse of _escape_token().
    Args:
    escaped_token: a unicode string
    Returns:
    token: a unicode string
    """
    def match(m):
        if (m.group(1) is None):
            return (u'_' if (m.group(0) == u'\\u') else u'\\')
        try:
            return six.unichr(int(m.group(1)))
        except (ValueError, OverflowError) as _:
            return ''
    trimmed = (escaped_token[:(-1)] if escaped_token.endswith('_') else escaped_token)
    return _UNESCAPE_REGEX.sub(match, trimmed)