@pmelab/gtd 54.0.0 → 56.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +109 -104
- package/dist/chunks/{reserved-CQ7amcKG.mjs → reserved-B8EC-WE8.mjs} +124 -230
- package/dist/chunks/{review-CXzUXJHL.mjs → review-HdrX0FJ7.mjs} +30 -125
- package/dist/chunks/{steering-CLhu8C7q.mjs → steering-CCNvngSH.mjs} +256 -65
- package/dist/chunks/{tail-JZ9PAOwp.mjs → tail-BSLah2mA.mjs} +155 -63
- package/dist/gtd.bundle.mjs +259 -22
- package/dist/steering.mjs +2 -2
- package/dist/testkit.mjs +6 -6
- package/dist/web/main.css +1 -1
- package/dist/web/main.js +551 -66
- package/dist/workflow-kit.mjs +1 -1
- package/dist/workflows/cleanup.mjs +2 -2
- package/dist/workflows/feature.mjs +47 -102
- package/dist/workflows/fix.mjs +3 -3
- package/dist/workflows/review.mjs +3 -3
- package/dist/workflows/rollout.mjs +1 -1
- package/dist/workflows.mjs +614 -574
- package/package.json +1 -1
- package/skills/authoring/SKILL.md +3 -3
- package/src/cli/Cli.ts +5 -5
- package/src/edge/Edge.test.ts +1 -1
- package/src/steering/FORMATS.md +5 -1
- package/src/steering/SteeringFormats.test.ts +2 -2
- package/src/steering/contract.test.ts +1 -0
- package/src/steering/findings.test.ts +47 -0
- package/src/steering/findings.ts +350 -0
- package/src/steering/fixtures/findings/gate.md +34 -0
- package/src/steering/fixtures/findings/gate.read.json +87 -0
- package/src/steering/index.test.ts +2 -2
- package/src/steering/index.ts +4 -3
- package/src/steering/review.test.ts +1 -75
- package/src/steering/review.ts +1 -74
- package/src/workflow/compile.test.ts +1 -0
- package/src/workflows/feature/criteria-coverage.feature +104 -0
- package/src/workflows/feature/feature.test.ts +1 -1
- package/src/workflows/feature/feature.ts +17 -20
- package/src/workflows/feature/green.ts +2 -5
- package/src/workflows/feature/lens-review.feature +323 -171
- package/src/workflows/feature/naive-acceptance.feature +31 -32
- package/src/workflows/feature/prototype.ts +5 -8
- package/src/workflows/feature/refactor-absorbs.feature +1 -7
- package/src/workflows/feature/refactor-first.feature +2 -10
- package/src/workflows/feature/refactor-rebuild.feature +20 -36
- package/src/workflows/feature/refactor-review.feature +33 -117
- package/src/workflows/feature/refactor.test.ts +0 -2
- package/src/workflows/feature/refactor.ts +0 -1
- package/src/workflows/feature/review-gate.feature +6 -22
- package/src/workflows/feature/reviewer-walkthrough.feature +16 -103
- package/src/workflows/feature/seam.test.ts +19 -101
- package/src/workflows/feature/seam.ts +13 -89
- package/src/workflows/feature/standards.feature +75 -34
- package/src/workflows/fix/fix-lens-origin.feature +20 -7
- package/src/workflows/fix/fix-quality.feature +104 -23
- package/src/workflows/review/review-door.feature +62 -59
- package/src/workflows/shared/access.test.ts +1 -0
- package/src/workflows/shared/learn.test.ts +0 -14
- package/src/workflows/shared/learn.ts +1 -6
- package/src/workflows/shared/lenses.ts +149 -43
- package/src/workflows/shared/review.test.ts +30 -27
- package/src/workflows/shared/review.ts +29 -196
- package/src/workflows/shared/skills.test.ts +3 -1
- package/src/workflows/shared/steps.test.ts +9 -6
- package/src/workflows/shared/steps.ts +12 -3
- package/src/workflows/shared/tail.test.ts +20 -2
- package/src/workflows/shared/tail.ts +38 -16
- package/src/workflows/shared/text.test.ts +122 -294
- package/src/workflows/shared/text.ts +181 -358
- package/src/workflows/shared/vars.ts +1 -1
- package/src/workflows/feature/review-answers.feature +0 -324
- package/src/workflows/feature/severity-budget.feature +0 -116
- package/src/workflows/feature/severity-sorted-review.feature +0 -198
package/README.md
CHANGED
|
@@ -474,24 +474,37 @@ noted in steps 3 and 4 below.
|
|
|
474
474
|
and skip a gate unattended.**
|
|
475
475
|
|
|
476
476
|
Once the change is built, the whole change goes through a qualitative review
|
|
477
|
-
lap before you see anything:
|
|
477
|
+
lap before you see anything: seven lenses, one turn each, in order —
|
|
478
478
|
`correctness`, `owasp-security`, `ponytail-review`, `test-audit`,
|
|
479
|
-
`conventions`, `spec-challenge`. `correctness`,
|
|
480
|
-
`spec-challenge`
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
(
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
479
|
+
`conventions`, `spec-challenge`, `criteria-coverage`. `correctness`,
|
|
480
|
+
`owasp-security`, `spec-challenge` and `criteria-coverage` run on the planner
|
|
481
|
+
model (`smart`), the other three on the coder model (`base`); a
|
|
482
|
+
`qualityReviews` entry `<lens>=<model>` picks a lens's own.
|
|
483
|
+
`criteria-coverage` reads the requirements and the change's tests and writes
|
|
484
|
+
one finding per acceptance criterion no test exercises; with no requirements
|
|
485
|
+
(the `review` and `fix` workflows) it runs no turn. Each traces the change
|
|
486
|
+
from its own angle and records every finding, blocking or not, as its own
|
|
487
|
+
`## ` chunk of `.gtd/QUALITY.md`. A clean turn means approval only when that
|
|
488
|
+
lens found nothing at all. The lenses are the only agentic review: a judge
|
|
489
|
+
(`build.quality.triage`) then classifies each finding — `mechanical` ones are
|
|
490
|
+
fixed by the fix turn (`build.fix.quality.fixing`, up to three turns),
|
|
491
|
+
`noise` is dropped with its `p` recorded as
|
|
492
|
+
`Gtd-Mark: noise=<id> p=<p> <title>`, and `design` ones (questioning a
|
|
493
|
+
criterion or the approach) become notes. An unsure verdict (below
|
|
494
|
+
`qualityTriageMinP`, `0.7`) is `design`; mechanical findings the fix turns
|
|
495
|
+
leave become notes too. **The finding gate** (`build.quality.gate`) then
|
|
496
|
+
stops for you: `.gtd/QUALITY.md` lists the notes, then the noise under
|
|
497
|
+
`# Dropped as noise` so you can overrule the judge, each with one `- [ ] fix`
|
|
498
|
+
box. Tick a finding to have it fixed, optionally with a line of guidance
|
|
499
|
+
below its box; leave it unticked to drop it — landing the file untouched
|
|
500
|
+
drops them all, and guidance under an unticked box is refused. The ticked
|
|
501
|
+
ones go to the same fix turns (up to three), then the suite is kept green;
|
|
502
|
+
what they leave is listed as unresolved, with no second gate. A ticked
|
|
503
|
+
finding is fixed, never re-planned: raise anything bigger in your review. A
|
|
504
|
+
lap with no notes and no noise has no gate. This lap is where code quality is
|
|
505
|
+
looked at, and every round pays for it. It never replaces step 4 — your
|
|
493
506
|
review stays the final gate, and nothing here skips it. The `fix` and
|
|
494
|
-
`cleanup` doors
|
|
507
|
+
`cleanup` doors run the same lap and gate before their own review.
|
|
495
508
|
|
|
496
509
|
A red suite that keeps failing past a few fix attempts escalates instead of
|
|
497
510
|
retrying forever: an agent turn reads the failing output and writes
|
|
@@ -509,46 +522,37 @@ noted in steps 3 and 4 below.
|
|
|
509
522
|
4. **You review.** After the quality lap a reviewer turn
|
|
510
523
|
(`build.review.reviewing`) walks you through the whole change: `## ` chunks
|
|
511
524
|
grouped by concern, **every chunk pointing at its code**
|
|
512
|
-
(`./path#start-end`), so the phone shows the diff beside each one.
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
**
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
note
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
naive pass or seam judge, the hands-on test runs again, the quality lap runs,
|
|
544
|
-
and you review again. At the refactor review an `edit` re-derives the
|
|
545
|
-
refactor instead. A `question` is answered inline under your note and the
|
|
546
|
-
process stops at the review again — no new plan. A `nit` is fixed in one
|
|
547
|
-
batch, the suite must go green (a red one gets fix turns first), then a fresh
|
|
548
|
-
review of the change stops at the review again. `praise` is dropped; a round
|
|
549
|
-
of only praise signs off. When a round mixes them, questions are answered and
|
|
550
|
-
nits fixed first, then the edits are planned — risk: the planning lap may
|
|
551
|
-
redo nit fixes it touches.
|
|
525
|
+
(`./path#start-end`), so the phone shows the diff beside each one. gtd
|
|
526
|
+
appends one `## Quality lap` chunk (`build.review.carrying`) listing, for
|
|
527
|
+
reference, what the quality lap did with every finding: **fixed
|
|
528
|
+
automatically** and **fixed at the finding gate** (each with its fixing
|
|
529
|
+
commit), **dropped at the finding gate**, **dropped as noise**, and
|
|
530
|
+
**unresolved after the finding gate**. To reopen one, write a note under its
|
|
531
|
+
line. A review with a chunk pointing at no code is refused
|
|
532
|
+
(`review-pointers`). A pointer note the reviewer opens with `Risk:` is fixed
|
|
533
|
+
before you see the review (`build.review.fix.risks.fixing`), then the review
|
|
534
|
+
is written again over the reviewer's own draft. On `refactor-first` the
|
|
535
|
+
refactor gets a walkthrough of its own first, covering the whole refactor on
|
|
536
|
+
every round, before the feature is built; see
|
|
537
|
+
[the naive pass](#the-naive-pass). Land with nothing changed to approve, or
|
|
538
|
+
write what is wrong. A note added with its own `Tick exactly one:` boxes (as
|
|
539
|
+
`/gtd pr` imports a thread) is answered by its tick instead of judged: fix as
|
|
540
|
+
suggested joins the nit batch below, won't fix drops it and records
|
|
541
|
+
`Gtd-Mark: wontfix=<title>`, your own answer is judged like a note. Approving
|
|
542
|
+
ends the process (at the refactor review, it moves on to the feature);
|
|
543
|
+
feedback is judged note by note, each as `edit`, `question`, `nit` or
|
|
544
|
+
`praise`. An `edit` sends the process back to step 2 for re-derived
|
|
545
|
+
requirements — the built criteria keep their IDs (reworded in place when
|
|
546
|
+
their behaviour changes) and new behaviour gets new ones — then the
|
|
547
|
+
implementation is amended to meet them, with no new naive pass or seam judge,
|
|
548
|
+
the hands-on test runs again, the quality lap runs, and you review again. At
|
|
549
|
+
the refactor review an `edit` re-derives the refactor instead. A `question`
|
|
550
|
+
is answered inline under your note and the process stops at the review again
|
|
551
|
+
— no new plan. A `nit` is fixed in one batch, the suite must go green (a red
|
|
552
|
+
one gets fix turns first), then a fresh review of the change stops at the
|
|
553
|
+
review again. `praise` is dropped; a round of only praise signs off. When a
|
|
554
|
+
round mixes them, questions are answered and nits fixed first, then the edits
|
|
555
|
+
are planned — risk: the planning lap may redo nit fixes it touches.
|
|
552
556
|
|
|
553
557
|
Each `edit` note also gets a severity tier from four judge questions
|
|
554
558
|
(security, reversibility, blast radius, new concept). Every tier is
|
|
@@ -596,9 +600,10 @@ conversation under their block, question, chunk, or hunk, and one the agent
|
|
|
596
600
|
answered last carries a "waiting on you" badge. Tap it to reply — your reply is
|
|
597
601
|
added as a new `H:` entry; while the agent has yet to answer, reopening it edits
|
|
598
602
|
your last entry instead. Tap an already-answered question to leave a note on it;
|
|
599
|
-
the agent may overturn the answer.
|
|
600
|
-
|
|
601
|
-
|
|
603
|
+
the agent may overturn the answer. At the finding gate the phone lists the open
|
|
604
|
+
findings, then those dropped as noise, each with a fix checkbox and, once
|
|
605
|
+
ticked, an optional line of guidance; Done stays disabled while the file holds
|
|
606
|
+
anything the gate would refuse. See
|
|
602
607
|
[Configuration](https://github.com/pmelab/gtd/blob/main/docs/configuration.md)
|
|
603
608
|
for its `ui:` settings.
|
|
604
609
|
|
|
@@ -612,17 +617,15 @@ gtd door review <commitish>
|
|
|
612
617
|
|
|
613
618
|
starts a review of everything from `<commitish>` to HEAD — the same review a
|
|
614
619
|
`feature` process ends with, minus planning and building. A green gate, then the
|
|
615
|
-
quality lenses: mechanical findings are fixed,
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
start one. `gtd door fix` repairs a red baseline as its own reviewed commit; a
|
|
625
|
-
note at its review is left in `.gtd/REVIEW.md` (beside the reviewer's original,
|
|
620
|
+
quality lenses: mechanical findings are fixed, the rest wait at the finding
|
|
621
|
+
gate, then a reviewer walks you through the change in `.gtd/REVIEW.md`, with the
|
|
622
|
+
lap's summary. A nit note is fixed in place; a note asking for a change is
|
|
623
|
+
collected into `.gtd/REQUIREMENTS.md` and built by one `feedback.fixing` turn,
|
|
624
|
+
with no design phase and no criteria — under the health loop, then it asks for
|
|
625
|
+
your review again. Sign off and it closes; nothing is left behind. A note asking
|
|
626
|
+
for new behaviour belongs in a `feature` process: sign off and start one.
|
|
627
|
+
`gtd door fix` repairs a red baseline as its own reviewed commit; a note at its
|
|
628
|
+
review is left in `.gtd/REVIEW.md` (beside the reviewer's original,
|
|
626
629
|
`.gtd/REVIEW.orig.md`) for the next `gtd door fix`, and until that runs,
|
|
627
630
|
starting `feature` or `review` is refused — remove both files to abandon the
|
|
628
631
|
hand-off. `gtd doors` lists the doors of the workflows your `gtd.config.ts`
|
|
@@ -652,39 +655,41 @@ home directory — fails every command until you delete it. See
|
|
|
652
655
|
#### The naive pass
|
|
653
656
|
|
|
654
657
|
After design the agent first implements the requirements directly,
|
|
655
|
-
breadth-first
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
file it added, or the suite is red on it. A
|
|
659
|
-
anything outside the expected set (tests,
|
|
660
|
-
Incidental changes land: the pass itself is
|
|
661
|
-
straight through the health loop and the
|
|
662
|
-
resets: the pass is never applied. An agent
|
|
663
|
-
refactor note (`.gtd/REFACTOR-NOTE.md`: which
|
|
664
|
-
refactored first, flag-free with the existing
|
|
665
|
-
own quality lap (`refactorQualityReviews`) and
|
|
666
|
-
rebuilt on the refactored base, behind a release
|
|
667
|
-
naive diff as reference. The rebuild is
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
658
|
+
breadth-first. It is asked to test the behaviour the criteria describe — one
|
|
659
|
+
test per behaviour, not per criterion, with no criterion ID in a test name —
|
|
660
|
+
through code that existed before the pass, but no test is required. The pass is
|
|
661
|
+
sent back while a test imports a file it added, or the suite is red on it. A
|
|
662
|
+
judge checks whether it changed anything outside the expected set (tests,
|
|
663
|
+
steering files; see `seamAllow`). Incidental changes land: the pass itself is
|
|
664
|
+
the implementation, with no rebuild, straight through the health loop and the
|
|
665
|
+
quality lap. A needed seam change resets: the pass is never applied. An agent
|
|
666
|
+
reads its whole diff and writes a refactor note (`.gtd/REFACTOR-NOTE.md`: which
|
|
667
|
+
seams, which shape); the seam is refactored first, flag-free with the existing
|
|
668
|
+
suite green, on its own with its own quality lap (`refactorQualityReviews`) and
|
|
669
|
+
review; then the feature is rebuilt on the refactored base, behind a release
|
|
670
|
+
flag, with the note and the naive diff as reference. The rebuild is asked to
|
|
671
|
+
carry over every test file the naive pass added or changed, and the suite must
|
|
672
|
+
be green; whether each criterion is still tested is the `criteria-coverage`
|
|
673
|
+
lens's call in the quality lap. A wrong approach is retried twice, then rests
|
|
674
|
+
for you to steer or overrule it. A refactor that already carried the whole
|
|
675
|
+
feature leaves the rebuild only the carried-over tests, and the feature's
|
|
676
|
+
quality lap and review cover the whole change. Once the implementation is green,
|
|
677
|
+
a judge asks, per acceptance criterion, whether a person can observe it by using
|
|
678
|
+
the software; an agent then uses the change by hand for those — the real program
|
|
679
|
+
in a scratch directory, the real page, guided by a project skill or a manual
|
|
680
|
+
testing section in `AGENTS.md`, `CLAUDE.md` or `README.md` — and writes
|
|
681
|
+
`.gtd/PROTOTYPE.md`: per criterion pass, fail or blocked, with the steps run and
|
|
682
|
+
what it saw. A criterion the judge finds no one can observe (a refactor,
|
|
683
|
+
something left unchanged, internal shape), or one design tagged `(no hands-on)`,
|
|
684
|
+
is skipped; a change with none left skips this step. This is the one check that
|
|
685
|
+
a criterion is met: with `prototypeRounds` set to `0` nothing checks the
|
|
686
|
+
criteria beyond the green suite. Failures are fixed and re-tested before the
|
|
687
|
+
quality lap, up to `prototypeRounds` (3) fix rounds; past them, with only
|
|
688
|
+
blocked items, or with no way to test found, it rests for you. See
|
|
689
|
+
[The hands-on test](docs/configuration.md#the-hands-on-test). Feedback at the
|
|
690
|
+
feature review re-runs design and the implementation, never the naive pass;
|
|
691
|
+
feedback at the refactor review re-runs the refactor, never design; a
|
|
692
|
+
refactor-review change the refactor cannot build is refused, and the only way
|
|
688
693
|
out is `gtd abandon`. A process from 27.5.0 or later whose judge ruled
|
|
689
694
|
`refactor-first` must `gtd abandon` too. Details in
|
|
690
695
|
[the naive-pass path](docs/configuration.md#the-naive-pass-path).
|
|
@@ -878,7 +883,7 @@ gtd is one package, `@pmelab/gtd`, and every entrypoint shares its version and
|
|
|
878
883
|
| -------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
879
884
|
| `@pmelab/gtd/flows` | The flow API a workflow is written in: the steps (`agent`, `human`, `run`, …), `scope`, workflow factories, `defineConfig` and `FLOWS_PROTOCOL`. |
|
|
880
885
|
| `@pmelab/gtd/wire` | The driver protocol: `WIRE_SCHEMA`, the exit codes and the types of every `--json` document. |
|
|
881
|
-
| `@pmelab/gtd/steering` | The steering-file formats (`qa`, `review`) and the review-note readers.
|
|
886
|
+
| `@pmelab/gtd/steering` | The steering-file formats (`qa`, `review`, `findings`) and the review-note readers. |
|
|
882
887
|
| `@pmelab/gtd/workflow-kit` | Policy-free building blocks to compose a workflow from: health checks, quality laps, scenario freezing, review tails. |
|
|
883
888
|
| `@pmelab/gtd/workflows` | Every shipped workflow and all its parts in one module; also resolvable as `@pmelab/gtd/workflow`. |
|
|
884
889
|
| `@pmelab/gtd/workflows/feature`, `@pmelab/gtd/workflows/review`, `@pmelab/gtd/workflows/fix`, `@pmelab/gtd/workflows/rollout`, `@pmelab/gtd/workflows/cleanup` | One shipped workflow each: its factory as the default export, its parts, and the reserved exports (`defaults`, `envDefaults`, `summary`, `steering`, `skills`, `access`). `gtd install` imports these. |
|