iterative-retrieval

Manages subagent context by iteratively retrieving and refining codebase information.

Updated Mar 20, 2026
One-click install
npx skills add https://github.com/KanakMalpani/General-Private-Skills --skill iterative-retrieval-kanakmalpani
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: iterative-retrieval
Source: https://github.com/KanakMalpani/General-Private-Skills/tree/main/skills/iterative-retrieval
Command: npx skills add https://github.com/KanakMalpani/General-Private-Skills --skill iterative-retrieval-kanakmalpani

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Progressive context retrieval solves the subagent context problem.

Core Features & Use Cases

  • Provides a structured 4-phase loop (DISPATCH, EVALUATE, REFINE, LOOP) to progressively gather and prune context.
  • Applies relevance scoring and cycle-limited iteration to avoid context overload.
  • Supports multi-agent workflows where subagents require evolving information from a codebase.

Quick Start

Start an iterative retrieval with broad queries and refine by relevance until sufficient context is gathered.

Frequently Asked Questions about iterative-retrieval

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

FAQPage Schema
How do I prevent context overload when retrieving codebase information for subagents?

To prevent context overload when retrieving codebase information for subagents, apply progressive context retrieval using a structured loop that scores relevance and prunes unnecessary material through phased refinement. This limits cycles to a maximum of three iterations.

What is the best way to progressively refine context for multi-agent workflows?

The best way to progressively refine context for multi-agent workflows is enforcing a four-phase loop: DISPATCH, EVALUATE, REFINE, and LOOP. This cycle-limited iteration applies relevance scoring to ensure subagents receive only high-quality contextual material.

How do I handle large repositories when spawning subagents that require evolving codebase context?

Handling large repositories with subagents requires iterative retrieval. Start with broad queries, evaluate the gathered context against a relevance threshold, and refine the scope across up to three cycles to prevent context overload and ensure accurate contextual material.

Does progressive context retrieval limit the number of refinement cycles for subagents?

Yes, progressive context retrieval limits the iteration to a maximum of three cycles. This constraint prevents infinite loops during the EVALUATE and REFINE phases, ensuring that context gathering for subagents remains efficient and avoids context overload.

When should I use iterative retrieval instead of single-pass context gathering for subagents?

Use iterative retrieval instead of single-pass gathering when subagents require evolving codebase context from large repositories. If the initial context lacks sufficient relevance, the phased refinement loop prunes and gathers more material until the relevance threshold is met.