Barrel
FR GitHub

Libraries

Barrel is one database made of independent Apache 2.0 libraries in one umbrella repository. You use the barrel API, run barrel_server, or depend on a single library. This page lists them, says what each needs to build, and links its generated reference: the guides it ships plus its module documentation, built with ex_doc from the source.

The stack

LibraryVersionRoleReference
barrel1.14.0The database: documents, attachments and vectors under one id, BQL, record mode, timeline, contexts/docs/lib/barrel/
barrel_docdb3.1.0Documents, versions, queries, attachments, replication/docs/lib/docdb/
barrel_vectordb2.5.4Vector index (HNSW, DiskANN, FAISS), BM25, hybrid search/docs/lib/vectordb/
barrel_ngram0.11.5Exact substring and regex search over a docdb databasesource
barrel_embed2.6.1Embedding providers, local or cloud/docs/lib/embed/
barrel_rerank1.0.3Cross-encoder reranking/docs/lib/rerank/
barrel_crypto1.0.0Encryption-at-rest primitives and key providers/docs/lib/crypto/
barrel_spaces2.0.0Spaces, capability tokens, sessions, handoffs/docs/lib/spaces/
barrel_server1.15.1REST and MCP over HTTP/docs/lib/server/
barrel_att_s30.2.2Attachments in S3-compatible storagesource
barrel_faiss1.0.1NIF bindings to FAISSHexDocs
barrel-lite0.1.0TypeScript client with a copy in the browser; not published to npmguide

barrel_faiss links against a system FAISS build, so its reference is not built with this site; read it on HexDocs. barrel_ngram and barrel_att_s3 have no reference site here yet; their README and module docs are in the repository.

For the HTTP and MCP surface, use the REST API and MCP tools pages.

Build profiles

A plain build of the umbrella leaves out the apps that need extra toolchains or pull network dependencies:

rebar3 compile              # barrel and its libraries
rebar3 as server compile    # adds barrel_server
rebar3 as s3 compile        # adds barrel_att_s3
rebar3 as faiss compile     # adds barrel_faiss
  • Every app needs OTP 26 or later. barrel_docdb, barrel_vectordb and barrel_ngram build C or C++ code with CMake.
  • barrel_faiss needs the FAISS library, OpenMP and BLAS. It builds on Linux, macOS and the BSDs, not Windows.
  • barrel_embed and barrel_rerank install Python packages into a venv for their local models.

See Build and test for the test commands.

Depend on one library

Each library has its own rebar.config and depends on its siblings by version. For example, documents and replication without vectors:

{deps, [{barrel_docdb, "~> 3.1"}]}.

The source of every library is at github.com/barrel-db/barrel, under apps/.

Written for the site Edit this page View as Markdown

Up and down to moveEnter to open