BrainAPI
BrainAPI
Start

For the complete BrainAPI documentation index, see llms.txt. A markdown version of any docs page is available by appending .md to its URL. Docs MCP: /docs/mcp.

BrainAPI V2

Build, operate, and extend applications on a traceable knowledge graph

BrainAPI turns text, files, and structured events into a shared knowledge base for context retrieval, ranked search, recommendations, and agent tools. You choose how much structure and ranking you need; BrainAPI keeps every request scoped to a brain.

Current documentation

These pages describe BrainAPI 2.17.0-dev. V1 remains available as Legacy, but start with V2 for new systems.

Choose your path

The product in one minute

  1. Ingest text, files, or explicit graph facts into a named brain.
  2. Process the input asynchronously with deterministic logic and, when configured, specialized extraction agents.
  3. Store passages, entities, relationships, events, observations, and vectors in the configured backends.
  4. Retrieve the representation suited to your application: context packs, ranked hits, recommendations, graph facts, or agent tools.

The brain is the isolation boundary. A request normally carries a BrainPAT token and an X-Brain-ID header; BrainAPI validates both before reading or writing data.

What you can build

GoalStart withWhy
Ground an assistantContextReturns passages and graph context ready for an LLM prompt.
Search documentation or support dataSearchReturns ranked, inspectable hits with optional graph and plugin stages.
Suggest related content or next actionsRecommendationsStarts from a user or item rather than a text query.
Investigate connected eventsGraph retrievalExposes relationships and traversal signals directly.
Give an agent toolsMCPLets compatible runtimes call BrainAPI without embedding REST details in prompts.

What BrainAPI is not

BrainAPI is not a replacement for ordinary CRUD when rows and foreign keys already answer the problem. It is most useful when information arrives as changing language or events, multiple representations must coexist, or a caller needs traceable relationships behind an answer.

First successful request

The Quickstart takes you from an empty machine to a completed ingest-and-retrieve flow. If BrainAPI is already running, go directly to Authentication and brains, then choose how to ingest and how to retrieve.

Help and machine-readable docs

Edit on GitHub

Last updated on

On this page