from typing import List


def _format_results(results: list) -> List[dict]:
    """
    Args:
        results: a list of results with the following format:
        ['"<hash>","<anchor_hash>",<score>']

    Returns: a list of dictionaries containing the hash and score

    """
    formatted_res = []

    # Remove last empty value returned from the process
    if not results[-1]:
        results = results[:-1]

    for result in results:
        result = result.split(',')
        formatted_res.append({
            'hash': result[0].strip('"'),
            'similarityValue': int(result[2])
        })
    return formatted_res