← Back to PRs

#11157: Add sandbox mode quick switcher for local models

by pearyj open 2026-02-07 13:37 View on GitHub →
stale
## Summary Adds a `/agent` command extension for quick switching between sandboxed and unsandboxed modes for the same local model. ## Motivation Local model users (Ollama, LM Studio) face a trade-off: - **Unsandboxed** = Fast but risky - **Sandboxed** = Safe but slower (requires Docker) The built-in `Ctrl+G` switcher doesn't show sandbox modes, making it hard to know which configuration you're selecting. ## Changes - New plugin: `extensions/sandbox-switcher/` - Implements `/agent` slash command for agent switching - Shows sandbox mode (off/all) before switching - Validates Docker availability for sandboxed agents - Opens new terminal window with isolated session - Platform: macOS (Terminal.app) - Future: Linux/Windows support planned ## Example Usage ```bash /agent # Shows: qwen (qwen3:8b, sandbox: off) # qwen-sandbox (qwen3:8b, sandbox: all) /agent qwen # Opens fast unsandboxed session /agent qwen-sandbox # Opens safe sandboxed session ``` ## Testing Level: Fully Tested - ✅ Tested on macOS 14.6 with Ollama qwen3:8b - ✅ Docker validation works correctly - ✅ Clean session isolation verified - ✅ AppleScript injection protection verified - ✅ All CI checks pass locally ## AI-Assisted Development This PR was developed with AI assistance (Claude). The contributor has reviewed and tested all code to ensure it meets requirements and follows OpenClaw conventions. ## Notes This is my first open source contribution! 🎉 Feedback and suggestions very welcome. Thanks! @pearyj

Most Similar PRs