Foundation~25 minHazelJS
Hazel CLI Agent Ops
Use hazel agent doctor, run, logs, and runs — and know DNA smoke stubs are not the same as app runtime.execute.
- Authors
- editorial-team
- Published
- Last reviewed
Progress is stored locally in this browser.
Direct answer
@hazeljs/cli helps you doctor the environment, smoke-test DNA, read timelines, and list durable runs. Real tools and HITL continuation still happen in your app via AgentRuntime.execute / approveAndResume.
Docs: CLI. Guide: /guides/design-an-agent-manifest.
Critical distinction (do not skip)
| Path | What it is |
|---|---|
hazel agent run ./agent.dna.json "…" --mock | DNA bootstrap with stub tools |
Your app runtime.execute('ops-desk', …) | Real @Tool handlers |
hazel agent runs resume|approve (file store) | Records HITL intent; app must still approveAndResume |
Never demo “production behavior” using only DNA stub smoke.
Step 1Daily local ops loop
bash
# Environment / wiring checks
hazel agent doctor
# Optional DNA smoke (stubs) — offline LLM with --mock
hazel agent run ./agent.dna.json "Status of ORD-1001?" --mock
# Timeline / logs (path depends on your starter)
hazel agent logs --timeline .hazel/runs/timeline.jsonl
# Durable runs on disk
hazel agent runs list --dir .hazel/runs
Step 2When to use which
| Situation | Use |
|---|---|
| New laptop / CI image | doctor |
| Manifest / DNA sanity | hazel agent run smoke |
| Tool truth & product QA | App execute + goldens |
| Incident “what happened?” | logs --timeline + Inspector |
| Approval after suspend | App approveAndResume (CLI may mark store intent) |
Step 3Cheat sheet for the team wiki
doctorbefore first run on a machine- DNA smoke for manifest only
- App execute for tool truth
- Timeline + Inspector for incidents
- Link to kill switch / revoke tool auth runbook
Checkpoint
- You ran
doctorsuccessfully once - You can explain stub DNA vs app execute to a teammate
- You know where timelines live for Ops Desk locally
What to do next
Promote with the checklist: /learn/agentic-development/from-demo-to-production-checklist
Artifact: Local ops cheat sheet for Ops Desk: doctor → logs → runs list