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/humanerd-drew/opencode-drewgent/tool-integration-protocolnpx skills add humanerd-drew/opencode-drewgent --skill tool-integration-protocolgit clone --depth 1 https://github.com/humanerd-drew/opencode-drewgentWhat 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.00000 | $0.00666 |
| Opus 5 | $0.00000 | $0.00333 |
| Sonnet 5 | $0.00000 | $0.00133 |
| Haiku 4.5 | $0.00000 | $0.00067 |
Grade A, and why
tool-integration-protocol 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 2d 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.
What it actually says
space: outcome type: document links:
- "[[@action/skills/devops/DESCRIPTION]]"
- "[[@action/skills/SKILL-INDEX]]"
Tool Integration Protocol
{{AGENT_NAME}}에 새로운 도구를 추가할 때 사용하는 표준 절차.
3단계 통합 패턴
Step 1: 도구 핸들러 파일
파일: tools/<name>_tool.py
import json, os
from tools.registry import registry
def check_requirements() -> bool:
return bool(os.getenv("YOUR_API_KEY")) #또는 True
def your_tool(param: str, task_id: str = None) -> str:
return json.dumps({"success": True, "data": "..."})
registry.register(
name="your_tool",
toolset="your_toolset",
schema={
"name": "your_tool",
"description": "...",
"parameters": {
"type": "object",
"properties": {
"param": {"type": "string", "description": "..."}
},
"required": ["param"]
}
},
handler=lambda args, **kw: your_tool(
param=args.get("param", ""),
task_id=kw.get("task_id")
),
check_fn=check_requirements,
requires_env=["YOUR_API_KEY"], #또는 []
)
Step 2: model_tools.py import 추가
파일: model_tools.py, _discover_tools() 함수의 _modules 리스트
"tools.your_tool", # 알파벳 순서로 추가
Step 3: toolsets.py에 toolset 배정
파일: toolsets.py
_HERMES_CORE_TOOLS에 추가:
"your_tool",
필수 검증 체크리스트
-
registry.register()호출됨 -
schema["parameters"]["type"] = "object"확인 -
model_tools.pyimport 추가됨 -
toolsets.pytoolset 배정됨 - P0
禁tool_integration_3file위반 없음
Workflow 추적
IntegrationWorkflow가 signal_processor에서 자동 추적됨.
완료 시 brain.awareness.integration_complete 시그널 발생.
Pitfalls
- import 안 함 → 도구 레지스트리에 안 올라감
- toolset 안 배정 → tool_schemas에 안 포함됨
- check_fn이 False → availability check 실패
- handler가 JSON string 안 반환 → tool result 파싱 에러
- requires_env 빈 배열 → API 키 없어도 등록됨 (의도한 경우 제외)
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.
- 2d ago First seen · 101 lines · 0 tokens per session scan A d68019d4b731
tool-integration-protocol is a skill published in the GitHub repository humanerd-drew/opencode-drewgent (2 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 666 tokens. 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-08-31.
Other skills, from other repositories
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
brainstorming
You MUST use this before any creative work - creating features, building components, adding functionality, or modifying behavior. Explores user intent, requirements and design before implementation.
chat-pet-sprite-creation
Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.
cpu-profile-analysis
Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…
agent-host-chat-contributions
Build and review cross-cutting agent-host chat behavior through lifecycle contributions. Use when adding turn lifecycle side effects, prompt or context injection, restored-history transformation, protocol-action observation, or when reviewing changes that add code to AgentSideEffects or AgentService.
auto-perf-optimize
Run agent-driven VS Code performance or memory investigations. Use when asked to launch Code OSS, automate a VS Code scenario, run the Chat memory smoke runner, capture renderer heap snapshots, take workflow screenshots, compare run summaries, or drive a repeatable scenario before heap-snapshot analysis.