@skrr-ai/cli 0.1.119 → 0.1.120

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 (276) hide show
  1. package/dist/base-command.d.ts +31 -0
  2. package/dist/base-command.js +106 -4
  3. package/dist/commands/commands.js +11 -0
  4. package/dist/commands/commitments/action-proposal.d.ts +13 -0
  5. package/dist/commands/commitments/action-proposal.js +39 -0
  6. package/dist/commands/commitments/action-proposals/decide.js +8 -1
  7. package/dist/commands/commitments/action-proposals/execute.js +11 -1
  8. package/dist/commands/commitments/create.js +2 -2
  9. package/dist/commands/commitments/doctor.d.ts +8 -0
  10. package/dist/commands/commitments/doctor.js +22 -0
  11. package/dist/commands/commitments/execute-remediation.js +12 -1
  12. package/dist/commands/commitments/observations.js +2 -2
  13. package/dist/commands/commitments/pack/bind.d.ts +18 -1
  14. package/dist/commands/commitments/pack/bind.js +66 -8
  15. package/dist/commands/commitments/pack/plan.d.ts +4 -1
  16. package/dist/commands/commitments/pack/plan.js +30 -2
  17. package/dist/commands/commitments/update.js +8 -2
  18. package/dist/commands/completion/index.js +1 -1
  19. package/dist/commands/completion/values.js +1 -1
  20. package/dist/commands/computer-use/audio.d.ts +1 -0
  21. package/dist/commands/computer-use/audio.js +1 -0
  22. package/dist/commands/computer-use/browser.d.ts +1 -0
  23. package/dist/commands/computer-use/browser.js +1 -0
  24. package/dist/commands/computer-use/disable.d.ts +1 -0
  25. package/dist/commands/computer-use/disable.js +1 -0
  26. package/dist/commands/computer-use/enable.d.ts +1 -0
  27. package/dist/commands/computer-use/enable.js +1 -0
  28. package/dist/commands/computer-use/index.d.ts +1 -0
  29. package/dist/commands/computer-use/index.js +1 -0
  30. package/dist/commands/computer-use/install.d.ts +1 -0
  31. package/dist/commands/computer-use/install.js +1 -0
  32. package/dist/commands/computer-use/recover.d.ts +1 -0
  33. package/dist/commands/computer-use/recover.js +1 -0
  34. package/dist/commands/computer-use/status.d.ts +1 -0
  35. package/dist/commands/computer-use/status.js +1 -0
  36. package/dist/commands/computer-use/stop.d.ts +1 -0
  37. package/dist/commands/computer-use/stop.js +1 -0
  38. package/dist/commands/context.js +16 -11
  39. package/dist/commands/convos/recovery.js +1 -1
  40. package/dist/commands/daemon/diagnostics.d.ts +9 -0
  41. package/dist/commands/daemon/diagnostics.js +53 -0
  42. package/dist/commands/daemon/index.js +2 -0
  43. package/dist/commands/daemon/maintenance/attest.d.ts +15 -0
  44. package/dist/commands/daemon/maintenance/attest.js +52 -0
  45. package/dist/commands/daemon/maintenance/hold.d.ts +17 -0
  46. package/dist/commands/daemon/maintenance/hold.js +70 -0
  47. package/dist/commands/daemon/maintenance/index.d.ts +12 -0
  48. package/dist/commands/daemon/maintenance/index.js +30 -0
  49. package/dist/commands/daemon/maintenance/resume.d.ts +13 -0
  50. package/dist/commands/daemon/maintenance/resume.js +36 -0
  51. package/dist/commands/daemon/maintenance/status.d.ts +13 -0
  52. package/dist/commands/daemon/maintenance/status.js +36 -0
  53. package/dist/commands/doctor.d.ts +4 -1
  54. package/dist/commands/doctor.js +50 -6
  55. package/dist/commands/followups/plans/cancel-batch.js +6 -3
  56. package/dist/commands/followups/plans/capacity.js +7 -3
  57. package/dist/commands/followups/plans/observability.js +11 -3
  58. package/dist/commands/followups/plans/preferences/set.js +26 -8
  59. package/dist/commands/followups/plans/preferences.js +1 -1
  60. package/dist/commands/followups/plans/show.js +1 -1
  61. package/dist/commands/goals/key-results/assess.d.ts +36 -0
  62. package/dist/commands/goals/key-results/assess.js +110 -0
  63. package/dist/commands/goals/key-results/history.d.ts +30 -0
  64. package/dist/commands/goals/key-results/history.js +104 -0
  65. package/dist/commands/goals/key-results/list.d.ts +5 -4
  66. package/dist/commands/goals/key-results/list.js +12 -6
  67. package/dist/commands/goals/key-results/show.d.ts +4 -2
  68. package/dist/commands/goals/key-results/show.js +25 -4
  69. package/dist/commands/goals/key-results/update.d.ts +4 -0
  70. package/dist/commands/goals/key-results/update.js +18 -24
  71. package/dist/commands/goals/plan-now.js +12 -1
  72. package/dist/commands/goals/planner-compare.d.ts +30 -0
  73. package/dist/commands/goals/planner-compare.js +136 -0
  74. package/dist/commands/machines/dedicated/service/exec.d.ts +3 -0
  75. package/dist/commands/machines/dedicated/service/exec.js +70 -11
  76. package/dist/commands/machines/hosted/destroy.d.ts +1 -0
  77. package/dist/commands/machines/hosted/destroy.js +11 -1
  78. package/dist/commands/machines/hosted/exec.d.ts +1 -0
  79. package/dist/commands/machines/hosted/exec.js +12 -1
  80. package/dist/commands/machines/hosted/index.js +1 -0
  81. package/dist/commands/machines/hosted/operation.d.ts +14 -0
  82. package/dist/commands/machines/hosted/operation.js +51 -0
  83. package/dist/commands/machines/hosted/pull.js +1 -1
  84. package/dist/commands/machines/hosted/start.js +6 -2
  85. package/dist/commands/spaces/auto-executor/compare.d.ts +18 -0
  86. package/dist/commands/spaces/auto-executor/compare.js +139 -0
  87. package/dist/commands/spaces/auto-executor/runs.d.ts +3 -0
  88. package/dist/commands/spaces/auto-executor/runs.js +13 -1
  89. package/dist/commands/spaces/charter/create-from-description.d.ts +21 -0
  90. package/dist/commands/spaces/charter/create-from-description.js +77 -0
  91. package/dist/commands/spaces/charter/show.d.ts +22 -0
  92. package/dist/commands/spaces/charter/show.js +61 -0
  93. package/dist/commands/spaces/heartbeats/list.d.ts +1 -16
  94. package/dist/commands/spaces/heartbeats/list.js +13 -0
  95. package/dist/commands/spaces/install-template.js +3 -0
  96. package/dist/commands/spaces/loops/migrate.d.ts +32 -0
  97. package/dist/commands/spaces/loops/migrate.js +103 -0
  98. package/dist/commands/spaces/loops/release.d.ts +14 -0
  99. package/dist/commands/spaces/loops/release.js +59 -0
  100. package/dist/commands/spaces/notebook.d.ts +25 -0
  101. package/dist/commands/spaces/notebook.js +75 -0
  102. package/dist/commands/spaces/proposals/discard.d.ts +17 -0
  103. package/dist/commands/spaces/proposals/discard.js +17 -0
  104. package/dist/commands/spaces/proposals/keep.d.ts +17 -0
  105. package/dist/commands/spaces/proposals/keep.js +17 -0
  106. package/dist/commands/spaces/proposals/list.d.ts +24 -0
  107. package/dist/commands/spaces/proposals/list.js +89 -0
  108. package/dist/commands/spaces/skills/propose.d.ts +29 -0
  109. package/dist/commands/spaces/skills/propose.js +82 -0
  110. package/dist/commands/spaces/templates/fork.js +3 -0
  111. package/dist/commands/spaces/triggers/show.js +6 -0
  112. package/dist/commands/spaces/workflows/retry.d.ts +1 -0
  113. package/dist/commands/spaces/workflows/retry.js +8 -1
  114. package/dist/commands/spaces/workflows/triggers/create.js +3 -2
  115. package/dist/commands/spaces/workflows/triggers/fire.js +4 -0
  116. package/dist/commands/spaces/workflows/triggers/update.js +2 -1
  117. package/dist/commands/spaces/write-policy/set.d.ts +22 -0
  118. package/dist/commands/spaces/write-policy/set.js +82 -0
  119. package/dist/commands/spaces/write-policy/show.d.ts +19 -0
  120. package/dist/commands/spaces/write-policy/show.js +49 -0
  121. package/dist/commands/store/artifacts/receipt.d.ts +14 -0
  122. package/dist/commands/store/artifacts/receipt.js +34 -0
  123. package/dist/commands/store/artifacts/release.d.ts +2 -0
  124. package/dist/commands/store/artifacts/release.js +11 -0
  125. package/dist/commands/store/governance/publish-release.d.ts +2 -0
  126. package/dist/commands/store/governance/publish-release.js +30 -1
  127. package/dist/commands/store/governance/release-receipt.d.ts +12 -0
  128. package/dist/commands/store/governance/release-receipt.js +32 -0
  129. package/dist/commands/tasks/approvals/list.d.ts +11 -5
  130. package/dist/commands/tasks/approvals/list.js +13 -6
  131. package/dist/commands/tasks/attachments/facts.d.ts +12 -0
  132. package/dist/commands/tasks/attachments/facts.js +29 -0
  133. package/dist/commands/tasks/attachments/upload.d.ts +1 -0
  134. package/dist/commands/tasks/attachments/upload.js +16 -0
  135. package/dist/commands/tasks/bulk-update.js +35 -1
  136. package/dist/commands/tasks/context.d.ts +15 -0
  137. package/dist/commands/tasks/context.js +69 -0
  138. package/dist/commands/tasks/copy.d.ts +18 -0
  139. package/dist/commands/tasks/copy.js +85 -0
  140. package/dist/commands/tasks/create-tree.js +97 -23
  141. package/dist/commands/tasks/create.js +9 -1
  142. package/dist/commands/tasks/deliverable/add.js +20 -10
  143. package/dist/commands/tasks/move.js +8 -1
  144. package/dist/commands/tasks/operations/show.d.ts +16 -0
  145. package/dist/commands/tasks/operations/show.js +98 -0
  146. package/dist/commands/tasks/operations/wait.d.ts +22 -0
  147. package/dist/commands/tasks/operations/wait.js +114 -0
  148. package/dist/commands/tasks/preflight.d.ts +1 -0
  149. package/dist/commands/tasks/preflight.js +11 -1
  150. package/dist/commands/tasks/rearm-recurrence.js +4 -0
  151. package/dist/commands/tasks/result/show.js +22 -0
  152. package/dist/commands/tasks/result/submit.d.ts +1 -0
  153. package/dist/commands/tasks/result/submit.js +3 -0
  154. package/dist/commands/tasks/retry-receipt.d.ts +15 -0
  155. package/dist/commands/tasks/retry-receipt.js +89 -0
  156. package/dist/commands/tasks/retry-review.d.ts +16 -0
  157. package/dist/commands/tasks/retry-review.js +66 -0
  158. package/dist/commands/tasks/retry.d.ts +4 -8
  159. package/dist/commands/tasks/retry.js +34 -68
  160. package/dist/commands/tasks/runs.d.ts +21 -0
  161. package/dist/commands/tasks/runs.js +95 -0
  162. package/dist/commands/tasks/show.d.ts +2 -0
  163. package/dist/commands/tasks/show.js +15 -1
  164. package/dist/commands/tasks/start-receipt.d.ts +15 -0
  165. package/dist/commands/tasks/start-receipt.js +95 -0
  166. package/dist/commands/tasks/start.d.ts +4 -0
  167. package/dist/commands/tasks/start.js +49 -3
  168. package/dist/commands/tasks/update.js +3 -0
  169. package/dist/commands/tasks/upsert.js +17 -3
  170. package/dist/commands/tasks/watch.d.ts +3 -0
  171. package/dist/commands/tasks/watch.js +85 -20
  172. package/dist/commands/wiki/history.d.ts +33 -0
  173. package/dist/commands/wiki/history.js +134 -0
  174. package/dist/commands/wiki/ls.d.ts +2 -0
  175. package/dist/commands/wiki/ls.js +8 -0
  176. package/dist/commands/wiki/update.d.ts +3 -1
  177. package/dist/commands/wiki/update.js +24 -2
  178. package/dist/commands/wiki/write.d.ts +22 -0
  179. package/dist/commands/wiki/write.js +144 -6
  180. package/dist/generated/agent-guides.json +81 -81
  181. package/dist/generated/managed-instruction-guides.json +1 -1
  182. package/dist/lib/agent-guides.d.ts +9 -0
  183. package/dist/lib/agent-guides.js +23 -1
  184. package/dist/lib/agentic-stream.d.ts +5 -0
  185. package/dist/lib/agentic-stream.js +122 -3
  186. package/dist/lib/auth-diagnostics.d.ts +39 -0
  187. package/dist/lib/auth-diagnostics.js +71 -0
  188. package/dist/lib/cli-client-identity.d.ts +6 -0
  189. package/dist/lib/cli-client-identity.js +16 -0
  190. package/dist/lib/cli-installation-diagnostics.d.ts +52 -0
  191. package/dist/lib/cli-installation-diagnostics.js +254 -0
  192. package/dist/lib/command-hygiene.d.ts +45 -0
  193. package/dist/lib/command-hygiene.js +413 -0
  194. package/dist/lib/commitments.d.ts +64 -3
  195. package/dist/lib/commitments.js +34 -6
  196. package/dist/lib/completion-index.d.ts +16 -4
  197. package/dist/lib/completion-index.js +50 -14
  198. package/dist/lib/config.js +7 -1
  199. package/dist/lib/daemon-maintenance-command.d.ts +22 -0
  200. package/dist/lib/daemon-maintenance-command.js +39 -0
  201. package/dist/lib/daemon-maintenance.d.ts +275 -0
  202. package/dist/lib/daemon-maintenance.js +1035 -0
  203. package/dist/lib/dedicated-service.d.ts +3 -2
  204. package/dist/lib/dedicated-service.js +11 -3
  205. package/dist/lib/governed-store.d.ts +8 -0
  206. package/dist/lib/governed-store.js +5 -0
  207. package/dist/lib/hosted-machines.d.ts +33 -2
  208. package/dist/lib/hosted-machines.js +19 -1
  209. package/dist/lib/json-output.d.ts +1 -1
  210. package/dist/lib/machines.d.ts +9 -1
  211. package/dist/lib/machines.js +15 -1
  212. package/dist/lib/node-adapter.js +13 -0
  213. package/dist/lib/record-output.d.ts +22 -0
  214. package/dist/lib/record-output.js +78 -0
  215. package/dist/lib/roles.d.ts +3 -3
  216. package/dist/lib/scoped-memory-command.d.ts +18 -0
  217. package/dist/lib/scoped-memory-command.js +53 -2
  218. package/dist/lib/space-charter.d.ts +49 -0
  219. package/dist/lib/space-charter.js +78 -0
  220. package/dist/lib/space-loop-migration.d.ts +18 -0
  221. package/dist/lib/space-loop-migration.js +128 -0
  222. package/dist/lib/space-notebook.d.ts +22 -0
  223. package/dist/lib/space-notebook.js +140 -0
  224. package/dist/lib/space-proposal-decision-command.d.ts +36 -0
  225. package/dist/lib/space-proposal-decision-command.js +108 -0
  226. package/dist/lib/space-proposals.d.ts +44 -0
  227. package/dist/lib/space-proposals.js +186 -0
  228. package/dist/lib/space-templates.d.ts +8 -0
  229. package/dist/lib/space-templates.js +17 -0
  230. package/dist/lib/space-write-policy.d.ts +24 -0
  231. package/dist/lib/space-write-policy.js +103 -0
  232. package/dist/lib/task-agent-context-capabilities.d.ts +10 -0
  233. package/dist/lib/task-agent-context-capabilities.js +22 -0
  234. package/dist/lib/task-agent-context-compatibility.d.ts +9 -0
  235. package/dist/lib/task-agent-context-compatibility.js +30 -0
  236. package/dist/lib/task-asset-upload.d.ts +22 -0
  237. package/dist/lib/task-asset-upload.js +257 -29
  238. package/dist/lib/task-batch.d.ts +15 -1
  239. package/dist/lib/task-batch.js +35 -2
  240. package/dist/lib/task-operation-watch.d.ts +66 -0
  241. package/dist/lib/task-operation-watch.js +159 -0
  242. package/dist/lib/task-resolver.d.ts +1 -1
  243. package/dist/lib/task-resolver.js +4 -3
  244. package/dist/lib/task-work.d.ts +1 -1
  245. package/dist/lib/task-work.js +35 -1
  246. package/dist/lib/task-write-attribution.d.ts +14 -0
  247. package/dist/lib/task-write-attribution.js +35 -2
  248. package/dist/lib/triggers.d.ts +11 -0
  249. package/dist/lib/triggers.js +7 -0
  250. package/dist/lib/wiki-update.d.ts +1 -0
  251. package/dist/lib/wiki-update.js +10 -1
  252. package/dist/lib/wiki.js +4 -1
  253. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/computerWire.d.ts +9 -1
  254. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/computerWire.js +31 -15
  255. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/daemonToolApproval.js +1 -0
  256. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/daemonWire.js +13 -7
  257. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/guidedUpdate.d.ts +370 -0
  258. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/guidedUpdate.js +315 -0
  259. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/maintenanceReportWire.d.ts +178 -0
  260. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/maintenanceReportWire.js +262 -0
  261. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/toolApprovalSignature.d.ts +51 -0
  262. package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/toolApprovalSignature.js +106 -0
  263. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/computerWire.d.ts +9 -1
  264. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/computerWire.js +32 -5
  265. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/daemonToolApproval.js +1 -0
  266. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/daemonWire.js +33 -14
  267. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/guidedUpdate.d.ts +370 -0
  268. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/guidedUpdate.js +404 -0
  269. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/maintenanceReportWire.d.ts +178 -0
  270. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/maintenanceReportWire.js +342 -0
  271. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/toolApprovalSignature.d.ts +51 -0
  272. package/dist/node_modules/@skrr-ai/auth-core/dist/esm/toolApprovalSignature.js +138 -0
  273. package/dist/node_modules/@skrr-ai/auth-core/package.json +20 -0
  274. package/dist/node_modules/@skrr-ai/data-provider/index.js +27085 -20250
  275. package/oclif.manifest.json +10566 -7247
  276. package/package.json +20 -2
