@devflow-core/dsh-devflow 0.6.2 → 0.9.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/README.md +1 -1
- package/RELEASE.md +1 -1
- package/assets/presets/devflow-2/agent.cordis.yml +10 -1
- package/assets/scripts/devflow-plan.js +35 -8
- package/assets/skills/devflow-build/SKILL.md +1 -1
- package/assets/skills/devflow-build/references/build-methods.md +2 -0
- package/assets/skills/devflow-core/SKILL.md +8 -0
- package/assets/skills/devflow-docs-followup/SKILL.md +2 -0
- package/assets/skills/devflow-plan/SKILL.md +9 -5
- package/assets/skills/devflow-plan/references/plan-methods.md +12 -1
- package/assets/skills/devflow-prove/references/proof-recovery-methods.md +2 -0
- package/assets/skills/devflow-spec/references/spec-plan-methods.md +2 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -33,7 +33,7 @@ npx @deepseek-ai/dsh plugin --profile web add @devflow-core/dsh-devflow
|
|
|
33
33
|
|
|
34
34
|
- **devflow-\* 权威覆盖**:目标文件与包内源文件字节相同 → 跳过;不同 → 覆盖。
|
|
35
35
|
- 源不再包含的 devflow-\* 残留(升级后旧文件)→ 删除(prune)。
|
|
36
|
-
- **非 devflow 资产永不触碰**:用户自装的 skill(如 `atlassian
|
|
36
|
+
- **非 devflow 资产永不触碰**:用户自装的 skill(如 `atlassian`)、
|
|
37
37
|
自定义命令/脚本一律保留,不删除不覆盖。
|
|
38
38
|
- **preset 目录完全由插件管理**:`~/.dsh/.agent-presets/devflow-2/` 整目录归
|
|
39
39
|
插件所有,目录内非包内文件(含手动备份如 `agent.cordis.yml.bak-*`)会在
|
package/RELEASE.md
CHANGED
|
@@ -101,7 +101,7 @@ npx @deepseek-ai/dsh plugin --profile web update @devflow-core/dsh-devflow
|
|
|
101
101
|
- 字节相同的文件跳过(不覆盖用户 mtime)
|
|
102
102
|
- 不同的文件覆盖(devflow-* 权威)
|
|
103
103
|
- 源不再包含的 devflow-* 残留 prune
|
|
104
|
-
- 非 devflow 资产(atlassian
|
|
104
|
+
- 非 devflow 资产(atlassian 等)永不触碰
|
|
105
105
|
- `~/.dsh/.agent-presets/devflow-2/` 整目录归插件管理,目录内非包内文件会被清理
|
|
106
106
|
|
|
107
107
|
## 常见错误对照表
|
|
@@ -88,7 +88,12 @@
|
|
|
88
88
|
# restores THIS text after promotion. The DevFlow paragraph guarantees
|
|
89
89
|
# activation even when the model would otherwise skip reading AGENTS.md; the
|
|
90
90
|
# route table and hard boundaries stay in the devflow-core skill and AGENTS.md
|
|
91
|
-
# (single source, no duplication).
|
|
91
|
+
# (single source, no duplication). The two trailing paragraphs carry the
|
|
92
|
+
# AGENTS.md rules no lifecycle skill owns — Independent Judgment and the
|
|
93
|
+
# fallback output contracts — because `instructionHint: true` (tool-bootstrap
|
|
94
|
+
# above) replaces the workspace AGENTS.md digest with a reference hint once the
|
|
95
|
+
# session is promoted.
|
|
96
|
+
# devflow: ceiling: clause-level restatement checked by scripts/validate-devflow.js, not full semantic alignment; revisit when either AGENTS.md section is reworded.
|
|
92
97
|
- id: persona
|
|
93
98
|
name: '@deepseek-ai/dsh-persona'
|
|
94
99
|
config:
|
|
@@ -97,6 +102,10 @@
|
|
|
97
102
|
|
|
98
103
|
You run DevFlow. Before any development work — creating features, building components, adding functionality, modifying behavior, or defining an unapproved problem-directed change — load the `devflow-core` skill with the skill tool and read its `core-methods.md` reference, then load only the selected lifecycle owner skill. The route table and hard boundaries live in that skill and in AGENTS.md; do not invent lifecycle details. Pure Q&A, lookup, verification, and investigation-only reports need no lifecycle.
|
|
99
104
|
|
|
105
|
+
Independent judgment: before answering or acting, check for false premises, logical leaps, and material missing information; never agree merely to accommodate the user — when disagreeing, state the evidence, risks, and plausible alternative explanations; separate verified facts, inferences, and opinions, and state the evidence boundary when verification is unavailable; name overlooked variables, costs, constraints, and likely biases.
|
|
106
|
+
|
|
107
|
+
Fallback output contracts: design as Goal / Smallest useful plan / Not doing / Impact / Verification; completion as Command / Result / Adversarial review / Judgment (PASS, FAIL, or BLOCKED).
|
|
108
|
+
|
|
100
109
|
- id: agent-instructions
|
|
101
110
|
name: '@deepseek-ai/dsh-agent-instructions'
|
|
102
111
|
config:
|
|
@@ -369,20 +369,24 @@ function splitTasksV2(body) {
|
|
|
369
369
|
}
|
|
370
370
|
|
|
371
371
|
/** Validate one v2 task: files, change intent, acceptance, proof, and exclusion. */
|
|
372
|
-
function checkTaskV2(task) {
|
|
372
|
+
function checkTaskV2(task, enforceGranularity = true) {
|
|
373
373
|
const missing = v2TaskFields.filter((field) => !v2FieldPatterns[field].test(task.body));
|
|
374
374
|
const files = v2FieldBlock(task.body, "Files");
|
|
375
375
|
const change = v2FieldBlock(task.body, "Change");
|
|
376
|
+
const acceptance = v2FieldBlock(task.body, "Acceptance");
|
|
376
377
|
const verify = v2FieldBlock(task.body, "Verify");
|
|
377
378
|
const notDoing = v2FieldBlock(task.body, "Not doing");
|
|
378
379
|
const fileEntries = parseFileEntries(files);
|
|
379
380
|
const invalidFiles = fileEntries.filter(({ match }) => !match).map(({ line }) => line);
|
|
380
381
|
const unlocatedCodeFiles = findUnlocatedCodeFiles(fileEntries);
|
|
381
382
|
const unresolved = findMatches(task.body, unresolvedPatterns);
|
|
382
|
-
const vague = findMatches([change,
|
|
383
|
+
const vague = findMatches([change, acceptance, verify].join("\n"), vaguePatterns);
|
|
383
384
|
// v2 不强制精确改法;只要求 Change 说出可执行意图,具体实现归 Build。
|
|
384
385
|
const missingChange = !implementationVerbPattern.test(change) || genericMechanicsPattern.test(change);
|
|
385
386
|
const incompleteVerification = !hasVerificationExpectation(verify);
|
|
387
|
+
// 单结果保守代理:Acceptance 含分号即视为多交付单元;先剔除反引号代码片段,避免命令里的半角分号误报。语义判据("且"连接独立结果、镜像合并)在技能指南,checker 只强制可静态判定的子集。
|
|
388
|
+
const acceptanceText = acceptance.replace(/`[^`]*`/g, "");
|
|
389
|
+
const multiResult = enforceGranularity && /[;;]/.test(acceptanceText);
|
|
386
390
|
|
|
387
391
|
return {
|
|
388
392
|
number: task.number,
|
|
@@ -393,6 +397,7 @@ function checkTaskV2(task) {
|
|
|
393
397
|
unlocatedCodeFiles,
|
|
394
398
|
missingChange,
|
|
395
399
|
incompleteVerification,
|
|
400
|
+
multiResult,
|
|
396
401
|
missingNotDoing: !notDoing,
|
|
397
402
|
ok:
|
|
398
403
|
missing.length === 0 &&
|
|
@@ -402,6 +407,7 @@ function checkTaskV2(task) {
|
|
|
402
407
|
unlocatedCodeFiles.length === 0 &&
|
|
403
408
|
!missingChange &&
|
|
404
409
|
!incompleteVerification &&
|
|
410
|
+
!multiResult &&
|
|
405
411
|
Boolean(notDoing)
|
|
406
412
|
};
|
|
407
413
|
}
|
|
@@ -409,13 +415,15 @@ function checkTaskV2(task) {
|
|
|
409
415
|
/** Validate the v2 plan contract: slim header, task rows, Progress table, and Cut subtraction. */
|
|
410
416
|
function checkPlanV2(body) {
|
|
411
417
|
const tasks = splitTasksV2(body);
|
|
412
|
-
const taskResults = tasks.map(checkTaskV2);
|
|
413
|
-
const missingGlobal = v2GlobalFields.filter((field) => !v2FieldPatterns[field].test(body));
|
|
414
|
-
const cutBlock = v2FieldBlock(body, "Cut");
|
|
415
|
-
const missingRejected = !/Rejected\s*:\s*\S/im.test(cutBlock);
|
|
416
418
|
const statusMatch = body.match(statusPattern);
|
|
417
419
|
const status = statusMatch ? statusMatch[1].trim() : "legacy";
|
|
418
420
|
const invalidStatus = statusMatch ? !validStatuses.includes(status) : false;
|
|
421
|
+
// 粒度代理只在活跃计划(draft/approved/in-progress)上强制;done 计划是历史记录,不重判,避免既有 v2 计划校验回归。
|
|
422
|
+
const enforceGranularity = status !== "done";
|
|
423
|
+
const taskResults = tasks.map((task) => checkTaskV2(task, enforceGranularity));
|
|
424
|
+
const missingGlobal = v2GlobalFields.filter((field) => !v2FieldPatterns[field].test(body));
|
|
425
|
+
const cutBlock = v2FieldBlock(body, "Cut");
|
|
426
|
+
const missingRejected = !/Rejected\s*:\s*\S/im.test(cutBlock);
|
|
419
427
|
const progress = [...body.matchAll(progressRowPattern)].map((match) => ({
|
|
420
428
|
number: Number(match[1]),
|
|
421
429
|
state: match[3],
|
|
@@ -806,6 +814,7 @@ function report(body, filePath, json) {
|
|
|
806
814
|
...task.vague.map((match) => `vague ${match}`),
|
|
807
815
|
...task.invalidFiles.map((line) => `unclassified file ${line}`),
|
|
808
816
|
...task.unlocatedCodeFiles.map((line) => `missing file symbol/anchor ${line}`),
|
|
817
|
+
...(task.multiResult ? ["Acceptance lists multiple results; split the task or state one observable result"] : []),
|
|
809
818
|
...(task.missingChange ? ["Change needs an executable intent verb"] : []),
|
|
810
819
|
...(task.missingNotDoing ? ["missing Not doing exclusion"] : []),
|
|
811
820
|
...(task.incompleteVerification ? ["Verify needs command/scenario and expected result"] : [])
|
|
@@ -1046,7 +1055,7 @@ function selfTest() {
|
|
|
1046
1055
|
"Files:",
|
|
1047
1056
|
"- Modify: scripts/devflow-plan.js | symbol: `checkPlanV2` | validate the slim contract",
|
|
1048
1057
|
"Change: add v2 field validation and dispatch",
|
|
1049
|
-
"Acceptance: v2 plans pass
|
|
1058
|
+
"Acceptance: v2 plans pass the slim contract",
|
|
1050
1059
|
"Verify: run `node scripts/devflow-plan.js --self-test` expect exit 0",
|
|
1051
1060
|
"Not doing: changing legacy validation",
|
|
1052
1061
|
"",
|
|
@@ -1058,6 +1067,24 @@ function selfTest() {
|
|
|
1058
1067
|
].join("\n");
|
|
1059
1068
|
if (!detectV2(validV2Plan)) throw new Error("Self-test expected v2 detection to pass");
|
|
1060
1069
|
if (!checkPlan(validV2Plan).ok) throw new Error("Self-test expected valid v2 plan to pass");
|
|
1070
|
+
const multiResultV2Plan = validV2Plan.replace(
|
|
1071
|
+
"Acceptance: v2 plans pass the slim contract",
|
|
1072
|
+
"Acceptance: v2 plans pass;legacy plans keep passing"
|
|
1073
|
+
);
|
|
1074
|
+
if (checkPlan(multiResultV2Plan).ok) throw new Error("Self-test expected a semicolon-joined Acceptance to fail");
|
|
1075
|
+
const doneMultiResultV2Plan = multiResultV2Plan
|
|
1076
|
+
.replace("Status: approved", "Status: done")
|
|
1077
|
+
.replace("| 1 | Add v2 validation | todo | - |", "| 1 | Add v2 validation | done | run `node scripts/devflow-plan.js --self-test` |");
|
|
1078
|
+
if (!checkPlan(doneMultiResultV2Plan).ok) {
|
|
1079
|
+
throw new Error("Self-test expected a done plan to keep validating without granularity re-judging");
|
|
1080
|
+
}
|
|
1081
|
+
const codeSpanSemicolonV2Plan = validV2Plan.replace(
|
|
1082
|
+
"Acceptance: v2 plans pass the slim contract",
|
|
1083
|
+
"Acceptance: `node -e \"a;b\"` prints one result"
|
|
1084
|
+
);
|
|
1085
|
+
if (!checkPlan(codeSpanSemicolonV2Plan).ok) {
|
|
1086
|
+
throw new Error("Self-test expected a semicolon inside a code span to stay valid");
|
|
1087
|
+
}
|
|
1061
1088
|
if (checkPlan(validV2Plan.replace(/Rejected:[^\n]*/, "Rejected:")).ok) throw new Error("Self-test expected missing Rejected to fail");
|
|
1062
1089
|
if (checkPlan(validV2Plan.replace("| 1 | Add v2 validation | todo | - |", "| 1 | Add v2 validation | done | - |")).ok) {
|
|
1063
1090
|
throw new Error("Self-test expected a done Progress row without evidence to fail");
|
|
@@ -1089,7 +1116,7 @@ function selfTest() {
|
|
|
1089
1116
|
if (missingArtifact.length === 0) throw new Error("Self-test expected a missing requirement artifact to fail");
|
|
1090
1117
|
|
|
1091
1118
|
console.log("DevFlow plan self-test passed");
|
|
1092
|
-
console.log("Checked v2 and legacy plan contracts, Progress evidence, Cut Rejected, code-level fields, precise file locations, verification expectations, documentation-only exception, external-skill declaration, and plan landing guidance");
|
|
1119
|
+
console.log("Checked v2 and legacy plan contracts, Progress evidence, Cut Rejected, single-result Acceptance granularity, code-level fields, precise file locations, verification expectations, documentation-only exception, external-skill declaration, and plan landing guidance");
|
|
1093
1120
|
}
|
|
1094
1121
|
|
|
1095
1122
|
const args = process.argv.slice(2);
|
|
@@ -46,7 +46,7 @@ When saving a plan file, use `docs/plans/YYYY-MM-DD-<short-kebab-name>.md`, reso
|
|
|
46
46
|
|
|
47
47
|
For multi-step work, tasks must cite the approved source, be small and verifiable, and follow the six-field contract (`Task` / `Files` / `Change` / `Acceptance` / `Verify` / `Not doing`) in `skills/devflow-plan/SKILL.md`. Legacy plans with `Change mechanics` and `Prewalk` stay executable under their own contract.
|
|
48
48
|
|
|
49
|
-
No unresolved markers. `Change` states the executable intent and boundary; add exact mechanics only when the change crosses a module contract, is irreversible,
|
|
49
|
+
No unresolved markers. `Change` states the executable intent and boundary; add exact mechanics only when the change crosses a module contract, is irreversible, touches security or data boundaries, or the mechanism cannot be inferred from the task's named anchors by a different session or model. Otherwise Build chooses the smallest implementation and records it as Progress evidence. The verification step keeps its trigger/input, expected result, and command or manual scenario. A task whose files are all documentation paths is documentation-only. No "add tests" without naming the behavior, no "handle edge cases" without naming the edge case, no "similar to Task N" shortcuts.
|
|
50
50
|
|
|
51
51
|
Close each task by writing back its `## Progress` row: `doing` when starting, `done` with the command and key result when its `Verify` passes. A `done` row without evidence fails the checker. On a legacy plan without a Progress table, report the same evidence in the completion message. When every task is `done`, advance the requirement row in `docs/requirements.md` to `built`.
|
|
52
52
|
|
|
@@ -42,3 +42,5 @@ A function may contain several steps when they form one coherent business narrat
|
|
|
42
42
|
## Build Comments
|
|
43
43
|
|
|
44
44
|
The approved Spec/Plan and local project convention define required code comments. Add a comment when it records a protected contract, failure condition, business rule, compatibility boundary, or other non-obvious reason; inline comments explain reasons, not syntax. Markdown runtime contracts use headings and fixed output shapes rather than narrative comments.
|
|
45
|
+
|
|
46
|
+
When a comment describes behavior, write it from the accepted final state. Regenerate it from the final behavior instead of editing rejected wording; comments never narrate rejected alternatives, session corrections, intermediate attempts, or why-not-X reasoning, and keep only the non-obvious reasons a future maintainer needs.
|
|
@@ -22,6 +22,14 @@ Status: [DevFlow: <node> -> <next> | awaiting approval / in progress]
|
|
|
22
22
|
|
|
23
23
|
While a DevFlow lifecycle node is active, end each user-facing message with one status line: `[DevFlow: <node> -> <next> | awaiting approval / in progress]`. It reflects the current node without reloading the owner skill. Keep progress visible in the persistent UI: maintain a `todo_write` list with one item per active work unit (lifecycle node, background job, or subagent), marking it `completed` the moment it settles, and use `create_goal` for the session's long-running objective.
|
|
24
24
|
|
|
25
|
+
## Delivery Surfaces
|
|
26
|
+
|
|
27
|
+
Final artifacts and their wrappers — titles, filenames, body text, comments, tags, commits, PR text, documents, and handoffs — describe the accepted final state, assuming the reader did not see this session; rejected session-only alternatives, intermediate attempts, and wording corrections stay control data.
|
|
28
|
+
|
|
29
|
+
For each surface, decide whether a session-less reader needs the information: keep an exclusion only when omission would make the artifact inaccurate, unsafe, misleading, or incompatible, or when this surface must explain a real change from the committed or user-approved baseline. Regenerate high-salience names, titles, and openings from the positive target instead of editing rejected wording, and never write an absent option as a labeled absence. Keep real baseline changes, executed external actions, required technical names, diagnostics, tests, and pre-existing user changes.
|
|
30
|
+
|
|
31
|
+
Before completion, reread every user-visible surface and wrapper, including filenames, metadata, and hook rewrites, and recheck after any content change. Keep unrelated changes out of this task's commit, PR, or handoff; keep comparisons, quotations, audits, or migration notes only when the user asked or the surface requires them, and do not add cleanup or no-residue claims.
|
|
32
|
+
|
|
25
33
|
## Context Map
|
|
26
34
|
|
|
27
35
|
Read `skills/devflow-core/references/core-methods.md` before route selection. It supplies Method 0, shared route rules, and the owner map. Do not load all lifecycle references by default.
|
|
@@ -41,6 +41,8 @@ Rules:
|
|
|
41
41
|
|
|
42
42
|
Before writing a selected document, read the current diff, implementation, tests, commands, and user-confirmed decisions. Use project documentation conventions and templates when they exist.
|
|
43
43
|
|
|
44
|
+
Describe the accepted final state: session-only alternatives, intermediate attempts, and corrections stay out of created documents. Regenerate titles and openings from the positive target; keep API names, real removals, executed external actions, diagnostics, tests, and compatibility facts that accuracy requires, and keep unrelated changes out unless the document requires them.
|
|
45
|
+
|
|
44
46
|
When the target project has no relevant convention, use these fallback locations:
|
|
45
47
|
|
|
46
48
|
| Document type | Fallback path |
|
|
@@ -18,7 +18,7 @@ Turn an A/B `CUT_PASS`-bounded approved design or confirmed Spec into one review
|
|
|
18
18
|
1. Read only source material, code, tests, and conventions relevant to the approved scope. Load `skills/devflow-spec/references/spec-plan-methods.md` and `skills/devflow-plan/references/plan-methods.md` before applying Plan Pack mechanics.
|
|
19
19
|
2. Map the intended touch set once: list the files and the responsibility each one carries. Reuse existing modules and name the intended file operation.
|
|
20
20
|
3. Do the bounded investigation needed to write correct tasks. Keep that evidence in the conversation or in a learning card; it is not a plan field.
|
|
21
|
-
4. Split
|
|
21
|
+
4. Split by delivery unit: one task = one independently verifiable deliverable and the smallest unit worth a fresh reviewer's gate — split only where a reviewer could meaningfully reject one task while approving its neighbor, and fold setup, configuration, scaffolding, and documentation into the task whose deliverable needs them. Split whenever `Acceptance` needs `且`/`and` to join two independently verifiable results; keep one task when the same rule mirrors across files — mirrored edits are one delivery unit, not one task per file. Each task carries `Files`, `Change`, `Acceptance`, `Verify`, and `Not doing` so an executor can act on it without reading another task.
|
|
22
22
|
5. Write the plan using the required header, task contract, and `## Progress` table below.
|
|
23
23
|
6. Self-review Cut fidelity, touch-set coverage, acceptance proof, scope exclusions, and Progress row count against the task count.
|
|
24
24
|
7. Run `node scripts/devflow-plan.js <plan-file>` when the project-level checker exists. Otherwise resolve the user-level checker according to `core-methods.md` Script Path Resolution.
|
|
@@ -49,7 +49,7 @@ Files:
|
|
|
49
49
|
- Create: <path> | new file | <responsibility>
|
|
50
50
|
- Modify: <path> | <symbol or stable anchor> | <responsibility>
|
|
51
51
|
- Test: <path> | <symbol or stable anchor> | <behavior proved> # only when applicable
|
|
52
|
-
Change: <what changes and its boundary; add the smallest mechanics only when the change crosses a module contract, is irreversible,
|
|
52
|
+
Change: <what changes and its boundary; add the smallest mechanics (pseudocode, exact replacement, or key fragment) only when the change crosses a module contract, is irreversible, touches security or data boundaries, or the mechanism cannot be inferred from the task's named anchors by a different session or model>
|
|
53
53
|
Acceptance: <specific observable condition>
|
|
54
54
|
Verify: <exact command or manual scenario, trigger/input, and expected result>
|
|
55
55
|
Not doing: <scope excluded by this task>
|
|
@@ -77,15 +77,15 @@ Files:
|
|
|
77
77
|
- Create: <path> | new file | <responsibility>
|
|
78
78
|
- Modify: <path> | <symbol or stable anchor> | <responsibility>
|
|
79
79
|
- Test: <path> | <symbol or stable anchor> | <behavior proved> # only when applicable
|
|
80
|
-
Change: <what changes and its boundary; exact mechanics only when the change crosses a module contract, is irreversible,
|
|
80
|
+
Change: <what changes and its boundary; exact mechanics (pseudocode, exact replacement, or key fragment) only when the change crosses a module contract, is irreversible, touches security or data boundaries, or the mechanism cannot be inferred from the task's named anchors by a different session or model>
|
|
81
81
|
Acceptance: <specific observable condition>
|
|
82
82
|
Verify: <exact command or manual scenario, trigger/input, and expected result>
|
|
83
83
|
Not doing: <scope excluded by this task>
|
|
84
84
|
```
|
|
85
85
|
|
|
86
|
-
Use only `Create`, `Modify`, and `Test` file-operation labels. `Create` rows use `new file`; every other row names a symbol or stable anchor. `Change` states the executable intent and its boundary in one or two lines; it does not restate current behavior, target behavior, call impact, or interfaces unless the task changes a cross-module contract. The Plan no longer classifies tasks by `Task type`: a task whose files are all documentation paths is documentation-only, and the checker treats it that way.
|
|
86
|
+
Use only `Create`, `Modify`, and `Test` file-operation labels. `Create` rows use `new file`; every other row names a symbol or stable anchor. `Change` states the executable intent and its boundary in one or two lines; it does not restate current behavior, target behavior, call impact, or interfaces unless the task changes a cross-module contract. When the mechanism cannot be inferred from the task's named anchors — the common case when a different session or model executes the plan — `Change` carries the smallest runnable mechanics (pseudocode, exact replacement, or key fragment) so the executor acts without the author's session context. The Plan no longer classifies tasks by `Task type`: a task whose files are all documentation paths is documentation-only, and the checker treats it that way.
|
|
87
87
|
|
|
88
|
-
Six fields per task is the whole contract: ordering, the touch set, the intent, the acceptance condition, the proof command, and the exclusion. Investigation traces, handoff facts, per-task worklists, architecture, tech stack, spec coverage, and comment locations are owned by other nodes or stay in the conversation. `Prewalk`, `File Structure`, `Interfaces`, `Current behavior`, `Target behavior`, `Change mechanics`, `Call impact`, and `Comments` are not part of the v2 contract; a plan that still carries them is treated as legacy.
|
|
88
|
+
Six fields per task is the whole contract: ordering, the touch set, the intent, the acceptance condition, the proof command, and the exclusion. `Acceptance` states one observable result; a `;`/`;`-joined multi-result acceptance is a split signal and the checker fails it while the plan is active. Plan length has no fixed total line cap: it grows with the number of delivery units while every task keeps the six-field, one-result shape. Investigation traces, handoff facts, per-task worklists, architecture, tech stack, spec coverage, and comment locations are owned by other nodes or stay in the conversation. `Prewalk`, `File Structure`, `Interfaces`, `Current behavior`, `Target behavior`, `Change mechanics`, `Call impact`, and `Comments` are not part of the v2 contract; a plan that still carries them is treated as legacy.
|
|
89
89
|
|
|
90
90
|
Keep one task understandable on its own. Do not use cross-task shorthand, generic test additions, unnamed edge cases, or cleanup entries. Name a test file only when the stated behavior needs one.
|
|
91
91
|
|
|
@@ -103,6 +103,8 @@ Plan generation does not repeat Cut, perform Build or Prove, prescribe independe
|
|
|
103
103
|
| "The checker proves the architecture." | It proves structure only; the author must review scope and design consistency. |
|
|
104
104
|
| "The plan is approved, so Cut can be skipped." | Plan generation requires an existing `CUT_PASS`; it cannot replace the earlier reuse and scope decision. |
|
|
105
105
|
| "The task details can broaden the solution." | If a task exceeds the Cut Decision, return the scope-drift facts to `devflow-core`; do not directly enter Build. |
|
|
106
|
+
| "Two results can share one task when they ship together." | Two independently verifiable results are two delivery units; split the task or reduce `Acceptance` to one observable result. |
|
|
107
|
+
| "A different session or model will figure out the how." | If the mechanism cannot be inferred from the task's named anchors, `Change` must carry the smallest runnable mechanics; otherwise the handoff stalls. |
|
|
106
108
|
|
|
107
109
|
## Verification
|
|
108
110
|
|
|
@@ -114,6 +116,8 @@ Before leaving this skill, confirm:
|
|
|
114
116
|
- [ ] Approved design or saved spec is cited as optional `Source`.
|
|
115
117
|
- [ ] Header, tasks, and `## Progress` match the v2 contract; each task has six fields and no legacy field.
|
|
116
118
|
- [ ] Every task is independently understandable and has no unresolved or vague placeholder.
|
|
119
|
+
- [ ] Each task is exactly one delivery unit: no `;`/`;`-joined `Acceptance`, and a mirrored rule was not split per file.
|
|
120
|
+
- [ ] Every task is executable by a different session or model from its six fields plus named anchors: a non-inferable mechanism carries the smallest runnable mechanics.
|
|
117
121
|
- [ ] Progress row count equals task count; every `done` row carries evidence.
|
|
118
122
|
- [ ] The checker passed when available.
|
|
119
123
|
- [ ] The user reviewed the written plan.
|
|
@@ -8,6 +8,17 @@ State the intended touch set once, before tasks: the files and the responsibilit
|
|
|
8
8
|
|
|
9
9
|
The v2 Plan Pack has no `File Structure` table. The per-task `Files` rows are the touch set; a global table would only restate them.
|
|
10
10
|
|
|
11
|
+
## Delivery Unit
|
|
12
|
+
|
|
13
|
+
Split by delivery unit, not by file or by step: one task = one independently verifiable deliverable.
|
|
14
|
+
|
|
15
|
+
- Splitting test: if `Acceptance` needs `且`/`and` to join two independently verifiable results, they are two delivery units — split them.
|
|
16
|
+
- Mirror test: the same rule edited across several files is one delivery unit; do not split it per file.
|
|
17
|
+
- Right-sizing test: a task is the smallest unit worth a fresh reviewer's gate — split only where a reviewer could meaningfully reject one task while approving its neighbor; fold setup, configuration, scaffolding, and documentation into the task whose deliverable needs them.
|
|
18
|
+
- `Acceptance` states one observable result. The checker fails a v2 task whose `Acceptance` contains a `;`/`;` separator outside backtick code spans as the conservative static proxy for this rule; it applies while the plan is active (draft/approved/in-progress), while done plans stay historical records. The semantic tests above still govern mirrored and independently verifiable cases.
|
|
19
|
+
- Handoff density: when the mechanism cannot be inferred from the task's named anchors — a different session or model executes the plan — `Change` carries the smallest runnable mechanics (pseudocode, exact replacement, or key fragment); otherwise it stays intent plus boundary.
|
|
20
|
+
- No fixed total line cap: plan length grows with the number of delivery units; the six-field shape keeps each task slim.
|
|
21
|
+
|
|
11
22
|
## Task Rows
|
|
12
23
|
|
|
13
24
|
Each task carries exactly six fields:
|
|
@@ -21,7 +32,7 @@ Verify: <command or manual scenario with trigger, input, and expected result>
|
|
|
21
32
|
Not doing: <scope excluded by this task>
|
|
22
33
|
```
|
|
23
34
|
|
|
24
|
-
`Change` states the executable intent. Add exact mechanics only when the change crosses a module contract, is irreversible,
|
|
35
|
+
`Change` states the executable intent. Add exact mechanics (pseudocode, exact replacement, or key fragment) only when the change crosses a module contract, is irreversible, touches security or data boundaries, or the mechanism cannot be inferred from the task's named anchors by a different session or model. Otherwise the executor chooses the smallest implementation inside the task boundary. This is the deliberate trade: the plan stops pre-deciding every edit, and Build regains bounded implementation authority. That trade is the fix for the bloated-plan problem, not a relaxation of proof.
|
|
25
36
|
|
|
26
37
|
Investigation evidence does not belong in the plan. Keep it in the conversation, or in a `.copilot/cards/` learning card when it is reusable across tasks.
|
|
27
38
|
|
|
@@ -17,6 +17,8 @@ Adversarial review: <acceptance, regressions, activation, proof coverage>
|
|
|
17
17
|
Judgment: PASS / FAIL / BLOCKED
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
+
Before the completion report, reread every final artifact and its wrapper — filenames, titles, comments, tags, documents, commit or PR text, metadata, hook rewrites, and the report itself — as a reader without access to this session, and describe only the accepted final state. Recheck after any content change; keep deliberate decision records, safety and compatibility facts, real baseline changes, executed external actions, and pre-existing user changes; keep unrelated changes out of this task's commit, PR, or handoff, and do not add cleanup or no-residue claims.
|
|
21
|
+
|
|
20
22
|
`PASS` is Prove's terminal success after Learn review. Proof `FAIL`, `BLOCKED`, a real adversarial gap, unresolved Code Review Blocker/Warning, or incomplete PUA recovery evidence returns its facts to `devflow-core`; Core selects the repair, recovery, or re-clarification path. Prove never infers that next owner.
|
|
21
23
|
|
|
22
24
|
### Quality-Finding Recovery
|
|
@@ -8,6 +8,8 @@ Owner: `devflow-spec` and `devflow-plan`. Load this reference only after Core se
|
|
|
8
8
|
|
|
9
9
|
`devflow-plan` consumes A/B `CUT_PASS` plus an approved design or confirmed Spec. It creates one implementation plan under `docs/plans/`, then waits for user review. An approved A/B Plan directly enters Build; scope-drift facts return to Core.
|
|
10
10
|
|
|
11
|
+
Spec and Plan names, titles, and framing describe the accepted final state, regenerated from the positive target rather than edited from rejected wording. Keep Non-goals and Rejected as deliberate decision records; keep unrelated changes, comparisons, quotations, audits, or migration notes out unless the user asked or the document requires them.
|
|
12
|
+
|
|
11
13
|
A Spec contains Goal, Context, Requirements, Non-goals, Approach, Impact, Acceptance, Verification, Code Documentation, and Open Questions. A Plan states Source, Spec coverage, Cut Decision, External Skills, exact files or anchors, interfaces, current and target behavior, mechanics, call impact, verification, comments, and exclusions.
|
|
12
14
|
|
|
13
15
|
## Plan Contract
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devflow-core/dsh-devflow",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"description": "DevFlow for DeepSeek Harness: devflow-2 agent preset + skills + commands + verification scripts, synced into ~/.dsh on host startup.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"engines": {
|