litellm-mirror/docs/my-website/docs/embedding/async_embedding.md
2024-08-22 19:04:14 -07:00

15 lines
No EOL
390 B
Markdown

# litellm.aembedding()
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)
```