planning_agent

command
v0.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 30, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Example: planning_agent demonstrates the built-in planning ("todo") tool (WC-A-001). An agent works a multi-step task, writing a structured plan and marking steps done as it progresses. The plan is persisted durably per session via builtins.NewStoragePlanStore, so it survives a checkpoint/resume — the example proves this by reloading the plan from a fresh store after the run.

A small deterministic mock model.Provider drives the loop, so the example runs with NO API keys and NO network access. On each turn the mock advances the plan based on how many tasks are already completed:

turn 0: create the 3-step plan (step 1 in_progress)
turn 1: step 1 done, step 2 in_progress
turn 2: step 2 done, step 3 in_progress
turn 3: all steps done, then emit the final answer

go run ./examples/planning_agent/

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL