# Localnest

> Local-only MCP server for secure project context retrieval across cloned repositories.

- **Type:** MCP server
- **Install:** `agentstack add mcp-wmt-mobile-localnest`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [wmt-mobile](https://agentstack.voostack.com/s/wmt-mobile)
- **Installs:** 0
- **Category:** [Search](https://agentstack.voostack.com/c/search)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [wmt-mobile](https://github.com/wmt-mobile)
- **Source:** https://github.com/wmt-mobile/localnest
- **Website:** https://wmt-mobile.github.io/localnest/

## Install

```sh
agentstack add mcp-wmt-mobile-localnest
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

LocalNest MCP

  Code Intelligence + Knowledge Graph + AI Memory — One Local MCP Server

  
  
  

  The only MCP server that unifies semantic code search, a temporal knowledge graph, and persistent AI memory in a single local-first package.
  74 tools. Zero cloud. Pure SQLite.

---

## Why LocalNest?

Every other MCP server forces you to choose: memory **or** code intelligence. Never both.

LocalNest is the first to combine all three pillars into one server that runs entirely on your machine:

| Pillar | What it does | Why it matters |
|:---|:---|:---|
| **Code Intelligence** | Hybrid BM25+vector search, AST-aware chunking, symbol finding (defs/usages/callers) | Your AI understands code structure, not just text |
| **Knowledge Graph** | Temporal entity-triple store with multi-hop traversal and `as_of` time-travel queries | Architectural decisions, dependencies, and facts — versioned over time |
| **Persistent Memory** | Cross-session recall, semantic dedup, agent-scoped isolation, conversation ingestion | Your AI remembers what you taught it — forever |

---

## How LocalNest Compares

No other MCP server covers all three pillars. Here's how the landscape breaks down:

### vs Memory-Only Servers

| | **LocalNest** | **Mem0** | **Basic Memory** | **MCP Memory Service** | **AgentMemory** |
|:---|:---:|:---:|:---:|:---:|:---:|
| Persistent AI memory | **Yes** | Yes | Yes | Yes | Yes |
| Knowledge graph | **Yes** | No | No | No | No |
| Semantic code search | **Yes** | No | No | No | No |
| Symbol finding (defs/usages) | **Yes** | No | No | No | No |
| AST-aware chunking | **Yes** | No | No | No | No |
| Local-first / no cloud | **Yes** | Hybrid | Yes | Yes | Yes |
| MCP tools | **74** | 8 | ~10 | 24 | 43 |

> Mem0 has 41k stars and $24M in funding — but it's memory-only with no code intelligence. Basic Memory integrates with Obsidian but can't search code. AgentMemory has auto-capture hooks but zero code features.

### vs Code Intelligence Servers

| | **LocalNest** | **GitNexus** | **claude-context** | **codebase-memory-mcp** | **CodeGraphContext** |
|:---|:---:|:---:|:---:|:---:|:---:|
| Semantic code search | **Yes** | Yes | Yes | Yes | Yes |
| Knowledge graph | **Yes** | Code-only | No | Code-only | Yes |
| Persistent AI memory | **Yes** | No | No | No | No |
| Cross-session recall | **Yes** | No | No | No | No |
| Symbol finding | **Yes** | Yes | No | Yes | Yes |
| Temporal time-travel queries | **Yes** | No | No | No | No |
| Conversation ingestion | **Yes** | No | No | No | No |
| Local-first / no cloud | **Yes** | Yes | Partial | Yes | Yes |
| MCP tools | **74** | 16 | ~5 | 14 | ~10 |

> GitNexus (27k stars) has strong code search but no memory. claude-context (Zilliz, 5.9k stars) is Milvus-backed with no KG or memory. codebase-memory-mcp (DeusData) is the closest competitor — code + KG in a single binary — but has no AI memory layer.

### Full Feature Matrix

| Feature | LocalNest | codebase-memory-mcp | GitNexus | claude-context | Basic Memory | Mem0 |
|:---|:---:|:---:|:---:|:---:|:---:|:---:|
| Semantic code search (hybrid BM25+vec) | **Yes** | Yes | Yes | Yes | No | No |
| Knowledge graph (entities + triples) | **Yes** | Code-only | Code-only | No | No | No |
| Persistent AI memory | **Yes** | No | No | No | Yes | Yes |
| Symbol finding (defs/usages/callers) | **Yes** | Yes | Yes | No | No | No |
| AST-aware chunking | **Yes** | Yes | Yes | Yes | No | No |
| Temporal time-travel queries | **Yes** | No | No | No | No | No |
| Multi-hop graph traversal | **Yes** | No | No | No | No | No |
| Conversation ingestion | **Yes** | No | No | No | No | No |
| Agent-scoped isolation | **Yes** | No | No | No | No | No |
| Semantic dedup | **Yes** | No | No | No | No | No |
| Hooks system (pre/post callbacks) | **Yes** | No | No | No | No | No |
| Interactive TUI dashboard | **Yes** | No | No | No | No | No |
| Local-first / no cloud | **Yes** | Yes | Yes | Partial | Yes | Hybrid |
| MCP tools | **74** | 14 | 16 | ~5 | ~10 | 8 |
| Zero external deps | No (Node.js) | Yes (binary) | No | No | No | No |

**LocalNest is the only server that checks every box in the first three rows.**

---

## Quick Start

```bash
# Install
npm install -g localnest-mcp

# Setup workspace + embeddings
localnest setup

# Verify
localnest doctor
```

**Interactive dashboard:**
```bash
localnest dashboard
```

### MCP Client Config

After setup, add this to your AI client config:

```json
{
  "mcpServers": {
    "localnest": {
      "command": "localnest-mcp",
      "startup_timeout_sec": 30,
      "env": {
        "MCP_MODE": "stdio",
        "LOCALNEST_CONFIG": "~/.localnest/config/localnest.config.json",
        "LOCALNEST_INDEX_BACKEND": "sqlite-vec",
        "LOCALNEST_MEMORY_ENABLED": "true"
      }
    }
  }
}
```

Works with Claude Code, Cursor, Windsurf, Cline, Continue, Gemini CLI, and any MCP-compatible client.

---

## Tool Suites

LocalNest exposes **74 specialized MCP tools**, organized into focused suites:

Workspace & Discovery — file navigation, project summaries, scoped reads
project_tree, read_file, file_changed, list_projects, list_roots, summarize_project

Search & Code Intelligence — hybrid search, symbols, AST-aware queries
search_hybrid, search_code, search_files, find, find_definition, find_usages, find_callers, find_implementations, get_symbol, rename_preview

Memory & Recall — persistent cross-session memory with semantic dedup
memory_store, memory_recall, memory_get, memory_update, memory_delete, memory_list, memory_store_batch, memory_delete_batch, memory_related, memory_suggest_relations, memory_add_relation, memory_remove_relation, memory_capture_event, memory_events, memory_status, memory_check_duplicate

Knowledge Graph — temporal triples, time-travel, multi-hop traversal
kg_add_entity, kg_add_triple, kg_query, kg_invalidate, kg_as_of, kg_timeline, kg_stats, kg_add_entities_batch, kg_add_triples_batch, kg_backfill_links, graph_traverse, graph_bridges

Organization — nests, branches, agent isolation, diary
nest_list, nest_branches, nest_tree, diary_write, diary_read

Ingestion & Hooks — conversation import, lifecycle callbacks
ingest_markdown, ingest_json, hooks_stats, hooks_list_events

Agent Context — priming, teaching, outcomes, task context
agent_prime, teach, capture_outcome, task_context, whats_new

System — health, indexing, updates, embedding status
health, server_status, index_project, index_status, embed_status, update_self, update_status, audit, backup, restore, help, usage_guide

Full parameter reference: [Tool Documentation](https://wmt-mobile.github.io/localnest/docs/tools/overview)

---

## Agentic Workflows

LocalNest is designed as the foundational context layer for AI coding agents:

- **Cold start** — `agent_prime` instantly hydrates the context window with relevant memories, recent changes, and project state.
- **Deep investigation** — `find` runs fused search across code fragments and historical design decisions in a single call.
- **Continuous learning** — `teach` saves architectural rules that persist across sessions, ensuring agents never repeat mistakes.
- **Outcome capture** — `capture_outcome` records what worked and what didn't, building an experience base over time.

---

## Enterprise-Grade Quality

- **OIDC Trusted Publishing** for verifiable npm provenance
- **Continuous CodeQL** static analysis on all branches
- **OpenSSF Scorecard** monitoring and proactive Dependabot updates

---

## Troubleshooting

Installing from GitHub fails

Direct `npm install -g git+https://...` may fail with `TAR_ENTRY_ERRORS`. This is a [known npm limitation](https://github.com/npm/cli/issues/3910).

**Fix: clone, pack, install**
```bash
git clone https://github.com/wmt-mobile/localnest.git
cd localnest && npm pack
npm install -g ./localnest-mcp-*.tgz
```

Semantic search not working

```bash
cd $(npm root -g)/localnest-mcp && npm install --no-save @huggingface/transformers
localnest doctor
```

---

## Resources

- **[Documentation](https://wmt-mobile.github.io/localnest/)** — Full tool reference, architecture, and guides
- **[Comparison](https://wmt-mobile.github.io/localnest/docs/comparison)** — Detailed competitive analysis
- **[Architecture](https://wmt-mobile.github.io/localnest/docs/architecture)** — Retrieval pipeline and memory graph internals
- **[Changelog](./CHANGELOG.md)** — Release history
- **[Security](./SECURITY.md)** — Vulnerability disclosure policy

---

  Code intelligence. Knowledge graph. AI memory. One server. Your machine.

## Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [wmt-mobile](https://github.com/wmt-mobile)
- **Source:** [wmt-mobile/localnest](https://github.com/wmt-mobile/localnest)
- **License:** MIT
- **Homepage:** https://wmt-mobile.github.io/localnest/

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/mcp-wmt-mobile-localnest
- Seller: https://agentstack.voostack.com/s/wmt-mobile
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
