RefineDataMCP
Provides data analysis capabilities using DuckDB, enabling extraction of descriptive statistics from large CSV and Parquet files without loading them into memory.
Allows querying PostgreSQL databases directly via DuckDB, enabling out-of-core SQL queries on massive datasets.
Allows querying SQLite databases directly via DuckDB, enabling out-of-core SQL queries on massive datasets.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@RefineDataMCPanalyze the sales data from sales.csv"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
RefineData MCP Server
RefineData MCP is a Model Context Protocol server that gives AI agents (Claude Code, Cursor, ChatGPT) a toolbox for data preparation, anonymization, analysis, and visualization. It leans on Polars and DuckDB so the heavy tools stream data out-of-core instead of loading everything into RAM.
Tools
Analysis & Profiling
Tool | Purpose | Engine | Scales beyond RAM? |
| Row counts, schema, numeric stats | DuckDB | ✅ out-of-core |
| Per-column null rates, unique counts, sample values, date ranges | DuckDB | ✅ out-of-core |
| Preview N rows (head/tail/random/stratified) | DuckDB | ✅ out-of-core |
| Percentiles, skew, correlations | Polars (lazy/streaming) | ◐ streamed |
| Check columns and types against an expected schema | DuckDB | ✅ out-of-core |
Cleaning & Transformation
Tool | Purpose | Engine | Scales beyond RAM? |
| Dedup + missing-value handling | Polars (lazy/streaming) | ◐ streamed |
| CSV ↔ Parquet ↔ JSONL with compression options | Polars (lazy/streaming) | ◐ streamed |
| Join two datasets on key columns | DuckDB | ✅ out-of-core |
| IQR or z-score outlier extraction | DuckDB | ✅ out-of-core |
ML / NLP
Tool | Purpose | Engine | Scales beyond RAM? |
| Drop toxic rows (batched inference) | Detoxify | ✗ in-memory |
| Mask PII in text columns | Presidio NLP | ✗ in-memory |
Generation & Database
Tool | Purpose | Engine | Scales beyond RAM? |
| Schema-driven synthetic dataset generation | Polars | ✗ in-memory |
| Run SQL on PostgreSQL/SQLite → file | DuckDB | ✅ out-of-core |
| Extract the main HTML table from a URL | requests + BeautifulSoup | ✗ in-memory |
Session Management
Tool | Purpose |
| Load a file into the in-process cache, returns a handle |
| Free a cached dataset from memory |
| List all currently loaded dataset handles |
Visualization
Tool | Purpose | Engine | Scales beyond RAM? |
| Heatmap/scatter/boxplot/bar → image | Matplotlib/Seaborn | ✗ in-memory |
◐ = the streamable parts of the plan run in chunks; the result is materialized. The PII/toxicity/scraping/viz tools load the working set into memory by design.
Related MCP server: Quack MCP
Installation
Core install (only analyze_data + query_db) is lightweight. Heavy features are
optional extras, so you don't pull in PyTorch/spaCy/Matplotlib unless you need them.
python -m venv venv && . venv/Scripts/activate # Windows
# source venv/bin/activate # Linux/Mac
pip install -e . # core (DuckDB + Polars)
pip install -e ".[scraping]" # + web scraper
pip install -e ".[viz]" # + visualizer
pip install -e ".[pii]" # + PII anonymizer
pip install -e ".[toxicity]" # + toxicity filter
pip install -e ".[all]" # everythingIf you call a tool whose extra isn't installed, it returns a clear message telling you
which pip install to run.
The PII tool also needs a spaCy model:
python -m spacy download en_core_web_smSupported Python: 3.11+ for core/
[scraping]/[viz]; the[pii]/[toxicity]extras are pinned to 3.11–3.12 until spaCy/PyTorch ship newer wheels.
Configuration for MCP clients
Once published, run with zero local setup via uv —
no clone, no venv:
{
"mcpServers": {
"RefineDataMCP": {
"command": "uvx",
"args": ["--from", "refinedata-mcp[all]", "refinedata-mcp"]
}
}
}Drop [all] (or swap in [scraping], [viz], etc.) to install only the
extras you need. uvx fetches the package into an isolated, cached
environment on first run.
Running from a local checkout
{
"mcpServers": {
"RefineDataMCP": {
"command": "refinedata-mcp",
"cwd": "/absolute/path/to/refinedata-mcp"
}
}
}refinedata-mcp is installed as a console script. Alternatively use
"command": "python", "args": ["-m", "refinedata_mcp"].
Environment variables
Variable | Default | Effect |
|
| Log verbosity (logs go to stderr) |
| unset | Path to a JSONL audit log file (tool name, status, duration) |
|
| Reject in-memory loads larger than this (0 = off) |
| unset | Sandbox: restrict all file reads/writes to this dir |
|
| Comma-separated tool names to expose, or |
|
| Max simultaneous tool calls (0 = unlimited) |
|
| Web scraper request timeout (seconds) |
|
| Allow scraping private/loopback IPs (SSRF override) |
|
| Attach external databases read-only |
|
| Best-effort DB query timeout (seconds, 0 = off) |
|
| Presidio scan language |
|
| Cells per spaCy |
|
| Detoxify model variant |
Security notes
The web scraper blocks requests to private/loopback/link-local/metadata IPs (SSRF guard). Override only for trusted local use with
REFINEDATA_ALLOW_PRIVATE_URLS=true.query_dbexecutes the SQL you pass it and attaches databases read-only by default.Set
REFINEDATA_WORKDIRto confine file access to a single directory.Set
REFINEDATA_ENABLED_TOOLSto expose only a subset of tools in multi-tenant setups.This server is built for a single trusted user (your agent). Do not expose it to untrusted input without adding allow-lists.
Testing
pip install -e ".[dev]"
python -m pytestTests for optional features importorskip their dependencies, so the suite runs
(skipping what isn't installed) at any install level. See ROADMAP.md
for what's done and what's next.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityCmaintenanceGives LLM agents access to local and remote data via databases, files, graphs, and structured documents, along with a full data science toolkit for analysis and modeling.Last updated3Apache 2.0
- Alicense-qualityDmaintenanceEnables LLM agents to load, explore, and analyze CSV and Excel files using DuckDB, with tools for SQL querying, statistical analysis, expense optimization, and anomaly detection.Last updatedMIT

Agent Toolsofficial
Alicense-qualityCmaintenanceProvides deterministic tools for transforming, formatting, and inspecting structured data for AI agents.Last updated1419Apache 2.0- AlicenseAqualityCmaintenanceProvides AI agents with data validation, transformation, and normalization capabilities, including JSON schema validation, CSV processing, data normalization, text cleaning, and dataset merging.Last updated564MIT
Related MCP Connectors
45 AI data tools for agents — crypto, DeFi risk, audits, equities, energy, and more.
Twitter/X, Instagram, Reddit & TikTok data for AI agents. Billions of posts. No API keys.
Persistent memory and knowledge management for AI agents with semantic search and 50+ tools.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Enesp4rl4k/refinedata-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server