scene-capability-engine 3.1.0 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
8
8
  ## [Unreleased]
9
9
 
10
10
  ### Added
11
+ - **Interactive approval role-policy step-up**: `interactive-approval-workflow` now supports optional role-based action authorization (`--role-policy`, `--actor-role`) and loop/flow/scene commands can pass role policy and actor roles (`--approval-role-policy`, `--approval-actor-role`, `--approver-actor-role`) for separation-of-duties governance.
11
12
  - **Interactive runtime policy + work-order default pipeline**: Added `interactive-runtime-policy-evaluate` and `interactive-work-order-build`, integrated both into `interactive-customization-loop` and `interactive-flow` (including `sce scene interactive-loop/interactive-flow` passthrough), with default `runtime_mode=ops-fix`, `runtime_environment=staging`, runtime non-allow fail gate option, and auditable work-order artifacts.
12
13
  - **Release weekly ops closed-loop summary**: Added `node scripts/release-ops-weekly-summary.js` (npm alias `npm run report:release-ops-weekly`) to aggregate handoff evidence, release-gate history, interactive governance, and matrix signals into one weekly risk/recommendation card (`weekly-ops-summary.json|.md`).
13
14
  - **Release workflow weekly ops asset publication**: `release.yml` now exports and publishes `weekly-ops-summary-<tag>.json|.md` alongside governance snapshot and Moqui release evidence assets.
@@ -987,7 +987,7 @@ Interactive context bridge helper (script-level provider normalization):
987
987
  - npm alias: `npm run report:interactive-context-bridge`
988
988
 
989
989
  Interactive full flow helper (script-level one-command entry):
990
- - `node scripts/interactive-flow.js --input <path> (--goal <text> | --goal-file <path>) [--provider <moqui|generic>] [--execution-mode <suggestion|apply>] [--runtime-mode <user-assist|ops-fix|feature-dev>] [--runtime-environment <dev|staging|prod>] [--runtime-policy <path>] [--policy <path>] [--catalog <path>] [--dialogue-policy <path>] [--context-contract <path>] [--auto-execute-low-risk] [--auth-password-hash <sha256>] [--auth-password <text>] [--feedback-score <0..5>] [--work-order-out <path>] [--work-order-markdown-out <path>] [--fail-on-runtime-non-allow] [--no-matrix] [--matrix-min-score <0..100>] [--matrix-min-valid-rate <0..100>] [--matrix-compare-with <path>] [--matrix-signals <path>] [--matrix-fail-on-portfolio-fail] [--matrix-fail-on-regression] [--json]`: run `context-bridge -> interactive-loop -> matrix-baseline-snapshot` in one command for Moqui workbench integration.
990
+ - `node scripts/interactive-flow.js --input <path> (--goal <text> | --goal-file <path>) [--provider <moqui|generic>] [--execution-mode <suggestion|apply>] [--runtime-mode <user-assist|ops-fix|feature-dev>] [--runtime-environment <dev|staging|prod>] [--runtime-policy <path>] [--policy <path>] [--catalog <path>] [--dialogue-policy <path>] [--context-contract <path>] [--approval-role-policy <path>] [--approval-actor-role <name>] [--approver-actor-role <name>] [--auto-execute-low-risk] [--auth-password-hash <sha256>] [--auth-password <text>] [--feedback-score <0..5>] [--work-order-out <path>] [--work-order-markdown-out <path>] [--fail-on-runtime-non-allow] [--no-matrix] [--matrix-min-score <0..100>] [--matrix-min-valid-rate <0..100>] [--matrix-compare-with <path>] [--matrix-signals <path>] [--matrix-fail-on-portfolio-fail] [--matrix-fail-on-regression] [--json]`: run `context-bridge -> interactive-loop -> matrix-baseline-snapshot` in one command for Moqui workbench integration.
991
991
  - Default flow artifact root: `.kiro/reports/interactive-flow/<session-id>/`
