@v11g/agents-rock 1.0.9 → 1.0.11
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/README.md +3 -1
- package/package.json +2 -2
- package/plugins/business-analyst/.claude-plugin/plugin.json +2 -2
- package/plugins/business-analyst/evals/ba-interview-conflict/graders/conflict-quoted.md +15 -0
- package/plugins/business-analyst/evals/ba-interview-conflict/graders/no-internal-ids.md +9 -0
- package/plugins/business-analyst/evals/ba-interview-conflict/graders/one-question.md +15 -0
- package/plugins/business-analyst/evals/ba-interview-conflict/graders/skill-fired.md +7 -0
- package/plugins/business-analyst/evals/ba-interview-conflict/prompt.md +31 -0
- package/plugins/business-analyst/evals/ba-interview-first-turn/graders/no-internal-ids.md +9 -0
- package/plugins/business-analyst/evals/ba-interview-first-turn/graders/no-setup-questions.md +16 -0
- package/plugins/business-analyst/evals/ba-interview-first-turn/graders/one-scope-question.md +19 -0
- package/plugins/business-analyst/evals/ba-interview-first-turn/graders/skill-fired.md +7 -0
- package/plugins/business-analyst/evals/ba-interview-first-turn/prompt.md +31 -0
- package/plugins/business-analyst/evals/ba-review-page/case.yaml +4 -0
- package/plugins/business-analyst/evals/ba-review-page/fixture.sh +12 -0
- package/plugins/business-analyst/evals/ba-review-page/graders/decide-in-interview.md +26 -0
- package/plugins/business-analyst/evals/ba-review-page/graders/skill-fired.md +7 -0
- package/plugins/business-analyst/evals/ba-review-page/prompt.md +9 -0
- package/plugins/business-analyst/evals/draft-scope-rich/case.yaml +4 -0
- package/plugins/business-analyst/evals/draft-scope-rich/fixture.sh +5 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/conflict-question.md +11 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/keep-and-exclude.md +14 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/noise-and-shape.md +13 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/problem-not-solution.md +13 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/share-kept.md +11 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/skill-fired.md +7 -0
- package/plugins/business-analyst/evals/draft-scope-rich/graders/vague-word.md +13 -0
- package/plugins/business-analyst/evals/draft-scope-rich/inputs/C1.txt +10 -0
- package/plugins/business-analyst/evals/draft-scope-rich/inputs/E1.txt +5 -0
- package/plugins/business-analyst/evals/draft-scope-rich/inputs/E2.txt +5 -0
- package/plugins/business-analyst/evals/draft-scope-rich/inputs/E3.txt +5 -0
- package/plugins/business-analyst/evals/draft-scope-rich/prompt.md +9 -0
- package/plugins/business-analyst/evals/draft-scope-thin/case.yaml +4 -0
- package/plugins/business-analyst/evals/draft-scope-thin/fixture.sh +4 -0
- package/plugins/business-analyst/evals/draft-scope-thin/graders/no-invention.md +18 -0
- package/plugins/business-analyst/evals/draft-scope-thin/graders/skill-fired.md +7 -0
- package/plugins/business-analyst/evals/draft-scope-thin/inputs/E1.txt +5 -0
- package/plugins/business-analyst/evals/draft-scope-thin/prompt.md +8 -0
- package/plugins/business-analyst/skills/business-analyst/README.md +8 -0
- package/plugins/business-analyst/skills/business-analyst/SKILL.md +47 -16
- package/plugins/business-analyst/skills/business-analyst/assets/review-page.html +68 -0
- package/plugins/business-analyst/skills/business-analyst/evals/evals.json +1 -1
- package/plugins/business-analyst/skills/business-analyst/references/frameworks.md +3 -2
- package/plugins/business-analyst/skills/business-analyst/references/interview.md +156 -8
- package/plugins/business-analyst/skills/business-analyst/references/review.md +18 -4
- package/plugins/business-analyst/skills/business-analyst/references/writing.md +49 -8
- package/plugins/business-analyst/skills/business-analyst/scripts/__pycache__/review_data.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/__pycache__/review_layout.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/__pycache__/review_page.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/__pycache__/scope_checks.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/__pycache__/scope_render.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/__pycache__/validate.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/checks.mjs +12 -6
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/review-data.mjs +66 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/review-layout.mjs +53 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/review-page.mjs +78 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/scope-checks.mjs +73 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/scope-md.mjs +53 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/scope-render.mjs +72 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/lib/scope-rules.mjs +90 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/review.mjs +48 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/review.py +60 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/review_data.py +81 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/review_layout.py +50 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/review_page.py +115 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/scope.mjs +24 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/scope.py +35 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/scope_checks.py +168 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/scope_render.py +140 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/checks.test.mjs +27 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/fixtures/requirements-workflow-pass.json +78 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/fixtures/requirements-workflow-pass.md +136 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/python-parity.test.mjs +88 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/quality-gates.test.mjs +26 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/review-browser.test.mjs +106 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/review-fixture.mjs +32 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/review-page.test.mjs +340 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/review-parity.test.mjs +79 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/scope-cases.mjs +58 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/scope-checks.test.mjs +31 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/test/scope-md.test.mjs +140 -0
- package/plugins/business-analyst/skills/business-analyst/scripts/validate.mjs +1 -1
- package/plugins/business-analyst/skills/business-analyst/scripts/validate.py +17 -8
- package/plugins/business-analyst/skills/draft-scope/SKILL.md +46 -0
- package/plugins/business-analyst/skills/draft-scope/references/credits.md +12 -0
- package/plugins/business-analyst/skills/draft-scope/references/draft-schema.md +44 -0
- package/plugins/business-analyst/skills/draft-scope/references/rules.md +24 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/docx_body.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/docx_flow.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/docx_package.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/docx_xml.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/draft_quotes.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/draft_rules.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/__pycache__/draft_schema.cpython-312.pyc +0 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/build_docx.py +36 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/check.py +53 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/docx_body.py +58 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/docx_flow.py +52 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/docx_package.py +62 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/docx_xml.py +44 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/draft_quotes.py +49 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/draft_rules.py +106 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/draft_schema.py +87 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/build-docx.test.mjs +76 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/check-rules.test.mjs +131 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/check-shape.test.mjs +70 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/fixtures/draft-pass.json +40 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/fixtures/sources/C1.txt +7 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/fixtures/sources/E1.txt +5 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/gates.test.mjs +39 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/helpers.mjs +30 -0
- package/plugins/business-analyst/skills/draft-scope/scripts/test/skill-files.test.mjs +59 -0
- package/plugins/business-analyst/skills/draft-scope/steps/assumptions.md +24 -0
- package/plugins/business-analyst/skills/draft-scope/steps/check.md +24 -0
- package/plugins/business-analyst/skills/draft-scope/steps/discover.md +53 -0
- package/plugins/business-analyst/skills/draft-scope/steps/draft.md +64 -0
- package/plugins/solution-architect/.claude-plugin/plugin.json +1 -1
- package/plugins/solution-architect/evals/proposal-workflow/case.yaml +6 -0
- package/plugins/solution-architect/evals/proposal-workflow/fixture.sh +6 -0
- package/plugins/solution-architect/evals/proposal-workflow/graders/inputs-written.md +23 -0
- package/plugins/solution-architect/evals/proposal-workflow/graders/no-proposal-md.md +7 -0
- package/plugins/solution-architect/evals/proposal-workflow/graders/skill-fired.md +7 -0
- package/plugins/solution-architect/evals/proposal-workflow/graders/validate-then-render.md +16 -0
- package/plugins/solution-architect/evals/proposal-workflow/prompt.md +10 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/case.yaml +4 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/fixture.sh +6 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/graders/no-classic-fallback.md +10 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/graders/nothing-written.md +7 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/graders/skill-fired.md +7 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/graders/stops-at-gate.md +11 -0
- package/plugins/solution-architect/evals/workflow-gate-no-architecture/prompt.md +7 -0
- package/plugins/solution-architect/evals/workflow-happy-path/case.yaml +4 -0
- package/plugins/solution-architect/evals/workflow-happy-path/fixture.sh +6 -0
- package/plugins/solution-architect/evals/workflow-happy-path/graders/no-estimation-md.md +7 -0
- package/plugins/solution-architect/evals/workflow-happy-path/graders/pages-or-stop.md +16 -0
- package/plugins/solution-architect/evals/workflow-happy-path/graders/routed-to-workflow.md +12 -0
- package/plugins/solution-architect/evals/workflow-happy-path/graders/skill-fired.md +7 -0
- package/plugins/solution-architect/evals/workflow-happy-path/graders/three-questions-max.md +14 -0
- package/plugins/solution-architect/evals/workflow-happy-path/graders/workflow-or-exact-stop.md +15 -0
- package/plugins/solution-architect/evals/workflow-happy-path/prompt.md +9 -0
- package/plugins/solution-architect/skills/analyze-requirements/SKILL.md +8 -7
- package/plugins/solution-architect/skills/analyze-requirements/assets/section-help.json +5 -5
- package/plugins/solution-architect/skills/analyze-requirements/assets/viewer-template.html +26 -4
- package/plugins/solution-architect/skills/analyze-requirements/evals/evals.json +50 -6
- package/plugins/solution-architect/skills/analyze-requirements/evals/fixtures/ba-package-citations/requirements.json +31 -0
- package/plugins/solution-architect/skills/analyze-requirements/evals/fixtures/ba-package-citations/requirements.md +17 -0
- package/plugins/solution-architect/skills/analyze-requirements/evals/fixtures/transcript-citations/C1-kickoff-call.txt +16 -0
- package/plugins/solution-architect/skills/analyze-requirements/evals/fixtures/transcript-citations/E1-intro-email.md +9 -0
- package/plugins/solution-architect/skills/analyze-requirements/references/extract.md +108 -0
- package/plugins/solution-architect/skills/analyze-requirements/references/interview.md +39 -5
- package/plugins/solution-architect/skills/analyze-requirements/references/project-types.md +1 -1
- package/plugins/solution-architect/skills/analyze-requirements/references/quality-goals.md +84 -0
- package/plugins/solution-architect/skills/analyze-requirements/references/research.md +1 -1
- package/plugins/solution-architect/skills/analyze-requirements/references/rewriting.md +7 -2
- package/plugins/solution-architect/skills/analyze-requirements/references/viewer.md +10 -6
- package/plugins/solution-architect/skills/analyze-requirements/references/writing.md +45 -3
- package/plugins/solution-architect/skills/analyze-requirements/scripts/ba-facts.mjs +32 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/check-quotes.mjs +39 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/ba-package.mjs +75 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/doc-links.mjs +19 -7
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/doc-routes.mjs +1 -1
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/inputs.mjs +42 -11
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/md-render.mjs +15 -4
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/section-help.mjs +1 -1
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/strategy-sections.mjs +30 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/validate-provenance.mjs +14 -2
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/validate-quotes.mjs +55 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/lib/validate-strategy.mjs +65 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/render.mjs +18 -5
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/ba-facts-cli.test.mjs +55 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/ba-package-cli.test.mjs +101 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/ba-package.test.mjs +115 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/browser.test.mjs +77 -2
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/check-quotes-cli.test.mjs +49 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/doc-links.test.mjs +49 -4
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/extract-workflow.test.mjs +69 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/inputs.test.mjs +14 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/md-render.test.mjs +19 -5
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/record-cli.test.mjs +1 -1
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/render.test.mjs +69 -2
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/rewriting.test.mjs +1 -1
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/section-help.test.mjs +6 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/validate-provenance.test.mjs +19 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/validate-quotes-cli.test.mjs +58 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/validate-quotes.test.mjs +81 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/validate-strategy-cli.test.mjs +32 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/test/validate-strategy.test.mjs +118 -0
- package/plugins/solution-architect/skills/analyze-requirements/scripts/validate.mjs +17 -6
- package/plugins/solution-architect/skills/analyze-requirements/workflows/extract.js +51 -0
- package/plugins/solution-architect/skills/estimate/README.md +18 -3
- package/plugins/solution-architect/skills/estimate/SKILL.md +18 -75
- package/plugins/solution-architect/skills/estimate/classic/FLOW.md +77 -0
- package/plugins/solution-architect/skills/estimate/classic/assets/estimate-template.html +1337 -0
- package/plugins/solution-architect/skills/estimate/{references → classic/references}/task-shapes.md +1 -1
- package/plugins/solution-architect/skills/estimate/{references → classic/references}/writing.md +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/compute.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/checks.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/roadmap.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/rollup.mjs +5 -5
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/schema.mjs +4 -26
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/score-csv.mjs +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/score-html.mjs +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/render.mjs +8 -7
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/score-review.mjs +3 -3
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/baselines.test.mjs +3 -3
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/browser-agentic.test.mjs +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/browser.test.mjs +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/compute.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/e2e.test.mjs +6 -6
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/estimate-math.test.mjs +3 -3
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/measurements.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/pricing.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/project-price.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/quality-gates.test.mjs +7 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/references.test.mjs +6 -6
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/render.test.mjs +3 -3
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/schema.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/score-review.test.mjs +6 -6
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/scoring.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/url-state.test.mjs +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/validate.test.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/xlsx-export.test.mjs +3 -3
- package/plugins/solution-architect/skills/estimate/classic/scripts/test/zip-store.test.mjs +26 -0
- package/plugins/solution-architect/skills/estimate/evals/evals.json +37 -2
- package/plugins/solution-architect/skills/estimate/evals/fixtures/workflow-sin-kowa-mini/ARCHITECTURE.md +28 -0
- package/plugins/solution-architect/skills/estimate/evals/fixtures/workflow-sin-kowa-mini/requirements.json +79 -0
- package/plugins/solution-architect/skills/estimate/evals/fixtures/workflow-sin-kowa-mini/requirements.md +141 -0
- package/plugins/solution-architect/skills/estimate/shared/assets/xlsx-export.js +336 -0
- package/plugins/solution-architect/skills/estimate/shared/lib/agentic-task-schema.mjs +24 -0
- package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/context-schema.mjs +2 -2
- package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/inline.mjs +8 -0
- package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/scoring-schema.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/scoring.mjs +1 -1
- package/plugins/solution-architect/skills/estimate/shared/lib/zip.mjs +60 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/FLOW.md +91 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/assets/estimate-components.html +994 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/assets/estimate-template.html +440 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/assets/estimator-system.xlsx +0 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/assets/score-review.html +838 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/references/hidden-work-by-type.md +429 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/references/linking.md +59 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/build-components-template.mjs +80 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/build-template.mjs +60 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/build-workflow-template.mjs +51 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/build-xlsx-template.py +144 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/compute.mjs +32 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/page-html.mjs +44 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/page-view.mjs +71 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/pair-findings.mjs +19 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/requirements.mjs +33 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/rollup.mjs +66 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/schema-components.mjs +69 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/schema.mjs +70 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/score-diff.mjs +54 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/score-html.mjs +52 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/lib/xlsx-rows.mjs +51 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/render.mjs +42 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/score-review.mjs +46 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/template/arch-link.js +9 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/template/click.js +28 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/template/prelude.js +4 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/template/view.js +63 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/browser.test.mjs +127 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/build-pages.test.mjs +43 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/build-template.test.mjs +18 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/cli.test.mjs +48 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/estimator-system.test.mjs +66 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/fixtures/ARCHITECTURE-mini.md +31 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/fixtures/feedback.json +19 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/fixtures/inputs-pass.json +80 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/fixtures/measurements.jsonl +0 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/fixtures/requirements.json +79 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/page-view.test.mjs +54 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/pages-browser.test.mjs +209 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/quality-gates.test.mjs +25 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/render.test.mjs +54 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/requirements.test.mjs +33 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/rollup.test.mjs +80 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/schema.test.mjs +61 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/score-review.test.mjs +108 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/stage.mjs +32 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/workflow-script.test.mjs +24 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/test/xlsx-rows.test.mjs +58 -0
- package/plugins/solution-architect/skills/estimate/workflow-based/scripts/validate.mjs +19 -0
- package/plugins/solution-architect/skills/proposal/README.md +13 -0
- package/plugins/solution-architect/skills/proposal/SKILL.md +8 -0
- package/plugins/solution-architect/skills/proposal/assets/proposal-workflow.html +143 -0
- package/plugins/solution-architect/skills/proposal/evals/fixtures/workflow-sin-kowa-mini/ARCHITECTURE.md +31 -0
- package/plugins/solution-architect/skills/proposal/evals/fixtures/workflow-sin-kowa-mini/estimation-inputs.json +468 -0
- package/plugins/solution-architect/skills/proposal/evals/fixtures/workflow-sin-kowa-mini/estimation.json +773 -0
- package/plugins/solution-architect/skills/proposal/evals/fixtures/workflow-sin-kowa-mini/measurements.jsonl +0 -0
- package/plugins/solution-architect/skills/proposal/evals/fixtures/workflow-sin-kowa-mini/requirements.json +79 -0
- package/plugins/solution-architect/skills/proposal/references/review.md +11 -0
- package/plugins/solution-architect/skills/proposal/references/workflow.md +88 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/docx-body.mjs +42 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/docx-package.mjs +56 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/docx-xml.mjs +44 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/workflow-checks.mjs +71 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/workflow-cli.mjs +46 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/workflow-html.mjs +39 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/workflow-lead.mjs +45 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/workflow-page.mjs +30 -0
- package/plugins/solution-architect/skills/proposal/scripts/lib/workflow-view.mjs +80 -0
- package/plugins/solution-architect/skills/proposal/scripts/render.mjs +5 -1
- package/plugins/solution-architect/skills/proposal/scripts/test/docx.test.mjs +68 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/e2e.test.mjs +2 -2
- package/plugins/solution-architect/skills/proposal/scripts/test/evals-fixtures.test.mjs +9 -2
- package/plugins/solution-architect/skills/proposal/scripts/test/fixtures/proposal-inputs-pass.json +17 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/render.test.mjs +2 -2
- package/plugins/solution-architect/skills/proposal/scripts/test/validate.test.mjs +2 -2
- package/plugins/solution-architect/skills/proposal/scripts/test/workflow-browser.test.mjs +96 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/workflow-checks.test.mjs +98 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/workflow-docs.test.mjs +25 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/workflow-render.test.mjs +75 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/workflow-stage.mjs +15 -0
- package/plugins/solution-architect/skills/proposal/scripts/test/workflow-view.test.mjs +78 -0
- package/plugins/solution-architect/skills/proposal/scripts/validate.mjs +4 -1
- package/plugins/solution-architect/workflows/review-links.js +61 -0
- package/plugins/solution-architect/skills/estimate/assets/estimate-template.html +0 -1677
- /package/plugins/solution-architect/skills/estimate/{assets → classic/assets}/estimate-template-agentic.html +0 -0
- /package/plugins/solution-architect/skills/estimate/{assets → classic/assets}/scores-review-template.html +0 -0
- /package/plugins/solution-architect/skills/estimate/{references → classic/references}/agentic-estimation.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{references → classic/references}/ai-multipliers.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{references → classic/references}/interview.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{references → classic/references}/scoring-guide.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{references → classic/references}/slicing.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{references → classic/references}/techniques.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/agentic-checks.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/components.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/md-tables.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/redact.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/lib/scoring-checks.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/agentic-estimation-fail.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/agentic-estimation-pass.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/agentic-inputs.json +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/booking-inputs.json +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/estimation-fail.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/estimation-pass.md +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/fixtures/measurements.jsonl +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/test/zip.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → classic/scripts}/validate.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/baselines.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/estimate-math.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/measurements.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/pricing.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/project-price.mjs +0 -0
- /package/plugins/solution-architect/skills/estimate/{scripts → shared}/lib/score-diff.mjs +0 -0
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
---
|
|
2
|
+
lead: sin-kowa-mini
|
|
3
|
+
status: ANALYZED
|
|
4
|
+
depth: STANDARD
|
|
5
|
+
scopeMode: workflow
|
|
6
|
+
updated: 2026-10-06
|
|
7
|
+
readiness: 63
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Requirements — Sin Kowa (mini)
|
|
11
|
+
|
|
12
|
+
Source: PO brief, trimmed to two systems for tests.
|
|
13
|
+
|
|
14
|
+
## Part 1 — Discovery Brief
|
|
15
|
+
|
|
16
|
+
Problem: clients dispute charges after the ship sails and there is no record of what was packed.
|
|
17
|
+
|
|
18
|
+
| ID | Goal | Metric |
|
|
19
|
+
| --- | --- | --- |
|
|
20
|
+
| G-001 | Stop billing disputes after sailing | disputes per month down 50% in 6 months |
|
|
21
|
+
|
|
22
|
+
Constraints: CON-001 — vessels are offline at sea; delivery orders are signed on paper today.
|
|
23
|
+
|
|
24
|
+
## Part 2 — Process & Domain
|
|
25
|
+
|
|
26
|
+
As-is workflow WF-001 (order to invoice today): office staff (ACT-002) key the order in →
|
|
27
|
+
the packer (ACT-001) packs from a paper list → paper delivery order signed at the dock →
|
|
28
|
+
invoice raised when the paper returns.
|
|
29
|
+
|
|
30
|
+
| ID | Rule | Examples |
|
|
31
|
+
| --- | --- | --- |
|
|
32
|
+
| BR-001 | Invoice quantity equals packed-and-audited quantity | ordered 10, packed 8 → invoice 8 |
|
|
33
|
+
|
|
34
|
+
<!-- scope:start -->
|
|
35
|
+
|
|
36
|
+
### To-be scope
|
|
37
|
+
|
|
38
|
+
What we propose to build: 2 systems, each shown as its workflows and then the features that serve them.
|
|
39
|
+
|
|
40
|
+
| ID | System | Purpose | IMDA roadmap pillar |
|
|
41
|
+
| --- | --- | --- | --- |
|
|
42
|
+
| SYS-001 | Warehouse operations | Moves an order from intake to the dock; the one screen a warehouse worker needs. | Warehouse Automation |
|
|
43
|
+
| SYS-002 | Orders & invoicing | Quotation through to a paid invoice. | Finance/Documentation |
|
|
44
|
+
|
|
45
|
+
### SYS-001 Warehouse operations
|
|
46
|
+
|
|
47
|
+
Moves an order from intake to the dock; the one screen a warehouse worker needs. Replaces today's "Order to invoice today".
|
|
48
|
+
|
|
49
|
+
**Main workflow: WF-002 Order pipeline**
|
|
50
|
+
|
|
51
|
+
```mermaid
|
|
52
|
+
flowchart LR
|
|
53
|
+
n0 --> n1
|
|
54
|
+
n1 --> n2
|
|
55
|
+
n2 --> n3
|
|
56
|
+
n1 -.->|can't fulfil| n4
|
|
57
|
+
n2 -.->|mismatch| n1
|
|
58
|
+
n0["Order In"]
|
|
59
|
+
n1["Pack"]
|
|
60
|
+
n2["Pack Review"]
|
|
61
|
+
n3["Shipped"]
|
|
62
|
+
n4["Short-pack alert"]
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
| ID | Feature | What it does | Where in the workflow | Requirements |
|
|
66
|
+
| --- | --- | --- | --- | --- |
|
|
67
|
+
| FEAT-001 | Order pipeline & stage engine | Moves an order through each stage, with task views per role | Order In → Pack → Pack Review → Shipped | FR-001 |
|
|
68
|
+
| FEAT-002 | Short-pack alert | Flags an item that cannot be packed, in time to buy or cancel | Short-pack alert | FR-002 |
|
|
69
|
+
|
|
70
|
+
### SYS-002 Orders & invoicing
|
|
71
|
+
|
|
72
|
+
Quotation through to a paid invoice. Replaces today's "Order to invoice today".
|
|
73
|
+
|
|
74
|
+
**Main workflow: WF-003 Order to cash**
|
|
75
|
+
|
|
76
|
+
```mermaid
|
|
77
|
+
flowchart LR
|
|
78
|
+
n0 --> n1
|
|
79
|
+
n1 --> n2
|
|
80
|
+
n2 --> n3
|
|
81
|
+
n0["Order received"]
|
|
82
|
+
n1["Quote"]
|
|
83
|
+
n2["Invoice"]
|
|
84
|
+
n3["Paid"]
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
**Sub-workflow: WF-004 Custom order** — starts at Order received, rejoins Order pipeline · about 20% of orders
|
|
88
|
+
|
|
89
|
+
```mermaid
|
|
90
|
+
flowchart LR
|
|
91
|
+
n0 --> n1
|
|
92
|
+
n1 --> n2
|
|
93
|
+
n0["Flag as custom"]
|
|
94
|
+
n1["Vendor PO"]
|
|
95
|
+
n2["Receive into stock"]
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
| ID | Feature | What it does | Where in the workflow | Requirements |
|
|
99
|
+
| --- | --- | --- | --- | --- |
|
|
100
|
+
| FEAT-003 | Order intake & quotation | Captures email and phone orders and prices them | Order received → Quote; Flag as custom | FR-003 |
|
|
101
|
+
| FEAT-004 | Invoice from packed quantities | Raises the invoice from what was packed and shipped | Shipped (in Order pipeline); Invoice → Paid | FR-004 |
|
|
102
|
+
| FEAT-005 | One login, role-based screens | One login; packers see packing tasks, office staff see orders and invoices | every step | FR-005 |
|
|
103
|
+
|
|
104
|
+
<!-- scope:end -->
|
|
105
|
+
|
|
106
|
+
## Part 3 — Requirements
|
|
107
|
+
|
|
108
|
+
Scope — out: last-mile delivery tracking. Future: pallet labels.
|
|
109
|
+
|
|
110
|
+
| ID | Requirement | Label | Scope | Feature |
|
|
111
|
+
| --- | --- | --- | --- | --- |
|
|
112
|
+
| FR-001 | Move each order through Order In, Pack, Pack Review, Shipped | confirmed | in | Order pipeline & stage engine |
|
|
113
|
+
| FR-002 | Packer flags an item that cannot be packed; office alerted | confirmed | in | Short-pack alert |
|
|
114
|
+
| FR-003 | Enter an email or phone order and produce a quotation | confirmed | in | Order intake & quotation |
|
|
115
|
+
| FR-004 | Raise the invoice from packed-and-audited quantities | assumed | in | Invoice from packed quantities |
|
|
116
|
+
| FR-005 | One login; packers limited to packing tasks | confirmed | in | One login, role-based screens |
|
|
117
|
+
| FR-006 | Print a pallet label at Pack | assumed | future | — |
|
|
118
|
+
|
|
119
|
+
NFR-001 (availability, assumed): offline scans synced within 5 minutes of reconnecting.
|
|
120
|
+
INT-001: write invoices to the InvoiceNow network (recommended).
|
|
121
|
+
DAT-001: Order — commercial, about 300 per month (assumed).
|
|
122
|
+
|
|
123
|
+
## Part 4 — Acceptance Scenarios
|
|
124
|
+
|
|
125
|
+
| ID | Given | When | Then |
|
|
126
|
+
| --- | --- | --- | --- |
|
|
127
|
+
| SC-001 | an order of 10 items with 8 packed | the invoice is raised | it bills 8 items |
|
|
128
|
+
|
|
129
|
+
## Part 5 — Readiness Report
|
|
130
|
+
|
|
131
|
+
Readiness: 63%. Areas — businessContext 80, workflows 70, rules 60,
|
|
132
|
+
integrations 50, data 60, nfrs 60.
|
|
133
|
+
|
|
134
|
+
Open questions: Q-001 (P2) — invoice at shipping or at the signed delivery order?
|
|
135
|
+
Assumptions: ASM-001 (medium impact, unconfirmed) — packers carry a camera phone.
|
|
136
|
+
Blockers: none. Conflicts: none.
|
package/plugins/business-analyst/skills/business-analyst/scripts/test/python-parity.test.mjs
CHANGED
|
@@ -5,6 +5,7 @@ import { mkdtempSync, readFileSync, writeFileSync } from 'node:fs';
|
|
|
5
5
|
import { tmpdir } from 'node:os';
|
|
6
6
|
import { join } from 'node:path';
|
|
7
7
|
import { fileURLToPath } from 'node:url';
|
|
8
|
+
import { CASES, loadWorkflow, noFlows } from './scope-cases.mjs';
|
|
8
9
|
|
|
9
10
|
const py = fileURLToPath(new URL('../validate.py', import.meta.url));
|
|
10
11
|
const js = fileURLToPath(new URL('../validate.mjs', import.meta.url));
|
|
@@ -48,3 +49,90 @@ test('python and node agree on a mutated package (status + blocker + md sync)',
|
|
|
48
49
|
assert.equal(p.code, 1);
|
|
49
50
|
assert.equal(p.err.trim(), n.err.trim());
|
|
50
51
|
});
|
|
52
|
+
|
|
53
|
+
const pyScope = fileURLToPath(new URL('../scope.py', import.meta.url));
|
|
54
|
+
const jsScope = fileURLToPath(new URL('../scope.mjs', import.meta.url));
|
|
55
|
+
|
|
56
|
+
function writePair(pkg, md) {
|
|
57
|
+
const dir = mkdtempSync(join(tmpdir(), 'ba-parity-'));
|
|
58
|
+
const jsonPath = join(dir, 'requirements.json');
|
|
59
|
+
const mdPath = join(dir, 'requirements.md');
|
|
60
|
+
writeFileSync(jsonPath, JSON.stringify(pkg));
|
|
61
|
+
writeFileSync(mdPath, md);
|
|
62
|
+
return { jsonPath, mdPath };
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
test('python validator accepts the workflow pass pair like node', () => {
|
|
66
|
+
const p = run('python3', py, fx('requirements-workflow-pass.json'), fx('requirements-workflow-pass.md'));
|
|
67
|
+
assert.equal(p.code, 0);
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
for (const c of CASES) {
|
|
71
|
+
test(`python and node agree on scope rule: ${c.name}`, () => {
|
|
72
|
+
const { pkg, md } = c.edit(loadWorkflow());
|
|
73
|
+
const { jsonPath, mdPath } = writePair(pkg, md);
|
|
74
|
+
const n = run('node', js, jsonPath, mdPath);
|
|
75
|
+
const p = run('python3', py, jsonPath, mdPath);
|
|
76
|
+
assert.equal(n.code, 1);
|
|
77
|
+
assert.equal(p.code, 1);
|
|
78
|
+
assert.equal(p.err.trim(), n.err.trim());
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
test('scope.py writes the same bytes as scope.mjs', () => {
|
|
83
|
+
const { pkg, md } = loadWorkflow();
|
|
84
|
+
const bare = md.replace(/<!-- scope:start -->[\s\S]*?<!-- scope:end -->\n*/, '');
|
|
85
|
+
const a = writePair(pkg, bare);
|
|
86
|
+
const b = writePair(pkg, bare);
|
|
87
|
+
assert.equal(run('node', jsScope, a.jsonPath, a.mdPath).code, 0);
|
|
88
|
+
assert.equal(run('python3', pyScope, b.jsonPath, b.mdPath).code, 0);
|
|
89
|
+
assert.equal(readFileSync(b.mdPath, 'utf8'), readFileSync(a.mdPath, 'utf8'));
|
|
90
|
+
assert.equal(readFileSync(a.mdPath, 'utf8'), md);
|
|
91
|
+
});
|
|
92
|
+
|
|
93
|
+
test('scope.py and scope.mjs agree on escaped pipes and a colon step', () => {
|
|
94
|
+
const { pkg, md } = loadWorkflow();
|
|
95
|
+
pkg.features[0].does = 'Moves an order | shows each stage';
|
|
96
|
+
pkg.workflows[1].steps[1] = 'Pack: scan';
|
|
97
|
+
pkg.workflows[1].branches = [{ from: 'Pack: scan', to: 'Short-pack alert' }];
|
|
98
|
+
pkg.features[0].steps[1] = 'WF-002:Pack: scan';
|
|
99
|
+
const a = writePair(pkg, md);
|
|
100
|
+
const b = writePair(pkg, md);
|
|
101
|
+
assert.equal(run('node', jsScope, a.jsonPath, a.mdPath).code, 0);
|
|
102
|
+
assert.equal(run('python3', pyScope, b.jsonPath, b.mdPath).code, 0);
|
|
103
|
+
assert.equal(readFileSync(b.mdPath, 'utf8'), readFileSync(a.mdPath, 'utf8'));
|
|
104
|
+
});
|
|
105
|
+
|
|
106
|
+
function exec(cmd, args) {
|
|
107
|
+
try {
|
|
108
|
+
return { code: 0, out: execFileSync(cmd, args, { encoding: 'utf8' }), err: '' };
|
|
109
|
+
} catch (e) {
|
|
110
|
+
return { code: e.status, out: e.stdout ?? '', err: e.stderr ?? '' };
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
test('validate.py --json without --md matches node', () => {
|
|
115
|
+
const { jsonPath } = writePair(loadWorkflow().pkg, '');
|
|
116
|
+
assert.deepEqual(exec('python3', [py, '--json', jsonPath]), exec('node', [js, '--json', jsonPath]));
|
|
117
|
+
});
|
|
118
|
+
|
|
119
|
+
test('scope.py and validate.py agree with node on a system with no workflow', () => {
|
|
120
|
+
const { pkg, md } = noFlows();
|
|
121
|
+
const bare = md.replace(/<!-- scope:start -->[\s\S]*?<!-- scope:end -->\n*/, '');
|
|
122
|
+
const a = writePair(pkg, bare);
|
|
123
|
+
const b = writePair(pkg, bare);
|
|
124
|
+
assert.equal(run('node', jsScope, a.jsonPath, a.mdPath).code, 0);
|
|
125
|
+
assert.equal(run('python3', pyScope, b.jsonPath, b.mdPath).code, 0);
|
|
126
|
+
assert.equal(readFileSync(b.mdPath, 'utf8'), readFileSync(a.mdPath, 'utf8'));
|
|
127
|
+
assert.deepEqual(exec('python3', [py, '--json', a.jsonPath]), exec('node', [js, '--json', a.jsonPath]));
|
|
128
|
+
});
|
|
129
|
+
|
|
130
|
+
test('scope.py and scope.mjs agree on a system with no workflows key', () => {
|
|
131
|
+
const { pkg, md } = noFlows();
|
|
132
|
+
delete pkg.systems[1].workflows;
|
|
133
|
+
const a = writePair(pkg, md);
|
|
134
|
+
const b = writePair(pkg, md);
|
|
135
|
+
assert.equal(run('node', jsScope, a.jsonPath, a.mdPath).code, 0);
|
|
136
|
+
assert.equal(run('python3', pyScope, b.jsonPath, b.mdPath).code, 0);
|
|
137
|
+
assert.equal(readFileSync(b.mdPath, 'utf8'), readFileSync(a.mdPath, 'utf8'));
|
|
138
|
+
});
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { test } from 'node:test';
|
|
2
|
+
import assert from 'node:assert/strict';
|
|
3
|
+
import { readFileSync } from 'node:fs';
|
|
4
|
+
import {
|
|
5
|
+
TEMPLATE_LIMITS, templateScripts, violations,
|
|
6
|
+
} from '../../../../../solution-architect/skills/analyze-requirements/scripts/lib/quality-gate.mjs';
|
|
7
|
+
|
|
8
|
+
// The review page's modules. checks.mjs predates the gates and is over them;
|
|
9
|
+
// it is not listed, and this work only shrinks it.
|
|
10
|
+
const MODULES = [
|
|
11
|
+
'scripts/review.mjs', 'scripts/lib/review-data.mjs',
|
|
12
|
+
'scripts/lib/review-page.mjs', 'scripts/lib/review-layout.mjs', 'scripts/lib/scope-render.mjs',
|
|
13
|
+
];
|
|
14
|
+
const base = new URL('../..', import.meta.url).pathname;
|
|
15
|
+
|
|
16
|
+
for (const file of MODULES) {
|
|
17
|
+
test(`gates: ${file}`, () => {
|
|
18
|
+
assert.deepEqual(violations(readFileSync(base + file, 'utf8')), []);
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
for (const { file, js } of templateScripts(base)) {
|
|
23
|
+
test(`gates: ${file.replace(base, '')}`, () => {
|
|
24
|
+
assert.deepEqual(violations(js, TEMPLATE_LIMITS), []);
|
|
25
|
+
});
|
|
26
|
+
}
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { test } from 'node:test';
|
|
2
|
+
import assert from 'node:assert/strict';
|
|
3
|
+
import { mkdtempSync, writeFileSync } from 'node:fs';
|
|
4
|
+
import { tmpdir } from 'node:os';
|
|
5
|
+
import { join } from 'node:path';
|
|
6
|
+
import { pathToFileURL } from 'node:url';
|
|
7
|
+
import { findChrome } from '../../../../../solution-architect/skills/analyze-requirements/scripts/lib/chrome.mjs';
|
|
8
|
+
import { openPage } from '../../../../../solution-architect/skills/analyze-requirements/scripts/lib/cdp.mjs';
|
|
9
|
+
import { pageHtml } from '../lib/review-page.mjs';
|
|
10
|
+
import { DATE, decided } from './review-fixture.mjs';
|
|
11
|
+
|
|
12
|
+
const skip = { skip: !findChrome() && 'no chrome on PATH' };
|
|
13
|
+
|
|
14
|
+
function open(pkg) {
|
|
15
|
+
const file = join(mkdtempSync(join(tmpdir(), 'ba-review-browser-')), 'review.html');
|
|
16
|
+
writeFileSync(file, pageHtml(pkg, DATE));
|
|
17
|
+
return openPage(pathToFileURL(file).href);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
test('the page draws with no script, no controls and no ids', skip, async () => {
|
|
21
|
+
const page = await open(decided());
|
|
22
|
+
try {
|
|
23
|
+
assert.deepEqual(page.errors, []);
|
|
24
|
+
assert.equal(await page.eval(`document.querySelectorAll('script, button, input, textarea, select').length`), 0);
|
|
25
|
+
assert.equal(await page.eval(`/\\b(?:SYS|WF|FEAT|FR|BR|Q|ASM)-\\d{3}\\b/.test(document.body.innerText)`), false);
|
|
26
|
+
assert.equal(await page.eval(`document.querySelectorAll('tr.new, li.new').length`), 2);
|
|
27
|
+
assert.equal(await page.eval(`document.querySelectorAll('.flow').length`), 3);
|
|
28
|
+
} finally { page.close(); }
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
test('markup in a name shows as text, never as html', skip, async () => {
|
|
32
|
+
const pkg = decided();
|
|
33
|
+
pkg.features[0].name = 'Order <b>pipeline</b> & "stage"';
|
|
34
|
+
const page = await open(pkg);
|
|
35
|
+
try {
|
|
36
|
+
assert.equal(await page.eval(`document.querySelector('td').textContent`), 'Order <b>pipeline</b> & "stage"');
|
|
37
|
+
assert.equal(await page.eval(`document.querySelectorAll('td b').length`), 0);
|
|
38
|
+
} finally { page.close(); }
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
test('a side branch sits under the step it leaves', skip, async () => {
|
|
42
|
+
const page = await open(decided());
|
|
43
|
+
const mid = (t) => `(() => { const e = [...document.querySelectorAll('.step')].find((x) => x.textContent === ${JSON.stringify(t)}); const r = e.getBoundingClientRect(); return r.left + r.width / 2; })()`;
|
|
44
|
+
try {
|
|
45
|
+
assert.ok(Math.abs(await page.eval(mid('Short-pack alert')) - await page.eval(mid('Pack'))) <= 1);
|
|
46
|
+
assert.ok(Math.abs(await page.eval(mid('↺ back to Pack')) - await page.eval(mid('Pack Review'))) <= 1);
|
|
47
|
+
} finally { page.close(); }
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
test('a step box fills its column, so arrows stay next to it', skip, async () => {
|
|
51
|
+
const page = await open(decided());
|
|
52
|
+
const box = (t) => `[...document.querySelectorAll('.step')].find((x) => x.textContent === ${JSON.stringify(t)}).getBoundingClientRect()`;
|
|
53
|
+
const arrow = `document.querySelector('.arrow').getBoundingClientRect()`;
|
|
54
|
+
try {
|
|
55
|
+
assert.ok(Math.abs(await page.eval(`${box('Order In')}.right - ${arrow}.left`)) <= 1);
|
|
56
|
+
assert.ok(Math.abs(await page.eval(`${arrow}.right - ${box('Pack')}.left`)) <= 1);
|
|
57
|
+
} finally { page.close(); }
|
|
58
|
+
});
|
|
59
|
+
|
|
60
|
+
test('main-row arrows and branch connectors are drawn the same way', skip, async () => {
|
|
61
|
+
const page = await open(decided());
|
|
62
|
+
const css = (sel, pseudo, prop) => `getComputedStyle(document.querySelector(${JSON.stringify(sel)}), ${JSON.stringify(pseudo)}).${prop}`;
|
|
63
|
+
try {
|
|
64
|
+
const px = (sel, pseudo, prop) => page.eval(css(sel, pseudo, prop));
|
|
65
|
+
assert.equal(await px('.arrow', '::before', 'height'), '1px');
|
|
66
|
+
assert.equal(await px('.down', '::before', 'width'), '1px');
|
|
67
|
+
const dotted = await px('.down', '::before', 'backgroundImage');
|
|
68
|
+
assert.ok(dotted.includes(await px('.arrow', '::before', 'backgroundColor')));
|
|
69
|
+
assert.ok(dotted.includes('repeating-linear-gradient'));
|
|
70
|
+
assert.equal(await px('.arrow', '::after', 'borderLeftColor'), await px('.down', '::after', 'borderTopColor'));
|
|
71
|
+
assert.equal(await px('.arrow', '::after', 'borderLeftWidth'), '7px');
|
|
72
|
+
assert.equal(await px('.down', '::after', 'borderTopWidth'), '7px');
|
|
73
|
+
assert.equal(await page.eval(`document.querySelector('.arrow').getBoundingClientRect().height < 20`), true);
|
|
74
|
+
} finally { page.close(); }
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
test('two branches from one step sit side by side under it; labels stay in their column', skip, async () => {
|
|
78
|
+
const pkg = decided();
|
|
79
|
+
const flow = pkg.workflows.find((w) => w.name === 'Order pipeline');
|
|
80
|
+
flow.branches[0].label = 'cannot fulfil the whole order from stock';
|
|
81
|
+
flow.branches.push({ from: 'Pack', to: 'Extra box', label: 'customer asked for one more box' });
|
|
82
|
+
const page = await open(pkg);
|
|
83
|
+
const rect = (sel, t) => `(() => { const r = [...document.querySelectorAll(${JSON.stringify(sel)})].find((x) => x.textContent === ${JSON.stringify(t)}).getBoundingClientRect(); return { l: r.left, r: r.right, t: r.top, b: r.bottom }; })()`;
|
|
84
|
+
const hit = (a, b) => a.l < b.r && b.l < a.r && a.t < b.b && b.t < a.b;
|
|
85
|
+
try {
|
|
86
|
+
const [pack, one, two] = [await page.eval(rect('.step', 'Pack')), await page.eval(rect('.step', 'Short-pack alert')), await page.eval(rect('.step', 'Extra box'))];
|
|
87
|
+
const [l1, l2] = [await page.eval(rect('.lbl', flow.branches[0].label)), await page.eval(rect('.lbl', 'customer asked for one more box'))];
|
|
88
|
+
assert.ok(Math.abs(one.t - two.t) <= 1, 'siblings share a row');
|
|
89
|
+
assert.ok(!hit(one, two) && !hit(l1, l2) && !hit(l1, two) && !hit(l2, one));
|
|
90
|
+
for (const s of [one, two]) assert.ok((s.l + s.r) / 2 >= pack.l && (s.l + s.r) / 2 <= pack.r);
|
|
91
|
+
} finally { page.close(); }
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
test('a main step fills a column widened by a long branch box, so no arrow has a gap', skip, async () => {
|
|
95
|
+
const pkg = decided();
|
|
96
|
+
const flow = pkg.workflows.find((w) => w.name === 'Order pipeline');
|
|
97
|
+
flow.branches.push({ from: 'Order In', to: 'Escalate to the duty manager for a manual decision', label: 'unclear' });
|
|
98
|
+
const page = await open(pkg);
|
|
99
|
+
const gaps = `(() => { const g = document.querySelector('.grid'); const out = [];
|
|
100
|
+
for (const a of g.querySelectorAll('.arrow')) { const p = a.previousElementSibling.getBoundingClientRect(); const n = a.nextElementSibling.getBoundingClientRect(); const r = a.getBoundingClientRect(); out.push(Math.max(Math.abs(p.right - r.left), Math.abs(r.right - n.left))); }
|
|
101
|
+
return out; })()`;
|
|
102
|
+
try {
|
|
103
|
+
const found = await page.eval(gaps);
|
|
104
|
+
assert.ok(found.length > 0 && found.every((d) => d <= 1), `gaps: ${found}`);
|
|
105
|
+
} finally { page.close(); }
|
|
106
|
+
});
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
// Review-state fixtures built from the workflow pass pair, so no reviewed
|
|
2
|
+
// JSON is committed that could drift from the pass fixture.
|
|
3
|
+
import { loadWorkflow } from './scope-cases.mjs';
|
|
4
|
+
|
|
5
|
+
export const DATE = '2026-10-07';
|
|
6
|
+
|
|
7
|
+
// The pass package once the interview settled it: one feature and one
|
|
8
|
+
// assumption added by the PO.
|
|
9
|
+
export function decided() {
|
|
10
|
+
const { pkg } = loadWorkflow();
|
|
11
|
+
Object.assign(pkg.features[3], { label: 'confirmed', source: `PO in interview, ${DATE}` });
|
|
12
|
+
pkg.assumptions.push({
|
|
13
|
+
id: 'ASM-002', text: 'Offline scan gaps last under 1 hour; longer outages are a change request.',
|
|
14
|
+
impact: 'low', status: 'accepted', source: `PO in interview, ${DATE}`,
|
|
15
|
+
});
|
|
16
|
+
return pkg;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
// A 0.3.x package being re-run: the BA drafted "Order to cash" and the
|
|
20
|
+
// invoice feature, each paired with an open question. Valid, not decided.
|
|
21
|
+
export function drafted() {
|
|
22
|
+
const { pkg } = loadWorkflow();
|
|
23
|
+
const was = { label: 'recommended', source: 'drafted from PO brief, System 2' };
|
|
24
|
+
Object.assign(pkg.workflows[2], was);
|
|
25
|
+
Object.assign(pkg.features[3], was);
|
|
26
|
+
pkg.openQuestions.push({
|
|
27
|
+
id: 'Q-002', question: 'Is order to cash the right shape: quote before the order is confirmed?',
|
|
28
|
+
priority: 'P1', reason: 'the workflow was drafted, not described by the client',
|
|
29
|
+
affects: ['WF-003'], status: 'open', answer: null, architectureBlocker: false,
|
|
30
|
+
});
|
|
31
|
+
return pkg;
|
|
32
|
+
}
|