Skip to main content

BrainPalace CLI - Command-line interface for the typed-memory & retrieval engine for AI agents (code & docs today, more domains coming)

Project description

BrainPalace CLI

Command-line interface for managing AI agent memory and knowledge retrieval with the BrainPalace RAG server.

BrainPalace (formerly doc-serve) is an intelligent document indexing and semantic search system designed to give AI agents long-term memory. This CLI provides a convenient way to manage your BrainPalace server and knowledge base.

PyPI version Python 3.10+ License: MIT

Why BrainPalace?

AI agents need persistent memory to be truly useful. BrainPalace provides the retrieval infrastructure that enables context-aware, knowledge-grounded AI interactions.

Search Capabilities

Search Type Description Best For
Semantic Search Natural language queries using OpenAI embeddings Conceptual questions, related content
Keyword Search (BM25) Traditional keyword matching with TF-IDF ranking Exact matches, technical terms
Hybrid Search Combines vector + BM25 approaches General-purpose queries
GraphRAG Knowledge graph retrieval Understanding relationships

Installation

pip install brainpalace-cli

Quick Start

brainpalace init          # Initialize project
brainpalace start         # Start server
brainpalace index ./docs  # Index documents
brainpalace query "search term"

Note: The legacy command doc-svr-ctl is still available but deprecated. Please use brainpalace for new installations.

Development Installation

cd brainpalace-cli
poetry install

Usage

# Check server status
brainpalace status

# Search documents
brainpalace query "how to use python"

# Index documents from a folder
brainpalace index ./docs

# Reset/clear the index
brainpalace reset --yes

Configuration

Set the server URL via environment variable:

export BRAINPALACE_URL=http://localhost:8000

Or use the --url flag:

brainpalace --url http://localhost:8000 status

Note: The legacy environment variable DOC_SERVE_URL is still supported for backwards compatibility.

Commands

Server Management

Command Description
init Initialize project for BrainPalace (creates .claude/brainpalace/)
start Start the BrainPalace server for current project
stop Stop the running server
list List all running BrainPalace instances
status Check server health and indexing status

Data Management

Command Description
query Search indexed documents
index Start indexing documents from a folder
reset Clear all indexed documents

Options

All commands support:

  • --url - Server URL (or BRAINPALACE_URL / DOC_SERVE_URL env var)
  • --json - Output as JSON for scripting

Example Workflow

# 1. Initialize a new project
cd my-project
brainpalace init

# 2. Start the server
brainpalace start

# 3. Index your documentation
brainpalace index ./docs ./src

# 4. Query your knowledge base
brainpalace query "How does authentication work?"

# 5. Stop when done
brainpalace stop

Documentation

Release Information

Related Packages

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

brainpalace_cli-26.7.6.tar.gz (295.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

brainpalace_cli-26.7.6-py3-none-any.whl (361.2 kB view details)

Uploaded Python 3

File details

Details for the file brainpalace_cli-26.7.6.tar.gz.

File metadata

  • Download URL: brainpalace_cli-26.7.6.tar.gz
  • Upload date:
  • Size: 295.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for brainpalace_cli-26.7.6.tar.gz
Algorithm Hash digest
SHA256 ab5d0b000dc15959be6b830f9a9631315861d97ed3dd3bbf3822d10c760684f2
MD5 4b6803018204883b58402f99562d556a
BLAKE2b-256 bb1f3c04388157971353f19968b7bf9b6110087e6b5b51c5b95324415f8228cb

See more details on using hashes here.

Provenance

The following attestation bundles were made for brainpalace_cli-26.7.6.tar.gz:

Publisher: publish-to-pypi.yml on bxw91/brainpalace

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file brainpalace_cli-26.7.6-py3-none-any.whl.

File metadata

File hashes

Hashes for brainpalace_cli-26.7.6-py3-none-any.whl
Algorithm Hash digest
SHA256 c7d2102cd8cd8793803202d65c93e834b838a15d314a441765ebc793986d92db
MD5 565a427aaf061255aea137840c8b2a14
BLAKE2b-256 5725e9335a2bcd42b0ed91b01ccd05f752f1fe0aebae838b0d4913f4f4d884bd

See more details on using hashes here.

Provenance

The following attestation bundles were made for brainpalace_cli-26.7.6-py3-none-any.whl:

Publisher: publish-to-pypi.yml on bxw91/brainpalace

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page