🧪 Skills
RTK Rewrite
RTK rewrite plugin for OpenClaw. Intercepts exec tool calls and delegates rewrites to rtk rewrite to reduce token usage while preserving command intent.
v0.15.3
Description
name: rtk-rewrite version: "0.15.3" author: "luw2007" repository: "https://github.com/rtk-ai/rtk" license: MIT published: true tags: rtk, openclaw, plugin, token-saving, rewrite description: > RTK rewrite plugin for OpenClaw. Intercepts exec tool calls and delegates rewrites to rtk rewrite to reduce token usage while preserving command intent.
RTK Rewrite OpenClaw Plugin
This plugin hooks into OpenClaw's before_tool_call lifecycle:
- Intercepts only
exectool calls - Calls
rtk rewrite "<command>"to request a rewrite - Replaces the original command when a rewrite is available
- Supports optional audit logs compatible with Claude Code hook audit format
Prerequisites
rtk must be installed and available in PATH.
brew install rtk-ai/tap/rtk
Install Plugin Files
Copy plugin files to the OpenClaw extensions directory:
mkdir -p ~/.openclaw/extensions/rtk-rewrite
cp index.ts openclaw.plugin.json ~/.openclaw/extensions/rtk-rewrite/
openclaw config set plugins.entries.rtk-rewrite.enabled true
openclaw gateway restart
Configuration
enabled: Enables rewrite behavior. Defaulttrue.verbose: Prints rewrite logs to console. Defaultfalse.audit: Writes hook-style audit logs. Defaultfalse.auditDir: Optional audit directory. Falls back toRTK_AUDIT_DIRor~/.local/share/rtk.
Verification
rtk rewrite "git status"
rtk hook-audit --since 7 -v
Reviews (0)
Sign in to write a review.
No reviews yet. Be the first to review!
Comments (0)
No comments yet. Be the first to share your thoughts!