mirror of
https://github.com/tiennm99/litellm.git
synced 2026-07-06 07:08:05 +00:00
(feat) cohere embedding
This commit is contained in:
@@ -41,4 +41,17 @@ for chunk in response:
|
||||
print(chunk)
|
||||
```
|
||||
|
||||
LiteLLM supports 'command', 'command-light', 'command-medium', 'command-medium-beta', 'command-xlarge-beta', 'command-nightly' models from [Cohere](https://cohere.com/).
|
||||
LiteLLM supports 'command', 'command-light', 'command-medium', 'command-medium-beta', 'command-xlarge-beta', 'command-nightly' models from [Cohere](https://cohere.com/).
|
||||
|
||||
## Embedding
|
||||
|
||||
```python
|
||||
from litellm import embedding
|
||||
os.environ["COHERE_API_KEY"] = "cohere key"
|
||||
|
||||
# cohere call
|
||||
response = embedding(
|
||||
model="embed-english-v3.0",
|
||||
input=["good morning from litellm", "this is another item"],
|
||||
)
|
||||
```
|
||||
Reference in New Issue
Block a user