(docs) add async embeddings

This commit is contained in:
ishaan-jaff
2023-10-23 15:23:23 -07:00
parent 5516113f18
commit ea0c65d146
2 changed files with 20 additions and 1 deletions
@@ -0,0 +1,15 @@
# Async Embedding
LiteLLM provides an asynchronous version of the `embedding` function called `aembedding`
### Usage
```python
from litellm import aembedding
import asyncio
async def test_get_response():
response = await aembedding('text-embedding-ada-002', input=["good morning from litellm"])
return response
response = asyncio.run(test_get_response())
print(response)
```
+5 -1
View File
@@ -46,7 +46,11 @@ const sidebars = {
{
type: "category",
label: "Embedding() & Moderation()",
items: ["embedding/supported_embedding", "embedding/moderation"],
items: [
"embedding/supported_embedding",
"embedding/async_embedding",
"embedding/moderation",
],
},
{
type: "category",