Smart algorithm upgrde