iterative-retrieval

Iteratively refine search queries to retrieve relevant codebase context for subagents.

1|Updated Mar 10, 2026
One-click install
npx skills add https://github.com/aleonsa/claude-config --skill iterative-retrieval-aleonsa
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: iterative-retrieval
Source: https://github.com/aleonsa/claude-config/tree/main/claude/skills/iterative-retrieval
Command: npx skills add https://github.com/aleonsa/claude-config --skill iterative-retrieval-aleonsa

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill addresses the challenge of providing subagents with the precise codebase context they need, especially when that context is unpredictable or too large to send upfront.

Core Features & Use Cases

  • Progressive Context Refinement: Iteratively searches and evaluates files to build a relevant context set.
  • Handles Unpredictable Needs: Ideal for scenarios where subagents discover their context requirements as they work.
  • RAG-like Pipelines: Enables sophisticated retrieval for code exploration and complex task execution.
  • Use Case: When debugging a complex feature, this Skill can intelligently find and provide the most relevant code files related to authentication and user sessions, even if the exact files aren't known initially.

Quick Start

Use the iterative-retrieval skill to find files related to 'authentication' and 'user sessions' within the 'src' and 'lib' directories.

Frequently Asked Questions about iterative-retrieval

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

FAQPage Schema
How do I provide codebase context to subagents when the required files are unpredictable?

Iterative context retrieval solves unpredictable codebase context needs by progressively dispatching, evaluating, and refining search queries. It dynamically builds a relevant context set for subagents based on relevance and identified gaps.

What is the best way to handle context size limitations in multi-agent workflows?

Handling context size limitations in multi-agent workflows is best achieved through progressive context refinement. Subagents iteratively search and evaluate files to gather only the necessary context, avoiding large upfront payloads.

How does iterative search work for RAG-like codebase exploration?

Iterative search for RAG-like codebase exploration works by dispatching initial search queries, evaluating the returned files for relevance, and refining subsequent queries to fill identified context gaps.

Can I use progressive context refinement to debug complex features across multiple directories?

Yes, progressive context refinement can debug complex features across multiple directories. It intelligently finds relevant code files, such as those related to authentication in 'src' and 'lib', even when exact files are unknown initially.

When do I need dynamic context gathering for subagents instead of sending all files upfront?

Dynamic context gathering is needed when subagents discover their context requirements as they work, or when the total codebase context is too large to send upfront. It prevents overwhelming the subagent with irrelevant files.