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/opencode-knowledge-conventionnpx skills add humanerd-drew/opencode-drewgent --skill opencode-knowledge-conventiongit 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.00623 |
| Opus 5 | $0.00000 | $0.00311 |
| Sonnet 5 | $0.00000 | $0.00125 |
| Haiku 4.5 | $0.00000 | $0.00062 |
Grade A, and why
opencode-knowledge-convention 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 yesterday.
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
Knowledge Management Convention
이 convention은 @{{AGENT_NAME_LOWER}}/opencode-knowledge 플러그인 설치 시 적용된다.
remember(), recall(), memory-stats() 툴이 제공될 때 반드시 따라야 할 규칙.
Rules (Tier 1 — Autonomous)
R1: 세션 시작 시 자동 recall
세션 시작 직후, 무조건 recall("recent decisions|active context") 호출
결과가 있으면 system context에 통합하여 응답 품질 향상
R2: 과거 맥락 언급 시 즉시 검색
사용자가 "저번에", "아까", "전에", "그때", "예전에" 등 과거 맥락 언급
→ 지체 없이 recall() 호출 후 응답
R3: 결정/선호/패턴 발견 시 즉시 저장
다음 패턴 발견 시 remember()로 즉시 저장:
- 명시적 결정 ("이걸로 하자", "X 선택")
- 사용자 선호 ("나는 Y 방식이 좋아")
- 반복 작업 패턴 ("이건 항상 Z로 해결")
- 아키텍처 결정 ("이유 때문에 X 선택")
- 금지/규칙 ("절대 하지마")
R4: 세션 종료 시 저장 확인
세션이 자연스럽게 종료될 때:
- memory-stats() 호출
- 오늘 저장된 사실이 0이면, 놓친 게 없는지 확인
R5: Secrets 절대 저장 금지
API key, 토큰, 비밀번호, 개인정보는 절대 remember()로 저장하지 않음
→ vault_cli가 canonical path
→ 실수로 들어갔으면 즉시 remove (수동)
Storage
- 파일 위치:
~/.{{AGENT_NAME_LOWER}}/.opencode/knowledge.db - 엔진: SQLite + FTS5 (built-in full-text search)
- FTS5 기능: stemming, ranking, phrase matching, boolean operators
- types: fact, decision, preference, pattern, session
- 세션 저장: sessions 테이블 (id, title, message_count)
- 보안: 평문. secrets 저장 금지.
의존성
- opencode 1.17.10+
- tools/ 디렉토리 자동 발견 기능
- 별도 서버/DB/API key 불필요
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.
- yesterday First seen · 67 lines · 0 tokens per session scan A a962cfaf8a8f
opencode-knowledge-convention 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 623 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.
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
babysit-pr
Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…
imagegen
Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…
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…
next-cache-components-optimizer
Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…