whatisgithub

What is gbrain?

garrytan/gbrain — explained in plain English

Analysis updated 2026-06-24

15,465TypeScriptAudience · developerComplexity · 3/5Setup · moderate

In one sentence

A persistent memory system for AI agents that stores meetings, emails, and notes in a local knowledge graph so agents can remember past context, people, and relationships across conversations, no AI call needed at ingest time.

Mindmap

mindmap
  root((gbrain))
    What it does
      Persistent memory
      Knowledge graph
      Entity linking
      Hybrid retrieval
    Inputs
      Meetings
      Emails
      Notes
      Voice calls
    Retrieval
      Vector search
      Graph traversal
    Integrations
      OpenAI
      Voyage
      Gemini
      Ollama
      llama.cpp
    Audience
      AI agent builders
      Developers
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Give a personal AI assistant durable memory so it can recall contacts, meeting notes, and past decisions across separate sessions.

USE CASE 2

Build a knowledge graph of your professional network by feeding GBrain emails and meeting transcripts, then query it by relationship.

USE CASE 3

Integrate GBrain with an autonomous agent platform to add structured long-term memory without extra language-model calls at ingest.

What is it built with?

TypeScriptBunPGLiteOpenAIVoyageGoogle GeminiOllama

How does it compare?

garrytan/gbrainvercel/vercelpascalorg/editor
Stars15,46515,47615,412
LanguageTypeScriptTypeScriptTypeScript
Setup difficultymoderateeasymoderate
Complexity3/53/53/5
Audiencedeveloperdeveloperdesigner

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires a 30-minute setup via agent or CLI plus an embedding provider API key such as OpenAI or Voyage.

So what is it?

GBrain is a long-term memory system for AI agents, always-on assistants that read emails, take notes from meetings, or follow your calendar. Out of the box those agents tend to be smart but forgetful: they answer the question in front of them and then lose everything once the conversation ends. GBrain gives them a "brain" that persists, so each new interaction can draw on what the agent has seen before. The brain ingests raw material, meetings, emails, tweets, voice calls, notes, into a local database. As each page is saved, GBrain extracts the people, companies, and other entities mentioned and creates typed links between them (such as "attended," "works_at," "invested_in," "founded," "advises") to build a knowledge graph, without extra calls to a language model. Retrieval uses a hybrid of vector search and that graph, so questions like "who works at Acme AI?" can be answered by following links, not similarity alone. Overnight jobs enrich entities, fix citations, and consolidate memory. The project ships 34 reusable skills, an evaluation harness called BrainBench, and an integration with the LongMemEval benchmark. You would set GBrain up if you run an autonomous AI agent, built on platforms like OpenClaw or Hermes, and want it to accumulate durable, structured memory about your work and contacts. Install takes about thirty minutes via an agent or a standalone command-line tool, the database is PGLite, which needs no server. It is written in TypeScript and runs under Bun, with built-in support for embedding providers including OpenAI, Voyage, Google Gemini, Azure OpenAI, Ollama, and llama.cpp. The full README is longer than what was provided.

Copy-paste prompts

Prompt 1
I want my AI agent to remember past emails and meeting notes. Show me how to set up GBrain with the standalone CLI and ingest a folder of meeting transcripts.
Prompt 2
Using GBrain's knowledge graph, write a query to find all people who work at a specific company based on ingested emails.
Prompt 3
Set up GBrain with Ollama as the embedding provider instead of OpenAI and ingest a batch of plain-text notes from a local folder.
Prompt 4
Explain how GBrain's overnight enrichment jobs work and what they do to entity records between ingest sessions.

Frequently asked questions

What is gbrain?

A persistent memory system for AI agents that stores meetings, emails, and notes in a local knowledge graph so agents can remember past context, people, and relationships across conversations, no AI call needed at ingest time.

What language is gbrain written in?

Mainly TypeScript. The stack also includes TypeScript, Bun, PGLite.

How hard is gbrain to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is gbrain for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.