992
992
  - Default flow summary output: `.kiro/reports/interactive-flow/<session-id>/interactive-flow.summary.json`
993
993
  - Default dialogue report output: `.kiro/reports/interactive-flow/<session-id>/interactive-dialogue-governance.json`
@@ -1027,7 +1027,7 @@ Interactive change-plan generator helper (script-level stage-B planning bridge):
1027
1027
  - Generated plans can be evaluated directly by `interactive-change-plan-gate`.
1028
1028
 
1029
1029
  Interactive one-click loop helper (script-level orchestration entry):
1030
- - `node scripts/interactive-customization-loop.js --context <path> (--goal <text> | --goal-file <path>) [--execution-mode <suggestion|apply>] [--runtime-mode <user-assist|ops-fix|feature-dev>] [--runtime-environment <dev|staging|prod>] [--runtime-policy <path>] [--policy <path>] [--catalog <path>] [--dialogue-policy <path>] [--context-contract <path>] [--no-strict-contract] [--auto-approve-low-risk] [--auto-execute-low-risk] [--auth-password-hash <sha256>] [--auth-password <text>] [--feedback-score <0..5>] [--feedback-comment <text>] [--feedback-tags <csv>] [--allow-suggestion-apply] [--work-order-out <path>] [--work-order-markdown-out <path>] [--fail-on-dialogue-deny] [--fail-on-gate-non-allow] [--fail-on-runtime-non-allow] [--json]`: run dialogue->intent->plan->gate->runtime->approval pipeline in one command and optionally trigger low-risk one-click apply via Moqui adapter.
1030
+ - `node scripts/interactive-customization-loop.js --context <path> (--goal <text> | --goal-file <path>) [--execution-mode <suggestion|apply>] [--runtime-mode <user-assist|ops-fix|feature-dev>] [--runtime-environment <dev|staging|prod>] [--runtime-policy <path>] [--policy <path>] [--catalog <path>] [--dialogue-policy <path>] [--context-contract <path>] [--approval-role-policy <path>] [--approval-actor-role <name>] [--approver-actor-role <name>] [--no-strict-contract] [--auto-approve-low-risk] [--auto-execute-low-risk] [--auth-password-hash <sha256>] [--auth-password <text>] [--feedback-score <0..5>] [--feedback-comment <text>] [--feedback-tags <csv>] [--allow-suggestion-apply] [--work-order-out <path>] [--work-order-markdown-out <path>] [--fail-on-dialogue-deny] [--fail-on-gate-non-allow] [--fail-on-runtime-non-allow] [--json]`: run dialogue->intent->plan->gate->runtime->approval pipeline in one command and optionally trigger low-risk one-click apply via Moqui adapter.
1031
1031
  - CLI equivalent: `sce scene interactive-loop --context <path> --goal "<goal>" --context-contract docs/interactive-customization/moqui-copilot-context-contract.json --execution-mode apply --auto-execute-low-risk --auth-password "<password>" --feedback-score 5 --json`
1032
1032
  - Default loop artifact root: `.kiro/reports/interactive-loop/<session-id>/`
1033
1033
  - Default summary output: `.kiro/reports/interactive-loop/<session-id>/interactive-customization-loop.summary.json`
@@ -1054,7 +1054,7 @@ Interactive work-order helper (script-level usage/maintenance/dev closure):
1054
1054
  - `.kiro/reports/interactive-work-order.md`
1055
1055
 
1056
1056
  Interactive approval workflow helper (script-level stage-B approval state machine):
1057
- - `node scripts/interactive-approval-workflow.js --action <init|submit|approve|reject|execute|verify|archive|status> [--plan <path>] [--state-file <path>] [--audit-file <path>] [--actor <id>] [--comment <text>] [--password <text>] [--password-hash <sha256>] [--password-hash-env <name>] [--password-required] [--password-scope <csv>] [--json]`: maintain approval lifecycle state for interactive change plans and append approval events to JSONL audit logs.
1057
+ - `node scripts/interactive-approval-workflow.js --action <init|submit|approve|reject|execute|verify|archive|status> [--plan <path>] [--state-file <path>] [--audit-file <path>] [--actor <id>] [--actor-role <name>] [--role-policy <path>] [--comment <text>] [--password <text>] [--password-hash <sha256>] [--password-hash-env <name>] [--password-required] [--password-scope <csv>] [--json]`: maintain approval lifecycle state for interactive change plans and append approval events to JSONL audit logs.
1058
1058
  - Default state file: `.kiro/reports/interactive-approval-state.json`
1059
1059
  - Default audit file: `.kiro/reports/interactive-approval-events.jsonl`
1060
1060
  - `init` requires `--plan`; high-risk plans are marked as `approval_required=true`.
@@ -11,6 +11,7 @@ This directory contains baseline contracts and safety policy artifacts for the i
11
11
  - `guardrail-policy-baseline.json`: default secure-by-default guardrail policy.
12
12
  - `dialogue-governance-policy-baseline.json`: baseline communication rules for embedded assistant dialogue.
13
13
  - `runtime-mode-policy-baseline.json`: baseline runtime mode/environment policy (`user-assist|ops-fix|feature-dev` x `dev|staging|prod`).
14
+ - `approval-role-policy-baseline.json`: optional approval role policy baseline (`submit/approve/execute/verify/archive` role requirements).
14
15
  - `high-risk-action-catalog.json`: baseline high-risk action classification for deny/review decisions.
15
16
  - `change-plan.sample.json`: runnable sample plan for gate checks.
16
17
  - `page-context.sample.json`: runnable page context sample for read-only intent generation.
@@ -156,6 +157,9 @@ node scripts/interactive-customization-loop.js \
156
157
  --runtime-mode ops-fix \
157
158
  --runtime-environment staging \
158
159
  --runtime-policy docs/interactive-customization/runtime-mode-policy-baseline.json \
160
+ --approval-role-policy docs/interactive-customization/approval-role-policy-baseline.json \
161
+ --approval-actor-role product-owner \
162
+ --approver-actor-role release-operator \
159
163
  --execution-mode apply \
160
164
  --auto-execute-low-risk \
161
165
  --auth-password-hash "<sha256-of-demo-pass>" \
@@ -223,11 +227,15 @@ node scripts/interactive-approval-workflow.js \
223
227
 
224
228
  # submit -> approve -> execute -> verify
225
229
  node scripts/interactive-approval-workflow.js --action submit --actor product-owner --json
226
- node scripts/interactive-approval-workflow.js --action approve --actor security-admin --json
227
- node scripts/interactive-approval-workflow.js --action execute --actor release-operator --password "demo-pass" --json
228
- node scripts/interactive-approval-workflow.js --action verify --actor qa-owner --json
230
+ node scripts/interactive-approval-workflow.js --action approve --actor security-admin --actor-role security-admin --json
231
+ node scripts/interactive-approval-workflow.js --action execute --actor release-operator --actor-role release-operator --password "demo-pass" --json
232
+ node scripts/interactive-approval-workflow.js --action verify --actor qa-owner --actor-role qa-owner --json
229
233
  ```
230
234
 
235
+ When role control is required, initialize workflow with:
236
+ - `--role-policy docs/interactive-customization/approval-role-policy-baseline.json`
237
+ - and pass `--actor-role <role>` in each mutating action.
238
+
231
239
  Run the Moqui adapter interface (`capabilities/plan/validate/apply/rollback`):
232
240
 
233
241
  ```bash
@@ -0,0 +1,36 @@
1
+ {
2
+ "version": "1.0.0",
3
+ "profile": "interactive-approval-role-baseline",
4
+ "role_requirements": {
5
+ "submit": [
6
+ "product-owner",
7
+ "ops-engineer",
8
+ "workflow-operator"
9
+ ],
10
+ "approve": [
11
+ "security-admin",
12
+ "product-owner",
13
+ "workflow-operator"
14
+ ],
15
+ "reject": [
16
+ "security-admin",
17
+ "product-owner",
18
+ "workflow-operator"
19
+ ],
20
+ "execute": [
21
+ "release-operator",
22
+ "ops-engineer",
23
+ "workflow-operator"
24
+ ],
25
+ "verify": [
26
+ "qa-owner",
27
+ "release-operator",
28
+ "workflow-operator"
29
+ ],
30
+ "archive": [
31
+ "product-owner",
32
+ "release-operator",
33
+ "workflow-operator"
34
+ ]
35
+ }
36
+ }
@@ -15,6 +15,7 @@ This baseline is the default operating policy for SCE-driven delivery, including
15
15
  - Low-risk auto-apply is allowed only when gate result is `allow`.
16
16
  - Runtime policy gate is mandatory before apply (`runtime_mode=ops-fix`, `runtime_environment=staging` by default).
17
17
  - Runtime non-allow (`deny|review-required`) should block unattended apply (`--fail-on-runtime-non-allow`).
18
+ - Enable role-based action control when environment requires stronger separation of duties (`approval-role-policy-baseline.json` + `--actor-role`).
18
19
  - Apply-mode mutating plans require password authorization (`authorization.password_required=true` by default).
19
20
  - Password verifier hash must be supplied via `SCE_INTERACTIVE_AUTH_PASSWORD_SHA256` (or explicit override).
20
21
  - Work-order artifacts (`interactive-work-order.json|.md`) are required for usage/maintenance/dev integrated auditing.
@@ -582,7 +582,10 @@ function registerSceneCommands(program) {
582
582
  .option('--work-order-out <path>', 'Work-order JSON output file path')
583
583
  .option('--work-order-markdown-out <path>', 'Work-order markdown output file path')
584
584
  .option('--approval-actor <id>', 'Approval workflow actor')
585
+ .option('--approval-actor-role <name>', 'Approval workflow actor role')
585
586
  .option('--approver-actor <id>', 'Auto-approve actor')
587
+ .option('--approver-actor-role <name>', 'Auto-approve actor role')
588
+ .option('--approval-role-policy <path>', 'Approval role policy JSON path')
586
589
  .option('--skip-submit', 'Skip approval submit step')
587
590
  .option('--auto-approve-low-risk', 'Auto-approve low-risk allow plans')
588
591
  .option('--auto-execute-low-risk', 'Auto-run low-risk apply for allow+low plans')
@@ -649,7 +652,10 @@ function registerSceneCommands(program) {
649
652
  .option('--work-order-markdown-out <path>', 'Work-order markdown output file path')
650
653
  .option('--out <path>', 'Flow summary output file path')
651
654
  .option('--approval-actor <id>', 'Approval workflow actor')
655
+ .option('--approval-actor-role <name>', 'Approval workflow actor role')
652
656
  .option('--approver-actor <id>', 'Auto-approve actor')
657
+ .option('--approver-actor-role <name>', 'Auto-approve actor role')
658
+ .option('--approval-role-policy <path>', 'Approval role policy JSON path')
653
659
  .option('--skip-submit', 'Skip approval submit step')
654
660
  .option('--auto-approve-low-risk', 'Auto-approve low-risk allow plans')
655
661
  .option('--auto-execute-low-risk', 'Auto-run low-risk apply for allow+low plans')
@@ -11166,7 +11172,10 @@ function normalizeSceneInteractiveFlowOptions(options = {}) {
11166
11172
  bridgeOutContext: options.bridgeOutContext ? String(options.bridgeOutContext).trim() : undefined,
11167
11173
  bridgeOutReport: options.bridgeOutReport ? String(options.bridgeOutReport).trim() : undefined,
11168
11174
  approvalActor: options.approvalActor ? String(options.approvalActor).trim() : undefined,
11175
+ approvalActorRole: options.approvalActorRole ? String(options.approvalActorRole).trim().toLowerCase() : undefined,
11169
11176
  approverActor: options.approverActor ? String(options.approverActor).trim() : undefined,
11177
+ approverActorRole: options.approverActorRole ? String(options.approverActorRole).trim().toLowerCase() : undefined,
11178
+ approvalRolePolicy: options.approvalRolePolicy ? String(options.approvalRolePolicy).trim() : undefined,
11170
11179
  skipSubmit: options.skipSubmit === true,
11171
11180
  autoApproveLowRisk: options.autoApproveLowRisk === true,
11172
11181
  autoExecuteLowRisk: options.autoExecuteLowRisk === true,
@@ -11277,7 +11286,10 @@ function normalizeSceneInteractiveLoopOptions(options = {}) {
11277
11286
  workOrderOut: options.workOrderOut ? String(options.workOrderOut).trim() : undefined,
11278
11287
  workOrderMarkdownOut: options.workOrderMarkdownOut ? String(options.workOrderMarkdownOut).trim() : undefined,
11279
11288
  approvalActor: options.approvalActor ? String(options.approvalActor).trim() : undefined,
11289
+ approvalActorRole: options.approvalActorRole ? String(options.approvalActorRole).trim().toLowerCase() : undefined,
11280
11290
  approverActor: options.approverActor ? String(options.approverActor).trim() : undefined,
11291
+ approverActorRole: options.approverActorRole ? String(options.approverActorRole).trim().toLowerCase() : undefined,
11292
+ approvalRolePolicy: options.approvalRolePolicy ? String(options.approvalRolePolicy).trim() : undefined,
11281
11293
  skipSubmit: options.skipSubmit === true,
11282
11294
  autoApproveLowRisk: options.autoApproveLowRisk === true,
11283
11295
  autoExecuteLowRisk: options.autoExecuteLowRisk === true,
@@ -11656,9 +11668,18 @@ async function runSceneInteractiveFlowCommand(rawOptions = {}, dependencies = {}
11656
11668
  if (options.approvalActor) {
11657
11669
  args.push('--approval-actor', options.approvalActor);
11658
11670
  }
11671
+ if (options.approvalActorRole) {
11672
+ args.push('--approval-actor-role', options.approvalActorRole);
11673
+ }
11659
11674
  if (options.approverActor) {
11660
11675
  args.push('--approver-actor', options.approverActor);
11661
11676
  }
11677
+ if (options.approverActorRole) {
11678
+ args.push('--approver-actor-role', options.approverActorRole);
11679
+ }
11680
+ if (options.approvalRolePolicy) {
11681
+ args.push('--approval-role-policy', options.approvalRolePolicy);
11682
+ }
11662
11683
  if (options.skipSubmit) {
11663
11684
  args.push('--skip-submit');
11664
11685
  }
@@ -11872,9 +11893,18 @@ async function runSceneInteractiveLoopCommand(rawOptions = {}, dependencies = {}
11872
11893
  if (options.approvalActor) {
11873
11894
  args.push('--approval-actor', options.approvalActor);
11874
11895
  }
11896
+ if (options.approvalActorRole) {
11897
+ args.push('--approval-actor-role', options.approvalActorRole);
11898
+ }
11875
11899
  if (options.approverActor) {
11876
11900
  args.push('--approver-actor', options.approverActor);
11877
11901
  }
11902
+ if (options.approverActorRole) {
11903
+ args.push('--approver-actor-role', options.approverActorRole);
11904
+ }
11905
+ if (options.approvalRolePolicy) {
11906
+ args.push('--approval-role-policy', options.approvalRolePolicy);
11907
+ }
11878
11908
  if (options.skipSubmit) {
11879
11909
  args.push('--skip-submit');
11880
11910
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scene-capability-engine",
3
- "version": "3.1.0",
3
+ "version": "3.2.0",
4
4
  "description": "SCE (Scene Capability Engine) - A CLI tool and npm package for spec-driven development with AI coding assistants.",
5
5
  "main": "index.js",
6
6
  "bin": {