km-update

Knowledge Manager 업데이트 — upstream pull + vault 경로 재적용.

Command for Claude Code

Install

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.

agentmods
npx agentmods add commands/treylom/knowledge-manager/km-update
Clone the repo
git clone --depth 1 https://github.com/treylom/knowledge-manager

Made for: Claude Code.

Per session 13 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 338 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00013 $0.00338
Opus 5 $0.00006 $0.00169
Sonnet 5 $0.00003 $0.00068
Haiku 4.5 $0.00001 $0.00034

Measured today against content hash 6edf8112c25a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

km-update 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.

.claude/commands/km-update.md · 37 lines

What it actually says

/km-update — Knowledge Manager 업데이트

배포 repo의 최신 버전을 받고, 기존 vault 설정을 자동으로 재적용합니다.

실행

bash scripts/km-update.sh

동작 순서

  1. skip-worktree 설정된 파일들의 잠금 해제
  2. placeholder 템플릿으로 복원 (git checkout HEAD)
  3. git pull origin <current-branch> 로 upstream 업데이트
  4. scripts/configure-vault-paths.sh 재실행
  5. skip-worktree 재설정

주의사항

  • km-config.json 이외의 파일을 수동 편집했다면 stash 또는 commit 후 실행
  • vault 경로를 변경하고 싶다면 /km-update 대신 /knowledge-manager-setup 재실행
  • /km-update 실행 전 권장: git status 로 예상치 못한 로컬 변경 확인

에러 대응

에러 원인 해결
"Uncommitted changes detected" skip-worktree 바깥에서 수동 편집함 git stash 또는 git commit 후 재실행
"Merge conflict" upstream이 치환 구간을 수정했음 git mergetool 또는 수동 해결 후 bash scripts/configure-vault-paths.sh
"km-config.json not found" setup 미실행 /knowledge-manager-setup 먼저 실행
Changes

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.

  1. today First seen · 37 lines · 13 tokens per session scan A 6edf8112c25a

Subscribe to this mod's changes

km-update is a command published in the GitHub repository treylom/knowledge-manager (227 stars, last pushed yesterday), licensed MIT. It adds 13 tokens to every session and 338 once invoked, about $0.0001 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-01.