kiro-spec-engine 1.46.2 → 1.47.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 +102 -0
- package/README.md +65 -5
- package/README.zh.md +62 -1
- package/bin/kiro-spec-engine.js +4 -0
- package/docs/OFFLINE_INSTALL.md +68 -138
- package/docs/README.md +29 -9
- package/docs/autonomous-control-guide.md +291 -0
- package/docs/command-reference.md +355 -1
- package/docs/faq.md +3 -3
- package/docs/quick-start.md +40 -1
- package/docs/release-checklist.md +100 -0
- package/docs/releases/README.md +13 -0
- package/docs/releases/v1.46.2-validation.md +45 -0
- package/docs/releases/v1.46.2.md +50 -0
- package/docs/troubleshooting.md +4 -4
- package/docs/value-observability-guide.md +127 -0
- package/docs/zh/README.md +49 -9
- package/docs/zh/quick-start.md +45 -8
- package/docs/zh/release-checklist.md +100 -0
- package/docs/zh/releases/README.md +13 -0
- package/docs/zh/releases/v1.46.2-validation.md +45 -0
- package/docs/zh/releases/v1.46.2.md +50 -0
- package/docs/zh/value-observability-guide.md +127 -0
- package/lib/auto/close-loop-runner.js +1630 -0
- package/lib/auto/goal-decomposer.js +278 -0
- package/lib/auto/semantic-decomposer.js +137 -0
- package/lib/commands/auto.js +5845 -1
- package/lib/commands/orchestrate.js +46 -2
- package/lib/commands/value.js +569 -0
- package/lib/commands/watch.js +132 -17
- package/lib/governance/archive-tool.js +59 -6
- package/lib/orchestrator/agent-spawner.js +17 -7
- package/lib/repo/output-formatter.js +3 -0
- package/lib/utils/validation.js +26 -8
- package/lib/value/gate-summary-emitter.js +99 -0
- package/lib/value/metric-contract-loader.js +210 -0
- package/lib/value/risk-evaluator.js +117 -0
- package/lib/value/weekly-snapshot-builder.js +61 -0
- package/locales/en.json +2 -2
- package/locales/zh.json +2 -2
- package/package.json +10 -3
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,108 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
### Added
|
|
11
|
+
- **KPI sample generator command**: Added `kse value metrics sample` to generate a ready-to-use KPI input JSON scaffold (`kpi-input.json`) for first-time observability runs.
|
|
12
|
+
- **Value observability documentation track**: Added dedicated EN/ZH guides for KPI snapshot/baseline/trend workflow (`docs/value-observability-guide.md`, `docs/zh/value-observability-guide.md`) and wired entry links from README + docs indexes for faster discovery of measurable delivery capabilities.
|
|
13
|
+
- **Release communication assets**: Added bilingual v1.46.2 release notes (`docs/releases/v1.46.2.md`, `docs/zh/releases/v1.46.2.md`) and a reusable pre-release checklist (`docs/release-checklist.md`).
|
|
14
|
+
- **Release validation artifacts**: Added release-readiness evidence reports in EN/ZH (`docs/releases/v1.46.2-validation.md`, `docs/zh/releases/v1.46.2-validation.md`) with test and package dry-run results.
|
|
15
|
+
- **Release archive indexes**: Added release archive index pages (`docs/releases/README.md`, `docs/zh/releases/README.md`) and wired links from documentation indexes for faster release artifact discovery.
|
|
16
|
+
- **Value metrics helper test coverage**: Added deterministic tests for ISO week period derivation and sample payload structure in command-level unit tests.
|
|
17
|
+
- **Spec 115 quality hardening program**: Added a master/sub-spec collaboration portfolio (`115-00` + `115-01..115-04`) to parallelize CI trust, Jest open-handle governance, watch follow completion, and doc link canonicalization.
|
|
18
|
+
- **Test governance scripts**: Added `test:smoke`, `test:full`, `test:handles`, `test:skip-audit`, plus `scripts/check-skip-allowlist.js` and `tests/skip-allowlist.txt` for skip-test regression guardrails.
|
|
19
|
+
- **Autonomous close-loop command**: Added `kse auto close-loop "<goal>"` to perform one-command goal decomposition (master/sub specs), collaboration bootstrap, and orchestration until terminal state.
|
|
20
|
+
- **Definition-of-Done gates for close-loop**: Added configurable completion gates for `kse auto close-loop` (`--dod-tests`, `--dod-tasks-closed`, `--no-dod*`) so autonomous runs only report success when required evidence checks pass.
|
|
21
|
+
- **DoD evidence archive for close-loop**: Added automatic DoD report persistence to `.kiro/specs/<master>/custom/dod-report.json` with CLI controls (`--dod-report`, `--no-dod-report`) for audit-ready closure evidence.
|
|
22
|
+
- **Close-loop session resume**: Added session snapshot persistence for `kse auto close-loop` (`.kiro/auto/close-loop-sessions`) plus resume controls (`--resume`, `--session-id`, `--no-session`) to continue interrupted master/sub executions.
|
|
23
|
+
- **Close-loop session hygiene commands**: Added `kse auto session list` and `kse auto session prune` (retention + age filters + dry-run/json) so long-running autonomous programs can maintain session archives without manual file cleanup.
|
|
24
|
+
- **Spec directory retention commands**: Added `kse auto spec-session list|prune` (retention + age filters + dry-run/json) to control `.kiro/specs` growth for continuous autonomous runs.
|
|
25
|
+
- **Active spec protection in retention prune**: `kse auto spec-session prune` now protects active/recently referenced specs by default (`--no-protect-active` to override).
|
|
26
|
+
- **Automatic spec retention policy for program/batch/recover**: Added `--spec-session-keep` / `--spec-session-older-than-days` (`--no-spec-session-protect-active` optional) so autonomous multi-goal runs can auto-prune `.kiro/specs` after execution.
|
|
27
|
+
- **Configurable spec protection window**: Added `--spec-session-protect-window-days` (and `spec-session prune --protect-window-days`) so teams can tune recent-reference protection horizon for retention safety.
|
|
28
|
+
- **Spec protection reason observability**: `spec-session prune` now emits `protection_ranking_top` by default and supports `--show-protection-reasons` for per-spec reason detail (`protected_specs[*].reasons`, `protection_ranking`) during retention audits.
|
|
29
|
+
- **Spec directory budget guardrail**: Added `--spec-session-max-total` with optional `--spec-session-budget-hard-fail` for batch/program/recover flows, including `spec_session_budget` telemetry in summaries to prevent uncontrolled `.kiro/specs` growth.
|
|
30
|
+
- **Unified program budget gate**: Added `--program-max-elapsed-minutes`, `--program-max-agent-budget`, and `--program-max-total-sub-specs` so `close-loop-program` convergence gate can enforce time/concurrency/sub-spec budgets together with success/risk policy.
|
|
31
|
+
- **Program/recover gate policy parity + auto-remediation hooks**: `close-loop-recover` now supports the same gate/fallback/budget policy flags as program mode and can emit `program_gate_auto_remediation` (auto patch/prune hints) when gate/budget checks fail.
|
|
32
|
+
- **Spec growth/duplicate guardrails**: Added `--spec-session-max-created`, `--spec-session-max-created-per-goal`, and `--spec-session-max-duplicate-goals` (with hard-fail option) plus summary telemetry (`goal_input_guard`, `spec_session_growth_guard`) to reduce runaway autonomous portfolio expansion.
|
|
33
|
+
- **Autonomous KPI trend command**: Added `kse auto kpi trend` to aggregate weekly success/completion, failure, sub-spec, and spec-growth telemetry from persisted autonomous summary sessions.
|
|
34
|
+
- **Autonomous KPI trend period/csv/anomaly enhancement**: Extended `kse auto kpi trend` with `--period week|day`, `--csv` export mode, and JSON anomaly diagnostics (`anomaly_detection`, `anomalies`) for latest-period regression checks.
|
|
35
|
+
- **Close-loop multi-goal batch command**: Added `kse auto close-loop-batch <goals-file>` with file-format autodetect (`json|lines`), `--continue-on-error`, and per-goal summary output so autonomous master/sub execution can scale across multiple goals in one run.
|
|
36
|
+
- **Close-loop batch global scheduler**: Added `--batch-parallel` (`1-20`) to execute multiple goals concurrently in `close-loop-batch`, enabling master/sub portfolios to progress in parallel without manual orchestration handoffs.
|
|
37
|
+
- **Close-loop batch resume from summary**: Added `--resume-from-summary <path>` to recover pending goals from a prior batch run and continue autonomous delivery without rebuilding the entire goal queue manually.
|
|
38
|
+
- **Close-loop batch resume strategy selector**: Added `--resume-strategy pending|failed-only` so operators can choose whether summary resume should include unprocessed goals (`pending`) or only failed/error goals (`failed-only`).
|
|
39
|
+
- **Close-loop batch global agent budget**: Added `--batch-agent-budget` and `resource_plan` output so multi-goal autonomous runs can enforce a shared concurrency budget with automatic per-goal `maxParallel` throttling.
|
|
40
|
+
- **Close-loop batch complexity-weighted scheduler**: Added weighted slot scheduling (`goal_weight`/`scheduling_weight`) under batch budget mode so higher-complexity goals consume more shared budget and automatically lower same-batch concurrency.
|
|
41
|
+
- **Close-loop batch priority + aging scheduler controls**: Added `--batch-priority` (`fifo|complex-first|complex-last`) and `--batch-aging-factor` (`0-100`) with `resource_plan` wait/starvation telemetry so autonomous multi-goal runs can tune ordering and fairness without manual intervention.
|
|
42
|
+
- **Close-loop batch program decomposition mode**: Added `--decompose-goal` + `--program-goals` so one broad goal can be auto-split into multiple batch goals and executed as a master batch without manually authoring a goals file.
|
|
43
|
+
- **Close-loop batch automatic retry rounds**: Added `--batch-retry-rounds` + `--batch-retry-strategy` (`adaptive|strict`) with `batch_retry` summary telemetry so failed/stopped goals can be retried in the same autonomous batch run without manual re-invocation.
|
|
44
|
+
- **Close-loop batch session archive + latest resume**: Added automatic batch summary session persistence (`.kiro/auto/close-loop-batch-summaries`) with controls (`--batch-session-id`, `--batch-session-keep`, `--no-batch-session`) and support for `--resume-from-summary latest`.
|
|
45
|
+
- **Close-loop batch session maintenance commands**: Added `kse auto batch-session list` / `kse auto batch-session prune` plus age-based retention control (`--batch-session-older-than-days`) for persisted batch summary archives.
|
|
46
|
+
- **Close-loop batch until-complete retry mode**: Added `--batch-retry-until-complete` + `--batch-retry-max-rounds` so multi-goal runs can auto-drain failed/stopped goals to completion within one command invocation under bounded retry policy.
|
|
47
|
+
- **Close-loop batch autonomous policy mode**: Added `--batch-autonomous` to apply closed-loop defaults automatically (continue-on-error, adaptive parallelism, complexity-first scheduling, aging boost, retry-until-complete) for hands-off program execution.
|
|
48
|
+
- **Close-loop program command**: Added `kse auto close-loop-program "<goal>"` to auto-decompose one broad objective into multi-goal autonomous execution (master/sub portfolios) with closed-loop batch policy enabled by default.
|
|
49
|
+
- **Close-loop program KPI snapshot**: Added `program_kpi` in `close-loop-program` summary plus `--program-kpi-out` for standalone KPI export (convergence state, risk level, retry recovery, complexity/wait profile).
|
|
50
|
+
- **Close-loop program convergence gate + audit output**: Added policy gates (`--program-min-success-rate`, `--program-max-risk-level`) plus `--program-audit-out` for governance-grade audit JSON; program exits non-zero when gate policy is not met.
|
|
51
|
+
- **Close-loop program gate profiles**: Added `--program-gate-profile` (`default|dev|staging|prod`) so teams can switch convergence policy baselines by environment while still allowing explicit threshold overrides.
|
|
52
|
+
- **Close-loop program gate fallback tier**: Added `--program-gate-fallback-profile` (`none|default|dev|staging|prod`) so gate evaluation can use a controlled fallback policy tier when the primary gate fails.
|
|
53
|
+
- **Close-loop program gate fallback chain**: Added `--program-gate-fallback-chain <profiles>` so gate evaluation can try multiple fallback policy profiles in order after primary gate failure.
|
|
54
|
+
- **Close-loop program recovery time budget**: Added `--program-recover-max-minutes` so built-in auto recovery loops can stop on elapsed-time limits, with `recovery_cycle` budget telemetry.
|
|
55
|
+
- **Close-loop program remediation diagnostics**: Added `program_diagnostics` (`failure_clusters` + prioritized `remediation_actions`) to turn program KPI output into actionable convergence guidance.
|
|
56
|
+
- **Close-loop recovery command**: Added `kse auto close-loop-recover [summary]` with remediation-action selection (`--use-action`) to automatically replay unresolved goals using strategy patches derived from diagnostics.
|
|
57
|
+
- **Close-loop recovery self-healing rounds**: Added `--recover-until-complete` + `--recover-max-rounds` with `recovery_cycle` history so recovery can run multiple rounds autonomously until convergence or bounded exhaustion.
|
|
58
|
+
- **Close-loop recovery time/memory governance**: Added `--recover-max-minutes` and `--recovery-memory-ttl-days` so recovery loops can enforce elapsed-time budgets and stale-memory pruning during action selection.
|
|
59
|
+
- **Recovery memory lifecycle commands**: Added `kse auto recovery-memory show|prune|clear` to inspect, prune, and reset persisted recovery strategy memory.
|
|
60
|
+
- **Recovery memory scope analytics command**: Added `kse auto recovery-memory scopes` to inspect aggregate recovery-memory statistics grouped by scope.
|
|
61
|
+
- **Criticality-priority scheduler mode**: Added `--batch-priority critical-first` with per-goal criticality telemetry in `resource_plan` and result summaries.
|
|
62
|
+
- **Goal decomposition quality diagnostics**: Added `generated_from_goal.quality` (score, coverage ratio, warnings) for program/batch semantic decomposition observability.
|
|
63
|
+
- **Goal decomposition quality auto-refinement**: Added `--program-min-quality-score` with automatic second-pass goal refinement and `quality.refinement` telemetry, so weak decompositions are improved before execution.
|
|
64
|
+
- **Goal decomposition hard quality gate**: Added `--program-quality-gate` to fail execution when final decomposition quality remains below threshold after refinement.
|
|
65
|
+
- **Recovery memory scope isolation + explainability**: Added `--recovery-memory-scope` and selection explanation metadata (`selection_explain`) so remediation memory can be isolated by scope and action selection is auditable.
|
|
66
|
+
- **Scoped recovery memory maintenance**: `kse auto recovery-memory show|prune` now support `--scope <scope>` for targeted inspection and cleanup.
|
|
67
|
+
- **Program gate fallback observability**: Program outputs now include `program_gate_fallbacks` and `program_gate_effective` fields for full fallback decision traceability.
|
|
68
|
+
- **Program-level auto recovery loop**: `kse auto close-loop-program` now auto-enters bounded recovery rounds by default (`--program-recover-max-rounds`, `--no-program-auto-recover`) so one command can drive program execution to closure without manual follow-up.
|
|
69
|
+
- **Recovery strategy memory**: Added persisted recovery memory (`.kiro/auto/close-loop-recovery-memory.json`) so `close-loop-recover` and program auto-recovery can reuse previously successful remediation actions when `--use-action` is omitted.
|
|
70
|
+
- **Program coordination telemetry**: Added `program_coordination` output (master/sub topology, unresolved goals, scheduler snapshot) for multi-spec orchestration observability in both program and recover summaries.
|
|
71
|
+
- **Close-loop batch KPI summary**: Added aggregate `metrics` in batch output (success rate, status breakdown, average sub-spec count, average replan cycles) for portfolio-level observability.
|
|
72
|
+
- **Close-loop auto session retention policy**: Added `--session-keep` and `--session-older-than-days` to `kse auto close-loop` so each autonomous run can prune stale session snapshots automatically.
|
|
73
|
+
- **Automatic replan loop for close-loop failures**: Added remediation replan cycles (`--replan-attempts`, `--no-replan`) so failed orchestration runs can auto-generate recovery specs and retry autonomously.
|
|
74
|
+
- **Replan stall guard**: Added failed-spec signature deduplication so close-loop auto-replan stops early when the same failure set repeats, preventing low-value remediation loops.
|
|
75
|
+
- **Replan no-progress stall guard**: Added `--replan-no-progress-window` so close-loop retries terminate when consecutive failed cycles show no net progress, improving autonomous convergence and reducing retry noise.
|
|
76
|
+
- **Goal decomposition engine**: Added heuristic portfolio planner for automatic sub-spec splitting, dependency wiring, and deterministic spec prefix allocation.
|
|
77
|
+
- **Complex-goal auto-split scaling**: Enhanced decomposition heuristic to auto-escalate sub-spec count up to 5 for high-complexity goals, strengthening master/sub parallel delivery for larger feature sets.
|
|
78
|
+
- **Autonomous close-loop tests**: Added unit coverage for decomposition strategy and close-loop runner behavior (plan-only and execution paths).
|
|
79
|
+
- **Autonomous CLI end-to-end regression**: Added integration coverage for `kse auto close-loop --resume latest`, `kse auto close-loop-batch --dry-run --json`, and `kse auto session list/prune` via real `bin/kiro-spec-engine.js` execution.
|
|
80
|
+
- **Program gate fallback-chain integration fixture**: Added deterministic non-dry-run CLI integration coverage for primary-gate failure + fallback-chain acceptance to harden convergence policy regression checks.
|
|
81
|
+
- **Spec 116 autonomous-closure portfolio**: Added `116-00` master with `116-01..116-03` sub-specs as a live master/sub example generated through the close-loop workflow, including `custom/agent-sync-plan.md`.
|
|
82
|
+
- **Spec 117 autonomous hardening portfolio**: Added `117-00` master with `117-01..117-04` sub-specs to continue parallel delivery on no-confirmation closed-loop execution, master/sub decomposition, orchestration runtime, and observability gates.
|
|
83
|
+
- **Spec 118 resilience/replan portfolio**: Added `118-00` master with `118-01..118-04` sub-specs for interrupted-session resume and dynamic master/sub dependency replanning hardening.
|
|
84
|
+
- **Spec 119 dynamic-replanning portfolio**: Added `119-00` master with `119-01..119-04` sub-specs to drive remediation-spec generation and autonomous continuation after orchestration failures.
|
|
85
|
+
- **Spec 120 replan-governance portfolio**: Added `120-00` master with `120-01..120-04` sub-specs to enforce adaptive replan policy, remediation spec governance, and autonomous convergence hardening.
|
|
86
|
+
- **Semantic decomposition engine**: Added clause/category analysis (`semantic-decomposer`) and integrated it into portfolio planning for mixed-language goals.
|
|
87
|
+
- **Live orchestration status streaming**: Added event/interval-driven status persistence callback support in `runOrchestration()` and wired `auto close-loop` live progress output (`--no-stream` to disable).
|
|
88
|
+
|
|
89
|
+
### Changed
|
|
90
|
+
- **Positioning and onboarding messaging**: Strengthened EN/ZH README and quick-start docs with explicit kse advantage matrix, 90-second value proof, and KPI observability positioning to improve first-contact clarity.
|
|
91
|
+
- **CLI first-screen positioning text**: Updated `kse --help` top description in EN/ZH locales to reflect current core strengths: Spec workflow, orchestration, and KPI observability.
|
|
92
|
+
- **Offline onboarding consistency**: Refreshed `START_HERE.txt`, `INSTALL_OFFLINE.txt`, and `docs/OFFLINE_INSTALL.md` to v1.46.2 guidance and aligned quick-start prerequisites with current runtime requirement (Node.js >= 16).
|
|
93
|
+
- **Value metrics operator guidance**: Enhanced snapshot/baseline/trend failure messages with actionable follow-up commands (including `kse value metrics sample`) to reduce first-run friction.
|
|
94
|
+
- **Top-level release navigation**: Updated EN/ZH root READMEs to expose release archive and validation report links directly from Advanced Topics for faster proof-of-value discovery.
|
|
95
|
+
- **Observability guide usability**: Added EN/ZH expected JSON output examples for `snapshot --json` and `trend --json` to speed up first-run verification and integration scripting.
|
|
96
|
+
- **Watch log operator flow**: Implemented `kse watch logs --follow` streaming behavior and documented follow examples in command reference.
|
|
97
|
+
- **Canonical documentation links**: Standardized mixed repository links to `https://github.com/heguangyong/kiro-spec-engine` and wired canonical-link scan commands into EN/ZH release checklists.
|
|
98
|
+
- **Autonomy positioning clarity**: Strengthened EN/ZH docs and command reference to emphasize closed-loop delivery and automatic master/sub spec decomposition as kse core strengths.
|
|
99
|
+
- **Autonomous operator UX**: Expanded docs with semantic decomposition and live stream behavior for close-loop command usage.
|
|
100
|
+
|
|
101
|
+
### Fixed
|
|
102
|
+
- **npm package hygiene**: Excluded transient Python bytecode artifacts (`__pycache__`, `*.pyc/pyo/pyd`) from published package contents to reduce package noise and size.
|
|
103
|
+
- **Documentation contact placeholders**: Replaced `yourusername` placeholder repository links in onboarding docs with the canonical project URL and removed stale example email contact.
|
|
104
|
+
- **Jest force-exit dependency**: Removed `forceExit` from `jest.config.js` and `jest.config.ci.js`; test scripts now complete without explicit force-exit configuration.
|
|
105
|
+
- **Agent termination timer leak**: `AgentSpawner._terminateProcess()` now clears both SIGKILL and safety timers on process close/settle, preventing lingering timer handles after `kill()`/`killAll()`.
|
|
106
|
+
- **Validation python-check timer leak**: `checkPythonVersion()` now clears and `unref()`s its timeout with single-settle semantics, preventing post-test open-handle warnings.
|
|
107
|
+
- **Orchestrator/unit test stability**: Reduced timer-based flakiness in orchestration property tests and aligned orchestrator integration defaults to avoid long-lived test timers.
|
|
108
|
+
- **Recovery loop action stability**: `close-loop-recover --recover-until-complete` now pins the selected remediation action from round 1, avoiding later-round `--use-action` out-of-range aborts when diagnostics action counts change.
|
|
109
|
+
- **Summary-derived goal recovery robustness**: Recovery now skips synthetic `goals_file` placeholders (for example `"(derived-from-summary)"`) when rebuilding pending goals, preventing false "goals file not found" failures in multi-round loops.
|
|
110
|
+
- **Program gate dry-run correctness**: `close-loop-program` convergence gate now derives success rate from program KPI completion rate (with fallback), preventing false gate failures in dry-run program executions.
|
|
111
|
+
|
|
10
112
|
## [1.46.2] - 2026-02-14
|
|
11
113
|
|
|
12
114
|
### Added
|
package/README.md
CHANGED
|
@@ -48,6 +48,36 @@ graph LR
|
|
|
48
48
|
- ✅ Anyone building features that need clear requirements and design
|
|
49
49
|
- ✅ Projects that benefit from spec-driven development
|
|
50
50
|
|
|
51
|
+
## Why kse Wins in AI Delivery
|
|
52
|
+
|
|
53
|
+
| Advantage | kse Capability | Practical Impact |
|
|
54
|
+
| --- | --- | --- |
|
|
55
|
+
| Structure-first execution | Requirements → Design → Tasks + gate checks | Lower rework and fewer requirement drifts |
|
|
56
|
+
| Autonomous close-loop delivery | One-command close loop (`auto close-loop`) | No step-by-step confirmation waits |
|
|
57
|
+
| Multi-agent scale-out | DAG orchestration (`orchestrate run/status/stop`) | Parallel delivery without manual terminal juggling |
|
|
58
|
+
| Auto portfolio decomposition | Master/Sub spec split + dependency wiring | Complex goals become executable parallel plans automatically |
|
|
59
|
+
| Program self-healing closure | `auto close-loop-program` auto recovery + learned remediation memory | Failed/partial runs continue autonomously until bounded convergence |
|
|
60
|
+
| Autonomous convergence governance | Program gate (`min-success-rate` + `max-risk-level`) + audit JSON output | Program completion is policy-verified and traceable |
|
|
61
|
+
| Measurable outcomes | KPI automation (`value metrics snapshot/baseline/trend`) | Delivery quality can be tracked week-over-week |
|
|
62
|
+
| Tool-agnostic adoption | Works across Claude/Cursor/Windsurf/Copilot/Kiro | No lock-in to a single AI IDE |
|
|
63
|
+
| Built-in governance | Docs governance, lock management, audit, env/workspace controls | Team collaboration stays auditable and stable |
|
|
64
|
+
|
|
65
|
+
### 90-Second Value Proof
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
# 1) Adopt kse in current repo
|
|
69
|
+
kse adopt
|
|
70
|
+
|
|
71
|
+
# 2) Generate Spec workflow draft
|
|
72
|
+
kse spec bootstrap --name 01-00-demo-feature --non-interactive
|
|
73
|
+
|
|
74
|
+
# 3) Generate KPI input sample
|
|
75
|
+
kse value metrics sample --out ./kpi-input.json --json
|
|
76
|
+
|
|
77
|
+
# 4) Produce machine-readable KPI snapshot
|
|
78
|
+
kse value metrics snapshot --input ./kpi-input.json --json
|
|
79
|
+
```
|
|
80
|
+
|
|
51
81
|
---
|
|
52
82
|
|
|
53
83
|
## Quick Start
|
|
@@ -224,6 +254,7 @@ sequenceDiagram
|
|
|
224
254
|
- 📦 **[Multi-Repository Management](docs/multi-repo-management-guide.md)** - Manage multiple Git repositories
|
|
225
255
|
- 🎭 **[Scene Runtime](docs/scene-runtime-guide.md)** - Template engine, quality pipeline, ontology, Moqui ERP
|
|
226
256
|
- 🤖 **[Multi-Agent Coordination](docs/multi-agent-coordination-guide.md)** - Parallel agent coordination
|
|
257
|
+
- 📈 **[Value Observability](docs/value-observability-guide.md)** - KPI snapshot, baseline, trend, gate-ready evidence
|
|
227
258
|
- 🔌 **[Integration Modes](docs/integration-modes.md)** - Three ways to integrate kse
|
|
228
259
|
- 📝 **[Command Reference](docs/command-reference.md)** - All kse commands
|
|
229
260
|
|
|
@@ -243,6 +274,10 @@ sequenceDiagram
|
|
|
243
274
|
### Advanced Topics
|
|
244
275
|
- [Adoption Guide](docs/adoption-guide.md) - Adopting kse in existing projects
|
|
245
276
|
- [Upgrade Guide](docs/upgrade-guide.md) - Version upgrade instructions
|
|
277
|
+
- [Release Archive](docs/releases/README.md) - Versioned release notes and validation report index
|
|
278
|
+
- [Release Notes v1.46.2](docs/releases/v1.46.2.md) - Current release highlights and impact
|
|
279
|
+
- [Validation Report v1.46.2](docs/releases/v1.46.2-validation.md) - Release-readiness evidence and verification results
|
|
280
|
+
- [Release Checklist](docs/release-checklist.md) - Repeatable pre-release verification flow
|
|
246
281
|
- [Manual Workflows](docs/manual-workflows-guide.md) - Step-by-step workflows
|
|
247
282
|
- [Developer Guide](docs/developer-guide.md) - Contributing and extending kse
|
|
248
283
|
|
|
@@ -255,6 +290,10 @@ sequenceDiagram
|
|
|
255
290
|
|
|
256
291
|
### Autonomous Control 🚀 NEW in v1.23.0
|
|
257
292
|
- **Fully Autonomous Execution**: AI independently manages entire development workflows from requirements to delivery
|
|
293
|
+
- **Closed-Loop Program Execution**: `kse auto close-loop "<goal>"` runs from goal decomposition to terminal orchestration state without manual confirmation gates
|
|
294
|
+
- **Automatic Master/Sub Portfolio Split**: Large goals are auto-split into dependency-wired sub-specs and coordinated by a master spec
|
|
295
|
+
- **Semantic Decomposition + Live Stream**: Clause/category-aware goal parsing plus live orchestration status stream (disable via `--no-stream`)
|
|
296
|
+
- **Session Resume + Retention Hygiene**: Resume interrupted runs with `--resume latest` and maintain archives via `kse auto session list/prune`
|
|
258
297
|
- **Intelligent Error Recovery**: Automatically diagnose and fix errors with 3 retry attempts and learning system
|
|
259
298
|
- **Strategic Checkpoints**: Pause only at meaningful milestones (phase boundaries, fatal errors, external resources)
|
|
260
299
|
- **Continuous Task Execution**: Execute multiple tasks without interruption between individual tasks
|
|
@@ -267,6 +306,9 @@ sequenceDiagram
|
|
|
267
306
|
|
|
268
307
|
**Quick Start**:
|
|
269
308
|
```bash
|
|
309
|
+
# Decompose one broad goal into master/sub specs and run to closure
|
|
310
|
+
kse auto close-loop "build autonomous close-loop and master/sub multi-spec execution for kse"
|
|
311
|
+
|
|
270
312
|
# Create and execute a feature autonomously
|
|
271
313
|
kse auto create "user authentication with JWT tokens"
|
|
272
314
|
|
|
@@ -285,6 +327,13 @@ kse auto resume
|
|
|
285
327
|
### Spec-Driven Development
|
|
286
328
|
Structure your work with Requirements → Design → Tasks workflow
|
|
287
329
|
|
|
330
|
+
### KPI Automation & Observability 🚀 NEW in v1.46.2
|
|
331
|
+
- **Unified Metric Contract**: Load and validate KPI definitions from `metric-definition.yaml`
|
|
332
|
+
- **Weekly Snapshot Pipeline**: Generate machine-readable snapshots with risk level and audit reasons
|
|
333
|
+
- **Baseline and Trend Analysis**: Build baseline from historical data and detect worsening trends automatically
|
|
334
|
+
- **Gate-Ready Summary**: Emit Day30/Day60-consumable summary payloads with evidence paths
|
|
335
|
+
- **CLI Commands**: `value metrics sample`, `value metrics snapshot`, `value metrics baseline`, `value metrics trend` with `--json` support
|
|
336
|
+
|
|
288
337
|
### Multi-Workspace Management 🚀 NEW in v1.11.0
|
|
289
338
|
- **Workspace Registry**: Manage multiple kse projects from a single location
|
|
290
339
|
- **Quick Switching**: Switch between projects without directory navigation
|
|
@@ -479,6 +528,10 @@ English and Chinese interfaces
|
|
|
479
528
|
kse adopt # Adopt kse in existing project
|
|
480
529
|
kse create-spec <name> # Legacy: create empty Spec folder only
|
|
481
530
|
|
|
531
|
+
# Autonomous close-loop program (one command, no confirmation loop)
|
|
532
|
+
kse auto close-loop "<goal>" # Auto split goal into master/sub specs and execute to closure
|
|
533
|
+
kse auto close-loop "<goal>" --dry-run --json # Preview decomposition plan only
|
|
534
|
+
|
|
482
535
|
# Spec workflow (recommended)
|
|
483
536
|
kse spec bootstrap --name <spec> --non-interactive # Generate requirements/design/tasks draft
|
|
484
537
|
kse spec pipeline run --spec <spec> # Run staged workflow for one Spec
|
|
@@ -491,6 +544,14 @@ kse spec gate run --specs "<spec-a,spec-b>" --max-parallel <N> # Multi-Spec
|
|
|
491
544
|
kse context export <spec-name> # Export context for AI tools
|
|
492
545
|
kse prompt generate <spec> <task> # Generate task-specific prompt
|
|
493
546
|
|
|
547
|
+
# KPI automation and observability (NEW in v1.46.2)
|
|
548
|
+
kse value metrics sample --out <path> --json # Generate sample KPI input JSON
|
|
549
|
+
kse value metrics snapshot --input <path> --json # Generate weekly KPI snapshot + gate summary
|
|
550
|
+
kse value metrics baseline --from-history <N> --json # Build baseline from earliest N snapshots
|
|
551
|
+
kse value metrics trend --window <N> --json # Analyze trend/risk from latest N snapshots
|
|
552
|
+
kse auto kpi trend --weeks 8 --period week --json # Aggregate autonomous delivery KPI trend (weekly/daily buckets + anomalies)
|
|
553
|
+
kse auto kpi trend --weeks 8 --period day --csv --out <path> # Export autonomous KPI trend as CSV
|
|
554
|
+
|
|
494
555
|
# Workspace management (NEW in v1.11.0)
|
|
495
556
|
kse workspace create <name> [path] # Register a new workspace
|
|
496
557
|
kse workspace list # List all workspaces
|
|
@@ -596,9 +657,8 @@ See [Command Reference](docs/command-reference.md) for complete documentation.
|
|
|
596
657
|
### Getting Help
|
|
597
658
|
|
|
598
659
|
- 📖 **Documentation**: Start with the [Quick Start Guide](docs/quick-start.md)
|
|
599
|
-
- 🐛 **Bug Reports**: [GitHub Issues](https://github.com/
|
|
600
|
-
- 💬 **Discussions**: [GitHub Discussions](https://github.com/
|
|
601
|
-
- 📧 **Email**: support@example.com
|
|
660
|
+
- 🐛 **Bug Reports**: [GitHub Issues](https://github.com/heguangyong/kiro-spec-engine/issues)
|
|
661
|
+
- 💬 **Discussions**: [GitHub Discussions](https://github.com/heguangyong/kiro-spec-engine/discussions)
|
|
602
662
|
|
|
603
663
|
### Contributing
|
|
604
664
|
|
|
@@ -611,7 +671,7 @@ We welcome contributions! See our [Contributing Guide](CONTRIBUTING.md) for:
|
|
|
611
671
|
### Development Setup
|
|
612
672
|
|
|
613
673
|
```bash
|
|
614
|
-
git clone https://github.com/
|
|
674
|
+
git clone https://github.com/heguangyong/kiro-spec-engine.git
|
|
615
675
|
cd kiro-spec-engine
|
|
616
676
|
npm install
|
|
617
677
|
npm link # For local development
|
|
@@ -676,5 +736,5 @@ A deep conversation about AI development trends, Neo-Confucian philosophy, and s
|
|
|
676
736
|
---
|
|
677
737
|
|
|
678
738
|
**Version**: 1.46.2
|
|
679
|
-
**Last Updated**: 2026-02-
|
|
739
|
+
**Last Updated**: 2026-02-14
|
|
680
740
|
|
package/README.zh.md
CHANGED
|
@@ -46,6 +46,36 @@ graph LR
|
|
|
46
46
|
- ✅ 构建需要清晰需求和设计的功能的任何人
|
|
47
47
|
- ✅ 受益于 Spec 驱动开发的项目
|
|
48
48
|
|
|
49
|
+
## 为什么 kse 更有优势
|
|
50
|
+
|
|
51
|
+
| 优势点 | kse 能力 | 实际收益 |
|
|
52
|
+
| --- | --- | --- |
|
|
53
|
+
| 结构化先行 | 需求 → 设计 → 任务 + gate 检查 | 降低返工和需求漂移 |
|
|
54
|
+
| 自动闭环交付 | 单命令闭环(`auto close-loop`) | 不再分步骤等待人工确认 |
|
|
55
|
+
| 多 Agent 扩展 | DAG 编排(`orchestrate run/status/stop`) | 并行交付,不再手工开多终端 |
|
|
56
|
+
| 自动主从拆分 | 目标自动拆成 Master/Sub Spec 并建立依赖 | 复杂需求自动转成可并行执行计划 |
|
|
57
|
+
| 程序级自愈闭环 | `auto close-loop-program` 自动恢复 + 策略记忆 | 失败/部分失败会自动续跑,直到有界收敛 |
|
|
58
|
+
| 自治收敛治理 | Program Gate(最小成功率 + 最大风险)+ 审计 JSON 导出 | 完成结果可按策略验收且全程可追溯 |
|
|
59
|
+
| 结果可量化 | KPI 自动化(`value metrics snapshot/baseline/trend`) | 周度趋势可追踪、可审计 |
|
|
60
|
+
| 工具无锁定 | 兼容 Claude/Cursor/Windsurf/Copilot/Kiro | 团队可保留现有 AI 工具链 |
|
|
61
|
+
| 治理内建 | 文档治理、锁机制、审计、环境/工作区管理 | 协作更稳定,过程可回放 |
|
|
62
|
+
|
|
63
|
+
### 90 秒价值验证
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
# 1) 在当前仓库启用 kse
|
|
67
|
+
kse adopt
|
|
68
|
+
|
|
69
|
+
# 2) 生成 Spec 工作流草稿
|
|
70
|
+
kse spec bootstrap --name 01-00-demo-feature --non-interactive
|
|
71
|
+
|
|
72
|
+
# 3) 生成 KPI 输入样例
|
|
73
|
+
kse value metrics sample --out ./kpi-input.json --json
|
|
74
|
+
|
|
75
|
+
# 4) 产出机器可读 KPI 快照
|
|
76
|
+
kse value metrics snapshot --input ./kpi-input.json --json
|
|
77
|
+
```
|
|
78
|
+
|
|
49
79
|
---
|
|
50
80
|
|
|
51
81
|
## 快速开始
|
|
@@ -220,6 +250,7 @@ sequenceDiagram
|
|
|
220
250
|
- 📄 **[文档治理](docs/document-governance.md)** - 自动化文档管理
|
|
221
251
|
- 🎭 **[场景运行时指南](docs/scene-runtime-guide.md)** - 模板引擎、质量流水线、Ontology、Moqui ERP
|
|
222
252
|
- 🤖 **[多 Agent 协调指南](docs/multi-agent-coordination-guide.md)** - 多 Agent 并行协调
|
|
253
|
+
- 📈 **[Value 可观测指南](docs/zh/value-observability-guide.md)** - KPI 快照、基线、趋势与门禁证据
|
|
223
254
|
- 🔌 **[集成模式](docs/integration-modes.md)** - 三种集成 kse 的方式
|
|
224
255
|
- 📝 **[命令参考](docs/command-reference.md)** - 所有 kse 命令
|
|
225
256
|
|
|
@@ -239,6 +270,10 @@ sequenceDiagram
|
|
|
239
270
|
### 高级主题
|
|
240
271
|
- [采用指南](docs/adoption-guide.md) - 在现有项目中采用 kse
|
|
241
272
|
- [升级指南](docs/upgrade-guide.md) - 版本升级说明
|
|
273
|
+
- [发布归档](docs/zh/releases/README.md) - 版本化发布说明与验证报告入口
|
|
274
|
+
- [发布说明 v1.46.2](docs/zh/releases/v1.46.2.md) - 当前版本更新亮点
|
|
275
|
+
- [验证报告 v1.46.2](docs/zh/releases/v1.46.2-validation.md) - 发布就绪验证与证据结果
|
|
276
|
+
- [发布检查清单](docs/zh/release-checklist.md) - 可重复执行的发版前核验流程
|
|
242
277
|
- [手动工作流](docs/manual-workflows-guide.md) - 分步工作流
|
|
243
278
|
- [开发者指南](docs/developer-guide.md) - 贡献和扩展 kse
|
|
244
279
|
|
|
@@ -249,9 +284,23 @@ sequenceDiagram
|
|
|
249
284
|
|
|
250
285
|
## 主要功能
|
|
251
286
|
|
|
287
|
+
### Autonomous Control(自动闭环)🚀
|
|
288
|
+
- **自动闭环推进**:`kse auto close-loop "<目标>"` 从目标拆分到编排完成全程自动推进
|
|
289
|
+
- **自动主从拆分**:自动生成 Master/Sub Spec 组合、依赖关系与 Agent 分配
|
|
290
|
+
- **语义分解 + 实时状态流**:按目标语义自动归类拆分,并实时输出编排进度(可用 `--no-stream` 关闭)
|
|
291
|
+
- **会话恢复与归档治理**:支持 `--resume latest` 续跑,并可用 `kse auto session list/prune` 管理会话归档
|
|
292
|
+
- **终态收敛**:输出统一执行结果(completed/failed/stopped),避免中途等待人工逐步确认
|
|
293
|
+
|
|
252
294
|
### Spec 驱动开发
|
|
253
295
|
使用需求 → 设计 → 任务工作流结构化你的工作
|
|
254
296
|
|
|
297
|
+
### KPI 自动化与可观测 🚀 v1.46.2 新增
|
|
298
|
+
- **统一指标契约**:从 `metric-definition.yaml` 加载并校验 KPI 定义
|
|
299
|
+
- **周快照流水线**:生成包含风险级别和审计原因的 machine-readable 快照
|
|
300
|
+
- **基线与趋势分析**:基于历史快照生成 baseline,并自动识别连续恶化趋势
|
|
301
|
+
- **门禁可复用摘要**:输出 Day30/Day60 可直接消费的 summary 与证据路径
|
|
302
|
+
- **CLI 命令**:`value metrics sample`、`value metrics snapshot`、`value metrics baseline`、`value metrics trend`,支持 `--json`
|
|
303
|
+
|
|
255
304
|
### 多工作区管理 🚀 v1.11.0 新功能
|
|
256
305
|
- **工作区注册表**:从单一位置管理多个 kse 项目
|
|
257
306
|
- **快速切换**:无需目录导航即可在项目间切换
|
|
@@ -396,6 +445,10 @@ kse orchestrate stop
|
|
|
396
445
|
kse adopt # 在现有项目中采用 kse
|
|
397
446
|
kse create-spec <name> # 兼容旧版:仅创建空 Spec 目录
|
|
398
447
|
|
|
448
|
+
# 自动闭环主从编排(单命令)
|
|
449
|
+
kse auto close-loop "<目标>" # 自动拆分 Master/Sub Spec 并推进到完成态
|
|
450
|
+
kse auto close-loop "<目标>" --dry-run --json # 仅预览拆分与依赖计划
|
|
451
|
+
|
|
399
452
|
# Spec 工作流(推荐)
|
|
400
453
|
kse spec bootstrap --name <spec> --non-interactive # 生成 requirements/design/tasks 初稿
|
|
401
454
|
kse spec pipeline run --spec <spec> # 对单个 Spec 执行分阶段流程
|
|
@@ -408,6 +461,14 @@ kse spec gate run --specs "<spec-a,spec-b>" --max-parallel <N> # 多 Spec
|
|
|
408
461
|
kse context export <spec-name> # 为 AI 工具导出上下文
|
|
409
462
|
kse prompt generate <spec> <task> # 生成任务特定提示
|
|
410
463
|
|
|
464
|
+
# KPI 自动化与可观测(v1.46.2 新增)
|
|
465
|
+
kse value metrics sample --out <path> --json # 生成 KPI 输入样例 JSON
|
|
466
|
+
kse value metrics snapshot --input <path> --json # 生成周度 KPI 快照 + gate 摘要
|
|
467
|
+
kse value metrics baseline --from-history <N> --json # 从最早 N 个快照生成 baseline
|
|
468
|
+
kse value metrics trend --window <N> --json # 基于最近 N 个快照分析趋势与风险
|
|
469
|
+
kse auto kpi trend --weeks 8 --period week --json # 聚合自动交付 KPI 趋势(支持周/日桶 + 异常信号)
|
|
470
|
+
kse auto kpi trend --weeks 8 --period day --csv --out <path> # 以 CSV 导出自动 KPI 趋势
|
|
471
|
+
|
|
411
472
|
# 工作区管理(v1.11.0 新增)
|
|
412
473
|
kse workspace create <name> [path] # 注册新工作区
|
|
413
474
|
kse workspace list # 列出所有工作区
|
|
@@ -539,6 +600,6 @@ kse spec bootstrap --name 01-00-my-first-feature --non-interactive
|
|
|
539
600
|
---
|
|
540
601
|
|
|
541
602
|
**版本**:1.46.2
|
|
542
|
-
**最后更新**:2026-02-
|
|
603
|
+
**最后更新**:2026-02-14
|
|
543
604
|
|
|
544
605
|
|
package/bin/kiro-spec-engine.js
CHANGED
|
@@ -17,6 +17,7 @@ const registerCollabCommands = require('../lib/commands/collab');
|
|
|
17
17
|
const { registerSpecBootstrapCommand } = require('../lib/commands/spec-bootstrap');
|
|
18
18
|
const { registerSpecPipelineCommand } = require('../lib/commands/spec-pipeline');
|
|
19
19
|
const { registerSpecGateCommand } = require('../lib/commands/spec-gate');
|
|
20
|
+
const { registerValueCommands } = require('../lib/commands/value');
|
|
20
21
|
const VersionChecker = require('../lib/version/version-checker');
|
|
21
22
|
|
|
22
23
|
const i18n = getI18n();
|
|
@@ -657,6 +658,9 @@ registerKnowledgeCommands(program);
|
|
|
657
658
|
const { registerOrchestrateCommands } = require('../lib/commands/orchestrate');
|
|
658
659
|
registerOrchestrateCommands(program);
|
|
659
660
|
|
|
661
|
+
// Value realization and observability commands
|
|
662
|
+
registerValueCommands(program);
|
|
663
|
+
|
|
660
664
|
// Template management commands
|
|
661
665
|
const templatesCommand = require('../lib/commands/templates');
|
|
662
666
|
|
package/docs/OFFLINE_INSTALL.md
CHANGED
|
@@ -1,166 +1,96 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
# 安装依赖
|
|
23
|
-
npm install
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
3. **全局安装**
|
|
27
|
-
```bash
|
|
28
|
-
npm install -g .
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
4. **验证安装**
|
|
32
|
-
```bash
|
|
33
|
-
kse --version
|
|
34
|
-
# 应该显示: 1.24.1
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
## 方法 2: 创建 npm 包(如果 npm 可用)
|
|
38
|
-
|
|
39
|
-
### 步骤:
|
|
40
|
-
|
|
41
|
-
1. **在当前目录创建 npm 包**
|
|
42
|
-
```bash
|
|
43
|
-
npm pack
|
|
44
|
-
# 会生成: kiro-spec-engine-1.24.1.tgz
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
2. **将 .tgz 文件复制到目标机器**
|
|
48
|
-
|
|
49
|
-
3. **在目标机器上安装**
|
|
50
|
-
```bash
|
|
51
|
-
npm install -g kiro-spec-engine-1.24.1.tgz
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
## 方法 3: 手动复制(最简单)
|
|
55
|
-
|
|
56
|
-
### 步骤:
|
|
57
|
-
|
|
58
|
-
1. **复制以下文件/目录到目标机器**
|
|
59
|
-
- `bin/` - CLI 入口
|
|
60
|
-
- `lib/` - 核心代码
|
|
61
|
-
- `template/` - 模板文件
|
|
62
|
-
- `locales/` - 国际化文件
|
|
63
|
-
- `docs/` - 文档
|
|
64
|
-
- `package.json` - 包配置
|
|
65
|
-
- `README.md` - 说明文档
|
|
66
|
-
- `LICENSE` - 许可证
|
|
67
|
-
|
|
68
|
-
2. **在目标目录安装依赖**
|
|
69
|
-
```bash
|
|
70
|
-
npm install --production
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
3. **创建全局链接**
|
|
74
|
-
```bash
|
|
75
|
-
npm link
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
## 依赖列表
|
|
79
|
-
|
|
80
|
-
如果目标机器无法访问 npm registry,需要手动下载以下依赖:
|
|
81
|
-
|
|
82
|
-
```json
|
|
83
|
-
{
|
|
84
|
-
"chalk": "^4.1.2",
|
|
85
|
-
"chokidar": "^3.5.3",
|
|
86
|
-
"cli-table3": "^0.6.5",
|
|
87
|
-
"commander": "^9.0.0",
|
|
88
|
-
"fs-extra": "^10.0.0",
|
|
89
|
-
"inquirer": "^8.2.0",
|
|
90
|
-
"js-yaml": "^4.1.1",
|
|
91
|
-
"minimatch": "^10.1.1",
|
|
92
|
-
"path": "^0.12.7",
|
|
93
|
-
"semver": "^7.5.4",
|
|
94
|
-
"simple-git": "^3.30.0"
|
|
95
|
-
}
|
|
1
|
+
# kse 离线安装指南
|
|
2
|
+
|
|
3
|
+
> 适用于无法直接访问 npm registry 的环境。
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
**版本**: 1.46.2
|
|
8
|
+
**最后更新**: 2026-02-14
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## 前置条件
|
|
13
|
+
|
|
14
|
+
- Node.js >= 16
|
|
15
|
+
- npm 可用(建议 npm >= 8)
|
|
16
|
+
|
|
17
|
+
验证:
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
node --version
|
|
21
|
+
npm --version
|
|
96
22
|
```
|
|
97
23
|
|
|
98
|
-
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
## 方式 1:使用 `.tgz` 离线包安装(推荐)
|
|
99
27
|
|
|
100
|
-
|
|
28
|
+
1. 获取离线包文件(示例:`kiro-spec-engine-1.46.2.tgz`)。
|
|
29
|
+
2. 在目标机器执行:
|
|
101
30
|
|
|
102
31
|
```bash
|
|
103
|
-
|
|
104
|
-
|
|
32
|
+
npm install -g kiro-spec-engine-1.46.2.tgz
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
3. 验证:
|
|
105
36
|
|
|
106
|
-
|
|
37
|
+
```bash
|
|
38
|
+
kse --version
|
|
107
39
|
kse --help
|
|
40
|
+
```
|
|
108
41
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## 方式 2:从源码离线安装
|
|
45
|
+
|
|
46
|
+
1. 将项目目录复制到目标机器(建议排除 `node_modules/.git/coverage`)。
|
|
47
|
+
2. 在目标机器安装依赖并全局安装:
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
npm install
|
|
51
|
+
npm install -g .
|
|
112
52
|
```
|
|
113
53
|
|
|
114
|
-
|
|
54
|
+
3. 验证:
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
kse --version
|
|
58
|
+
```
|
|
115
59
|
|
|
116
|
-
|
|
117
|
-
- ✅ 多仓库管理增强
|
|
118
|
-
- ✅ 跨平台路径处理改进
|
|
60
|
+
---
|
|
119
61
|
|
|
120
|
-
##
|
|
62
|
+
## Windows 常见问题
|
|
121
63
|
|
|
122
|
-
###
|
|
64
|
+
### 问题:`npm` 命令不可用
|
|
123
65
|
|
|
124
|
-
|
|
66
|
+
症状:PowerShell 提示无法识别 `npm`。
|
|
125
67
|
|
|
126
|
-
|
|
68
|
+
解决:
|
|
127
69
|
|
|
128
|
-
**解决方案**:
|
|
129
70
|
```powershell
|
|
130
|
-
# 方法 1: 临时添加 Node.js 到 PATH(推荐)
|
|
131
71
|
$env:Path = "C:\Program Files\nodejs;$env:Path"
|
|
132
72
|
npm --version
|
|
133
|
-
|
|
134
|
-
# 方法 2: 重启 PowerShell/终端
|
|
135
|
-
|
|
136
|
-
# 方法 3: 使用完整路径
|
|
137
|
-
& "C:\Program Files\nodejs\npm.cmd" --version
|
|
138
73
|
```
|
|
139
74
|
|
|
140
|
-
|
|
141
|
-
```bash
|
|
142
|
-
# 检查全局安装路径
|
|
143
|
-
npm config get prefix
|
|
75
|
+
---
|
|
144
76
|
|
|
145
|
-
|
|
146
|
-
```
|
|
77
|
+
## 安装后建议的 90 秒验证
|
|
147
78
|
|
|
148
|
-
### 问题 3: 依赖安装失败
|
|
149
79
|
```bash
|
|
150
|
-
|
|
151
|
-
|
|
80
|
+
cd your-project
|
|
81
|
+
kse adopt
|
|
82
|
+
kse spec bootstrap --name 01-00-demo-feature --non-interactive
|
|
83
|
+
kse value metrics sample --out ./kpi-input.json --json
|
|
84
|
+
kse value metrics snapshot --input ./kpi-input.json --json
|
|
152
85
|
```
|
|
153
86
|
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
# Linux/Mac: 使用 sudo
|
|
158
|
-
sudo npm install -g .
|
|
159
|
-
```
|
|
87
|
+
如果最后一步成功,说明你的环境已经可以输出机器可读 KPI 结果(用于周度评审和门禁证据)。
|
|
88
|
+
|
|
89
|
+
---
|
|
160
90
|
|
|
161
|
-
##
|
|
91
|
+
## 相关文档
|
|
162
92
|
|
|
163
|
-
|
|
164
|
-
-
|
|
165
|
-
-
|
|
166
|
-
-
|
|
93
|
+
- [文档索引](README.md)
|
|
94
|
+
- [快速入门](quick-start.md)
|
|
95
|
+
- [命令参考](command-reference.md)
|
|
96
|
+
- [Value 可观测指南](value-observability-guide.md)
|