katas-multipass-prompt-chaining

Decompose oversized tasks into typed local passes and a summary-only integration pass.

Updated Jun 28, 2026
One-click install
npx skills add https://github.com/JaviMontano/claude-plugins --skill katas-multipass-prompt-chaining-javimontano
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: katas-multipass-prompt-chaining
Source: https://github.com/JaviMontano/claude-plugins/tree/main/plugins/claude-native-toolkit/skills/katas-multipass-prompt-chaining
Command: npx skills add https://github.com/JaviMontano/claude-plugins --skill katas-multipass-prompt-chaining-javimontano

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Asking a model to audit 50 files or summarize a long document in one mega-prompt saturates its attention, loses details, and produces generic summaries that hallucinate relationships between units. This Skill teaches a multi-pass prompt chaining pattern that keeps each pass focused, cheap, and verifiable. ## Core Features & Use Cases - Typed local pass: Process each unit (file, section, page) independently with a compact typed output schema such as FileFindings, parallelizable via subagents. - Summary-only integration pass: The second pass consumes only the typed summaries from pass one, never the raw units, and emits a final report such as AuditReport. - Typed per-unit error state: Each unit carries a status/error field so the integration pass knows exactly how many valid units it has, preventing silent N-1 failures. - Use Case: Auditing 50 Python files for security findings by generating one FileFindings record per file in parallel, then integrating only those summaries into a single AuditReport that reports 49/50 valid units. ## Quick Start Ask the assistant to audit all Python files in a directory using multi-pass prompt chaining with a typed findings schema per file and an integrated final report.

Frequently Asked Questions about katas-multipass-prompt-chaining

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

FAQPage Schema
How do I audit many files with an LLM without losing detail?▼

Use multi-pass prompt chaining: run an isolated local pass per file that emits a compact typed findings record, then run an integration pass that consumes only those typed summaries. This keeps each pass within its context limit and makes results auditable per unit.

What is prompt chaining with a local pass and integration pass?▼

It is a pipeline where pass one processes each unit independently with a declared output schema, and pass two integrates only those typed outputs, never the raw units. Each pass declares its schema and the next pass consumes exactly that schema.

When should I not use multi-pass prompt chaining?▼

Do not chain when the task fits comfortably in a single prompt and the coordination overhead exceeds the benefit. Chaining is justified only when the workload does not fit holgadamente in one context window, such as many files or a very long document.

Why does the integration pass need a typed error state per unit?▼

Without a typed status or error field per unit, a failed unit disappears silently and the integration pass assumes it has N valid summaries when it only has N-1. Explicit error states make the valid-unit count accurate and the failure visible.

Can the local pass be parallelized across subagents?▼

Yes. Because each unit is processed in isolation with no cross-unit dependencies, the local pass maps naturally to parallel subagents, one invocation per unit, with structured outputs collected for the integration pass.