OpenClaw-Setup/openclaw-setup-max/docs/operations/MODEL_SWITCHING.md

1.9 KiB

Model Switching (Paid vs Free)

This setup adds two model profiles:

  • paid -> moonshot/kimi-k2.5 with local Ollama fallbacks
  • free -> local Ollama-only stack

On-demand switch (immediate)

cd /Volumes/Data/openclaw-setups/openclaw-setup-max
bash ./scripts/model_profile_switch.sh free

Switch back:

bash ./scripts/model_profile_switch.sh paid

Notes:

  • This updates OpenClaw default + fallbacks.
  • It also pushes /model ... to the active agent:main:main session by default.

Show status and available profiles

bash ./scripts/model_profile_switch.sh status

Schedule auto-switching (example: free from 9pm-7am)

  1. Edit config:
cd /Volumes/Data/openclaw-setups/openclaw-setup-max
open config/model-schedule.config.json

Ensure:

{
  "enabled": true,
  "dayProfile": "paid",
  "nightProfile": "free",
  "dayStartHour": 7,
  "nightStartHour": 21
}
  1. Install schedule launchd job:
bash ./scripts/install_model_schedule_guard_launchd.sh

Note:

  • Installer stages runtime files in ~/Library/Application Support/openclaw-local-model-guard.
  • If you edit configs/scripts in this repo, rerun installer scripts to sync stage files.
  1. Verify:
launchctl print gui/$(id -u)/ai.openclaw.local.model-schedule-guard
tail -n 50 /tmp/openclaw-model-schedule-guard.log /tmp/openclaw-model-schedule-guard.err.log

If schedule is enabled, it will override manual model switches on the next run.

This warns when high-cost models are left on and can auto-revert.

bash ./scripts/install_model_budget_guard_launchd.sh

Or install both schedule + budget:

bash ./scripts/install_local_model_guardrails.sh

Disable / remove launchd jobs

launchctl bootout gui/$(id -u)/ai.openclaw.local.model-schedule-guard 2>/dev/null || true
launchctl bootout gui/$(id -u)/ai.openclaw.local.model-budget-guard 2>/dev/null || true