gradient + timeouts first implementation