@@ -0,0 +1,36 @@
1
+ import type { KeyResultEvidenceRef } from '@skrr-ai/data-provider';
2
+ import { BaseCommand } from '../../../base-command';
3
+ /**
4
+ * `skrr goals key-results assess <goal-id> <kr-id>` — record a judgment of a
5
+ * key result (OSK-17987, decision D4). Wraps
6
+ * `POST /api/goals/:goalId/key-results/:krId/assessments` (data-provider
7
+ * `assessKeyResult`).
8
+ *
9
+ * How a key result is going is a judgment, and an Agent may make it — marking
10
+ * it `done` included. Nothing is refused for what is judged; the server records
11
+ * WHO judged (from the authenticated runtime: a Run proves an Agent, otherwise
12
+ * the credential decides), why, and on what evidence, and keeps every judgment
13
+ * (`goals key-results history`). A person overrides by judging again.
14
+ */
15
+ export default class GoalsKeyResultsAssess extends BaseCommand {
16
+ static description: string;
17
+ static examples: string[];
18
+ static args: {
19
+ goalId: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
20
+ krId: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
21
+ };
22
+ static flags: {
23
+ status: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
24
+ rationale: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
25
+ evidence: import("@oclif/core/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/interfaces").CustomOptions>;
26
+ progress: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
27
+ json: import("@oclif/core/interfaces").BooleanFlag<boolean>;
28
+ };
29
+ run(): Promise<void>;
30
+ }
31
+ /**
32
+ * `<kind>:<id-or-uri>` → a reference. A value that looks like a URL is a `uri`,
33
+ * anything else an `id` — the same reading `tasks expectations assess` uses.
34
+ * Exported for `assess.spec.ts`.
35
+ */
36
+ export declare function parseEvidenceRef(raw: string): KeyResultEvidenceRef;
@@ -0,0 +1,110 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.parseEvidenceRef = parseEvidenceRef;
4
+ const core_1 = require("@oclif/core");
5
+ const data_provider_1 = require("@skrr-ai/data-provider");
6
+ const base_command_1 = require("../../../base-command");
7
+ const history_1 = require("./history");
8
+ /**
9
+ * `skrr goals key-results assess <goal-id> <kr-id>` — record a judgment of a
10
+ * key result (OSK-17987, decision D4). Wraps
11
+ * `POST /api/goals/:goalId/key-results/:krId/assessments` (data-provider
12
+ * `assessKeyResult`).
13
+ *
14
+ * How a key result is going is a judgment, and an Agent may make it — marking
15
+ * it `done` included. Nothing is refused for what is judged; the server records
16
+ * WHO judged (from the authenticated runtime: a Run proves an Agent, otherwise
17
+ * the credential decides), why, and on what evidence, and keeps every judgment
18
+ * (`goals key-results history`). A person overrides by judging again.
19
+ */
20
+ class GoalsKeyResultsAssess extends base_command_1.BaseCommand {
21
+ static description = 'Record a judgment of a key result: its status, why, and what it rests on';
22
+ static examples = [
23
+ '<%= config.bin %> goals key-results assess <goal-id> <kr-id> --status at_risk --rationale "Signups flat for two weeks"',
24
+ '<%= config.bin %> goals key-results assess <goal-id> <kr-id> --status done --rationale "Shipped and adopted" --evidence task:OSK-42 --evidence url:https://example.com/dashboard',
25
+ '<%= config.bin %> goals key-results assess <goal-id> <kr-id> --status on_track --progress 60 --rationale "3 of 5 cohorts migrated"',
26
+ ];
27
+ static args = {
28
+ goalId: core_1.Args.string({ description: 'Goal ID', required: true, ignoreStdin: true }),
29
+ krId: core_1.Args.string({ description: 'Key Result ID', required: true, ignoreStdin: true }),
30
+ };
31
+ static flags = {
32
+ status: core_1.Flags.string({
33
+ description: 'Your judgment of how the key result is going',
34
+ required: true,
35
+ options: [...data_provider_1.KEY_RESULT_STATUS_VALUES],
36
+ }),
37
+ rationale: core_1.Flags.string({
38
+ description: 'Why: what you looked at and what it showed',
39
+ required: true,
40
+ }),
41
+ evidence: core_1.Flags.string({
42
+ description: 'What it rests on, as <kind>:<id-or-uri> (repeatable)',
43
+ multiple: true,
44
+ }),
45
+ progress: core_1.Flags.integer({
46
+ description: 'Optional: how far along it is, 0–100',
47
+ min: 0,
48
+ max: 100,
49
+ }),
50
+ json: core_1.Flags.boolean({ description: 'Output the assessed key result as JSON' }),
51
+ };
52
+ async run() {
53
+ this.requireAuth();
54
+ const { args, flags } = await this.parse(GoalsKeyResultsAssess);
55
+ let evidenceRefs = [];
56
+ try {
57
+ evidenceRefs = (flags.evidence || []).map(parseEvidenceRef);
58
+ }
59
+ catch (err) {
60
+ this.error(err.message, { exit: 1 });
61
+ }
62
+ let kr;
63
+ try {
64
+ kr = await data_provider_1.dataService.assessKeyResult({
65
+ goalId: args.goalId,
66
+ krId: args.krId,
67
+ data: {
68
+ status: flags.status,
69
+ rationale: flags.rationale,
70
+ ...(flags.progress !== undefined ? { progress: flags.progress } : {}),
71
+ ...(evidenceRefs.length > 0 ? { evidenceRefs } : {}),
72
+ },
73
+ });
74
+ }
75
+ catch (err) {
76
+ this.handleApiError(err);
77
+ }
78
+ // An unattended judgment the Space's write policy held for approval
79
+ // (`202 pending_approval`, OSK-17994): nothing was recorded yet.
80
+ if (this.reportHeldSpaceWrite(kr, { json: flags.json }))
81
+ return;
82
+ if (flags.json) {
83
+ this.printJsonResult(kr);
84
+ return;
85
+ }
86
+ const k = kr;
87
+ // Echo what the SERVER recorded — in particular who it says judged, which
88
+ // is read from this process's credential and Run, not from anything sent.
89
+ this.log(`Assessed key result ${k.id ?? args.krId} on goal ${args.goalId}.`);
90
+ if (k.assessment) {
91
+ for (const line of (0, history_1.describeAssessment)(k.assessment))
92
+ this.log(line);
93
+ }
94
+ }
95
+ }
96
+ exports.default = GoalsKeyResultsAssess;
97
+ /**
98
+ * `<kind>:<id-or-uri>` → a reference. A value that looks like a URL is a `uri`,
99
+ * anything else an `id` — the same reading `tasks expectations assess` uses.
100
+ * Exported for `assess.spec.ts`.
101
+ */
102
+ function parseEvidenceRef(raw) {
103
+ const split = raw.indexOf(':');
104
+ if (split < 1 || split === raw.length - 1) {
105
+ throw new Error(`--evidence must be <kind>:<id-or-uri> (got "${raw}")`);
106
+ }
107
+ const kind = raw.slice(0, split);
108
+ const value = raw.slice(split + 1);
109
+ return /^https?:|^file:/.test(value) ? { kind, uri: value } : { kind, id: value };
110
+ }
@@ -0,0 +1,30 @@
1
+ import type { KeyResultAssessment } from '@skrr-ai/data-provider';
2
+ import { BaseCommand } from '../../../base-command';
3
+ /**
4
+ * `skrr goals key-results history <goal-id> <kr-id>` — every judgment of a key
5
+ * result, newest first (OSK-17987). Wraps
6
+ * `GET /api/goals/:goalId/key-results/:krId/assessments` (data-provider
7
+ * `listKeyResultAssessments`).
8
+ *
9
+ * Each row says who judged — `agent`, `person` or `automation`, as the server
10
+ * read it from the credential and Run, never as the writer claimed — and an
11
+ * override reads as one: a person's row directly above an agent's.
12
+ */
13
+ export default class GoalsKeyResultsHistory extends BaseCommand {
14
+ static description: string;
15
+ static examples: string[];
16
+ static args: {
17
+ goalId: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
18
+ krId: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
19
+ };
20
+ static flags: {
21
+ limit: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
22
+ cursor: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
23
+ json: import("@oclif/core/interfaces").BooleanFlag<boolean>;
24
+ };
25
+ run(): Promise<void>;
26
+ }
27
+ /** `agent`, `person`, `automation` — what the server recorded, never guessed. */
28
+ export declare function describeAssessor(assessment: KeyResultAssessment | undefined | null): string;
29
+ /** The lines `assess` and `show` print for one judgment. */
30
+ export declare function describeAssessment(assessment: KeyResultAssessment): string[];
@@ -0,0 +1,104 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.describeAssessor = describeAssessor;
4
+ exports.describeAssessment = describeAssessment;
5
+ const core_1 = require("@oclif/core");
6
+ const data_provider_1 = require("@skrr-ai/data-provider");
7
+ const base_command_1 = require("../../../base-command");
8
+ const format_1 = require("../../../lib/format");
9
+ /**
10
+ * `skrr goals key-results history <goal-id> <kr-id>` — every judgment of a key
11
+ * result, newest first (OSK-17987). Wraps
12
+ * `GET /api/goals/:goalId/key-results/:krId/assessments` (data-provider
13
+ * `listKeyResultAssessments`).
14
+ *
15
+ * Each row says who judged — `agent`, `person` or `automation`, as the server
16
+ * read it from the credential and Run, never as the writer claimed — and an
17
+ * override reads as one: a person's row directly above an agent's.
18
+ */
19
+ class GoalsKeyResultsHistory extends base_command_1.BaseCommand {
20
+ static description = "List a key result's judgments, newest first";
21
+ static examples = [
22
+ '<%= config.bin %> goals key-results history <goal-id> <kr-id>',
23
+ '<%= config.bin %> goals key-results history <goal-id> <kr-id> --limit 50 --json',
24
+ ];
25
+ static args = {
26
+ goalId: core_1.Args.string({ description: 'Goal ID', required: true, ignoreStdin: true }),
27
+ krId: core_1.Args.string({ description: 'Key Result ID', required: true, ignoreStdin: true }),
28
+ };
29
+ static flags = {
30
+ limit: core_1.Flags.integer({ description: 'How many judgments to show (1–100)', min: 1, max: 100 }),
31
+ cursor: core_1.Flags.string({ description: 'Continue from a previous page' }),
32
+ json: core_1.Flags.boolean({ description: 'Output as JSON' }),
33
+ };
34
+ async run() {
35
+ this.requireAuth();
36
+ const { args, flags } = await this.parse(GoalsKeyResultsHistory);
37
+ let page;
38
+ try {
39
+ page = await data_provider_1.dataService.listKeyResultAssessments(args.goalId, args.krId, {
40
+ ...(flags.limit !== undefined ? { limit: flags.limit } : {}),
41
+ ...(flags.cursor ? { cursor: flags.cursor } : {}),
42
+ });
43
+ }
44
+ catch (err) {
45
+ this.handleApiError(err);
46
+ }
47
+ if (flags.json) {
48
+ this.printJsonResult(page);
49
+ return;
50
+ }
51
+ const entries = page?.data ?? [];
52
+ if (entries.length === 0) {
53
+ this.log('No judgments recorded for this key result.');
54
+ return;
55
+ }
56
+ (0, format_1.renderTable)(entries.map((entry) => ({
57
+ rev: String(entry.revisionNumber ?? '-'),
58
+ at: formatAt(entry.assessment?.at),
59
+ status: String(entry.assessment?.status ?? '-'),
60
+ by: describeAssessor(entry.assessment),
61
+ progress: typeof entry.assessment?.progress === 'number'
62
+ ? `${Math.round(entry.assessment.progress)}%`
63
+ : '-',
64
+ why: oneLine(entry.assessment?.rationale) || '(no reason given)',
65
+ })), [
66
+ { key: 'rev', header: 'REV' },
67
+ { key: 'at', header: 'AT' },
68
+ { key: 'status', header: 'STATUS' },
69
+ { key: 'by', header: 'BY' },
70
+ { key: 'progress', header: 'PROGRESS' },
71
+ { key: 'why', header: 'WHY', maxWidth: 60 },
72
+ ], (line) => this.log(line));
73
+ if (page?.has_more && page.next_cursor) {
74
+ this.log(`More: --cursor ${page.next_cursor}`);
75
+ }
76
+ }
77
+ }
78
+ exports.default = GoalsKeyResultsHistory;
79
+ /** `agent`, `person`, `automation` — what the server recorded, never guessed. */
80
+ function describeAssessor(assessment) {
81
+ const kind = assessment?.assessedBy?.kind;
82
+ return kind === 'agent' || kind === 'person' || kind === 'automation' ? kind : 'unattributed';
83
+ }
84
+ /** The lines `assess` and `show` print for one judgment. */
85
+ function describeAssessment(assessment) {
86
+ const lines = [`Status: ${assessment.status} (${describeAssessor(assessment)})`];
87
+ if (typeof assessment.progress === 'number') {
88
+ lines.push(`Progress: ${Math.round(assessment.progress)}% (judged)`);
89
+ }
90
+ lines.push(`Why: ${oneLine(assessment.rationale) || '(no reason given)'}`);
91
+ for (const ref of assessment.evidenceRefs ?? []) {
92
+ lines.push(`Evidence: ${ref.kind}:${ref.id ?? ref.uri ?? ''}`);
93
+ }
94
+ if (assessment.runId)
95
+ lines.push(`Run: ${assessment.runId}`);
96
+ lines.push(`At: ${formatAt(assessment.at)}`);
97
+ return lines;
98
+ }
99
+ function oneLine(text) {
100
+ return typeof text === 'string' ? text.replace(/\s+/g, ' ').trim() : '';
101
+ }
102
+ function formatAt(at) {
103
+ return at ? String(at).slice(0, 19).replace('T', ' ') : '-';
104
+ }
@@ -1,10 +1,11 @@
1
1
  import { BaseCommand } from '../../../base-command';
2
2
  /**
3
3
  * `skrr goals key-results list <goal-id>` — the goal's Key Results (the
4
- * measurable OKR outcomes under it). For KRs in `auto` progress mode the server
5
- * computes progress from the linked tasks' done ratio; `resolveKeyResultProgress`
6
- * surfaces that computed value, falling back to the stored `progress` for
7
- * `manual` KRs.
4
+ * measurable OKR outcomes under it). PROGRESS is the current judgment's number
5
+ * when it stated one (decision D4), else the server-computed linked-task ratio
6
+ * for `auto` KRs and the stored `progress` for `manual` ones
7
+ * (`resolveKeyResultProgress`). BY is who set the status; TASKS DONE is the
8
+ * activity signal (linked tasks done / linked), shown beside the judgment.
8
9
  *
9
10
  * Wraps `GET /api/goals/:goalId/key-results` (data-provider `listKeyResults`).
10
11
  */
@@ -7,10 +7,11 @@ const base_command_1 = require("../../../base-command");
7
7
  const format_1 = require("../../../lib/format");
8
8
  /**
9
9
  * `skrr goals key-results list <goal-id>` — the goal's Key Results (the
10
- * measurable OKR outcomes under it). For KRs in `auto` progress mode the server
11
- * computes progress from the linked tasks' done ratio; `resolveKeyResultProgress`
12
- * surfaces that computed value, falling back to the stored `progress` for
13
- * `manual` KRs.
10
+ * measurable OKR outcomes under it). PROGRESS is the current judgment's number
11
+ * when it stated one (decision D4), else the server-computed linked-task ratio
12
+ * for `auto` KRs and the stored `progress` for `manual` ones
13
+ * (`resolveKeyResultProgress`). BY is who set the status; TASKS DONE is the
14
+ * activity signal (linked tasks done / linked), shown beside the judgment.
14
15
  *
15
16
  * Wraps `GET /api/goals/:goalId/key-results` (data-provider `listKeyResults`).
16
17
  */
