Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/yonatangross/orchestkit/chain-patternsnpx skills add yonatangross/orchestkit --skill chain-patternsgit clone --depth 1 https://github.com/yonatangross/orchestkitWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/yonatangross/orchestkit/chain-patterns)<a href="https://agentmods.dev/skills/yonatangross/orchestkit/chain-patterns"><img src="https://agentmods.dev/badge/skills/yonatangross/orchestkit/chain-patterns.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00039 | $0.05035 |
| Opus 5 | $0.00019 | $0.02518 |
| Sonnet 5 | $0.00008 | $0.01007 |
| Haiku 4.5 | $0.00004 | $0.00504 |
Grade A, and why
chain-patterns scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 344 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Chain Patterns
Overview
Foundation patterns for CC 2.1.71 pipeline skills. This skill is loaded via the skills: frontmatter field — it provides patterns that parent skills follow.
Pattern 1: MCP Detection (ToolSearch Probe)
Run BEFORE any MCP tool call. Probes are parallel and instant.
# FIRST thing in any pipeline skill — all in ONE message:
ToolSearch(query="select:mcp__memory__search_nodes")
ToolSearch(query="select:mcp__context7__resolve-library-id")
ToolSearch(query="select:mcp__sequential-thinking__sequentialthinking")
# Store results for all phases:
Write(".claude/chain/capabilities.json", JSON.stringify({
"memory": true_or_false,
"context7": true_or_false,
"sequential": true_or_false,
"timestamp": "ISO-8601"
}))
Usage in phases:
# BEFORE any mcp__memory__ call:
if capabilities.memory:
mcp__memory__search_nodes(query="...")
# else: skip gracefully, no error
Load details: Read("${CLAUDE_PLUGIN_ROOT}/skills/chain-patterns/references/mcp-detection.md")
Pattern 2: Handoff Files
Write structured JSON after every major phase. Survives context compaction and rate limits.
Write(".claude/chain/NN-phase-name.json", JSON.stringify({
"phase": "rca",
"skill": "fix-issue",
"timestamp": "ISO-8601",
"status": "completed",
"outputs": { ... }, # phase-specific results
"mcps_used": ["memory"],
"next_phase": 5
}))
Location: .claude/chain/ — numbered files for ordering, descriptive names for clarity.
Load schema: Read("${CLAUDE_PLUGIN_ROOT}/skills/chain-patterns/references/handoff-schema.md")
Pattern 3: Checkpoint-Resume
Read state at skill start. If found, skip completed phases.
# FIRST instruction after MCP probe:
Read(".claude/chain/state.json")
# If exists and matches current skill:
# → Read last handoff file
# → Skip to current_phase
# → Tell user: "Resuming from Phase N"
# If not exists:
Write(".claude/chain/state.json", JSON.stringify({
"skill": "fix-issue",
"started": "ISO-8601",
"current_phase": 1,
"completed_phases": [],
"capabilities": { ... }
}))
# After each major phase:
# Update state.json with new current_phase and append to completed_phases
What ships with it
21 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/assertion-grader.md 5.1 KB
- references/checkpoint-resume.md 3.7 KB
- references/cron-monitoring.md 1.5 KB
- references/dynamic-workflow-patterns.md 14 KB
- references/experiment-journal.md 4.2 KB
- references/fork-pattern.md 6.4 KB
- references/handoff-schema.md 1.7 KB
- references/mcp-detection.md 3.1 KB
- references/mcp-tool-hooks.md 3.8 KB
- references/monitor-patterns.md 4.4 KB
- references/plugin-tag.md 3.6 KB
- references/pr-from-platform.md 3.6 KB
- references/schedule-wakeup.md 3.9 KB
- references/tier-fallbacks.md 1.7 KB
- references/worktree-agent-pattern.md 8.8 KB
- rules/_sections.md 274 B
- rules/checkpoint-on-gate.md 1002 B
- rules/handoff-after-phase.md 1.0 KB
- rules/probe-before-use.md 1.6 KB
- rules/push-notification-on-completion.md 3.1 KB
- test-cases.json 1.8 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- today First seen · 344 lines · 39 tokens per session scan A 64d9b1d8f01e
chain-patterns is a skill published in the GitHub repository yonatangross/orchestkit (225 stars, last pushed today), licensed MIT. It adds 39 tokens to every session and 5,035 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
agent-self-scheduling
Schedule AI agent runs with cron, loops, or external clocks while avoiding unsafe tight autonomous timers.
idea-clarifier
Clarifies a vague request into a concrete starting point.
scqa-writing-framework
Structures content using the Situation, Complication, Question, Answer framework for clear, logical, and engaging narratives suitable for threads, articles, and reports.
source-validation-skill
Validates the credibility of information sources, highlighting reliability, relevance, and potential biases.
video-script-generator
Generates video scripts with hooks, structured sections, pacing, and call-to-actions optimized for engagement and retention.
deep-research-synthesizer
Synthesizes insights from large datasets, filters irrelevant data, identifies patterns, and produces actionable summaries.