Dynamiq is a Python framework for building multi-agent LLM systems with SurrealDB vector storage capabilities.
SurrealDB ≥ v1.5 has built-in HNSW / M-Tree vector indexes, queried with SurrealQL’s <| K |> operator and vector::distance::* functions.
What happens
SurrealDocumentWriter embeds & inserts snack facts into snack_mem with an HNSW index.SurrealDocumentRetriever performs a cosine k-NN query on embedding <|2|> and passes the top-2 passages to the LLM.| Feature | Benefit | 
|---|---|
| Unified store | Keep vectors, relational data, graph edges & real-time queries in one DB. | 
| Native ANN | DEFINE INDEX … HNSWavoids an extra service. | 
| SurrealQL filters | Mix vector similarity with rich metadata predicates ( WHERE metadata.cuisine = ‘asian’ AND …). | 
Copy the snippets above into your Dynamiq repo and you’re ready to build end-to-end RAG and agent flows with SurrealDB as the memory spine. Happy hacking!