feat(skills): add RTK_DISABLED=1 opt-out skill and install via rtk init#1848
feat(skills): add RTK_DISABLED=1 opt-out skill and install via rtk init#1848bb1 wants to merge 2 commits into
Conversation
Add an agent-agnostic skill (skills/raw-command-output/SKILL.md) that teaches LLM agents to prefix commands with RTK_DISABLED=1 when they need raw, uncompressed output. This leverages the existing Rust binary override (rtk-ai#345) and works across all agent integrations. Install the skill to ~/.agents/skills/ alongside the OpenCode plugin during rtk init --opencode. Also install during combined Claude+OpenCode modes. Show skill path in rtk status output. On uninstall (rtk init --uninstall), remove the skill file alongside the plugin.
0265205 to
e93d10d
Compare
rtk init now writes SKILL.md to both ~/.agents/skills/raw-command-output/ and ~/.claude/skills/raw-command-output/ so Claude Code discovers the RTK_DISABLED opt-out skill natively. Install, uninstall, and status flows updated for both locations.
|
@pszymkowiak — would appreciate your review on this when you get a chance. Quick context: this adds an agent-agnostic One design question: currently only OpenCode and Claude Code support the |
Summary
skills/raw-command-output/SKILL.md) that teaches LLM agents to prefix commands withRTK_DISABLED=1when they need raw, uncompressed output (JSON/XML/CSV for data analysis)~/.agents/skills/duringrtk init --opencode(and combined Claude+OpenCode modes)rtk statusoutput; remove on uninstallMotivation
When rtk compresses command output for token savings, agents sometimes cannot parse the result (e.g., JSON data for analysis). This causes infinite retry loops where the agent keeps re-issuing the same command with slight variations.
The
RTK_DISABLED=1env prefix already exists in the Rust binary (#345) but agents don't know about it. This skill teaches them to use it proactively.Related Issues
rtk git branch --show-currentloop in opencode #732 —rtk git branch --show-currentloop in OpenCodeRTK_DISABLED=1env var to bypass hooks (already implemented in binary; this PR makes agents aware of it)Changes
skills/raw-command-output/SKILL.mdsrc/hooks/constants.rsAGENTS_DIR,SKILLS_SUBDIR,RTK_SKILL_DIR,RTK_SKILL_FILEconstantssrc/hooks/init.rsrtk_skill_path(),ensure_rtk_skill_installed(), update install/remove/status flowsTesting
cargo checkpasses (verified via Dockerrust:latest)~/.agents/skills/raw-command-output/SKILL.md