Skip to main content

Semantic memory for Claude Code sessions

Project description

Megatron

Semantic memory system for Claude Code. Indexes conversation transcripts into project-local vector databases for context persistence across sessions.

Installation

claude mcp add megatron-mcp uvx megatron-mcp

That's it. Restart Claude Code and the memory tools are available.

Alternative: Manual Setup

If you prefer manual configuration, add to your .mcp.json:

{
  "mcpServers": {
    "megatron-mcp": {
      "command": "uvx",
      "args": ["megatron-mcp"]
    }
  }
}

Available Tools

Once configured, Claude Code gains these MCP tools:

Tool Description
memory_search Search past conversations semantically
memory_resume Get context to continue previous work
memory_remember Save important decisions/context
memory_sync Index the current session
memory_stats View memory index statistics

Skills (Slash Commands)

If you copied the skills, these commands become available:

  • /recall <topic> - Search memory for past context
  • /remember - Save something to memory
  • /resume - Continue where you left off
  • /stats - Show memory statistics
  • /sync - Sync current session to memory

CLI Commands

uv run megatron init                    # Initialize project memory
uv run megatron sync                    # Sync from latest transcript
uv run megatron project-search "query"  # Search project memory
uv run megatron resume                  # Get resume context
uv run megatron project-stats           # Show memory stats

Project Structure

When used, each project gets a .megatron/ directory containing:

  • index/ - ChromaDB vector database
  • state.json - Session state snapshots
  • queue/ - Pending sync items

How It Works

  1. Parses Claude Code JSONL transcripts from ~/.claude/projects/
  2. Groups messages into user-assistant exchanges
  3. Indexes chunks into ChromaDB with semantic embeddings
  4. Exposes search/remember/sync tools via MCP protocol

See CLAUDE.md for detailed architecture.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

megatron_mcp-0.1.0.tar.gz (28.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

megatron_mcp-0.1.0-py3-none-any.whl (31.6 kB view details)

Uploaded Python 3

File details

Details for the file megatron_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: megatron_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 28.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for megatron_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 1f8dd202db8677a1027c48f3d69b3e9f1bbc968f40f49fc3e1ad5f552c92906e
MD5 7746ef5de45bf34c18ac4a90f1c47a79
BLAKE2b-256 8e4d4c1c59099bd49053080b735b8adddf9efa7bd1c1b89a37e47f4717776536

See more details on using hashes here.

File details

Details for the file megatron_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: megatron_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 31.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for megatron_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 21f9836c21bf1342cc5fb98e45239b7499ed0d72c92dbda3152bfb1a0e7109d1
MD5 4938b4a513c64351c1b6012b8cec4186
BLAKE2b-256 00a1035b9188729073c9bf7e925f3d927b5d704cd21cdd25ad6fd2cda5cfa854

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page