@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,159 @@
1
+ "use strict";
2
+ /**
3
+ * Read-only waiting for a server-authoritative Task Operation.
4
+ *
5
+ * A Task status is intentionally not used as a completion signal here. One
6
+ * Task can have several sequential or competing operations, so only the
7
+ * operation's immutable id and server projection may settle this wait.
8
+ */
9
+ Object.defineProperty(exports, "__esModule", { value: true });
10
+ exports.parseTaskOperationWatchDuration = parseTaskOperationWatchDuration;
11
+ exports.classifyTaskOperation = classifyTaskOperation;
12
+ exports.watchTaskOperation = watchTaskOperation;
13
+ exports.taskOperationCheckpointLine = taskOperationCheckpointLine;
14
+ // These are operation outcomes, not Task-execution outcomes. A start can be
15
+ // successfully accepted and a retry successfully admitted while its execution
16
+ // Run is still active; waiting on the Operation must stop successfully at that
17
+ // durable boundary rather than misreporting it as an unknown terminal state.
18
+ const SUCCESS_STATES = new Set(['succeeded', 'completed', 'accepted', 'admitted']);
19
+ const FAILED_STATES = new Set(['failed', 'cancelled', 'canceled', 'abandoned', 'rejected', 'refused']);
20
+ /** Parse the same bounded duration grammar used by `tasks watch`. */
21
+ function parseTaskOperationWatchDuration(value) {
22
+ if (!value)
23
+ return null;
24
+ const match = value.trim().match(/^(\d+)(ms|s|m|h)?$/i);
25
+ if (!match)
26
+ throw new Error(`Invalid --timeout value: ${value}`);
27
+ const amount = Number(match[1]);
28
+ if (!Number.isSafeInteger(amount) || amount < 0) {
29
+ throw new Error(`Invalid --timeout value: ${value}`);
30
+ }
31
+ const unit = (match[2] || 's').toLowerCase();
32
+ if (unit === 'ms')
33
+ return amount;
34
+ if (unit === 's')
35
+ return amount * 1000;
36
+ if (unit === 'm')
37
+ return amount * 60 * 1000;
38
+ if (unit === 'h')
39
+ return amount * 60 * 60 * 1000;
40
+ throw new Error(`Invalid --timeout value: ${value}`);
41
+ }
42
+ /**
43
+ * Classify only server-declared terminal status or the narrow, stable terminal
44
+ * vocabulary. An absent/malformed/unknown projection never becomes success by
45
+ * inference, and neither does a Task's own workflow status.
46
+ */
47
+ function classifyTaskOperation(operation) {
48
+ if (!operation || typeof operation !== 'object') {
49
+ return { terminal: false, result: 'unknown' };
50
+ }
51
+ const state = typeof operation.state === 'string' ? operation.state.trim().toLowerCase() : '';
52
+ const outcome = typeof operation.outcome === 'string' ? operation.outcome.trim().toLowerCase() : '';
53
+ if (SUCCESS_STATES.has(state) || SUCCESS_STATES.has(outcome)) {
54
+ return { terminal: true, result: 'succeeded' };
55
+ }
56
+ if (FAILED_STATES.has(state) || FAILED_STATES.has(outcome)) {
57
+ return { terminal: true, result: 'failed' };
58
+ }
59
+ if (operation.terminal === true) {
60
+ // A terminal projection without a known outcome is intentionally not
61
+ // recast as success. The caller sees `unknown` and must inspect its
62
+ // immutable recovery/receipt fields instead of issuing a new mutation.
63
+ return { terminal: true, result: 'unknown' };
64
+ }
65
+ return { terminal: false, result: state === 'unknown' ? 'unknown' : 'pending' };
66
+ }
67
+ function operationSignature(operation) {
68
+ if (!operation)
69
+ return 'null';
70
+ return JSON.stringify({
71
+ state: operation.state,
72
+ phase: operation.phase,
73
+ terminal: operation.terminal,
74
+ outcome: operation.outcome,
75
+ updatedAt: operation.updatedAt,
76
+ recovery: operation.recovery,
77
+ });
78
+ }
79
+ function defaultSleep(milliseconds) {
80
+ return new Promise((resolve) => setTimeout(resolve, milliseconds));
81
+ }
82
+ /**
83
+ * Poll one immutable operation until it reaches an authoritative terminal
84
+ * result. Every read is emitted as a checkpoint so JSON consumers can prove
85
+ * liveness even where a server does not yet offer an event stream.
86
+ */
87
+ async function watchTaskOperation(options) {
88
+ const now = options.now ?? Date.now;
89
+ const sleep = options.sleep ?? defaultSleep;
90
+ const startedAt = now();
91
+ let lastSignature = null;
92
+ while (true) {
93
+ const operation = await options.read(options.taskId, options.operationId);
94
+ const classification = classifyTaskOperation(operation);
95
+ const signature = operationSignature(operation);
96
+ const changed = signature !== lastSignature;
97
+ lastSignature = signature;
98
+ await options.onCheckpoint({
99
+ object: 'task_operation_watch_checkpoint',
100
+ schemaVersion: 1,
101
+ observedAt: new Date(now()).toISOString(),
102
+ taskId: options.taskId,
103
+ operationId: options.operationId,
104
+ observation: 'observed',
105
+ changed,
106
+ terminal: classification.terminal,
107
+ result: classification.result,
108
+ operation,
109
+ });
110
+ if (classification.terminal) {
111
+ if (classification.result === 'succeeded' || classification.result === 'failed') {
112
+ return { terminal: true, result: classification.result, operation };
113
+ }
114
+ // A terminal-but-unclassified operation is a server truth that requires
115
+ // an explicit user inspection, not an accidental green result.
116
+ const error = Object.assign(new Error('Task operation reached an unknown terminal state.'), {
117
+ code: 'TASK_OPERATION_TERMINAL_UNKNOWN',
118
+ operation,
119
+ });
120
+ throw error;
121
+ }
122
+ if (options.timeoutMs !== null && now() - startedAt >= options.timeoutMs) {
123
+ await options.onCheckpoint({
124
+ object: 'task_operation_watch_checkpoint',
125
+ schemaVersion: 1,
126
+ observedAt: new Date(now()).toISOString(),
127
+ taskId: options.taskId,
128
+ operationId: options.operationId,
129
+ observation: 'timeout',
130
+ changed: false,
131
+ terminal: false,
132
+ result: classification.result,
133
+ operation,
134
+ });
135
+ const error = Object.assign(new Error(`Timed out waiting for task operation ${options.operationId}.`), {
136
+ code: 'TASK_OPERATION_WAIT_TIMEOUT',
137
+ exitCode: 124,
138
+ operation,
139
+ });
140
+ throw error;
141
+ }
142
+ await sleep(options.intervalMs);
143
+ }
144
+ }
145
+ function taskOperationCheckpointLine(checkpoint) {
146
+ if (checkpoint.observation === 'timeout') {
147
+ return `[${checkpoint.observedAt}] operation ${checkpoint.operationId}: timeout; last state ${operationLabel(checkpoint.operation)}`;
148
+ }
149
+ const suffix = checkpoint.changed ? '' : ' (unchanged)';
150
+ return `[${checkpoint.observedAt}] operation ${checkpoint.operationId}: ${operationLabel(checkpoint.operation)}${suffix}`;
151
+ }
152
+ function operationLabel(operation) {
153
+ if (!operation)
154
+ return 'unknown';
155
+ const state = typeof operation.state === 'string' && operation.state ? operation.state : 'unknown';
156
+ const phase = typeof operation.phase === 'string' && operation.phase ? ` / ${operation.phase}` : '';
157
+ const intent = typeof operation.intent === 'string' && operation.intent ? ` (${operation.intent})` : '';
158
+ return `${state}${phase}${intent}`;
159
+ }
@@ -26,7 +26,7 @@ export declare function resolveTaskIdentity({ positionalId, flagTask, jsonBody,
26
26
  * The same resolution `resolveTaskIdentity` performs, without the throw.
27
27
  * Read-only surfaces that REPORT task context (`skrr context`) need the
28
28
  * identical answer an id-less task command would act on — runtime binding
29
- * first, then the `oversky/task/<REF>` git branch — but "no task anywhere"
29
+ * first, then the canonical task git branch — but "no task anywhere"
30
30
  * is a fact to print, not an error to fail on.
31
31
  */
32
32
  export declare function tryResolveTaskIdentity(options?: Parameters<typeof resolveTaskIdentity>[0]): TaskIdentity | null;
@@ -65,8 +65,9 @@ function resolveTaskIdentity({ positionalId, flagTask, jsonBody, jsonKeys = ['ta
65
65
  identifierFallback: true,
66
66
  };
67
67
  }
68
- // Human-side task work has no daemon runtime context. A canonical
69
- // `oversky/task/OSK-123` branch is therefore the final, local-only default.
68
+ // Human-side task work has no daemon runtime context. A branch in the
69
+ // canonical task namespace (TASK_BRANCH_PREFIX) is therefore the final,
70
+ // local-only default.
70
71
  // Keep it after all trusted session coordinates: a daemon-bound task must
71
72
  // not silently become whichever branch happens to be checked out.
72
73
  const branchTaskRef = gitTaskReference()?.trim();
@@ -90,7 +91,7 @@ function resolveTaskIdentity({ positionalId, flagTask, jsonBody, jsonKeys = ['ta
90
91
  * The same resolution `resolveTaskIdentity` performs, without the throw.
91
92
  * Read-only surfaces that REPORT task context (`skrr context`) need the
92
93
  * identical answer an id-less task command would act on — runtime binding
93
- * first, then the `oversky/task/<REF>` git branch — but "no task anywhere"
94
+ * first, then the canonical task git branch — but "no task anywhere"
94
95
  * is a fact to print, not an error to fail on.
95
96
  */
96
97
  function tryResolveTaskIdentity(options = {}) {
@@ -1,4 +1,4 @@
1
- import type { TaskExecutionSnapshot, TaskConversationInputBody, TaskConversationInputReceipt, TaskInputPurpose } from '@skrr-ai/data-provider';
1
+ import type { TaskConversationInputBody, TaskConversationInputReceipt, TaskExecutionSnapshot, TaskInputPurpose } from '@skrr-ai/data-provider';
2
2
  /** Observation time is not evidence that a worker just sent a heartbeat. */
3
3
  export declare function describeExecutionState(state: TaskExecutionSnapshot): string[];
4
4
  export declare function buildTaskContinuationBody(input: {
@@ -6,10 +6,44 @@ exports.describeTaskContinuation = describeTaskContinuation;
6
6
  const node_crypto_1 = require("node:crypto");
7
7
  /** Observation time is not evidence that a worker just sent a heartbeat. */
8
8
  function describeExecutionState(state) {
9
+ const execution = state.execution;
10
+ const attempt = execution.attemptKey
11
+ ? `Attempt: ${execution.attemptKey}`
12
+ : 'Attempt: not claimed by an executor';
13
+ const terminal = execution.executorTerminal
14
+ ? `Executor terminal: observed for this attempt; canonical Run is ${execution.runStatus ?? 'not observed'}`
15
+ : null;
16
+ const finalization = execution.finalizationPending
17
+ ? 'Finalization: pending; the canonical terminal is recorded but Task workflow projection is still reconciling'
18
+ : null;
19
+ const coverage = execution.workCoverage
20
+ ? `Work coverage: ${execution.workCoverage.applicability}${execution.workCoverage.reason ? `; ${execution.workCoverage.reason}` : ''}`
21
+ : null;
22
+ const failure = execution.failure
23
+ ? `Execution failure: ${[execution.failure.code, execution.failure.class]
24
+ .filter(Boolean)
25
+ .join(' · ')}${execution.failure.message
26
+ ? `${execution.failure.code || execution.failure.class ? '; ' : ''}${execution.failure.message}`
27
+ : ''}`
28
+ : null;
29
+ const resources = state.resources
30
+ ? [
31
+ `Execution resources: ${state.resources.state}; ${state.resources.reason}`,
32
+ ...state.resources.items.map((resource) => `Resource: ${resource.kind} ${resource.state}; ${resource.reason}${resource.attempt
33
+ ? `; attempt ${resource.attempt.kind}:${resource.attempt.runId}:${resource.attempt.attempt}:${resource.attempt.generation}`
34
+ : ''}; evidence ${resource.evidence?.source ?? 'unavailable'}${resource.evidence?.observedAt ? ` ${resource.evidence.observedAt}` : ''}${resource.requestedAt ? `; requested ${resource.requestedAt}` : ''}${resource.transportRequestedAt ? `; transport requested ${resource.transportRequestedAt}` : ''}${resource.acknowledgedAt ? `; acknowledged ${resource.acknowledgedAt}` : ''}${resource.releasedAt ? `; released ${resource.releasedAt}` : ''}${resource.unknownAt ? `; release unverifiable ${resource.unknownAt}` : ''}${resource.recoveryAttempts !== undefined ? `; recovery attempts ${resource.recoveryAttempts}` : ''}`),
35
+ ]
36
+ : ['Execution resources: unavailable; this server did not return a resource projection'];
9
37
  return [
10
38
  `Task: ${state.taskId}`,
11
39
  `Workflow: ${state.workflowStatus} (generation ${state.workflowGeneration})`,
12
- `Execution: ${state.execution.runStatus ?? 'not observed'}${state.execution.runId ? `; Run ${state.execution.runId}` : ''}`,
40
+ `Execution: ${execution.runStatus ?? 'not observed'}${execution.runId ? `; Run ${execution.runId}` : ''}`,
41
+ attempt,
42
+ ...(terminal ? [terminal] : []),
43
+ ...(finalization ? [finalization] : []),
44
+ ...(coverage ? [coverage] : []),
45
+ ...(failure ? [failure] : []),
46
+ ...resources,
13
47
  `Liveness: ${state.liveness.state}; last runtime signal ${state.liveness.lastRuntimeSignalAt ?? 'unavailable'}`,
14
48
  `Health: ${state.health.condition}; ${state.health.reason}`,
15
49
  ...(state.waiting ? [`Waiting: ${state.waiting.kind}; ${state.waiting.referenceId}`] : []),
@@ -1,4 +1,18 @@
1
1
  import { readRuntimeContext } from './runtime-context';
2
+ export type UnboundRuntimeSetupStep = {
3
+ kind: 'inspect_local_harnesses' | 'inspect_local_code_agent' | 'start_assigned_task';
4
+ command: string;
5
+ description: string;
6
+ };
7
+ /**
8
+ * An unbound shell is normal for a person starting the CLI by hand. The useful
9
+ * answer is not an invitation to forge an environment variable; it is the
10
+ * smallest truthful route to learn which local engines are registered, choose
11
+ * a local Code identity, or enter an assigned task's authenticated runtime.
12
+ */
13
+ export declare function unboundRuntimeSetup(bin?: string): UnboundRuntimeSetupStep[];
14
+ export declare function agentBindingGuidance(bin?: string): string;
15
+ /** Compatibility for receipts and surfaces that do not know the invoked bin name. */
2
16
  export declare const AGENT_BINDING_GUIDANCE: string;
3
17
  export declare const ACCOUNT_ATTRIBUTION_NOTICE: string;
4
18
  type Principal = {
@@ -1,11 +1,44 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ACCOUNT_ATTRIBUTION_NOTICE = exports.AGENT_BINDING_GUIDANCE = void 0;
4
+ exports.unboundRuntimeSetup = unboundRuntimeSetup;
5
+ exports.agentBindingGuidance = agentBindingGuidance;
4
6
  exports.taskWriteAttribution = taskWriteAttribution;
5
7
  exports.attributionLines = attributionLines;
6
8
  exports.runtimeWriteAttribution = runtimeWriteAttribution;
7
- exports.AGENT_BINDING_GUIDANCE = 'Run `skrr tasks start <task>` to execute in the assigned Agent’s authenticated runtime. ' +
8
- 'An --agent flag or an environment Agent id cannot establish authenticated authorship.';
9
+ /**
10
+ * An unbound shell is normal for a person starting the CLI by hand. The useful
11
+ * answer is not an invitation to forge an environment variable; it is the
12
+ * smallest truthful route to learn which local engines are registered, choose
13
+ * a local Code identity, or enter an assigned task's authenticated runtime.
14
+ */
15
+ function unboundRuntimeSetup(bin = 'skrr') {
16
+ return [
17
+ {
18
+ kind: 'inspect_local_harnesses',
19
+ command: `${bin} harnesses list --all`,
20
+ description: 'List the local provider harnesses this account has registered, including offline rows.',
21
+ },
22
+ {
23
+ kind: 'inspect_local_code_agent',
24
+ command: `${bin} code skrr-agent`,
25
+ description: 'Show which Agent a locally started managed skrr Code session would use; it does not start work.',
26
+ },
27
+ {
28
+ kind: 'start_assigned_task',
29
+ command: `${bin} tasks start <task>`,
30
+ description: 'For an assigned Task, enter its authenticated Agent runtime and execute that Task.',
31
+ },
32
+ ];
33
+ }
34
+ function agentBindingGuidance(bin = 'skrr') {
35
+ const [harnesses, codeAgent, task] = unboundRuntimeSetup(bin);
36
+ return (`This shell is not an authenticated Agent runtime. Inspect registered local engines with \`${harnesses.command}\`; ` +
37
+ `inspect the local managed Code identity with \`${codeAgent.command}\`; and for an assigned Task, start it with \`${task.command}\`. ` +
38
+ 'An --agent flag or an environment Agent id cannot establish authenticated authorship.');
39
+ }
40
+ /** Compatibility for receipts and surfaces that do not know the invoked bin name. */
41
+ exports.AGENT_BINDING_GUIDANCE = agentBindingGuidance();
9
42
  exports.ACCOUNT_ATTRIBUTION_NOTICE = 'Without authenticated Agent provenance, Task writes are attributed to the signed-in account. ' +
10
43
  'An account-attributed assessment is not proof of an independent human check.';
11
44
  /** Use the persisted server receipt, never the process's claimed Agent identity. */
@@ -126,6 +126,17 @@ export interface TriggerDefinition {
126
126
  * to disagree with the route that does the refusing.
127
127
  */
128
128
  producerOwned?: boolean;
129
+ /**
130
+ * The Space loop this trigger was converted into (`skrr spaces loops
131
+ * migrate`, OSK-18009/OSK-18011). `pending`: read-only and still firing until
132
+ * the loop is active; `retired`: replaced by the loop, read-only, does not run.
133
+ */
134
+ supersededBy?: {
135
+ commitmentId?: string;
136
+ state?: string;
137
+ recordedAt?: string;
138
+ retiredAt?: string;
139
+ };
129
140
  createdAt?: string;
130
141
  updatedAt?: string;
131
142
  }
@@ -1294,6 +1294,13 @@ function renderTriggerSummary(trigger, log, options = {}) {
1294
1294
  if (trigger.producerOwned === true) {
1295
1295
  log('Managed: by the platform — not editable here; change the object that owns it');
1296
1296
  }
1297
+ // A trigger converted into a Space loop is read-only, and says where its turn went.
1298
+ const loop = trigger.supersededBy;
1299
+ if (loop?.commitmentId) {
1300
+ log(loop.state === 'retired'
1301
+ ? `Loop: replaced by Space loop ${loop.commitmentId}; read-only and does not run (skrr commitments show ${loop.commitmentId})`
1302
+ : `Loop: being converted into Space loop ${loop.commitmentId}; read-only, and keeps firing until the loop is active`);
1303
+ }
1297
1304
  if (trigger.label)
1298
1305
  log(`Label: ${trigger.label}`);
1299
1306
  if (trigger.execution?.mode)
@@ -4,6 +4,7 @@ export type WikiPageUpdateInput = {
4
4
  icon?: string;
5
5
  clearIcon?: boolean;
6
6
  order?: number;
7
+ kind?: string;
7
8
  };
8
9
  export type WikiPageUpdateResult = {
9
10
  ok: true;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.buildWikiPageUpdate = buildWikiPageUpdate;
4
+ const data_provider_1 = require("@skrr-ai/data-provider");
4
5
  /**
5
6
  * Build the PATCH body for `skrr wiki update`.
6
7
  *
@@ -39,10 +40,18 @@ function buildWikiPageUpdate(input) {
39
40
  }
40
41
  data.order = input.order;
41
42
  }
43
+ // oclif already limits the flag to these values; this is the same check for
44
+ // a caller of the builder that is not the flag parser.
45
+ if (input.kind !== undefined) {
46
+ if (!(0, data_provider_1.isWikiPageKind)(input.kind)) {
47
+ return { ok: false, error: `--kind must be one of: ${data_provider_1.WIKI_PAGE_KINDS.join(', ')}.` };
48
+ }
49
+ data.kind = input.kind;
50
+ }
42
51
  if (Object.keys(data).length === 0) {
43
52
  return {
44
53
  ok: false,
45
- error: 'Nothing to update. Pass --title, --icon, --clear-icon, or --order.',
54
+ error: 'Nothing to update. Pass --title, --icon, --clear-icon, --order, or --kind.',
46
55
  };
47
56
  }
48
57
  return { ok: true, data };
package/dist/lib/wiki.js CHANGED
@@ -68,7 +68,10 @@ function decorate(node) {
68
68
  // name has drifted from its slug is worth seeing.
69
69
  const slug = node.slug || node.name;
70
70
  const title = node.name && node.name !== slug ? ` [${node.name}]` : '';
71
- return `${slug}${title}`;
71
+ // An ordinary page says nothing; any other kind is named, so the charter and
72
+ // journal entries can be told apart from docs at a glance (OSK-17985).
73
+ const kind = node.kind && node.kind !== 'doc' ? ` (${node.kind})` : '';
74
+ return `${slug}${title}${kind}`;
72
75
  }
73
76
  function sortNodes(nodes) {
74
77
  return [...nodes].sort((a, b) => {
@@ -185,6 +185,14 @@ export type DaemonComputerEventKey = keyof typeof DAEMON_COMPUTER_EVENTS;
185
185
  export type DaemonComputerEventName = (typeof DAEMON_COMPUTER_EVENTS)[DaemonComputerEventKey];
186
186
  export declare const COMPUTER_EVENT_NAMES: readonly ComputerEventName[];
187
187
  export declare const DAEMON_COMPUTER_EVENT_NAMES: readonly DaemonComputerEventName[];
188
+ /**
189
+ * API → daemon: an authorized person observes, configures, stops or recovers
190
+ * the machine's Computer Use provider. Answered with `daemon:computer:ack`. It
191
+ * is deliberately outside `DAEMON_COMPUTER_EVENTS`, which lists the events the
192
+ * attachment protocol itself speaks, so the registry parity over that table
193
+ * does not move.
194
+ */
195
+ export declare const DAEMON_COMPUTER_USE_CONTROL_EVENT: "daemon:computer:use-control";
188
196
  /** The daemon → API events; every other `daemon:computer:*` event flows API → daemon. */
189
197
  export declare const DAEMON_COMPUTER_REPORT_EVENT_KEYS: readonly ["ack", "manifest", "data", "activity", "detached", "filesChanged", "diagnostics"];
190
198
  /** The API → client events; every other `computer:*` event flows client → API. */
@@ -362,7 +370,7 @@ export declare const COMPUTER_CAPABILITY_VALUES: [ComputerCapability, ...Compute
362
370
  * Every refusal and limit the computer protocol can answer with. Callers branch
363
371
  * on the code; a message beside it is free text and may change.
364
372
  */
365
- export declare const COMPUTER_REFUSAL_CODES: readonly ["human_control", "stale_epoch", "stale_generation", "file_changed", "capability_missing", "unauthorized", "control_denied", "not_holder", "attachment_limit", "observer_limit", "watch_limit", "grant_limit", "browser_limit", "rate_limited", "not_found", "surface_ended", "machine_unavailable", "daemon_unreachable", "relay_error", "timeout", "invalid_request", "consent_missing", "path_withheld", "too_large", "service_limit"];
373
+ export declare const COMPUTER_REFUSAL_CODES: readonly ["human_control", "stale_epoch", "stale_generation", "file_changed", "capability_missing", "unauthorized", "control_denied", "not_holder", "attachment_limit", "observer_limit", "watch_limit", "grant_limit", "browser_limit", "rate_limited", "not_found", "surface_ended", "machine_unavailable", "daemon_unreachable", "relay_error", "timeout", "invalid_request", "consent_missing", "path_withheld", "too_large", "service_limit", "maintenance_hold"];
366
374
  export type ComputerRefusalCode = (typeof COMPUTER_REFUSAL_CODES)[number];
367
375
  /**
368
376
  * The code when it is a computer refusal, else `null`. There is one spelling
@@ -131,6 +131,7 @@ __export(computerWire_exports, {
131
131
  DAEMON_COMPUTER_EVENTS: () => DAEMON_COMPUTER_EVENTS,
132
132
  DAEMON_COMPUTER_EVENT_NAMES: () => DAEMON_COMPUTER_EVENT_NAMES,
133
133
  DAEMON_COMPUTER_REPORT_EVENT_KEYS: () => DAEMON_COMPUTER_REPORT_EVENT_KEYS,
134
+ DAEMON_COMPUTER_USE_CONTROL_EVENT: () => DAEMON_COMPUTER_USE_CONTROL_EVENT,
134
135
  browserActivityOriginAllowed: () => browserActivityOriginAllowed,
135
136
  clampComputerBrowserViewport: () => clampComputerBrowserViewport,
136
137
  computerAccessOperations: () => computerAccessOperations,
@@ -301,6 +302,7 @@ const DAEMON_COMPUTER_EVENTS = {
301
302
  };
302
303
  const COMPUTER_EVENT_NAMES = Object.values(COMPUTER_EVENTS);
303
304
  const DAEMON_COMPUTER_EVENT_NAMES = Object.values(DAEMON_COMPUTER_EVENTS);
305
+ const DAEMON_COMPUTER_USE_CONTROL_EVENT = "daemon:computer:use-control";
304
306
  const DAEMON_COMPUTER_REPORT_EVENT_KEYS = [
305
307
  "ack",
306
308
  "manifest",
@@ -516,7 +518,15 @@ const COMPUTER_REFUSAL_CODES = [
516
518
  /** The file is over the size the editor or the read accepts. */
517
519
  "too_large",
518
520
  /** The machine has as many declared services as it allows (`COMPUTER_DECLARED_SERVICES_MAX`). */
519
- "service_limit"
521
+ "service_limit",
522
+ /**
523
+ * The machine's owner paused NEW work on it (OSK-19107). Refuses an `open` only:
524
+ * watching, reading files and controlling a surface that already exists keep
525
+ * working, and nothing running is touched. The refusal carries the hold's facts
526
+ * (`maintenance`), and it is not `machine_unavailable`, which says the machine is
527
+ * down: a paused machine is up.
528
+ */
529
+ "maintenance_hold"
520
530
  ];
521
531
  function normalizeComputerRefusalCode(code) {
522
532
  if (typeof code !== "string") {
@@ -1020,21 +1030,26 @@ function normalizeBrowserActivityOriginPolicy(input) {
1020
1030
  const origins = (items, required) => {
1021
1031
  if (!Array.isArray(items) || items.length > 20 || required && !items.length)
1022
1032
  throw new Error("Choose from one to twenty allowed origins and up to twenty excluded origins");
1023
- return [...new Set(items.map((item) => {
1024
- if (typeof item !== "string" || item.length > 500)
1025
- throw new Error("Use an exact http or https origin without a path, credentials, query or fragment");
1026
- let url;
1027
- try {
1028
- url = new URL(item);
1029
- } catch {
1030
- throw new Error("Use an exact http or https origin");
1031
- }
1032
- if (!["http:", "https:"].includes(url.protocol) || url.hostname.includes("*") || url.username || url.password || item !== url.origin)
1033
- throw new Error("Use an exact http or https origin without a path, credentials, query or fragment");
1034
- return url.origin;
1035
- }))].sort();
1033
+ return [
1034
+ ...new Set(items.map((item) => {
1035
+ if (typeof item !== "string" || item.length > 500)
1036
+ throw new Error("Use an exact http or https origin without a path, credentials, query or fragment");
1037
+ let url;
1038
+ try {
1039
+ url = new URL(item);
1040
+ } catch {
1041
+ throw new Error("Use an exact http or https origin");
1042
+ }
1043
+ if (!["http:", "https:"].includes(url.protocol) || url.hostname.includes("*") || url.username || url.password || item !== url.origin)
1044
+ throw new Error("Use an exact http or https origin without a path, credentials, query or fragment");
1045
+ return url.origin;
1046
+ }))
1047
+ ].sort();
1048
+ };
1049
+ return {
1050
+ allowOrigins: origins(value.allowOrigins, true),
1051
+ excludeOrigins: origins(value.excludeOrigins, false)
1036
1052
  };
1037
- return { allowOrigins: origins(value.allowOrigins, true), excludeOrigins: origins(value.excludeOrigins, false) };
1038
1053
  }
1039
1054
  function browserActivityOriginAllowed(policy, url) {
1040
1055
  if (typeof url !== "string")
@@ -1161,6 +1176,7 @@ function browserActivityOriginAllowed(policy, url) {
1161
1176
  DAEMON_COMPUTER_EVENTS,
1162
1177
  DAEMON_COMPUTER_EVENT_NAMES,
1163
1178
  DAEMON_COMPUTER_REPORT_EVENT_KEYS,
1179
+ DAEMON_COMPUTER_USE_CONTROL_EVENT,
1164
1180
  browserActivityOriginAllowed,
1165
1181
  clampComputerBrowserViewport,
1166
1182
  computerAccessOperations,
@@ -51,6 +51,7 @@ function categoryForDaemonTool(toolName) {
51
51
  case "filelist":
52
52
  case "filestat":
53
53
  case "filereadtagged":
54
+ case "personaldata":
54
55
  return "read";
55
56
  case "write":
56
57
  case "edit":
@@ -239,18 +239,18 @@ const TOOLS = [
239
239
  capability: TOOL_RESPONSE_OUTBOX
240
240
  }),
241
241
  toDaemon("daemon:tool:cancel", "Abandon a running tool call."),
242
- toDaemon("daemon:computer:use-control", "An authorized person observes, configures, stops or recovers the machine Computer Use provider.", {
242
+ toDaemon(import_computerWire.DAEMON_COMPUTER_USE_CONTROL_EVENT, "An authorized person observes, configures, stops or recovers the machine Computer Use provider.", {
243
243
  stability: "experimental",
244
244
  capability: "computer_use_mcp_v1",
245
245
  delivery: "acked",
246
- answeredBy: "daemon:computer:ack",
246
+ answeredBy: import_computerWire.DAEMON_COMPUTER_EVENTS.ack,
247
247
  payload: { kind: "zod", schema: "daemonComputerUseControlSchema" }
248
248
  }),
249
249
  toDaemon("daemon:computer-use:rotate-credential", "The approved hosted-desktop owner requests credential rotation for this exact active machine lease generation.", {
250
250
  stability: "experimental",
251
251
  capability: "computer_use_mcp_v1",
252
252
  delivery: "acked",
253
- answeredBy: "daemon:computer:ack",
253
+ answeredBy: import_computerWire.DAEMON_COMPUTER_EVENTS.ack,
254
254
  payload: { kind: "zod", schema: "daemonComputerUseRotateCredentialSchema" }
255
255
  }),
256
256
  toDaemon("daemon:computer-use:revoke", "Revoke cloud Computer Use bindings after owner machine authority was removed.", {
@@ -262,15 +262,21 @@ const TOOLS = [
262
262
  stability: "experimental",
263
263
  capability: import_desktopWire.COMPUTER_DESKTOP_CAPABILITY,
264
264
  delivery: "acked",
265
- answeredBy: "daemon:computer:ack",
266
- payload: { kind: "zod", schema: `daemonComputerDesktop${operation[0].toUpperCase()}${operation.slice(1)}Schema` }
265
+ answeredBy: import_computerWire.DAEMON_COMPUTER_EVENTS.ack,
266
+ payload: {
267
+ kind: "zod",
268
+ schema: `daemonComputerDesktop${operation[0].toUpperCase()}${operation.slice(1)}Schema`
269
+ }
267
270
  })),
268
271
  ...["control", "input"].map((operation) => toDaemon(import_desktopWire.DAEMON_COMPUTER_DESKTOP_EVENTS[operation], `Human-only typed desktop ${operation}; exact authenticated attachment, stream and generation.`, {
269
272
  stability: "experimental",
270
273
  capability: import_desktopWire.COMPUTER_DESKTOP_CONTROL_CAPABILITY,
271
274
  delivery: "acked",
272
- answeredBy: "daemon:computer:ack",
273
- payload: { kind: "zod", schema: `daemonComputerDesktop${operation[0].toUpperCase()}${operation.slice(1)}Schema` }
275
+ answeredBy: import_computerWire.DAEMON_COMPUTER_EVENTS.ack,
276
+ payload: {
277
+ kind: "zod",
278
+ schema: `daemonComputerDesktop${operation[0].toUpperCase()}${operation.slice(1)}Schema`
279
+ }
274
280
  })),
275
281
  toServer(import_desktopWire.DAEMON_COMPUTER_DESKTOP_EVENTS.controlChanged, "Private desktop holder and input revocation fact; never carries a control token.", {
276
282
  stability: "experimental",