yam-flow 0.1.0 → 0.1.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yam-flow",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Progressive proof-first agent flow: start fast, deepen deliberately, stay honest by design.",
5
5
  "type": "module",
6
6
  "author": "0kim0bos",
@@ -96,6 +96,7 @@
96
96
  "license": "MIT",
97
97
  "devDependencies": {
98
98
  "@types/node": "^25.9.1",
99
+ "playwright": "^1.60.0",
99
100
  "typescript": "^6.0.3"
100
101
  }
101
102
  }
@@ -36,6 +36,30 @@ Subagent policy:
36
36
  - If the user explicitly insists on mission despite missing subagents, mark the result `partial` or `blocked`; do not treat self-review as team execution.
37
37
  - The final proof must record the subagent decision: `used`, `downgraded_to_deep`, `unavailable_partial`, or `blocked`, with the reason.
38
38
 
39
+ Patch envelope:
40
+
41
+ Use a small envelope when a real mission lane changes code:
42
+
43
+ - `agent_id`: who or which lane made the change.
44
+ - `assigned_scope`: the bounded work area.
45
+ - `changed_files`: files the lane touched.
46
+ - `verification_hint`: the smallest relevant check for the lane.
47
+ - `rollback_hint`: what to inspect or revert if the change is wrong.
48
+ - `truth_status`: the lane's honest status.
49
+
50
+ This is only a record shape. It is not a queue, lock manager, or parallel apply engine.
51
+
52
+ Rollback hint:
53
+
54
+ Record:
55
+
56
+ - touched files
57
+ - generated files
58
+ - before check
59
+ - safe revert note
60
+
61
+ Do not claim rollback safety unless the relevant check or revert path was actually inspected.
62
+
39
63
  Runtime use:
40
64
 
41
65
  - Mission may use deep runtime verification when needed, but runtime proof alone does not make a mission if subagents were not used.
@@ -110,6 +110,19 @@ On demand:
110
110
 
111
111
  - command evidence
112
112
  - browser/screenshot evidence
113
+ - visual provenance for reference-based UI work
114
+ - mission patch envelopes for real team lanes
115
+ - rollback hints for risky changes
113
116
  - runtime/tmux/process cleanup evidence
114
117
  - truth status
115
118
  - skipped/blocked/assumed items
119
+
120
+ `yam release report --json` should collect release readiness into a machine-readable artifact:
121
+
122
+ - typecheck
123
+ - forbidden names
124
+ - package boundary
125
+ - registry status
126
+ - CLI smoke
127
+ - dist freshness
128
+ - final truth status
@@ -19,6 +19,26 @@ Skip or compress them when:
19
19
 
20
20
  ## Artifact Set
21
21
 
22
+ ### Opt-In CLI Helpers
23
+
24
+ Ueye is one route. It should not split into separate lite/deep skills. Use these helpers only when the current visual claim needs real evidence:
25
+
26
+ ```bash
27
+ yam ueye capture --url http://localhost:3000 --out .yam/screens/home.png
28
+ yam ueye compare --reference ./reference.png --actual .yam/screens/home.png --json
29
+ ```
30
+
31
+ - `capture` uses a Playwright install from the current project when present, then reports `blocked` instead of installing dependencies or pretending a screenshot exists.
32
+ - `compare` is local-only and dependency-free. It records hashes, dimensions, comparison result, and visual provenance. Different screenshots stay `partial`; exact file matches can be `verified`.
33
+ - Without capture or user-provided screenshots, report implementation/source review separately from visual verification and cap the visual claim.
34
+
35
+ ### Browser Preference
36
+
37
+ - Prefer the Codex in-app Browser plugin for local pages, localhost, file URLs, and ordinary visual QA.
38
+ - Do not silently switch to the user's Chrome browser when the in-app Browser cannot capture or inspect.
39
+ - Use Chrome only when the user explicitly asks for it, or when the task requires existing Chrome cookies, sessions, extensions, or profile state.
40
+ - If the in-app Browser is unavailable and Chrome was not explicitly requested or required, cap the visual claim at `partial` or `blocked`.
41
+
22
42
  ### Visual Evidence Inventory
23
43
 
24
44
  Purpose: identify what visual sources were inspected.
@@ -41,6 +61,25 @@ Bounds:
41
61
  - Record missing dimensions or hashes as `unknown`, not as failure.
42
62
  - Use generated annotations only as derivative aids.
43
63
 
64
+ ### Visual Provenance
65
+
66
+ Purpose: prove the visual source path from reference reading to implementation recheck.
67
+
68
+ Record these fields when a reference or screenshot materially affects the claim:
69
+
70
+ - `source_kind`
71
+ - `source_path`
72
+ - `source_hash`
73
+ - `reference_id`
74
+ - `screenshot_id`
75
+ - `local_only`
76
+ - `redacted`
77
+ - `operator_provided`
78
+ - `comparison_result`
79
+ - `truth_status`
80
+
81
+ Use `unknown` for missing hashes and `not-verified` for comparisons that were not actually rechecked. Do not upgrade a visual claim only because a reference was supplied.
82
+
44
83
  ### Reference Read Proof
45
84
 
46
85
  Purpose: separate reading the reference from judging the implementation.
@@ -49,12 +49,14 @@ Do not use for:
49
49
  - UX/browser verifier: checks screen behavior when relevant.
50
50
  - Doctor/scanner: checks direction fit, scope control, verification, cleanup, stale context, and false-completion risk.
51
51
  5. Execute the implementation in bounded steps.
52
- 6. Use `$deep`-style runtime verification when the mission needs dev server, tmux, test watcher, browser QA, cleanup, or before/after evidence.
53
- 7. Cross-check findings and resolve contradictions.
54
- 8. Run the smallest honest final verification set.
55
- 9. Run doctor scan with `references/doctor-scan.md`.
56
- 10. Confirm cleanup or explicitly report intentionally running processes.
57
- 11. Produce final proof summary, truth status, remaining tasks, and fix-first items.
52
+ 6. Record a compact patch envelope for each real lane that changes code.
53
+ 7. Add rollback hints for touched files, generated files, before checks, and safe revert notes.
54
+ 8. Use `$deep`-style runtime verification when the mission needs dev server, tmux, test watcher, browser QA, cleanup, or before/after evidence.
55
+ 9. Cross-check findings and resolve contradictions.
56
+ 10. Run the smallest honest final verification set.
57
+ 11. Run doctor scan with `references/doctor-scan.md`.
58
+ 12. Confirm cleanup or explicitly report intentionally running processes.
59
+ 13. Produce final proof summary, truth status, remaining tasks, and fix-first items.
58
60
 
59
61
  ## Proof Summary
60
62
 
@@ -64,6 +66,8 @@ Include:
64
66
  - Role work completed.
65
67
  - Subagent decision: used / downgraded_to_deep / unavailable_partial / blocked, with reason.
66
68
  - Files or surfaces changed.
69
+ - Patch envelope for each real code-changing lane.
70
+ - Rollback hint for risky or multi-file changes.
67
71
  - Runtime/tmux/browser evidence when used.
68
72
  - Cross-verification result.
69
73
  - Doctor/scanner result.
@@ -35,6 +35,8 @@ Do not use for:
35
35
  - Generated annotated images are optional, not a default gate.
36
36
  - Image evidence should stay bounded: inspect the primary screen first, then only the states/images needed to support the claim.
37
37
  - Design quality judgment belongs after implementation/review: compare to the reference first, then judge whether the result is good design.
38
+ - Keep Ueye as one route: start fast, then opt into `yam ueye capture` and `yam ueye compare` only when a `verified` visual claim needs real screen evidence.
39
+ - Prefer the Codex in-app Browser plugin for interactive visual checks. Do not switch to the user's Chrome browser unless the user explicitly asks for Chrome or the task requires existing Chrome cookies, sessions, extensions, or profile state.
38
40
 
39
41
  ## Workflow
40
42
 
@@ -52,6 +54,10 @@ Do not use for:
52
54
  6. Implement the smallest coherent design improvement when implementation is requested.
53
55
  7. Check default, loading, error, empty, disabled, hover/focus, and mobile states when relevant.
54
56
  8. Run browser/screenshot verification when feasible.
57
+ - Prefer the Codex in-app Browser plugin for local pages, localhost, file URLs, and ordinary visual QA.
58
+ - Do not silently use Chrome as a fallback. If the in-app Browser cannot capture or inspect, report the visual cap as `partial` or `blocked`.
59
+ - Use `yam ueye capture --url URL --out path.png` when a local Playwright install is available and the claim needs real browser evidence.
60
+ - Use `yam ueye compare --reference ref.png --actual shot.png` when reference fidelity needs a proof-ready local comparison record.
55
61
  9. Compare reference and implementation when reference fidelity was requested:
56
62
  - matched, similar, different, not-applicable, or not-verified.
57
63
  - Separate "faithful to reference" from "good design."
@@ -77,13 +83,16 @@ Use these artifacts for reference-led implementation or serious visual review. K
77
83
  - reference, before, and after evidence when available.
78
84
  - path or URL, source type, state, viewport, and visual verification cap.
79
85
  - sha256 and dimensions when an image file is locally available.
80
- 2. Reference Read Proof:
86
+ 2. Visual Provenance:
87
+ - source kind, path, hash, reference id, screenshot id, redaction/locality flags, operator-provided flag, comparison result, and truth status.
88
+ - use this to prove the route from reference reading to implementation recheck.
89
+ 3. Reference Read Proof:
81
90
  - concrete observations from the reference before implementation.
82
91
  - no implementation claim should depend on an unrecorded reference observation.
83
- 3. Reference vs Implementation Matrix:
92
+ 4. Reference vs Implementation Matrix:
84
93
  - compare the implemented result against the reference by aspect.
85
94
  - record matched, similar, different, not-applicable, or not-verified.
86
- 4. Design Quality Review:
95
+ 5. Design Quality Review:
87
96
  - judge whether the result is good UI/UX/design after reference comparison.
88
97
  - use pass, needs-polish, or fails for each relevant design dimension.
89
98