Skip to content

Mix task reference ​

Lemon ships 54 mix lemon.* tasks across the umbrella (plus mix lemon.new from the installer archive). mix help | grep lemon lists them alphabetically with no grouping, which makes the tooling hard to discover. This page groups every task by purpose. For a live, grouped listing from the CLI, run:

bash
mix lemon.help

mix lemon.help reads each task's @shortdoc at runtime, so it never drifts from the code; this document adds the flags, examples, and follow-up notes that the one-liner can't.

Each task's own docs are always available with mix help lemon.<task>.

Packaged and source users: use the release CLI (lemon …) or the matching source wrapper (./bin/lemon …) for normal setup and diagnostics. The Mix commands on this page are the direct contributor interfaces behind those user-facing verbs.

bash
# Installed release
lemon setup
lemon model --provider anthropic
lemon gateway setup
lemon config validate
lemon secrets status
lemon channels
lemon providers status
lemon doctor

# Source checkout
./bin/lemon setup
./bin/lemon model --provider anthropic
./bin/lemon gateway setup
./bin/lemon config validate
./bin/lemon secrets status
./bin/lemon channels
./bin/lemon providers status
./bin/lemon doctor
./bin/lemon node join --name worker-1 --controller ws://controller:4040/ws --pair --cwd /srv/project

The installed lemon runtime CLI is included in the minimal and full release profiles. It returns 0 for success, 1 for command failures, and 2 for usage errors; command-specific help returns 0 without running the command. The simulation release does not include this runtime CLI.


Onboarding & setup ​

Getting a fresh checkout or a fresh machine to a working agent.

TaskPurpose
mix lemon.new NAMEScaffold a new Lemon agent project. Ships in the installer/ archive, not the umbrella — install it with mix archive.install before use. Flags: --hex (Hex requirements, no checkout; not with --channel), --channel, --memory, --lemon-path, --packages-path, --install.
mix lemon.setupIdempotent first-run setup: derives config/secrets/provider state, creates only missing config and secrets state, skips an already usable provider, and verifies a newly configured provider unless --skip-verify defers its live check. This is the contributor alternative to lemon setup / ./bin/lemon setup.
mix lemon.onboardTop-level interactive provider onboarding. Contributor alternative to lemon model / ./bin/lemon model.
mix lemon.onboard.anthropicInteractive onboarding for the Anthropic provider.
mix lemon.onboard.codexInteractive onboarding for the OpenAI Codex provider.
mix lemon.onboard.copilotInteractive onboarding for the GitHub Copilot provider.
mix lemon.onboard.geminiInteractive onboarding for the Google Gemini CLI provider.
mix lemon.onboard.antigravityInteractive onboarding for the Google Antigravity provider.
mix lemon.providersShow redacted provider readiness. This contributor task remains read-only; use lemon providers / ./bin/lemon providers for fallback and credential-pool reference edits.
mix lemon.workspaceInitialize ~/.lemon/agent/workspace bootstrap files.
mix lemon.updateUpdate Lemon: config migration and bundled-skill sync.
Hermes migration Mix tasksDeleted; use lemon migrate hermes from a release or ./bin/lemon migrate hermes from a source checkout.

Secrets ​

Encrypted secret store plus the voice-specific helper. When running the individual secrets tasks directly, mix lemon.secrets.init must run once to create the master key. The full mix lemon.setup / lemon setup journey initializes a missing master key itself and does not replace an existing one.

TaskPurpose
mix lemon.secrets.initInitialize the Lemon secrets master key.
mix lemon.secrets.set KEY VALUEStore an encrypted secret.
mix lemon.secrets.listList stored secret metadata (no values).
mix lemon.secrets.statusShow encrypted secrets status.
mix lemon.secrets.checkCheck secret resolution sources (env vs. store).
mix lemon.secrets.delete KEYDelete a stored secret.
mix lemon.secrets.import_envImport env-based secrets into the encrypted store.
mix lemon.secrets.rotate_keyRotate the secrets master key and re-encrypt stored secrets.
mix lemon.voice.secretsInteractively set voice API secrets.

Diagnostics ​

Read-only, redacted health and configuration reports. Safe to run anywhere.

TaskPurpose
mix lemon.doctorRun Lemon diagnostics and report health.
mix lemon.configValidate and inspect Lemon configuration (--validate, etc.).
mix lemon.channelsInspect channel configuration.
mix lemon.usageShow redacted usage, cost, token, and quota diagnostics.
mix lemon.mediaShow redacted generated-media job status.
mix lemon.modelsList known Lemon AI models (--provider, --vision, --thinking, --json).
mix lemon.introspectionQuery agent introspection events.
mix lemon.feedbackInspect historical routing feedback stats.

Quality & CI ​

mix lemon.quality runs in CI (scripts/test quality) on every PR and push to main; the rest are adjacent guards.

TaskPurpose
mix lemon.qualityRun the docs link, architecture docs, deps/0 policy, and duplicate test module checks (--root, --validate-config).
mix lemon.architecture.docsGenerate architecture boundary docs from policy.
mix lemon.check_duplicate_testsCheck for duplicate test module names.
mix lemon.extension.validateValidate Lemon extension package manifests.
mix lemon.evalRun the coding-quality eval harness.
mix lemon.eval.codingRun the opt-in live production-CLI coding benchmark.

Data, stores & messaging ​

