Files
letta-server/letta/schemas/openai/embedding_response.py
Shubham Naik 5a743d1dc4 Add 'apps/core/' from commit 'ea2a7395f4023f5b9fab03e6273db3b64a1181d5'
git-subtree-dir: apps/core
git-subtree-mainline: a8963e11e7a5a0059acbc849ce768e1eee80df61
git-subtree-split: ea2a7395f4023f5b9fab03e6273db3b64a1181d5
2024-12-22 20:31:22 -08:00

12 lines
357 B
Python

from typing import List, Literal
from pydantic import BaseModel
class EmbeddingResponse(BaseModel):
"""OpenAI embedding response model: https://platform.openai.com/docs/api-reference/embeddings/object"""
index: int # the index of the embedding in the list of embeddings
embedding: List[float]
object: Literal["embedding"] = "embedding"