servers.get_router
servers.get_router(vector_stores, endpoint_names)
Create and return a FastAPI.APIRouter with search endpoints.
Parameters
| vector_stores |
list[VectorStore] |
A list of VectorStore objects, each responsible for handling embedding and search operations for a specific endpoint. |
required |
| endpoint_names |
list[str] |
A list of endpoint names corresponding to the vector stores. |
required |
Returns
|
APIRouter |
Router with intialized search endpoints |
Raises
|
DataValidationError |
Raised if the input parameters are invalid. |
|
ConfigurationError |
Raised if one or more of the vector_stores are invalid. |