mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-25 10:44:24 +00:00
ollama exception mapping + new cookbook
This commit is contained in:
parent
0c895b76fe
commit
935d148423
2 changed files with 169 additions and 76 deletions
|
@ -2421,6 +2421,9 @@ def exception_type(
|
|||
llm_provider="vllm",
|
||||
model=model
|
||||
)
|
||||
elif custom_llm_provider == "ollama":
|
||||
if "no attribute 'async_get_ollama_response_stream" in error_str:
|
||||
raise ImportError("Import error - trying to use async for ollama. import async_generator failed. Try 'pip install async_generator'")
|
||||
raise original_exception
|
||||
except Exception as e:
|
||||
# LOGGING
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue