context-savvy-mcp

A high-performance Model Context Protocol server that transforms Claude Desktop into a memory-enabled AI assistant with persistent context, secure command execution, and intelligent workflow automation.

https://github.com/baebu/context-savvy-mcp

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.9%) to scientific vocabulary

Keywords

ai-assistant anthropic claude claude-desktop context-management developer-tools mcp nodejs persistent-memory productivity semantic-search sqlite task-management typescript workflow-automation
Last synced: 4 months ago · JSON representation ·

Repository

A high-performance Model Context Protocol server that transforms Claude Desktop into a memory-enabled AI assistant with persistent context, secure command execution, and intelligent workflow automation.

Basic Info
  • Host: GitHub
  • Owner: Baebu
  • License: mit
  • Language: TypeScript
  • Default Branch: main
  • Homepage:
  • Size: 1.75 MB
Statistics
  • Stars: 3
  • Watchers: 0
  • Forks: 0
  • Open Issues: 3
  • Releases: 0
Topics
ai-assistant anthropic claude claude-desktop context-management developer-tools mcp nodejs persistent-memory productivity semantic-search sqlite task-management typescript workflow-automation
Created 7 months ago · Last pushed 6 months ago
Metadata Files
Readme Changelog Contributing Funding License Code of conduct Citation Security Support Governance Roadmap

README.md

Context Savvy MCP 🧠✨

The AI assistant's best friend - because even Claude needs a good memory

The Problem That Wouldn't Go Away

You know that feeling when you're deep in a coding session with Claude, everything's flowing perfectly, and then... 💥 Context limit hit. Your conversation gets truncated. The AI forgets what you were working on. All that beautiful, collaborative momentum? Gone.

Or maybe you're the type who switches between projects constantly (guilty 🙋‍♂️), and every time you start a new chat, you have to re-explain your entire setup, your file structure, your preferences, your... everything.

What if your AI assistant could remember? Not just remember, but truly understand your projects, maintain context across conversations, and actually help you stay organized?

That's exactly why this exists.

What This Thing Actually Does

Context Savvy MCP is a turbocharged memory system for Claude Desktop that turns your AI assistant into something that feels almost... permanent. Instead of starting from scratch every conversation, Claude can:

  • Remember everything across chat sessions (your projects, preferences, ongoing work)
  • Execute commands safely (because sometimes you need to actually do things, not just talk about them)
  • Manage files intelligently (read, write, search, organize - all with context awareness)
  • Learn from your patterns (it gets smarter about how you work over time)
  • Keep itself organized (autonomous maintenance, cleanup, optimization)

Think of it as giving Claude a persistent workspace and a really, really good memory.

Tech Stack 🛠️

Built with modern, reliable technologies:

  • TypeScript - Type-safe development with excellent IDE support
  • Node.js - High-performance JavaScript runtime
  • Inversify.js - Dependency injection container for clean, modular architecture
  • better-sqlite3 - Fast, synchronous SQLite database operations

✨ Key Features & Performance

🚀 Token Efficiency (96% Reduction)

  • compact_search - Intelligent search with massive token savings
  • precision_edit - Surgical code changes with validation
  • compression_algorithms - Auto-compress large contexts (hybrid algorithm)
  • token_budget_optimization - Maintain <80% usage automatically

🧠 Intelligence & Automation

  • get_project_overview - Comprehensive codebase analysis with technology detection
  • autonomous_monitoring - Self-managing system with intelligent thresholds
  • semantic_search_context - Find related solutions with 0.7+ similarity
  • adaptive_workflow_creation - Learn and automate your patterns

🛡️ Safety & Security

  • security_diagnostics - Auto-expand safe zones and validate access
  • recycle_file - Safe file deletion with recovery options
  • backup_redundancy - Multiple backup strategies for critical operations
  • panic_storage - Emergency state preservation at 95% token usage

📊 Project Management

  • create_task - Advanced task tracking with genealogy and relationships
  • workspace_management - Multi-project support with intelligent switching
  • cascade_storage - Related contexts with automatic relationships
  • integration_test - Comprehensive system validation

These tools work together to create a seamless, context-aware development experience with industry-leading performance.

The Magic in Action 🎩

Scenario 1: Project Continuity

``` You (in Chat #1): "Help me refactor this React component..." [Work gets done, chat ends naturally]

You (in Chat #47, two weeks later): "Hey, what was I working on?" Claude: "You were refactoring the UserProfile component. You'd gotten the props interface done and were working on the state management. Should we continue where we left off?" ```

Scenario 2: Context-Aware File Operations

``` You: "Find all the TODO comments in my project" Claude: [Searches across your entire codebase] "Found 23 TODOs. The urgent ones are in auth.ts and database.service.ts. Want me to show you those first?"

You: "Fix the auth one" Claude: [Opens file, understands context, makes intelligent suggestions] "I see the issue - you're missing error handling in the token validation. Here's a fix..." ```

Scenario 3: Learning Your Workflow

``` After a few weeks of use...

Claude: "I noticed you always run tests after refactoring. Should I go ahead and run them now?" You: "Yes! And check the coverage while you're at it." Claude: [Executes tests, analyzes coverage, provides detailed report] "All green! Coverage increased by 2.3%. The new code is well-tested." ```

Why This Exists (The Real Story)

I got tired of explaining my setup to Claude every. single. time.

I'm a developer who juggles multiple projects, has strong opinions about code organization, and relies heavily on AI assistance for the tedious stuff. But every new conversation meant starting over - re-explaining my file structure, my preferences, my coding standards, what I was working on.

So I built this. Initially just for me, with too much coffee and stubborn determination.

Turns out, having an AI assistant with persistent memory and the ability to actually do things (not just suggest them) changes everything. Conversations flow naturally. Work gets done faster. Context never gets lost.

The honest truth: This started as a personal tool and grew into something that might actually be useful to other developers. It works well for me, but I'm curious if it resonates with anyone else.

Quick Reality Check ✋

What definitely works:

  • Persistent context across Claude conversations
  • Safe command execution with security boundaries
  • Intelligent file operations and project management
  • Task tracking and workflow automation
  • Most of the daily-use features I depend on

What might be quirky:

  • The autonomous monitoring (new, needs more testing)
  • Complex task workflows (works, but UX could be better)
  • Performance with massive projects (it's good, but not tested at enterprise scale)
  • Setup process (functional, but could be smoother)

What I'm genuinely curious about:

  • Is this actually useful to other developers?
  • Are there better patterns I should be using?
  • Should this be one big server or split into smaller focused ones?
  • What features are missing that would make this indispensable?

🚀 Quick Start - Optimized Configuration

Want the best performance immediately? Copy this to your Claude Desktop preferences:

```

Context-Savvy Server - Optimal Setup

Token efficiency: Use compactsearch for 96% token reduction Auto-monitoring: enableautonomousmonitoring for self-management Smart search: Progressive detail (summary → expand → full context) Precision editing: precisionedit for surgical code changes Project intelligence: getprojectoverview for comprehensive analysis Safe operations: Automatic backups and safe zone management ```

💥 Performance Boost: Users report 96% reduction in token usage and 10x faster development workflows with optimal configuration.

Complete Claude Desktop Setup Guide - Detailed configuration for maximum productivity

| Without Optimization | With Optimized Setup | |----------------------|---------------------| | Manual file operations | Intelligent batch processing | | Token usage at limits | <80% usage maintained | | Repetitive searches | Smart path automation | | Risk of data loss | Safe recycle system | | Start from scratch each chat | Persistent context and memory |


Getting Started (The Actually Quick Version)

Prerequisites: Node.js 18+, Claude Desktop, and 5 minutes

```bash

Clone and setup

git clone https://github.com/Baebu/context-savvy-mcp.git cd context-savvy-mcp npm install

One-command setup (handles everything)

npm run quick-setup ```

The setup script will:

  • Build the project ⚙️
  • Create example configurations 📝
  • Run tests to make sure everything works ✅
  • Show you exactly what to add to Claude Desktop 📋

Add to Claude Desktop config:

json { "mcpServers": { "context-server": { "command": "node", "args": ["/path/to/your/context-savvy-mcp/dist/index.js"], "env": { "MCP_SERVER_CONFIG_PATH": "/path/to/your/context-savvy-mcp/config/server.yaml" } } } }

Restart Claude Desktop, and you're off to the races.

What You Can Do With It

Memory & Context

  • Store anything: Project notes, decisions, preferences, todo lists
  • Smart search: Natural language queries across all your stored context
  • Relationship mapping: Connect related ideas, files, and projects automatically
  • Learning: The system gets better at understanding your work patterns

File & Project Management

  • Intelligent reading: Handles large files, multiple formats, smart truncation
  • Context-aware editing: Find/replace with understanding of your code patterns
  • Project analysis: Comprehensive overviews with actionable insights
  • Workspace organization: Multiple project support with smart switching

Secure Automation

  • Safe command execution: Whitelist-based security with path restrictions
  • Process management: Monitor and control background tasks
  • System health: Real-time performance monitoring and optimization
  • Backup management: Automatic file versioning and recovery

Task & Workflow Management

  • Smart task creation: Context-aware task tracking with automatic tagging
  • Workflow automation: Learn and automate your common patterns
  • Progress tracking: Persistent task state across conversations
  • Template system: Reusable workflows for common project types

The Architecture (For Fellow Code Nerds)

Built with clean architecture principles because I have opinions about code organization:

src/ ├── core/ # Pure business logic, no dependencies ├── application/ # Use cases, services, workflows ├── infrastructure/ # Database, file system, external APIs └── presentation/ # MCP protocol interface

Tech stack: TypeScript, SQLite, TensorFlow.js (for embeddings), Dependency Injection, way too much attention to detail.

Design philosophy: Make it work first, make it elegant second, make it fast third. Currently somewhere between steps 2 and 3.

Security (Because I'm Paranoid)

This server operates on a "trust but verify" model, configured entirely by you. There are no runtime pop-ups or consent dialogs; security is handled by your config/server.yaml file.

  • Command Whitelisting: Only commands explicitly listed in your configuration's allowedCommands can be executed. Everything else is blocked by default.
  • Path Sandboxing (Safe Zones): File operations are restricted to directories you define in safezones. By default, this is "recursive," meaning subdirectories are also accessible.
  • Restricted Zones: The server maintains a list of sensitive system paths (/etc, C:\Windows, etc.) and project paths (.git, .ssh) that are always blocked, even if they fall within a safe zone.
  • Input Validation: All file paths and command arguments are sanitized to prevent common injection and path traversal attacks.

The default config is locked down tight. You explicitly allow what you want, giving you full control over the server's capabilities.

Want to Help? 🤝

I'm genuinely looking for:

  • Testing: Try it with your projects, break it, tell me what happens
  • Code review: I have blind spots, you probably see them
  • Ideas: What features would make this indispensable for you?
  • Documentation: If something doesn't make sense, let me know
  • Real-world feedback: Does this actually solve problems you have?

Good first contributions:

  • Try the setup process and document any friction
  • Test with different project types and report what works/doesn't
  • Add support for your favorite tools or languages
  • Improve error messages and UX
  • Write tests for edge cases I missed

To contribute:

```bash

Fork on GitHub, then:

git clone https://github.com/YOUR_USERNAME/context-savvy-mcp.git cd context-savvy-mcp npm install npm test # Make sure everything works npm run dev # Start hacking ```

Configuration & Customization

The system is controlled by config/server.yaml. Here's what you can tune:

```yaml

Security boundaries

security: allowedCommands: ['ls', 'git status', 'npm test'] safezones: ['~/projects/my-web-app', './workspace']

Database and storage

database: path: './data/context.db' backupInterval: 360 # In minutes. 0 to disable.

Semantic search features

semanticSearch: enabled: true model: 'universal-sentence-encoder'

Autonomous behaviors

autonomous: enabled: true monitoring: compressionThreshold: 10240 # In bytes. Auto-compress contexts larger than this. panicThreshold: 0.95 # Trigger emergency state save at 95% of context window. ```

Run npm run config for a web-based configuration UI. For a full breakdown of options, see the Installation Guide.

Performance & Scaling

Tested with:

  • Projects up to 10,000 files
  • Context databases up to 1GB
  • Concurrent conversations (works, but not heavily tested)
  • Long-running sessions (months of continuous use)

Optimization features:

  • Intelligent compression and archiving
  • Semantic deduplication
  • Background maintenance
  • Connection pooling and caching

📚 Documentation & Setup

Essential Guides:

Quick Links:

The Honest FAQ

Q: Is this production-ready? A: For personal use? Absolutely. For enterprise? Probably needs more testing and hardening.

Q: Why not use [existing solution]? A: I tried. Nothing gave me the exact combination of persistence, security, and workflow integration I wanted.

Q: Will this slow down Claude? A: In my experience, no. The context loading is fast, and having persistent memory actually makes conversations more efficient.

Q: What if I find bugs? A: Please report them! I use this daily, so bugs get fixed quickly.

Q: Can I use this for commercial projects? A: MIT license, so yes. Just don't blame me if something breaks.

What's Next

Near-term roadmap:

  • Better onboarding and setup experience
  • More intelligent autonomous behaviors
  • Plugin system for custom tools
  • Improved performance monitoring
  • Better mobile/web interface options

Longer-term possibilities:

  • Multi-user support
  • Cloud synchronization
  • Advanced workflow automation
  • Integration with more development tools
  • AI model fine-tuning on your patterns

Support & Community

💙 Support This Project

This project is a labor of love, built with too much coffee and stubborn determination. If Context Savvy MCP makes your AI interactions better, consider supporting its development:

  • Buy me a coffee on Ko-fi - Keep the caffeine-fueled coding sessions going
  • Star the repository - It genuinely motivates continued development
  • 🐛 Report bugs - Help make it better for everyone
  • 💡 Share ideas - Your feedback shapes the roadmap
  • 🤝 Contribute code - Join the development effort

Every cup of coffee, every star, every contribution helps keep this project alive and growing. Thank you for being part of the journey!

License & Acknowledgments

MIT License - do whatever you want with it.

Built on the shoulders of:


Made with ❤️ and stubborn determination

If this makes your AI interactions even 10% better, it was worth building.

Owner

  • Login: Baebu
  • Kind: user

Citation (CITATION.cff)

cff-version: 1.2.0
title: 'Context Savvy MCP'
message: 'If you use this software, please cite it as below.'
type: software
authors:
  - name: 'Baebu'
    email: 'bae.bu.8@gmail.com'

repository-code: 'https://github.com/Baebu/context-savvy-mcp'
url: 'https://github.com/Baebu/context-savvy-mcp'
abstract: 'A high-performance Model Context Protocol server that transforms Claude Desktop into a memory-enabled AI assistant with persistent context, secure command execution, and intelligent workflow automation.'
keywords:
  - context
  - server
  - typescript
  - nodejs
  - mcp
  - model-context-protocol
  - claude
  - claude-desktop
  - ai-assistant
  - semantic-search
  - persistent-memory
license: MIT # Update this if you're using a different license
version: '2.0.1'
date-released: '2025-06-17'

GitHub Events

Total
  • Watch event: 3
  • Delete event: 4
  • Issue comment event: 17
  • Push event: 3
  • Pull request event: 8
  • Create event: 5
Last Year
  • Watch event: 3
  • Delete event: 4
  • Issue comment event: 17
  • Push event: 3
  • Pull request event: 8
  • Create event: 5

Dependencies

.github/workflows/auto-assign.yml actions
  • kentaro-m/auto-assign-action v2.0.0 composite
  • pozil/auto-assign-issue v1.12.0 composite
.github/workflows/ci.yml actions
  • actions/cache v4 composite
  • actions/checkout v4 composite
  • actions/setup-node v4 composite
  • codecov/codecov-action v4 composite
  • trufflesecurity/trufflehog main composite
.github/workflows/codeql.yml actions
  • actions/checkout v4 composite
  • actions/setup-node v4 composite
  • github/codeql-action/analyze v3 composite
  • github/codeql-action/init v3 composite
.github/workflows/stale.yml actions
  • actions/stale v9 composite
Dockerfile docker
  • node 20-alpine build
docker-compose.yml docker
package-lock.json npm
  • 753 dependencies
package.json npm
  • @jest/globals 29.7.0 development
  • @types/better-sqlite3 ^7.6.13 development
  • @types/convict ^6.1.6 development
  • @types/express ^4.17.21 development
  • @types/jest ^29.5.14 development
  • @types/lru-cache ^7.10.10 development
  • @types/node ^20.11.5 development
  • @types/node-cron ^3.0.11 development
  • @types/uuid ^9.0.7 development
  • @types/ws ^8.18.1 development
  • @typescript-eslint/eslint-plugin ^7.18.0 development
  • @typescript-eslint/parser ^7.18.0 development
  • cross-env ^7.0.3 development
  • eslint ^8.57.1 development
  • eslint-config-prettier ^9.1.0 development
  • eslint-plugin-prettier ^5.5.0 development
  • husky ^9.0.11 development
  • jest ^29.7.0 development
  • lint-staged ^15.2.0 development
  • prettier ^3.3.3 development
  • rimraf ^5.0.5 development
  • ts-jest ^29.3.4 development
  • ts-node ^10.9.2 development
  • tsconfig-paths ^4.2.0 development
  • tsx ^4.7.0 development
  • typescript ^5.8.3 development
  • @modelcontextprotocol/sdk ^1.12.3
  • @tensorflow/tfjs-node ^4.15.0
  • better-sqlite3 ^11.10.0
  • convict ^6.2.4
  • fastmcp ^2.0.0
  • glob ^10.3.10
  • inversify ^6.0.2
  • lru-cache ^10.0.0
  • node-cron ^3.0.3
  • p-queue ^8.0.1
  • pino ^9.7.0
  • pino-pretty ^13.0.0
  • reflect-metadata ^0.2.1
  • stream-json ^1.8.0
  • uuid ^9.0.1
  • winston ^3.17.0
  • ws ^8.18.2
  • yaml ^2.3.4
  • zod ^3.24.3
  • zod-to-json-schema ^3.24.5