iterative-retrieval

Structures sub-agent spawning with a 3-cycle protocol, WHY context, and coordinator validation.

1|Updated Jul 7, 2026
One-click install
npx skills add https://github.com/seiggy/maf-copilot-studio-demo --skill iterative-retrieval-seiggy
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: iterative-retrieval
Source: https://github.com/seiggy/maf-copilot-studio-demo/tree/main/.squad/templates/skills/iterative-retrieval
Command: npx skills add https://github.com/seiggy/maf-copilot-studio-demo --skill iterative-retrieval-seiggy

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? When AI coordinators spawn sub-agents for scoped work, handoffs often lack context, retry cycles multiply without bound, and outputs get accepted without verification. This Skill enforces a disciplined protocol that caps retries at 3 cycles, mandates WHY context in every spawn prompt, and requires coordinator validation before any issue is closed. ## Core Features & Use Cases - Structured Spawn Prompts: A mandatory four-section template (Task, WHY, Success criteria, Escalation path) ensures every sub-agent receives complete context. - 3-Cycle Protocol: Bounded retry logic with objective context forwarding between cycles and mandatory escalation after cycle 3 instead of endless loops. - Coordinator Validation & Dedup: A pre-acceptance checklist, mandatory GitHub issue deduplication search via gh issue list, and a research-then-execute rule requiring every analysis task to end with a concrete action (issue, PR, or decision record). - Use Case: A squad coordinator agent delegating a documentation update spawns a sub-agent with explicit acceptance criteria, validates the returned PR against the checklist, and escalates to .squad/decisions/inbox/ if three cycles fail to converge. ## Quick Start Use the iterative-retrieval protocol to spawn a sub-agent for my next scoped task, including WHY context, checkbox success criteria, and an escalation path.

Frequently Asked Questions about iterative-retrieval

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I spawn a sub-agent with proper context?

Use the four-section spawn prompt template: Task (concrete and bounded), WHY this matters (motivation and consequences), Success criteria (explicit checkboxes), and Escalation path (what to do when stuck). Vague prompts without WHY context are an explicit anti-pattern.

How many retry cycles should a sub-agent get before escalating?

The protocol caps retries at 3 cycles. Cycle 2 and 3 prompts must include what previous cycles got wrong, not just repeat the original task. After cycle 3 fails, escalate by writing a summary to the decisions inbox and labeling the issue status:needs-decision.

How do I avoid creating duplicate GitHub issues with agents?

Run `gh issue list --search "<keywords>" --state open` before creating any issue, using 2-3 representative keywords from the planned title. If an open issue covers the same problem, comment on it instead of creating a new one.

When should a coordinator reject sub-agent output?

Reject output when any checklist item fails: unmet success criteria, missing or mismatched PR, introduced TODO/FIXME markers or build failures, silently skipped task parts, or unresolved uncertainty. Spawn the next cycle with specific deltas instead of accepting.

What are the limitations of a fixed 3-cycle retry protocol?

The protocol assumes failures stem from agent execution, not requirements. If 3 cycles do not converge, the problem is treated as a requirements or decision gap requiring human escalation, so tasks needing open-ended exploration may not fit this model.