From 5351ec2e407edac690f21e8eaf20df4d26a1171f Mon Sep 17 00:00:00 2001 From: autonomic-bot Date: Mon, 22 Jun 2026 20:23:26 +0000 Subject: [PATCH] launch-upgrader: default to opencode-go/glm-5.2 when unset MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Weekly upgrade run now defaults backend=opencode, model=opencode-go/glm-5.2 with no env set. Model default tracks backend (claude override → sonnet). Override via LOOP_BACKEND/LOOP_MODEL or /srv/cc-ci/upgrader.env. Co-Authored-By: Claude Opus 4.8 --- cc-ci-plan/launch-upgrader.py | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/cc-ci-plan/launch-upgrader.py b/cc-ci-plan/launch-upgrader.py index c4f50ca..9ccf109 100644 --- a/cc-ci-plan/launch-upgrader.py +++ b/cc-ci-plan/launch-upgrader.py @@ -14,10 +14,11 @@ Usage: launch-upgrader.py attach tmux attach to the session Env: - LOOP_BACKEND claude (default) | opencode — also accepts UPGRADER_BACKEND - LOOP_MODEL model flag (overrides UPGRADER_MODEL) - UPGRADER_MODEL sonnet (default for claude) | provider/model for opencode, e.g. - opencode-go/glm-5.2 (OpenCode Go subscription) or tinfoil/deepseek-v4-pro + LOOP_BACKEND opencode (default) | claude — also accepts UPGRADER_BACKEND + LOOP_MODEL model flag (overrides UPGRADER_MODEL); default tracks backend — + opencode→opencode-go/glm-5.2, claude→sonnet + UPGRADER_MODEL provider/model for opencode, e.g. opencode-go/glm-5.2 (OpenCode Go + subscription) or tinfoil/deepseek-v4-pro; sonnet etc. for claude UPGRADER_ARGS extra args passed to /upgrade-all (e.g. "n8n ghost", "--dry-run") claude backend: @@ -37,8 +38,12 @@ WORKDIR = os.environ.get("UPGRADER_DIR", "/srv/cc-ci") LOG_DIR = os.environ.get("LOG_DIR", "/srv/cc-ci/.cc-ci-logs") # LOOP_BACKEND / LOOP_MODEL take precedence (unified control from the operator). -BACKEND = os.environ.get("LOOP_BACKEND", os.environ.get("UPGRADER_BACKEND", "claude")) -MODEL = os.environ.get("LOOP_MODEL", os.environ.get("UPGRADER_MODEL", "sonnet")) +# Default backend+model is the OpenCode Go subscription on glm-5.2; override either via env. +# The model default tracks the backend so an explicit `LOOP_BACKEND=claude` (without a model) +# still gets a sensible claude model rather than a glm id. +BACKEND = os.environ.get("LOOP_BACKEND", os.environ.get("UPGRADER_BACKEND", "opencode")) +_DEFAULT_MODEL = "opencode-go/glm-5.2" if BACKEND == "opencode" else "sonnet" +MODEL = os.environ.get("LOOP_MODEL", os.environ.get("UPGRADER_MODEL", _DEFAULT_MODEL)) CLAUDE_BIN = os.environ.get("CLAUDE_BIN", "claude") CLAUDE_FLAGS = os.environ.get("CLAUDE_FLAGS", "--dangerously-skip-permissions")