MCPMake
An MCP (Model Context Protocol) server for managing and running Python scripts with LLM-extracted schemas - like make
, but smarter.
Features
Automatic Schema Extraction: Uses LLMs (Claude Sonnet 4 or GPT-4.1) to analyze Python scripts and extract argument schemas
Script Registry: Store and manage multiple scripts with metadata
Input Validation: Validates arguments against JSON Schema before execution
Execution History: Tracks all script runs with full output logs
Environment Variables: Pass custom env vars per execution
Flexible Execution: Custom Python interpreters, timeouts, and output truncation
Update & Re-analyze: Refresh script schemas when code changes
Installation
Configuration
Set up API keys
You'll need an API key for either Anthropic or OpenAI (or both):
Add to MCP settings
Add the server to your MCP client configuration (e.g., Claude Desktop):
Usage
1. Register a Script
2. List Scripts
3. Get Script Info
4. Run a Script
5. View Run History
6. Update Script Schema
7. Delete Script
Data Storage
MCPMake stores data in ~/.mcpmake/
:
How It Works
Registration: When you register a script, MCPMake:
Reads the script file
Sends it to an LLM (Claude Sonnet 4 or GPT-4.1)
Extracts a JSON Schema describing the script's arguments
Extracts a description from docstrings/comments
Stores everything in
scripts.json
Execution: When you run a script:
Validates your arguments against the stored JSON Schema
Checks if the script file still exists
Builds command-line arguments from your input
Runs the script with specified Python interpreter and env vars
Captures stdout/stderr with timeout protection
Saves full output to a log file
Returns truncated output (first N lines)
Logs execution details to history
History: All runs are logged with:
Timestamp, arguments, exit code
Execution time
Full output file path
Environment variables used
Example Python Scripts
MCPMake works best with scripts that use:
argparse
click
Simple functions
Requirements
Python 3.10+
MCP SDK
Anthropic SDK (for Claude)
OpenAI SDK (for GPT)
jsonschema
License
MIT
This server cannot be installed
local-only server
The server can only run on the client's local machine because it depends on local resources.
Enables management and execution of Python scripts with automatic LLM-extracted argument schemas and validation. Provides script registry, execution history, and intelligent argument parsing like make but for Python scripts.