Checkout the retry_policy reference to add retries to your AI function.