add-rtk
Skill4 starsChanged 6 months agoMITView on GitHub
Install rtk token-compression proxy into agent containers. Routes Bash tool calls through rtk for 60–90% token savings on dev commands (git, cargo, pytest, docker, kubectl, etc.).
- Pipes a download into a shell
3 other projects use a version of this, 3 of them edited.
Adopted by
Most recently taken up by
- prathish-ks/isthmusedited, first seen Oct 6, 2026
- nanocoai/nanoclawedited, first seen Oct 4, 2026
- TomGranot/groupguardedited, first seen Sep 3, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 3
- nanocoai/nanoclaw★ 31k55% same
- TomGranot/groupguard★ 455% same
- prathish-ks/isthmus★ 255% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository51 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- container/CLAUDE.mdCLAUDE.md
- add-amplifier-agentSkill
- add-atomic-chat-toolSkill
- add-codexSkill
- add-dashboardSkill
- add-deltachatSkill
- add-discordSkill
- add-emacsSkill
- add-gcal-toolSkill
- add-gchatSkill
- add-githubSkill
- add-gmail-toolSkill
- add-imessageSkill
- add-karpathy-llm-wikiSkill
- add-linearSkill
- add-macos-statusbarSkill
- add-matrixSkill
- add-mnemonSkill
- add-ollama-providerSkill
- add-ollama-toolSkill
- add-opencodeSkill
- add-parallelSkill
- add-resendSkill
- add-signalSkill
- add-slackSkill
- add-teamsSkill
- add-telegramSkill
- add-vercelSkill
- add-webexSkill
- add-wechatSkill
- add-whatsapp-cloudSkill
- add-whatsappSkill
- clawSkill
- convert-to-apple-containerSkill
- customizeSkill
- debugSkill
- get-qodo-rulesSkill
- init-first-agentSkill
- init-onecliSkill
- manage-channelsSkill
- manage-mountsSkill
- migrate-from-openclawSkill
- migrate-from-v1Skill
- migrate-nanoclawSkill
- qodo-pr-resolverSkill
- setupSkill
- update-nanoclawSkill
- update-skillsSkill
- use-native-credential-proxySkill
- x-integrationSkill
The file
We split this skill into the rules it gives an agent
7 rules. 2 are common, 2 are distinctive, and 3 are very specific to this project.
2
Common
Most of the 3 edited versions we read keep these.
2
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Common: line 22
If the script put the binary elsewhere, move it:
- Distinctive: line 48
Read current mounts first:
- Very specific: line 81
Add the PreToolUse entry using jq to merge safely:
- Very specific: line 90
If PreToolUse already exists, append instead of overwriting:
- Distinctive: line 107
Ask the agent to run git status or any other supported command.
- Very specific: line 128
Verify the hook is in settings.json:
- Common: line 134
If missing, re-run Step 4.
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Add rtk
Install rtk — a CLI proxy delivering 60–90% token savings on common dev commands (git, cargo, pytest, docker, kubectl, etc.) — and wire it transparently into agent containers via the Claude Code PreToolUse hook.
What this sets up
rtkbinary at~/.local/bin/rtkon the host~/.local/bin/rtkmounted read-only at/usr/local/bin/rtkinside the target agent group's containersPreToolUsehook in the agent group'ssettings.jsonso every Bash call is automatically filtered through rtk — no CLAUDE.md instructions needed
Step 1 — Install rtk on the host
curl -fsSL https://raw.githubusercontent.com/rtk-ai/rtk/refs/heads/master/install.sh | shIf the script put the binary elsewhere, move it:
find ~/.local ~/.cargo/bin ~/bin -name rtk 2>/dev/null
mv "$(which rtk 2>/dev/null)" ~/.local/bin/rtkVerify:
~/.local/bin/rtk --version
chmod +x ~/.local/bin/rtk # if neededStep 2 — Identify the target agent group
ncl groups listNote the group ID (e.g. ag-1776342942165-ptgddd). Repeat Steps 3–5 for each group.
Step 3 — Mount rtk into the container config
additional_mounts is a JSON column not exposed via ncl config update. Update it directly via the DB helper, merging with any existing mounts.
Read current mounts first:
pnpm exec tsx scripts/q.ts data/v2.db \
"SELECT additional_mounts FROM container_configs WHERE agent_group_id = '<group-id>'"Then write the merged array (include all existing entries plus the rtk entry):
pnpm exec tsx scripts/q.ts data/v2.db \
"UPDATE container_configs SET additional_mounts = '<merged-json>' WHERE agent_group_id = '<group-id>'"The rtk entry to append: {"hostPath":"/home/<user>/.local/bin/rtk","containerPath":"/usr/local/bin/rtk","readonly":true}
Verify:
pnpm exec tsx scripts/q.ts data/v2.db \
"SELECT additional_mounts FROM container_configs WHERE agent_group_id = '<group-id>'"Step 4 — Add the PreToolUse hook to settings.json
Each agent group has a settings.json at:
data/v2-sessions/<group-id>/.claude-shared/settings.jsonThis file is mounted at /home/node/.claude/settings.json inside the container and is read by Claude Code for hooks, env, and model config.
Add the PreToolUse entry using jq to merge safely:
SETTINGS="data/v2-sessions/<group-id>/.claude-shared/settings.json"
jq '.hooks.PreToolUse = [{"matcher":"Bash","hooks":[{"type":"command","command":"rtk hook claude"}]}]' \
"$SETTINGS" > /tmp/rtk-settings.json && mv /tmp/rtk-settings.json "$SETTINGS"If PreToolUse already exists, append instead of overwriting:
jq '.hooks.PreToolUse += [{"matcher":"Bash","hooks":[{"type":"command","command":"rtk hook claude"}]}]' \
"$SETTINGS" > /tmp/rtk-settings.json && mv /tmp/rtk-settings.json "$SETTINGS"Step 5 — Restart the container
ncl groups restart --id <group-id>No --message needed — the hook is transparent and requires no agent awareness.
Verify
Ask the agent to run git status or any other supported command. rtk intercepts it silently. Check savings with:
~/.local/bin/rtk gainTroubleshooting
rtk: command not found inside the container
Mount wasn't applied or container wasn't restarted:
pnpm exec tsx scripts/q.ts data/v2.db \
"SELECT additional_mounts FROM container_configs WHERE agent_group_id = '<group-id>'"
# Look for entry with /usr/local/bin/rtk
ncl groups restart --id <group-id>Hook not firing
Verify the hook is in settings.json:
jq '.hooks.PreToolUse' data/v2-sessions/<group-id>/.claude-shared/settings.jsonIf missing, re-run Step 4.
Binary won't execute — permission denied
chmod +x ~/.local/bin/rtkDoes it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

