Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

14 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

homebrew-openmemory

A Homebrew tap that installs OpenMemory — a self-hosted memory layer for AI — as three managed macOS services plus a convenience CLI.

OpenMemory gives your AI tools persistent, searchable memory backed by a vector database. This tap packages the full stack:

Component Formula What it is
Qdrant qdrant Vector database for similarity search (pre-built binary)
MCP backend openmemory-mcp FastAPI/Python server, SQLite database, Alembic migrations
UI openmemory-ui Next.js 15 web dashboard
CLI wrapper (installed by openmemory) openmemory start/stop/restart/status

Prerequisites

  • macOS (Apple Silicon or Intel)
  • Homebrew — brew.sh
  • OpenAI API key (or a compatible alternative — see Configuration)

Quick Start

# 1. Add the tap
brew tap jabbas/openmemory

# 2. Install the full stack
brew install openmemory

# 3. Set your API key
#    The config file was created automatically at install time:
nano "$(brew --prefix)/etc/openmemory/openmemory.env"
#    Replace 'sk-replace-me' with your actual key:
#    OPENAI_API_KEY=sk-...

# 4. Start all services
openmemory start

Once running:


CLI Usage

The openmemory command manages all three services together via brew services.

openmemory <command>

Commands:
  start    Start all OpenMemory services (qdrant, openmemory-mcp, openmemory-ui)
  stop     Stop all OpenMemory services
  restart  Restart all OpenMemory services
  status   Show status of all OpenMemory services

Examples:

openmemory start
openmemory status
openmemory restart
openmemory stop

Configuration

The config file lives at:

$(brew --prefix)/etc/openmemory/openmemory.env

It is created automatically from openmemory.env.example on first install. Edit it before starting services.

Available Options

# ── Required ──────────────────────────────────────────────────────────────────
OPENAI_API_KEY=sk-replace-me

# ── Data storage ──────────────────────────────────────────────────────────────
# OPENMEMORY_DATA_DIR=/opt/homebrew/var/openmemory
# DATABASE_URL=sqlite:////opt/homebrew/var/openmemory/openmemory.db

# ── Qdrant ────────────────────────────────────────────────────────────────────
QDRANT_HOST=localhost
QDRANT_PORT=6333

# ── MCP API server ────────────────────────────────────────────────────────────
OPENMEMORY_HOST=0.0.0.0
OPENMEMORY_PORT=8765
# OPENMEMORY_WORKERS=4

# ── UI server ─────────────────────────────────────────────────────────────────
# OPENMEMORY_UI_PORT=3000
# OPENMEMORY_UI_HOST=0.0.0.0

# ── Optional: LLM provider overrides (defaults to OpenAI) ─────────────────────
# LLM_PROVIDER=ollama
# LLM_MODEL=llama3.1:latest
# LLM_API_KEY=
# LLM_BASE_URL=
# OLLAMA_BASE_URL=http://localhost:11434

# ── Optional: Embedder overrides ──────────────────────────────────────────────
# EMBEDDER_PROVIDER=ollama
# EMBEDDER_MODEL=nomic-embed-text

Ports

Service Default port Override env var
Qdrant HTTP 6333 QDRANT_PORT (also update etc/qdrant/config.yaml)
Qdrant gRPC 6334 (edit etc/qdrant/config.yaml)
MCP API 8765 OPENMEMORY_PORT
UI 3000 OPENMEMORY_UI_PORT

Note: NEXT_PUBLIC_API_URL is baked into the UI bundle at build time (default: http://localhost:8765). If you change the MCP API port, you must rebuild the UI:

cd "$(brew --prefix)/opt/openmemory-ui/libexec/ui"
NEXT_PUBLIC_API_URL=http://localhost:<new-port> pnpm build

Individual Formula Install

For advanced users who only need specific components:

# Vector database only
brew install jabbas/openmemory/qdrant

# MCP backend only (requires qdrant)
brew install jabbas/openmemory/openmemory-mcp

# UI only (requires openmemory-mcp running somewhere)
brew install jabbas/openmemory/openmemory-ui

Start individual services:

brew services start qdrant
brew services start openmemory-mcp
brew services start openmemory-ui

Troubleshooting

Check service status

openmemory status
# or
brew services list | grep -E "qdrant|openmemory"

View logs

All logs are written to $(brew --prefix)/var/log/openmemory/:

File Service
qdrant.log / qdrant.error.log Qdrant
mcp.log / mcp.error.log MCP backend
ui.log / ui.error.log Next.js UI
# Tail MCP backend logs
tail -f "$(brew --prefix)/var/log/openmemory/mcp.log"
tail -f "$(brew --prefix)/var/log/openmemory/mcp.error.log"

Common issues

Services won't start / OPENAI_API_KEY error Edit your config file and ensure OPENAI_API_KEY is set to a real key (not sk-replace-me):

nano "$(brew --prefix)/etc/openmemory/openmemory.env"

Database not initialized Run migrations manually:

openmemory-migrate

UI shows "cannot connect to API" Ensure openmemory-mcp is running and NEXT_PUBLIC_API_URL matches the MCP port. The URL is baked in at build time — see the note in Configuration.

Port conflict Change the relevant port in openmemory.env and restart:

openmemory restart

Reinstall / reset data

openmemory stop
rm -rf "$(brew --prefix)/var/openmemory"
openmemory start   # migrations run automatically on restart

Upstream Project


License

Apache 2.0 — same as the upstream mem0 project.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages