Load, chunk, embed, store
The whole path from raw content to searchable vectors runs from one call, which is the part most projects rebuild badly before they rebuild it well.
The RAG pipeline as swappable parts, covering loaders, chunkers, embedders, vector stores and retrievers, with token-budgeted assembly and citations at the end. Postgres, SQLite or memory for metadata; pgvector or memory for vectors. Runs standalone or as a Forge extension with its own HTTP surface.
Ingestion loads, chunks, embeds and stores in a single operation, so the pipeline is not yours to assemble.
Cosine similarity, maximal marginal relevance and hybrid search, with configurable top-K and score thresholds.
OnIngestCompleted, OnRetrievalStarted and twelve more, so metrics and audit trails attach without a fork.
Retrieval-augmented generation as a library, with the document lifecycle handled for you.
The whole path from raw content to searchable vectors runs from one call, which is the part most projects rebuild badly before they rebuild it well.
Cosine similarity for the obvious case, maximal marginal relevance when results cluster too tightly, and hybrid search across both, with top-K and score thresholds configurable per query.
Collections, documents and chunks all carry their tenant on the context, so a cross-tenant query cannot be written.
Development runs in memory and production on Postgres with pgvector, with every subsystem behind a Go interface.
OnIngestCompleted, OnRetrievalStarted and twelve others, for metrics, audit trails and behaviour that belongs outside the library.
Each collection sets its embedding model, chunk strategy and metadata, and can be reindexed at any point without the others moving.
Documents in, chunked and embedded.
Vector and keyword recall over the same store.
Ordering the candidates before they reach the model.
Context built to a budget, not to a limit.
Weave is a composable RAG pipeline for Go. Load documents, chunk them, embed, store vectors, retrieve relevant context and assemble a prompt, with each stage swappable, in one library.
Ingest runs loader → chunker → embedder → vector store. Retrieve runs query → embedder → retriever → results. Assemble takes those results and applies a token budget and citations before the prompt is built.
Splitting assembly out as its own stage was the decision that mattered most. Most RAG failures I have debugged were not retrieval failures. The right chunk was in the result set and got truncated out of the prompt by a naive concatenation with no budget.
Weave supplies the retrieval half of the agent stack. Cortex runs the episode; KGKit holds what survives it. A retrieval hit and a graph claim are different kinds of evidence, and keeping them in separate systems has made it much easier to tell which one an answer actually rested on.
Shipping something on Weave? Nobody is listed here yet. Tell me what you built and you will be the first.
Get listed →