Commands
/magic:deliver
/magic:deliver — Deliver processed data to a destination
Usage
/magic:deliver [destination]
Description
Deliver your processed data to an external destination. This command guides you through the delivery workflow with appropriate safety checks.
Destinations
Database (db)
Deliver processed data to a database table.
Read the magic-data-transformation SKILL.md ## Database Delivery section for delivery guidance.
Workflow:
- Check workspace state for current data (latest checkpoint or DataFrame)
- Ask user for delivery target:
- Environment variable for connection (default:
DATABASE_URL) - Target table name
- Write mode: append (default) / replace
- Environment variable for connection (default:
- Validate data with
validate_transform.py(transformation skill, Tier A scriptable — call directly) before delivery - Present write plan: row count, target table, mode, column mapping
- PAUSE (always): Confirm before writing — "Write {N} rows to {table}? [y/N]"
- Execute write via
deliver_to_db.py - Update
workspace_state.mdwith delivery results
Safety: This command creates a NON-read-only connection. The PAUSE gate is mandatory and cannot be skipped even in autonomous mode.
HuggingFace Hub (hf)
Upload processed data to a HuggingFace dataset repository.
Workflow:
- Confirm repo name and visibility (private by default)
- Generate dataset card from data metadata
- Upload data folder with atomic commit
- Report Hub URL
Example:
/magic:deliver hfRequired: HF_TOKEN env var or huggingface-cli login
Scripts used:
generate_dataset_card.py(loading skill, callable tool) — creates README.md with schema and provenancedeliver_to_hf.py(transformation skill, callable tool) — uploads folder to HF Hub (has built-in confirmation prompt)
Local File (local)
Save processed data to a local output directory (default behavior without destination).
Example:
/magic:deliver localSafety
- All external deliveries require user confirmation (PAUSE gate)
- Database writes use non-read-only connections — PAUSE is mandatory
- Defaults to private visibility for HuggingFace repos
- Credentials are never included in uploads or dataset cards
- Use
--create-prfor PR-based HF delivery when working in teams
Was this page helpful?
Edit on GitHub
Last updated on