- As a first step, we may want to sort tracks by similarity. With Spotify API, each track has attributes that could be used to easily "map" the tracks mutual distances.
- Spotify already has an automix feature that works only on exclusive Spotify playlists [1]. And I think it is automated.
- There are (at least one) mobile apps that do this (not tested) : https://www.mixonset.com/
[1] https://community.spotify.com/t5/FAQs/What-is-Automix/ta-p/5...