loop selector

    1

    A task router that selects the optimal iterative pattern and generates the required loop configuration.

    Free

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+22 more

    loop selector

    Example session with this skill installed

    I have a prompt for classifying support tickets that currently hits 82% accuracy. I want to improve it until it reaches at least 95% accuracy. How should I structure the loop?

    • Read your context and instructions
    • Compiled the loop selector

    The task involves tuning a reusable artifact (a prompt template) against a specific, achievable numeric metric. This is a system optimization task that fits the Prompt Optimization pattern.

    Loop Configuration

    {
      "category": "system-optimization-loops",
      "pattern": "Prompt Optimization",
      "loop_start": {
        "exit_mode": "target",
        "target_value": 0.95,
        "direction": "increase",
        "max_iterations": 8
      },
      "feedback_loop": {
        "metric": "classification_accuracy",
        "companion_tool": "prompt-evolve"
      }
    }
    

    Next steps

    1. Review the system-optimization-loops skill for specific details on wiring the prompt-evolve tool.
    2. Define your held-out evaluation dataset to ensure the target_value is calculated consistently across iterations.
    3. Initialize the loop using the provided loop_start configuration.

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

    About this skill

    Stop wasting tokens on loops that never converge or tasks that shouldn't be loops at all. This agent skill acts as a high-level router for iterative tasks, ensuring you select the right architectural pattern before writing a single line of logic. It evaluates tasks against a strict "loop-shaped" gate and then maps them to a specialized category—Quality, Memory, Planning, Exploration, or System Optimization.

    What it does

    • Pre-loop validation ensures a task has a clear progress signal, requires multiple passes, and possesses a natural stopping point before proceeding.
    • Pattern routing maps ambiguous user requests like "optimize this" or "fix this" to one of twenty specific iterative patterns.
    • Config generation produces immediate loop_start parameters including exit_mode, target_value, and max_iterations tailored to the specific pattern.
    • Composite detection identifies when a task requires a sequence of different loop types rather than forcing a single, ill-fitting pattern.
    • Budget enforcement recommends appropriate iteration limits to prevent infinite loops and manage compute costs.

    How it works

    1. Validation: Run the Step 0 check to confirm the task is actually loop-shaped based on signal availability and necessity.
    2. Classification: Use the decision tree to match the task against five core categories: quality, memory, planning, exploration, or system optimization.
    3. Pattern Selection: Identify the specific sub-pattern (e.g., Adversarial Critique vs. Judge Ensemble) within the chosen category.
    4. Configuration: Generate the concrete loop_start JSON config with the correct exit modes and progress directions.

    Frameworks & tools

    This skill is designed for agents using iterative ledger patterns or loop-based architectures. It integrates with bantamkit for memory-related workflows and utilizes standard iteration controllers like critique-gate and prompt-evolve.

    Why this beats prompting it yourself

    Prompting an agent to "loop until finished" often leads to hallucinated stopping conditions or inefficient iteration. This skill provides a structured decision framework that enforces architectural best practices, ensuring you use the most efficient pattern for the specific problem domain.

    Use cases

    • Quality Control: Routing a content generation task to a Multi-Critic or Adversarial loop.
    • Bug Fixing: Mapping a failing test suite to a Plan-Execute-Replan planning loop.
    • Prompt Engineering: Configuring a System Optimization loop to tune templates against a metric.
    • Design Research: Setting up an Exploration loop to branch and compare multiple UI candidates.

    Known limitations

    This skill is a router and does not contain the full implementation logic for every pattern. Users must refer to the specific category skills for deep wiring rationale and failure-mode notes.

    How to use

    Skills on Agensi run inside your AI agent. Copy the prompt, paste it into your agent, and it connects to Agensi and installs this skill for you. If a payment is needed, your agent shows it to you first.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill passes our trust checks below.

    Security scanned

    Passed our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free forever

    No account required to browse

    Trust & safety

    Security scanned

    Verified clean today

    • Free to download with an account

    Requires

    Loop Ledger (Optional Enforces The Loop Brake) MCP

    Listedtoday

    What's inside

    Frequently Asked Questions