planning loops

    1

    Implement adaptive planning loops that decompose goals, handle mid-execution changes, and satisfy complex constraints.

    Free

    2 usesSecurity scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    planning loops

    Example session with this skill installed

    Decompose the goal 'Build a v1 documentation site using Docusaurus' into executable subgoals until every leaf is a single PR-sized task.

    • Read your context and instructions
    • Compiled the planning loops

    I have initiated a Goal Decomposition loop to break down the documentation site project. I will recursively split the high-level goal into manageable, executable units.

    Goal Decomposition: Docusaurus v1 Site

    Subgoal IDDescriptionStatusType
    G1Environment SetupPendingBranch
    G1.1Initialize Docusaurus project with TypeScript templatePendingLeaf (Executable)
    G1.2Configure GitHub Actions for CI/CD deployment to GH PagesPendingLeaf (Executable)
    G2Content StructurePendingBranch
    G2.1Define sidebar.js hierarchy and category indexingPendingLeaf (Executable)
    G2.2Create placeholder .mdx files for Core Concepts and APIPendingLeaf (Executable)
    G3Theming & BrandPendingBranch
    G3.1Implement custom CSS for brand colors and logo assetsPendingLeaf (Executable)
    G3.2Configure Search (Algolia/Local) and Footer linksPendingLeaf (Executable)

    Next steps

    1. Begin execution of G1.1 (Initialize project) using the Plan-Execute-Replan pattern.
    2. Validate G1.2 configuration once the repository structure is established.
    3. Review the content hierarchy in G2.1 against the project requirements.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Linear plans fail the moment they hit an unexpected dependency or a hidden constraint. This skill moves your agent beyond static to-do lists, implementing adaptive planning loops that treat execution as a source of new information. It ensures your agent doesn't just finish a list of steps, but actually reaches the goal by replanning when reality deviates from the initial hypothesis.

    What it does

    • Plan-Execute-Replan updates the remaining steps whenever execution results invalidate the original strategy.
    • Dynamic Workflow enables state-machine logic where the next step is chosen based on the immediate output of the previous action.
    • Goal Decomposition recursively breaks large, complex objectives into directly executable subgoals before execution begins.
    • Progress Evaluation acts as an objective sanity check to measure actual goal proximity, preventing local successes from masking global drift.
    • Constraint Satisfaction iterates through competing requirements, such as scheduling or resource allocation, until all conditions are met.

    How it works

    1. Initialize the Loop using the loop-ledger to set a goal, max iterations, and the specific exit mode (manual, target, or dry).
    2. Execute and Observe the first step or current state to gather ground-truth data from the environment.
    3. Evaluate and Replan by comparing results against the goal; if a conflict or new information appears, the agent generates a revised sequence.
    4. Monitor for Stalls using the ledger to detect if the agent is repeating the same failed plan or oscillating between identical constraint violations.

    Frameworks & tools

    This skill is designed for agents using loop-ledger for iteration tracking and state management. It is framework-agnostic but requires an environment capable of handling serialized state and multi-step execution cycles.

    Why this beats prompting it yourself

    Standard prompts often result in agents "hallucinating" progress by simply finishing a checklist even if the goal isn't met. This skill enforces a rigorous ledger-based system that distinguishes between task completion and goal attainment, providing specific wiring for handling mid-execution surprises.

    Use cases

    • Service Migrations where breaking changes are discovered incrementally during the porting process.
    • Subsystem Architecture that requires breaking a massive v1 goal into PR-sized executable leaves.
    • Resource Scheduling where jobs must be allocated across machines with competing memory and deadline limits.
    • Long-running Explorations that need periodic progress scoring to ensure the agent hasn't drifted off-track.

    Known limitations

    This skill is not for simple linear tasks where surprises are unlikely. It requires the loop-ledger tool to manage iteration state and prevent infinite loops.

    Requires loop-ledger for state tracking. Not for simple linear tasks. Does not handle choosing between multiple candidate plans.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    2 uses

    Times used to date

    Free forever

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 28 days ago

    • Free with an Agensi account

    Permissions

    No special permissions declared or detected

    Listed28 days ago

    What's inside

    Frequently Asked Questions

    Unlike static prompts that follow a linear checklist, this skill implements a recursive 'Plan-Execute-Replan' cycle that detects when an execution result contradicts the original plan and forces a strategic pivot.

    This skill is framework-agnostic but requires your environment to support the `loop-ledger` tool for state management and iteration tracking.

    The purchase includes the core adaptive planning logic, specialized integration schemas for the `loop-ledger`, and configuration templates for different exit modes (manual, target, or dry).

    Yes, the skill includes a stall-monitoring feature via the ledger that detects if an agent is oscillating between identical constraint violations or repeating failed plans, triggering a loop break or alert.

    This skill is designed for high-complexity tasks with hidden dependencies; for simple, one-off linear tasks, the overhead of a planning loop may be unnecessary.

    New in Agents & Orchestration