Skip to content

Repository files navigation

Synthdata Plugin

A general-purpose Claude Code plugin for synthetic data generation across any tabular domain.

Synthdata turns a YAML schema (or one of 12 built-in templates) into realistic synthetic datasets — with Faker-backed fields, statistical distributions, foreign-key integrity, behavioral profiles, and temporal event generation. Outputs xlsx, csv, json, sql, or parquet.

Skills

SkillWhat it does
synthdata-generatePick a template (HR, e-commerce, SaaS, healthcare, finance, security, IoT, CRM, logs, surveys, +blank) or design custom schema via interview, generate synthetic dataset
synthdata-extractExtract tabular data from Excel workbooks to JSON (auto-detects title rows and headers)
synthdata-extendAdd rows or new columns to an existing dataset while preserving FK integrity and profile distributions
synthdata-anonymizeTransform a real dataset into a synthetic equivalent — detects PII, replaces with Faker values, preserves shape and distributions
synthdata-computeDerive aggregated, scored, or transformed tables from existing data — monthly rollups, composite scores, percentile ranks, segment summaries
synthdata-serveSpin up a read-only MCP server from a dataset — auto-generates tools for querying, filtering, sampling, and statistics
synthdata-prompt-builderPlan multi-step generation workflows — identify raw vs derived tables, match to templates, output a sequenced set of prompts
synthdata-tutorialGuided interactive walkthrough of the synthdata skills

Installation

Option 1: GitHub marketplace (recommended)

/plugin marketplace add rappdw/synthdata
/plugin install synthdata@synthdata-marketplace

Option 2: Reference from another marketplace

In another marketplace's marketplace.json:

{
"name": "synthdata",
"source": {
"source": "github",
"repo": "rappdw/synthdata"
}
}

Option 3: Plugin directory

claude --plugin-dir /path/to/synthdata

Option 4: Manual skill copy

cp -r skills/*~/.claude/skills/
# or use the installer:
./install.sh

Option 5: Cowork upload

./package.sh # produces dist/synthdata-v0.3.0.plugin# Cowork > Customize > Plugins > Upload custom plugin

Prerequisites

pip install openpyxl faker numpy pandas pyyaml mcp --break-system-packages

Quick Start

> Generate me a synthetic HR directory with 500 employees
> Create an e-commerce orders dataset
> Build a custom dataset for my app — I'll describe the tables
> Extract this spreadsheet to JSON
> Anonymize this customer export
> Compute monthly risk scores from my event data
> Help me plan what data I need for a fraud detection demo
> Serve this dataset as an MCP server so Claude can query it

Templates

12 domain starters ship with synthdata-generate. Pick one to get going fast, or start from blank-slate for a custom schema.

TemplateEntities
hr-directoryemployees, departments
ecommerce-orderscustomers, products, orders, order_items
saas-metricsaccounts, users, events, subscriptions
healthcare-patientspatients, providers, encounters, claims
financial-transactionsaccounts, customers, transactions
security-eventsusers, devices, alerts, incidents
log-eventsservices, requests, errors
iot-sensorsdevices, readings, events
crm-pipelinecontacts, companies, deals, activities
survey-responsesrespondents, questions, responses
healthcare-hrm-securityusers, threat events, phishing sims, training, DLP, abuse mailbox
blank-slateminimal starter for custom schemas

Schema Format

name: my-datasettables:
- name: usersrows: { quick: 50, medium: 1000, thorough: 5000 }columns:
- { name: user_id, type: id, prefix: "U", width: 4 }
- { name: name, type: faker, method: name }
- { name: department, type: choice, values: [Sales, Eng, Ops], weights: [0.4, 0.4, 0.2] }
- { name: salary, type: float, distribution: lognormal, mean: 75000, sigma: 0.4, min: 30000 }profiles:
- { name: high_risk, weight: 0.05, overrides: { risk_multiplier: 3.0 } }
- name: eventsforeign_key: { column: user_id, references: users.user_id, distribution: zipfian, alpha: 1.5 }rows_per_parent: { distribution: poisson, lam: 5 }columns:
- { name: event_type, type: choice, values: [login, click, error] }
- { name: ts, type: timestamp, start: "2025-01-01", end: "2025-12-31" }writers: [xlsx, json]

See skills/synthdata-generate/references/schema-spec.md for the complete spec.

Serving Data as an MCP Server

Any generated (or existing) dataset can be exposed as a read-only MCP server that Claude can query directly.

Inspect first

python3 skills/synthdata-serve/scripts/serve.py --inspect --input ./hr.xlsx

Configure Claude Code

Add to .mcp.json in your project root (or ~/.claude/.mcp.json for global):

{
"mcpServers": {
"synthdata-hr": {
"command": "python3",
"args": ["/path/to/skills/synthdata-serve/scripts/serve.py", "--input", "/path/to/hr.xlsx"]
}
}
}

Restart Claude Code to pick up the new server. Five tools become available:

ToolWhat it does
list_tablesTable names, row counts, column summaries
describe_tableColumn dtypes, sample values, FK hints
query_tableFilter, sort, paginate rows (default limit: 50, max: 500)
sample_rowsRandom sample of N rows
get_statsMean, std, min, max, percentiles (numeric) or top values (categorical)

Export a standalone server

python3 skills/synthdata-serve/scripts/export.py \
--input ./hr.xlsx --output ./hr-server/ --name hr-data

Produces a self-contained directory (server.py, data/dataset.json, requirements.txt, README.md) that runs independently — no synthdata plugin needed. Works with Claude Code and Claude Desktop.

License

MIT — see LICENSE.

About

A general-purpose Claude Code plugin for **synthetic data generation** across any tabular domain

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages