diff --git a/api_update_plan.md b/api_update_plan.md index dd9017cb8..91ad92bca 100644 --- a/api_update_plan.md +++ b/api_update_plan.md @@ -226,7 +226,7 @@ Before finalizing documentation, verify: [x] 5. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/tools/tools.py` - Tool system APIs [x] 6. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/tools/rag_tool.py` - RAG tool runtime [x] 7. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/vector_io/vector_io.py` - Vector database operations -8. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/vector_dbs/vector_dbs.py` - Vector database management +[x] 8. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/vector_dbs/vector_dbs.py` - Vector database management 9. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/files/files.py` - File management 10. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/datasets/datasets.py` - Dataset management 11. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/datasetio/datasetio.py` - Dataset I/O operations diff --git a/docs/_static/llama-stack-spec.html b/docs/_static/llama-stack-spec.html index f11c9f59c..67c9a695e 100644 --- a/docs/_static/llama-stack-spec.html +++ b/docs/_static/llama-stack-spec.html @@ -11387,15 +11387,17 @@ "tool", "tool_group" ], - "title": "ResourceType", "const": "vector_db", - "default": "vector_db" + "default": "vector_db", + "description": "Type of resource, always 'vector_db' for vector databases" }, "embedding_model": { - "type": "string" + "type": "string", + "description": "Name of the embedding model to use for vector generation" }, "embedding_dimension": { - "type": "integer" + "type": "integer", + "description": "Dimension of the embedding vectors" } }, "additionalProperties": false, @@ -11406,7 +11408,8 @@ "embedding_model", "embedding_dimension" ], - "title": "VectorDB" + "title": "VectorDB", + "description": "Vector database resource for storing and querying vector embeddings." }, "HealthInfo": { "type": "object", @@ -12306,14 +12309,16 @@ "type": "array", "items": { "$ref": "#/components/schemas/VectorDB" - } + }, + "description": "List of vector databases" } }, "additionalProperties": false, "required": [ "data" ], - "title": "ListVectorDBsResponse" + "title": "ListVectorDBsResponse", + "description": "Response from listing vector databases." }, "Event": { "oneOf": [ diff --git a/docs/_static/llama-stack-spec.yaml b/docs/_static/llama-stack-spec.yaml index 2822342e9..7fd65d1fd 100644 --- a/docs/_static/llama-stack-spec.yaml +++ b/docs/_static/llama-stack-spec.yaml @@ -8151,13 +8151,17 @@ components: - benchmark - tool - tool_group - title: ResourceType const: vector_db default: vector_db + description: >- + Type of resource, always 'vector_db' for vector databases embedding_model: type: string + description: >- + Name of the embedding model to use for vector generation embedding_dimension: type: integer + description: Dimension of the embedding vectors additionalProperties: false required: - identifier @@ -8166,6 +8170,8 @@ components: - embedding_model - embedding_dimension title: VectorDB + description: >- + Vector database resource for storing and querying vector embeddings. HealthInfo: type: object properties: @@ -8817,10 +8823,12 @@ components: type: array items: $ref: '#/components/schemas/VectorDB' + description: List of vector databases additionalProperties: false required: - data title: ListVectorDBsResponse + description: Response from listing vector databases. Event: oneOf: - $ref: '#/components/schemas/UnstructuredLogEvent' diff --git a/llama_stack/apis/vector_dbs/vector_dbs.py b/llama_stack/apis/vector_dbs/vector_dbs.py index 405852476..db518b249 100644 --- a/llama_stack/apis/vector_dbs/vector_dbs.py +++ b/llama_stack/apis/vector_dbs/vector_dbs.py @@ -15,6 +15,12 @@ from llama_stack.schema_utils import json_schema_type, webmethod @json_schema_type class VectorDB(Resource): + """Vector database resource for storing and querying vector embeddings. + + :param type: Type of resource, always 'vector_db' for vector databases + :param embedding_model: Name of the embedding model to use for vector generation + :param embedding_dimension: Dimension of the embedding vectors + """ type: Literal[ResourceType.vector_db] = ResourceType.vector_db embedding_model: str @@ -30,6 +36,13 @@ class VectorDB(Resource): class VectorDBInput(BaseModel): + """Input parameters for creating or configuring a vector database. + + :param vector_db_id: Unique identifier for the vector database + :param embedding_model: Name of the embedding model to use for vector generation + :param embedding_dimension: Dimension of the embedding vectors + :param provider_vector_db_id: (Optional) Provider-specific identifier for the vector database + """ vector_db_id: str embedding_model: str embedding_dimension: int @@ -37,6 +50,10 @@ class VectorDBInput(BaseModel): class ListVectorDBsResponse(BaseModel): + """Response from listing vector databases. + + :param data: List of vector databases + """ data: list[VectorDB]