Skip to content

πŸ› dashboard: make the agent Model picker readable for gateway backends - #12165

Merged
hivecommons-hive[bot] merged 1 commit into
v5from
fix/9945-agent-model-picker-labels
Oct 15, 2026
Merged

hivecommons-hive[bot] merged 1 commit into
v5from
fix/9945-agent-model-picker-labels

Conversation

@clubanderson

Copy link
Copy Markdown
Member

Refs #9945 β€” cc @MikeSpreitzer

Follow-up to #12160. Mike couldn't tell how to "unset" an agent's model in Configuration β†’ General: the inherit option was labelled "(from launch command)", gateway ids were shown with the provider prefix stripped (glm-5-3 for rits/zai-org/glm-5-3) while the stale current model kept its prefix (aws/claude-sonnet-4-6), and nothing said that current model was the reason every call 403'd.

Not a second bug: option values were already the full gateway ids (value: m, label m.split('/').pop()), so choosing "glm-5-3" saved rits/zai-org/glm-5-3. Only the labels were misleading. A test now pins that.

Changes

  • Inherit option β†’ (backend default β€” rits/zai-org/glm-5-3) when the gateway default_model is known; (backend default β€” the gateway's default_model, Settings β†’ Model Gateways) when not; (backend default β€” chosen by the claude CLI) for CLI backends.
  • Every option shows the full model id; a current model that isn't in the gateway's entitled set (from the last key-info probe / team-403) is labelled (current β€” not allowed by gateway).
  • Select tooltip + help text state the precedence: per-agent model β†’ gateway default_model β†’ CLI default. πŸ› Fall back to the gateway default_model when the per-agent model is not entitledΒ #12160 semantics (proxy fallback to the gateway default) unchanged.
  • /api/inference/models/{backend} now also returns default_model and the full entitled_models set.
  • Docs note in docs/inference-backends.md; changelog fragment.

Tests: agent_model_picker_9945_test.go β€” static wiring, node-rendered labels for stale/none/explicit/unknown-entitlement/CLI cases (values stay full ids), and the API reporting default_model/entitled_models. cli_pin_model_options_test.go harness updated.

Validation: gofmt -l pkg/dashboard clean, go vet ./pkg/dashboard/, go build ./..., go test ./pkg/dashboard/... all pass.

The "(from launch command)" option is now "(backend default β€” <resolved
default model>)", options show full gateway model ids, a current model
outside the gateway's entitled set is flagged "(current β€” not allowed by
gateway)", and the select tooltip states the precedence. The models API
reports default_model and entitled_models. Saved values were always full
ids; only labels changed.

Refs #9945

Signed-off-by: Andrew Anderson <andy@clubanderson.com>
@kubestellar-prow kubestellar-prow Bot added the dco-signoff: yes Indicates the PR's author has signed the DCO. label Oct 15, 2026
@kubestellar-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign nicholasjackson for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubestellar-prow kubestellar-prow Bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Oct 15, 2026
@github-actions

github-actions Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Open PR overlap check

Base branch: v5

Conflicts are checked with every PR merged onto the current tip of v5, so a PR that only needs a rebase is not reported as conflicting with its siblings.

PR Title Relation Files
#12158 ✨ review: add review.shadow to record would_have_held for the review gate same files src/pkg/dashboard/static/index.html
#12167 πŸ› Admit operator-trusted registry contributors in the contributor-lane auto-merge tier same files src/pkg/dashboard/static/index.html
#12159 ✨ dashboard: iPhone widget entry in the avatar menu deep-links into Scriptable same files src/pkg/dashboard/static/index.html
#12164 🌱 tokens: per-issue/PR/head-SHA launch attribution over the token collector same files src/pkg/dashboard/static/index.html

@hivecommons-hive

Copy link
Copy Markdown
Contributor

merged by Hive trusted-author auto-merge: author @clubanderson holds role owner and GitHub permission admin on repo; CI green at 675f1c4.

@kubestellar-prow
kubestellar-prow Bot deleted the fix/9945-agent-model-picker-labels branch October 15, 2026 19:22
@github-actions

Copy link
Copy Markdown
Contributor

Thank you for your contribution! Your PR has been merged.

We'd love to hear how your experience was: share feedback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dco-signoff: yes Indicates the PR's author has signed the DCO. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant