Abstract MCP MCP Server

$npm install -g abstract-mcp
README.md

Prevents large MCP tool responses from consuming your LLM's context window.

Abstract MCP Server

Prevents large MCP tool responses from consuming your LLM's context window. Abstract acts as a smart proxy that caches responses to files and returns compact resource links, and supports direct tool calls and file uploads to avoid context bloat.

Why Abstract?

  • 🚀 Preserves Context Window: Large responses (search results, file contents, API data) don't bloat your conversation
  • 💾 Smart Storage: Responses saved to directories you control with security validation
  • 🔄 Format Conversion: Automatic conversion to CSV, YAML, JSON, Markdown, and more
  • 📂 File Uploads: Inject CSV, JSON, YAML, and other file data into upstream tools without exposing raw content
  • ⚡ Direct Calls: Skip caching when responses are small with plain call_tool for instant results
  • 🔗 Zero Config: Works with your existing MCP servers without changes

Quick Start

  1. Install: npm install -g abstract-mcp (or build from source)

  2. Add to your MCP client config (Claude Desktop, Cursor, Cline, etc):

{
  "mcpServers": {    
    "abstract": {
      "command": "abstract-mcp",
      "args": [
        "/path/to/allowed/storage/dir1",
        "/path/to/allowed/storage/dir2"
      ],
      "env": {
        "APP_CONFIG_PATH": "/path/to/claude/desktop/config.json",
        "ABSTRACT_PROXY_SERVERS": "server1,server2"
      }
    }
  }
}

Example with Existing MCP Servers

Your existing MCP servers work unchanged alongside Abstract. Here's an example configuration:

{
  "mcpServers": {    
    "abstract": {
      "command": "abstract-mcp",
      "args": [
        "/path/to/allowed/storage/dir1",
        "/path/to/allowed/storage/dir2"
      ],
      "env": {
        "APP_CONFIG_PATH": "/path/to/claude/desktop/config.json",
        "ABSTRACT_PROXY_SERVERS": "tavily-mcp"
      }
    },
    "tavily-mcp": {
      "command": "npx",
      "args": ["-y", "tavily-mcp@latest"],
      "env": {
        "TAVILY_API_KEY": "your-tavily-api-key"
      }
    }
  }
}

Config Path Examples

Set APP_CONFIG_PATH to your MCP client's config file:

  • Claude Desktop (macOS): /Users/username/Library/Application Support/Claude/claude_desktop_config.json
  • Claude Desktop (Windows): %APPDATA%\Claude\claude_desktop_config.json
  • Claude Desktop (Linux): ~/.config/Claude/claude_desktop_config.json
  • Cursor: ~/.cursor/config.json
  • Other clients: Check your client's documentation for config location

Abstract reads this config file to find the settings for servers listed in ABSTRACT_PROXY_SERVERS.

Best Practice: Disable Upstream Tools

For more reliable tool calling, consider disabling the direct tools from upstream servers that you've added to Abstract's ABSTRACT_PROXY_SERVERS. This prevents confusion and ensures all calls go through Abstract's enhanced functionality (caching, file handling, format conversion).

Why? When both Abstract and upstream servers expose the same tools, AI assistants may randomly choose between them. By disabling upstream tools, you guarantee consistent behavior through Abstract's proxy.

Core Tools

Tool Purpose When to Use
call_tool_and_store Cache large responses to files Web searches, database queries, file operations
call_tool Direct tool calls in context Small responses, status checks, quick calculations
call_tool_with_file_content Upload file data to tools Bulk imports, config deployments, data processing
list_available_tools Discover upstream tools Before calling any upstream tools
list_tool_details Get tool parameter schemas When you need exact parameter requirements
list_allowed_directories View storage locations Before using custom storage paths

Usage Examples

Basic Response Caching

{
  "server": "tavily-mcp",
  "tool_name": "search", 
  "tool_args": {"query": "bitcoin ETF flows", "max_results": 10}
}

Advanced: Custom Storage & Format

{
  "server": "tavily-mcp",
  "tool_name": "search",
  "tool_args": {"query": "bitcoin ETF flows", "max_results": 10},
  "storage_path": "/Users/you/Documents/research",
  "filename": "bitcoin-etf-analysis",
  "file_format": "csv"
}

File Upload to Tools

{
  "server": "database-mcp",
  "tool_name": "bulk_insert",
  "file_path": "/Users/you/Documents/users.csv",
  "data_key": "records",
  "tool_args": {"table": "users"}
}

File Format Support

Format Use Case Example Output
json Structured data (default) Clean JSON without MCP metadata
csv Spreadsheet analysis Headers + data rows
md Documentation Formatted markdown
yaml Configuration files Key-value structured data
txt Plain text Universal format
html Web content Formatted HTML
xml API responses Structured markup

Tools (6)

call_tool_and_storeCache large responses to files such as web searches, database queries, or file operations.
call_toolDirect tool calls in context for small responses, status checks, or quick calculations.
call_tool_with_file_contentUpload file data to tools for bulk imports, config deployments, or data processing.
list_available_toolsDiscover upstream tools before calling any upstream tools.
list_tool_detailsGet tool parameter schemas when you need exact parameter requirements.
list_allowed_directoriesView storage locations before using custom storage paths.

Environment Variables

APP_CONFIG_PATHrequiredPath to your MCP client's config file (e.g., claude_desktop_config.json).
ABSTRACT_PROXY_SERVERSrequiredComma-separated list of existing MCP servers to proxy through Abstract.

Configuration

claude_desktop_config.json
{
  "mcpServers": {
    "abstract": {
      "command": "abstract-mcp",
      "args": [
        "/path/to/allowed/storage/dir1",
        "/path/to/allowed/storage/dir2"
      ],
      "env": {
        "APP_CONFIG_PATH": "/path/to/claude/desktop/config.json",
        "ABSTRACT_PROXY_SERVERS": "server1,server2"
      }
    }
  }
}

Try it

Search for 'bitcoin ETF flows' using tavily-mcp via Abstract and save the results as a CSV file in my research folder.
List all the tools available from my proxied database-mcp server.
Upload the data from users.csv and use the bulk_insert tool on the database-mcp server to add them to the users table.
Run a search for recent AI news but return a compact resource link instead of the full text to save context space.

Frequently Asked Questions

What are the key features of Abstract MCP?

Caches large tool responses to local files to preserve LLM context window.. Automatic format conversion between JSON, CSV, YAML, Markdown, and more.. Direct tool call support for small responses to skip caching when unnecessary.. File upload capability to inject local data into upstream tools without raw content exposure.. Zero-config compatibility with existing MCP servers via smart proxying..

What can I use Abstract MCP for?

Handling massive search result datasets without hitting token limits.. Converting complex API responses into clean CSV or Markdown files for local analysis.. Performing bulk data imports from local files into remote database tools.. Managing multiple MCP servers through a single interface to ensure consistent response handling..

How do I install Abstract MCP?

Install Abstract MCP by running: npm install -g abstract-mcp

What MCP clients work with Abstract MCP?

Abstract MCP works with any MCP-compatible client including Claude Desktop, Claude Code, Cursor, and other editors with MCP support.

Use Abstract MCP with Conare

Manage MCP servers visually, upload persistent context, and never start from zero with Claude Code & Codex.

Try Free