← Back to PRs

#20785: feat: add bypass-model support for skill commands

by MichaelC001 open 2026-02-19 09:23 View on GitHub →
agents size: S
## Summary Add `bypass-model: true` and `exec-command: "..."` frontmatter support for skills, allowing slash commands to execute shell commands directly without AI model invocation. ## Why This Matters **With bypass-model, OpenClaw becomes a true Intelligent Assistant — not just an AI Assistant.** - 🧠 **Uses AI when AI is needed** — complex reasoning, creative tasks, conversations - ⚡ **Uses direct commands when commands are enough** — system queries, scripts, utilities - 💰 **Zero tokens wasted** on deterministic operations - 🎯 **100% accuracy** for command-based tasks (no hallucination possible) - 🚀 **Instant response** — no model latency for simple commands This is the difference between a smart tool that knows when to think vs. one that overthinks everything. ## Usage ```yaml # ~/.openclaw/skills/ip/SKILL.md --- name: ip description: Get public IP address user-invocable: true bypass-model: true exec-command: "curl -s ipinfo.io/ip" --- ``` Arguments pass through automatically: - `/git status` → executes `git status` - `/note list` → executes `note list` - `/docker ps` → executes `docker ps` ## Changes | File | Change | |------|--------| | `src/agents/skills/workspace.ts` | Parse `bypass-model` and `exec-command` from frontmatter | | `src/auto-reply/reply/get-reply-inline-actions.ts` | Execute bypass logic before normal dispatch | | `src/auto-reply/reply/get-reply-directives.ts` | Fix bug: skill commands now load without model aliases | ## Testing 1. Create a bypass-model skill as shown above 2. Invoke via `/ip` in any channel 3. Verify instant response without model usage ## Backwards Compatibility - ✅ No breaking changes - ✅ Existing skills work exactly as before - ✅ Opt-in via explicit `bypass-model: true` --- **Fixes:** #7985 **Also addresses:** #10366 cc @ShenWang96 @twobotass @5hanth

Most Similar PRs