Skip to content

feat(roadmap): consolidate shortlists find bot families by fingerprint #4812

Open

Description

@dan-petty

Problem or Motivation

The 17 open hardening-audit items (#3515 to #3683) use one template and the same 6 declared surfaces. The common-citation cut of the consolidate shortlists (value 8 in defaults.py) drops their signal, so the shortlists miss the family. The alert filer (alert_filer.py) files one issue for each rule and file, so one rule over N files gives N items.

Proposed Solution & Architectural Design

  • Add a signal FINGERPRINT to consolidate_shortlist.py. It hashes, with hashlib:
    • the login of the filer;
    • the title template, with each number masked;
    • the first stable key: the rule id, the alert, the path or the set of declared surfaces.
  • FINGERPRINT is the strongest signal. The common-citation cut does not apply to it.
  • Siblings "Split from" one parent and trackers get no fingerprint.
  • A person-filed item gets no fingerprint. The brain-daily judge (feat(roadmap): run brain repair, consolidate and evaluate daily #4687) handles person-filed items.

Target Subsystem

SDLC, Git & PR Governance (src/devops_cli/roadmap/consolidate*).

Existing Tool Considered

The consolidate shortlists and hashlib. GitHub closes its own code-scanning alerts, but not the issues that a job files from them. Cost to build: about 40,000 tokens and 1 hour.

Acceptance Criteria

  • The 17 hardening bodies give one family.
  • Two split siblings give no family.
  • A person-filed item gets no fingerprint.
  • The current shortlist tests pass.

Dependencies

None.

Source: #4780

Owner decision 2026-11-13

The approved pipeline split (tracker #5482, Phase 5) keeps this scope. The group row (#4813) reads the shortlists.

  • Live proof: after the merge and the release, consolidate runs as the App over the open bot items. A comment gives the families that it found, with the fingerprint and the item numbers of each.

Alternatives check of 2026-11-26: none.
Tool: none found.
Reason: Searches found only generic documentation and record-linkage libraries (dedupe, datasketch); none derives a family fingerprint from a filer login, a number-masked title and a first stable key, or feeds this project's consolidate shortlists.

Lacks:

  • Fingerprint from filer login, masked title and first stable key
  • Exemption from the value-8 common-citation cut
  • No fingerprint for split siblings, trackers and person-filed items
  • Fingerprint evidence carried into the project's own shortlists

Proposed design

Problem statement

The consolidate shortlists group open items by shared citations, links and embeddings, and none of those signals carries a family of items that one bot job filed: the 17 hardening-audit items (#3515 to #3683) share a template and six declared surfaces, and the common-citation cut (value 8 in defaults.py) drops the surfaces they share. The alert filer files one issue for each rule and file, so one rule over N files gives N items. The group row (#4813) of the approved pipeline split needs the shortlists to name these families, with a fingerprint that survives the per-item numbers and the edits to a body.

Acceptance criteria

Requirement: Fingerprint signal

The consolidate shortlists SHALL carry a FINGERPRINT signal that is stronger than every other signal and that groups two bot-filed items with the same filer login, masked title template and first stable key.

Scenario: Two items of one bot family

  • WHEN Two open items that the same bot login filed hold the same masked title template and the same first stable key.
  • THEN Each is a member of the other's shortlist with the FINGERPRINT signal, and that signal is the strongest evidence of the member.

Requirement: Hardening-audit family

The consolidate shortlists SHALL put the seventeen hardening-audit items into one family.

Scenario: Seventeen hardening-audit bodies

  • WHEN The shortlist runs over seventeen fixtures that github-actions[bot] filed, whose titles differ only by the pull request number and whose bodies name the same declared hardening surfaces.
  • THEN One shortlist holds all seventeen items with the FINGERPRINT signal and one fingerprint.

Requirement: One alert rule over several files

The consolidate shortlists SHALL give one fingerprint to the items of one alert rule over several files.

Scenario: One Trivy rule in two files

  • WHEN Two bot-filed items give the same rule id and different paths in their bodies, and each title holds that rule id and path.
  • THEN Both items carry the same fingerprint and join one family.

Requirement: Fingerprint exempt from the common-citation cut

The consolidate shortlists SHALL NOT apply the common-citation cut to a family that a FINGERPRINT groups.

Scenario: Family below the citation cut

  • WHEN Two bot-filed items share a fingerprint and share fewer citations than the value-8 cut.
  • THEN The shortlist keeps the family in its output.

Requirement: Fingerprint family above the member cap

The consolidate shortlists SHALL keep every member of a FINGERPRINT family, even when the family is larger than DEFAULT_ROADMAP_CONSOLIDATE_MEMBERS.

Scenario: A family of seventeen

  • WHEN Seventeen items share a fingerprint and ten other items are cited by the anchor.
  • THEN The shortlist holds all seventeen fingerprint members and at most ten members without a fingerprint.

Requirement: Split siblings get no fingerprint

The consolidate shortlists SHALL give no FINGERPRINT to an item that says 'Split from' one parent.

Scenario: Two split siblings

Requirement: Tracker gets no fingerprint

The consolidate shortlists SHALL give no FINGERPRINT to an item that has sub-issues.

Scenario: A tracker with sub-issues

  • WHEN A bot-filed item has at least one sub-issue.
  • THEN The item gets no FINGERPRINT.

Requirement: Person-filed item gets no fingerprint

The consolidate shortlists SHALL give no FINGERPRINT to an item that a person filed.

Scenario: A person files a matching item

  • WHEN A person files an item with a title template and a key that match a bot family.
  • THEN The item gets no FINGERPRINT and joins no bot family.

Requirement: Current shortlist tests pass

The change SHALL keep the current consolidate shortlist tests passing.

Scenario: Run the shortlist tests

  • WHEN The shortlist test suite runs after the change.
  • THEN Every test passes and no existing shortlist output changes for an item without a FINGERPRINT.

Existing Tool Considered

No open, maintained tool covers the need. The alternatives check of 2026-11-14 searched for duplicate-issue, fingerprint and near-duplicate clustering tools and found none that derives a family fingerprint from a filing login, a number-masked title template and a first stable key, or that feeds a fingerprint into this project's consolidate shortlists; the error-tracking tools that group by fingerprint group error events, not GitHub issues. The change builds the signal in consolidate_shortlist.py and reuses the project's own code: hash_text (SHA-256, src/devops_cli/roadmap/body_hash.py:43) for the digest and bot_logins (src/devops_cli/roadmap/trust.py:35) for the bot check, so it adds no hashing and no login list. Written cost to build, keep and fix it: about 40,000 tokens and 1 hour.

Key questions

  • Which signal groups the bot-filed family, and how does it hash?: Add FINGERPRINT as the first member of Signal in consolidate_shortlist.py, so _STRENGTH gives it the highest value and it is the strongest evidence. Its input is one string of four fields joined with a separator that a login, a title and a key cannot hold: the version consolidate/v1, the filer login, the masked title template and the first stable key. Hash it with the project's hash_text (SHA-256 hex digest, src/devops_cli/roadmap/body_hash.py:43), as the SARIF fingerprint already does with its own version key, and carry the hex digest in Evidence(signal=Signal.FINGERPRINT, detail=<digest>). (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:147, src/devops_cli/roadmap/consolidate_shortlist.py:56, src/devops_cli/roadmap/consolidate_shortlist.py:66, src/devops_cli/roadmap/body_hash.py:43, src/devops_cli/config/constants.py:4419]
    • Chosen: New FINGERPRINT signal in consolidate_shortlist.py. ADR 0021 records the fingerprint as the selection of the group row, and no existing signal carries the filer login, the template and the stable key.
    • Rejected: Raise the common-citation cut above value 8. A higher cut still drops a family whose shared surfaces outnumber the cut, and it widens every citation shortlist.
    • Rejected: Group by title similarity alone. The per-item numbers differ, and similarity cannot tell one alert rule from another.
  • How is the first stable key read?: Read the first of these that the item's body names, in the order that ADR 0021 records: a rule id (the - Rule: <id> line that the alert filer writes), an alert id (an alert <n> line), a path (the - Path: <path> line), or the set of declared hardening surfaces that the body lists, from the table at src/devops_cli/github/defect_classifier.py:29. An item whose body names none of them gets no fingerprint. For the hardening-audit items the key is the set of surfaces, which is the same for all seventeen; for a Trivy item it is the rule id, which groups one rule over its files. (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:147, src/devops_cli/security/alert_filer.py:73, src/devops_cli/security/alert_filer.py:74, src/devops_cli/github/defect_classifier.py:29]
    • Chosen: First key the body names, in the order of ADR 0021. The body is the stable record of the rule, the path and the surfaces, and the order puts the rule id before the path, so one rule over N files stays one family.
    • Rejected: Read the key from the title only. The hardening title names no rule, path or surface, so the family would get no key.
    • Rejected: Hash the whole body as the key. A body edit moves the fingerprint, and the rule asks for a stable key.
  • Does the common-citation cut apply to a FINGERPRINT family?: No. _rare filters only the citation sets (src/devops_cli/roadmap/consolidate_shortlist.py:127), and a FINGERPRINT member never comes from a citation, so the cut cannot drop it. The cut stays as it is for the path and identifier signals. (best practice) [sources: src/devops_cli/roadmap/consolidate_shortlist.py:117, src/devops_cli/roadmap/consolidate_shortlist.py:127, docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md:147]
    • Chosen: Exempt FINGERPRINT from the common-citation cut. The family shares surfaces that the cut drops, and the fingerprint does not read citations at all.
    • Rejected: Apply the common-citation cut to FINGERPRINT. It would drop the seventeen-item family that this issue must group.
  • Which items get no fingerprint?: A part of a split (a body that says 'Split from #N', which _RELATION already matches), a tracker (IssueRecord.sub_issues > 0), and a person-filed item get no fingerprint. The group row (feat(roadmap): the group row links a family and closes on a re-check #4813) applies its other skips (a started item, a milestone, an owner/* claim and a declined group id) to its own selection. (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:147, docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md:148, src/devops_cli/roadmap/consolidate_shortlist.py:46, src/devops_cli/roadmap/stores/store.py:587]
    • Chosen: Exclude split parts, trackers and person-filed items. They are not one bot family, so a shared fingerprint would make a false family: a part repeats its parent's template and a tracker holds its sub-issues.
    • Rejected: Give every item a fingerprint. It would group the split siblings of one parent and a tracker with its own sub-issues.
    • Rejected: Give no fingerprint to any bot item. That is the family this issue must build.
  • How does the shortlist mask the numbers in a title template?: Replace each run of digits in the title with one token, <n> (the pattern that _ISSUE_NUMBER uses, src/devops_cli/roadmap/consolidate_shortlist.py:51), and replace each value of the first stable key that the body names and the title holds (the rule id, the alert id, the path) with <key>. Two titles that differ only in their numbers then give one template, and one alert rule in two files gives one template too, while the key keeps two rules apart even though their masked titles collide. The placeholder keeps the position of the variable, so two different templates do not collide. (best practice) [sources: src/devops_cli/roadmap/consolidate_shortlist.py:51, src/devops_cli/security/alert_filer.py:28, src/devops_cli/security/alert_filer.py:74]
    • Chosen: Mask each variable with one placeholder token. It keeps the shape of the template, removes the per-item values, and lets one rule over N files share a template.
    • Rejected: Remove all digits from the title. KSV-0001 and KSV-0017 would collide into KSV-, and the key would be the only guard.
    • Rejected: Keep the numbers in the title. Each hardening item would get a different fingerprint.
  • How does the shortlist tell a bot-filed item from a person-filed item?: Compare issue.author_login with bot_logins(), the one trust rule, which holds service.github_app.bot_login and github-actions[bot]. The App login alone is not enough: github-actions[bot] filed the hardening items (11 of them on 2026-11-05, all hardening titles), so the App login alone would leave the seventeen-item family empty. A login that only resembles a bot login gets no fingerprint. (best practice) [sources: src/devops_cli/roadmap/trust.py:35, src/devops_cli/roadmap/stores/store.py:582, docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md:147, openspec/changes/archive/2026-11-05-3502-jobs-trust-service-app-items/proposal.md:5]
    • Chosen: Compare the filer login with bot_logins(). It is the project's one bot rule, and it covers the two bots that filed the items this issue groups, github-actions[bot] included.
    • Rejected: Compare the filer login with the App login only. The hardening-audit items came from github-actions[bot], so they would get no fingerprint and the first acceptance criterion would fail.
    • Rejected: Accept any login that ends with [bot]. A bot outside the project's trust rule would join a family, and the project already refuses that login.
  • Does the member cap apply to a fingerprint family?: No. The cap of DEFAULT_ROADMAP_CONSOLIDATE_MEMBERS (10) stays for the members that no fingerprint groups, because it bounds the text that the model of consolidate reads, but every member of a fingerprint family is kept. ADR 0021 defines a family as two or more open members with one fingerprint and gives it no cap, and the seventeen-item family would otherwise lose seven members. assign_groups already places all of them under the lowest anchor, so no other rule changes. (best practice) [sources: src/devops_cli/config/defaults.py:853, src/devops_cli/roadmap/consolidate_shortlist.py:269, openspec/changes/archive/2026-11-06-1127-consolidate-shortlist/design.md:10, docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md:147]
    • Chosen: Keep every fingerprint member above the cap. The cap exists to bound the model's text, and the family is the unit that the group row reads; a truncated family is a wrong family.
    • Rejected: Keep the cap for every member. It drops seven of the seventeen hardening items, so they never reach one family.
    • Rejected: Raise the cap. It widens every shortlist that no fingerprint groups and weakens the reason for the cap.
  • How does the shortlist detect a tracker?: An item with sub_issues > 0 is a tracker, and it gets no fingerprint. The listing already carries the count, so the check costs no request. (best practice) [sources: src/devops_cli/roadmap/stores/store.py:587, docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md:148, CONTEXT.md:94]
    • Chosen: Detect a tracker by its sub-issues. CONTEXT.md says the sub-issues deliver their parent item, and ADR 0021 skips a tracker.
    • Rejected: Detect a tracker by a title pattern. No stable title pattern exists.
    • Rejected: Detect a tracker by a label. The label families hold status, priority, value and effort, not a tracker label.
  • Does the approved pipeline split keep this scope?: Yes. ADR 0021 records the group row as the reader of the families, with the fingerprint as its selection, and the owner decision of 2026-11-13 keeps that scope in this issue. The live proof waits on the merge and the release, so it is deferred to its own issue. (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:145, docs/adr/0021-the-roadmap-service-is-a-webhook-router-cluster-pods-run-the-roadmap-jobs-and-valkey-holds-their-shared-state.md:147]

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

None.

Activity

  1. added
    source/agent
    on Nov 11, 2026
  2. added
    type/feature
    scope/roadmap
    status/new
    value/medium
    effort/low
    on Nov 11, 2026
  3. 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/feature. The feat prefix of the title gives the type.
    • Scope: scope/roadmap. The (roadmap) scope of the title gives the scope.
    • Priority: P2-Medium. It reduces shortlist noise for 17 items but does not block delivery or fix a defect.
    • Value: Medium. Grouping 17 bot-filed items into one family cuts triage noise for the roadmap.
    • Effort: Low. The body estimates about 40,000 tokens and 1 hour of work.
    • Related: fix(ci): the hardening audit files no issue for a tested fix #3479, which asks for a different change. Both deal with hardening-audit filed issues, but #3479 stops filing for tested fixes while the candidate groups filed issues into one family.
  4. added
    priority/p2-medium
    on Nov 11, 2026
  5. devops-cli-service commented on Nov 14, 2026

    @devops-cli-service
    Contributor

    Alternatives check: none

    Reason: Searches for duplicate-issue, fingerprint and near-duplicate clustering tools returned only unrelated pages and error-tracking products that group error events (Sentry and a Sentry-compatible ingest with "issue grouping", 1 star and no release), none of which reads GitHub roadmap issues or the shortlist data. No open tool computes a family fingerprint from the filer login, a number-masked title template and a rule/path/declared-surface key, so the hashlib-based FINGERPRINT signal has to be built in consolidate_shortlist.py as proposed.

    Tool: none found

    Lacks:

    • No found tool derives a family fingerprint from the filing login, the masked title template and the first stable key (rule id, alert, path or declared surfaces).
    • No found tool integrates a FINGERPRINT signal into the project's consolidate shortlists as the strongest signal, exempt from the common-citation cut.
    • No found tool excludes split siblings, trackers and person-filed items from grouping.
    • Error-tracking grouping tools (Sentry-style) group error events by fingerprint, not GitHub issues filed by a bot job.

    Tools considered:

    Searches run:

    • tool to cluster duplicate issues tracker by fingerprint dedupe, results: 5
    • open source duplicate issue detection grouping fingerprint tool GitHub, results: 5
    • duplicate bug report detection python library clustering, results: 5
    • Sentry grouping fingerprint how grouping works, results: 5
    • dedupe library python fuzzy matching records, results: 5
    • github action duplicate issue detection bot, results: 5
    • sentry issue grouping, results: 5
    • fingerprint hash group similar issues tool, results: 5
    • duplicate issue detector github repository, results: 5
    • minhash near-duplicate clustering python package, results: 5

    Sources:

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

  6. added
    status/ready
    and removed
    status/new
    on Nov 15, 2026
  7. devops-cli-service commented on Nov 15, 2026

    @devops-cli-service
    Contributor

    Status set to Ready at e5dfddb (see proposed design in issue body).

    Moved to new items: #5815.

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions