cablecar
An MCP server for LLM-powered clinical research
claude mcp add --transport stdio aartiksarma-cablecar-mcp-server python server/main.py
How to use
CableCar v2 is a privacy-first MPC (Minimal MCP) data server designed to let researchers run analyses on sensitive clinical data without exposing raw patient information. The server exposes four core MCP tools: get_schema, load_data, query_cohort, and execute_analysis. These tools are intended to be invoked by Claude Code skills and subagents through standardized MCP interfaces. Outputs are sanitized by the built-in PrivacyGuard before any data leaves the server, ensuring patient data never directly leaves the local environment. When you start the server, you can load your data schema, bring in data files, define cohorts, and execute analyses or generate reproducible code templates for downstream CLIF-compatible environments. The architecture emphasizes reproducible research with privacy safeguards, enabling causal reasoning, descriptive statistics, regression analyses, survival modeling, and code generation via templated Python and R scripts.
To use CableCar effectively, begin by loading a schema with get_schema and then use load_data to ingest your datasets (CSV/Parquet). Construct cohorts with query_cohort to define inclusion/exclusion criteria, then run execute_analysis to perform the statistical analyses or generate reproducible analysis scripts. The system integrates a causal framework (DAGs, backdoor criteria, adjustment sets) and a robust reporting suite (STROBE/TRIPOD+AI checklists) to support transparent, auditable research workflows. The 15 skills under Claude's context provide guided steps—from new-study design to data export—without exposing raw data to the AI components.
How to install
Prerequisites:
- Python 3.8+ installed on your machine
- Git
- Optional: a virtual environment manager (venv, conda)
-
Clone the repository: git clone https://github.com/aartiksarma-cablecar-mcp-server.git cd cablecar
-
Create and activate a virtual environment (recommended): python -m venv venv
Windows
venv\Scripts\activate
macOS/Linux
source venv/bin/activate
-
Install Python dependencies: pip install -r requirements.txt
-
Prepare environment variables (optional):
- MASKING_POLICY: description of privacy masking policy (e.g., strict, moderate)
- DATA_DIR: path to data directory (default may be local ./data)
- LOG_LEVEL: INFO|DEBUG|WARNING for server logs
-
Run the MCP server: python server/main.py
-
Optional: run tests or sample pipelines if provided in the repo to verify local functionality.
Additional notes
Tips and caveats:
- The server processes raw data entirely within memory; all outputs pass through PrivacyGuard to redact or suppress sensitive information before leaving the process.
- Ensure data loading uses compatible schemas defined in the schema/ directory to avoid runtime errors.
- Review the privacy policy and PHI detectors (PHI types like SSN, MRN, emails, etc.) to configure appropriate data protection levels.
- When generating reproducible code via codegen/templates, verify the target environment (Python/R versions and package versions) to ensure compatibility.
- If you encounter issues with data loading, inspect the audit trail under privacy/audit.py for an immutable JSONL log of actions and potential policy violations.
Related MCP Servers
mcp-vegalite
MCP server from isaacwasserman/mcp-vegalite-server
github-chat
A Model Context Protocol (MCP) for analyzing and querying GitHub repositories using the GitHub Chat API.
nautex
MCP server for guiding Coding Agents via end-to-end requirements to implementation plan pipeline
pagerduty
PagerDuty's official local MCP (Model Context Protocol) server which provides tools to interact with your PagerDuty account directly from your MCP-enabled client.
futu-stock
mcp server for futuniuniu stock
mcp -boilerplate
Boilerplate using one of the 'better' ways to build MCP Servers. Written using FastMCP