Skip to content

How-to guides ​

Short, task-oriented recipes: each one solves a single problem, assumes you already know the basics, and gives you a complete example you can run and adapt. If you're starting from zero, read the PGDL guide first (see What is PGDL? and Expressions (PEL)).

Every example on these pages is a real phony invocation and its actual output.

The recipes ​

The shape of every recipe ​

Most recipes register a composition (a generator authored as data) in a phony.json package, then run it with phony generate:

bash
phony generate --use <generator-name> --package ./my-pkg --seed 42 -n 3
  • --use NAME runs a registered generator by name.
  • --package DIR loads a package directory (one containing phony.json), so its generators and assets are available.
  • --seed makes the run reproducible — the same seed always yields the same rows.
  • -n is how many values to produce; -f jsonl switches to one JSON value per line.

phony prints a ✓ Loaded … line to stderr for each package it loads, so the JSON on stdout stays clean and pipeable.

Phony Cloud — Documentation & Specification