iterative-retrieval

Refine codebase context retrieval through iterative 4-phase search cycles.

12|4|Updated Mar 22, 2026
One-click install
npx skills add https://github.com/TeiNam/kiro-with-harness --skill iterative-retrieval-teinam
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: iterative-retrieval
Source: https://github.com/TeiNam/kiro-with-harness/tree/main/skills/iterative-retrieval
Command: npx skills add https://github.com/TeiNam/kiro-with-harness --skill iterative-retrieval-teinam

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Addresses the "context problem" in multi-agent workflows where subagents lack predictive context for their tasks.

Core Features & Use Cases

  • Progressive Refinement: A 4-phase loop that refines context progressively.
  • Dispatch: Initial broad query to gather candidate files.
  • Evaluate: Assess retrieved content for relevance.
  • Refine: Update search criteria based on evaluation.
  • Loop: Repeat with refined criteria up to 3 cycles.
  • Use Case: Solving "context too large" or "missing context" failures in agent tasks.

Quick Start

Activate the iterative-retrieval skill with the task prompt: "Retrieve codebase context for fixing authentication token expiry issues."

Frequently Asked Questions about iterative-retrieval

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

FAQPage Schema
How do I refine codebase context retrieval for multi-agent workflows?

Codebase context retrieval in multi-agent systems fails when subagents lack predictive context, leading to missing context or context too large errors. An iterative 4-phase approach dispatches broad queries, evaluates relevance, and refines search criteria to accurately target necessary files.

What is the best way to fix missing context failures in multi-agent codebase tasks?

To fix missing context failures in multi-agent codebase tasks, use a progressive refinement loop. This approach dispatches initial broad queries, evaluates the retrieved content, and updates search criteria over up to 3 cycles to ensure subagents receive accurate context.

How does progressive context refinement work for multi-agent systems?

Progressive context refinement works through a 4-phase loop: dispatching an initial broad query to gather candidate files, evaluating retrieved content for relevance, refining search criteria, and repeating the loop up to 3 cycles. This iteratively optimizes context for subagents.

Does iterative context retrieval work for large codebases with multiple subagents?

Iterative context retrieval works for large codebases with multiple subagents by running up to 3 refinement cycles. It prevents the context too large problem by evaluating and narrowing down candidate files, ensuring subagents only receive the most relevant context for their tasks.

When should I use an iterative retrieval process instead of a single search query?

Use an iterative retrieval process instead of a single search query when subagents lack predictive context for complex codebase tasks. If initial broad searches return too much irrelevant data or miss critical files, the 3-cycle refinement loop evaluates and updates criteria to improve accuracy.