One-click install
npx skills add https://github.com/vinitgirdhar/GRID_ --skill iterative-retrieval-vinitgirdhar
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: iterative-retrieval
Source: https://github.com/vinitgirdhar/GRID_/tree/main/.agent/skills/iterative-retrieval
Command: npx skills add https://github.com/vinitgirdhar/GRID_ --skill iterative-retrieval-vinitgirdhar

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Subagents often operate with limited context and struggle to determine what information they need, leading to inefficiencies or failures in complex workflows. Iterative Retrieval provides a structured four-phase loop to progressively refine the context loaded into subagents.

Core Features & Use Cases

  • Four-phase loop (DISPATCH, EVALUATE, REFINE, LOOP) that narrows the search space and surfaces relevant files and patterns.
  • Automatic adaptation to evolving codebase contexts by extracting new patterns, terminology, and gaps across cycles.
  • Improves reliability of multi-agent tasks by keeping context size manageable while preserving critical information.
  • Practical use: when spawning subagents that need codebase context, building complex workflows, or handling context-too-large failures.

Quick Start

Initiate an iterative retrieval cycle to gather and refine context across files until sufficient high-relevance results are obtained.

Frequently Asked Questions about iterative-retrieval

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

FAQPage Schema
How do I refine subagent context when codebase searches return irrelevant files?

To refine subagent context, use an iterative retrieval loop that progressively narrows the search space and scores file relevance across cycles. This dispatches subagents, evaluates results, and refines the query to surface missing codebase patterns automatically.

What is the best way to handle context-too-large failures in multi-agent workflows?

Handling context-too-large failures in multi-agent workflows requires progressively refining the context loaded into subagents. A structured retrieval loop keeps context size manageable while preserving critical information by scoring and filtering irrelevant files.

How does iterative retrieval work for managing AI agent context in a codebase?

Iterative retrieval for AI agent context works through a four-phase loop: DISPATCH, EVALUATE, REFINE, and LOOP. It cycles up to three times, using relevance scoring to extract new terminology and gaps, adapting the context loaded into subagents dynamically.

Can I use iterative context refinement to fix missing-context failures when spawning subagents?

Yes, you can fix missing-context failures by applying iterative context refinement when spawning subagents. The evaluation phase identifies context gaps, and the refine phase adapts the retrieval query to extract necessary codebase patterns and files.

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

You need iterative retrieval for multi-agent workflows when subagents operate with limited context and struggle to determine required information. It is applied when spawning subagents that need evolving codebase context or addressing context-size limits.

Does iterative retrieval support automatic adaptation to evolving codebase contexts?

Yes, iterative retrieval supports automatic adaptation to evolving codebase contexts. The refine phase extracts new patterns, terminology, and gaps across cycles, ensuring subagents receive updated and relevant file information dynamically.