A personal knowledge library for AI agents, built on Arcade for the Model Context Protocol (MCP).
Status. Agent Library is a community project built by Arcade.dev engineers. and is not covered by Arcade.dev support or SLAs. See below for what to expect.
Agent Library personal knowledge base with a search and retrieval system MCP Server and CLI. Preconfigured local models and support for Text, images, OCR/vision, and code embeddings. Use over MCP with (Claude, Cursor, Codex, ChatGPT, etc)
Naming. The package is Agent Library (agent-library on PyPI, librarian as the Python module). The MCP server inside it identifies itself as Librarian — that's the role your agent talks to, and it's why the exposed tools are named Librarian_SearchLibrary, Librarian_AddToLibrary, and so on.
Overview
Agent Library provides AI agents with persistent storage for text, documents, and knowledge. Agents can store information and retrieve it later through semantic and keyword search, maintaining context across conversations.
graph LR
A[Agent Stores Info] --> B[Parser]
B --> C[Chunker]
C --> D[Embedder]
D --> E[(SQLite + vec)]
F[Agent Queries] --> G[Hybrid Search]
E --> G
G --> H[Relevant Context]
Features
Persistent knowledge storage for AI agents
SQLite storage with sqlite-vec for vector search
Full-text search using FTS5 with BM25 ranking
Hybrid search combining semantic and keyword matching
Max Marginal Relevance (MMR) for diverse results
Configurable embedding models (local or OpenAI-compatible API)
Header-aware text chunking with overlap
Time-bounded search filters
CLI and MCP server interfaces
Multi-Modal Support
Agent Library supports indexing and searching across multiple file types:
Asset Type
File Extensions
Features
Text
.md, .txt
Frontmatter extraction, header-aware chunking
Code
.py, .js, .ts, .go, .rs, .java, .cpp, and more
Symbol extraction (classes, functions, methods)
PDF
.pdf
Page-based text extraction
Image
.png, .jpg, .jpeg, .gif, .webp
Metadata and EXIF extraction, optional OCR
Installation
The recommended way to install Agent Library is as a uv tool, which gives you the libr CLI and the MCP server in an isolated environment:
uv tool install 'agent-library[all]'
The [all] extra pulls in optional support for PDFs, images, OCR, and code-aware embeddings. If you'd rather install only what you need:
uv tool install agent-library # core only (text + code)
uv tool install 'agent-library[pdf]' # add PDF support
uv tool install 'agent-library[vision]' # add image support
uv tool install 'agent-library[ocr]' # add OCR for image-based PDFs
Installing from source
If you want to contribute or run from a clone:
git clone https://github.com/arcadeai-labs/agent-library.git
cd agent-library
./setup.sh
Or install manually with the dev extras:
uv pip install -e ".[dev,all]"
CLI Usage
# Add files to the library
libr add ~/notes
# Search the library
libr search "machine learning concepts"
# List sources
libr list
# View library statistics
libr index
# Rebuild the index
libr index build
MCP Server
Start the server for AI assistant integration:
# stdio transport (Claude Desktop, CLI)
libr serve stdio
# HTTP transport (Cursor, VS Code)
libr serve http --port 8000
make install # Install dependencies
make test # Run tests
make lint # Run linter
make format # Format code
make typecheck # Type checking
make check # All checks
make evals # Run evaluations
Agent Library is a community project built by Arcade.dev engineers. It is not an official Arcade.dev product and is not covered by Arcade.dev support or SLAs.
GitHub issues are monitored on a best-effort basis. Expect response times in days-to-weeks, not hours.
Pull requests are welcome. See CONTRIBUTING.md for how to file one and what we're likely to accept.
Security vulnerabilities should be reported privately per SECURITY.md, not via public issues.
If you're using Agent Library in something important, snapshot the SQLite index (~/.librarian/index.db) before anything you can't easily redo. The index is a single file — cp is your friend.
Contributing
See CONTRIBUTING.md. Issues, PRs, and new parsers/embedders are all welcome.
Agent Library personal knowledge base with a search and retrieval system MCP Server and CLI. Preconfigured local models and support for Text, images, OCR/vision, and code embeddings. Use over MCP with
Agent Library personal knowledge base with a search and retrieval system MCP Server and CLI. Preconfigured local models and support for Text, images, OCR/vision, and code embeddings. Use over MCP with (Claude, Cursor, Codex, ChatGPT, etc)
ตรวจสอบล่าสุดเมื่อ 2026-10-28 Agent Library personal knowledge base with a search and retrieval system MCP Server and CLI. Preconfigured local models and support for Text, images, OCR/vision, and code embeddings. Use over MCP with (Claude, Cursor, Codex, ChatGPT, etc)