-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs(gemini.md,-deploy.md): doc updates
- Loading branch information
1 parent
4ea3e77
commit c720870
Showing
5 changed files
with
1,003 additions
and
523 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Gemini - Google AI Studio | ||
|
||
## Pre-requisites | ||
* `pip install -q google-generativeai` | ||
|
||
## Sample Usage | ||
```python | ||
import litellm | ||
import os | ||
|
||
os.environ['GEMINI_API_KEY'] = "" | ||
response = completion( | ||
model="gemini/gemini-pro", | ||
messages=[{"role": "user", "content": "write code for saying hi from LiteLLM"}] | ||
) | ||
``` | ||
|
||
LiteLLM Supports the following image types passed in `url` | ||
- Images with direct links - https://storage.googleapis.com/github-repo/img/gemini/intro/landmark3.jpg | ||
- Image in local storage - ./localimage.jpeg | ||
|
||
|
||
|
||
## Chat Models | ||
| Model Name | Function Call | Required OS Variables | | ||
|------------------|--------------------------------------|-------------------------| | ||
| gemini-pro | `completion('gemini/gemini-pro', messages)` | `os.environ['PALM_API_KEY']` | | ||
| gemini-pro-vision | `completion('gemini/gemini-pro-vision', messages)` | `os.environ['PALM_API_KEY']` | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.