@cyning/harness 2.6.0 → 2.8.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 +31 -1
- package/docs/ONBOARDING.md +15 -1
- package/docs/USER_GUIDE_v1.0_zh.md +14 -2
- package/docs/rethink/2026-07-mechanization-rate/01_big_directions.md +1 -0
- package/docs/spec/SPEC-lifecycle-and-verify-lint_v1.md +174 -0
- package/docs/spec/SPEC-spec-reviews-retention-gate_v1.md +192 -0
- package/harness/lifecycle.yaml +83 -0
- package/harness/prompts/20-spec-audit.md +1 -0
- package/lib/cli.js +100 -24
- package/lib/lifecycle.js +121 -0
- package/lib/task-meta.js +101 -0
- package/lib/verify.js +164 -5
- package/package.json +1 -1
- package/schema/lifecycle.v1.schema.json +63 -0
- package/schema/verify_result.v1.schema.json +10 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://cyning.dev/schemas/cyning-harness/lifecycle.v1.json",
|
|
4
|
+
"title": "cyning-harness Task Lifecycle (minimal)",
|
|
5
|
+
"description": "状态/转移/守卫登记 · 只读真值 · 非引擎(v2.7+)",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": ["version", "states", "transitions"],
|
|
9
|
+
"properties": {
|
|
10
|
+
"version": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"description": "lifecycle 文档 schema 版本"
|
|
13
|
+
},
|
|
14
|
+
"states": {
|
|
15
|
+
"type": "array",
|
|
16
|
+
"minItems": 1,
|
|
17
|
+
"items": {
|
|
18
|
+
"type": "object",
|
|
19
|
+
"additionalProperties": false,
|
|
20
|
+
"required": ["id"],
|
|
21
|
+
"properties": {
|
|
22
|
+
"id": { "type": "string", "minLength": 1 },
|
|
23
|
+
"note": { "type": "string" }
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"transitions": {
|
|
28
|
+
"type": "array",
|
|
29
|
+
"minItems": 1,
|
|
30
|
+
"items": {
|
|
31
|
+
"type": "object",
|
|
32
|
+
"additionalProperties": false,
|
|
33
|
+
"required": ["id", "from", "to", "guards"],
|
|
34
|
+
"properties": {
|
|
35
|
+
"id": { "type": "string", "minLength": 1 },
|
|
36
|
+
"from": {
|
|
37
|
+
"type": "array",
|
|
38
|
+
"minItems": 1,
|
|
39
|
+
"items": { "type": "string", "minLength": 1 }
|
|
40
|
+
},
|
|
41
|
+
"to": { "type": "string", "minLength": 1 },
|
|
42
|
+
"hat": { "type": "string" },
|
|
43
|
+
"description": { "type": "string" },
|
|
44
|
+
"guards": {
|
|
45
|
+
"type": "array",
|
|
46
|
+
"items": {
|
|
47
|
+
"type": "object",
|
|
48
|
+
"additionalProperties": false,
|
|
49
|
+
"required": ["id", "command_or_check", "severity"],
|
|
50
|
+
"properties": {
|
|
51
|
+
"id": { "type": "string", "minLength": 1 },
|
|
52
|
+
"command_or_check": { "type": "string", "minLength": 1 },
|
|
53
|
+
"severity": { "type": "string", "enum": ["block", "warn"] },
|
|
54
|
+
"allow_flag": { "type": "string" },
|
|
55
|
+
"note": { "type": "string" }
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -35,6 +35,16 @@
|
|
|
35
35
|
"type": "array",
|
|
36
36
|
"items": { "type": "string" }
|
|
37
37
|
},
|
|
38
|
+
"lint": {
|
|
39
|
+
"description": "v2.7+ · 仅 --task;不参与 may_start_30",
|
|
40
|
+
"type": ["object", "null"],
|
|
41
|
+
"properties": {
|
|
42
|
+
"ok": { "type": "boolean" },
|
|
43
|
+
"errors": { "type": "array" },
|
|
44
|
+
"warnings": { "type": "array" },
|
|
45
|
+
"suppressed": { "type": "boolean" }
|
|
46
|
+
}
|
|
47
|
+
},
|
|
38
48
|
"gates": {
|
|
39
49
|
"type": "array",
|
|
40
50
|
"items": {
|