Add compute-distances command