You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
404 B
19 lines
404 B
from pydantic import BaseModel
|
|
from typing import Optional, List, Any
|
|
|
|
|
|
class VectorItem(BaseModel):
|
|
id: str
|
|
text: str
|
|
vector: List[float | int]
|
|
metadata: Any
|
|
|
|
|
|
class GetResult(BaseModel):
|
|
ids: Optional[List[List[str]]]
|
|
documents: Optional[List[List[str]]]
|
|
metadatas: Optional[List[List[Any]]]
|
|
|
|
|
|
class SearchResult(GetResult):
|
|
distances: Optional[List[List[float | int]]]
|
|
|