Repository navigation
Description
Split from #4682.
Problem or MotivationnThe digest of #4682 holds the ring of each tool that it names, with the date of the ring. The brain index of #4676 holds no ring (src/devops_cli/roadmap/brain_index.py:222).nn## Why this part is deferredn#4693 gives the ring, and it is not built. The digest cannot read a field that the index does not hold. The rest of #4682 does not wait on the ring.nn## Acceptance Criterian- The digest SHALL hold the ring of each tool when the brain index entry holds a ring.n- The digest SHALL hold the date of the ring.n- A test with a fixture entry that holds a ring SHALL assert the ring in the digest.n- A test with a fixture entry that holds no ring SHALL assert that the digest names the tool with no ring.
Proposed design
Problem statement
The brain digest gives the alternatives check the near items of an item and the tool of each near item. The digest does not hold the ring of a tool, because the brain index holds no ring. Item #4693 adds the ring to the brain. This change makes the digest copy the ring and its date from the tool entry. A tool with no ring stays in the digest with no ring.
Acceptance criteria
Requirement: Ring in the digest
The brain digest SHALL hold the ring of a tool when the tool entry of the brain index holds a ring.
Scenario: Tool entry holds a ring
- WHEN A test gives
read_digesta stub index whose tool entry for a tool holds a ring, and calls it - THEN The
toolmapping of the digest entry holds the ring of the tool entry, under the field name of the ring in the tool entry.
Requirement: Ring date in the digest
The brain digest SHALL hold the date of each ring that it holds.
Scenario: Ring date is copied
- WHEN A test gives
read_digesta stub index whose tool entry holds a ring with a date, and calls it - THEN The
toolmapping of the digest entry holds the date of the ring, under the field name of the ring date in the tool entry.
Requirement: Tool with no ring
The brain digest SHALL name a tool whose tool entry holds no ring and SHALL hold no ring and no ring date for it.
Scenario: Tool entry holds no ring
- WHEN A test gives
read_digesta stub index whose tool entry for a tool holds no ring, and calls it - THEN The digest entry holds no key in its
toolmapping other thantool,tool_nameandrejected_by.
Requirement: Token bound with a ring
The brain digest SHALL keep the token bound of its text when a tool entry holds a ring.
Scenario: A ring that does not fit
- WHEN A test gives
read_digesta stub index whose first near item holds a ring that makes its entry text exceedCONST_ROADMAP_BRAIN_DIGEST_MAX_TOKENS - THEN The digest leaves that entry out and the text of the digest holds at most
CONST_ROADMAP_BRAIN_DIGEST_MAX_TOKENStokens.
Existing Tool Considered
No alternatives check has run. No open, maintained tool or library covers a copy of one field of an internal index into an internal digest. The change builds its own code: about 3,000 tokens to build, 1,000 tokens to keep and fix, and 2 hours of elapsed time.
Key questions
- Does the brain index hold the ring of a tool now?: No. The digest module states that the brain index holds no ring of a tool and no area check. The aggregate and improve tasks of feat(roadmap): the brain files project insights through intake #4693 add them to the brain. [sources: src/devops_cli/roadmap/brain_digest.py, src/devops_cli/roadmap/brain_index.py:222]
- Which entry of the brain index holds the ring?: The tool entry.
read_digestreads the tool entries withindex.toolsand gives eachHeldToolto the digest entry. [sources: src/devops_cli/roadmap/brain_digest.py] - Where in the digest does the ring go?: In the
toolmapping of the digest entry, next totoolandtool_name. The ring belongs to the tool, not to the item. (best practice) [sources: src/devops_cli/roadmap/brain_digest.py]- Chosen: In the
toolmapping. The ring belongs to the tool. The entry keeps one place for each tool fact. - Rejected: At the top level of the entry. The ring is not a fact of the item. A top-level key reads as an item fact.
- Rejected: In a separate list of rings. A second list splits the schema. The token cut takes whole entries and cannot cut a list.
- Chosen: In the
- Which field names does the digest use for the ring and the date of the ring?: The names of the fields that feat(roadmap): the brain files project insights through intake #4693 adds to the tool entry. The digest copies them and adds no second name. (best practice) [sources: src/devops_cli/roadmap/brain_digest.py, src/devops_cli/roadmap/brain_index.py:222]
- Chosen: Copy the field names of the index. The digest is a view of the index. One name keeps one schema.
- Rejected: Use digest-only names. A second name needs a mapping and adds no value.
- Rejected: Use short aliases. An alias hides the index field that it copies.
- What does the digest do for a tool with no ring?: It names the tool and holds no ring and no ring date. The digest already omits
tool_namewhen the tool entry has no name. (best practice) [sources: src/devops_cli/roadmap/brain_digest.py]- Chosen: Omit the ring keys. The body asks for a tool with no ring. An omitted key shows that the index holds no ring.
- Rejected: Write a null ring. A null is not a ring. It hides a missing field.
- Rejected: Write an empty string. An empty string is a value. The model cannot tell it from a missing ring.
- Does the digest change or filter the ring?: No. The digest copies the ring and the date from the tool entry as they are. feat(roadmap): the brain files project insights through intake #4693 owns the meaning of the ring. (best practice) [sources: src/devops_cli/roadmap/brain_digest.py]
- Chosen: Copy the ring as it is. The digest is a view of the index. It adds no meaning to a field.
- Rejected: Filter the near items by ring. The digest shows the near items of the item. A filter hides items that named the same tool.
- Rejected: Map the ring to a digest label. A second vocabulary splits the schema and adds no value.
- Does the digest change the token cut for a ring?: No.
_fittedcounts the text of each entry value. A ring that does not fit leaves its entry out, and a later entry that fits stays. (best practice) [sources: src/devops_cli/roadmap/brain_digest.py]- Chosen: Keep the cut as it is. The cut takes whole entries and already counts each field of an entry.
- Rejected: Raise the token bound. No evidence shows that the bound is too small for a ring.
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
Watched files
A commit on the default branch that changes one of these files starts the next refine round.
src/devops_cli/roadmap/brain_index.py
Activity
devops-cli-service commentedon Nov 28, 2026
Next step: the open items close, or a person replies in a comment or edits the body. See Dependencies and Watched files in the section Proposed design of the body.