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 skills add humanerd-drew/opencode-drewgent --skill yaml-config-patch-drewgentgit clone --depth 1 https://github.com/humanerd-drew/opencode-drewgentWrote 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/humanerd-drew/opencode-drewgent/yaml-config-patch-drewgent)<a href="https://agentmods.dev/skills/humanerd-drew/opencode-drewgent/yaml-config-patch-drewgent"><img src="https://agentmods.dev/badge/skills/humanerd-drew/opencode-drewgent/yaml-config-patch-drewgent/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/humanerd-drew/opencode-drewgent/yaml-config-patch-drewgent"><img src="https://agentmods.dev/badge/skills/humanerd-drew/opencode-drewgent/yaml-config-patch-drewgent.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00056 | $0.01911 |
| Opus 5.5 | $0.00022 | $0.00764 |
| Sonnet 5.5 | $0.00011 | $0.00382 |
| Haiku 4.5 | $0.00006 | $0.00191 |
Grade A, and why
yaml-config-patch-{{AGENT_NAME_LOWER}} 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 3mo ago.
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 — 165 lines — stays where its author put it; the contents beside it link to each section on GitHub.
YAML Config Patch — {{AGENT_NAME}} Dual-Config Pattern
{{AGENT_NAME}}는 config.yaml을 두 곳에 중복으로 유지한다. compression이나 auxiliary 같은 task-specific routing 변경 시 두 파일 모두 손대야 하고, 각 파일 내에서도 nested section 구조를 정확히 이해하고 patch해야 한다.
이 skill은 2026-06-03 cost optimization (H3 — M3 → M2.5 routing) 작업 중 두 차례 patch 실수로 얻은 운영 노하우를 정리한다.
1. Dual-Config Pattern (CRITICAL)
{{AGENT_NAME}}는 두 개의 config.yaml을 운영한다:
| File | Used by | What it has |
|---|---|---|
~/.{{AGENT_NAME_LOWER}}/config.yaml |
gateway, CLI, cron scheduler, run_kanban_worker | auxiliary.compression (provider/model) 만 |
~/.{{AGENT_NAME_LOWER}}/P5-ego/config/config.yaml |
P5-ego layer (identity snapshot) | compression: (summary_*) + auxiliary.compression: (provider/model) 둘 다 |
P5-ego 파일의 compression 섹션이 두 군데:
- root-level
compression:(line 43-50 근처) —summary_provider,summary_model,summary_base_url auxiliary.compression:(line 72-77 근처) —provider,model,base_url,api_key,timeout
이 둘은 다른 dict. P5-ego의 의도는 P5 layer가 자기 config를 가진 것. path-integrity-report-2026-05-17에서는 "do not auto-fix yet" 결정.
변경 시 두 파일 + P5-ego는 두 section 모두 손봐야 할 수 있다. auxiliary.compression만 보면 P5-ego의 root-level compression이 stale로 남는다.
2. mcp_patch YAML Gotcha
mcp_patch로 YAML을 patch할 때 partial old_string이 sibling section을
복제하는 사고를 내기 쉽다.
발생 패턴 (실제 사고 사례, 2026-06-03)
원본:
compression: ← root-level
enabled: true
threshold: 0.9
summary_model: ''
summary_provider: minimax
잘못된 patch — old_string이 summary_model: '' 부분만 잡고 new_string이
compression:으로 다시 시작:
compression: ← root-level (line 43)
enabled: true
compression: ← DUPLICATE (line 45) — 잘못된 새 키
enabled: true ← DUPLICATE (line 46)
threshold: 0.9
...
YAML이 broken. 두 개의 compression:이 같은 level에 있어서 parser가
후자만 인식하거나 error.
Prevention Rule
- Always read the file first — 정확한 indentation, sibling section 위치, 부모 key까지 확인 후 patch
- Match enough context — old_string에 부모 key + 첫 child 1
2줄 + target key 12줄 포함. target만 매치하면 부모가 ambiguous - Verify after every patch — 즉시
python3 -c "import yaml; yaml.safe_load(open(p))"- 출력으로 scope 확인
- If duplication appears, read file → 정확한 라인 파악 → 다시 patch
(이미 있는
compression:줄을 기준으로 작업)
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.
- 3mo ago First seen · 165 lines · 56 tokens per session scan A 665bfcc42b97
yaml-config-patch-{{AGENT_NAME_LOWER}} is a skill published in the GitHub repository humanerd-drew/opencode-drewgent (3 stars, last pushed 4mo ago), licensed MIT. It adds 56 tokens to every session and 1,911 once invoked, about $0.0002 per session on Opus 5.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.
yaml-config-patch-{{AGENT_NAME_LOWER}} compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| yaml-config-patch-{{AGENT_NAME_LOWER}}humanerd-drew/opencode-drewgent | Skill | 3 | 4mo ago | MIT | A | 56 | Claude Code, Codex |
| local-ai-agentsmicrosoft/ai-agents-for-beginners | Skill | 82k | yesterday | MIT | A | 200 | Claude Code, Codex |
| imagegenopenai/codex | Skill | 137k | today | Apache-2.0 | A | 113 | Codex |
| playwright-climicrosoft/playwright | Skill | 102k | today | Apache-2.0 | A | 19 | Claude Code |
| browser-automationopenclaw/openclaw | Skill | 396k | today | MIT | A | 36 | Claude Code |
| free-llm-apismnfst/awesome-free-llm-apis | Skill | 15k | yesterday | CC0-1.0 | A | 113 | Claude Code, Codex |
| systematic-debuggingobra/superpowers | Skill | 332k | 6d ago | MIT | A | 21 | Claude Code |