dsh-workplan 2.1.3 → 2.2.6

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.
Files changed (38) hide show
  1. package/CHANGELOG.md +380 -1
  2. package/README.en.md +5 -2
  3. package/README.md +5 -2
  4. package/README.zh.md +5 -2
  5. package/client.js +143 -3
  6. package/docs/dsh-workplan_T4_runtime.patch +508 -0
  7. package/docs/release-records/_release_notes_2.1.2_20261106.md +44 -0
  8. package/docs/release-records/_t2_version_determination_20261106.md +39 -0
  9. package/docs/release-records/_t5_external_reverify_20261106.md +18 -0
  10. package/docs/release-records/release-dryrun-report-20261106.md +74 -0
  11. package/docs/release-records/release-notes-2.2.6-T3.md +128 -0
  12. package/docs/release-records/release-record-2.1.3-20261106.md +82 -0
  13. package/docs/release-records/release-steps-20261106.md +129 -0
  14. package/docs/release-records/version-freeze-20261109-T2.md +37 -0
  15. package/lib/client.js +143 -3
  16. package/lib/comm-format.js +17 -0
  17. package/lib/departments.js +19 -0
  18. package/lib/host.js +95 -17
  19. package/lib/notice-channel.js +290 -0
  20. package/lib/plan.js +541 -32
  21. package/lib/replan.js +4 -0
  22. package/lib/runtime.js +1481 -85
  23. package/lib/supersede.js +2 -2
  24. package/lib/understanding.js +8 -2
  25. package/lib/watchdog.js +52 -1
  26. package/package.json +3 -2
  27. package/scripts/repair-malformed-user-messages.mjs +312 -0
  28. package/src/client.ts +150 -2
  29. package/src/comm-format.ts +17 -0
  30. package/src/departments.ts +22 -0
  31. package/src/host.ts +90 -12
  32. package/src/notice-channel.ts +328 -0
  33. package/src/plan.ts +575 -24
  34. package/src/replan.ts +4 -0
  35. package/src/runtime.ts +1500 -86
  36. package/src/supersede.ts +2 -1
  37. package/src/understanding.ts +10 -2
  38. package/src/watchdog.ts +80 -1
package/lib/replan.js CHANGED
@@ -145,6 +145,8 @@ const REPLACEMENT_FIELDS = [
145
145
  'outputs',
146
146
  'acceptance',
147
147
  'risk',
148
+ // [2.2.0][T13b/推理等级] 替换行可显式改档位;未给时 mergeReplacement 继承旧行。
149
+ 'reasoningEffort',
148
150
  ];
149
151
  /** 用调用方给的替换内容覆盖旧子任务的同名字段;未给字段原样继承。 */
150
152
  function mergeReplacement(old, replacement, id, reason) {
@@ -391,6 +393,8 @@ export function planReplan(plan, changes, options = {}) {
391
393
  ? raw.acceptance.map((item) => truncate(String(item), 800))
392
394
  : ['复述完成的工作并给出可核对证据'],
393
395
  risk: truncate(String(raw.risk ?? '需求变更后新增,原计划未覆盖'), 1000),
396
+ // [2.2.0][T13b/推理等级] 只登记字段名:显式档位原样透传,缺失时留给 readSubtasks 回落 high。
397
+ ...(typeof raw.reasoningEffort === 'string' ? { reasoningEffort: raw.reasoningEffort } : {}),
394
398
  insertedBy: 'replan',
395
399
  replannedReason: truncate(String(raw.reason ?? reason), MAX_REPLAN_REASON_CHARS),
396
400
  };