Split large or varied source material across parallel subagents for extraction before synthesis. Use this when documentation exceeds what can be processed in a single pass — typically more than 5 dense documents or 50+ pages — or when material spans multiple distinct domains. Produces structured Context Packets that can feed into complexity-mapper, decision-brief, or architecture-risk-review. Ask to "shard documents", "split for parallel extraction", or "break this into digestible chunks" to use this workflow.
How this skill is triggered — by the user, by Claude, or both
Slash command
/systems-thinking-plugin:context-shardingThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Use Context Sharding when:
Use Context Sharding when:
Do not use Context Sharding when:
| Input | Required | Description |
|---|---|---|
| Source material | Yes | Large document sets, multiple documents, big codebases, or any collection of material that needs extraction. Provide file paths, URLs, or inline content. |
| Extraction goal | Yes | What information needs to be extracted. This drives the sharding strategy and the instructions given to each doc-reader instance. |
| Downstream workflow | No | If the sharded output will feed into another skill (complexity-mapper, decision-brief, etc.), specify it so the extraction can be shaped to match expected inputs. |
If the extraction goal involves topics that require web research (e.g., vendor documentation, pricing, service limits not available locally):
web-researcher agent to discover and collect relevant source material.Web-sourced material should be treated as separate shard candidates from local material to maintain source clarity.
Skip this step if all material is already available locally.
When inventorying materials to shard, also check reference/vendor_docs/ and reference/previous_designs/ for files relevant to the extraction goal. Include relevant reference materials as additional input sources.
Run the doc-indexer agent on the full set of provided materials (including any web-sourced material from Step 0.5). The doc-indexer produces:
This output is the foundation for the sharding plan. Do not skip this step and shard based on file names or guesses.
Using the doc-indexer output, design a sharding plan that optimizes for:
Source separation: Keep reference materials (from reference/) in separate shards from user-provided materials to maintain source clarity. This makes it easy to distinguish findings derived from reference context vs. primary inputs.
Shard independence: Each shard should be processable without requiring context from other shards. The less cross-shard dependency, the higher the quality of parallel extraction.
Shard coherence: Each shard should cover a logically complete unit — a service, a subsystem, a concern area, a document group. Avoid splitting a single tightly coupled section across shards.
Shard size balance: Shards should be roughly equal in processing effort. One massive shard and four tiny ones defeat the purpose of parallelization.
The sharding plan should specify:
| Shard ID | Contents | Rationale | Cross-references to other shards | Extraction focus |
|---|---|---|---|---|
| shard-1 | [Files/sections] | [Why these belong together] | [References to shard-2, shard-3, etc.] | [What to extract from this shard] |
Sharding strategies (choose based on material structure):
If the material is too interrelated to shard cleanly, flag this and adjust: either use larger shards with more overlap, or add a mandatory cross-reference pass in Step 5.
Launch one doc-reader instance per shard with:
All doc-reader instances run in parallel. Each produces a Context Packet containing:
If the extraction goal includes risk identification, limitation discovery, or the downstream workflow is complexity-mapper or architecture-risk-review, and the per-shard material volume is large (>5 sections per shard):
extraction-planner on each shard to determine how many caveat-extractors to spawn per shard and what scoped instructions each receives.Skip this step if per-shard material is small (≤5 sections) — use a single caveat-extractor per shard.
If the extraction goal includes risk identification, limitation discovery, or the downstream workflow is complexity-mapper or architecture-risk-review:
caveat-extractor on each shard's raw material (not on the Context Packet — on the original source).This step adds depth but also adds processing time. Skip it if the extraction goal is purely informational (e.g., summarization, inventory).
Gather Context Packets from all shards. Post-collection quality checks:
If critical cross-references were lost in sharding, run a targeted cross-reference pass: a single agent that reads the relevant sections from multiple shards and produces a Cross-Reference Addendum appended to the affected Context Packets.
Depending on the workflow:
If presenting directly to the user: Deliver all Context Packets with a summary that includes:
If feeding into a downstream workflow: Package the Context Packets in the format expected by the target skill:
complexity-mapper: Pass as documentation input along with design assumptions.decision-brief: Pass as extracted findings input.architecture-risk-review: Pass as architecture docs input.The output is a set of Context Packets, one per shard, conforming to the output contract:
## Context Packet — [Shard ID]: [Shard Label]
### Shard Scope
- **Contents**: [Files/sections in this shard]
- **Extraction Focus**: [What was extracted and why]
### Extracted Items
#### [Category: Facts / Decisions / Constraints / Open Questions]
| Item | Source | Confidence | Cross-Shard Reference |
|---|---|---|---|
| [Extracted item] | [Document, section, line] | [High/Medium/Low] | [Shard ID if referencing another shard, or "None"] |
### Caveats (if caveat-extractor was run)
| Caveat | Severity | Trigger Condition | Source |
|---|---|---|---|
| [Caveat] | [Critical/High/Medium/Low] | [When this becomes a problem] | [Source anchor] |
### Out-of-Shard References
- [Reference]: [What shard or external source it points to] — [Resolved / Unresolved]
### Shard Summary
[2-3 sentence summary of the most important findings in this shard]
## Sharding Summary
### Sharding Strategy
[Strategy used and rationale]
### Shard Overview
| Shard ID | Label | Items Extracted | Caveats Found | Cross-References | Confidence |
|---|---|---|---|---|---|
| shard-1 | [Label] | [Count] | [Count] | [Count resolved / unresolved] | [H/M/L] |
### Cross-Shard Themes
- [Theme]: [Which shards contribute to this theme]
### Contradictions
- [Contradiction]: [Shard X says A, Shard Y says B] — [Recommended resolution]
### Gaps
- [Gap]: [What is missing and which shard boundary caused it]
| Failure Mode | Signal | Response |
|---|---|---|
| Documents too interrelated to shard cleanly | doc-indexer shows dense cross-reference graph; most documents reference most other documents | Use larger shards with intentional overlap at boundaries. Add a mandatory cross-reference pass after extraction. Accept higher processing cost for better coherence. |
| Individual shards still too large | A single shard exceeds single-pass processing capacity | Re-shard: split the oversized shard into sub-shards. Apply the same sharding strategy recursively. Update the sharding plan. |
| Critical cross-references lost in sharding | Step 5 reveals important links between shards that neither shard's Context Packet captured | Run a targeted cross-reference pass. A single agent reads the boundary material from both shards and produces a Cross-Reference Addendum. |
| Shard failure | One or more doc-reader instances fail to produce output | Do not proceed with incomplete data. Investigate the failure (material too dense, format issues, access problems), fix, and re-run the failed shard. |
| Unbalanced shards | One shard produces vastly more extracted items than others | Review the sharding plan. The large shard may need splitting, or the small shards may be too granular and should be merged. Rebalance for the next run. |
| Over-sharding | Material is split into so many shards that the synthesis step cannot hold all Context Packets in context | Reduce shard count. Merge related shards. As a rule of thumb, keep shard count under 8 for a single synthesis pass. |
npx claudepluginhub fakoli/systems-thinking-plugin --plugin systems-thinking-pluginOrchestrates parallel Worker and Critic subagents plus Summarizer to analyze large text/code/data corpora exceeding single-agent context, with layout computation, effort levels, and failure recovery.
Structured, cited extraction of insights and context from local documents and project knowledge. Writes a scan plan, parallel-subagent findings, and a cited synthesis report to disk — never inline prose.
Based on the Recursive Language Models (RLM) research by Zhang, Kraska, and Khattab (2025), this skill provides strategies for handling tasks that exceed comfortable context limits through programmatic decomposition and recursive self-invocation. Triggers on phrases like "analyze all files", "process this large document", "aggregate information from", "search across the codebase", or tasks involving 10+ files or 50k+ tokens.