You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fixes#31
Compute vector store usage bytes in `create_vector_store` and `create_vector_store_file` functions.
* **`impl/routes_v2/vector_stores.py`**:
- Import `os` and `HTTPException`.
- Compute `usage_bytes` in `create_vector_store` by summing `usage_bytes` of each file.
- Compute `usage_bytes` in `create_vector_store_file` by reading file size from the database.
- Return `DeleteVectorStoreFileResponse` in `delete_vector_store_file`.
* **`client/.github/workflows/run-tests.yml`**:
- Add a new job for running vector store bytes tests.
* **`client/tests/astra-assistants/test_vector_store_bytes.py`**:
- Add a new test file to verify the `usage_bytes` attribute for vector stores.
- Set up the test environment and write a test function that creates a vector store, attaches files to it, and verifies the `usage_bytes` attribute.
---
For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/datastax/astra-assistants-api/issues/31?shareId=XXXX-XXXX-XXXX-XXXX).
phact
linked a pull request
Dec 2, 2024
that will
close
this issue
No description provided.
The text was updated successfully, but these errors were encountered: