# Lybrary [Health: Active]

**Category:** 🧠 Knowledge & Memory  
**Repository:** https://github.com/vibhu-dixit/lybrary  
**GitHub Stars:** 0  
**Views:** 1  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/lybrary

## Description
Local codebase memory and repository code search for Codex, Claude Code, and MCP coding agents.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `uvx` (confidence: high):

```json
"mcpServers": {
  "lybrary": {
    "command": "uvx",
    "args": ["lybrary"]
  }
}
```

## Documentation

## What Lybrary MCP server does

The Lybrary MCP server gives coding agents a searchable map of a local repository. It identifies functions, classes, files, source paths, and line ranges, allowing an agent to locate likely implementation areas before opening complete files. The index is kept on the local machine, with a separate index and configuration directory for each repository.

The main MCP tools are `memory_query`, `memory_status`, and `memory_update`. Queries return ranked matches with symbols, line ranges, and compact numbered excerpts by default. Status reports the active repository and index health, while update starts incremental, full, or path-scoped re-indexing.

## How it works

Run `lybrary start` from a repository after installing the Python package. The command creates `.lybrary/` when needed, builds the initial index, and starts a background file-watching daemon. Changed files are refreshed while the daemon runs. `lybrary stop`, `lybrary status`, `lybrary query`, `lybrary index --full`, and `lybrary logs` provide local administration and terminal search options.

`memory_query` checks exact symbols and an SQLite FTS5 index first. When wording does not match the source closely, semantic search can serve as a fallback using the local embedding model. The MCP process is started with `lybrary mcp`, using the repository root as context. If an agent starts outside the indexed repository, pass that repository's absolute path as `repo_root`.

## Setup and configuration

Install the package with `pip install lybrary`, change to the repository to index, and run:

```bash
lybrary start
lybrary status
```

Register the stdio server with the MCP client using command `lybrary` and argument `mcp`. Codex can register it with `codex mcp add lybrary -- lybrary mcp`. Claude Code can register it with `claude mcp add --scope user --transport stdio lybrary -- lybrary mcp`. Their documented plugins can also help with setup.

Configuration is stored in `.lybrary/config.toml`. It can control the embedding model and device, chunk sizes, indexed languages, excluded paths, and watcher debounce behavior. Git-style ignore patterns can be added to `.lybrary/ignore`. Run `lybrary index --full` after changing settings that affect chunks or embeddings. The first indexing pass may download the local embedding model; subsequent runs use its cache.

## Tools and capabilities

The Lybrary MCP server supports parsers for Python, JavaScript, TypeScript, TSX, Go, Rust, Java, C, and C++. Tree-sitter boundaries are used during indexing. Separate repository indexes let agents work with more than one local codebase without using a hosted service.

Useful capabilities include:

- Searching for exact symbols, textual matches, or semantically related code
- Returning ranked paths, symbols, line ranges, and excerpts
- Requesting complete indexed chunks when needed
- Checking repository and index status
- Triggering incremental, full, or path-specific updates
- Keeping the index current through a background file watcher

## Limitations and notes

Lybrary is intended for local repositories and requires a running or available repository index. It does not replace inspection of the source files an agent ultimately needs to modify. Search quality and token use depend on the task, indexed content, and the agent's tool choices. A single benchmark question is not enough to establish typical savings.

If the index is missing or an MCP query fails, an agent should fall back to normal code search. When a call trace reaches a named symbol absent from the first result, query that symbol separately.

_Full upstream README: https://allmcps.com/mcp/lybrary/readme_

