Mold Gallery
A curated selection of molds from the examples registry, showcasing what fimod can do out of the box. All of these are available immediately after running fimod setup registry defaults.
⚙️ DevOps & Config
@yaml_merge — Patch a YAML file
Applies a set of path=value assignments to an existing YAML document using dot-path notation. Useful for patching Kubernetes manifests or any structured config without a full template engine.
# Scale a deployment and tag it for production
fimod s -i deployment.yaml -m @yaml_merge \
--arg set="spec.replicas=3,metadata.labels.env=prod" \
-o deployment.yaml
Values are auto-cast: true/false become booleans, numeric strings become integers.
# Before
spec:
replicas: 1
metadata:
labels: {}
# After
spec:
replicas: 3
metadata:
labels:
env: prod
@env_to_dotenv — Config to .env format
Flattens a JSON/YAML config into a .env file with KEY=value lines.
@validate_fields — Assert required fields exist
Checks that a set of dotpaths are present in the input. Exits with code 1 if any are missing — perfect for CI gates.
🔍 Data Exploration
@jq_compat — Common jq operations
A lightweight jq-compatible interface for the three most-used operations: get (dot-path extraction), map (field projection), and select (filtering). Useful when you want the ergonomics of jq without the dependency.
# Extract a nested field
fimod s -i data.json -m @jq_compat --arg get=user.address.city
# Project a single field from an array
fimod s -i users.json -m @jq_compat --arg map=name
# Filter by field value
fimod s -i users.json -m @jq_compat --arg select=active=true
@deep_pluck — Extract nested fields into a flat object
Pulls values from deep dotpaths and returns a flat key/value object.
fimod s -i order.json -m @deep_pluck --arg paths=customer.name,shipping.address.city,total
# → {"customer.name": "Alice", "shipping.address.city": "Paris", "total": 99}
@flatten_nested — Flatten a nested object to dot-path keys
fimod s -i config.json -m @flatten_nested
# {"database": {"host": "localhost", "port": 5432}} → {"database.host": "localhost", "database.port": 5432}
@json_schema_extract — Extract a simplified JSON schema
Infers a schema from a JSON document — useful for quick documentation or validation scaffolding.
🔄 Data Transformation
@pick_fields — Keep only specified fields
@filter_fields — Keep or drop fields (with dotpaths)
fimod s -i api.json -m @filter_fields --arg mode=drop --arg fields=password,meta.debug
fimod s -i api.json -m @filter_fields --arg mode=keep --arg fields=id,user.email
@rename_keys — Rename keys via mapping
@dedup_by — Deduplicate records by a field
@group_count — Group by field and count
fimod s -i events.json -m @group_count --arg field=type
# → [{"type": "click", "count": 42}, {"type": "view", "count": 128}]
@split_tags — Split a delimiter-separated field into a list
fimod s -i articles.json -m @split_tags --arg field=tags
# "rust,cli,tools" → ["rust", "cli", "tools"]
@sort_json_keys — Recursively sort JSON keys
🛡️ Data Quality
@anonymize_pii — Hash PII fields
Replaces the values of specified fields with their SHA-256 hash. Works on both arrays of objects and single objects.
// Before
[{"id": 1, "email": "alice@example.com", "phone": "555-0100"}]
// After
[{"id": 1, "email": "a4c2e...", "phone": "f91b3..."}]
The original id and any non-listed fields are preserved. Deterministic hashing means the same input always produces the same fingerprint — useful for consistent pseudonymisation across datasets.
📊 CSV
@csv_stats — Basic statistics on numeric columns
fimod s -i data.csv -m @csv_stats
# → {"salary": {"min": 30000, "max": 120000, "mean": 65000, "count": 50}, ...}
@csv_to_json_records — CSV to JSON array of objects
📝 Text & Markdown
@badge_md — Generate a shields.io badge
fimod s -i status.json -m @badge_md --arg label=build --arg status=passing --arg color=green
# → []()
@git_changelog — Markdown changelog from structured data
@markdown_toc — Extract table of contents from Markdown
@log_parse — Parse log lines into structured records
Extracts structured fields from log lines using regex capture groups.
🗄️ BigQuery
@bq_insert — Generate INSERT statement from bq show
@bq_select — Generate SELECT statement from bq show
🚀 fimod-powered registry
More production-ready molds are available in the fimod-powered registry:
| Mold | Description |
|---|---|
@gh_latest |
Fetch latest GitHub release tag, resolve asset download URLs |
@download |
wget-like file download with binary pass-through |
@poetry_migrate |
Migrate Poetry 1.x pyproject.toml to uv or Poetry 2 |
@skylos_to_gitlab |
Convert Skylos dead code reports to GitLab Code Quality JSON |
See the fimod-powered README for the full list.