iterative-retrieval

Iteratively refine retrieval results for multi-agent workflows using a four-stage loop.

302|21|Updated May 10, 2026
One-click install
npx skills add https://github.com/virgo777/buddyme --skill iterative-retrieval-virgo777
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: iterative-retrieval
Source: https://github.com/virgo777/buddyme/tree/main/buddyMe/skill_library/skills/iterative-retrieval
Command: npx skills add https://github.com/virgo777/buddyme --skill iterative-retrieval-virgo777

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Iterative Retrieval Pattern addresses the context discovery challenge in multi-agent workflows by progressively refining the retrieved information to match the needs of subagents.

Core Features & Use Cases

  • 4-stage retrieval loop (DISPATCH, EVALUATE, REFINE, LOOP) that incrementally improves context relevance.
  • Dynamic query refinement using evaluation feedback to expand or prune search terms and results.
  • Practical use cases include provisioning codebase context for subagents, handling large repositories, and optimizing token usage through staged retrieval.

Quick Start

Run an iterative retrieval cycle to progressively refine the codebase context for subagents.

Frequently Asked Questions about iterative-retrieval

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

FAQPage Schema
How do I retrieve relevant codebase context for subagents when initial search results are too large or incomplete?

Iterative retrieval solves context discovery for subagents by progressively refining search results through a four-stage loop. It uses relevance scoring and dynamic keyword extraction to shrink large codebases into high-confidence context artifacts.

What is the best way to manage context discovery in multi-agent workflows?

Multi-agent context discovery is best managed by iteratively refining retrieved information to match subagent needs. This approach applies pattern-based queries and evaluation feedback to expand or prune search terms, ensuring progressively accurate context provisioning.

How does iterative retrieval refine context for subagents step by step?

Iterative retrieval refines context by executing a four-stage loop: DISPATCH, EVALUATE, REFINE, and LOOP. It evaluates initial results, extracts dynamic keywords, adjusts pattern-based queries, and repeats until cycle limits are met or high-confidence context is produced.

Can I use iterative retrieval to optimize token usage when provisioning large repositories to subagents?

Yes, iterative retrieval optimizes token usage by staging context extraction from large repositories. It dynamically prunes irrelevant search terms and results through evaluation feedback, ensuring subagents receive only the most relevant, high-confidence context artifacts.

When do I need iterative retrieval for multi-agent workflows?

You need iterative retrieval when subagents require progressively accurate context or when initial context is too large or incomplete. It is essential for multi-agent workflows handling complex codebases where single-pass information retrieval fails to provide relevant patterns.

What are the limitations of using an iterative retrieval loop to find codebase context?

The main limitation of an iterative retrieval loop is the enforced cycle limit, which stops refinement after a set number of iterations. If pattern-based queries and dynamic keyword extraction fail to converge, the resulting context artifacts may lack full relevance.