Skip to content

chore(k8s): put ai.decision_model in the ConfigMap template #4446

Closed

Description

@dan-petty

Problem or Motivation

The change for #4397 adds the setting ai.decision_model. With it empty, no decision point sends a request, so the verify screen stage.verify_screen records nothing in the mode shadow. AIConfig refuses a key that it does not know (extra="forbid"). So k8s/devops/configmap.example.yaml cannot hold ai.decision_model before the image of #4397 runs in the cluster: an older image, or a runner Job of an older image, fails to load the ConfigMap. A person adds the key to the live ConfigMap by hand after the image runs. But devops k8s deploy-stack --stack devops renders the ConfigMap from the template, so the next run of deploy-stack removes the key, and the screen stops again with no error.

Proposed Solution & Architectural Design

After the image of #4397 runs in roadmap-service and in the runner Jobs, add decision_model: typesafe/jev-1.14 under ai in k8s/devops/configmap.example.yaml, and remove the sentence of the template comment that says the key must wait for the image. tests/k8s/test_k8s_configmap_keys.py then checks the key. Start this item only when kubectl -n devops exec deploy/roadmap-service -- devops config get ai.decision_model prints an empty value and no error.

Target Subsystem

Kubernetes manifests (k8s/devops/configmap.example.yaml).

Existing Tool Considered

No tool is needed. The change is one line of the template and one comment.

Standards Compliance

  • I confirm this proposal aligns with AGENTS.md engineering principles (cyclomatic complexity <= 10, nesting <= 5, zero bare exceptions, tests that cover the changed lines).
  • I am willing to submit a pull request implementing this feature with accompanying tests.

Proposed design

Problem statement

The example ConfigMap k8s/devops/configmap.example.yaml does not name ai.decision_model. AIConfig refuses a key that it does not declare, so the template cannot hold the key before the image of #4397 runs in the cluster. An older image then fails to load the ConfigMap. A hand edit of the live ConfigMap is lost at the next run of devops k8s deploy-stack. The verify screen stage.verify_screen then records nothing in the mode shadow, with no error.

Acceptance criteria

Requirement: Decision model in the example ConfigMap

The example ConfigMap MUST set ai.decision_model to typesafe/jev-1.14.

Scenario: A render names the decision model

  • WHEN render_active_devops_configmap renders k8s/devops/configmap.example.yaml
  • THEN the ai section holds decision_model with the value typesafe/jev-1.14.

Requirement: The example loads with the new key

Every key of the rendered example ConfigMap SHALL load into Settings with no unknown key.

Scenario: The key check passes

Requirement: The Jev pilots stay off

The change MUST leave roadmap.stage.jev_screen and roadmap.intake.jev at off.

Scenario: A render keeps the pilots off

  • WHEN the rendered example ConfigMap is read
  • THEN roadmap.stage.jev_screen is off and roadmap.intake.jev is off.

Existing Tool Considered

No check has run. No tool is needed. The change is one key in k8s/devops/configmap.example.yaml, and the test tests/k8s/test_k8s_configmap_keys.py checks the rendered key against Settings. The change builds no code, so the cost to build, keep and fix code is zero tokens and zero elapsed time.

Key questions

  • Does AIConfig refuse a key that it does not declare, so the example ConfigMap cannot hold ai.decision_model before the image that declares it runs?: Yes. AIConfig sets extra="forbid", so an image that does not declare the key fails to load the ConfigMap. ADR 0020 states that ai.decision_model must wait for the image that knows it. [sources: src/devops_cli/config/settings.py, docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md:101]
  • Which value does ai.decision_model take?: typesafe/jev-1.14. The ai comment of the example ConfigMap names TypeSafe Jev as the decision model of this project, and the gateway serves that model. [sources: k8s/devops/configmap.example.yaml, openspec/specs/roadmap-service-deployment/spec.md]
  • Which test checks the new key?: tests/k8s/test_k8s_configmap_keys.py renders the example and asserts that every key is a declared setting, so it checks ai.decision_model with no new test. [sources: tests/k8s/test_k8s_configmap_keys.py, src/devops_cli/k8s/configmap.py]
  • Does the comment of the example ConfigMap hold the sentence that says the key must wait for the image?: No. The ai comment of k8s/devops/configmap.example.yaml holds no wait sentence. The wait statement is in ADR 0020 at line 101. The change adds the key and changes no comment. [sources: k8s/devops/configmap.example.yaml, docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md:101]
  • Which key does the template name, and where does it go?: ai.decision_model, beside ai.model in the ai section of the example ConfigMap. (best practice) [sources: docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md:101, k8s/devops/configmap.example.yaml]
    • Chosen: ai.decision_model beside ai.model. ADR 0020 names the key ai.decision_model, and feat(roadmap): a decision-point registry with a resolver chain #4397 declares it as a field of AIConfig.
    • Rejected: ai.tasks.decision.model in the task map. The task map holds generative models that write text and use tools. A decision model answers one closed question, and ADR 0020 names the key ai.decision_model.
  • Does the change amend the ordering note of ADR 0020?: No. The note records the order that this item obeys, and the key enters the template only after the image knows it. (best practice) [sources: docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md:101]
    • Chosen: Leave ADR 0020 unchanged. The note stays true after the merge: the key waited for the image, and the image now knows it.
    • Rejected: Add an amendment line to ADR 0020. No rule changes, and the line states a fact that the record already holds.

Fit

Fits in one pull request.

Suspected block

The rollout of the image of #4397 to the cluster: start only when kubectl -n devops exec deploy/roadmap-service -- devops config get ai.decision_model prints an empty value and no error.

Dependencies

#4397

Alternatives check of 2026-11-11: not-applicable.
Class: chore, no search.
Tool: none found.

Activity

  1. added
    source/agent
    type/chore
    scope/k8s
    status/new
    value/medium
    effort/low
    on Nov 11, 2026
  2. dan-petty commented on Nov 11, 2026

    @dan-petty
    OwnerAuthor

    Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones.

    • Type: type/chore. The chore prefix of the title gives the type.
    • Scope: scope/k8s. The (k8s) scope of the title gives the scope.
    • Priority: P3-Low. It is a follow-up chore that only matters after #4397 is deployed and does not block any user-facing feature.
    • Value: Medium. It prevents a silent loss of the decision_model key on the next deploy-stack run, but the system runs without it until #4397 ships.
    • Effort: Low. The body states the change is one line in the template, one comment removal, and one test assertion.
    • Related: fix(k8s): the ConfigMap template names DeepSeek for analysis #4369, which asks for a different change. Both update k8s/devops/configmap.example.yaml so the template matches the live ConfigMap, but this item adds ai.decision_model while #4369 sets ai.tasks.analysis.model.
  3. added
    priority/p3-low
    on Nov 11, 2026
  4. devops-cli-service commented on Nov 11, 2026

    @devops-cli-service
    Contributor

    Refine cannot set this item to Ready at 3180bf1 while the items below stay open. The next refine round looks at the item again when they close, or when a person replies in a comment or edits the body.

    The next refine round also looks at the item again when a commit on the default branch changes one of these files: src/devops_cli/config/settings.py.

  5. dan-petty commented on Nov 11, 2026

    @dan-petty
    OwnerAuthor

    The start condition of this item checks only the Service image. CronJob devops-cli-runner (image runner) and Deployment mcp-server (image mcp-server) also load ConfigMap devops-cli-config, and Image Updater keeps a separate digest for each image. An older runner Job or MCP server stops at the load of settings when the ConfigMap holds ai.decision_model.

    Start this item only when all three images know the key:

    1. The comment Live since of the release is on feat(roadmap): a decision-point registry with a resolver chain #4397. That comment checks the Service digest and the runner digest.
    2. kubectl -n devops exec deploy/roadmap-service -- devops config get ai.decision_model prints an empty value and no error.
    3. kubectl -n devops exec deploy/mcp-server -- devops config get ai.decision_model prints an empty value and no error.

    #4496 changes the texts of the gate (docs/roadmap/stage.md, the ai comment of k8s/devops/configmap.example.yaml). The review of PR #4453 found this gap.

  6. devops-cli-service commented on Nov 11, 2026

    @devops-cli-service
    Contributor

    Alternatives check: not-applicable

    Class: chore. The check makes no search and no model call for an item of this class.

    Tool: none found

    Checked on 2026-11-11. A person decides what this means for the item. The check changes no label and closes no issue.

  7. added
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 15, 2026
  8. removed
    status/in-review
    on Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/lowpriority/p3-lowscope/k8ssource/agenttype/chorevalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions