← Back to Pull requests

feat(model): cut over Agent model ownership #593

Closed
unknown closed this pull request without merging on Jul 29, 2026 13:43 UTC
View on GitHub
unknown unknown commented on Jul 27, 2026 14:54 UTC
Author

Description

Makes tagged Models the only runtime source for Agent model configuration.

  • Removes AgentSpec.modelProvider and AgentSpec.modelName from the public API, generated OpenAPI/TypeScript clients, examples, CLI output, and Agent UI.

  • Resolves explicit Deployment.spec.modelRef values through the existing runtime getter and makes the selected Model's provider/name authoritative in both local and Kubernetes adapters.

  • Gives harness Agent Deployments a deterministic namespace default: omitting modelRef materializes and resolves Model/<deployment namespace>/default@latest; explicit refs always win, and a missing default fails reference resolution.

  • Includes effective Model dependencies in deployment fingerprints so default and explicit Model changes trigger the same reconciliation path.

  • Keeps arctl init agent provider/model selection working for source-template generation without persisting those choices in agent.yaml or arctl.yaml; generated projects persist only generic requiredEnv keys.

  • Expands arctl get agents with mode and description columns, including the valid source+harness combination.

  • Documents default-Model ownership, resolution semantics, failure behavior, and the rule that the registry never selects the first or only Model automatically.
  • The broader portable harness-composition scaffold is intentionally separate: #592.

    Change Type

    /kind feature
    /kind breaking_change
    /kind cleanup

    Changelog

    ``release-note
    Agent model configuration now comes from tagged Deployment model references; harness Agent deployments that omit modelRef resolve the namespace's Model/default@latest, and Agent modelProvider/modelName fields are removed.
    `

    Additional Notes

    Current-head local verification:

  • make test-unit — 1,266 tests passed

  • focused declarative CLI, API, fingerprint, and local/Kubernetes runtime tests

  • git diff --check
  • Earlier implementation-pass verification also included:

  • make lint — 0 issues

  • provider-template compatibility coverage for Gemini, OpenAI, Anthropic, Bedrock, and agentgateway

  • exact Docker E2E regression coverage for missing provider credentials

  • focused Agent card UI tests

  • make lint-ui — no errors; one pre-existing React hook warning

  • make build-ui

  • clean-commit make verify`
  • PostgreSQL-backed integration and Kubernetes E2E coverage remain CI-only in this environment.

    Diff: 301 lines (+225 / -76) across 3 files Reviewer: lcopi Review duration: 2808m
    All Vouch review confidence checks passed
    Residual risk 0.16 = Change Risk (0.40) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.40 · 301 lines diff across 3 files
    0.40
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.342
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #593"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 40.1% (MEDIUM) · Higher = larger blast radius
    40.1%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 15.8% · Safe to merge
    15.8%