feat: split SRS into product requirements vs technical specs (srs-improved.md)#1
Open
paologaleotti wants to merge 8 commits into
Open
feat: split SRS into product requirements vs technical specs (srs-improved.md)#1paologaleotti wants to merge 8 commits into
paologaleotti wants to merge 8 commits into
Conversation
Adds a sixth role, the redattore, that runs in parallel with the final report and restructures the original SRS into a derivative markdown deliverable: every "[Work Item N]" section is split into two subsections — "Requisiti di prodotto" (the what/why, caller-visible behavior) and "Specifiche tecniche" (endpoints, schema/event identifiers, impl notes). Properties: - variant-agnostic and analysis-independent: reads only the original SRS (no findings/reviews/code/gh), so it is identical across the prescriptive/goals arms and never alters requirement meaning. - content-conservative: each original sentence is redistributed into exactly one subsection (no duplication, no dropping, no invented facts); code identifiers/SQL kept verbatim; non-WI sections passed through. - output is markdown for manual import into a NEW Confluence page (Insert > Markup > Markdown); the original page is never touched. - budget-gated skip-with-flag like the other optional roles; surfaced in RR-5. Also documents a driver-hygiene precondition in meta.whenToUse: on a re-run of an existing slug the driver must delete derived artifacts first (keeping repo-map/), because Write-tool roles without Bash (the redattore) are refused on a pre-existing un-Read file and would silently keep the stale version, and leftover prior-run files pollute the findings/*.md glob. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- restore the self-check rule: REDATTORE_SCHEMA.summary asks the agent to state a conservation check was done, but the prompt-simplification had dropped that rule — re-add it (rule 6) so schema and prompt agree and the content-conservation safety-net is back. - trim the meta.whenToUse driver-hygiene note: the redattore now Read-before-overwrites and reads back to confirm, so it does NOT silently keep a stale file; the genuine remaining reason for the pre-clean is findings/*.md glob pollution from differently-named prior-run files (read by report/ricognitore). Reworded accordingly. - document the redattore in the role-traceability doc comment (added role, no agents/*.md counterpart, variant-agnostic). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The redattore reads only the original SRS and now Read-before-overwrites its own output, so it needs no driver pre-clean. The findings/*.md glob pollution the note described concerns report/ricognitore — pre-existing upstream roles unrelated to this feature — so it does not belong in this PR. Restore upstream's original whenToUse verbatim. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
GorlemZ
reviewed
Jun 18, 2026
GorlemZ
left a comment
Contributor
There was a problem hiding this comment.
Review (no GitHub bias — posted on request). The editor sub-pipeline and role renames look solid: clean skeleton, correct null-handling in runEditor (skipEditor / reader / verify / rework failures), and the attached srs-improved.md shows it works end-to-end. Three points below — one design (token reserve), one docs, one prompt-contract.
Verdict: NEEDS_CHANGES (none are logic bugs in the skeleton).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds an editor step that runs in parallel with the final report and produces a derivative deliverable,
srs-improved.md. Every[Work Item N]section is restructured into two subsections and enriched with the behaviors the reverse-diff found in code but missing from the SRS:Output is markdown for manual import into a new Confluence page (Insert > Markup > Markdown) — the original page is never touched.
This PR also renames all workflow roles to English (
cartographer,crawler,analyzer,verifier,reverse-scout,editor) and writes every prompt in English (deliverables stay Italian on purpose).How — editor sub-pipeline
The editor is itself a small pipeline (runs concurrently with the report):
revisea single rework fixes the file. No separate review artifact.Key behaviors
_(nessun requisito di prodotto dedicato: WI tecnico/abilitante)_marker instead of padding.## Rilievi implementativi (non requisiti)appendix. Every added line carries a provenance marker_(da reverse-diff — presente nel codice, assente nell'SRS originale)_.Why
The SRS mixes product intent and implementation detail in the same paragraphs. Splitting them into a real product view vs a faithful technical view lets a PO validate behavior without parsing DDL, while the reverse-diff enrichment surfaces undocumented behavior the spec should capture. The independent adversarial verify keeps the rewrite honest (no dropped technical facts, no invented product claims, no code references, correctly-placed enrichment).
Validation
Test run against
pagopa/interop-be-monorepo@develop(epic PIN-8621, SRS = "DRAFT SRS Link Template EService-Agevolata"), 10 analysis units:srs-improved.mdregenerated with 0 code references, genuine product subsections, honest "nessun requisito" markers on technical-only WIs.