Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- MCP tools `roadmap_render` and `roadmap_migrate`, which only previews, in a new lazy `roadmap` domain (#739).
- The roadmap store gains board creation from the template, field deletion, card listing, writes and removal, issue creation and closing with a reason and comment, Release deletion, workflow listing and repository file reads, in both adapters (#739).
- `docs/VISION.md` holds the design principles and the themes from `docs/ROADMAP.md`, without release numbers (#739).
- **Branch and PR Reviews Compute Their Own Symbol Delta (`devops review branch`, `devops review pr`)**:
- Each review records the symbols that every changed Python file added, removed and kept since the commit its diff starts at, so an earlier `devops ai analyze branch` run is no longer needed. That commit is the merge base for a branch, `HEAD` for uncommitted changes, and the merge base from GitHub's compare endpoint for a pull request, not the base branch's tip. A branch's files are read at its own commit, so reviewing a branch that is not checked out, or one with uncommitted deletions, does not count the checkout's removals as the branch's. A renamed file is compared with its old path, an added file's symbols are all added, and a file whose base or head cannot be read gets no delta (#593).
- Verification exempts a finding only when it cites a symbol this review's diff removed, and moves it to the file's diff hunk without asking the model. The summary's Symbol Delta row and `removed_symbol_findings_count` count only the reviewed files (#593).

### Changed
- **`devops gh milestones edit` and `close` Take a Version (`devops gh milestones`)**:
Expand All @@ -39,6 +42,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- **Editing a Milestone No Longer Closes It (`devops gh milestones edit`)**:
- `edit` sends only the fields it is given. Before, `devops gh milestones edit v0.2.25 --description x` also sent `state=closed` whenever a GitHub token resolved, and closed the milestone (#768).
- When GitHub can't be read, `devops gh milestones list` exits 1 and names the failed read, instead of printing "No milestones found" (#768).
- **Reviews No Longer Use Another Run's Symbol Delta (`devops review`)**:
- Pre-analysis kept symbol lists that another review or `devops ai analyze branch` had cached. Verification read the newest cached analysis, whichever run wrote it, and the summary added up that analysis when the reviewed files had no delta. A finding could be exempted for a symbol that a different branch removed. Now only the session's own delta counts (#593).
- **`devops ai analyze branch` Compares a Renamed File With Its Old Path (`devops ai analyze branch`)**:
- A renamed file is analysed at its new path and compared with its old one at the merge base. The plain `--name-status` parser read `old.py<TAB>new.py` as one path that does not exist, so it recorded the file as deleted. A reused file's delta is now computed again, because the cached one may be against an older merge base (#593).

### Removed
- **ROADMAP-to-GitHub Sync (`devops gh issues sync-roadmap`, `devops gh issues reconcile-roadmap`, `devops gh milestones sync`, `devops release epic`)**:
Expand Down
14 changes: 7 additions & 7 deletions docs/ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -804,12 +804,12 @@ High-density product roadmap, engineering milestones, and open-source integratio
- *Constraint*: A prefix allowlist or a second hand-written table like `_ATTRIBUTE_NORMALIZATION` (`tracer.py:454-475`, no GenAI entries) is what produced the drift. The installed package is not the oracle (its `gen_ai` constants are all deprecated as moved); snapshot from the GenAI repository at a recorded commit. Weaver output stability across refreshes is unverified; if unstable, commit only the reduced table. No in-tree dashboard or alert references `gen_ai.*` (0 hits under `k8s/`); external ad-hoc queries are a release-note item. The report is the rename's completion proof; renaming without it, or keeping old keys beside new, adds a third vocabulary.
- *Measured*: `grep -rhoE 'gen_ai\.[a-z_.]+' src | sort -u | wc -l`: 32 (30 attribute keys after excluding span names `gen_ai.chat`, `gen_ai.stream`). Script diffing those 30 against `opentelemetry.semconv._incubating.attributes.gen_ai_attributes` (0.65b0 via `importlib.metadata`): defined=9 (renamed=3, moved=6), undefined=21. `grep -rn gen_ai.provider.name src | wc -l`: 0. `grep -rn gen_ai k8s | wc -l`: 0.
- *Source*: vibes `tools/semconv_snapshot.py`, `examples/agent-telemetry-trace-generator/semconv.py`, `examples/agent-telemetry-trace-generator/semconv_genai.json`, `examples/agent-telemetry-trace-generator/test_semconv.py`, `observations/systems/19-self-consistency-is-not-conformance.md`, `docs/RETROSPECTIVE.md`
- [ ] **Base-vs-Head Symbol Delta and Removed-Symbol Finding Exemption in Reviews (P1 - High, Issue #593)**:
- *Context & Rationale*: devops-cli measures structure at one revision only: per-function complexity in `security/complexity.py:141`, top-level symbols in `ai/ast_cache.py:20`, a regex Low/Medium/High bucket in `ai/analyze/outlines.py:163`. `devops ai analyze branch` knows each file's added/modified/deleted status (`commands/analyze.py:372-397`) but analyzes head content only, and the review pre-analysis leaves `change_type` at `existing` (`ai/review/pipeline.py:755`). The delivered construct validator invalidates a finding whose cited construct is absent from the head file (`ai/review/construct_validator.py:395`) and records it as a false positive (line 343), so a finding about a symbol the change removed is discarded: a probe finding "removal of `legacy_helper` breaks callers" came back INVALIDATED. How often real reviews hit this is unmeasured. vibes `repomap_cache.py:326-400` scores a refactor by cosine distance over eight AST features, with bands at 0.05 and 0.15 that `README.md:42-44` states without calibration data.
- *Deliverable*: Three PRs. (1) In `_process_single_branch_file_meta` (`commands/analyze.py:134`), for modified Python files, parse `git show <base>:<path>` and head in memory and record on `FileAnalysisMeta` symbols added, removed and retained: top-level from `_extract_symbols_from_tree`, methods from `repomap._extract_class_methods` per `ClassDef` (`parse_file_symbols` reads only from disk). Review reads it through the cached analysis (`ai/analyze/cache.py:181`), not a second git walk. `_deterministic_pre_verification` (`ai/review/verification.py:1179`) passes the removed set to `validate_construct_location`, which labels such findings "cites removed symbol" and re-anchors them to the diff hunk instead of invalidating them. The review summary and session JSON show the delta and that count. (2) Per-function complexity before and after through a content-taking entry to `security/complexity.py`, shared with Cyclomatic Complexity Debt Reduction; a library backend is lizard (`analyze_source_code` takes text; 1.24.0, 2026-08-19), not radon (last release 6.0.1, 2023-03-26). (3) PR reviews, fetching `pull.base.sha` and `pull.head.sha`, since `_prepare_pr_content` has only the API diff (`ai/review/runner.py:1718-1719`). Port only the vibes symbol report.
- *Constraint*: The vibes vector as specified is blind here: its two logarithmic dimensions dominate the unit vector and the five per-line ratios stay at or below 0.045, so every measured pair, unrelated modules included, scored PRESERVED. A gate on it would certify a rewrite as a refactor, worse than no gate. No scalar score, threshold, persona routing or auto-apply verdict ships in this task; any score needs its own task and a labelled corpus. The exemption must stay narrow: a symbol absent from both base and head still goes through invalidation.
- *Measured*: vibes `EmbeddingDriftAuditor` on `git show` extracts (`python3 probe_vectors.py`): `commands/devcontainer.py` at `b7f2a2e7^` against unrelated `ai/gateway.py` at `bc510aac`, no symbol shared, scored `D_C = 0.004639`, PRESERVED; the real devcontainer change to `bc510aac` scored `D_C = 0.000024`; ln(1+lines) was `0.81–0.86` of every unit vector. lizard `analyze_source_code` on the same devcontainer pair (`python3 -c` over both extracts): functions above CCN 10 went from `10` to `11`.
- *Source*: vibes `examples/valkey-l2-repomap-cache/README.md`, `examples/valkey-l2-repomap-cache/repomap_cache.py`, `examples/valkey-l2-repomap-cache/test_repomap_cache.py`, `observations/systems/04-content-addressed-two-tier-caching-and-embedding-drift-audits.md`
- [x] **Base-vs-Head Symbol Delta and Removed-Symbol Finding Exemption in Reviews (P1 - High, Issue #593)**:
- *Context & Rationale*: Part 1 (v0.2.23) records the symbols each file added, removed and kept, and the construct validator exempts a finding that cites a removed symbol instead of invalidating it. Real reviews never got the removed set. Only `devops ai analyze branch` computed a delta, and it took a rename for a deletion. Review pre-analysis kept cached deltas, verification read the newest cached analysis whichever run wrote it, with no diff hunks, and the summary fell back to that analysis when the reviewed files had no delta.
- *Deliverable*: One PR. Branch and PR reviews compute the delta for the files they review from the commit their diff starts at: the merge base for a branch, `HEAD` for uncommitted changes, and the compare endpoint's merge base for a pull request. `devops ai analyze branch` and the review share the base-read, merge-base and changed-file helpers in `git/operations.py`. Pre-analysis records the delta, verification takes the session's metadata and each file's diff text, and the summary counts only the reviewed files.
- *Constraint*: The exemption stays narrow: a symbol missing from both base and head is invalidated, and a failed base read leaves the delta empty. No scalar score, threshold, persona routing, auto-apply verdict or new dependency. Per-function complexity before and after is #873.
- *Measured*: vibes' `EmbeddingDriftAuditor` scored two unrelated modules, `commands/devcontainer.py` and `ai/gateway.py`, at `D_C = 0.0048` (PRESERVED); its line-count dimensions were 0.81 and 0.86 of the unit vectors, so no drift score ships.
- *Source*: vibes `examples/valkey-l2-repomap-cache/README.md`, `examples/valkey-l2-repomap-cache/repomap_cache.py`, `observations/systems/04-content-addressed-two-tier-caching-and-embedding-drift-audits.md`
- [ ] **Finish Reasons, Stream Completeness and Truncation Markers for Model Replies (P1 - High, Issue #599)**:
- *Context & Rationale*: No provider reads a finish reason, and the span hardcodes `gen_ai.response.finish_reasons` to `["stop"]` (`ai/client/unified.py:91`). A persona-review reply cut at its cap (`ai/review/runner.py:713`) is silently repaired, keeps its partial last finding, passes the validator and is cached (`unified.py:579`); failed validation resends the identical prompt (`unified.py:605-609`). Streaming: every provider reads `iter_lines()` (`ai/client/streaming.py:330`), the Ollama extractor never reports done (`:306-308`) and the Claude extractor handles only `content_block_delta` (`:269`). An early EOF or error frame is stored by `devops ai chat` (`commands/ai.py:954`) and billed as complete (`unified.py:816`). Repair enters through three functions (`ai/response_repair.py:51`, `ai/client/structured.py:57`, `core/serialization.py:23`); only `chat_structured`, which nothing calls, counts repairs (`structured.py:197,255`). vibes observation 15 shows retrying into the same token ceiling fails; vibes' RESP decoder returns `(None, 0)` until a whole frame arrives, tested over a frame-splitting socket.
- *Deliverable*: (1) Byte-level characterization tests feeding `_consume_streaming_lines` from an httpx2 `MockTransport`: mid-line and mid-codepoint splits, raw U+2028 deltas, EOF without a terminal frame or mid-line, Ollama and Anthropic error frames, replacing whole-line `iter_lines` stubs. (2) Type `LLMResponse.finish_reason` as pydantic-ai `FinishReason` through `to_model_response`, mapping OpenAI `finish_reason`, Ollama `done_reason` and Anthropic `stop_reason` (`max_tokens` becomes `length`). Emit it on the chat and `gen_ai.stream` spans, never cache `length`, record it per spend-ledger row beside the backend (#474), and report truncation rate per stage and backend in `profile.json` (#473). (3) Read SSE with httpx-sse `EventSource`, pinned directly (already locked via `mcp`); split Ollama NDJSON from `iter_bytes()` on `\n` only. A stream completes only on `finish_reason`, `message_stop` or `done: true`; otherwise raise `AIClientError` with the provider message, which the chat loop already drops (`commands/ai.py:1106-1110`). (4) One `repair_json` seam over `json_repair.loads` returning `repaired`, counted per caller except `security/tflint.py:189`; with Lossless Structured Error Reflection, wire in or delete `chat_structured`. (5) Only if (2) shows a non-zero rate: pipeline-set `ReviewResult.truncated`, trailing-record drop on `length`, and re-chunking instead of identical retry. Budget sizing stays with #479.
Expand Down Expand Up @@ -1427,7 +1427,7 @@ High-density product roadmap, engineering milestones, and open-source integratio
| **Quick Wins** | Extend the Ruff Rule Set to the Correctness Families | Ruff (B, SIM, RUF, BLE, ASYNC) | High | Low | v0.2.23 | 📋 Scheduled (P1) |
| **Quick Wins** | Tests That Cannot Fail Correctly | Pytest / Ruff B017, RUF043 | High | Low | v0.2.23 | 📋 Scheduled (P1) |
| **Strategic Bets** | Outward-Facing Capability & Upstream Maturity Survey | GitHub API / PyPI / Citation Manifest | High | Medium | v0.2.23 | 📋 Scheduled (P2) |
| | Base-vs-Head Symbol Delta and Removed-Symbol Finding Exemption in Reviews | Python ast / git / lizard | High | Medium | v0.2.23 | 📋 Scheduled (P1) |
| | Base-vs-Head Symbol Delta and Removed-Symbol Finding Exemption in Reviews | Python ast / git / GitHub compare API | High | Medium | v0.2.25 | ✅ Completed (P1) |
| | Attested DevContainer Image Releases and Digest-Pinned, Verified Scaffolds | actions/attest-build-provenance, gh attestation verify | High | Medium | v0.3.5 | 📋 Scheduled (P1) |
| | Typed Step Journals for Partially Failed Mutating MCP Tools | OpenTofu JSON UI / Helm / FastMCP | High | Medium | v0.2.25 | 📋 Scheduled (P1) |
| **Incremental** | Attribute Verification Failure in AI Review | Pydantic / Structured Telemetry | Medium | Low | v0.2.23 | 📋 Scheduled (P2) |
Expand Down
Loading
Loading