Examples#
Every example below is a runnable Jupyter notebook committed to the
repository under examples/.
Flagship screencast#
screencast/research_agent/screencast.ipynb— four-way head-to-head (create_react_agentbaseline vs. hand-wiredStateGraphvs. LangGOAP vs. LangGOAP-under-disruption) with real OpenAI + Tavily costs and Tavily-key revocation as the climax.
Basics#
Short primers — each notebook exercises a single mechanic.
plan_visualization.ipynb— Mermaid, DOT, ASCII, and Gantt renderers over an A* → CSP plan.nl_goal_interpreter.ipynb— Plain-English request →GoalSpecvia anyBaseChatModel.create_goap_agent_quickstart.ipynb— The Layer A one-liner: LangChain tools + goal → compiledStateGraph.termination_policies.ipynb—MaxCostPolicy,MaxActionsPolicy, andFirstOfPolicycomposition.stuck_handlers.ipynb—FunctionalStuckHandlerandMulticastStuckHandlerrecovering planning failures.typed_form_hitl.ipynb— Typed-forminterrupt()with Pydantic validation on resume.action_qos.ipynb— In-executor retry withActionQosand exponential backoff.
Tutorials#
Complete end-to-end walkthroughs across three tiers of complexity.
Tier 1 — Primers
directory_handler.ipynb— GOAP basics on a file-system world state.robot_navigation.ipynb— A* primer on a linear graph.hungry_agent.ipynb— Natural-language goal + cost-driven action selection.from_routing_graphs_to_goap.ipynb— Hand-wired LangGraph routing graph rewritten as a GOAP plan that absorbs runtime disruptions.
Tier 2 — Workflows and constraint optimization
cloud_balancing.ipynb— VM bin-packing with thecreate_goap_agentone-liner.vehicle_routing.ipynb— Capacity-constrained routing with CSP temporal scheduling.nurse_rostering.ipynb— Shift assignment withHardSoftScoreand skill matching.project_job_scheduling.ipynb— RCPSP with precedence constraints and makespan minimization.task_assigning.ipynb— Ticket routing with the fluentConstraintBuilder.sql_query_agent.ipynb— Schema-explore → generate → test → refine loop usingeffect_validator.vulnerability_scanner.ipynb— Phased discovery with action blacklisting.cost_bounded_research_agent.ipynb— Token / USD budget enforced viaMaxCostPolicy.personal_shopper_agent.ipynb— Utility-maximizing planning withUtilityStrategyandNirvanaGoal.scheduled_delivery_confirmer.ipynb— Typed-form HITL with Pydantic validation.deepagents_integration.ipynb— Embed aGoapGraphas aStructuredToolor Deep Agents subagent.
Tier 3 — Full-stack showcases
deep_research_agent.ipynb— LLM-heavy research loop withStoreExecutionHistoryand tracing.hierarchical_product_launch.ipynb—MultiGoalsequential decomposition.content_builder_agent.ipynb— Multi-objective CSP with conditional format generation.temporal_match_cellar.ipynb— Durative actions with overlap constraints and parallel scheduling.flexible_job_shop.ipynb— Every v0.1.0 feature in one notebook.supply_chain_disruption_mediator.ipynb— Stuck handlers and goal relaxation under cascading disruption.code_review_agent_mcp_deployment.ipynb—langgoap deploy-initscaffolds alanggraph dev-ready deployment with an/mcpendpoint.