Consider overlaps between k-mers extracted from three genomes - two that share sequence, and one that does not.
From these we can calculate k-mer based similarity measures (Jaccard similarity and containment).
This is implemented in the software sourmash.
Credits: Dr. Tessa Pierce-Ward et al; more info.
FracMinHash and sourmash - Lightweight compositional analysis of metagenomes with FracMinHash and minimum metagenome covers, Irber et al. 2022
ANI calculations - Debiasing FracMinHash and deriving confidence intervals for mutation rates across a wide range of evolutionary distances, Hera et al., Hera et al., 2022