@@ -50,13 +51,17 @@ class GoalsKeyResultsList extends base_command_1.BaseCommand {
50
51
  .sort((a, b) => (a.order ?? 0) - (b.order ?? 0))
51
52
  .map((kr) => {
52
53
  const progress = (0, data_provider_1.resolveKeyResultProgress)(kr);
54
+ const activity = (0, data_provider_1.resolveKeyResultActivity)(kr);
53
55
  return {
54
56
  id: String(kr.id ?? '-'),
55
57
  title: String(kr.title ?? '-'),
56
58
  status: String(kr.status ?? '-'),
59
+ // Who set the status: the server's reading of the credential and Run.
60
+ by: (0, data_provider_1.keyResultAssessorKind)(kr) ?? '-',
57
61
  mode: String(kr.progressMode ?? '-'),
58
62
  progress: typeof progress === 'number' ? `${Math.round(progress)}%` : '-',
59
- linked: kr._linkedTaskCount != null ? String(kr._linkedTaskCount) : '-',
63
+ // Linked tasks done — activity beside the judgment, not the progress.
64
+ activity: activity ? `${activity.done}/${activity.total}` : '-',
60
65
  order: String(kr.order ?? 0),
61
66
  };
62
67
  });
@@ -64,9 +69,10 @@ class GoalsKeyResultsList extends base_command_1.BaseCommand {
64
69
  { key: 'id', header: 'ID' },
65
70
  { key: 'title', header: 'TITLE', maxWidth: 44 },
66
71
  { key: 'status', header: 'STATUS' },
72
+ { key: 'by', header: 'BY' },
67
73
  { key: 'mode', header: 'MODE' },
68
74
  { key: 'progress', header: 'PROGRESS' },
69
- { key: 'linked', header: 'TASKS' },
75
+ { key: 'activity', header: 'TASKS DONE' },
70
76
  { key: 'order', header: 'ORDER' },
71
77
  ], (line) => this.log(line));
