def overlap_ratios(a: set, b: set) -> float:
    """
    Calculates the Jacard distance between two sets.
    """
    overlap = a.intersection(b)
    union = a.union(b)
    return len(overlap) / (len(union) + 0.001)