kratos-mcp

ceorkm/kratos-mcp

3.4

If you are the rightful owner of kratos-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

Kratos MCP is a memory system designed for AI coding tools, ensuring that AI retains project-specific knowledge across sessions.

๐Ÿ›๏ธ Kratos MCP

Memory System for AI Coding Tools

npm version License: MIT MCP Compatible TypeScript

Never explain your codebase again. Let AI remember everything.

๐ŸŒ kratos-mcp.com โ€ข Installation โ€ข Quick Start โ€ข Features โ€ข Documentation โ€ข Contributing


๐ŸŽฏ Why Kratos?

After building 30+ production apps with AI, we discovered a critical problem: AI tools forget everything between sessions. You explain your architecture, your patterns, your decisionsโ€”and tomorrow, you explain it all again.

Kratos MCP solves this with the Four Pillars Frameworkโ€”a battle-tested system that gives AI perfect memory of your project.

โœจ Features

๐Ÿ”’ 100% Project Isolation

Each project gets its own SQLite database. No cross-contamination. Ever.

๐ŸŽฏ 95.8% Context Accuracy

Smart retrieval engine that knows exactly what memories matter for your current task.

โšก Zero Configuration

Auto-detects projects via git, package.json, or directory structure. Just install and code.

๐ŸŒ Universal Protocol

Works with Claude, Cursor, Windsurf, Continueโ€”any MCP-compatible tool.

๐Ÿš€ Installation

# Install globally
npm install -g kratos-mcp

# Or run directly with npx (no installation required)
npx kratos-mcp

# Or install as a dependency
npm install kratos-mcp

๐ŸŽฌ Quick Start

1๏ธโƒฃ Configure Your AI Tool

Claude Desktop

Add to your Claude Desktop config file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/claude/claude_desktop_config.json
{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}

Or if you have it installed globally:

{
  "mcpServers": {
    "kratos": {
      "command": "kratos-mcp",
      "args": []
    }
  }
}
Claude Code (Anthropic's VSCode Extension)

Run this command in your terminal:

claude mcp add kratos -- npx --yes kratos-mcp@latest

Or for global installation:

# First install globally
npm install -g kratos-mcp@latest

# Then add to Claude Code
claude mcp add kratos -- kratos-mcp

See Claude Code MCP docs for more info.

Cursor

Add to .cursor/mcp_config.json in your project root:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Windsurf (Codeium)

Add to ~/.windsurf/mcp_config.json:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Cline (VSCode Extension)
  1. Open VSCode Command Palette (Cmd+Shift+P)
  2. Run "Cline: Edit MCP Settings"
  3. Add server configuration:
{
  "kratos": {
    "command": "npx",
    "args": ["kratos-mcp"]
  }
}
BoltAI
  1. Open BoltAI Settings
  2. Navigate to MCP Servers
  3. Add new server with:
{
  "name": "kratos",
  "command": "npx",
  "args": ["kratos-mcp"]
}
Augment Code

Add to Augment settings under MCP configuration:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Roo Code (VSCode Extension)

Add to .roo/config.json:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Zencoder

Configure in Zencoder settings:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Amazon Q Developer

Add to Q Developer settings:

{
  "mcpServers": [
    {
      "name": "kratos",
      "command": "npx",
      "args": ["kratos-mcp"]
    }
  ]
}
Qodo Gen

Add to Qodo configuration:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
JetBrains AI Assistant
  1. Open Settings โ†’ Tools โ†’ AI Assistant
  2. Add MCP server:
{
  "kratos": {
    "command": "npx",
    "args": ["kratos-mcp"]
  }
}
Warp Terminal

Add to ~/.warp/mcp_config.json:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Opencode

Configure in Opencode settings:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Copilot Coding Agent

Add to Copilot configuration:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Kiro

Add to Kiro settings:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
OpenAI Codex

Configure in Codex settings:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
LM Studio

Add to LM Studio MCP configuration:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Perplexity Desktop

Add to Perplexity settings:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Continue.dev

Add to ~/.continue/config.json:

{
  "models": [...],
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["kratos-mcp"]
    }
  }
}
Zed

Add to ~/.config/zed/settings.json:

{
  "assistant": {
    "mcpServers": {
      "kratos": {
        "command": "npx",
        "args": ["kratos-mcp"]
      }
    }
  }
}
VS Code (Generic MCP Extensions)

For any MCP-compatible VS Code extension, add to .vscode/settings.json:

{
  "mcpServers": {
    "kratos": {
      "command": "npx",
      "args": ["--yes", "kratos-mcp@latest"]
    }
  }
}
Other MCP Tools

