def hinted_tuple_hook(obj):
    """
    This hook can be passed to json.load* as a object_hook. Assuming the incoming
    JSON string is from the MultiDimensionalArrayEncoder, tuples are marked
    and then reconstructed into tuples from dictionaries.

    Args:
        obj (object): Object to be parsed

    Returns:
        object: Object (if it's a tuple dictionary, returns a tuple)
    """
    if '__tuple__' in obj:
        return tuple(obj['items'])
    return obj