72
78
  }
@@ -2,8 +2,10 @@ import { BaseCommand } from '../../../base-command';
2
2
  /**
3
3
  * `skrr goals key-results show <goal-id> <kr-id>` — full detail for one key
4
4
  * result. Wraps `GET /api/goals/:goalId/key-results/:krId` (data-provider
5
- * `getKeyResult`). For `auto` KRs the displayed progress is the server-computed
6
- * value; the stored `progress` field is only authoritative in `manual` mode.
5
+ * `getKeyResult`). Progress is the current judgment's number when it stated
6
+ * one (decision D4); otherwise the server-computed value for `auto` KRs and the
7
+ * stored `progress` for `manual` ones. Linked-task completion is printed
8
+ * separately as ACTIVITY, and the status says who set it.
7
9
  */
8
10
  export default class GoalsKeyResultsShow extends BaseCommand {
9
11
  static description: string;
@@ -3,11 +3,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
4
  const data_provider_1 = require("@skrr-ai/data-provider");
5
5
  const base_command_1 = require("../../../base-command");
6
+ const history_1 = require("./history");
6
7
  /**
7
8
  * `skrr goals key-results show <goal-id> <kr-id>` — full detail for one key
8
9
  * result. Wraps `GET /api/goals/:goalId/key-results/:krId` (data-provider
9
- * `getKeyResult`). For `auto` KRs the displayed progress is the server-computed
10
- * value; the stored `progress` field is only authoritative in `manual` mode.
10
+ * `getKeyResult`). Progress is the current judgment's number when it stated
11
+ * one (decision D4); otherwise the server-computed value for `auto` KRs and the
12
+ * stored `progress` for `manual` ones. Linked-task completion is printed
13
+ * separately as ACTIVITY, and the status says who set it.
11
14
  */
12
15
  class GoalsKeyResultsShow extends base_command_1.BaseCommand {
13
16
  static description = 'Show a key result';
@@ -38,18 +41,36 @@ class GoalsKeyResultsShow extends base_command_1.BaseCommand {
38
41
  }
39
42
  const k = kr;
40
43
  const progress = (0, data_provider_1.resolveKeyResultProgress)(k);
44
+ const assessment = (0, data_provider_1.currentKeyResultAssessment)(k);
45
+ const activity = (0, data_provider_1.resolveKeyResultActivity)(k);
41
46
  this.log(`ID: ${k.id}`);
42
47
  this.log(`Goal: ${k.goalId}`);
43
48
  this.log(`Title: ${k.title}`);
44
49
  if (k.description) {
45
50
  this.log(`Description: ${k.description}`);
46
51
  }
47
- this.log(`Status: ${k.status}`);
52
+ this.log(`Status: ${k.status} ${assessment ? `(${(0, history_1.describeAssessor)(assessment)})` : '(not assessed)'}`);
48
53
  this.log(`Mode: ${k.progressMode}`);
49
54
  this.log(`Progress: ${typeof progress === 'number' ? `${Math.round(progress)}%` : '-'}`);
50
- if (k.progressMode === 'auto') {
55
+ if (typeof assessment?.progress === 'number') {
56
+ this.log(' (judged in the latest assessment)');
57
+ }
58
+ else if (k.progressMode === 'auto') {
51
59
  this.log(` (computed from ${k._linkedTaskCount ?? 0} linked task(s))`);
52
60
  }
61
+ this.log(`Activity: ${activity ? `${activity.done} of ${activity.total} linked task(s) done` : '-'}`);
62
+ if (assessment) {
63
+ const why = assessment.rationale?.replace(/\s+/g, ' ').trim();
64
+ this.log(`Judged: ${String(assessment.at ?? '')
65
+ .slice(0, 19)
66
+ .replace('T', ' ')}`);
67
+ this.log(`Why: ${why || '(no reason given)'}`);
68
+ for (const ref of assessment.evidenceRefs ?? []) {
69
+ this.log(`Evidence: ${ref.kind}:${ref.id ?? ref.uri ?? ''}`);
70
+ }
71
+ if (assessment.runId)
72
+ this.log(`Run: ${assessment.runId}`);
73
+ }
53
74
  this.log(`Order: ${k.order ?? 0}`);
54
75
  }
55
76
  }
@@ -4,6 +4,10 @@ import { BaseCommand } from '../../../base-command';
4
4
  * `PATCH /api/goals/:goalId/key-results/:krId` (data-provider `updateKeyResult`).
5
5
  * Only the fields you pass change. `--clear-description` sends `description:
6
6
  * null`, the server's signal to clear the field (distinct from an empty string).
7
+ *
8
+ * `--status` and `--progress` are a judgment (decision D4): the server records
9
+ * them as an assessment with who made it and no reason. To say why and on what
10
+ * evidence, use `goals key-results assess`.
7
11
  */
8
12
  export default class GoalsKeyResultsUpdate extends BaseCommand {
9
13
  static description: string;
@@ -6,11 +6,16 @@ const core_1 = require("@oclif/core");
6
6
  const data_provider_1 = require("@skrr-ai/data-provider");
7
7
  const base_command_1 = require("../../../base-command");
8
8
  const prompt_1 = require("../../../lib/prompt");
9
+ const history_1 = require("./history");
9
10
  /**
10
11
  * `skrr goals key-results update <goal-id> <kr-id>` — patch a key result. Wraps
11
12
  * `PATCH /api/goals/:goalId/key-results/:krId` (data-provider `updateKeyResult`).
12
13
  * Only the fields you pass change. `--clear-description` sends `description:
13
14
  * null`, the server's signal to clear the field (distinct from an empty string).
15
+ *
16
+ * `--status` and `--progress` are a judgment (decision D4): the server records
17
+ * them as an assessment with who made it and no reason. To say why and on what
18
+ * evidence, use `goals key-results assess`.
14
19
  */
15
20
  class GoalsKeyResultsUpdate extends base_command_1.BaseCommand {
16
21
  static description = 'Update a key result';
@@ -92,6 +97,10 @@ class GoalsKeyResultsUpdate extends base_command_1.BaseCommand {
92
97
  catch (err) {
93
98
  this.handleApiError(err);
94
99
  }
100
+ // A status or progress edit is a judgment the Space's write policy may hold
101
+ // for approval (`202 pending_approval`, OSK-17994): nothing was changed yet.
102
+ if (this.reportHeldSpaceWrite(updated, { json: flags.json }))
103
+ return;
95
104
  if (flags.json) {
96
105
  this.log(JSON.stringify(updated, null, 2));
97
106
  return;
@@ -106,10 +115,15 @@ class GoalsKeyResultsUpdate extends base_command_1.BaseCommand {
106
115
  .map((field) => `${field}=${describeField(k, field)}`)
107
116
  .join(' ');
108
117
  this.log(`Updated key result ${k.id ?? args.krId} on goal ${args.goalId}: ${echo}`);
109
- // The write echoes the number back, so without this the caller has every
110
- // reason to believe it took — and then `key-results list` shows `-`.
111
- if (k.progressMode === 'auto' && flags.progress !== undefined) {
112
- this.warn(`The value is stored. ${AUTO_MODE_NOTE}`);
118
+ // A status or progress edit is recorded as a judgment; say whose the server
119
+ // recorded it as (read from this credential and Run, not from anything
120
+ // sent), and that it carries no reason.
121
+ if (flags.status !== undefined || flags.progress !== undefined) {
122
+ const assessment = k.assessment;
123
+ if (assessment) {
124
+ this.log(`Recorded as a judgment by: ${(0, history_1.describeAssessor)(assessment)}, with no reason given. ` +
125
+ 'Use `goals key-results assess --rationale` to say why.');
126
+ }
113
127
  }
114
128
  // `done` beside `25%` on one row, with nothing reconciling them. The two
115
129
  // ARE independent axes — a key result can be closed out incomplete, and
@@ -148,23 +162,3 @@ function describeField(kr, field) {
148
162
  return '(not returned)';
149
163
  return typeof value === 'string' ? value : JSON.stringify(value);
150
164
  }
151
- /**
152
- * Why an `auto` key result reads as `-` from the CLI.
153
- *
154
- * Auto progress is computed from tasks linked to THIS key result
155
- * (`Task.keyResultIds`), and the task↔key-result link is a DOCUMENTED
156
- * omission from the CLI surface — it sits in `domain-api-parity.spec.ts`'s
157
- * allowlist with a stated reason. So `--progress-mode auto` is offered by a
158
- * surface that cannot make it move, and `resolveKeyResultProgress` renders
159
- * `_computedProgress ?? null` for auto, i.e. `-`, while a `--progress` value
160
- * you set is stored and returned by `update`.
161
- *
162
- * The result was one CLI reporting two different values for one field: the
163
- * write echoed 40 and the list showed `-`. Saying so at the point of use is
164
- * the honest fix; silently rendering the stored number instead would hide a
165
- * real distinction (a manual value is not a computed one), and adding the
166
- * link command would reverse a recorded decision.
167
- */
168
- const AUTO_MODE_NOTE = 'Auto progress is computed from tasks linked to this key result, and linking a task to a key ' +
169
- 'result is deliberately not in the CLI — so this reads as "-" here until it is linked ' +
170
- 'elsewhere. Use --progress-mode manual to track a number from the CLI.';
@@ -23,7 +23,12 @@ const TIMEOUT_STATUSES = new Set([408, 504, 524]);
23
23
  * to run later. Everything else (`goal_archived`, `goal_planner_disabled`, …)
24
24
  * needs the user to change something first, so a script retrying it would spin.
25
25
  */
26
- const TRANSIENT_SKIP_REASONS = new Set(['lock_held', 'not_due', 'schedule_superseded']);
26
+ const TRANSIENT_SKIP_REASONS = new Set([
27
+ 'lock_held',
28
+ 'not_due',
29
+ 'schedule_superseded',
30
+ 'goal_turn_unreadable',
31
+ ]);
27
32
  /**
28
33
  * Turn the planner's internal `reason` enum into a sentence.
29
34
  *
@@ -66,6 +71,10 @@ function describePlannerReason(reason) {
66
71
  return 'the planner ran and found nothing to add or refine';
67
72
  case 'one_voice_busy':
68
73
  return 'another agent was already speaking for this owner, so the tick stayed quiet';
74
+ case 'goal_loop_holds_turn':
75
+ return "a goal_advance loop holds this goal's planning turn, so the planner stood down (ask the loop instead: `commitments check-now <id>`; cancelling it or detaching its advance link hands the goal back)";
76
+ case 'goal_turn_unreadable':
77
+ return 'whether a goal_advance loop holds this goal could not be read, so the planner did not run';
69
78
  default:
70
79
  // `one_voice_<something>` is a family the server composes at run time.
71
80
  if (reason.startsWith('one_voice_')) {
@@ -199,9 +208,11 @@ class GoalsPlanNow extends base_command_1.BaseCommand {
199
208
  const retry = transient
200
209
  ? ` Re-run \`${this.config.bin} goals plan-now ${args.id}\` to try again.`
201
210
  : '';
211
+ const loop = r?.commitmentId ? ` The loop is commitment ${r.commitmentId}.` : '';
202
212
  this.failWithCliError({
203
213
  message: `The planner did not run for goal ${args.id}` +
204
214
  (reasonText ? `: ${reasonText}.` : '.') +
215
+ loop +
205
216
  backfilled +
206
217
  retry,
207
218
  code: 'PLANNER_TICK_NOT_RUN',
@@ -0,0 +1,30 @@
1
+ import { type GoalPlanningComparison } from '@skrr-ai/data-provider';
2
+ import { BaseCommand } from '../../base-command';
3
+ /** The comparison as the lines the command prints. Pure, so it is tested as such. */
4
+ export declare function comparisonLines(result: GoalPlanningComparison): string[];
5
+ /**
6
+ * `skrr goals planner-compare <goal-id>` (OSK-18012): GoalPlanner beside the
7
+ * Goal's `goal_advance` loop, read from `GET /api/goals/:goalId/planning-comparison`.
8
+ *
9
+ * What it is for: the evidence to retire the planner for this Goal. Over a
10
+ * window of at least seven days in which each holder held the Goal: the loop
11
+ * turned at the Goal's pace (its turns and the planner ticks it held), it judged
12
+ * the key results (the planner never does), its open and failed work is no
13
+ * worse than the planner's, the key results it held over moved no worse, and
14
+ * concurrent turns are 0. Every stop of the loop is explained in its Cycles
15
+ * (`commitments cycles <id>`).
16
+ */
17
+ export default class GoalsPlannerCompare extends BaseCommand {
18
+ static description: string;
19
+ static examples: string[];
20
+ static args: {
21
+ id: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
22
+ };
23
+ static flags: {
24
+ json: import("@oclif/core/interfaces").BooleanFlag<boolean>;
25
+ days: import("@oclif/core/interfaces").OptionFlag<number | undefined, import("@oclif/core/interfaces").CustomOptions>;
26
+ since: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
27
+ until: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
28
+ };
29
+ run(): Promise<void>;
30
+ }