Skip to content

mcp_bridge

sqllocks_spindle.mcp_bridge

MCP bridge — JSON stdin/stdout protocol for spindle-forge MCP server.

Usage

echo '{"command": "list"}' | python -m sqllocks_spindle.mcp_bridge

Commands

list — List available domains with metadata describe — Full schema description for a domain generate — Generate data, return summary + file paths dry_run — Preview planned row counts without generating validate — Validate a .spindle.json schema file preview — Generate small sample, return first N rows as JSON profile_info — Get distribution keys and ratios for a domain

Classes

Functions:

cmd_list(_params)

List all available domains.

cmd_describe(params)

Describe a domain's schema.

cmd_generate(params)

Generate data and optionally write to disk.

cmd_dry_run(params)

Preview planned row counts.

cmd_validate(params)

Validate a .spindle.json schema file.

cmd_preview(params)

Generate small sample and return as JSON.

cmd_profile_info(params)

Get distribution keys and ratios for a domain's profile.

cmd_scale_generate(params)

Generate data at scale using multi-process (local_mp) or single-process (local_single) path.

cmd_stream(params)

Start a background streaming job.

Params: domain, scale, seed, sinks, sink_config, interval_seconds, chunk_size, max_chunks, mode, profile.

Returns: {"stream_id": "uuid"}

cmd_stream_status(params)

Get status of a running stream. Params: stream_id.

cmd_stream_stop(params)

Stop a running stream. Params: stream_id.

cmd_scale_status(params)

Poll the status of a submitted fabric_spark generation job.

cmd_scale_cancel(params)

Cancel an in-flight fabric_spark generation job.

cmd_demo_list(_params)

List all available demo scenarios.

cmd_demo_run(params)

Run a demo scenario. Returns structured result; Spark mode includes fabric_run_id.

cmd_demo_status(params)

Return demo manifest by session_id; if Spark, include live Fabric job status.

cmd_demo_cleanup(params)

Run CleanupEngine against a saved demo manifest.

main()

Read JSON from stdin, dispatch command, write JSON to stdout.