From 742f4ef91677551c66778cfb01e22d1a8bc3597c Mon Sep 17 00:00:00 2001 From: atlas Date: Sat, 4 Jul 2026 17:52:48 +0200 Subject: [PATCH] feat(#2220): add low and max effort levels claude --effort now accepts low, medium, high, xhigh, max. Expand EFFORT_LEVELS from 3 to 5, update NixOS enum + description, and fix the stale doc comment in web_ui.rs. Closes #2220 --- hive-ag3nt/src/events.rs | 2 +- hive-ag3nt/src/web_ui.rs | 2 +- nix/templates/harness-base.nix | 14 ++++++++------ 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/hive-ag3nt/src/events.rs b/hive-ag3nt/src/events.rs index e69a9cff..854ed0ec 100644 --- a/hive-ag3nt/src/events.rs +++ b/hive-ag3nt/src/events.rs @@ -583,7 +583,7 @@ pub const DEFAULT_EFFORT: &str = "medium"; /// Valid claude `--effort` levels, ascending. The operator picker is /// constrained to these; [`is_valid_effort`] guards the persist path. -pub const EFFORT_LEVELS: [&str; 3] = ["medium", "high", "xhigh"]; +pub const EFFORT_LEVELS: [&str; 5] = ["low", "medium", "high", "xhigh", "max"]; /// True iff `level` is one of [`EFFORT_LEVELS`]. #[must_use] diff --git a/hive-ag3nt/src/web_ui.rs b/hive-ag3nt/src/web_ui.rs index 694d6dba..1925ea90 100644 --- a/hive-ag3nt/src/web_ui.rs +++ b/hive-ag3nt/src/web_ui.rs @@ -461,7 +461,7 @@ struct StateSnapshot { /// runtime via `POST /api/effort`; applies on the next session. effort: String, /// Selectable effort levels for the picker, ascending. Fixed set - /// (`medium`, `high`, `xhigh`) — sourced from + /// (`low`, `medium`, `high`, `xhigh`, `max`) — sourced from /// [`crate::events::EFFORT_LEVELS`], not operator-configurable like /// `available_models`. The frontend renders one button per entry. available_efforts: Vec, diff --git a/nix/templates/harness-base.nix b/nix/templates/harness-base.nix index 0629116b..1610fa6f 100644 --- a/nix/templates/harness-base.nix +++ b/nix/templates/harness-base.nix @@ -219,9 +219,11 @@ in options.hyperhive.effortLevel = lib.mkOption { type = lib.types.enum [ + "low" "medium" "high" "xhigh" + "max" ]; default = "medium"; example = "high"; @@ -231,12 +233,12 @@ in effort as operator-override-file → this env → built-in `"medium"`, and passes the result to `claude --effort` at turn launch. - `"medium"` (the default) keeps token spend low and works well with - the harness across families. `"high"` matches the current platform - default; `"xhigh"` is recommended for coding / high-autonomy work on - capable models (Opus 4.8+) at higher token cost. The operator can - override at runtime per-agent via the web UI (applied on the next - session); any rebuild that changes this option resets that override. + Ascending scale: `"low"` (minimal thinking budget), `"medium"` + (default — balanced), `"high"` (platform default), `"xhigh"` + (recommended for autonomous coding on capable models), `"max"` + (maximum thinking budget, highest cost). The operator can override + at runtime per-agent via the web UI (applied on the next session); + any rebuild that changes this option resets that override. ''; };