symfony/ai-weaviate-store
Weaviate vector store integration for Symfony AI Store, with links to the REST API, GraphQL Get, and nearVector similarity search docs. Part of the Symfony AI monorepo for reporting issues and contributions.
What the package actually is (and is not)
nearVector API into Symfony AI's StoreInterface (add/query/remove/clear/count, plus VectorDocumentInterface and a query filter abstraction as of v0.4–v0.14).Architecture fit
StoreInterface, sibling bridges (and an in-memory store for tests) share a contract, which is a genuine portability lever.symfony/http-client and a set of Symfony contracts alongside Illuminate. This is workable but is a second DI/runtime idiom we must isolate, not sprinkle.count is the most immediately valuable addition — pagination totals, index-health dashboards, and coverage checks without fetching documents.Integration feasibility
StoreInterface to a configured Weaviate store instance, with config in config/ai.php and credentials from env, is a day-scale task. Scoping an HTTP client (the ScopingHttpClient support added in v0.7.0) is exactly the right hook for per-tenant or per-environment Weaviate endpoints.Technical risk
StoreInterface::clear(), count(), VectorDocumentInterface). Any 0.x minor may shift contracts. We must pin to a tested minor and treat upgrades as intentional work items.Key questions
count on a hot path, and what is our caching story for it?VectorDocumentInterface as our DTO contract, or map our own domain objects to it inside an adapter?symfony/http-client alongside our existing Guzzle/Illuminate HTTP stack without constraint surgery?Stack fit
app/Search or a first-party package), exposing exactly one port: SearchStore with upsert, search, delete, count.symfony/ai-weaviate-store implements that port; nothing outside the module imports StoreInterface, VectorDocumentInterface, or Weaviate response types.config/ai.php), credentials from env, HTTP client scoped per environment/tenant, and a WeaviateStore binding registered by a dedicated service provider.Migration path
nearVector query → filtered query → count → remove/clear end-to-end from Laravel with the scoped HTTP client.count for pagination and dashboards.VectorDocumentInterface becomes our internal DTO contract.Compatibility
~0.x.y of the tested line; do not float the minor, and do not use ^ on a 0.x package whose minors carry interface changes.symfony/http-client and our Guzzle/Illuminate HTTP usage; if they conflict, keep the Symfony client strictly inside the module boundary.StoreInterface signature drift, then bump.Sequencing rationale
count instrumentation; count is an optimization and observability layer, not a day-one need.Maintenance
Support
symfony/ai monorepo; MIT, no SLA, effectively no downstream user base to lean on. Internal ownership is mandatory, not optional.Scaling
count is cheaper than fetching documents but not free on large filtered collections. Cache dashboard and pagination counts in Redis with collection-scoped keys and a short TTL; never call count on every search request unless the UX demands it.nearVector at 10M+ objects behaves very differently from 10k. Load-test with production-shaped data before committing to SLAs.Failure modes
Ramp-up and recommendation
SearchStore port is ours. Approve the spike, require the exit plan (direct Weaviate client, or a Postgres/pgvector alternative) to be written down, and re-evaluate on the next pre-1.0 bump or at 1.0, whichever comes first.How can I help you explore Laravel packages today?