In traditional programming and system administration, we often think in terms of scripts. A script is a linear sequence of commands designed to achieve a specific, well-defined task. It operates like a recipe: follow the steps in order, and you will get the expected result.
UnifyWeaver, at its core, is a powerful tool for creating highly efficient scripts from declarative logic. However, the true power of a modern AI-driven development environment lies in moving beyond rigid recipes.
This book introduces a new way of thinking: thinking in Workflows.
A Workflow is not just a script; it is a Strategy Guide for an intelligent AI agent. Instead of a single, fixed plan, a Workflow provides the agent with:
ancestor example) required to execute those strategies.In this model, the AI agent is not a simple script executor. It is an economic strategist that makes intelligent, resource-aware decisions. This book will teach you how to design and build these Workflows, empowering you to collaborate with AI agents on a whole new level.
While often used interchangeably in common parlance, within the UnifyWeaver framework, “Workflows” and “Playbooks” have distinct, yet complementary, roles:
Workflows: Represent the overarching strategic guide for an AI agent. A workflow defines the agent’s high-level goals, the general principles it should follow, the types of tools available, and the criteria for making strategic decisions (e.g., economic data, heuristic guidance). It’s the “operating manual” for the agent’s general behavior and problem-solving approach. Workflows are highly reusable and define the context for many tasks.
Playbooks: Are specific, detailed project plans or “scripts” for accomplishing a particular task or sub-goal within the context of a workflow. A playbook outlines the concrete steps, specific tools to use, and conditional logic required for a given job. Playbooks are less reusable than workflows, as they are tailored to individual tasks, but they operate strictly within the strategic framework established by a workflow.
In essence, a Workflow tells the agent how to think and operate broadly, while a Playbook tells the agent what specific actions to take for a particular problem.
To further empower AI agents and promote efficient development, both Workflows and Playbooks can reference and utilize example libraries. These libraries provide concrete instances of common patterns, tool usage, and problem-solving approaches.
A dedicated Perl tool is available to extract specific examples or sections from these example libraries, allowing agents to dynamically access and integrate relevant code snippets or data into their execution plans. This mechanism ensures that agents can learn from and apply established best practices without embedding large amounts of redundant information directly into playbooks.