Commit graph

2221 commits

Author SHA1 Message Date
Nilanjan De
ecfae6d465 update factory.py 2024-04-18 22:31:08 +04:00
Nilanjan De
e1fd463f8c update factory.py 2024-04-18 22:27:11 +04:00
alisalim17
a3f90ab735 fix: add missing tool_calls and function name to messages in mistral_api_pt 2024-04-18 20:49:01 +04:00
Nilanjan De
c85018c780 update factory.py 2024-04-18 18:13:20 +04:00
Nilanjan De
4c7d94b2b4 update factory.py 2024-04-18 17:35:52 +04:00
Nilanjan De
7ca213e92f update factory.py 2024-04-18 15:12:31 +04:00
Nilanjan De
f1f2204c2a fix tool call errors using anthropic 2024-04-18 15:04:54 +04:00
alisalim17
5060d8d64f fix: newline issue in cohere_message_pt 2024-04-18 11:10:31 +04:00
Krrish Dholakia
c47b39c032 fix(vertex_ai.py): fix faulty async completion function call tool check 2024-04-17 16:30:28 -07:00
Krrish Dholakia
32d94feddd refactor(utils.py): make it clearer how vertex ai params are handled '
'
2024-04-17 16:20:56 -07:00
Krrish Dholakia
060ac995d6 fix(vertex_ai.py): accept credentials as a json string 2024-04-16 17:34:25 -07:00
Krish Dholakia
2837b6b2f3
Merge pull request #3019 from ligaz/fix-anthropic-system-msg-handling
Fix Anthropic system message handling
2024-04-16 07:18:47 -07:00
Ishaan Jaff
abf365b3ac
Merge pull request #3054 from BerriAI/litellm_supports_vision
[Feat] view models that `supports_vision`
2024-04-15 18:31:32 -07:00
Ishaan Jaff
462da5a778 fix - support base 64 image conversion for all gemini model 2024-04-15 18:18:55 -07:00
frob
2492fade3a
Update comment. 2024-04-16 01:12:24 +02:00
frob
dd623d92c4
Merge branch 'BerriAI:main' into ollama-image-handling 2024-04-16 01:06:04 +02:00
Krrish Dholakia
1ec7118e1f fix(vertex_ai_anthropic.py): set vertex_credentials for vertex ai anthropic calls
allows setting vertex credentials as a json string for vertex ai anthropic calls
2024-04-15 14:16:28 -07:00
Krrish Dholakia
50081479f9 fix(main.py): accept vertex service account credentials as json string
allows us to dynamically set vertex ai credentials
2024-04-15 13:28:59 -07:00
Krrish Dholakia
dce1f5466f fix(anthropic_text.py): return process_response value 2024-04-15 08:51:26 -07:00
Krrish Dholakia
26286a54b8 fix(anthropic_text.py): add support for async text completion calls 2024-04-15 08:15:00 -07:00
Stefan Dobrev
1cfea955aa
Fix Anthropic system message handling 2024-04-14 16:23:59 +03:00
frob
ea117fc859
Merge branch 'BerriAI:main' into ollama-image-handling 2024-04-13 21:42:58 +02:00
Krrish Dholakia
7a3821e0f6 fix(gemini.py): log system prompt in verbose output 2024-04-11 23:15:58 -07:00
Krrish Dholakia
77d6b882b8 fix(vertex_ai.py): check if 'response_mime_type' in generation config before passing it in 2024-04-11 23:10:59 -07:00
David Manouchehri
05350037be
(feat) - Extreme dirty hack for response_mime_type in Vertex AI. 2024-04-12 00:03:31 +00:00
David Manouchehri
d08674bf2f
(feat) - Dirty hack to get response_mime_type working before it's released in the Python SDK. 2024-04-12 00:03:30 +00:00
David Manouchehri
649c3bb0dd
(feat) - Add support for JSON mode in Vertex AI 2024-04-12 00:03:29 +00:00
Ishaan Jaff
79451242c8
Merge pull request #2892 from gregnwosu/patch-1
created defaults for response["eval_count"]
2024-04-11 13:40:32 -07:00
Ishaan Jaff
fb657423ee fix - stop using imghdr 2024-04-11 09:32:42 -07:00
Ishaan Jaff
b3f62b7ce3 fix cleanup 2024-04-10 21:28:04 -07:00
Ishaan Jaff
6a5d5bcd47 fix use ImmutableSandboxedEnvironment 2024-04-10 21:26:50 -07:00
Ishaan Jaff
f9cabf09ff fix jinja2 use ImmutableSandboxedEnvironment 2024-04-10 20:30:13 -07:00
Ishaan Jaff
05e02f829c fix - security report / vuln 2024-04-10 15:42:17 -07:00
Krrish Dholakia
47997c3f04 fix(replicate.py): handle empty response - replicate 2024-04-09 21:57:25 -07:00
Krrish Dholakia
67b1ad622f feat(gemini.py): support google-genai system instruction 2024-04-09 17:23:14 -07:00
frob
82a4232dce
ollama also accepts PNG 2024-04-08 03:35:02 +02:00
frob
59ed4fb51e
Update ollama.py for image handling
ollama wants plain base64 jpeg images, and some clients send dataURI and/or webp.  Remove prefixes and convert all non-jpeg images to jpeg.
2024-04-08 03:28:24 +02:00
Gregory Nwosu
559a4cde23
created defaults for response["eval_count"]
there is no way in litellm to disable the cache in ollama that is removing the eval_count response keys from the json.
This PR allows the code to create sensible defaults for when the response is empty
see 
- https://github.com/ollama/ollama/issues/1573
- https://github.com/ollama/ollama/issues/2023
2024-04-08 02:03:54 +01:00
frob
d5c1ae1cb2
Update ollama.py for image handling
Some clients (eg librechat) send images in datauri format, not plain base64.  Strip off the prerix when passing images to ollama.
2024-04-07 13:05:39 +02:00
Ishaan Jaff
9be250c0f0 add exit and aenter 2024-04-06 19:27:26 -07:00
Ishaan Jaff
a38d3b17c5 ci/cd run async handler 2024-04-06 19:16:27 -07:00
Ishaan Jaff
fcf5aa278b fix - use anthropic class for clients 2024-04-06 18:19:28 -07:00
Ishaan Jaff
2cf41d3d9f async ahtropic streaming 2024-04-06 17:54:19 -07:00
Ishaan Jaff
5c796b4365 async streaming anthropic 2024-04-06 17:53:06 -07:00
Ishaan Jaff
58c4b02447 feat - make anthropic async 2024-04-06 15:50:13 -07:00
Krish Dholakia
7495222a8b
Merge pull request #2855 from Caixiaopig/fix_update_default_claude3_maxtokens
Updating the default Anthropic Officlal Claude 3 max_tokens to 4096
2024-04-06 08:39:55 -07:00
Ishaan Jaff
37ef5c0cbf fix - test using specific commit 2024-04-05 16:10:54 -07:00
Krish Dholakia
a50edef1e6
Merge pull request #2856 from lazyhope/anthropic-tools-use-2024-04-04
Support latest Anthropic Tools Use (2024-04-04)
2024-04-05 14:31:26 -07:00
Krrish Dholakia
f662dac5c9 fix(vertex_ai_anthropic.py): fix import 2024-04-05 13:38:05 -07:00
Zihao Li
f16d0c06fd Add backward compatibility to support xml tool use for bedrock and vertex 2024-04-06 00:34:33 +08:00