AI agent for autonomous long-running task completion