The way modern machine learning and artificial intelligence are often practised today shows an uncanny resemblance to alchemy.