MCP runtime + package manager + memory layer - One MCP to rule them all
npm install luunixMCP Runtime + Package Manager + Memory Layer - One MCP to rule them all
Luunix is a runtime and package manager for Model Context Protocol (MCP) servers. It allows you to dynamically load, unload, and manage multiple MCPs through a single interface, with a built-in memory layer for context management.
Luunix supports 7 popular AI coding assistants:
| Client | Config Location | Status |
|--------|----------------|--------|
| Claude Code | ~/.claude.json | Full Support |
| Cursor | .cursor/mcp.json | Full Support |
| Windsurf | ~/.codeium/windsurf/mcp_config.json | Full Support |
| Zed | ~/.config/zed/settings.json | Full Support |
| Continue | ~/.continue/config.json | Full Support |
| Cline | VS Code Settings | Full Support |
| Codex CLI | ~/.codex/config.yaml | Full Support |
Traditional approach: All MCP tools are exposed to the LLM in every API request.
- 50 tools × ~150 tokens/tool = ~7,500 tokens per turn
Luunix approach: Only 10 core tools, load MCPs on-demand, store large responses in memory.
- 10 tools × ~150 tokens = ~1,500 tokens per turn
- Saves ~80% of tool schema tokens
- Memory layer further reduces context by storing large MCP responses
```
┌─────────────────────────────────────────────────────────┐
│ Claude Code │
│ │
│ Only sees 10 Luunix tools: │
│ • luunix.list • luunix.load • luunix.call │
│ • luunix.unload • luunix.status │
│ • luunix.store • luunix.recall • luunix.forget│
│ • luunix.compress • luunix.memory_stats │
└─────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────┐
│ Luunix Server │
│ │
│ MCP Runtime: │
│ Manages 100+ MCPs internally, load on-demand │
│ │
│ Memory Layer: │
│ SQLite + Local Embedding (all-MiniLM-L6-v2) │
│ Store large responses → Return summaries │
│ Semantic search for context recall │
└─────────────────────────────────────────────────────────┘
- Token Efficient: Only 10 tools exposed, saves ~80% schema tokens
- Dynamic Loading: Load/unload MCPs at runtime
- Full Schema Return: luunix.load returns complete parameter schemasluunix.call
- Unified Proxy: Call any MCP tool via
- Built-in Registry: Pre-configured popular MCPs
- Memory Layer: Store large MCP responses, recall via semantic search
- Local Embedding: No external API needed, runs entirely offline
`bash`
npm install -g luunix
`bash`
luunix init
This will automatically detect and configure your AI client to use Luunix. Supports Claude Code, Cursor, Windsurf, Zed, Continue, Cline, and Codex CLI.
Run luunix without arguments to enter the interactive menu:
`bash`
luunix
``
? What would you like to do?
❯ 🔍 Search & Install MCPs
📦 Manage Installed MCPs
⚙️ Configure AI Clients
📊 View Status
❌ Exit
`bash`
luunix add context7 github playwright
`Step 1: List available MCPs
luunix.list
CLI Commands
$3
Initialize Luunix and configure your AI client.
`bash
luunix init
luunix init --force # Force reconfiguration
`$3
Add MCPs to your installation.
`bash
luunix add context7
luunix add context7 github playwright # Add multiple at once
`$3
Remove MCPs from your installation.
`bash
luunix remove github
luunix rm context7 github # 'rm' is an alias
`$3
List MCPs.
`bash
luunix list # Show installed MCPs
luunix list --all # Show all available MCPs
luunix ls -a # 'ls' is an alias
`$3
Search MCPs in remote registry (17,000+ available).
`bash
luunix search # List popular MCPs
luunix search github # Search for GitHub-related MCPs
luunix search --limit 50 # Show more results
luunix search --refresh # Force refresh cache
`$3
Show Luunix configuration.
`bash
luunix config
luunix config --path # Show config file path only
`$3
Start the Luunix MCP server. This is called automatically by AI clients.
`bash
luunix serve
`MCP Server Tools
When running as an MCP server, Luunix provides 10 tools:
$3
####
luunix.listList all available MCPs and their status.
Returns: MCP names, descriptions, install status, load status, available tools.
####
luunix.loadLoad an MCP and get its complete tool schemas.
Input:
`json
{ "name": "context7" }
`Returns: Full tool definitions including parameter names, types, and descriptions. This allows the LLM to correctly call tools via
luunix.call.####
luunix.callCall a tool from a loaded MCP.
Input:
`json
{
"mcp": "context7",
"tool": "query-docs",
"args": {
"libraryId": "/pmndrs/zustand",
"query": "how to persist state"
}
}
`Returns: The tool's response, proxied from the sub-MCP.
####
luunix.unloadUnload an MCP and free its resources.
Input:
`json
{ "name": "context7" }
`####
luunix.statusShow Luunix server status with full tool schemas for all loaded MCPs.
Returns: Server info, loaded MCP count, total proxied tools, and complete tool schemas.
$3
####
luunix.storeStore content in the memory layer. Returns a summary and ID.
Input:
`json
{
"content": "Large MCP response text...",
"tags": ["github", "issues"],
"sourceMcp": "github",
"sourceTool": "search_issues"
}
`Returns:
`json
{
"success": true,
"id": "a0fba3ec-20d5-4db9-821f-15ec5b95d19c",
"summary": "[~171 tokens, 17 lines] GitHub Issue #456...",
"tokensSaved": 115,
"tags": ["github", "issues"]
}
`####
luunix.recallRecall memories using semantic search.
Input:
`json
{
"query": "database performance issue",
"limit": 5,
"threshold": 0.3,
"tags": ["github"],
"includeContent": false
}
`Returns: Matching memories sorted by similarity score.
####
luunix.compressCompress content to generate a summary without storing it.
Input:
`json
{
"content": "Very long text...",
"maxLength": 200
}
`Returns: Summary with token counts and compression ratio.
####
luunix.forgetDelete memory entries by ID or filter.
Input:
`json
{
"id": "specific-memory-id",
"sourceMcp": "github",
"tags": ["outdated"],
"olderThanDays": 30
}
`####
luunix.memory_statsShow memory store statistics.
Returns:
`json
{
"totalEntries": 42,
"totalTokens": 15000,
"totalTags": 12,
"bySource": { "github": 20, "notion": 22 }
}
`Built-in MCPs
| Name | Description |
|------|-------------|
|
context7 | Get up-to-date documentation and code examples for any library |
| github | GitHub platform interaction - issues, PRs, repos |
| playwright | Browser automation - web scraping, screenshots, testing |
| filesystem | File system access - read and write local files |
| fetch | HTTP requests - fetch web content |Configuration
$3
Stored at
~/.luunix/config.yaml:`yaml
installed:
- context7
- github
custom: {}
autoload: []
memory:
enabled: true
# dbPath: ~/.luunix/memory.db # Optional custom path
# embeddingModel: Xenova/all-MiniLM-L6-v2 # Optional custom model
`$3
The memory layer uses:
- SQLite (
~/.luunix/memory.db) for persistent storage
- Local Embedding (Xenova/all-MiniLM-L6-v2, 384 dimensions) for semantic search
- WAL mode for improved performanceFirst use will download the embedding model (~100MB). Subsequent calls are instant.
$3
Luunix is configured in
~/.claude.json under mcpServers:`json
{
"mcpServers": {
"luunix": {
"command": "node",
"args": ["/path/to/luunix/bin/luunix.js", "serve"],
"type": "stdio"
}
}
}
`Or if installed globally:
`json
{
"mcpServers": {
"luunix": {
"command": "luunix",
"args": ["serve"],
"type": "stdio"
}
}
}
`$3
Luunix is configured in
.cursor/mcp.json in your project directory.$3
You can add custom MCP servers in
~/.luunix/config.yaml`. See Custom MCP Guide for details.- Architecture - System design and module overview
- Custom MCP Guide - How to add your own MCPs
- Troubleshooting - Common issues and solutions
| Scenario | Traditional | Luunix | Savings |
|----------|-------------|--------|---------|
| 10 MCPs × 5 tools | ~7,500 tokens/turn | ~1,500 tokens/turn | 80% |
| 10-turn conversation | ~75,000 tokens | ~16,500 tokens | 78% |
| 100 MCPs available | ~75,000 tokens/turn | ~1,500 tokens/turn | 98% |
| Large MCP response | ~2,000 tokens | ~200 tokens (summary) | 90% |
The key insight: Tool schemas in system prompt are sent every turn. Luunix moves schemas to conversation history (one-time cost). The memory layer further reduces context by replacing large responses with summaries.
MIT