diff --git a/openclaw-setup-copilot/README.md b/openclaw-setup-copilot/README.md index c9867cf..174c2a5 100644 --- a/openclaw-setup-copilot/README.md +++ b/openclaw-setup-copilot/README.md @@ -207,6 +207,45 @@ Default schedule behavior: - Work hours (`08:00` to `18:00` local time): `paid` profile - Off-hours (`18:00` to `08:00` local time): `free` profile +Schedule wiring (important): +- `config/model-schedule.config.json` controls time windows and which script applies profiles. +- `switchScript` should be `./scripts/model_profile_switch.sh`. +- `config/model-profiles.config.json` defines what `paid` and `free` actually mean (primary + fallbacks). + +Expected schedule config shape: + +```json +{ + "enabled": true, + "dayProfile": "paid", + "nightProfile": "free", + "dayStartHour": 8, + "nightStartHour": 18, + "sessionKey": "agent:main:main", + "switchScript": "./scripts/model_profile_switch.sh", + "stateFile": "~/.openclaw/model-schedule-state.json" +} +``` + +Important behavior difference vs Max: +- Copilot `config/model-profiles.config.json` starts with empty model IDs in this template copy. +- `bash ./scripts/install_copilot_guardrails.sh` runs `configure_copilot_guardrails_defaults.sh`, detects available `github-copilot/*` models, and writes concrete `paid`/`free` models into `config/model-profiles.config.json`. +- Until that step runs on the target machine (after `copilot auth login`), schedule/profile switching has no concrete model IDs to apply. + +Quick verify commands: + +```bash +cat config/model-schedule.config.json +cat config/model-profiles.config.json +``` + +After installing guardrails, verify staged runtime files used by launchd: + +```bash +cat ~/Library/Application\ Support/openclaw-copilot-guard/model-schedule.config.json +cat ~/Library/Application\ Support/openclaw-copilot-guard/model-profiles.config.json +``` + Manual profile switch: ```bash diff --git a/openclaw-setup-copilot/docs/operations/troubleshooting.md b/openclaw-setup-copilot/docs/operations/troubleshooting.md index 3941e65..da31b17 100644 --- a/openclaw-setup-copilot/docs/operations/troubleshooting.md +++ b/openclaw-setup-copilot/docs/operations/troubleshooting.md @@ -167,7 +167,9 @@ Checks: launchctl print gui/$(id -u)/ai.openclaw.copilot-model-schedule-guard tail -n 100 /tmp/openclaw-copilot-model-schedule-guard.log /tmp/openclaw-copilot-model-schedule-guard.err.log cat config/model-schedule.config.json +cat config/model-profiles.config.json cat ~/Library/Application\ Support/openclaw-copilot-guard/model-schedule.config.json +cat ~/Library/Application\ Support/openclaw-copilot-guard/model-profiles.config.json ``` Fixes: @@ -176,6 +178,10 @@ Fixes: - `bash ./scripts/install_copilot_guardrails.sh` - For a quick manual switch without live push: - `bash ./scripts/model_profile_switch.sh free --no-live` +- If `profiles.paid.primary` / `profiles.free.primary` are empty, run: + - `copilot auth login` + - `bash ./scripts/install_copilot_guardrails.sh` + This populates `config/model-profiles.config.json` and restages launchd runtime configs. ## 12) Copilot auth watchdog alerting repeatedly