Runtime interchange for adaptive re-use of intelligent cyber-physical system controllers