Durable state and outbound notifications.

TaskPurpose
mix lemon.store.migrate_jsonl_to_sqliteMigrate Lemon store data from JSONL files to SQLite.
mix lemon.honchoInspect the Honcho memory satellite (status / sessions / ping / context).
mix lemon.memoryManage the durable memory store (stats / prune / erase).
mix lemon.policyManage per-route model policies (channel / account / peer / thread).
mix lemon.sendSend a Telegram or Discord notification from a script.

Skills ​

TaskPurpose
mix lemon.skillManage Lemon skills (discover / install / update / remove).
mix lemon.skill.lintLint skill bundles for manifest compliance and audit cleanliness.

Benchmarks (platform) ​

TaskPurpose
mix lemon.benchRun the platform microbenchmark suites. See benchmarks/quickstart.md.

Sim & arena ​

lemon_sim contributes 11 tasks, and lemon_sim_ui adds mix lemon.sim.demo. They fall into five sub-groups.

Scenario runners (self-play) ​

Each runs one scenario's self-play example. All share the common flags --seed, --max-turns, --offline-strategy, --no-persist, and --sim-id (run mix help lemon.sim.<scenario> for scenario-specific options).

poker, tic_tac_toe, vending_bench, werewolf (4).

bash
mix lemon.sim.tic_tac_toe --offline-strategy random --seed 42 --no-persist --max-turns 10
mix lemon.sim.vending_bench --preset ci --offline-strategy baseline --sim-id vb_ci

Demo ​

TaskPurpose
mix lemon.sim.demoBoot the sim UI and watch a keyless offline Werewolf game.

Replay renderers ​

TaskPurpose
mix lemon.sim.replay <scenario> <log>Render any scenario's JSONL game log into a video.
mix lemon.sim.vending_bench_replay DIRBuild a static HTML replay browser from a VendingBench artifact directory (not a video).

mix lemon.sim.replay handles every video scenario through one task, backed by each scenario's shared VideoGenerator. Scenarios: poker, werewolf. Both the scenario and the log path are required.

bash
mix lemon.sim.replay poker apps/lemon_sim/priv/game_logs/poker/abc.jsonl
mix lemon.sim.replay werewolf werewolf.jsonl --fps 3 --output werewolf.mp4

VendingBench keeps a separate task because its replay is a static HTML browser, not a video. tic_tac_toe has no replay renderer.

Scoring & verification ​

TaskPurpose
mix lemon.sim.score PATHPrint the scorecard for a run artifact bundle.
mix lemon.sim.verify PATHVerify a run artifact bundle: hashes, event replay (VendingBench, Werewolf, Poker), and scorecard recompute. Exits non-zero on failure.
bash
mix lemon.sim.verify apps/lemon_sim/priv/game_logs/vending_bench/vb_ci
mix lemon.sim.score  apps/lemon_sim/priv/game_logs/vending_bench/vb_ci

Suites, leaderboards & ratings ​

TaskPurpose
mix lemon.sim.suiteRun a benchmark suite and write a leaderboard (--scenario, --preset, --seeds, --offline, --external-cmd, --out).
mix lemon.sim.leaderboard PATHPrint and rewrite a suite leaderboard (--recompute).
mix lemon.sim.ratingsAggregate suite leaderboards into cross-suite model ratings (--root/--suites, --out).

Not a mix task ​

scripts/release_package and scripts/verify_packages are shell scripts, not Mix tasks. Invoke scripts/release_package PACKAGE VERSION directly; see standalone packages. They are not listed by mix lemon.help.

./bin/lemon node join is also a source wrapper, not a Mix task. It starts a long-lived native coding execution worker and has no corresponding Mix task.

bash
LEMON_NODE_OPERATOR_TOKEN=... ./bin/lemon node join \
  --name worker-1 \
  --controller wss://controller.example/ws \
  --pair \
  --cwd /srv/project

Use --pair when creating the controller identity. Later starts reuse the private, controller-bound token stored by durable node ID on the destination. Re-run with --pair after the controller's seven-day session-token expiry to recover the same durable node and revoke older sessions. Use the explicit operator-authorized --pair --repair --node-id ID path only for a legacy record without a recovery credential. Prefer LEMON_NODE_OPERATOR_TOKEN / LEMON_NODE_TOKEN over token flags; node names must be unique on the controller, and the destination cwd must already exist.

Non-loopback controllers require wss:// by default. Plaintext ws:// needs --allow-insecure-controller and is acceptable only for development or across a verified encrypted overlay such as Tailscale.


Sim task consolidation notes ​

Done — replay renderers. The 15 per-scenario *_replay tasks were folded into the single parameterized mix lemon.sim.replay <scenario> <log>. They were near-identical thin wrappers over each scenario's shared VideoGenerator (LemonSim.Examples.Rendering.DomainVideoGenerator), so one registry-backed task covers them all. vending_bench_replay stayed separate (it builds a static HTML browser, not a video). Net: 15 tasks removed with no loss of capability.

Scenario runners remain separate. The four retained runners have distinct switch sets and example entrypoints: werewolf supports per-seat models, vending_bench has benchmark presets, and tic_tac_toe exposes kernel-level offline strategies. A shared dispatcher would not remove those differences. VendingBench is also called directly by scripts/sim_bench.sh and scripts/generate_sim_demo_bundles.sh.

Released under the MIT License.