def is_condition_key_match(document_key, some_str):
    """ Given a documented condition key and one from a policy, determine if they match
    Examples:
    - s3:prefix and s3:prefix obviously match
    - s3:ExistingObjectTag/<key> and s3:ExistingObjectTag/backup match
    """
    document_key = document_key.lower()
    some_str = some_str.lower()
    if '$' in document_key:
        if some_str.startswith(document_key.split('$')[0]):
            return True
    elif '<' in document_key:
        if some_str.startswith(document_key.split('<')[0]):
            return True
    elif 'tag-key' in document_key:
        if some_str.startswith(document_key.split('tag-key')[0]):
            return True
    return document_key == some_str
