@interf/compiler 0.21.0 → 0.22.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/README.md +65 -63
- package/dist/cli/commands/build-plan.d.ts +2 -0
- package/dist/cli/commands/{method.js → build-plan.js} +89 -72
- package/dist/cli/commands/{compile.d.ts → build.d.ts} +2 -2
- package/dist/cli/commands/{compile.js → build.js} +18 -18
- package/dist/cli/commands/doctor.js +2 -2
- package/dist/cli/commands/mcp.js +48 -48
- package/dist/cli/commands/prep.js +16 -29
- package/dist/cli/commands/reset.d.ts +1 -1
- package/dist/cli/commands/reset.js +6 -6
- package/dist/cli/commands/runs.js +6 -28
- package/dist/cli/commands/status.js +1 -1
- package/dist/cli/commands/test.d.ts +1 -1
- package/dist/cli/commands/test.js +8 -8
- package/dist/cli/commands/web.js +3 -3
- package/dist/cli/commands/wizard.js +38 -38
- package/dist/cli/index.d.ts +3 -3
- package/dist/cli/index.js +5 -5
- package/dist/interf-ui/404.html +1 -0
- package/dist/interf-ui/__next.__PAGE__.txt +10 -0
- package/dist/interf-ui/__next._full.txt +20 -0
- package/dist/interf-ui/__next._head.txt +5 -0
- package/dist/interf-ui/__next._index.txt +5 -0
- package/dist/{compiler-ui → interf-ui}/__next._tree.txt +3 -4
- package/dist/interf-ui/_next/static/chunks/0.tjb6f4golw..css +3 -0
- package/dist/interf-ui/_next/static/chunks/085-n_jv2ng_q.css +1 -0
- package/dist/interf-ui/_next/static/chunks/0dn41fa_zvgsl.js +1 -0
- package/dist/interf-ui/_next/static/chunks/0g-ea0zj5d-0k.js +1 -0
- package/dist/interf-ui/_next/static/chunks/0gwqglc4iz583.js +1 -0
- package/dist/interf-ui/_next/static/chunks/0haldgm65ve6l.js +1 -0
- package/dist/interf-ui/_next/static/chunks/0nv3am99vjzn4.js +1 -0
- package/dist/{compiler-ui/_next/static/chunks/02f_.8.ebn556.js → interf-ui/_next/static/chunks/0s77gt_o4jwtx.js} +1 -1
- package/dist/interf-ui/_next/static/chunks/0~a36ujuzpaz..js +116 -0
- package/dist/interf-ui/_next/static/chunks/10jeodxe4nkgj.js +31 -0
- package/dist/interf-ui/_next/static/chunks/119h2rouych2t.js +1 -0
- package/dist/interf-ui/_next/static/chunks/13c8b~m8knjsf.js +1 -0
- package/dist/interf-ui/_next/static/chunks/14dznb2qpt-ho.js +91 -0
- package/dist/interf-ui/_next/static/chunks/15z_en80lrq-3.js +5 -0
- package/dist/{compiler-ui/_next/static/chunks/turbopack-0apv8vb-nczuy.js → interf-ui/_next/static/chunks/turbopack-0p.pvcjrtq-jh.js} +1 -1
- package/dist/interf-ui/_next/static/chunks/turbopack-0usj_75.8frlw.js +1 -0
- package/dist/interf-ui/_not-found/__next._full.txt +15 -0
- package/dist/interf-ui/_not-found/__next._head.txt +5 -0
- package/dist/interf-ui/_not-found/__next._index.txt +5 -0
- package/dist/{compiler-ui → interf-ui}/_not-found/__next._not-found.__PAGE__.txt +2 -2
- package/dist/interf-ui/_not-found/__next._not-found.txt +5 -0
- package/dist/{compiler-ui → interf-ui}/_not-found/__next._tree.txt +2 -3
- package/dist/interf-ui/_not-found.html +1 -0
- package/dist/interf-ui/_not-found.txt +15 -0
- package/dist/interf-ui/index.html +1 -0
- package/dist/interf-ui/index.txt +20 -0
- package/dist/packages/build-plans/authoring/build-plan-authoring.d.ts +36 -0
- package/dist/packages/{methods/authoring/method-authoring.js → build-plans/authoring/build-plan-authoring.js} +52 -52
- package/dist/packages/build-plans/authoring/build-plan-edit-session.d.ts +18 -0
- package/dist/packages/{methods/authoring/method-edit-session.js → build-plans/authoring/build-plan-edit-session.js} +34 -34
- package/dist/packages/build-plans/authoring/build-plan-improvement.d.ts +23 -0
- package/dist/packages/build-plans/authoring/build-plan-improvement.js +216 -0
- package/dist/packages/build-plans/authoring/index.d.ts +4 -0
- package/dist/packages/build-plans/authoring/index.js +4 -0
- package/dist/packages/{methods/authoring/lib/method-edit-utils.d.ts → build-plans/authoring/lib/build-plan-edit-utils.d.ts} +3 -3
- package/dist/packages/build-plans/build-plan-resolution.d.ts +6 -0
- package/dist/packages/build-plans/build-plan-resolution.js +7 -0
- package/dist/packages/build-plans/index.d.ts +2 -0
- package/dist/packages/build-plans/index.js +2 -0
- package/dist/packages/build-plans/package/build-plan-definitions.d.ts +61 -0
- package/dist/packages/build-plans/package/build-plan-definitions.js +214 -0
- package/dist/packages/{methods/package/method-helpers.d.ts → build-plans/package/build-plan-helpers.d.ts} +7 -7
- package/dist/packages/{methods/package/method-helpers.js → build-plans/package/build-plan-helpers.js} +20 -20
- package/dist/packages/build-plans/package/build-plan-review-paths.d.ts +10 -0
- package/dist/packages/build-plans/package/build-plan-review-paths.js +31 -0
- package/dist/packages/{methods/package/method-stage-runner.d.ts → build-plans/package/build-plan-stage-runner.d.ts} +12 -12
- package/dist/packages/{methods/package/method-stage-runner.js → build-plans/package/build-plan-stage-runner.js} +10 -10
- package/dist/packages/build-plans/package/builtin-build-plan.d.ts +37 -0
- package/dist/packages/build-plans/package/builtin-build-plan.js +91 -0
- package/dist/packages/{methods → build-plans}/package/context-interface.d.ts +11 -11
- package/dist/packages/{methods → build-plans}/package/context-interface.js +23 -23
- package/dist/packages/build-plans/package/interf-build-plan-package.d.ts +31 -0
- package/dist/packages/build-plans/package/interf-build-plan-package.js +466 -0
- package/dist/packages/{methods → build-plans}/package/lib/package-root.js +1 -1
- package/dist/packages/build-plans/package/local-build-plans.d.ts +74 -0
- package/dist/packages/{methods/package/local-methods.js → build-plans/package/local-build-plans.js} +152 -152
- package/dist/packages/build-plans/package/user-build-plans.d.ts +17 -0
- package/dist/packages/build-plans/package/user-build-plans.js +77 -0
- package/dist/packages/contracts/index.d.ts +1 -1
- package/dist/packages/contracts/lib/preparation-paths.d.ts +37 -37
- package/dist/packages/contracts/lib/preparation-paths.js +43 -43
- package/dist/packages/contracts/lib/schema.d.ts +34 -41
- package/dist/packages/contracts/lib/schema.js +42 -34
- package/dist/packages/engine/action-definitions.d.ts +60 -60
- package/dist/packages/engine/action-definitions.js +198 -197
- package/dist/packages/engine/action-planner.d.ts +2 -2
- package/dist/packages/engine/action-planner.js +5 -5
- package/dist/packages/engine/action-values.d.ts +1 -1
- package/dist/packages/engine/action-values.js +1 -1
- package/dist/packages/engine/agents/index.d.ts +2 -2
- package/dist/packages/engine/agents/index.js +1 -1
- package/dist/packages/engine/agents/lib/args.d.ts +2 -2
- package/dist/packages/engine/agents/lib/args.js +1 -1
- package/dist/packages/engine/agents/lib/constants.js +1 -1
- package/dist/packages/engine/agents/lib/execution-profile.d.ts +5 -5
- package/dist/packages/engine/agents/lib/execution-profile.js +3 -3
- package/dist/packages/engine/agents/lib/executors.d.ts +11 -11
- package/dist/packages/engine/agents/lib/render.js +4 -4
- package/dist/packages/engine/agents/lib/shells.d.ts +30 -30
- package/dist/packages/engine/agents/lib/shells.js +248 -248
- package/dist/packages/engine/agents/lib/types.d.ts +2 -2
- package/dist/packages/engine/agents/lib/verifiable-context-bootstrap.d.ts +3 -0
- package/dist/packages/engine/agents/lib/verifiable-context-bootstrap.js +19 -0
- package/dist/packages/engine/agents/role-executors.d.ts +7 -7
- package/dist/packages/engine/agents/role-executors.js +2 -2
- package/dist/packages/engine/agents/role-router.d.ts +2 -2
- package/dist/packages/engine/agents/role-router.js +1 -1
- package/dist/packages/engine/build/artifact-counts.d.ts +1 -0
- package/dist/packages/engine/{compile → build}/artifact-counts.js +7 -7
- package/dist/packages/engine/{compile → build}/artifact-status.d.ts +8 -8
- package/dist/packages/engine/{compile → build}/artifact-status.js +19 -19
- package/dist/packages/engine/{compile → build}/billing-events.d.ts +4 -4
- package/dist/packages/engine/{compile → build}/billing-events.js +4 -4
- package/dist/packages/engine/build/build-execution.d.ts +4 -0
- package/dist/packages/engine/build/build-execution.js +4 -0
- package/dist/packages/engine/build/build-pipeline.d.ts +56 -0
- package/dist/packages/engine/{compile/compiled-pipeline.js → build/build-pipeline.js} +55 -55
- package/dist/packages/engine/build/build-plan-primitives.d.ts +2 -0
- package/dist/packages/engine/{compile/method-primitives.js → build/build-plan-primitives.js} +1 -1
- package/dist/packages/engine/build/build-plan-runs.d.ts +14 -0
- package/dist/packages/engine/build/build-plan-runs.js +31 -0
- package/dist/packages/engine/build/build-stage-plan.d.ts +16 -0
- package/dist/packages/engine/build/build-stage-plan.js +100 -0
- package/dist/packages/engine/build/build-stage-runner.d.ts +15 -0
- package/dist/packages/engine/{compile/compiled-stage-runner.js → build/build-stage-runner.js} +21 -21
- package/dist/packages/engine/build/build-target.d.ts +11 -0
- package/dist/packages/engine/build/build-target.js +16 -0
- package/dist/packages/engine/{compile → build}/check-evaluator.d.ts +4 -4
- package/dist/packages/engine/{compile → build}/check-evaluator.js +1 -1
- package/dist/packages/engine/{compile → build}/discovery.d.ts +2 -2
- package/dist/packages/engine/{compile → build}/discovery.js +4 -4
- package/dist/packages/engine/{compile → build}/index.d.ts +6 -6
- package/dist/packages/engine/{compile → build}/index.js +5 -5
- package/dist/packages/engine/{compile → build}/lib/schema.d.ts +79 -79
- package/dist/packages/engine/{compile → build}/lib/schema.js +71 -71
- package/dist/packages/engine/build/reset.d.ts +2 -0
- package/dist/packages/engine/build/reset.js +74 -0
- package/dist/packages/engine/{compile → build}/runtime-contracts.js +8 -8
- package/dist/packages/engine/build/runtime-inventory.d.ts +7 -0
- package/dist/packages/engine/{compile → build}/runtime-inventory.js +8 -8
- package/dist/packages/engine/{compile → build}/runtime-paths.js +6 -6
- package/dist/packages/engine/{compile → build}/runtime-prompt.js +11 -11
- package/dist/packages/engine/build/runtime-reconcile.d.ts +2 -0
- package/dist/packages/engine/{compile → build}/runtime-reconcile.js +18 -18
- package/dist/packages/engine/{compile → build}/runtime-runs.js +27 -27
- package/dist/packages/engine/{compile → build}/runtime-types.d.ts +10 -10
- package/dist/packages/engine/build/source-files.d.ts +46 -0
- package/dist/packages/engine/{compile → build}/source-files.js +32 -32
- package/dist/packages/engine/build/state-artifacts.d.ts +9 -0
- package/dist/packages/engine/build/state-artifacts.js +14 -0
- package/dist/packages/engine/build/state-health.d.ts +4 -0
- package/dist/packages/engine/{compile → build}/state-health.js +40 -40
- package/dist/packages/engine/build/state-io.d.ts +11 -0
- package/dist/packages/engine/{compile → build}/state-io.js +22 -22
- package/dist/packages/engine/build/state-paths.js +16 -0
- package/dist/packages/engine/build/state-view.d.ts +5 -0
- package/dist/packages/engine/{compile → build}/state-view.js +29 -29
- package/dist/packages/engine/build/state.d.ts +7 -0
- package/dist/packages/engine/build/state.js +12 -0
- package/dist/packages/engine/build/validate-verifiable-context.d.ts +27 -0
- package/dist/packages/engine/{compile/validate-compiled.js → build/validate-verifiable-context.js} +73 -73
- package/dist/packages/engine/{compile → build}/validate.d.ts +4 -4
- package/dist/packages/engine/{compile → build}/validate.js +27 -27
- package/dist/packages/engine/build/verifiable-context-paths.d.ts +47 -0
- package/dist/packages/engine/build/verifiable-context-paths.js +121 -0
- package/dist/packages/engine/build/verifiable-context-schema.d.ts +21 -0
- package/dist/packages/engine/build/verifiable-context-schema.js +126 -0
- package/dist/packages/engine/client.d.ts +16 -16
- package/dist/packages/engine/client.js +21 -21
- package/dist/packages/engine/cloud-seams.d.ts +3 -3
- package/dist/packages/engine/execution/index.d.ts +2 -2
- package/dist/packages/engine/execution/index.js +1 -1
- package/dist/packages/engine/execution/lib/schema.d.ts +90 -95
- package/dist/packages/engine/execution/lib/schema.js +31 -31
- package/dist/packages/engine/index.d.ts +7 -7
- package/dist/packages/engine/index.js +3 -3
- package/dist/packages/engine/instance-paths.d.ts +39 -39
- package/dist/packages/engine/instance-paths.js +48 -48
- package/dist/packages/engine/lib/schema.d.ts +900 -472
- package/dist/packages/engine/lib/schema.js +137 -153
- package/dist/packages/engine/native-run-handlers.d.ts +12 -12
- package/dist/packages/engine/native-run-handlers.js +135 -135
- package/dist/packages/engine/preparation-store.d.ts +22 -23
- package/dist/packages/engine/preparation-store.js +30 -31
- package/dist/packages/engine/readiness-check-draft.d.ts +2 -2
- package/dist/packages/engine/readiness-check-draft.js +1 -1
- package/dist/packages/engine/requested-artifacts.d.ts +2 -2
- package/dist/packages/engine/routes.d.ts +18 -17
- package/dist/packages/engine/routes.js +20 -19
- package/dist/packages/engine/run-observability.d.ts +5 -3
- package/dist/packages/engine/run-observability.js +101 -89
- package/dist/packages/engine/runtime-caches.d.ts +16 -16
- package/dist/packages/engine/runtime-caches.js +26 -26
- package/dist/packages/engine/runtime-event-applier.d.ts +2 -2
- package/dist/packages/engine/runtime-event-applier.js +1 -1
- package/dist/packages/engine/runtime-persistence.d.ts +9 -9
- package/dist/packages/engine/runtime-persistence.js +16 -16
- package/dist/packages/engine/runtime-proposal-helpers.d.ts +14 -14
- package/dist/packages/engine/runtime-proposal-helpers.js +78 -80
- package/dist/packages/engine/runtime-resource-builders.d.ts +12 -12
- package/dist/packages/engine/runtime-resource-builders.js +19 -19
- package/dist/packages/engine/runtime.d.ts +52 -61
- package/dist/packages/engine/runtime.js +440 -463
- package/dist/packages/engine/server.d.ts +2 -2
- package/dist/packages/engine/server.js +147 -116
- package/dist/packages/engine/service-registry.d.ts +5 -17
- package/dist/packages/engine/service-registry.js +5 -20
- package/dist/packages/engine/verify/lib/schema.d.ts +19 -19
- package/dist/packages/engine/verify/lib/schema.js +36 -8
- package/dist/packages/engine/verify/readiness-check-run.d.ts +15 -16
- package/dist/packages/engine/verify/readiness-check-run.js +46 -46
- package/dist/packages/engine/verify/verify-execution.d.ts +3 -3
- package/dist/packages/engine/verify/verify-execution.js +10 -10
- package/dist/packages/engine/verify/verify-paths.d.ts +4 -4
- package/dist/packages/engine/verify/verify-paths.js +17 -17
- package/dist/packages/engine/verify/verify-sandbox.d.ts +1 -1
- package/dist/packages/engine/verify/verify-sandbox.js +26 -26
- package/dist/packages/engine/verify/verify-targets.d.ts +2 -2
- package/dist/packages/engine/verify/verify-targets.js +17 -17
- package/dist/packages/engine/verify/verify-types.d.ts +2 -2
- package/dist/packages/engine/verify/verify.d.ts +1 -1
- package/dist/packages/engine/verify/verify.js +1 -1
- package/dist/packages/engine/wire-schemas.d.ts +38 -40
- package/dist/packages/engine/wire-schemas.js +13 -13
- package/dist/packages/project/index.d.ts +1 -1
- package/dist/packages/project/interf-bootstrap.d.ts +1 -1
- package/dist/packages/project/interf-bootstrap.js +1 -1
- package/dist/packages/project/interf-detect.d.ts +11 -11
- package/dist/packages/project/interf-detect.js +30 -30
- package/dist/packages/project/interf-scaffold.d.ts +3 -3
- package/dist/packages/project/interf-scaffold.js +72 -72
- package/dist/packages/project/interf.d.ts +4 -4
- package/dist/packages/project/interf.js +3 -3
- package/dist/packages/project/lib/schema.d.ts +12 -12
- package/dist/packages/project/lib/schema.js +14 -14
- package/dist/packages/project/preparation-entries.d.ts +3 -3
- package/dist/packages/project/preparation-entries.js +19 -19
- package/dist/packages/project/source-config.d.ts +10 -10
- package/dist/packages/project/source-config.js +58 -58
- package/package.json +15 -15
- package/public-repo/CONTRIBUTING.md +12 -12
- package/public-repo/README.md +65 -63
- package/public-repo/SECURITY.md +3 -3
- package/public-repo/build-plans/interf-default/README.md +33 -0
- package/public-repo/{methods/interf-default/compile → build-plans/interf-default/build}/stages/shape/SKILL.md +10 -10
- package/public-repo/{methods/interf-default/compile → build-plans/interf-default/build}/stages/structure/SKILL.md +2 -2
- package/public-repo/{methods/interf-default/compile → build-plans/interf-default/build}/stages/summarize/SKILL.md +1 -1
- package/public-repo/{methods/interf-default/method.json → build-plans/interf-default/build-plan.json} +15 -15
- package/public-repo/{methods/interf-default/method.schema.json → build-plans/interf-default/build-plan.schema.json} +4 -4
- package/public-repo/build-plans/interf-default/improve/SKILL.md +18 -0
- package/public-repo/{methods → build-plans}/interf-default/use/query/SKILL.md +6 -6
- package/public-repo/plugins/README.md +1 -1
- package/public-repo/plugins/interf/.claude-plugin/plugin.json +3 -3
- package/public-repo/plugins/interf/README.md +4 -1
- package/public-repo/plugins/interf/skills/interf/SKILL.md +189 -290
- package/public-repo/skills/interf/SKILL.md +189 -290
- package/LICENSE.md +0 -1
- package/TRADEMARKS.md +0 -8
- package/dist/cli/commands/method.d.ts +0 -2
- package/dist/compiler-ui/404.html +0 -1
- package/dist/compiler-ui/__next.__PAGE__.txt +0 -10
- package/dist/compiler-ui/__next._full.txt +0 -21
- package/dist/compiler-ui/__next._head.txt +0 -5
- package/dist/compiler-ui/__next._index.txt +0 -6
- package/dist/compiler-ui/_next/static/chunks/01646j7yi.w5a.css +0 -1
- package/dist/compiler-ui/_next/static/chunks/02r7siaw-_p5w.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/04d0ly-7xb~-j.js +0 -91
- package/dist/compiler-ui/_next/static/chunks/0fhs9psnxqd8s.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/0mssmhpbifj15.css +0 -2
- package/dist/compiler-ui/_next/static/chunks/0nypu~ddwxari.js +0 -116
- package/dist/compiler-ui/_next/static/chunks/0p3s8iyhgcww2.js +0 -31
- package/dist/compiler-ui/_next/static/chunks/0tjf-vu_rz8s0.css +0 -1
- package/dist/compiler-ui/_next/static/chunks/0u6p3fpbbfgtl.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/0wpx5..8dnh0w.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/0y0uj160p0ts~.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/10t8l~_oenf.c.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/13gz9e7z~imx1.js +0 -5
- package/dist/compiler-ui/_next/static/chunks/156xed-b6czaw.js +0 -1
- package/dist/compiler-ui/_next/static/chunks/turbopack-02-3e_c-yz~5g.js +0 -1
- package/dist/compiler-ui/_not-found/__next._full.txt +0 -16
- package/dist/compiler-ui/_not-found/__next._head.txt +0 -5
- package/dist/compiler-ui/_not-found/__next._index.txt +0 -6
- package/dist/compiler-ui/_not-found/__next._not-found.txt +0 -5
- package/dist/compiler-ui/_not-found.html +0 -1
- package/dist/compiler-ui/_not-found.txt +0 -16
- package/dist/compiler-ui/index.html +0 -1
- package/dist/compiler-ui/index.txt +0 -21
- package/dist/packages/engine/agents/lib/compiled-bootstrap.d.ts +0 -3
- package/dist/packages/engine/agents/lib/compiled-bootstrap.js +0 -19
- package/dist/packages/engine/compile/artifact-counts.d.ts +0 -1
- package/dist/packages/engine/compile/compiled-compile.d.ts +0 -4
- package/dist/packages/engine/compile/compiled-compile.js +0 -4
- package/dist/packages/engine/compile/compiled-paths.d.ts +0 -47
- package/dist/packages/engine/compile/compiled-paths.js +0 -121
- package/dist/packages/engine/compile/compiled-pipeline.d.ts +0 -56
- package/dist/packages/engine/compile/compiled-schema.d.ts +0 -21
- package/dist/packages/engine/compile/compiled-schema.js +0 -126
- package/dist/packages/engine/compile/compiled-stage-plan.d.ts +0 -16
- package/dist/packages/engine/compile/compiled-stage-plan.js +0 -100
- package/dist/packages/engine/compile/compiled-stage-runner.d.ts +0 -15
- package/dist/packages/engine/compile/compiled-target.d.ts +0 -11
- package/dist/packages/engine/compile/compiled-target.js +0 -16
- package/dist/packages/engine/compile/method-primitives.d.ts +0 -2
- package/dist/packages/engine/compile/method-runs.d.ts +0 -14
- package/dist/packages/engine/compile/method-runs.js +0 -31
- package/dist/packages/engine/compile/reset.d.ts +0 -2
- package/dist/packages/engine/compile/reset.js +0 -74
- package/dist/packages/engine/compile/runtime-inventory.d.ts +0 -7
- package/dist/packages/engine/compile/runtime-reconcile.d.ts +0 -2
- package/dist/packages/engine/compile/source-files.d.ts +0 -46
- package/dist/packages/engine/compile/state-artifacts.d.ts +0 -9
- package/dist/packages/engine/compile/state-artifacts.js +0 -14
- package/dist/packages/engine/compile/state-health.d.ts +0 -4
- package/dist/packages/engine/compile/state-io.d.ts +0 -11
- package/dist/packages/engine/compile/state-paths.js +0 -16
- package/dist/packages/engine/compile/state-view.d.ts +0 -5
- package/dist/packages/engine/compile/state.d.ts +0 -7
- package/dist/packages/engine/compile/state.js +0 -12
- package/dist/packages/engine/compile/validate-compiled.d.ts +0 -27
- package/dist/packages/methods/authoring/index.d.ts +0 -4
- package/dist/packages/methods/authoring/index.js +0 -4
- package/dist/packages/methods/authoring/method-authoring.d.ts +0 -36
- package/dist/packages/methods/authoring/method-edit-session.d.ts +0 -18
- package/dist/packages/methods/authoring/method-improvement.d.ts +0 -23
- package/dist/packages/methods/authoring/method-improvement.js +0 -217
- package/dist/packages/methods/index.d.ts +0 -2
- package/dist/packages/methods/index.js +0 -2
- package/dist/packages/methods/method-resolution.d.ts +0 -6
- package/dist/packages/methods/method-resolution.js +0 -7
- package/dist/packages/methods/package/builtin-compiled-method.d.ts +0 -37
- package/dist/packages/methods/package/builtin-compiled-method.js +0 -91
- package/dist/packages/methods/package/interf-method-package.d.ts +0 -31
- package/dist/packages/methods/package/interf-method-package.js +0 -466
- package/dist/packages/methods/package/local-methods.d.ts +0 -74
- package/dist/packages/methods/package/method-definitions.d.ts +0 -61
- package/dist/packages/methods/package/method-definitions.js +0 -214
- package/dist/packages/methods/package/method-review-paths.d.ts +0 -10
- package/dist/packages/methods/package/method-review-paths.js +0 -31
- package/dist/packages/methods/package/user-methods.d.ts +0 -17
- package/dist/packages/methods/package/user-methods.js +0 -77
- package/public-repo/methods/interf-default/README.md +0 -33
- package/public-repo/methods/interf-default/improve/SKILL.md +0 -18
- /package/dist/{compiler-ui/_next/static/tYHMLL9oKds1yDoNYgkPV → interf-ui/_next/static/--reS3xBzM5zc6QxNjZd6}/_buildManifest.js +0 -0
- /package/dist/{compiler-ui/_next/static/tYHMLL9oKds1yDoNYgkPV → interf-ui/_next/static/--reS3xBzM5zc6QxNjZd6}/_clientMiddlewareManifest.js +0 -0
- /package/dist/{compiler-ui/_next/static/tYHMLL9oKds1yDoNYgkPV → interf-ui/_next/static/--reS3xBzM5zc6QxNjZd6}/_ssgManifest.js +0 -0
- /package/dist/{compiler-ui → interf-ui}/_next/static/chunks/03~yq9q893hmn.js +0 -0
- /package/dist/{compiler-ui → interf-ui}/_next/static/chunks/0y5z3t-z1c8ks.js.map +0 -0
- /package/dist/{compiler-ui → interf-ui}/_next/static/chunks/turbopack-worker-0sjn--fhq~1cg.js +0 -0
- /package/dist/{compiler-ui → interf-ui}/_next/static/media/GeistMono_Variable.p.17jn9btb_52pq.woff2 +0 -0
- /package/dist/{compiler-ui → interf-ui}/_next/static/media/Geist_Variable-s.p.0-te~ja_gpvcf.woff2 +0 -0
- /package/dist/{compiler-ui → interf-ui}/_next/static/media/worker.102zas1s52_pf.js +0 -0
- /package/dist/packages/{methods/authoring/lib/method-edit-utils.js → build-plans/authoring/lib/build-plan-edit-utils.js} +0 -0
- /package/dist/packages/{methods → build-plans}/package/lib/package-root.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/runtime-contracts.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/runtime-paths.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/runtime-prompt.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/runtime-runs.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/runtime-types.js +0 -0
- /package/dist/packages/engine/{compile → build}/runtime.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/runtime.js +0 -0
- /package/dist/packages/engine/{compile → build}/state-paths.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/validate-helpers.d.ts +0 -0
- /package/dist/packages/engine/{compile → build}/validate-helpers.js +0 -0
|
@@ -14,24 +14,24 @@ export const PreparationSetupActionValuesSchema = z.object({
|
|
|
14
14
|
name: ActionValueIdSchema,
|
|
15
15
|
path: z.string().trim().min(1, "Source Folder is required."),
|
|
16
16
|
about: z.string().trim().min(1, "Agent work is required."),
|
|
17
|
-
|
|
17
|
+
build_plan: OptionalActionValueIdSchema.optional(),
|
|
18
18
|
checks: z.array(SourceReadinessCheckActionValueSchema).optional(),
|
|
19
19
|
requested_artifacts: z.array(RequestedArtifactActionValueSchema).optional(),
|
|
20
20
|
source_profile: SourceProfileActionValueSchema.optional(),
|
|
21
21
|
max_attempts: z.number().int().min(1).max(5).optional(),
|
|
22
22
|
max_loops: z.number().int().min(1).max(3).optional(),
|
|
23
23
|
readiness_notes: z.string().trim().optional(),
|
|
24
|
-
|
|
25
|
-
setup_mode: z.enum(["create", "select-
|
|
24
|
+
build_after_setup: z.boolean().optional(),
|
|
25
|
+
setup_mode: z.enum(["create", "select-build-plan"]).optional(),
|
|
26
26
|
}).strict();
|
|
27
|
-
export const
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
export const BuildPlanAuthoringActionValuesSchema = z.object({
|
|
28
|
+
build_plan_id: ActionValueIdSchema.optional(),
|
|
29
|
+
base_build_plan_id: ActionValueIdSchema.optional(),
|
|
30
|
+
reference_build_plan_id: ActionValueIdSchema.optional(),
|
|
31
31
|
label: z.string().trim().optional(),
|
|
32
32
|
hint: z.string().trim().optional(),
|
|
33
33
|
task_prompt: z.string().trim().min(1, "Agent work is required."),
|
|
34
|
-
|
|
34
|
+
requested_artifacts_description: z.string().trim().optional(),
|
|
35
35
|
requested_artifacts: z.array(RequestedArtifactActionValueSchema).optional(),
|
|
36
36
|
source_profile: SourceProfileActionValueSchema.nullable().optional(),
|
|
37
37
|
readiness_notes: z.string().trim().optional(),
|
|
@@ -43,27 +43,27 @@ export const INTERF_SERVICE_ACTIONS = {
|
|
|
43
43
|
title: "Create Preparation",
|
|
44
44
|
description: "Save a Source, requested Artifacts, Build Plan, and run history under one Preparation.",
|
|
45
45
|
},
|
|
46
|
-
|
|
47
|
-
id: "
|
|
48
|
-
serviceAction: "
|
|
49
|
-
title: "
|
|
50
|
-
description: "Run the saved Build Plan against this Source and write
|
|
46
|
+
buildRun: {
|
|
47
|
+
id: "build-run",
|
|
48
|
+
serviceAction: "build",
|
|
49
|
+
title: "Build Artifacts",
|
|
50
|
+
description: "Run the saved Build Plan against this Source and write verifiable context.",
|
|
51
51
|
},
|
|
52
|
-
|
|
53
|
-
id: "select-
|
|
52
|
+
selectBuildPlan: {
|
|
53
|
+
id: "select-build-plan",
|
|
54
54
|
serviceAction: "preparation-setup",
|
|
55
55
|
title: "Select Build Plan",
|
|
56
|
-
description: "Choose the Build Plan that will
|
|
56
|
+
description: "Choose the Build Plan that will build this Preparation's requested Artifacts.",
|
|
57
57
|
},
|
|
58
|
-
|
|
59
|
-
id: "
|
|
60
|
-
serviceAction: "
|
|
58
|
+
createBuildPlan: {
|
|
59
|
+
id: "build-plan-draft",
|
|
60
|
+
serviceAction: "build-plan-draft",
|
|
61
61
|
title: "Draft Build Plan",
|
|
62
|
-
description: "Draft a Build Plan for the Artifacts this Preparation should
|
|
62
|
+
description: "Draft a Build Plan for the Artifacts this Preparation should build.",
|
|
63
63
|
},
|
|
64
|
-
|
|
65
|
-
id: "
|
|
66
|
-
serviceAction: "
|
|
64
|
+
buildPlanChange: {
|
|
65
|
+
id: "build-plan-change",
|
|
66
|
+
serviceAction: "build-plan-change",
|
|
67
67
|
title: "Build Plan Change",
|
|
68
68
|
description: "Modify, duplicate, or remove an existing Build Plan.",
|
|
69
69
|
},
|
|
@@ -93,7 +93,7 @@ export const INTERF_SERVICE_ACTIONS = {
|
|
|
93
93
|
},
|
|
94
94
|
improvePreparation: {
|
|
95
95
|
id: "improve-preparation",
|
|
96
|
-
serviceAction: "
|
|
96
|
+
serviceAction: "build-plan-improvement",
|
|
97
97
|
title: "Improve Build Plan",
|
|
98
98
|
description: "Use readiness evidence to refine the Build Plan this Preparation uses.",
|
|
99
99
|
},
|
|
@@ -102,14 +102,14 @@ function optionalLine(label, value) {
|
|
|
102
102
|
const trimmed = value?.trim();
|
|
103
103
|
return trimmed ? `${label}: ${trimmed}` : null;
|
|
104
104
|
}
|
|
105
|
-
export function
|
|
105
|
+
export function buildPlanAuthoringTaskPrompt(values) {
|
|
106
106
|
const requestedArtifacts = values.requested_artifacts?.length
|
|
107
107
|
? formatRequestedArtifactsForPrompt(values.requested_artifacts)
|
|
108
108
|
: null;
|
|
109
109
|
return [
|
|
110
110
|
`Agent work: ${values.task_prompt}`,
|
|
111
111
|
requestedArtifacts ? `Requested Artifacts:\n${requestedArtifacts}` : null,
|
|
112
|
-
optionalLine("Requested Artifacts", values.
|
|
112
|
+
optionalLine("Requested Artifacts", values.requested_artifacts_description),
|
|
113
113
|
optionalLine("Readiness checks", values.readiness_notes),
|
|
114
114
|
].filter((line) => Boolean(line)).join("\n");
|
|
115
115
|
}
|
|
@@ -163,27 +163,27 @@ export function maybeActionValue(value) {
|
|
|
163
163
|
function inputValue(values, key) {
|
|
164
164
|
return values[key] ?? "";
|
|
165
165
|
}
|
|
166
|
-
export function
|
|
166
|
+
export function buildPlanChoiceOptions(buildPlans) {
|
|
167
167
|
const seen = new Set();
|
|
168
168
|
const options = [];
|
|
169
|
-
for (const
|
|
170
|
-
if (seen.has(
|
|
169
|
+
for (const buildPlan of [{ id: "interf-default", label: "interf-default" }, ...buildPlans]) {
|
|
170
|
+
if (seen.has(buildPlan.id))
|
|
171
171
|
continue;
|
|
172
|
-
seen.add(
|
|
173
|
-
options.push({ label:
|
|
172
|
+
seen.add(buildPlan.id);
|
|
173
|
+
options.push({ label: buildPlan.label ?? buildPlan.id, value: buildPlan.id });
|
|
174
174
|
}
|
|
175
175
|
return options;
|
|
176
176
|
}
|
|
177
|
-
export function
|
|
178
|
-
const parsed =
|
|
177
|
+
export function buildPlanTaskPromptFromInput(values) {
|
|
178
|
+
const parsed = BuildPlanAuthoringActionValuesSchema.safeParse(values);
|
|
179
179
|
if (parsed.success)
|
|
180
|
-
return
|
|
180
|
+
return buildPlanAuthoringTaskPrompt(parsed.data);
|
|
181
181
|
const taskPrompt = inputValue(values, "task_prompt");
|
|
182
|
-
const
|
|
182
|
+
const requestedArtifactsDescription = inputValue(values, "requested_artifacts_description");
|
|
183
183
|
const readinessNotes = inputValue(values, "readiness_notes");
|
|
184
184
|
return [
|
|
185
185
|
`Agent work: ${taskPrompt}`,
|
|
186
|
-
maybeActionValue(
|
|
186
|
+
maybeActionValue(requestedArtifactsDescription) ? `Requested Artifacts: ${requestedArtifactsDescription}` : null,
|
|
187
187
|
maybeActionValue(readinessNotes) ? `Readiness checks: ${readinessNotes}` : null,
|
|
188
188
|
].filter((line) => Boolean(line)).join("\n");
|
|
189
189
|
}
|
|
@@ -192,7 +192,7 @@ function createPreparationSchema(existingNames) {
|
|
|
192
192
|
name: actionIdField("Preparation name"),
|
|
193
193
|
path: requiredActionText("Source Folder"),
|
|
194
194
|
about: requiredActionText("Agent work"),
|
|
195
|
-
|
|
195
|
+
build_plan: optionalActionIdField("Build Plan"),
|
|
196
196
|
readiness_notes: optionalActionText,
|
|
197
197
|
}).strict().superRefine((values, ctx) => {
|
|
198
198
|
if (existingNames.has(values.name)) {
|
|
@@ -207,43 +207,43 @@ function createPreparationSchema(existingNames) {
|
|
|
207
207
|
function prepareRunSchema() {
|
|
208
208
|
return z.object({
|
|
209
209
|
preparation: actionIdField("Preparation"),
|
|
210
|
-
|
|
210
|
+
build_plan: optionalActionIdField("Build Plan"),
|
|
211
211
|
about: optionalActionText,
|
|
212
212
|
source_folder_path: optionalActionText,
|
|
213
213
|
}).strict();
|
|
214
214
|
}
|
|
215
|
-
function
|
|
215
|
+
function selectBuildPlanSchema() {
|
|
216
216
|
return z.object({
|
|
217
217
|
name: actionIdField("Preparation"),
|
|
218
218
|
path: requiredActionText("Source Folder"),
|
|
219
219
|
about: requiredActionText("Agent work"),
|
|
220
|
-
|
|
221
|
-
|
|
220
|
+
current_build_plan: optionalActionIdField("Current Build Plan"),
|
|
221
|
+
build_plan: actionIdField("Build Plan"),
|
|
222
222
|
}).strict();
|
|
223
223
|
}
|
|
224
|
-
function
|
|
224
|
+
function buildPlanAuthoringSchema(existingBuildPlanIds) {
|
|
225
225
|
return z.object({
|
|
226
|
-
|
|
226
|
+
build_plan_id: optionalActionIdField("Build Plan id"),
|
|
227
227
|
label: optionalActionText,
|
|
228
228
|
hint: optionalActionText,
|
|
229
229
|
task_prompt: requiredActionText("Agent work"),
|
|
230
|
-
|
|
230
|
+
requested_artifacts_description: optionalActionText,
|
|
231
231
|
readiness_notes: optionalActionText,
|
|
232
232
|
}).strict().superRefine((values, ctx) => {
|
|
233
|
-
const
|
|
234
|
-
if (
|
|
233
|
+
const explicitBuildPlanId = maybeActionValue(values.build_plan_id ?? "");
|
|
234
|
+
if (explicitBuildPlanId && existingBuildPlanIds.has(explicitBuildPlanId)) {
|
|
235
235
|
ctx.addIssue({
|
|
236
236
|
code: z.ZodIssueCode.custom,
|
|
237
|
-
path: ["
|
|
237
|
+
path: ["build_plan_id"],
|
|
238
238
|
message: "A Build Plan with this id already exists.",
|
|
239
239
|
});
|
|
240
240
|
}
|
|
241
241
|
});
|
|
242
242
|
}
|
|
243
|
-
function
|
|
243
|
+
function buildPlanChangeSchema(action, buildPlanId, existingBuildPlanIds) {
|
|
244
244
|
const base = {
|
|
245
245
|
action: requiredActionText("Action"),
|
|
246
|
-
|
|
246
|
+
build_plan: actionIdField("Build Plan"),
|
|
247
247
|
preparation: optionalActionIdField("Preparation"),
|
|
248
248
|
};
|
|
249
249
|
if (action === "modify") {
|
|
@@ -257,12 +257,12 @@ function methodChangeSchema(action, methodId, existingMethodIds) {
|
|
|
257
257
|
if (action === "duplicate") {
|
|
258
258
|
return z.object({
|
|
259
259
|
...base,
|
|
260
|
-
|
|
260
|
+
new_build_plan_id: actionIdField("New Build Plan id"),
|
|
261
261
|
}).strict().superRefine((values, ctx) => {
|
|
262
|
-
if (
|
|
262
|
+
if (existingBuildPlanIds.has(values.new_build_plan_id)) {
|
|
263
263
|
ctx.addIssue({
|
|
264
264
|
code: z.ZodIssueCode.custom,
|
|
265
|
-
path: ["
|
|
265
|
+
path: ["new_build_plan_id"],
|
|
266
266
|
message: "A Build Plan with this id already exists.",
|
|
267
267
|
});
|
|
268
268
|
}
|
|
@@ -270,7 +270,7 @@ function methodChangeSchema(action, methodId, existingMethodIds) {
|
|
|
270
270
|
}
|
|
271
271
|
return z.object({
|
|
272
272
|
...base,
|
|
273
|
-
confirmation: requiredActionText("Confirmation").refine((value) => value ===
|
|
273
|
+
confirmation: requiredActionText("Confirmation").refine((value) => value === buildPlanId, `Type ${buildPlanId} to confirm.`),
|
|
274
274
|
}).strict();
|
|
275
275
|
}
|
|
276
276
|
function preparationChangeSchema(action, preparation, existingNames) {
|
|
@@ -284,7 +284,7 @@ function preparationChangeSchema(action, preparation, existingNames) {
|
|
|
284
284
|
name: actionIdField("Preparation id"),
|
|
285
285
|
path: requiredActionText("Source Folder"),
|
|
286
286
|
about: requiredActionText("Agent work"),
|
|
287
|
-
|
|
287
|
+
build_plan: optionalActionIdField("Build Plan"),
|
|
288
288
|
}).strict().superRefine((values, ctx) => {
|
|
289
289
|
if (values.name !== preparation && existingNames.has(values.name)) {
|
|
290
290
|
ctx.addIssue({
|
|
@@ -301,7 +301,7 @@ function preparationChangeSchema(action, preparation, existingNames) {
|
|
|
301
301
|
name: actionIdField("New Preparation id"),
|
|
302
302
|
path: requiredActionText("Source Folder"),
|
|
303
303
|
about: requiredActionText("Agent work"),
|
|
304
|
-
|
|
304
|
+
build_plan: optionalActionIdField("Build Plan"),
|
|
305
305
|
}).strict().superRefine((values, ctx) => {
|
|
306
306
|
if (existingNames.has(values.name)) {
|
|
307
307
|
ctx.addIssue({
|
|
@@ -324,51 +324,52 @@ function conciseSummary(value, fallback) {
|
|
|
324
324
|
const sentence = normalized.match(/^.{24,180}?(?:[.!?](?:\s|$)|$)/)?.[0]?.trim() ?? normalized;
|
|
325
325
|
return sentence.length > 180 ? `${sentence.slice(0, 177).trim()}...` : sentence;
|
|
326
326
|
}
|
|
327
|
-
function
|
|
328
|
-
const
|
|
327
|
+
function normalizedBuildPlanActionValues(values, existingBuildPlanIds, defaultSeed) {
|
|
328
|
+
const explicitBuildPlanId = maybeActionValue(inputValue(values, "build_plan_id"));
|
|
329
329
|
const taskPrompt = inputValue(values, "task_prompt").trim();
|
|
330
|
-
const
|
|
331
|
-
const output = maybeActionValue(inputValue(values, "
|
|
330
|
+
const buildPlanId = explicitBuildPlanId ?? uniqueActionId(taskPrompt || defaultSeed || "custom-build-plan", existingBuildPlanIds);
|
|
331
|
+
const output = maybeActionValue(inputValue(values, "requested_artifacts_description"));
|
|
332
332
|
return {
|
|
333
333
|
...values,
|
|
334
|
-
|
|
335
|
-
label: maybeActionValue(inputValue(values, "label")) ?? titleFromActionId(
|
|
336
|
-
hint: maybeActionValue(inputValue(values, "hint")) ?? conciseSummary(output ?? taskPrompt, "Reusable Build Plan for
|
|
334
|
+
build_plan_id: buildPlanId,
|
|
335
|
+
label: maybeActionValue(inputValue(values, "label")) ?? titleFromActionId(buildPlanId),
|
|
336
|
+
hint: maybeActionValue(inputValue(values, "hint")) ?? conciseSummary(output ?? taskPrompt, "Reusable Build Plan for building Artifacts."),
|
|
337
337
|
task_prompt: taskPrompt,
|
|
338
338
|
};
|
|
339
339
|
}
|
|
340
340
|
function createPreparationActionValues(values) {
|
|
341
|
-
const
|
|
341
|
+
const buildPlan = inputValue(values, "build_plan");
|
|
342
342
|
const readinessNotes = inputValue(values, "readiness_notes");
|
|
343
343
|
return {
|
|
344
344
|
name: inputValue(values, "name"),
|
|
345
345
|
path: inputValue(values, "path"),
|
|
346
346
|
about: inputValue(values, "about"),
|
|
347
|
-
|
|
348
|
-
...(maybeActionValue(
|
|
347
|
+
build_after_setup: false,
|
|
348
|
+
...(maybeActionValue(buildPlan) ? { build_plan: buildPlan } : {}),
|
|
349
349
|
...(maybeActionValue(readinessNotes) ? { readiness_notes: readinessNotes } : {}),
|
|
350
350
|
};
|
|
351
351
|
}
|
|
352
|
-
function
|
|
352
|
+
function selectBuildPlanActionValues(values) {
|
|
353
353
|
return {
|
|
354
354
|
name: inputValue(values, "name"),
|
|
355
355
|
path: inputValue(values, "path"),
|
|
356
356
|
about: inputValue(values, "about"),
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
setup_mode: "select-
|
|
357
|
+
build_plan: inputValue(values, "build_plan"),
|
|
358
|
+
build_after_setup: false,
|
|
359
|
+
setup_mode: "select-build-plan",
|
|
360
360
|
};
|
|
361
361
|
}
|
|
362
362
|
export function preparationSetupRequestFromActionValues(input) {
|
|
363
363
|
const values = PreparationSetupActionValuesSchema.parse(input);
|
|
364
|
+
const buildPlan = values.build_plan;
|
|
364
365
|
return {
|
|
365
|
-
|
|
366
|
-
setup_mode: values.setup_mode === "select-
|
|
366
|
+
build_after_setup: values.build_after_setup ?? false,
|
|
367
|
+
setup_mode: values.setup_mode === "select-build-plan" ? "select-build-plan" : "create",
|
|
367
368
|
preparation: {
|
|
368
369
|
name: values.name,
|
|
369
370
|
path: values.path,
|
|
370
371
|
about: values.about,
|
|
371
|
-
...(
|
|
372
|
+
...(buildPlan && buildPlan.length > 0 ? { build_plan: buildPlan } : {}),
|
|
372
373
|
checks: values.checks ?? [],
|
|
373
374
|
...(values.requested_artifacts ? { requested_artifacts: values.requested_artifacts } : {}),
|
|
374
375
|
...(values.source_profile ? { source_profile: values.source_profile } : {}),
|
|
@@ -377,23 +378,23 @@ export function preparationSetupRequestFromActionValues(input) {
|
|
|
377
378
|
},
|
|
378
379
|
};
|
|
379
380
|
}
|
|
380
|
-
export function
|
|
381
|
-
const values =
|
|
382
|
-
const
|
|
383
|
-
if (!
|
|
381
|
+
export function buildPlanAuthoringRequestFromActionValues(input, context) {
|
|
382
|
+
const values = BuildPlanAuthoringActionValuesSchema.parse(input);
|
|
383
|
+
const buildPlanId = values.build_plan_id ?? values.build_plan_id;
|
|
384
|
+
if (!buildPlanId) {
|
|
384
385
|
throw new Error("Build Plan id is required.");
|
|
385
386
|
}
|
|
386
|
-
const taskPrompt =
|
|
387
|
+
const taskPrompt = buildPlanAuthoringTaskPrompt(values);
|
|
387
388
|
const requestedArtifacts = values.requested_artifacts ?? context.requestedArtifacts ?? [];
|
|
388
389
|
const sourceProfile = values.source_profile ?? context.sourceProfile ?? null;
|
|
389
390
|
return {
|
|
390
391
|
...(context.preparation ? { preparation: context.preparation } : {}),
|
|
391
392
|
source_folder_path: context.sourceFolderPath,
|
|
392
|
-
...(values.
|
|
393
|
-
...(values.
|
|
394
|
-
|
|
395
|
-
label: values.label ?? titleFromActionId(
|
|
396
|
-
hint: values.hint ?? conciseSummary(values.
|
|
393
|
+
...(values.base_build_plan_id ?? values.base_build_plan_id ? { base_build_plan_id: values.base_build_plan_id ?? values.base_build_plan_id } : {}),
|
|
394
|
+
...(values.reference_build_plan_id ?? values.reference_build_plan_id ? { reference_build_plan_id: values.reference_build_plan_id ?? values.reference_build_plan_id } : {}),
|
|
395
|
+
build_plan_id: buildPlanId,
|
|
396
|
+
label: values.label ?? titleFromActionId(buildPlanId),
|
|
397
|
+
hint: values.hint ?? conciseSummary(values.requested_artifacts_description ?? values.task_prompt, "Reusable Build Plan for building Artifacts."),
|
|
397
398
|
task_prompt: taskPrompt,
|
|
398
399
|
checks: context.checks ?? [],
|
|
399
400
|
requested_artifacts: requestedArtifacts,
|
|
@@ -401,76 +402,76 @@ export function methodAuthoringRequestFromActionValues(input, context) {
|
|
|
401
402
|
artifact_requirements: artifactRequirementsFromRequestedArtifacts(requestedArtifacts),
|
|
402
403
|
};
|
|
403
404
|
}
|
|
404
|
-
export function
|
|
405
|
+
export function buildPlanImprovementActionValues(options) {
|
|
405
406
|
const readinessNotes = (options.checks ?? [])
|
|
406
407
|
.map((check) => check.question)
|
|
407
408
|
.filter((question) => question.trim().length > 0)
|
|
408
409
|
.join("\n");
|
|
409
410
|
return {
|
|
410
|
-
|
|
411
|
-
|
|
411
|
+
build_plan_id: options.buildPlanId,
|
|
412
|
+
reference_build_plan_id: options.buildPlanId,
|
|
412
413
|
...(maybeActionValue(options.label ?? "") ? { label: options.label } : {}),
|
|
413
414
|
...(maybeActionValue(options.hint ?? "") ? { hint: options.hint } : {}),
|
|
414
|
-
task_prompt: `Improve Build Plan ${options.
|
|
415
|
+
task_prompt: `Improve Build Plan ${options.buildPlanId} using the latest readiness evidence for Preparation ${options.preparationName}.`,
|
|
415
416
|
...(maybeActionValue(readinessNotes) ? { readiness_notes: readinessNotes } : {}),
|
|
416
417
|
};
|
|
417
418
|
}
|
|
418
|
-
function
|
|
419
|
-
const
|
|
419
|
+
function buildPlanAuthoringActionValues(values) {
|
|
420
|
+
const buildPlanId = inputValue(values, "build_plan_id");
|
|
420
421
|
const label = inputValue(values, "label");
|
|
421
422
|
const hint = inputValue(values, "hint");
|
|
422
|
-
const
|
|
423
|
+
const requestedArtifactsDescription = inputValue(values, "requested_artifacts_description");
|
|
423
424
|
const readinessNotes = inputValue(values, "readiness_notes");
|
|
424
425
|
return {
|
|
425
|
-
...(maybeActionValue(
|
|
426
|
+
...(maybeActionValue(buildPlanId) ? { build_plan_id: buildPlanId } : {}),
|
|
426
427
|
...(maybeActionValue(label) ? { label } : {}),
|
|
427
428
|
...(maybeActionValue(hint) ? { hint } : {}),
|
|
428
429
|
task_prompt: inputValue(values, "task_prompt"),
|
|
429
|
-
...(maybeActionValue(
|
|
430
|
+
...(maybeActionValue(requestedArtifactsDescription) ? { requested_artifacts_description: requestedArtifactsDescription } : {}),
|
|
430
431
|
...(maybeActionValue(readinessNotes) ? { readiness_notes: readinessNotes } : {}),
|
|
431
432
|
};
|
|
432
433
|
}
|
|
433
|
-
function
|
|
434
|
+
function buildPlanChangeActionValues(action, values) {
|
|
434
435
|
if (action === "modify") {
|
|
435
|
-
const
|
|
436
|
+
const buildPlanId = inputValue(values, "build_plan");
|
|
436
437
|
return {
|
|
437
|
-
|
|
438
|
-
|
|
438
|
+
build_plan_id: buildPlanId,
|
|
439
|
+
reference_build_plan_id: buildPlanId,
|
|
439
440
|
...(maybeActionValue(inputValue(values, "label")) ? { label: inputValue(values, "label") } : {}),
|
|
440
441
|
...(maybeActionValue(inputValue(values, "hint")) ? { hint: inputValue(values, "hint") } : {}),
|
|
441
442
|
task_prompt: [
|
|
442
|
-
`Modify Build Plan ${
|
|
443
|
+
`Modify Build Plan ${buildPlanId}.`,
|
|
443
444
|
inputValue(values, "change_request"),
|
|
444
445
|
].filter(Boolean).join("\n"),
|
|
445
446
|
};
|
|
446
447
|
}
|
|
447
448
|
if (action === "duplicate") {
|
|
448
|
-
const
|
|
449
|
+
const newBuildPlanId = inputValue(values, "new_build_plan_id");
|
|
449
450
|
return {
|
|
450
|
-
action_type: "
|
|
451
|
+
action_type: "build-plan-change",
|
|
451
452
|
operation: "duplicate",
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
label: titleFromActionId(
|
|
455
|
-
hint: `Duplicate of ${inputValue(values, "
|
|
453
|
+
build_plan: inputValue(values, "build_plan"),
|
|
454
|
+
new_build_plan_id: newBuildPlanId,
|
|
455
|
+
label: titleFromActionId(newBuildPlanId),
|
|
456
|
+
hint: `Duplicate of ${inputValue(values, "build_plan")}`,
|
|
456
457
|
};
|
|
457
458
|
}
|
|
458
459
|
return {
|
|
459
|
-
action_type: "
|
|
460
|
+
action_type: "build-plan-change",
|
|
460
461
|
operation: "remove",
|
|
461
|
-
|
|
462
|
+
build_plan: inputValue(values, "build_plan"),
|
|
462
463
|
confirmation: inputValue(values, "confirmation"),
|
|
463
464
|
};
|
|
464
465
|
}
|
|
465
466
|
function duplicatePreparationActionValues(values) {
|
|
466
|
-
const
|
|
467
|
+
const buildPlan = inputValue(values, "build_plan");
|
|
467
468
|
return {
|
|
468
469
|
name: inputValue(values, "name"),
|
|
469
470
|
path: inputValue(values, "path"),
|
|
470
471
|
about: inputValue(values, "about"),
|
|
471
|
-
|
|
472
|
+
build_after_setup: false,
|
|
472
473
|
setup_mode: "create",
|
|
473
|
-
...(maybeActionValue(
|
|
474
|
+
...(maybeActionValue(buildPlan) ? { build_plan: buildPlan } : {}),
|
|
474
475
|
};
|
|
475
476
|
}
|
|
476
477
|
function preparationChangeActionValues(action, values) {
|
|
@@ -489,7 +490,7 @@ export function buildCreatePreparationActionDefinition(context) {
|
|
|
489
490
|
return {
|
|
490
491
|
id: INTERF_SERVICE_ACTIONS.createPreparation.id,
|
|
491
492
|
title: INTERF_SERVICE_ACTIONS.createPreparation.title,
|
|
492
|
-
description: "Describe the Source and agent job. Interf saves a Preparation so a Build Plan can be drafted and reviewed before
|
|
493
|
+
description: "Describe the Source and agent job. Interf saves a Preparation so a Build Plan can be drafted and reviewed before build.",
|
|
493
494
|
submitLabel: "Create",
|
|
494
495
|
initialValues: {
|
|
495
496
|
name,
|
|
@@ -502,7 +503,7 @@ export function buildCreatePreparationActionDefinition(context) {
|
|
|
502
503
|
name: "name",
|
|
503
504
|
path: "path",
|
|
504
505
|
about: "about",
|
|
505
|
-
|
|
506
|
+
build_plan: "build_plan",
|
|
506
507
|
}),
|
|
507
508
|
valuesPreview: createPreparationActionValues,
|
|
508
509
|
buildDraft: (values) => {
|
|
@@ -516,7 +517,7 @@ export function buildCreatePreparationActionDefinition(context) {
|
|
|
516
517
|
`Agent work: ${inputValue(values, "about")}`,
|
|
517
518
|
maybeActionValue(readinessNotes) ? `Requested Artifacts and readiness: ${readinessNotes}` : null,
|
|
518
519
|
`Source folder: ${inputValue(values, "path")}`,
|
|
519
|
-
"Draft or select the Build Plan after this Preparation exists. Do not
|
|
520
|
+
"Draft or select the Build Plan after this Preparation exists. Do not build yet.",
|
|
520
521
|
"Use the attached typed action input as the source of truth.",
|
|
521
522
|
].filter((line) => Boolean(line)).join("\n"),
|
|
522
523
|
};
|
|
@@ -551,38 +552,38 @@ export function buildCreatePreparationActionDefinition(context) {
|
|
|
551
552
|
],
|
|
552
553
|
};
|
|
553
554
|
}
|
|
554
|
-
export function
|
|
555
|
+
export function buildBuildRunActionDefinition(context) {
|
|
555
556
|
return {
|
|
556
|
-
id: INTERF_SERVICE_ACTIONS.
|
|
557
|
-
title: INTERF_SERVICE_ACTIONS.
|
|
558
|
-
description: "Build
|
|
557
|
+
id: INTERF_SERVICE_ACTIONS.buildRun.id,
|
|
558
|
+
title: INTERF_SERVICE_ACTIONS.buildRun.title,
|
|
559
|
+
description: "Build verifiable context for this Preparation. Interf will run the saved Build Plan against the Source and record a visible run.",
|
|
559
560
|
submitLabel: "Run",
|
|
560
561
|
initialValues: {
|
|
561
562
|
preparation: context.name,
|
|
562
|
-
|
|
563
|
+
build_plan: context.buildPlanId,
|
|
563
564
|
about: context.about,
|
|
564
565
|
source_folder_path: context.sourceFolderPath,
|
|
565
566
|
},
|
|
566
567
|
schema: prepareRunSchema(),
|
|
567
568
|
valuesPreview: (values) => ({
|
|
568
|
-
action_type: INTERF_SERVICE_ACTIONS.
|
|
569
|
+
action_type: INTERF_SERVICE_ACTIONS.buildRun.serviceAction,
|
|
569
570
|
preparation: inputValue(values, "preparation"),
|
|
570
|
-
|
|
571
|
+
build_plan: inputValue(values, "build_plan"),
|
|
571
572
|
source_folder_path: inputValue(values, "source_folder_path"),
|
|
572
573
|
about: inputValue(values, "about"),
|
|
573
574
|
}),
|
|
574
575
|
buildDraft: (values) => ({
|
|
575
576
|
preparation: inputValue(values, "preparation"),
|
|
576
577
|
values: {
|
|
577
|
-
action_type: INTERF_SERVICE_ACTIONS.
|
|
578
|
+
action_type: INTERF_SERVICE_ACTIONS.buildRun.serviceAction,
|
|
578
579
|
preparation: inputValue(values, "preparation"),
|
|
579
|
-
...(maybeActionValue(inputValue(values, "
|
|
580
|
+
...(maybeActionValue(inputValue(values, "build_plan")) ? { build_plan: inputValue(values, "build_plan") } : {}),
|
|
580
581
|
},
|
|
581
582
|
message: [
|
|
582
|
-
`
|
|
583
|
+
`Build Artifacts for Preparation ${inputValue(values, "preparation")}.`,
|
|
583
584
|
maybeActionValue(inputValue(values, "about")) ? `Agent work: ${inputValue(values, "about")}` : null,
|
|
584
|
-
`Build Plan: ${inputValue(values, "
|
|
585
|
-
"Build
|
|
585
|
+
`Build Plan: ${inputValue(values, "build_plan") || "(saved selection)"}.`,
|
|
586
|
+
"Build verifiable context from the saved Source and requested Artifacts.",
|
|
586
587
|
"Use the attached typed action input as the source of truth.",
|
|
587
588
|
].filter((line) => Boolean(line)).join("\n"),
|
|
588
589
|
}),
|
|
@@ -593,15 +594,15 @@ export function buildCompileRunActionDefinition(context) {
|
|
|
593
594
|
type: "text",
|
|
594
595
|
readOnly: true,
|
|
595
596
|
help: "The saved Preparation that will be built.",
|
|
596
|
-
context: "Sent as the
|
|
597
|
+
context: "Sent as the build target.",
|
|
597
598
|
},
|
|
598
599
|
{
|
|
599
|
-
name: "
|
|
600
|
+
name: "build_plan",
|
|
600
601
|
label: "Build Plan",
|
|
601
602
|
type: "text",
|
|
602
603
|
readOnly: true,
|
|
603
604
|
help: "The Build Plan Interf will run to build the requested Artifacts.",
|
|
604
|
-
context: "Sent as the
|
|
605
|
+
context: "Sent as the Build Plan override.",
|
|
605
606
|
},
|
|
606
607
|
{
|
|
607
608
|
name: "about",
|
|
@@ -610,7 +611,7 @@ export function buildCompileRunActionDefinition(context) {
|
|
|
610
611
|
readOnly: true,
|
|
611
612
|
advanced: true,
|
|
612
613
|
help: "The work this Preparation is meant to support.",
|
|
613
|
-
context: "Preserved as context for the
|
|
614
|
+
context: "Preserved as context for the Build run proposal.",
|
|
614
615
|
placeholder: "No saved job description.",
|
|
615
616
|
},
|
|
616
617
|
{
|
|
@@ -625,13 +626,13 @@ export function buildCompileRunActionDefinition(context) {
|
|
|
625
626
|
],
|
|
626
627
|
};
|
|
627
628
|
}
|
|
628
|
-
export function
|
|
629
|
-
const definition =
|
|
629
|
+
export function buildBuildRunActionDraft(context) {
|
|
630
|
+
const definition = buildBuildRunActionDefinition(context);
|
|
630
631
|
return definition.buildDraft(definition.initialValues);
|
|
631
632
|
}
|
|
632
|
-
export function
|
|
633
|
+
export function buildSelectBuildPlanActionDefinition(context) {
|
|
633
634
|
const actionValues = (values) => ({
|
|
634
|
-
...
|
|
635
|
+
...selectBuildPlanActionValues(values),
|
|
635
636
|
checks: context.checks ?? [],
|
|
636
637
|
requested_artifacts: context.requestedArtifacts ?? [],
|
|
637
638
|
...(context.sourceProfile ? { source_profile: context.sourceProfile } : {}),
|
|
@@ -639,45 +640,45 @@ export function buildSelectMethodActionDefinition(context) {
|
|
|
639
640
|
...(typeof context.maxLoops === "number" ? { max_loops: context.maxLoops } : {}),
|
|
640
641
|
});
|
|
641
642
|
return {
|
|
642
|
-
id: INTERF_SERVICE_ACTIONS.
|
|
643
|
-
title: INTERF_SERVICE_ACTIONS.
|
|
644
|
-
description: "Choose the Build Plan that
|
|
643
|
+
id: INTERF_SERVICE_ACTIONS.selectBuildPlan.id,
|
|
644
|
+
title: INTERF_SERVICE_ACTIONS.selectBuildPlan.title,
|
|
645
|
+
description: "Choose the Build Plan that builds this Preparation's requested Artifacts. This saves the selection without running a Build run.",
|
|
645
646
|
submitLabel: "Confirm",
|
|
646
647
|
initialValues: {
|
|
647
648
|
name: context.name,
|
|
648
649
|
path: context.sourceFolderPath,
|
|
649
650
|
about: context.about,
|
|
650
|
-
|
|
651
|
-
|
|
651
|
+
current_build_plan: context.currentBuildPlanId ?? "",
|
|
652
|
+
build_plan: context.currentBuildPlanId ?? "",
|
|
652
653
|
},
|
|
653
|
-
schema:
|
|
654
|
+
schema: selectBuildPlanSchema(),
|
|
654
655
|
validateRequest: (values) => packageSchemaFieldErrors(PreparationSetupActionValuesSchema.safeParse(actionValues(values)), {
|
|
655
656
|
name: "name",
|
|
656
657
|
path: "path",
|
|
657
658
|
about: "about",
|
|
658
|
-
|
|
659
|
+
build_plan: "build_plan",
|
|
659
660
|
}),
|
|
660
661
|
valuesPreview: actionValues,
|
|
661
662
|
buildDraft: (values) => ({
|
|
662
663
|
preparation: inputValue(values, "name"),
|
|
663
664
|
values: actionValues(values),
|
|
664
665
|
message: [
|
|
665
|
-
`Select Build Plan ${inputValue(values, "
|
|
666
|
-
"Save the selected Build Plan. Do not
|
|
666
|
+
`Select Build Plan ${inputValue(values, "build_plan")} for Preparation ${inputValue(values, "name")}.`,
|
|
667
|
+
"Save the selected Build Plan. Do not build yet.",
|
|
667
668
|
"Use the attached typed action input as the source of truth.",
|
|
668
669
|
].join("\n"),
|
|
669
670
|
}),
|
|
670
671
|
fields: [
|
|
671
672
|
{
|
|
672
|
-
name: "
|
|
673
|
+
name: "build_plan",
|
|
673
674
|
label: "Build Plan",
|
|
674
675
|
type: "select",
|
|
675
|
-
help: "The Build Plan future
|
|
676
|
+
help: "The Build Plan future Build runs should use to build requested Artifacts.",
|
|
676
677
|
context: "Saved on the existing Preparation.",
|
|
677
|
-
options:
|
|
678
|
+
options: buildPlanChoiceOptions(context.buildPlans),
|
|
678
679
|
},
|
|
679
680
|
{
|
|
680
|
-
name: "
|
|
681
|
+
name: "current_build_plan",
|
|
681
682
|
label: "Current Build Plan",
|
|
682
683
|
type: "text",
|
|
683
684
|
readOnly: true,
|
|
@@ -714,48 +715,48 @@ export function buildSelectMethodActionDefinition(context) {
|
|
|
714
715
|
],
|
|
715
716
|
};
|
|
716
717
|
}
|
|
717
|
-
export function
|
|
718
|
-
const
|
|
719
|
-
const defaultSeed = context.defaultPreparation ? `${context.defaultPreparation}-
|
|
720
|
-
const
|
|
721
|
-
const label = titleFromActionId(
|
|
718
|
+
export function buildCreateBuildPlanActionDefinition(context) {
|
|
719
|
+
const existingBuildPlanIds = new Set(context.existingBuildPlanIds);
|
|
720
|
+
const defaultSeed = context.defaultPreparation ? `${context.defaultPreparation}-build-plan` : context.suggestedBuildPlanId;
|
|
721
|
+
const buildPlanId = uniqueActionId(defaultSeed, existingBuildPlanIds);
|
|
722
|
+
const label = titleFromActionId(buildPlanId);
|
|
722
723
|
return {
|
|
723
|
-
id: INTERF_SERVICE_ACTIONS.
|
|
724
|
-
title: INTERF_SERVICE_ACTIONS.
|
|
725
|
-
description: "Describe the Artifacts the agent needs. Interf drafts the Build Plan from this description;
|
|
724
|
+
id: INTERF_SERVICE_ACTIONS.createBuildPlan.id,
|
|
725
|
+
title: INTERF_SERVICE_ACTIONS.createBuildPlan.title,
|
|
726
|
+
description: "Describe the Artifacts the agent needs. Interf drafts the Build Plan from this description; the Build run later proves source coverage.",
|
|
726
727
|
submitLabel: "Send Request",
|
|
727
728
|
initialValues: {
|
|
728
|
-
|
|
729
|
+
build_plan_id: "",
|
|
729
730
|
label: "",
|
|
730
731
|
hint: "",
|
|
731
732
|
task_prompt: "",
|
|
732
|
-
|
|
733
|
+
requested_artifacts_description: "",
|
|
733
734
|
readiness_notes: "",
|
|
734
735
|
},
|
|
735
|
-
normalizeValues: (values) =>
|
|
736
|
-
schema:
|
|
737
|
-
validateRequest: (values) => packageSchemaFieldErrors(
|
|
738
|
-
|
|
736
|
+
normalizeValues: (values) => normalizedBuildPlanActionValues(values, existingBuildPlanIds, defaultSeed),
|
|
737
|
+
schema: buildPlanAuthoringSchema(existingBuildPlanIds),
|
|
738
|
+
validateRequest: (values) => packageSchemaFieldErrors(BuildPlanAuthoringActionValuesSchema.safeParse(buildPlanAuthoringActionValues(values)), {
|
|
739
|
+
build_plan_id: "build_plan_id",
|
|
739
740
|
label: "label",
|
|
740
741
|
hint: "hint",
|
|
741
742
|
task_prompt: "task_prompt",
|
|
742
|
-
|
|
743
|
+
requested_artifacts_description: "requested_artifacts_description",
|
|
743
744
|
readiness_notes: "readiness_notes",
|
|
744
745
|
}),
|
|
745
746
|
valuesPreview: (values) => ({
|
|
746
|
-
|
|
747
|
+
build_plan_id: inputValue(values, "build_plan_id"),
|
|
747
748
|
label: inputValue(values, "label"),
|
|
748
749
|
hint: inputValue(values, "hint"),
|
|
749
|
-
task_prompt:
|
|
750
|
+
task_prompt: buildPlanTaskPromptFromInput(values),
|
|
750
751
|
}),
|
|
751
752
|
buildDraft: (values) => ({
|
|
752
753
|
preparation: context.defaultPreparation,
|
|
753
|
-
values:
|
|
754
|
+
values: buildPlanAuthoringActionValues(values),
|
|
754
755
|
message: [
|
|
755
|
-
`Draft Build Plan ${inputValue(values, "
|
|
756
|
+
`Draft Build Plan ${inputValue(values, "build_plan_id")}${context.defaultPreparation ? ` for Preparation ${context.defaultPreparation}` : ""}.`,
|
|
756
757
|
`Label: ${inputValue(values, "label")}`,
|
|
757
758
|
`Summary: ${inputValue(values, "hint")}`,
|
|
758
|
-
|
|
759
|
+
buildPlanTaskPromptFromInput(values),
|
|
759
760
|
"Use the attached typed action input as the Build Plan authoring request.",
|
|
760
761
|
].join("\n"),
|
|
761
762
|
}),
|
|
@@ -770,12 +771,12 @@ export function buildCreateMethodActionDefinition(context) {
|
|
|
770
771
|
placeholder: "Example: Analyze every report chart, extract annual take-up by location, and produce a source data file plus markdown summary.",
|
|
771
772
|
},
|
|
772
773
|
{
|
|
773
|
-
name: "
|
|
774
|
+
name: "requested_artifacts_description",
|
|
774
775
|
label: "Requested Artifacts",
|
|
775
776
|
type: "textarea",
|
|
776
777
|
rows: 3,
|
|
777
|
-
help: "Files, sections, or evidence agents should receive in
|
|
778
|
-
context: "Guides the requested Artifact shape and Build Plan stages before
|
|
778
|
+
help: "Files, sections, or evidence agents should receive in verifiable context.",
|
|
779
|
+
context: "Guides the requested Artifact shape and Build Plan stages before a Build run proves source coverage.",
|
|
779
780
|
placeholder: "Describe the files or sections agents should receive.",
|
|
780
781
|
},
|
|
781
782
|
{
|
|
@@ -788,13 +789,13 @@ export function buildCreateMethodActionDefinition(context) {
|
|
|
788
789
|
placeholder: "Describe the evidence that should make these Artifacts ready.",
|
|
789
790
|
},
|
|
790
791
|
{
|
|
791
|
-
name: "
|
|
792
|
+
name: "build_plan_id",
|
|
792
793
|
label: "Build Plan id",
|
|
793
794
|
type: "text",
|
|
794
795
|
advanced: true,
|
|
795
796
|
help: "Optional. Leave blank and Interf generates a stable id from the job.",
|
|
796
|
-
context: "Saved as the
|
|
797
|
-
placeholder:
|
|
797
|
+
context: "Saved as the Build Plan id and referenced by Preparations.",
|
|
798
|
+
placeholder: buildPlanId,
|
|
798
799
|
},
|
|
799
800
|
{
|
|
800
801
|
name: "label",
|
|
@@ -818,44 +819,44 @@ export function buildCreateMethodActionDefinition(context) {
|
|
|
818
819
|
],
|
|
819
820
|
};
|
|
820
821
|
}
|
|
821
|
-
export function
|
|
822
|
-
const
|
|
822
|
+
export function buildBuildPlanChangeActionDefinition(context) {
|
|
823
|
+
const existingBuildPlanIds = new Set(context.existingBuildPlanIds);
|
|
823
824
|
const actionLabel = titleFromActionId(context.action);
|
|
824
|
-
const
|
|
825
|
-
? uniqueActionId(`${context.
|
|
825
|
+
const newBuildPlanId = context.action === "duplicate"
|
|
826
|
+
? uniqueActionId(`${context.buildPlanId}-copy`, existingBuildPlanIds)
|
|
826
827
|
: "";
|
|
827
828
|
const initialValues = {
|
|
828
|
-
action: `
|
|
829
|
-
|
|
829
|
+
action: `build-plan-${context.action}`,
|
|
830
|
+
build_plan: context.buildPlanId,
|
|
830
831
|
preparation: context.preparation,
|
|
831
832
|
...(context.action === "modify" ? { change_request: "", label: context.label ?? "", hint: context.hint ?? "" } : {}),
|
|
832
|
-
...(context.action === "duplicate" ? {
|
|
833
|
+
...(context.action === "duplicate" ? { new_build_plan_id: newBuildPlanId } : {}),
|
|
833
834
|
...(context.action === "remove" ? { confirmation: "" } : {}),
|
|
834
835
|
};
|
|
835
|
-
const actionValues = (values) =>
|
|
836
|
+
const actionValues = (values) => buildPlanChangeActionValues(context.action, values);
|
|
836
837
|
const messageFor = (values) => {
|
|
837
838
|
if (context.action === "modify") {
|
|
838
839
|
return [
|
|
839
|
-
`Modify Build Plan ${inputValue(values, "
|
|
840
|
+
`Modify Build Plan ${inputValue(values, "build_plan")}.`,
|
|
840
841
|
`Requested change: ${inputValue(values, "change_request")}`,
|
|
841
842
|
"Use the attached typed Build Plan authoring input as the source of truth.",
|
|
842
843
|
].join("\n");
|
|
843
844
|
}
|
|
844
845
|
if (context.action === "duplicate") {
|
|
845
846
|
return [
|
|
846
|
-
`Duplicate Build Plan ${inputValue(values, "
|
|
847
|
+
`Duplicate Build Plan ${inputValue(values, "build_plan")} as ${inputValue(values, "new_build_plan_id")}.`,
|
|
847
848
|
"Use the attached typed Build Plan change input as the source of truth.",
|
|
848
849
|
].join("\n");
|
|
849
850
|
}
|
|
850
851
|
return [
|
|
851
|
-
`Remove Build Plan ${inputValue(values, "
|
|
852
|
+
`Remove Build Plan ${inputValue(values, "build_plan")}.`,
|
|
852
853
|
"The user typed the Build Plan id to confirm removal.",
|
|
853
854
|
"Use the attached typed Build Plan change input as the source of truth.",
|
|
854
855
|
].join("\n");
|
|
855
856
|
};
|
|
856
857
|
const fields = [
|
|
857
858
|
{
|
|
858
|
-
name: "
|
|
859
|
+
name: "build_plan",
|
|
859
860
|
label: "Build Plan",
|
|
860
861
|
type: "text",
|
|
861
862
|
readOnly: true,
|
|
@@ -875,22 +876,22 @@ export function buildMethodChangeActionDefinition(context) {
|
|
|
875
876
|
placeholder: "Describe the concrete change Interf should make.",
|
|
876
877
|
},
|
|
877
878
|
{
|
|
878
|
-
name: "
|
|
879
|
+
name: "new_build_plan_id",
|
|
879
880
|
label: "New Build Plan id",
|
|
880
881
|
type: "text",
|
|
881
882
|
advanced: context.action !== "duplicate",
|
|
882
883
|
help: "Stable id for the duplicated Build Plan.",
|
|
883
884
|
context: "Used as the target Build Plan id for the duplicate request.",
|
|
884
|
-
placeholder:
|
|
885
|
+
placeholder: newBuildPlanId,
|
|
885
886
|
},
|
|
886
887
|
{
|
|
887
888
|
name: "confirmation",
|
|
888
889
|
label: "Confirm removal",
|
|
889
890
|
type: "text",
|
|
890
891
|
advanced: context.action !== "remove",
|
|
891
|
-
help: `Type ${context.
|
|
892
|
+
help: `Type ${context.buildPlanId} to confirm this removal request.`,
|
|
892
893
|
context: "Prevents accidental destructive Build Plan requests.",
|
|
893
|
-
placeholder: context.
|
|
894
|
+
placeholder: context.buildPlanId,
|
|
894
895
|
},
|
|
895
896
|
{
|
|
896
897
|
name: "label",
|
|
@@ -899,7 +900,7 @@ export function buildMethodChangeActionDefinition(context) {
|
|
|
899
900
|
advanced: true,
|
|
900
901
|
help: "Readable Build Plan name to keep while modifying this Build Plan.",
|
|
901
902
|
context: "Sent to the Build Plan authoring run.",
|
|
902
|
-
placeholder: context.label ?? context.
|
|
903
|
+
placeholder: context.label ?? context.buildPlanId,
|
|
903
904
|
},
|
|
904
905
|
{
|
|
905
906
|
name: "hint",
|
|
@@ -923,7 +924,7 @@ export function buildMethodChangeActionDefinition(context) {
|
|
|
923
924
|
},
|
|
924
925
|
];
|
|
925
926
|
return {
|
|
926
|
-
id: `${INTERF_SERVICE_ACTIONS.
|
|
927
|
+
id: `${INTERF_SERVICE_ACTIONS.buildPlanChange.id}-${context.action}`,
|
|
927
928
|
title: `${actionLabel} Build Plan`,
|
|
928
929
|
description: context.action === "remove"
|
|
929
930
|
? "Confirm the Build Plan removal request. Interf will reject removal while any saved Preparation still uses it."
|
|
@@ -932,7 +933,7 @@ export function buildMethodChangeActionDefinition(context) {
|
|
|
932
933
|
: "Describe the change and Interf will run a visible Build Plan draft job.",
|
|
933
934
|
submitLabel: context.action === "modify" ? "Send Request" : "Confirm",
|
|
934
935
|
initialValues,
|
|
935
|
-
schema:
|
|
936
|
+
schema: buildPlanChangeSchema(context.action, context.buildPlanId, existingBuildPlanIds),
|
|
936
937
|
valuesPreview: actionValues,
|
|
937
938
|
buildDraft: (values) => ({
|
|
938
939
|
preparation: inputValue(values, "preparation"),
|
|
@@ -942,7 +943,7 @@ export function buildMethodChangeActionDefinition(context) {
|
|
|
942
943
|
fields: fields.filter((field) => {
|
|
943
944
|
if (field.name === "change_request")
|
|
944
945
|
return context.action === "modify";
|
|
945
|
-
if (field.name === "
|
|
946
|
+
if (field.name === "new_build_plan_id")
|
|
946
947
|
return context.action === "duplicate";
|
|
947
948
|
if (field.name === "confirmation")
|
|
948
949
|
return context.action === "remove";
|
|
@@ -966,7 +967,7 @@ export function buildPreparationChangeActionDefinition(context) {
|
|
|
966
967
|
name: context.action === "duplicate" ? duplicateName : context.preparation,
|
|
967
968
|
path: context.sourceFolderPath,
|
|
968
969
|
about: context.about ?? "",
|
|
969
|
-
|
|
970
|
+
build_plan: context.buildPlanId ?? "",
|
|
970
971
|
}
|
|
971
972
|
: {}),
|
|
972
973
|
...(context.action === "remove" ? { confirmation: "" } : {}),
|
|
@@ -977,7 +978,7 @@ export function buildPreparationChangeActionDefinition(context) {
|
|
|
977
978
|
return [
|
|
978
979
|
`Modify Preparation ${inputValue(values, "preparation")}.`,
|
|
979
980
|
`Agent work: ${inputValue(values, "about")}`,
|
|
980
|
-
maybeActionValue(inputValue(values, "
|
|
981
|
+
maybeActionValue(inputValue(values, "build_plan")) ? `Build Plan: ${inputValue(values, "build_plan")}` : null,
|
|
981
982
|
`Source folder: ${inputValue(values, "path")}`,
|
|
982
983
|
"Use the attached typed Preparation setup input as the source of truth.",
|
|
983
984
|
].filter((line) => Boolean(line)).join("\n");
|
|
@@ -986,7 +987,7 @@ export function buildPreparationChangeActionDefinition(context) {
|
|
|
986
987
|
return [
|
|
987
988
|
`Duplicate Preparation ${inputValue(values, "preparation")} as ${inputValue(values, "name")}.`,
|
|
988
989
|
`Agent work: ${inputValue(values, "about")}`,
|
|
989
|
-
maybeActionValue(inputValue(values, "
|
|
990
|
+
maybeActionValue(inputValue(values, "build_plan")) ? `Build Plan: ${inputValue(values, "build_plan")}` : null,
|
|
990
991
|
`Source folder: ${inputValue(values, "path")}`,
|
|
991
992
|
"Use the attached typed Preparation setup input as the source of truth.",
|
|
992
993
|
].filter((line) => Boolean(line)).join("\n");
|
|
@@ -1027,10 +1028,10 @@ export function buildPreparationChangeActionDefinition(context) {
|
|
|
1027
1028
|
placeholder: "Describe the agent job.",
|
|
1028
1029
|
},
|
|
1029
1030
|
{
|
|
1030
|
-
name: "
|
|
1031
|
+
name: "build_plan",
|
|
1031
1032
|
label: "Build Plan",
|
|
1032
1033
|
type: "text",
|
|
1033
|
-
help: "The Build Plan future
|
|
1034
|
+
help: "The Build Plan future Build runs should use.",
|
|
1034
1035
|
context: "Saved on this Preparation.",
|
|
1035
1036
|
placeholder: "interf-default",
|
|
1036
1037
|
},
|
|
@@ -1068,7 +1069,7 @@ export function buildPreparationChangeActionDefinition(context) {
|
|
|
1068
1069
|
name: "name",
|
|
1069
1070
|
path: "path",
|
|
1070
1071
|
about: "about",
|
|
1071
|
-
|
|
1072
|
+
build_plan: "build_plan",
|
|
1072
1073
|
})
|
|
1073
1074
|
: undefined,
|
|
1074
1075
|
valuesPreview: actionValues,
|
|
@@ -1078,7 +1079,7 @@ export function buildPreparationChangeActionDefinition(context) {
|
|
|
1078
1079
|
message: messageFor(values),
|
|
1079
1080
|
}),
|
|
1080
1081
|
fields: fields.filter((field) => {
|
|
1081
|
-
if (field.name === "name" || field.name === "about" || field.name === "
|
|
1082
|
+
if (field.name === "name" || field.name === "about" || field.name === "build_plan" || field.name === "path")
|
|
1082
1083
|
return context.action === "modify" || context.action === "duplicate";
|
|
1083
1084
|
if (field.name === "confirmation")
|
|
1084
1085
|
return context.action === "remove";
|
|
@@ -1150,7 +1151,7 @@ export function buildReadinessActionDraft(options) {
|
|
|
1150
1151
|
message: `Improve ${options.preparation} using the latest readiness evidence.`,
|
|
1151
1152
|
values: {
|
|
1152
1153
|
action_type: INTERF_SERVICE_ACTIONS.improvePreparation.serviceAction,
|
|
1153
|
-
...(options.
|
|
1154
|
+
...(options.buildPlanId ? { build_plan: options.buildPlanId } : {}),
|
|
1154
1155
|
preparation: options.preparation,
|
|
1155
1156
|
},
|
|
1156
1157
|
};
|