Self-learning neuromorphic chip that composes music