Kratos works with any tool supporting the Model Context Protocol. The general format is:

{
  "command": "npx",
  "args": ["kratos-mcp"]
}

Check your tool's documentation for specific MCP server configuration location.

2๏ธโƒฃ Start Using Kratos

// Your AI now remembers:
// โœ“ Your authentication patterns
// โœ“ Your API structure  
// โœ“ Your component architecture
// โœ“ Your coding standards
// โœ“ Every decision you've made

๐Ÿ›๏ธ The Four Pillars Framework

Based on real-world experience building 30+ production apps with AI, Kratos implements the Four Pillars of effective AI development:

๐Ÿ“‹ Pillar 1: PRD (Product Requirements)

"What Matters"

Define not just what to build, but how AI should build it:

  • Complete page paths and user flows
  • API endpoints and data structures
  • Edge cases and integration points
  • UI/UX references and patterns

๐ŸŽฏ Pillar 2: Prompt Templates

"What to Do"

Reusable task templates that work perfectly with your codebase:

  • Role & stack definition
  • Clear scope constraints
  • File context specifications
  • Verification steps

๐Ÿง  Pillar 3: Context Retrieval

"What to Inject"

Smart injection of relevant memories based on your current task:

  • Automatic pattern matching
  • Path-based relevance scoring
  • Recency weighting
  • Semantic clustering

๐Ÿ’พ Pillar 4: Memory Storage

"What to Save"

Permanent knowledge base that grows with your project:

  • Architecture decisions
  • Bug fixes and solutions
  • Feature implementations
  • Performance optimizations

๐Ÿ› ๏ธ Core Tools

ToolDescriptionExample
memory_saveStore important project knowledge
// Save authentication pattern
memory_save({
  title: "JWT Auth Flow",
  content: "Tokens in httpOnly cookies...",
  tags: ["auth", "security"]
})
memory_searchRetrieve relevant memories
// Get auth-related memories
memory_search({
  query: "authentication",
  k: 5
})
prd_updateDefine project requirements
// Update PRD section
prd_update({
  feature: "api_structure",
  content: "RESTful endpoints..."
})
prompt_buildCreate reusable prompts
// Build structured prompt
prompt_build({
  goal: "Create React component",
  role: "Senior React Developer"
})

๐Ÿ“Š How It Works

graph LR
    A[Your Code] --> B[Kratos MCP]
    B --> C{Project Detection}
    C --> D[Project Database]
    D --> E[Memory Storage]
    D --> F[Context Broker]
    F --> G[AI Tool]
    G --> H[Perfect Context]

๐Ÿ”ฌ Under the Hood

  • SQLite + FTS5: Lightning-fast full-text search
  • Smart Scoring: Path matching + recency + importance
  • Auto-detection: Git, package.json, or directory-based
  • Secure: All data stays local, no external calls

๐Ÿ“ˆ Performance

MetricValue
Context Accuracy95.8%
Memory Retrieval< 10ms
Project Switch< 100ms
Storage Overhead~2MB per project

๐Ÿ—‚๏ธ Memory Structure

.kratos/
โ”œโ”€โ”€ projects/
โ”‚   โ”œโ”€โ”€ project-id-1/
โ”‚   โ”‚   โ”œโ”€โ”€ memories.db      # SQLite database
โ”‚   โ”‚   โ”œโ”€โ”€ prd.yml          # Product requirements
โ”‚   โ”‚   โ””โ”€โ”€ prompts/          # Reusable templates
โ”‚   โ””โ”€โ”€ project-id-2/
โ”‚       โ””โ”€โ”€ ...
โ””โ”€โ”€ config.yml                # Global configuration

๐ŸŽฎ Live Demo

// User: "Explain the auth system"
// 
// Kratos automatically retrieves:
// โœ“ JWT implementation from 2 weeks ago
// โœ“ Middleware configuration from last month  
// โœ“ User model structure from initial setup
// โœ“ Security decisions from PRD
//
// AI Response: "Your auth uses JWT with refresh tokens 
// stored in httpOnly cookies. The middleware validates 
// tokens on protected routes at /api/middleware/auth.ts:42..."

๐Ÿค Contributing

We welcome contributions! See for guidelines.

# Clone the repo
git clone https://github.com/ceorkm/kratos-mcp.git

# Install dependencies
npm install

# Run in development
npm run dev

๐Ÿ“„ License

MIT ยฉ 2025 Kratos MCP Contributors

๐Ÿ™ Acknowledgments

Built on the Model Context Protocol by Anthropic.

Inspired by the Four Pillars Framework and real-world experience building production apps with AI.


Built for developers who value their time.

Report Bug โ€ข Request Feature โ€ข Documentation