ACAgentic Craft

Reference

Patterns

A browsable library of agentic design patterns. Published entries are complete; the editorial backlog lists what comes next — not fake stubs.

Augmented LLM

A single HazelJS AgentRuntime call enriched with retrieval, bounded tools, or structured output—without an open-ended agent loop.

Tool-Using Agent

A bounded AgentRuntime observe→decide→act loop where HazelJS validates tool calls via ToolRegistry and feeds observations back to the model.

Human Approval Gate

Pause a HazelJS AgentRun with durableSuspend before high-impact tools until a human approves or rejects via approveAndResume.

Evaluator–Optimizer

Iterate generation with HazelJS AgentRuntime loop stages (plan/execute/critique/validate) until quality bars or budgets are met.

Durable Agent Run

Persist AgentRun checkpoints and leases with createDurableRunStore / createSqlDurableRunStore so HazelJS agents survive crashes without double-applying side effects.

Memory Layers

Separate working context, session state, long-term memory, and artifacts in HazelJS so agents scale without stuffing everything into one prompt.

Idempotent Tool Execution

Make AgentRuntime write tools safe under retries and durable resume using idempotency keys and dedupe semantics in adapters.

Compensating Action

Undo or neutralize partial side effects after agent or workflow failure using saga/flow compensation and idempotent reverse tools.

Bounded Autonomy

Cap what a HazelJS agent may do unsupervised using capabilities, PolicyEngine effects, maxSteps, and HITL—not prompt instructions alone.

Budget-Aware Execution

Enforce hard economic stops with RunBudget maxTokens/maxCostUsd plus maxSteps—budgets that live in AgentRuntime, not in prompt text.

Agent Sandbox

Reduce blast radius for HazelJS agents using session/tenant isolation, curated tools, and policy—without claiming an unreleased OS/container sandbox product.

Router

Route intents to specialized agents or subgraphs with AgentGraph conditional edges or SupervisorAgent.

Sequential Workflow

Fixed-stage pipelines with @hazeljs/flow nodes or runtime.pipeline—when stages are stable.

Parallel Fan-Out / Fan-In

Run independent branches concurrently with AgentGraph parallel nodes, then merge.

Planner–Executor

Produce an explicit plan artifact, then execute under validation—via loop stages or split agents.

Agent Loop

Canonical observe→decide→act loop owned by AgentRuntime—not ad-hoc while(true) in app code.

Reflection / Critique Loop

Require a structured critique pass before committing answers or side effects—via loop stages or evaluator–optimizer.

Supervisor and Specialists

A supervisor delegates to specialist agents with narrow tools via createSupervisor / AgentGraph.

Agent Handoff

Transfer goals and minimal state between agents or to humans without dumping full transcripts unsafely.

Retrieval Before Action

Require grounded lookup/RAG before write tools fire—via policy, graph edges, or tool allow-order discipline.

Model Routing

Choose models by task class, cost, and risk using per-agent model prefs and documented cost routing—not one frontier model for everything.

Production Agent Runtime Blueprint

Reference architecture for a HazelJS production Agent Runtime: App code, DNA, Store, platform desired state, and AgentRuntime execute — as taught by Meridian Ops.

Editorial backlog

Not published yet. 1 draft stubs in the content model.

  • Cloud Control Plane Adoption Path
  • Production Agent Runtime Blueprint (Phase D)