Skip to content

feat(roadmap): research checks project standards and suggests changes #5514

Open

Description

@dan-petty

Problem or Motivation

No step checks an item against the ADRs and standards in force for its scope labels before refine and stage. The resolver needs a poor standards fit as a cause, and no step writes it. The approved pipeline split design (tracker #5482) adds a standards step and a suggestions step to the research unit.

Proposed Solution & Architectural Design

  • Step 3 standards: a rubric over the ADRs in force and the standards for the scope labels of the item. It gives a score and the gaps. Jev scores the closed rubric choice.
  • Step 4 suggestions: improvements, as text for refine.
  • Each step writes research.standards or research.suggestions with its at and the outside hash.
  • A poor fit writes the resolve cause.
  • Both steps stay in mode plan until E5 shows a lift for them.

Target Subsystem

Roadmap Service and roadmap jobs (src/devops_cli/roadmap/, the research unit).

Acceptance Criteria

  • Test first: a fixture item that breaks an ADR in force gets that gap. The test fails on the base.
  • A test: a poor fit writes the resolve cause.
  • Live proof: after the merge and the release, the two steps run as the App in mode plan on 5 items of the stage window. A comment on this issue gives the result lines and the gaps.

Existing Tool Considered

Jev (rubric scores) and the ADR set in docs/adr/ cover the inputs. No open tool scores an item against these ADRs. Build: 200,000 to 400,000 agent tokens and 1 day.

Related

Tracker #5482, Phase 6. Depends on #5513 and #5512. #4805, #5049, #4830.

Source: #5482

Alternatives check of 2026-11-30: partly.
Tool: backstage/community-plugins (https://github.com/backstage/community-plugins), Apache-2.0, last activity 2026-11-30, maintained.
Reason: The searches found only the Backstage tech-insights scorecards in backstage/community-plugins: weighted checks give a score and the failed checks, but it reads no ADRs in force and writes no roadmap record, so it covers a part.

Covers:

  • Weighted checks that give one total score
  • Failed checks show the gaps of an item
  • Checks run on collected facts, not on model text

Lacks:

  • No read of the ADRs in force or their supersede status
  • No table from scope labels to checks
  • No roadmap job record, resolve cause or suggestion text
  • Needs a Backstage app and a catalog entity

Proposed design

Problem statement

No research step checks an item against the ADRs in force and the standards for its scope/* labels before refine and stage. The resolver has no poor standards fit cause, and refine gets no suggestions. This change adds step 3 standards and step 4 suggestions to the research unit. Each step writes a record with its at and the outside hash. A poor fit writes the standards resolve cause. Both steps stay in mode plan until the evaluation shows a lift.

Acceptance criteria

Requirement: Gap from a broken ADR

The standards step SHALL write each rubric gap of the item and the ADR or guideline that it breaks.

Scenario: An item that breaks an accepted ADR

  • WHEN the test runs the standards step on a fixture item that breaks an ADR with status accepted in docs/adr/
  • THEN the decoded research.standards record holds a gap that names that ADR's number and the rubric check, and the test fails on the base commit

Requirement: Only ADRs in force

The standards step MUST read only the ADRs that are in force: an accepted ADR, or one with no status, that no ADR supersedes.

Scenario: A superseded ADR

  • WHEN the test runs the standards step on a fixture item that breaks only a superseded ADR
  • THEN the decoded research.standards record holds no gap for that ADR

Requirement: Score from the closed rubric

The standards step MUST give one band of the closed decision-point set continue, review or flag.

Scenario: An item that passes each rubric check

  • WHEN the test runs the standards step on a fixture item that passes each check of its scope/* labels
  • THEN research.standards.score is the continue band and gaps is an empty list

Requirement: Poor fit writes the resolve cause

A poor standards fit MUST write the standards resolve cause that the resolver reads.

Scenario: An item in the flag band

  • WHEN the test runs the standards step on a fixture item whose score is the flag band
  • THEN the item's job record holds the standards resolve cause, and the resolver returns standards for the item

Requirement: Plan mode changes no decision

Both steps MUST write their records and change no band, label or status while their mode is plan.

Scenario: A plan-mode run on an item that breaks an ADR

  • WHEN the test runs both steps in mode plan on a fixture item
  • THEN both decoded records hold at and the outside hash, and the item keeps its labels and its status

Requirement: Suggestion text for each gap

The suggestions step SHALL write one improvement text for each standards gap.

Scenario: Two gaps in the standards record

  • WHEN the test runs the suggestions step with a fake model on a standards record with two gaps
  • THEN the decoded research.suggestions record holds two texts, each text names its gap, and no text is a finding

Requirement: Stale record after a body change

Each record MUST hold the outside hash of the item text that the step read.

Scenario: The item body changes after a run

  • WHEN the test changes the body of the item and runs the step again
  • THEN the step writes a new record with a different outside hash and does not reuse the old record

Requirement: Research keys survive a record decode

The research record keys MUST join the job record's known keys so a decode keeps them.

Scenario: A job record that holds both research records

  • WHEN the test decodes a job record that holds research.standards and research.suggestions
  • THEN decode_job_record returns both keys with their values

Requirement: Scope labels select the checks

The standards step SHALL run only the rubric checks that the item's scope/* labels select.

Scenario: An item with the scope/docs label

  • WHEN the test runs the standards step on a fixture item with the scope/docs label
  • THEN research.standards.gaps names only the checks of that scope and the project-wide checks

Requirement: Pending a person after the merge

The two research steps MUST run as the App in mode plan on 5 items of the stage window after the merge and the release.

Scenario: Live proof after the release

  • WHEN a person runs the live proof after the merge and the release: the two steps run as the App in mode plan on 5 items of the stage window
  • THEN a comment on this issue gives the result lines and the gaps

Existing Tool Considered

backstage/community-plugins (https://github.com/backstage/community-plugins), Apache-2.0, maintained: the alternatives check of 2026-11-23 gives the verdict partly; its block in the issue body gives what the tool covers and lacks. The proposal builds its own code instead, at the cost the body gives: 200,000 to 400,000 agent tokens and 1 day. It adds the ADR-in-force read, the scope/* label map, the roadmap job records, the resolve cause and the suggestion text that the tool lacks.

Key questions

  • Which component gives the standards score?: The standards step uses the decision-point shape of ADR 0020. It gives one band of the closed set continue, review or flag. Jev answers the closed rubric questions. The step writes the band and the gaps to research.standards and returns no text. If ai.decision_model is empty, the rule or fallback gives the band. (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, CONTEXT.md, src/devops_cli/roadmap/decision_step.py]
    • Chosen: Decision point with Jev. ADR 0020 makes the score a band of a decision point, the body names Jev, and Band fixes the closed set.
    • Rejected: Generative model writes the score. ADR 0020: a point returns a band and never a text.
    • Rejected: Count of passed checks only. The body asks Jev to score the closed rubric choice.
  • Which standards are in force, and which label names the scope that selects them?: The ADRs in force are an accepted ADR, or one with no status, that no ADR supersedes (Adr.in_force). The guidelines are the entries of docs/guidelines/index.md. The scope is the scope/* label family in .github/labels.yml. The step reads item.labels, because a scope label is not an ItemField. [sources: src/devops_cli/roadmap/adr.py, docs/guidelines/index.md, .github/labels.yml, src/devops_cli/roadmap/stores/store.py]
  • How does a scope/* label select the standards?: The research unit holds a checked-in table with one row for each scope/* label in .github/labels.yml. Each row names the ADRs in force and the guideline sections that the label selects. A check with no scope row is project-wide. A test asserts the rows. (best practice) [sources: .github/labels.yml, src/devops_cli/roadmap/adr.py, docs/guidelines/index.md]
    • Chosen: Checked-in scope table. The repository holds no map, the standards stay in git, and a table gives a check a result to assert.
    • Rejected: Read every ADR and guideline for every item. A docs item would be scored against ADR 0021, and the gaps would be noise.
    • Rejected: A model picks the standards. ADR 0005: a finding comes from a tool or a checked fact, and a model only explains and plans.
  • Where do the two records live, and what does each hold?: Both records live in the hidden job record of the item body. A ResearchRecordKey family joins JobRecord, _JOB_RECORD_KEYS and __all__. The job record's values are str | None, so each record is a JSON string. research.standards holds score, gaps, at and the outside hash. research.suggestions holds the texts, at and the outside hash. (best practice) [sources: src/devops_cli/roadmap/stores/store.py]
    • Chosen: One JSON record for each step. The job record's values are str | None, JSON-valued keys such as implement.wip and stage.rejected are the existing pattern, and the issue names one record for each step.
    • Rejected: A flat key family. The issue writes one record for each step, and a flat family needs a key for each field.
    • Rejected: A comment on the issue. The job record is the one hidden block every job writes; a comment is the event, not the record.
  • What is the outside hash?: The outside hash is the SHA-256 hex digest of the item text outside the step's own block and refine's section. hash_text and body_hashes compute it in src/devops_cli/roadmap/body_hash.py. The alternatives check records the same hash as alternatives.body_hash, and the stage job as stage.text_hash. It covers the body text only; a label is not part of it. [sources: src/devops_cli/roadmap/body_hash.py, src/devops_cli/roadmap/stores/store.py, docs/ROADMAP_WORKFLOW.md]
  • Where does the resolver read a resolve cause, and which causes does it accept?: The resolver of feat(roadmap): eval stage leaves out one research section #5512 and feat(roadmap): one research unit runs its steps just in time #5513 reads a cause from the item's hidden job record. The existing cause reader has_person_cause is the pattern. This change writes the standards cause to that record. The cause set is closed in the research unit of feat(roadmap): eval stage leaves out one research section #5512 and feat(roadmap): one research unit runs its steps just in time #5513. [sources: src/devops_cli/roadmap/stores/store.py, src/devops_cli/roadmap/phase.py]
  • Which cause name does the standards step write?: standards, the name of the step and of its record. The record and the resolver use one name. The project uses short snake_case cause names, and standards fits. (best practice) [sources: src/devops_cli/telemetry/instruments.py, src/devops_cli/roadmap/phase.py]
    • Chosen: Name after the step (standards). One name for the record and the resolver, distinct from the other causes, and it matches the typed-cause naming.
    • Rejected: Reuse an existing cause. A poor standards fit is a new cause, and a re-used cause hides it.
    • Rejected: Write no cause. The resolver needs the cause, and this is the purpose of the change.
  • Which mode do the two steps ship in, and what does that mode change?: Both steps ship with their mode set to plan, as the body says. The mode is a setting of the research steps, not the off, shadow or on mode of roadmap.decisions. In that mode they write the two records and the resolve cause, and change no band, label or status. A later change flips the mode after the evaluation shows a lift. (best practice) [sources: docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md, docs/CONFIGURATION.md]
    • Chosen: Plan. The body keeps both steps in plan until the evaluation shows a lift.
    • Rejected: On. No evaluation shows a lift yet, so the steps change no decision.
    • Rejected: Off. The two records and the cause are the purpose of the change.
  • How does the suggestions step write its text, and is that text a finding?: A generative model writes the text from the gaps of the standards record. The text is a lead and never a finding. It changes no state of the item. ADR 0005 keeps a model's output apart from findings, with no field that can create or change one. (best practice) [sources: CONTEXT.md, docs/adr/0005-review-findings-come-from-tools-not-models.md]
    • Chosen: Generative model text, stored as a lead. The glossary says a suggestion from a model is a lead and never a finding.
    • Rejected: Template text from the gaps. A template gives no improvement that fits the item.
    • Rejected: Model finding. ADR 0005 and the glossary forbid it.
  • How does the rubric check each standard?: Each check is code in the research unit with a stable name and the ADR or guideline it reads. It returns pass or fail with a message. The set of results is the evidence for the decision point. Jev answers the closed questions, and the cuts give one band of continue, review or flag. A model never writes the gaps. (best practice) [sources: docs/adr/0005-review-findings-come-from-tools-not-models.md, 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, src/devops_cli/roadmap/stage/stage_jev_screen.py, src/devops_cli/roadmap/decision_step.py]
    • Chosen: Code check for each clause. ADR 0005 gives a finding to a tool or a checked fact, a code check gives a result a test can assert, and the checks are the evidence of the point.
    • Rejected: Model reads the ADRs and gives the gaps. ADR 0005: a model explains and plans, and its output can change no finding; a model text is no measurement a test can assert.
    • Rejected: A policy tool such as conftest. The alternatives check found no ADR-aware scorer, and conftest tests structured configuration against Rego policies, not prose ADRs.
  • What are the score bands and the poor-fit cut?: The bands are the closed set of a decision point: continue, review and flag. flag is the poor fit and writes the standards resolve cause. continue and review write no cause. (best practice) [sources: src/devops_cli/roadmap/decision_step.py, src/devops_cli/roadmap/decision_point.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]
    • Chosen: The three bands of a decision point, with flag the poor fit. ADR 0020 and Band fix the closed set at continue, review, flag, and DecisionPoint requires each band.
    • Rejected: A numeric score with a poor-fit cut. ADR 0020: a point returns a band and never a number or a text.
    • Rejected: Two bands, pass and fail. DecisionPoint.__post_init__ requires each band of Band, so a point with two bands does not load.

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

#5513, #5512

Activity

  1. added
    source/agent
    on Nov 13, 2026
  2. added
    type/feature
    scope/roadmap
    status/new
    value/medium
    effort/medium
    on Nov 13, 2026
  3. dan-petty commented on Nov 13, 2026

    @dan-petty
    OwnerAuthor
  4. added
    priority/p2-medium
    on Nov 13, 2026
  5. devops-cli-service commented on Nov 17, 2026

    @devops-cli-service
    Contributor

    Alternatives check: partly

    Reason: Searches found no ADR-aware scorer for an issue. Backstage Tech Insights is the nearest open, maintained tool: a checks-and-scorecard engine that yields a score and failing checks, but it reads no ADRs, takes no item input and writes no suggestions.

    Tool: backstage/community-plugins (https://github.com/backstage/community-plugins), Apache-2.0, last activity 2026-11-17, maintained.

    Covers:

    • Rubric checks written as code, each pass or fail
    • One score per entity from the checks that pass
    • Custom fact retrievers feed checks from outside data
    • Check results list the failed checks and their messages

    Lacks:

    • Reads no ADRs in force and no scope-label standards
    • No improvement text for refine beyond check messages
    • No research.standards record with timestamp and hash
    • Runs inside a Backstage catalog, not on GitHub issues
    Searches (10)

    Tools considered:

    Searches run:

    • Backstage Tech Insights scorecards checks open source, results: 5
    • open source tool checks item against architecture decision records compliance score, results: 5
    • "tech insights" backstage scorecard plugin, results: 5
    • architecture decision record compliance linter github, results: 5
    • conftest open policy agent test configuration against policies, results: 5
    • backstage plugin-tech-insights scorecards checks documentation, results: 5
    • open-policy-agent/conftest github, results: 5
    • github backstage/backstage tech-insights plugin, results: 5
    • Tech Insights scorecards Backstage plugin checks json rules engine, results: 5
    • spec-kit constitution analyze consistency gaps, results: 5

    Sources:

    A person decides what this check of 2026-11-17 means for the item.

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

    @devops-cli-service
    Contributor

    Refine cannot set this item to Ready at 86358b6 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.

  7. devops-cli-service commented on Nov 27, 2026

    @devops-cli-service
    Contributor

    Next step: the open items close, or a person replies in a comment or edits the body. See Dependencies in the section Proposed design of the body.

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/mediumpriority/p2-mediumscope/roadmapsource/agentstatus/newtype/featurevalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions