scene-capability-engine 3.4.6 → 3.5.1
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 +35 -0
- package/README.md +8 -2
- package/README.zh.md +8 -2
- package/docs/command-reference.md +53 -1
- package/lib/adoption/adoption-strategy.js +1 -0
- package/lib/adoption/detection-engine.js +1 -0
- package/lib/adoption/file-classifier.js +2 -1
- package/lib/adoption/smart-orchestrator.js +1 -0
- package/lib/commands/studio.js +334 -18
- package/lib/spec/related-specs.js +10 -2
- package/lib/spec/scene-binding-overrides.js +115 -0
- package/lib/studio/spec-intake-governor.js +1315 -0
- package/lib/workspace/takeover-baseline.js +81 -0
- package/package.json +1 -1
- package/template/.sce/config/studio-intake-policy.json +154 -0
- package/template/.sce/config/takeover-baseline.json +88 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,41 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [3.5.1] - 2026-03-03
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
- Studio historical scene backfill command:
|
|
14
|
+
- `sce studio backfill-spec-scenes`
|
|
15
|
+
- supports active-only/default batch backfill and writes `.sce/spec-governance/spec-scene-overrides.json`
|
|
16
|
+
- optionally refreshes governance artifacts after apply
|
|
17
|
+
|
|
18
|
+
### Changed
|
|
19
|
+
- Studio intake/governance policy is now stricter by default:
|
|
20
|
+
- `allow_manual_spec_override=false` blocks `--manual-spec` bypass unless explicitly enabled
|
|
21
|
+
- `governance.require_auto_on_plan=true` blocks `--no-spec-governance` bypass unless explicitly enabled
|
|
22
|
+
- Spec governance and related-spec lookup now read scene override mappings from `.sce/spec-governance/spec-scene-overrides.json`.
|
|
23
|
+
- Takeover/adoption baseline now provisions the stricter intake policy and backfill defaults.
|
|
24
|
+
|
|
25
|
+
## [3.5.0] - 2026-03-02
|
|
26
|
+
|
|
27
|
+
### Added
|
|
28
|
+
- Studio automatic intake + spec governance baseline:
|
|
29
|
+
- new policy: `.sce/config/studio-intake-policy.json` (template/adopt/takeover managed)
|
|
30
|
+
- `studio plan` now auto-detects goal intent and resolves spec by bind/create strategy
|
|
31
|
+
- new commands:
|
|
32
|
+
- `sce studio intake`
|
|
33
|
+
- `sce studio portfolio`
|
|
34
|
+
- plan stage now auto-writes scene portfolio governance artifacts:
|
|
35
|
+
- `.sce/spec-governance/scene-portfolio.latest.json`
|
|
36
|
+
- `.sce/spec-governance/scene-index.json`
|
|
37
|
+
- New intake/governance module:
|
|
38
|
+
- `lib/studio/spec-intake-governor.js`
|
|
39
|
+
- scene-level duplicate/overflow/stale spec governance summary for portfolio management
|
|
40
|
+
|
|
41
|
+
### Changed
|
|
42
|
+
- Takeover/adoption managed config baseline now includes `config/studio-intake-policy.json` by default.
|
|
43
|
+
- README/README.zh/command reference updated for auto intake and scene-organized spec governance workflow.
|
|
44
|
+
|
|
10
45
|
## [3.4.6] - 2026-03-02
|
|
11
46
|
|
|
12
47
|
### Added
|
package/README.md
CHANGED
|
@@ -26,6 +26,7 @@ SCE is designed for teams that want AI agents to deliver software end-to-end wit
|
|
|
26
26
|
| Capability | What SCE Provides | Outcome |
|
|
27
27
|
| --- | --- | --- |
|
|
28
28
|
| Scene + Spec model | Scene-governed sessions and Spec lifecycle (`requirements/design/tasks`) | Stable context across long AI runs |
|
|
29
|
+
| Auto intake + Spec governance | Goal intent detection, auto spec bind/create, scene portfolio governance | Automatic scene-to-spec tracking with bounded spec growth |
|
|
29
30
|
| Studio workflow | `studio plan -> generate -> apply -> verify -> release` | Structured chat-to-release execution |
|
|
30
31
|
| Autonomous delivery | `auto close-loop`, `close-loop-program`, `close-loop-controller` | Unattended bounded convergence |
|
|
31
32
|
| Multi-agent orchestration | DAG scheduling, retries, 429 adaptive parallel control | Reliable parallel execution at scale |
|
|
@@ -106,6 +107,9 @@ SCE now enforces a domain-closed diagnosis and repair route by default:
|
|
|
106
107
|
Hard rule defaults:
|
|
107
108
|
- After two failed rounds on the same problem fingerprint, debug evidence is required in subsequent attempts.
|
|
108
109
|
- `studio verify/release` run `problem-closure-gate` by default when a spec is bound.
|
|
110
|
+
- `studio plan` auto-runs goal intake (`bind existing spec` or `create spec`) and writes scene portfolio governance snapshots by default.
|
|
111
|
+
- `studio plan --manual-spec` and `--no-spec-governance` are blocked by default policy; use policy overrides only when absolutely necessary.
|
|
112
|
+
- Historical specs can be scene-governed incrementally via `sce studio backfill-spec-scenes --apply` (writes `.sce/spec-governance/spec-scene-overrides.json`).
|
|
109
113
|
|
|
110
114
|
---
|
|
111
115
|
|
|
@@ -128,6 +132,8 @@ SCE is tool-agnostic and works with Codex, Claude Code, Cursor, Windsurf, VS Cod
|
|
|
128
132
|
|
|
129
133
|
## Important Version Changes
|
|
130
134
|
|
|
135
|
+
- `3.5.1`: Enforced stricter Studio intake defaults (`--manual-spec` and `--no-spec-governance` blocked unless policy override), added historical spec scene backfill command (`sce studio backfill-spec-scenes`) and persisted override mapping (`.sce/spec-governance/spec-scene-overrides.json`) for portfolio/related-spec alignment.
|
|
136
|
+
- `3.5.0`: Added Studio automatic goal intake + scene spec portfolio governance (`sce studio intake`, `sce studio portfolio`), including default intake policy baseline and governance artifacts for bounded scene spec growth.
|
|
131
137
|
- `3.4.6`: Added default `problem-closure-gate` + `problem-contract` baseline and strengthened mandatory problem evaluation dimensions (`problem_contract`/`ontology_alignment`/`convergence`) for verify/release convergence control.
|
|
132
138
|
- `3.4.5`: `git-managed-gate` now treats worktree checks as advisory in default relaxed CI mode (`CI/GITHUB_ACTIONS`, non-strict), preventing false release blocking.
|
|
133
139
|
- `3.4.4`: Added `SCE_GIT_MANAGEMENT_ALLOW_UNTRACKED=1` / `--allow-untracked`; release workflow uses it for npm publish after generating release evidence artifacts.
|
|
@@ -174,5 +180,5 @@ MIT. See [LICENSE](LICENSE).
|
|
|
174
180
|
|
|
175
181
|
---
|
|
176
182
|
|
|
177
|
-
**Version**: 3.
|
|
178
|
-
**Last Updated**: 2026-03-
|
|
183
|
+
**Version**: 3.5.1
|
|
184
|
+
**Last Updated**: 2026-03-03
|
package/README.zh.md
CHANGED
|
@@ -26,6 +26,7 @@ SCE 面向希望让 AI Agent 端到端推进交付、同时保持治理可控的
|
|
|
26
26
|
| 能力 | SCE 提供什么 | 结果 |
|
|
27
27
|
| --- | --- | --- |
|
|
28
28
|
| Scene + Spec 模型 | 场景主会话治理 + Spec 生命周期(需求/设计/任务) | 长周期 AI 上下文稳定 |
|
|
29
|
+
| 自动 intake + Spec 治理 | 目标意图识别、自动绑定/创建 spec、按 scene 组合治理 | 场景需求自动纳管,spec 增长可控 |
|
|
29
30
|
| Studio 工作流 | `studio plan -> generate -> apply -> verify -> release` | 对话到发布路径结构化 |
|
|
30
31
|
| 自动闭环交付 | `auto close-loop`、`close-loop-program`、`close-loop-controller` | 无人值守有界收敛 |
|
|
31
32
|
| 多 Agent 编排 | DAG 调度、重试、429 自适应并行 | 并行执行稳定可控 |
|
|
@@ -106,6 +107,9 @@ SCE 默认按“问题域闭环”推进诊断与修复:
|
|
|
106
107
|
默认硬规则:
|
|
107
108
|
- 同一问题指纹失败两轮后,后续尝试必须补充 debug 证据。
|
|
108
109
|
- 当 spec 绑定时,`studio verify/release` 默认执行 `problem-closure-gate`。
|
|
110
|
+
- `studio plan` 默认执行目标 intake(自动绑定已有 spec 或新建 spec),并自动写入 scene 维度的 spec 治理快照。
|
|
111
|
+
- 默认策略会阻断 `studio plan --manual-spec` 与 `--no-spec-governance`(仅在确有必要且策略显式放开时可绕过)。
|
|
112
|
+
- 历史 spec 可通过 `sce studio backfill-spec-scenes --apply` 分批回填到 scene 治理映射(写入 `.sce/spec-governance/spec-scene-overrides.json`)。
|
|
109
113
|
|
|
110
114
|
---
|
|
111
115
|
|
|
@@ -128,6 +132,8 @@ SCE 对工具无锁定,可接入 Codex、Claude Code、Cursor、Windsurf、VS
|
|
|
128
132
|
|
|
129
133
|
## 重要版本变更
|
|
130
134
|
|
|
135
|
+
- `3.5.1`:默认强化 Studio intake 治理(`--manual-spec`、`--no-spec-governance` 在未显式放开策略时会被阻断),新增历史 spec 场景回填命令 `sce studio backfill-spec-scenes`,并写入 `.sce/spec-governance/spec-scene-overrides.json` 以统一 portfolio 与 related-spec 的场景映射。
|
|
136
|
+
- `3.5.0`:新增 Studio 目标自动 intake + 场景 spec 组合治理(`sce studio intake`、`sce studio portfolio`),并默认启用 intake 策略基线与治理快照产物,控制场景内 spec 无序增长。
|
|
131
137
|
- `3.4.6`:新增默认 `problem-closure-gate` + `problem-contract` 基线,并强化问题评估强制维度(`problem_contract`/`ontology_alignment`/`convergence`),提升 verify/release 收敛控制。
|
|
132
138
|
- `3.4.5`:`git-managed-gate` 在默认 CI 放宽模式下(`CI/GITHUB_ACTIONS` 且非 strict)对工作区变更改为告警,不再误阻断发布。
|
|
133
139
|
- `3.4.4`:新增 `SCE_GIT_MANAGEMENT_ALLOW_UNTRACKED=1` / `--allow-untracked`;发布工作流在 npm publish 前生成证据资产时可放行未跟踪文件。
|
|
@@ -174,5 +180,5 @@ MIT,见 [LICENSE](LICENSE)。
|
|
|
174
180
|
|
|
175
181
|
---
|
|
176
182
|
|
|
177
|
-
**版本**:3.
|
|
178
|
-
**最后更新**:2026-03-
|
|
183
|
+
**版本**:3.5.1
|
|
184
|
+
**最后更新**:2026-03-03
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
> Quick reference for all `sce` commands
|
|
4
4
|
|
|
5
|
-
**Version**: 3.
|
|
5
|
+
**Version**: 3.5.0
|
|
6
6
|
**Last Updated**: 2026-03-02
|
|
7
7
|
|
|
8
8
|
---
|
|
@@ -524,6 +524,11 @@ sce studio plan --scene scene.customer-order-inventory --from-chat session-20260
|
|
|
524
524
|
# Recommended: bind spec explicitly so Studio can ingest problem-domain-chain deterministically
|
|
525
525
|
sce studio plan --scene scene.customer-order-inventory --spec 01-00-customer-order-inventory --from-chat session-20260226 --goal "customer+order+inventory demo" --json
|
|
526
526
|
|
|
527
|
+
# Analyze intake decision only (no write by default)
|
|
528
|
+
sce studio intake --scene scene.customer-order-inventory --from-chat session-20260226 --goal "optimize checkout retry flow" --json
|
|
529
|
+
# Apply intake and create spec when decision is create_spec
|
|
530
|
+
sce studio intake --scene scene.customer-order-inventory --from-chat session-20260226 --goal "optimize checkout retry flow" --apply --json
|
|
531
|
+
|
|
527
532
|
# Generate patch bundle metadata (scene is inherited from plan)
|
|
528
533
|
sce studio generate --target 331 --json
|
|
529
534
|
# Optional explicit scene check (must match planned scene)
|
|
@@ -549,15 +554,36 @@ sce studio events --job <job-id> --limit 50 --json
|
|
|
549
554
|
# Rollback a job after apply/release
|
|
550
555
|
sce studio rollback --job <job-id> --reason "manual-check-failed" --json
|
|
551
556
|
|
|
557
|
+
# Build scene-organized spec governance portfolio
|
|
558
|
+
sce studio portfolio --json
|
|
559
|
+
sce studio portfolio --scene scene.customer-order-inventory --strict --json
|
|
560
|
+
|
|
561
|
+
# Backfill historical spec scene bindings into override map (active-only by default)
|
|
562
|
+
sce studio backfill-spec-scenes --apply --json
|
|
563
|
+
# Backfill a bounded batch from unassigned scene and refresh governance snapshot
|
|
564
|
+
sce studio backfill-spec-scenes --scene scene.unassigned --limit 20 --apply --json
|
|
565
|
+
|
|
552
566
|
# Enforce authorization for a protected action
|
|
553
567
|
SCE_STUDIO_REQUIRE_AUTH=1 SCE_STUDIO_AUTH_PASSWORD=top-secret sce studio apply --job <job-id> --auth-password top-secret --json
|
|
554
568
|
```
|
|
555
569
|
|
|
556
570
|
Stage guardrails are enforced by default:
|
|
557
571
|
- `plan` requires `--scene`; SCE binds one active primary session per scene
|
|
572
|
+
- `plan` runs auto intake by default (`.sce/config/studio-intake-policy.json`):
|
|
573
|
+
- detect goal intent (`change_request` vs `analysis_only`)
|
|
574
|
+
- resolve spec via explicit binding / scene latest / related specs / auto-create
|
|
575
|
+
- auto-create spec artifacts when no suitable spec is found and policy requires tracking
|
|
576
|
+
- `plan --manual-spec` is blocked by default (`allow_manual_spec_override=false`)
|
|
577
|
+
- `plan --no-spec-governance` is blocked by default (`governance.require_auto_on_plan=true`)
|
|
558
578
|
- `plan --spec <id>` (recommended) ingests `.sce/specs/<spec>/custom/problem-domain-chain.json` into studio job context
|
|
559
579
|
- when `--spec` is omitted, `plan` auto-resolves the latest matching spec chain by `scene_id` when available
|
|
560
580
|
- `plan` auto-searches related historical specs by `scene + goal` and writes top candidates into job metadata (`source.related_specs`)
|
|
581
|
+
- `plan` auto-runs scene spec governance snapshot and writes:
|
|
582
|
+
- `.sce/spec-governance/scene-portfolio.latest.json`
|
|
583
|
+
- `.sce/spec-governance/scene-index.json`
|
|
584
|
+
- historical spec scene backfill can be managed via:
|
|
585
|
+
- `sce studio backfill-spec-scenes --apply`
|
|
586
|
+
- writes `.sce/spec-governance/spec-scene-overrides.json`
|
|
561
587
|
- successful `release` auto-archives current scene session and auto-opens the next scene cycle session
|
|
562
588
|
- `generate` requires `plan`
|
|
563
589
|
- `generate` consumes the plan-stage domain-chain context and writes chain-aware metadata/report (`.sce/reports/studio/generate-<job-id>.json`)
|
|
@@ -632,6 +658,32 @@ Default policy file (recommended to commit): `.sce/config/studio-security.json`
|
|
|
632
658
|
}
|
|
633
659
|
```
|
|
634
660
|
|
|
661
|
+
Studio intake policy file (default, recommended to commit): `.sce/config/studio-intake-policy.json`
|
|
662
|
+
|
|
663
|
+
```json
|
|
664
|
+
{
|
|
665
|
+
"enabled": true,
|
|
666
|
+
"auto_create_spec": true,
|
|
667
|
+
"force_spec_for_studio_plan": true,
|
|
668
|
+
"allow_manual_spec_override": false,
|
|
669
|
+
"prefer_existing_scene_spec": true,
|
|
670
|
+
"related_spec_min_score": 45,
|
|
671
|
+
"governance": {
|
|
672
|
+
"auto_run_on_plan": true,
|
|
673
|
+
"require_auto_on_plan": true,
|
|
674
|
+
"max_active_specs_per_scene": 3,
|
|
675
|
+
"stale_days": 14,
|
|
676
|
+
"duplicate_similarity_threshold": 0.66
|
|
677
|
+
},
|
|
678
|
+
"backfill": {
|
|
679
|
+
"enabled": true,
|
|
680
|
+
"active_only_default": true,
|
|
681
|
+
"default_scene_id": "scene.sce-core",
|
|
682
|
+
"override_file": ".sce/spec-governance/spec-scene-overrides.json"
|
|
683
|
+
}
|
|
684
|
+
}
|
|
685
|
+
```
|
|
686
|
+
|
|
635
687
|
### Capability Matrix Utilities
|
|
636
688
|
|
|
637
689
|
```bash
|
|
@@ -120,6 +120,7 @@ class AdoptionStrategy {
|
|
|
120
120
|
'config/spec-domain-policy.json',
|
|
121
121
|
'config/problem-eval-policy.json',
|
|
122
122
|
'config/problem-closure-policy.json',
|
|
123
|
+
'config/studio-intake-policy.json',
|
|
123
124
|
'specs/SPEC_WORKFLOW_GUIDE.md',
|
|
124
125
|
'hooks/sync-tasks-on-edit.sce.hook',
|
|
125
126
|
'hooks/check-spec-on-create.sce.hook',
|
|
@@ -169,6 +169,7 @@ class DetectionEngine {
|
|
|
169
169
|
'config/spec-domain-policy.json',
|
|
170
170
|
'config/problem-eval-policy.json',
|
|
171
171
|
'config/problem-closure-policy.json',
|
|
172
|
+
'config/studio-intake-policy.json',
|
|
172
173
|
'README.md',
|
|
173
174
|
'ultrawork-application-guide.md',
|
|
174
175
|
'ultrawork-integration-summary.md',
|
|
@@ -70,7 +70,8 @@ class FileClassifier {
|
|
|
70
70
|
'config/session-governance.json',
|
|
71
71
|
'config/spec-domain-policy.json',
|
|
72
72
|
'config/problem-eval-policy.json',
|
|
73
|
-
'config/problem-closure-policy.json'
|
|
73
|
+
'config/problem-closure-policy.json',
|
|
74
|
+
'config/studio-intake-policy.json'
|
|
74
75
|
];
|
|
75
76
|
|
|
76
77
|
// Generated directory patterns
|