BREAKER DELTA
Breaker Delta
OverviewGetting StartedReading the SiteCLI ReferenceConfigurationSkill & MCPExtensionDeploy Your Own
CLI Reference

The CLI is one self-contained file, breaker-delta.mjs (see Getting Started for bundling), called BD below. Exit codes: 0 success, 1 runtime error, 2 usage error.

Global options (may appear before or after the command)

--data-dir <dir>   Instance data dir: editions/, state/, track-record.md,
                   config.yaml|json (default: $BD_DATA_DIR or current dir)
--config <path>    Config file (default: search the data dir, then the engine root)
--root-dir <dir>   Engine root holding assets/, favicon-cache/ and config.example.*
                   (default: $BD_ROOT_DIR or auto-detected)
--json             Machine-readable output: stdout carries one JSON document
--help             Show help

Commands

  • scan [--edition morning|evening] β€” run the fetch layer for one edition, write state/candidates-<date>-<edition>.json and print per-source status. Without --edition, the edition is chosen by local hour (before noon = morning). No command at all = scan.
  • review β€” list topics whose 14-day review is due.
  • record <file|-> [--date YYYY-MM-DD] β€” write agent-graded topics back to the store. Input is a JSON array, each entry like {"name":"Topic","sources":["Hacker News","Reddit"],"grade":"must"}, with grade must / watch / echo. Use - to read stdin. The store write is atomic.
  • record review --name <topic> --result hit|miss β€” record a 14-day review outcome for one topic.
  • publish [--out <dir>] [--base-url <url>] [--data-repo <owner/repo>] [--langs zh,en,ja] [--creator|--no-creator] β€” build the static site from the data dir. Flags override the TS_* environment variables, which override defaults (below).
  • docs [--out <dir>] [--docs-url <url>] [--main-url <url>] [--langs zh,en,ja] β€” build the standalone docs site (this site). Needs only the engine root; no data dir is read. --docs-url sets the docs site's own URL (default https://docs.breakerdelta.com/), --main-url the main radar site the docs link back to (default https://breakerdelta.com/); TS_DOCS_URL / TS_MAIN_URL / TS_DOCS_OUT do the same by environment.
  • doctor β€” offline self-check of Node, config, data dir and engine root; exits 1 when any check fails.
  • mcp β€” run the stdio MCP server with the tools radar_scan and radar_review (see Skill & MCP).

Common examples

BD="bun apps/cli/dist/breaker-delta.mjs"
$BD --data-dir /path/to/your-data doctor
$BD --data-dir /path/to/your-data scan --edition morning
echo '[{"name":"Some New Model","sources":["Hacker News","Reddit"],"grade":"must"}]' > picks.json
$BD --data-dir /path/to/your-data record picks.json
$BD --data-dir /path/to/your-data record review --name "Some New Model" --result hit
$BD --data-dir /path/to/your-data publish --out site

publish environment variables (what a data repo's CI uses)

TS_OUT           Output directory
TS_BASE_URL      Site root URL (drives canonical, sitemap and share links)
TS_DATA_REPO     Data repo (owner/repo) that submit links point at
TS_LANGS         Languages to build, comma-separated, e.g. zh,en,ja
TS_CREATOR       1 on / 0 off: the creator panel on topic pages
TS_PAGE_SIZE     Board page size (default 100)
TS_ARCHIVE_DAYS  Archive retention in days
TS_SOURCES_PAGE  Sources per sources-page
TS_SHARE         Share platforms, comma-separated
TS_DOCS_URL      Docs site URL: the main site's Docs tab points here (default https://docs.breakerdelta.com/)
TS_MAIN_URL      Main site URL: the docs site links back here (default https://breakerdelta.com/)