Skip to main content

Module demo

Module demo 

Source
Expand description

harn demo — bundled, fully-offline scenarios that demonstrate the Harn moat (persona supervision, replay determinism, provider routing) without any API keys. See issue #1650.

Each scenario ships with:

  • a .harn script (assets/demo/<id>/scenario.harn)
  • a JSONL --llm-mock tape (assets/demo/<id>/tape.jsonl)
  • optionally, sibling files (.harn.prompt templates, imported modules, fixtures) anywhere under assets/demo/<id>/

The script and tape are include_str!’d here; sibling files are embedded by build.rs (see DEMO_SIBLING_FILES). At run time stage_scenario materializes the whole set into a tempdir and run_scenario executes there hermetically, so harn demo <id> works from a static-linked install with no repo checkout — and a multi-file scenario behaves exactly like a real on-disk Harn project.

Functions§

scenario_ids
Public list of bundled scenario ids — used by tests and the smoke loop that exercises every demo on every PR.