acompletion_with_retry#
- async langchain_community.chat_models.gpt_router.acompletion_with_retry(llm: GPTRouter, models_priority_list: List[GPTRouterModel], run_manager: AsyncCallbackManagerForLLMRun | None = None, **kwargs: Any) GenerationResponse | AsyncGenerator[ChunkedGenerationResponse, None] [source]#
Use tenacity to retry the async completion call.
- Parameters:
llm (GPTRouter) –
models_priority_list (List[GPTRouterModel]) –
run_manager (Optional[AsyncCallbackManagerForLLMRun]) –
kwargs (Any) –
- Return type:
Union[GenerationResponse, AsyncGenerator[ChunkedGenerationResponse, None]]