@openrig/cli 0.5.1 → 0.5.3

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 (859) hide show
  1. package/daemon/assets/guidance/openrig-start.md +21 -64
  2. package/daemon/assets/plugins/openrig-core/hooks/claude.json +36 -0
  3. package/daemon/assets/plugins/openrig-core/hooks/codex.json +27 -0
  4. package/daemon/assets/plugins/openrig-core/hooks/scripts/refocus.cjs +132 -0
  5. package/daemon/assets/plugins/openrig-core/skills/claude-compaction-restore/SKILL.md +35 -3
  6. package/daemon/assets/plugins/openrig-core/skills/claude-compaction-restore/scripts/precompact-hook.mjs +8 -95
  7. package/daemon/assets/plugins/openrig-core/skills/claude-compaction-restore/scripts/restore-from-jsonl.mjs +63 -20
  8. package/daemon/assets/plugins/openrig-core/skills/forming-an-openrig-mental-model/SKILL.md +6 -2
  9. package/daemon/assets/plugins/openrig-core/skills/messaging-the-human/SKILL.md +28 -2
  10. package/daemon/assets/plugins/openrig-core/skills/mission-slice-sop/SKILL.md +42 -52
  11. package/daemon/assets/plugins/openrig-core/skills/openrig-skills/SKILL.md +23 -1
  12. package/daemon/assets/plugins/openrig-core/skills/openrig-user/SKILL.md +7 -2
  13. package/daemon/assets/plugins/openrig-core/skills/orienting-to-an-inherited-seat/CHANGELOG.md +64 -0
  14. package/daemon/assets/plugins/openrig-core/skills/orienting-to-an-inherited-seat/SKILL.md +235 -0
  15. package/daemon/assets/plugins/openrig-core/skills/queue-handoff/SKILL.md +31 -1
  16. package/daemon/assets/plugins/openrig-core/skills/retiring-and-inheriting-a-seat/CHANGELOG.md +48 -0
  17. package/daemon/assets/plugins/openrig-core/skills/retiring-and-inheriting-a-seat/SKILL.md +211 -0
  18. package/daemon/assets/plugins/openrig-core/skills/seat-continuity-and-handover/SKILL.md +8 -0
  19. package/daemon/assets/plugins/openrig-core/skills/software-for-agents/SKILL.md +28 -1
  20. package/daemon/context-packs/skills/core/agent-starters/SKILL.md +132 -0
  21. package/daemon/context-packs/skills/core/agent-starters/manifest.yaml +9 -0
  22. package/daemon/context-packs/skills/core/agent-startup-and-context-ingestion/SKILL.md +112 -0
  23. package/daemon/context-packs/skills/core/agent-startup-and-context-ingestion/manifest.yaml +9 -0
  24. package/daemon/context-packs/skills/core/attention-queue/SKILL.md +264 -0
  25. package/daemon/context-packs/skills/core/attention-queue/manifest.yaml +9 -0
  26. package/daemon/context-packs/skills/core/cross-host-rig-commands/SKILL.md +195 -0
  27. package/daemon/context-packs/skills/core/cross-host-rig-commands/manifest.yaml +9 -0
  28. package/daemon/context-packs/skills/core/human-in-the-loop/SKILL.md +104 -0
  29. package/daemon/context-packs/skills/core/human-in-the-loop/manifest.yaml +9 -0
  30. package/daemon/context-packs/skills/core/openrig-architect/SKILL.md +378 -0
  31. package/daemon/context-packs/skills/core/openrig-architect/manifest.yaml +9 -0
  32. package/daemon/context-packs/skills/core/openrig-cmux/SKILL.md +81 -0
  33. package/daemon/context-packs/skills/core/openrig-cmux/manifest.yaml +9 -0
  34. package/daemon/context-packs/skills/core/openrig-herdr/SKILL.md +153 -0
  35. package/daemon/context-packs/skills/core/openrig-herdr/manifest.yaml +9 -0
  36. package/daemon/context-packs/skills/core/openrig-upgrade/SKILL.md +460 -0
  37. package/daemon/context-packs/skills/core/openrig-upgrade/manifest.yaml +9 -0
  38. package/daemon/context-packs/skills/core/rig-bundles-and-shareable-artifacts/SKILL.md +101 -0
  39. package/daemon/context-packs/skills/core/rig-bundles-and-shareable-artifacts/manifest.yaml +9 -0
  40. package/daemon/context-packs/skills/core/rig-lifecycle/SKILL.md +127 -0
  41. package/daemon/context-packs/skills/core/rig-lifecycle/manifest.yaml +9 -0
  42. package/daemon/context-packs/skills/core/session-source-fork/SKILL.md +160 -0
  43. package/daemon/context-packs/skills/core/session-source-fork/manifest.yaml +9 -0
  44. package/daemon/context-packs/skills/core/specification-system/SKILL.md +103 -0
  45. package/daemon/context-packs/skills/core/specification-system/manifest.yaml +9 -0
  46. package/daemon/context-packs/skills/core/topology-mutation-and-seat-management/SKILL.md +118 -0
  47. package/daemon/context-packs/skills/core/topology-mutation-and-seat-management/manifest.yaml +9 -0
  48. package/daemon/context-packs/skills/core/watchdog/SKILL.md +126 -0
  49. package/daemon/context-packs/skills/core/watchdog/manifest.yaml +9 -0
  50. package/daemon/context-packs/skills/pm/backlog-capture/SKILL.md +43 -0
  51. package/daemon/context-packs/skills/pm/backlog-capture/manifest.yaml +9 -0
  52. package/daemon/context-packs/skills/pm/context-builder/SKILL.md +87 -0
  53. package/daemon/context-packs/skills/pm/context-builder/manifest.yaml +9 -0
  54. package/daemon/context-packs/skills/pm/exec-summary/SKILL.md +84 -0
  55. package/daemon/context-packs/skills/pm/exec-summary/manifest.yaml +9 -0
  56. package/daemon/context-packs/skills/pm/office-hours/SKILL.md +129 -0
  57. package/daemon/context-packs/skills/pm/office-hours/manifest.yaml +9 -0
  58. package/daemon/context-packs/skills/pm/plan-review/SKILL.md +98 -0
  59. package/daemon/context-packs/skills/pm/plan-review/manifest.yaml +9 -0
  60. package/daemon/context-packs/skills/pm/requirements-writer/SKILL.md +113 -0
  61. package/daemon/context-packs/skills/pm/requirements-writer/manifest.yaml +9 -0
  62. package/daemon/context-packs/skills/pm/ui-mockup/SKILL.md +76 -0
  63. package/daemon/context-packs/skills/pm/ui-mockup/manifest.yaml +9 -0
  64. package/daemon/context-packs/skills/pods/development-team/SKILL.md +156 -0
  65. package/daemon/context-packs/skills/pods/development-team/manifest.yaml +9 -0
  66. package/daemon/context-packs/skills/pods/orchestration-team/SKILL.md +307 -0
  67. package/daemon/context-packs/skills/pods/orchestration-team/manifest.yaml +9 -0
  68. package/daemon/context-packs/skills/pods/oversight-team/SKILL.md +106 -0
  69. package/daemon/context-packs/skills/pods/oversight-team/manifest.yaml +9 -0
  70. package/daemon/context-packs/skills/pods/review-team/SKILL.md +213 -0
  71. package/daemon/context-packs/skills/pods/review-team/manifest.yaml +9 -0
  72. package/daemon/context-packs/skills/process/agent-browser/LOCAL-INSIGHTS.md +189 -0
  73. package/daemon/context-packs/skills/process/agent-browser/OPENRIG.md +40 -0
  74. package/daemon/context-packs/skills/process/agent-browser/SKILL.md +427 -0
  75. package/daemon/context-packs/skills/process/agent-browser/manifest.yaml +13 -0
  76. package/daemon/context-packs/skills/process/brainstorming/OPENRIG.md +48 -0
  77. package/daemon/context-packs/skills/process/brainstorming/SKILL.md +107 -0
  78. package/daemon/context-packs/skills/process/brainstorming/manifest.yaml +11 -0
  79. package/daemon/context-packs/skills/process/context-engineering/SKILL.md +479 -0
  80. package/daemon/context-packs/skills/process/context-engineering/manifest.yaml +9 -0
  81. package/daemon/context-packs/skills/process/dogfood/SKILL.md +225 -0
  82. package/daemon/context-packs/skills/process/dogfood/manifest.yaml +13 -0
  83. package/daemon/context-packs/skills/process/dogfood/references/issue-taxonomy.md +109 -0
  84. package/daemon/context-packs/skills/process/dogfood/templates/dogfood-report-template.md +53 -0
  85. package/daemon/context-packs/skills/process/executing-plans/OPENRIG.md +56 -0
  86. package/daemon/context-packs/skills/process/executing-plans/SKILL.md +94 -0
  87. package/daemon/context-packs/skills/process/executing-plans/manifest.yaml +11 -0
  88. package/daemon/context-packs/skills/process/frontend-design/LICENSE.txt +177 -0
  89. package/daemon/context-packs/skills/process/frontend-design/SKILL.md +50 -0
  90. package/daemon/context-packs/skills/process/frontend-design/manifest.yaml +11 -0
  91. package/daemon/context-packs/skills/process/systematic-debugging/SKILL.md +301 -0
  92. package/daemon/context-packs/skills/process/systematic-debugging/condition-based-waiting-example.ts +158 -0
  93. package/daemon/context-packs/skills/process/systematic-debugging/condition-based-waiting.md +115 -0
  94. package/daemon/context-packs/skills/process/systematic-debugging/defense-in-depth.md +122 -0
  95. package/daemon/context-packs/skills/process/systematic-debugging/find-polluter.sh +63 -0
  96. package/daemon/context-packs/skills/process/systematic-debugging/manifest.yaml +19 -0
  97. package/daemon/context-packs/skills/process/systematic-debugging/root-cause-tracing.md +169 -0
  98. package/daemon/context-packs/skills/process/test-driven-development/SKILL.md +385 -0
  99. package/daemon/context-packs/skills/process/test-driven-development/manifest.yaml +11 -0
  100. package/daemon/context-packs/skills/process/test-driven-development/testing-anti-patterns.md +299 -0
  101. package/daemon/context-packs/skills/process/using-superpowers/OPENRIG.md +48 -0
  102. package/daemon/context-packs/skills/process/using-superpowers/SKILL.md +106 -0
  103. package/daemon/context-packs/skills/process/using-superpowers/manifest.yaml +11 -0
  104. package/daemon/context-packs/skills/process/verification-before-completion/SKILL.md +155 -0
  105. package/daemon/context-packs/skills/process/verification-before-completion/manifest.yaml +9 -0
  106. package/daemon/context-packs/skills/process/writing-plans/OPENRIG.md +52 -0
  107. package/daemon/context-packs/skills/process/writing-plans/SKILL.md +126 -0
  108. package/daemon/context-packs/skills/process/writing-plans/manifest.yaml +11 -0
  109. package/daemon/context-packs/world/install/01-world-from-primitives.md +97 -0
  110. package/daemon/context-packs/world/install/02-permission-self-sleep.md +141 -0
  111. package/daemon/context-packs/world/install/03-what-this-is-for.md +86 -0
  112. package/daemon/context-packs/world/install/04-ontology.md +790 -0
  113. package/daemon/context-packs/world/install/05-harness-power-use.md +355 -0
  114. package/daemon/context-packs/world/install/06-a-competent-turn.md +225 -0
  115. package/daemon/context-packs/world/install/manifest.yaml +125 -0
  116. package/daemon/context-packs/world/install/reference-material.md +125 -0
  117. package/daemon/context-packs/world/install/what-you-can-do.md +416 -0
  118. package/daemon/dist/adapters/claude-code-adapter.d.ts.map +1 -1
  119. package/daemon/dist/adapters/claude-code-adapter.js +7 -4
  120. package/daemon/dist/adapters/claude-code-adapter.js.map +1 -1
  121. package/daemon/dist/adapters/claude-resume.js +2 -2
  122. package/daemon/dist/adapters/claude-resume.js.map +1 -1
  123. package/daemon/dist/adapters/codex-runtime-adapter.d.ts +11 -2
  124. package/daemon/dist/adapters/codex-runtime-adapter.d.ts.map +1 -1
  125. package/daemon/dist/adapters/codex-runtime-adapter.js +18 -10
  126. package/daemon/dist/adapters/codex-runtime-adapter.js.map +1 -1
  127. package/daemon/dist/adapters/tmux.d.ts +10 -2
  128. package/daemon/dist/adapters/tmux.d.ts.map +1 -1
  129. package/daemon/dist/adapters/tmux.js +27 -7
  130. package/daemon/dist/adapters/tmux.js.map +1 -1
  131. package/daemon/dist/adapters/yolo-mode.d.ts +18 -0
  132. package/daemon/dist/adapters/yolo-mode.d.ts.map +1 -1
  133. package/daemon/dist/adapters/yolo-mode.js +21 -0
  134. package/daemon/dist/adapters/yolo-mode.js.map +1 -1
  135. package/daemon/dist/build-info.js +3 -3
  136. package/daemon/dist/domain/codex-thread-id.d.ts +100 -2
  137. package/daemon/dist/domain/codex-thread-id.d.ts.map +1 -1
  138. package/daemon/dist/domain/codex-thread-id.js +180 -6
  139. package/daemon/dist/domain/codex-thread-id.js.map +1 -1
  140. package/daemon/dist/domain/context-packs/context-pack-types.d.ts +48 -0
  141. package/daemon/dist/domain/context-packs/context-pack-types.d.ts.map +1 -1
  142. package/daemon/dist/domain/context-packs/context-pack-types.js +8 -0
  143. package/daemon/dist/domain/context-packs/context-pack-types.js.map +1 -1
  144. package/daemon/dist/domain/context-packs/manifest-parser.d.ts.map +1 -1
  145. package/daemon/dist/domain/context-packs/manifest-parser.js +234 -2
  146. package/daemon/dist/domain/context-packs/manifest-parser.js.map +1 -1
  147. package/daemon/dist/domain/context-packs/probe-eval-bridge.d.ts +34 -0
  148. package/daemon/dist/domain/context-packs/probe-eval-bridge.d.ts.map +1 -0
  149. package/daemon/dist/domain/context-packs/probe-eval-bridge.js +38 -0
  150. package/daemon/dist/domain/context-packs/probe-eval-bridge.js.map +1 -0
  151. package/daemon/dist/domain/context-packs/profile-composer.d.ts +49 -0
  152. package/daemon/dist/domain/context-packs/profile-composer.d.ts.map +1 -0
  153. package/daemon/dist/domain/context-packs/profile-composer.js +125 -0
  154. package/daemon/dist/domain/context-packs/profile-composer.js.map +1 -0
  155. package/daemon/dist/domain/context-packs/profile-source-resolver.d.ts +53 -0
  156. package/daemon/dist/domain/context-packs/profile-source-resolver.d.ts.map +1 -0
  157. package/daemon/dist/domain/context-packs/profile-source-resolver.js +129 -0
  158. package/daemon/dist/domain/context-packs/profile-source-resolver.js.map +1 -0
  159. package/daemon/dist/domain/context-packs/seat-recap-store.d.ts +48 -0
  160. package/daemon/dist/domain/context-packs/seat-recap-store.d.ts.map +1 -0
  161. package/daemon/dist/domain/context-packs/seat-recap-store.js +123 -0
  162. package/daemon/dist/domain/context-packs/seat-recap-store.js.map +1 -0
  163. package/daemon/dist/domain/crash-cart-conductor.d.ts +173 -0
  164. package/daemon/dist/domain/crash-cart-conductor.d.ts.map +1 -0
  165. package/daemon/dist/domain/crash-cart-conductor.js +233 -0
  166. package/daemon/dist/domain/crash-cart-conductor.js.map +1 -0
  167. package/daemon/dist/domain/crash-cart-probes.d.ts +7 -6
  168. package/daemon/dist/domain/crash-cart-probes.d.ts.map +1 -1
  169. package/daemon/dist/domain/crash-cart-probes.js +57 -7
  170. package/daemon/dist/domain/crash-cart-probes.js.map +1 -1
  171. package/daemon/dist/domain/hosts/fanout-contract.d.ts +4 -0
  172. package/daemon/dist/domain/hosts/fanout-contract.d.ts.map +1 -1
  173. package/daemon/dist/domain/hosts/fanout-contract.js +15 -0
  174. package/daemon/dist/domain/hosts/fanout-contract.js.map +1 -1
  175. package/daemon/dist/domain/hosts/hosts-registry-reader.d.ts +11 -0
  176. package/daemon/dist/domain/hosts/hosts-registry-reader.d.ts.map +1 -1
  177. package/daemon/dist/domain/hosts/hosts-registry-reader.js +34 -1
  178. package/daemon/dist/domain/hosts/hosts-registry-reader.js.map +1 -1
  179. package/daemon/dist/domain/markdown-address.d.ts +56 -0
  180. package/daemon/dist/domain/markdown-address.d.ts.map +1 -0
  181. package/daemon/dist/domain/markdown-address.js +188 -0
  182. package/daemon/dist/domain/markdown-address.js.map +1 -0
  183. package/daemon/dist/domain/model-divergence/current-generation-record.d.ts +73 -0
  184. package/daemon/dist/domain/model-divergence/current-generation-record.d.ts.map +1 -0
  185. package/daemon/dist/domain/model-divergence/current-generation-record.js +204 -0
  186. package/daemon/dist/domain/model-divergence/current-generation-record.js.map +1 -0
  187. package/daemon/dist/domain/model-divergence/effective-model-readers.d.ts +13 -0
  188. package/daemon/dist/domain/model-divergence/effective-model-readers.d.ts.map +1 -0
  189. package/daemon/dist/domain/model-divergence/effective-model-readers.js +163 -0
  190. package/daemon/dist/domain/model-divergence/effective-model-readers.js.map +1 -0
  191. package/daemon/dist/domain/model-divergence/model-divergence-monitor.d.ts +125 -0
  192. package/daemon/dist/domain/model-divergence/model-divergence-monitor.d.ts.map +1 -0
  193. package/daemon/dist/domain/model-divergence/model-divergence-monitor.js +199 -0
  194. package/daemon/dist/domain/model-divergence/model-divergence-monitor.js.map +1 -0
  195. package/daemon/dist/domain/periodic-snapshot-scheduler.d.ts +4 -0
  196. package/daemon/dist/domain/periodic-snapshot-scheduler.d.ts.map +1 -1
  197. package/daemon/dist/domain/periodic-snapshot-scheduler.js +5 -1
  198. package/daemon/dist/domain/periodic-snapshot-scheduler.js.map +1 -1
  199. package/daemon/dist/domain/permission-drift-observer.d.ts.map +1 -1
  200. package/daemon/dist/domain/permission-drift-observer.js +6 -1
  201. package/daemon/dist/domain/permission-drift-observer.js.map +1 -1
  202. package/daemon/dist/domain/predecessor-recap-resolver.d.ts +10 -3
  203. package/daemon/dist/domain/predecessor-recap-resolver.d.ts.map +1 -1
  204. package/daemon/dist/domain/predecessor-recap-resolver.js +61 -14
  205. package/daemon/dist/domain/predecessor-recap-resolver.js.map +1 -1
  206. package/daemon/dist/domain/process-census.d.ts +25 -0
  207. package/daemon/dist/domain/process-census.d.ts.map +1 -0
  208. package/daemon/dist/domain/process-census.js +47 -0
  209. package/daemon/dist/domain/process-census.js.map +1 -0
  210. package/daemon/dist/domain/resume-metadata-refresher.d.ts +41 -3
  211. package/daemon/dist/domain/resume-metadata-refresher.d.ts.map +1 -1
  212. package/daemon/dist/domain/resume-metadata-refresher.js +74 -31
  213. package/daemon/dist/domain/resume-metadata-refresher.js.map +1 -1
  214. package/daemon/dist/domain/review/compose.d.ts +5 -26
  215. package/daemon/dist/domain/review/compose.d.ts.map +1 -1
  216. package/daemon/dist/domain/review/compose.js +31 -57
  217. package/daemon/dist/domain/review/compose.js.map +1 -1
  218. package/daemon/dist/domain/review/gather.d.ts.map +1 -1
  219. package/daemon/dist/domain/review/gather.js +3 -2
  220. package/daemon/dist/domain/review/gather.js.map +1 -1
  221. package/daemon/dist/domain/{rig-policy/rig-policy-defaults.d.ts → rig-mode/rig-mode-defaults.d.ts} +2 -2
  222. package/daemon/dist/domain/rig-mode/rig-mode-defaults.d.ts.map +1 -0
  223. package/daemon/dist/domain/{rig-policy/rig-policy-defaults.js → rig-mode/rig-mode-defaults.js} +1 -1
  224. package/daemon/dist/domain/rig-mode/rig-mode-defaults.js.map +1 -0
  225. package/{node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-store.d.ts → daemon/dist/domain/rig-mode/rig-mode-store.d.ts} +6 -6
  226. package/daemon/dist/domain/rig-mode/rig-mode-store.d.ts.map +1 -0
  227. package/daemon/dist/domain/{rig-policy/rig-policy-store.js → rig-mode/rig-mode-store.js} +5 -5
  228. package/daemon/dist/domain/rig-mode/rig-mode-store.js.map +1 -0
  229. package/daemon/dist/domain/{rig-policy/rig-policy-types.d.ts → rig-mode/rig-mode-types.d.ts} +1 -1
  230. package/daemon/dist/domain/rig-mode/rig-mode-types.d.ts.map +1 -0
  231. package/{node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-types.js → daemon/dist/domain/rig-mode/rig-mode-types.js} +1 -1
  232. package/daemon/dist/domain/rig-mode/rig-mode-types.js.map +1 -0
  233. package/{node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-validator.d.ts → daemon/dist/domain/rig-mode/rig-mode-validator.d.ts} +2 -2
  234. package/daemon/dist/domain/rig-mode/rig-mode-validator.d.ts.map +1 -0
  235. package/daemon/dist/domain/{rig-policy/rig-policy-validator.js → rig-mode/rig-mode-validator.js} +3 -3
  236. package/daemon/dist/domain/rig-mode/rig-mode-validator.js.map +1 -0
  237. package/daemon/dist/domain/rigspec-instantiator.d.ts +4 -0
  238. package/daemon/dist/domain/rigspec-instantiator.d.ts.map +1 -1
  239. package/daemon/dist/domain/rigspec-instantiator.js +39 -0
  240. package/daemon/dist/domain/rigspec-instantiator.js.map +1 -1
  241. package/daemon/dist/domain/rigspec-schema.d.ts +7 -0
  242. package/daemon/dist/domain/rigspec-schema.d.ts.map +1 -1
  243. package/daemon/dist/domain/rigspec-schema.js +25 -2
  244. package/daemon/dist/domain/rigspec-schema.js.map +1 -1
  245. package/daemon/dist/domain/scope/logical-checkbox.d.ts +26 -0
  246. package/daemon/dist/domain/scope/logical-checkbox.d.ts.map +1 -0
  247. package/daemon/dist/domain/scope/logical-checkbox.js +65 -0
  248. package/daemon/dist/domain/scope/logical-checkbox.js.map +1 -0
  249. package/daemon/dist/domain/scope/node-file.d.ts +37 -0
  250. package/daemon/dist/domain/scope/node-file.d.ts.map +1 -0
  251. package/daemon/dist/domain/scope/node-file.js +55 -0
  252. package/daemon/dist/domain/scope/node-file.js.map +1 -0
  253. package/daemon/dist/domain/scope/plan-lock-artifacts.d.ts +12 -1
  254. package/daemon/dist/domain/scope/plan-lock-artifacts.d.ts.map +1 -1
  255. package/daemon/dist/domain/scope/plan-lock-artifacts.js +42 -2
  256. package/daemon/dist/domain/scope/plan-lock-artifacts.js.map +1 -1
  257. package/daemon/dist/domain/scope/scaffold-placeholder.d.ts +22 -0
  258. package/daemon/dist/domain/scope/scaffold-placeholder.d.ts.map +1 -1
  259. package/daemon/dist/domain/scope/scaffold-placeholder.js +24 -0
  260. package/daemon/dist/domain/scope/scaffold-placeholder.js.map +1 -1
  261. package/daemon/dist/domain/scope/scope-approve.d.ts +4 -0
  262. package/daemon/dist/domain/scope/scope-approve.d.ts.map +1 -1
  263. package/daemon/dist/domain/scope/scope-approve.js +56 -7
  264. package/daemon/dist/domain/scope/scope-approve.js.map +1 -1
  265. package/daemon/dist/domain/scope/scope-audit.d.ts +1 -1
  266. package/daemon/dist/domain/scope/scope-audit.d.ts.map +1 -1
  267. package/daemon/dist/domain/scope/scope-audit.js.map +1 -1
  268. package/daemon/dist/domain/scope/scope-view-projection.d.ts.map +1 -1
  269. package/daemon/dist/domain/scope/scope-view-projection.js +5 -2
  270. package/daemon/dist/domain/scope/scope-view-projection.js.map +1 -1
  271. package/daemon/dist/domain/seat-activity-service.d.ts +1 -0
  272. package/daemon/dist/domain/seat-activity-service.d.ts.map +1 -1
  273. package/daemon/dist/domain/seat-activity-service.js +39 -23
  274. package/daemon/dist/domain/seat-activity-service.js.map +1 -1
  275. package/daemon/dist/domain/seat-handover-service.d.ts +54 -15
  276. package/daemon/dist/domain/seat-handover-service.d.ts.map +1 -1
  277. package/daemon/dist/domain/seat-handover-service.js +74 -19
  278. package/daemon/dist/domain/seat-handover-service.js.map +1 -1
  279. package/daemon/dist/domain/seat-identity-reconciler.d.ts +17 -0
  280. package/daemon/dist/domain/seat-identity-reconciler.d.ts.map +1 -1
  281. package/daemon/dist/domain/seat-identity-reconciler.js +22 -0
  282. package/daemon/dist/domain/seat-identity-reconciler.js.map +1 -1
  283. package/daemon/dist/domain/session-jsonl.js +1 -1
  284. package/daemon/dist/domain/session-jsonl.js.map +1 -1
  285. package/daemon/dist/domain/session-transport.d.ts +8 -0
  286. package/daemon/dist/domain/session-transport.d.ts.map +1 -1
  287. package/daemon/dist/domain/session-transport.js +116 -0
  288. package/daemon/dist/domain/session-transport.js.map +1 -1
  289. package/daemon/dist/domain/shell-classifier.d.ts +23 -0
  290. package/daemon/dist/domain/shell-classifier.d.ts.map +1 -0
  291. package/daemon/dist/domain/shell-classifier.js +36 -0
  292. package/daemon/dist/domain/shell-classifier.js.map +1 -0
  293. package/daemon/dist/domain/slices/slice-detail-projector.d.ts.map +1 -1
  294. package/daemon/dist/domain/slices/slice-detail-projector.js +24 -3
  295. package/daemon/dist/domain/slices/slice-detail-projector.js.map +1 -1
  296. package/daemon/dist/domain/slices/slice-indexer.d.ts.map +1 -1
  297. package/daemon/dist/domain/slices/slice-indexer.js +16 -3
  298. package/daemon/dist/domain/slices/slice-indexer.js.map +1 -1
  299. package/daemon/dist/domain/spec-live-conformance.d.ts +22 -0
  300. package/daemon/dist/domain/spec-live-conformance.d.ts.map +1 -1
  301. package/daemon/dist/domain/spec-live-conformance.js +35 -0
  302. package/daemon/dist/domain/spec-live-conformance.js.map +1 -1
  303. package/daemon/dist/domain/spec-validation-advisory.d.ts +17 -0
  304. package/daemon/dist/domain/spec-validation-advisory.d.ts.map +1 -0
  305. package/daemon/dist/domain/spec-validation-advisory.js +38 -0
  306. package/daemon/dist/domain/spec-validation-advisory.js.map +1 -0
  307. package/daemon/dist/domain/successor-session-launcher.d.ts +7 -0
  308. package/daemon/dist/domain/successor-session-launcher.d.ts.map +1 -1
  309. package/daemon/dist/domain/successor-session-launcher.js +38 -1
  310. package/daemon/dist/domain/successor-session-launcher.js.map +1 -1
  311. package/daemon/dist/domain/sync-site-wrap.d.ts +9 -0
  312. package/daemon/dist/domain/sync-site-wrap.d.ts.map +1 -1
  313. package/daemon/dist/domain/sync-site-wrap.js +11 -0
  314. package/daemon/dist/domain/sync-site-wrap.js.map +1 -1
  315. package/daemon/dist/domain/topology-defaults-installer.d.ts +47 -0
  316. package/daemon/dist/domain/topology-defaults-installer.d.ts.map +1 -0
  317. package/daemon/dist/domain/topology-defaults-installer.js +92 -0
  318. package/daemon/dist/domain/topology-defaults-installer.js.map +1 -0
  319. package/daemon/dist/domain/transcript-rotation.d.ts +4 -0
  320. package/daemon/dist/domain/transcript-rotation.d.ts.map +1 -1
  321. package/daemon/dist/domain/transcript-rotation.js +61 -3
  322. package/daemon/dist/domain/transcript-rotation.js.map +1 -1
  323. package/daemon/dist/domain/transcript-store.d.ts.map +1 -1
  324. package/daemon/dist/domain/transcript-store.js +9 -2
  325. package/daemon/dist/domain/transcript-store.js.map +1 -1
  326. package/daemon/dist/domain/types.d.ts +18 -0
  327. package/daemon/dist/domain/types.d.ts.map +1 -1
  328. package/daemon/dist/domain/types.js.map +1 -1
  329. package/daemon/dist/domain/user-settings/settings-store.d.ts +10 -1
  330. package/daemon/dist/domain/user-settings/settings-store.d.ts.map +1 -1
  331. package/daemon/dist/domain/user-settings/settings-store.js +59 -0
  332. package/daemon/dist/domain/user-settings/settings-store.js.map +1 -1
  333. package/daemon/dist/domain/watchdog-auto-registration.d.ts +7 -0
  334. package/daemon/dist/domain/watchdog-auto-registration.d.ts.map +1 -1
  335. package/daemon/dist/domain/watchdog-auto-registration.js +27 -0
  336. package/daemon/dist/domain/watchdog-auto-registration.js.map +1 -1
  337. package/daemon/dist/domain/workspace/workspace-doctor.d.ts.map +1 -1
  338. package/daemon/dist/domain/workspace/workspace-doctor.js +4 -3
  339. package/daemon/dist/domain/workspace/workspace-doctor.js.map +1 -1
  340. package/daemon/dist/routes/activity.js +11 -2
  341. package/daemon/dist/routes/activity.js.map +1 -1
  342. package/daemon/dist/routes/bundles.d.ts +27 -0
  343. package/daemon/dist/routes/bundles.d.ts.map +1 -1
  344. package/daemon/dist/routes/bundles.js +107 -26
  345. package/daemon/dist/routes/bundles.js.map +1 -1
  346. package/daemon/dist/routes/context-packs.d.ts.map +1 -1
  347. package/daemon/dist/routes/context-packs.js +205 -0
  348. package/daemon/dist/routes/context-packs.js.map +1 -1
  349. package/daemon/dist/routes/crash-cart.d.ts +4 -0
  350. package/daemon/dist/routes/crash-cart.d.ts.map +1 -0
  351. package/daemon/dist/routes/crash-cart.js +144 -0
  352. package/daemon/dist/routes/crash-cart.js.map +1 -0
  353. package/daemon/dist/routes/missions.d.ts.map +1 -1
  354. package/daemon/dist/routes/missions.js +10 -6
  355. package/daemon/dist/routes/missions.js.map +1 -1
  356. package/daemon/dist/routes/{rig-policy.d.ts → rig-mode.d.ts} +3 -3
  357. package/daemon/dist/routes/rig-mode.d.ts.map +1 -0
  358. package/{node_modules/@openrig/daemon/dist/routes/rig-policy.js → daemon/dist/routes/rig-mode.js} +13 -13
  359. package/daemon/dist/routes/rig-mode.js.map +1 -0
  360. package/daemon/dist/routes/scope-approve.d.ts.map +1 -1
  361. package/daemon/dist/routes/scope-approve.js +4 -0
  362. package/daemon/dist/routes/scope-approve.js.map +1 -1
  363. package/daemon/dist/routes/scope-audit.d.ts.map +1 -1
  364. package/daemon/dist/routes/scope-audit.js +29 -2
  365. package/daemon/dist/routes/scope-audit.js.map +1 -1
  366. package/daemon/dist/routes/seat.d.ts.map +1 -1
  367. package/daemon/dist/routes/seat.js +18 -2
  368. package/daemon/dist/routes/seat.js.map +1 -1
  369. package/daemon/dist/routes/sessions.d.ts.map +1 -1
  370. package/daemon/dist/routes/sessions.js +66 -1
  371. package/daemon/dist/routes/sessions.js.map +1 -1
  372. package/daemon/dist/routes/transport.d.ts.map +1 -1
  373. package/daemon/dist/routes/transport.js +12 -3
  374. package/daemon/dist/routes/transport.js.map +1 -1
  375. package/daemon/dist/seat-recap-store-surface.d.ts +2 -0
  376. package/daemon/dist/seat-recap-store-surface.d.ts.map +1 -0
  377. package/daemon/dist/seat-recap-store-surface.js +6 -0
  378. package/daemon/dist/seat-recap-store-surface.js.map +1 -0
  379. package/daemon/dist/server.d.ts +3 -1
  380. package/daemon/dist/server.d.ts.map +1 -1
  381. package/daemon/dist/server.js +15 -5
  382. package/daemon/dist/server.js.map +1 -1
  383. package/daemon/dist/startup.d.ts.map +1 -1
  384. package/daemon/dist/startup.js +166 -6
  385. package/daemon/dist/startup.js.map +1 -1
  386. package/daemon/docs/reference/chain-file-convention.md +115 -0
  387. package/daemon/docs/reference/legacy-topology-migration.md +53 -0
  388. package/daemon/docs/reference/refocus-channel.md +80 -0
  389. package/daemon/docs/reference/sdlc-conventions.md +24 -0
  390. package/daemon/specs/agents/shared/skills/core/attention-queue/SKILL.md +1 -1
  391. package/daemon/specs/agents/shared/skills/core/human-in-the-loop/SKILL.md +1 -1
  392. package/daemon/specs/agents/shared/skills/core/session-source-fork/SKILL.md +1 -1
  393. package/daemon/specs/agents/shared/skills/core/watchdog/SKILL.md +4 -4
  394. package/daemon/specs/agents/shared/skills/pods/development-team/SKILL.md +8 -0
  395. package/daemon/specs/agents/shared/skills/pods/orchestration-team/SKILL.md +72 -31
  396. package/daemon/specs/agents/shared/skills/pods/oversight-team/SKILL.md +106 -0
  397. package/daemon/specs/agents/shared/skills/process/context-engineering/SKILL.md +479 -0
  398. package/daemon/specs/agents/shared/skills/process/test-driven-development/SKILL.md +9 -0
  399. package/daemon/specs/rigs/launch/demo/project-example/README.md +25 -0
  400. package/daemon/specs/rigs/launch/demo/project-example/missions/improve-onboarding/SPEC.md +19 -0
  401. package/daemon/specs/rigs/launch/demo/project-example/missions/improve-onboarding/slices/01-shorten-first-run/PROGRESS.md +6 -0
  402. package/daemon/specs/rigs/launch/demo/project-example/missions/improve-onboarding/slices/01-shorten-first-run/PROOF.md +7 -0
  403. package/daemon/specs/rigs/launch/demo/project-example/missions/improve-onboarding/slices/01-shorten-first-run/SPEC.md +31 -0
  404. package/daemon/specs/rigs/preview/product-team/topology/instance/CRAFT.md +24 -0
  405. package/daemon/specs/rigs/preview/product-team/topology/rig/CRAFT.md +21 -0
  406. package/daemon/specs/rigs/preview/product-team/topology/rig/ORCHESTRATION-CRAFT.md +50 -0
  407. package/daemon/specs/rigs/preview/product-team/topology/seats/dev1-qa/CRAFT.md +13 -0
  408. package/daemon/specs/rigs/preview/product-team/topology/seats/orch1-lead/CRAFT.md +17 -0
  409. package/daemon/specs/rigs/preview/product-team/topology/seats/rev1-r1/CRAFT.md +17 -0
  410. package/daemon/specs/rigs/preview/product-team/topology/seats/rev1-r2/CRAFT.md +15 -0
  411. package/dist/build-info.js +3 -3
  412. package/dist/commands/bundle.d.ts.map +1 -1
  413. package/dist/commands/bundle.js +6 -0
  414. package/dist/commands/bundle.js.map +1 -1
  415. package/dist/commands/capture.d.ts.map +1 -1
  416. package/dist/commands/capture.js +2 -0
  417. package/dist/commands/capture.js.map +1 -1
  418. package/dist/commands/config.d.ts.map +1 -1
  419. package/dist/commands/config.js +8 -0
  420. package/dist/commands/config.js.map +1 -1
  421. package/dist/commands/context.d.ts.map +1 -1
  422. package/dist/commands/context.js +353 -48
  423. package/dist/commands/context.js.map +1 -1
  424. package/dist/commands/crash-cart.d.ts.map +1 -1
  425. package/dist/commands/crash-cart.js.map +1 -1
  426. package/dist/commands/host.d.ts +5 -0
  427. package/dist/commands/host.d.ts.map +1 -1
  428. package/dist/commands/host.js +59 -3
  429. package/dist/commands/host.js.map +1 -1
  430. package/dist/commands/policy.d.ts +5 -0
  431. package/dist/commands/policy.d.ts.map +1 -0
  432. package/dist/commands/policy.js +307 -0
  433. package/dist/commands/policy.js.map +1 -0
  434. package/dist/commands/proof.d.ts.map +1 -1
  435. package/dist/commands/proof.js +70 -12
  436. package/dist/commands/proof.js.map +1 -1
  437. package/dist/commands/ps.d.ts +4 -0
  438. package/dist/commands/ps.d.ts.map +1 -1
  439. package/dist/commands/ps.js +4 -0
  440. package/dist/commands/ps.js.map +1 -1
  441. package/dist/commands/{rig-policy.d.ts → rig-mode.d.ts} +3 -3
  442. package/dist/commands/rig-mode.d.ts.map +1 -0
  443. package/dist/commands/{rig-policy.js → rig-mode.js} +17 -17
  444. package/dist/commands/rig-mode.js.map +1 -0
  445. package/dist/commands/rig.d.ts.map +1 -1
  446. package/dist/commands/rig.js +5 -0
  447. package/dist/commands/rig.js.map +1 -1
  448. package/dist/commands/scope.d.ts.map +1 -1
  449. package/dist/commands/scope.js +58 -16
  450. package/dist/commands/scope.js.map +1 -1
  451. package/dist/commands/send.d.ts.map +1 -1
  452. package/dist/commands/send.js +2 -0
  453. package/dist/commands/send.js.map +1 -1
  454. package/dist/commands/setup.d.ts +13 -0
  455. package/dist/commands/setup.d.ts.map +1 -1
  456. package/dist/commands/setup.js +3 -3
  457. package/dist/commands/setup.js.map +1 -1
  458. package/dist/commands/transcript.d.ts.map +1 -1
  459. package/dist/commands/transcript.js +27 -1
  460. package/dist/commands/transcript.js.map +1 -1
  461. package/dist/commands/walk.d.ts.map +1 -1
  462. package/dist/commands/walk.js +279 -26
  463. package/dist/commands/walk.js.map +1 -1
  464. package/dist/commands/whoami.d.ts.map +1 -1
  465. package/dist/commands/whoami.js +11 -1
  466. package/dist/commands/whoami.js.map +1 -1
  467. package/dist/config-store.d.ts +17 -1
  468. package/dist/config-store.d.ts.map +1 -1
  469. package/dist/config-store.js +53 -1
  470. package/dist/config-store.js.map +1 -1
  471. package/dist/cross-host-target.d.ts +8 -1
  472. package/dist/cross-host-target.d.ts.map +1 -1
  473. package/dist/cross-host-target.js +23 -4
  474. package/dist/cross-host-target.js.map +1 -1
  475. package/dist/daemon-lifecycle.d.ts +10 -1
  476. package/dist/daemon-lifecycle.d.ts.map +1 -1
  477. package/dist/daemon-lifecycle.js +26 -1
  478. package/dist/daemon-lifecycle.js.map +1 -1
  479. package/dist/front-door.d.ts.map +1 -1
  480. package/dist/front-door.js +11 -1
  481. package/dist/front-door.js.map +1 -1
  482. package/dist/host-bindings.d.ts +62 -0
  483. package/dist/host-bindings.d.ts.map +1 -0
  484. package/dist/host-bindings.js +147 -0
  485. package/dist/host-bindings.js.map +1 -0
  486. package/dist/host-registry.d.ts +14 -1
  487. package/dist/host-registry.d.ts.map +1 -1
  488. package/dist/host-registry.js +30 -2
  489. package/dist/host-registry.js.map +1 -1
  490. package/dist/index.d.ts +2 -2
  491. package/dist/index.d.ts.map +1 -1
  492. package/dist/index.js +5 -2
  493. package/dist/index.js.map +1 -1
  494. package/dist/lib/hosts/fanout-contract.d.ts +4 -0
  495. package/dist/lib/hosts/fanout-contract.d.ts.map +1 -1
  496. package/dist/lib/hosts/fanout-contract.js +15 -0
  497. package/dist/lib/hosts/fanout-contract.js.map +1 -1
  498. package/dist/lib/path-safety.d.ts +8 -0
  499. package/dist/lib/path-safety.d.ts.map +1 -0
  500. package/dist/lib/path-safety.js +24 -0
  501. package/dist/lib/path-safety.js.map +1 -0
  502. package/dist/lib/permission-policy/policy-ref.d.ts +89 -0
  503. package/dist/lib/permission-policy/policy-ref.d.ts.map +1 -0
  504. package/dist/lib/permission-policy/policy-ref.js +171 -0
  505. package/dist/lib/permission-policy/policy-ref.js.map +1 -0
  506. package/dist/lib/permission-policy/policy-spec.d.ts +34 -0
  507. package/dist/lib/permission-policy/policy-spec.d.ts.map +1 -0
  508. package/dist/lib/permission-policy/policy-spec.js +106 -0
  509. package/dist/lib/permission-policy/policy-spec.js.map +1 -0
  510. package/dist/lib/scope/logical-checkbox.d.ts +26 -0
  511. package/dist/lib/scope/logical-checkbox.d.ts.map +1 -0
  512. package/dist/lib/scope/logical-checkbox.js +65 -0
  513. package/dist/lib/scope/logical-checkbox.js.map +1 -0
  514. package/dist/lib/scope/scaffold-placeholder.d.ts +22 -0
  515. package/dist/lib/scope/scaffold-placeholder.d.ts.map +1 -1
  516. package/dist/lib/scope/scaffold-placeholder.js +24 -0
  517. package/dist/lib/scope/scaffold-placeholder.js.map +1 -1
  518. package/dist/lib/scope/scope-audit.d.ts +1 -1
  519. package/dist/lib/scope/scope-audit.d.ts.map +1 -1
  520. package/dist/lib/scope/scope-audit.js.map +1 -1
  521. package/dist/lib/scope/scope-fs.d.ts +19 -3
  522. package/dist/lib/scope/scope-fs.d.ts.map +1 -1
  523. package/dist/lib/scope/scope-fs.js +37 -17
  524. package/dist/lib/scope/scope-fs.js.map +1 -1
  525. package/dist/lib/topology-trace.d.ts +36 -0
  526. package/dist/lib/topology-trace.d.ts.map +1 -0
  527. package/dist/lib/topology-trace.js +91 -0
  528. package/dist/lib/topology-trace.js.map +1 -0
  529. package/dist/release-surface/extract-surface.js +1 -1
  530. package/dist/release-surface/extract-surface.js.map +1 -1
  531. package/node_modules/@openrig/daemon/dist/adapters/claude-code-adapter.d.ts.map +1 -1
  532. package/node_modules/@openrig/daemon/dist/adapters/claude-code-adapter.js +7 -4
  533. package/node_modules/@openrig/daemon/dist/adapters/claude-code-adapter.js.map +1 -1
  534. package/node_modules/@openrig/daemon/dist/adapters/claude-resume.js +2 -2
  535. package/node_modules/@openrig/daemon/dist/adapters/claude-resume.js.map +1 -1
  536. package/node_modules/@openrig/daemon/dist/adapters/codex-runtime-adapter.d.ts +11 -2
  537. package/node_modules/@openrig/daemon/dist/adapters/codex-runtime-adapter.d.ts.map +1 -1
  538. package/node_modules/@openrig/daemon/dist/adapters/codex-runtime-adapter.js +18 -10
  539. package/node_modules/@openrig/daemon/dist/adapters/codex-runtime-adapter.js.map +1 -1
  540. package/node_modules/@openrig/daemon/dist/adapters/tmux.d.ts +10 -2
  541. package/node_modules/@openrig/daemon/dist/adapters/tmux.d.ts.map +1 -1
  542. package/node_modules/@openrig/daemon/dist/adapters/tmux.js +27 -7
  543. package/node_modules/@openrig/daemon/dist/adapters/tmux.js.map +1 -1
  544. package/node_modules/@openrig/daemon/dist/adapters/yolo-mode.d.ts +18 -0
  545. package/node_modules/@openrig/daemon/dist/adapters/yolo-mode.d.ts.map +1 -1
  546. package/node_modules/@openrig/daemon/dist/adapters/yolo-mode.js +21 -0
  547. package/node_modules/@openrig/daemon/dist/adapters/yolo-mode.js.map +1 -1
  548. package/node_modules/@openrig/daemon/dist/build-info.js +3 -3
  549. package/node_modules/@openrig/daemon/dist/domain/codex-thread-id.d.ts +100 -2
  550. package/node_modules/@openrig/daemon/dist/domain/codex-thread-id.d.ts.map +1 -1
  551. package/node_modules/@openrig/daemon/dist/domain/codex-thread-id.js +180 -6
  552. package/node_modules/@openrig/daemon/dist/domain/codex-thread-id.js.map +1 -1
  553. package/node_modules/@openrig/daemon/dist/domain/context-packs/context-pack-types.d.ts +48 -0
  554. package/node_modules/@openrig/daemon/dist/domain/context-packs/context-pack-types.d.ts.map +1 -1
  555. package/node_modules/@openrig/daemon/dist/domain/context-packs/context-pack-types.js +8 -0
  556. package/node_modules/@openrig/daemon/dist/domain/context-packs/context-pack-types.js.map +1 -1
  557. package/node_modules/@openrig/daemon/dist/domain/context-packs/manifest-parser.d.ts.map +1 -1
  558. package/node_modules/@openrig/daemon/dist/domain/context-packs/manifest-parser.js +234 -2
  559. package/node_modules/@openrig/daemon/dist/domain/context-packs/manifest-parser.js.map +1 -1
  560. package/node_modules/@openrig/daemon/dist/domain/context-packs/probe-eval-bridge.d.ts +34 -0
  561. package/node_modules/@openrig/daemon/dist/domain/context-packs/probe-eval-bridge.d.ts.map +1 -0
  562. package/node_modules/@openrig/daemon/dist/domain/context-packs/probe-eval-bridge.js +38 -0
  563. package/node_modules/@openrig/daemon/dist/domain/context-packs/probe-eval-bridge.js.map +1 -0
  564. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-composer.d.ts +49 -0
  565. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-composer.d.ts.map +1 -0
  566. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-composer.js +125 -0
  567. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-composer.js.map +1 -0
  568. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-source-resolver.d.ts +53 -0
  569. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-source-resolver.d.ts.map +1 -0
  570. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-source-resolver.js +129 -0
  571. package/node_modules/@openrig/daemon/dist/domain/context-packs/profile-source-resolver.js.map +1 -0
  572. package/node_modules/@openrig/daemon/dist/domain/context-packs/seat-recap-store.d.ts +48 -0
  573. package/node_modules/@openrig/daemon/dist/domain/context-packs/seat-recap-store.d.ts.map +1 -0
  574. package/node_modules/@openrig/daemon/dist/domain/context-packs/seat-recap-store.js +123 -0
  575. package/node_modules/@openrig/daemon/dist/domain/context-packs/seat-recap-store.js.map +1 -0
  576. package/node_modules/@openrig/daemon/dist/domain/crash-cart-conductor.d.ts +173 -0
  577. package/node_modules/@openrig/daemon/dist/domain/crash-cart-conductor.d.ts.map +1 -0
  578. package/node_modules/@openrig/daemon/dist/domain/crash-cart-conductor.js +233 -0
  579. package/node_modules/@openrig/daemon/dist/domain/crash-cart-conductor.js.map +1 -0
  580. package/node_modules/@openrig/daemon/dist/domain/crash-cart-probes.d.ts +7 -6
  581. package/node_modules/@openrig/daemon/dist/domain/crash-cart-probes.d.ts.map +1 -1
  582. package/node_modules/@openrig/daemon/dist/domain/crash-cart-probes.js +57 -7
  583. package/node_modules/@openrig/daemon/dist/domain/crash-cart-probes.js.map +1 -1
  584. package/node_modules/@openrig/daemon/dist/domain/hosts/fanout-contract.d.ts +4 -0
  585. package/node_modules/@openrig/daemon/dist/domain/hosts/fanout-contract.d.ts.map +1 -1
  586. package/node_modules/@openrig/daemon/dist/domain/hosts/fanout-contract.js +15 -0
  587. package/node_modules/@openrig/daemon/dist/domain/hosts/fanout-contract.js.map +1 -1
  588. package/node_modules/@openrig/daemon/dist/domain/hosts/hosts-registry-reader.d.ts +11 -0
  589. package/node_modules/@openrig/daemon/dist/domain/hosts/hosts-registry-reader.d.ts.map +1 -1
  590. package/node_modules/@openrig/daemon/dist/domain/hosts/hosts-registry-reader.js +34 -1
  591. package/node_modules/@openrig/daemon/dist/domain/hosts/hosts-registry-reader.js.map +1 -1
  592. package/node_modules/@openrig/daemon/dist/domain/markdown-address.d.ts +56 -0
  593. package/node_modules/@openrig/daemon/dist/domain/markdown-address.d.ts.map +1 -0
  594. package/node_modules/@openrig/daemon/dist/domain/markdown-address.js +188 -0
  595. package/node_modules/@openrig/daemon/dist/domain/markdown-address.js.map +1 -0
  596. package/node_modules/@openrig/daemon/dist/domain/model-divergence/current-generation-record.d.ts +73 -0
  597. package/node_modules/@openrig/daemon/dist/domain/model-divergence/current-generation-record.d.ts.map +1 -0
  598. package/node_modules/@openrig/daemon/dist/domain/model-divergence/current-generation-record.js +204 -0
  599. package/node_modules/@openrig/daemon/dist/domain/model-divergence/current-generation-record.js.map +1 -0
  600. package/node_modules/@openrig/daemon/dist/domain/model-divergence/effective-model-readers.d.ts +13 -0
  601. package/node_modules/@openrig/daemon/dist/domain/model-divergence/effective-model-readers.d.ts.map +1 -0
  602. package/node_modules/@openrig/daemon/dist/domain/model-divergence/effective-model-readers.js +163 -0
  603. package/node_modules/@openrig/daemon/dist/domain/model-divergence/effective-model-readers.js.map +1 -0
  604. package/node_modules/@openrig/daemon/dist/domain/model-divergence/model-divergence-monitor.d.ts +125 -0
  605. package/node_modules/@openrig/daemon/dist/domain/model-divergence/model-divergence-monitor.d.ts.map +1 -0
  606. package/node_modules/@openrig/daemon/dist/domain/model-divergence/model-divergence-monitor.js +199 -0
  607. package/node_modules/@openrig/daemon/dist/domain/model-divergence/model-divergence-monitor.js.map +1 -0
  608. package/node_modules/@openrig/daemon/dist/domain/periodic-snapshot-scheduler.d.ts +4 -0
  609. package/node_modules/@openrig/daemon/dist/domain/periodic-snapshot-scheduler.d.ts.map +1 -1
  610. package/node_modules/@openrig/daemon/dist/domain/periodic-snapshot-scheduler.js +5 -1
  611. package/node_modules/@openrig/daemon/dist/domain/periodic-snapshot-scheduler.js.map +1 -1
  612. package/node_modules/@openrig/daemon/dist/domain/permission-drift-observer.d.ts.map +1 -1
  613. package/node_modules/@openrig/daemon/dist/domain/permission-drift-observer.js +6 -1
  614. package/node_modules/@openrig/daemon/dist/domain/permission-drift-observer.js.map +1 -1
  615. package/node_modules/@openrig/daemon/dist/domain/predecessor-recap-resolver.d.ts +10 -3
  616. package/node_modules/@openrig/daemon/dist/domain/predecessor-recap-resolver.d.ts.map +1 -1
  617. package/node_modules/@openrig/daemon/dist/domain/predecessor-recap-resolver.js +61 -14
  618. package/node_modules/@openrig/daemon/dist/domain/predecessor-recap-resolver.js.map +1 -1
  619. package/node_modules/@openrig/daemon/dist/domain/process-census.d.ts +25 -0
  620. package/node_modules/@openrig/daemon/dist/domain/process-census.d.ts.map +1 -0
  621. package/node_modules/@openrig/daemon/dist/domain/process-census.js +47 -0
  622. package/node_modules/@openrig/daemon/dist/domain/process-census.js.map +1 -0
  623. package/node_modules/@openrig/daemon/dist/domain/resume-metadata-refresher.d.ts +41 -3
  624. package/node_modules/@openrig/daemon/dist/domain/resume-metadata-refresher.d.ts.map +1 -1
  625. package/node_modules/@openrig/daemon/dist/domain/resume-metadata-refresher.js +74 -31
  626. package/node_modules/@openrig/daemon/dist/domain/resume-metadata-refresher.js.map +1 -1
  627. package/node_modules/@openrig/daemon/dist/domain/review/compose.d.ts +5 -26
  628. package/node_modules/@openrig/daemon/dist/domain/review/compose.d.ts.map +1 -1
  629. package/node_modules/@openrig/daemon/dist/domain/review/compose.js +31 -57
  630. package/node_modules/@openrig/daemon/dist/domain/review/compose.js.map +1 -1
  631. package/node_modules/@openrig/daemon/dist/domain/review/gather.d.ts.map +1 -1
  632. package/node_modules/@openrig/daemon/dist/domain/review/gather.js +3 -2
  633. package/node_modules/@openrig/daemon/dist/domain/review/gather.js.map +1 -1
  634. package/node_modules/@openrig/daemon/dist/domain/{rig-policy/rig-policy-defaults.d.ts → rig-mode/rig-mode-defaults.d.ts} +2 -2
  635. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-defaults.d.ts.map +1 -0
  636. package/node_modules/@openrig/daemon/dist/domain/{rig-policy/rig-policy-defaults.js → rig-mode/rig-mode-defaults.js} +1 -1
  637. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-defaults.js.map +1 -0
  638. package/{daemon/dist/domain/rig-policy/rig-policy-store.d.ts → node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-store.d.ts} +6 -6
  639. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-store.d.ts.map +1 -0
  640. package/node_modules/@openrig/daemon/dist/domain/{rig-policy/rig-policy-store.js → rig-mode/rig-mode-store.js} +5 -5
  641. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-store.js.map +1 -0
  642. package/node_modules/@openrig/daemon/dist/domain/{rig-policy/rig-policy-types.d.ts → rig-mode/rig-mode-types.d.ts} +1 -1
  643. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-types.d.ts.map +1 -0
  644. package/{daemon/dist/domain/rig-policy/rig-policy-types.js → node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-types.js} +1 -1
  645. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-types.js.map +1 -0
  646. package/{daemon/dist/domain/rig-policy/rig-policy-validator.d.ts → node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-validator.d.ts} +2 -2
  647. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-validator.d.ts.map +1 -0
  648. package/node_modules/@openrig/daemon/dist/domain/{rig-policy/rig-policy-validator.js → rig-mode/rig-mode-validator.js} +3 -3
  649. package/node_modules/@openrig/daemon/dist/domain/rig-mode/rig-mode-validator.js.map +1 -0
  650. package/node_modules/@openrig/daemon/dist/domain/rigspec-instantiator.d.ts +4 -0
  651. package/node_modules/@openrig/daemon/dist/domain/rigspec-instantiator.d.ts.map +1 -1
  652. package/node_modules/@openrig/daemon/dist/domain/rigspec-instantiator.js +39 -0
  653. package/node_modules/@openrig/daemon/dist/domain/rigspec-instantiator.js.map +1 -1
  654. package/node_modules/@openrig/daemon/dist/domain/rigspec-schema.d.ts +7 -0
  655. package/node_modules/@openrig/daemon/dist/domain/rigspec-schema.d.ts.map +1 -1
  656. package/node_modules/@openrig/daemon/dist/domain/rigspec-schema.js +25 -2
  657. package/node_modules/@openrig/daemon/dist/domain/rigspec-schema.js.map +1 -1
  658. package/node_modules/@openrig/daemon/dist/domain/scope/logical-checkbox.d.ts +26 -0
  659. package/node_modules/@openrig/daemon/dist/domain/scope/logical-checkbox.d.ts.map +1 -0
  660. package/node_modules/@openrig/daemon/dist/domain/scope/logical-checkbox.js +65 -0
  661. package/node_modules/@openrig/daemon/dist/domain/scope/logical-checkbox.js.map +1 -0
  662. package/node_modules/@openrig/daemon/dist/domain/scope/node-file.d.ts +37 -0
  663. package/node_modules/@openrig/daemon/dist/domain/scope/node-file.d.ts.map +1 -0
  664. package/node_modules/@openrig/daemon/dist/domain/scope/node-file.js +55 -0
  665. package/node_modules/@openrig/daemon/dist/domain/scope/node-file.js.map +1 -0
  666. package/node_modules/@openrig/daemon/dist/domain/scope/plan-lock-artifacts.d.ts +12 -1
  667. package/node_modules/@openrig/daemon/dist/domain/scope/plan-lock-artifacts.d.ts.map +1 -1
  668. package/node_modules/@openrig/daemon/dist/domain/scope/plan-lock-artifacts.js +42 -2
  669. package/node_modules/@openrig/daemon/dist/domain/scope/plan-lock-artifacts.js.map +1 -1
  670. package/node_modules/@openrig/daemon/dist/domain/scope/scaffold-placeholder.d.ts +22 -0
  671. package/node_modules/@openrig/daemon/dist/domain/scope/scaffold-placeholder.d.ts.map +1 -1
  672. package/node_modules/@openrig/daemon/dist/domain/scope/scaffold-placeholder.js +24 -0
  673. package/node_modules/@openrig/daemon/dist/domain/scope/scaffold-placeholder.js.map +1 -1
  674. package/node_modules/@openrig/daemon/dist/domain/scope/scope-approve.d.ts +4 -0
  675. package/node_modules/@openrig/daemon/dist/domain/scope/scope-approve.d.ts.map +1 -1
  676. package/node_modules/@openrig/daemon/dist/domain/scope/scope-approve.js +56 -7
  677. package/node_modules/@openrig/daemon/dist/domain/scope/scope-approve.js.map +1 -1
  678. package/node_modules/@openrig/daemon/dist/domain/scope/scope-audit.d.ts +1 -1
  679. package/node_modules/@openrig/daemon/dist/domain/scope/scope-audit.d.ts.map +1 -1
  680. package/node_modules/@openrig/daemon/dist/domain/scope/scope-audit.js.map +1 -1
  681. package/node_modules/@openrig/daemon/dist/domain/scope/scope-view-projection.d.ts.map +1 -1
  682. package/node_modules/@openrig/daemon/dist/domain/scope/scope-view-projection.js +5 -2
  683. package/node_modules/@openrig/daemon/dist/domain/scope/scope-view-projection.js.map +1 -1
  684. package/node_modules/@openrig/daemon/dist/domain/seat-activity-service.d.ts +1 -0
  685. package/node_modules/@openrig/daemon/dist/domain/seat-activity-service.d.ts.map +1 -1
  686. package/node_modules/@openrig/daemon/dist/domain/seat-activity-service.js +39 -23
  687. package/node_modules/@openrig/daemon/dist/domain/seat-activity-service.js.map +1 -1
  688. package/node_modules/@openrig/daemon/dist/domain/seat-handover-service.d.ts +54 -15
  689. package/node_modules/@openrig/daemon/dist/domain/seat-handover-service.d.ts.map +1 -1
  690. package/node_modules/@openrig/daemon/dist/domain/seat-handover-service.js +74 -19
  691. package/node_modules/@openrig/daemon/dist/domain/seat-handover-service.js.map +1 -1
  692. package/node_modules/@openrig/daemon/dist/domain/seat-identity-reconciler.d.ts +17 -0
  693. package/node_modules/@openrig/daemon/dist/domain/seat-identity-reconciler.d.ts.map +1 -1
  694. package/node_modules/@openrig/daemon/dist/domain/seat-identity-reconciler.js +22 -0
  695. package/node_modules/@openrig/daemon/dist/domain/seat-identity-reconciler.js.map +1 -1
  696. package/node_modules/@openrig/daemon/dist/domain/session-jsonl.js +1 -1
  697. package/node_modules/@openrig/daemon/dist/domain/session-jsonl.js.map +1 -1
  698. package/node_modules/@openrig/daemon/dist/domain/session-transport.d.ts +8 -0
  699. package/node_modules/@openrig/daemon/dist/domain/session-transport.d.ts.map +1 -1
  700. package/node_modules/@openrig/daemon/dist/domain/session-transport.js +116 -0
  701. package/node_modules/@openrig/daemon/dist/domain/session-transport.js.map +1 -1
  702. package/node_modules/@openrig/daemon/dist/domain/shell-classifier.d.ts +23 -0
  703. package/node_modules/@openrig/daemon/dist/domain/shell-classifier.d.ts.map +1 -0
  704. package/node_modules/@openrig/daemon/dist/domain/shell-classifier.js +36 -0
  705. package/node_modules/@openrig/daemon/dist/domain/shell-classifier.js.map +1 -0
  706. package/node_modules/@openrig/daemon/dist/domain/slices/slice-detail-projector.d.ts.map +1 -1
  707. package/node_modules/@openrig/daemon/dist/domain/slices/slice-detail-projector.js +24 -3
  708. package/node_modules/@openrig/daemon/dist/domain/slices/slice-detail-projector.js.map +1 -1
  709. package/node_modules/@openrig/daemon/dist/domain/slices/slice-indexer.d.ts.map +1 -1
  710. package/node_modules/@openrig/daemon/dist/domain/slices/slice-indexer.js +16 -3
  711. package/node_modules/@openrig/daemon/dist/domain/slices/slice-indexer.js.map +1 -1
  712. package/node_modules/@openrig/daemon/dist/domain/spec-live-conformance.d.ts +22 -0
  713. package/node_modules/@openrig/daemon/dist/domain/spec-live-conformance.d.ts.map +1 -1
  714. package/node_modules/@openrig/daemon/dist/domain/spec-live-conformance.js +35 -0
  715. package/node_modules/@openrig/daemon/dist/domain/spec-live-conformance.js.map +1 -1
  716. package/node_modules/@openrig/daemon/dist/domain/spec-validation-advisory.d.ts +17 -0
  717. package/node_modules/@openrig/daemon/dist/domain/spec-validation-advisory.d.ts.map +1 -0
  718. package/node_modules/@openrig/daemon/dist/domain/spec-validation-advisory.js +38 -0
  719. package/node_modules/@openrig/daemon/dist/domain/spec-validation-advisory.js.map +1 -0
  720. package/node_modules/@openrig/daemon/dist/domain/successor-session-launcher.d.ts +7 -0
  721. package/node_modules/@openrig/daemon/dist/domain/successor-session-launcher.d.ts.map +1 -1
  722. package/node_modules/@openrig/daemon/dist/domain/successor-session-launcher.js +38 -1
  723. package/node_modules/@openrig/daemon/dist/domain/successor-session-launcher.js.map +1 -1
  724. package/node_modules/@openrig/daemon/dist/domain/sync-site-wrap.d.ts +9 -0
  725. package/node_modules/@openrig/daemon/dist/domain/sync-site-wrap.d.ts.map +1 -1
  726. package/node_modules/@openrig/daemon/dist/domain/sync-site-wrap.js +11 -0
  727. package/node_modules/@openrig/daemon/dist/domain/sync-site-wrap.js.map +1 -1
  728. package/node_modules/@openrig/daemon/dist/domain/topology-defaults-installer.d.ts +47 -0
  729. package/node_modules/@openrig/daemon/dist/domain/topology-defaults-installer.d.ts.map +1 -0
  730. package/node_modules/@openrig/daemon/dist/domain/topology-defaults-installer.js +92 -0
  731. package/node_modules/@openrig/daemon/dist/domain/topology-defaults-installer.js.map +1 -0
  732. package/node_modules/@openrig/daemon/dist/domain/transcript-rotation.d.ts +4 -0
  733. package/node_modules/@openrig/daemon/dist/domain/transcript-rotation.d.ts.map +1 -1
  734. package/node_modules/@openrig/daemon/dist/domain/transcript-rotation.js +61 -3
  735. package/node_modules/@openrig/daemon/dist/domain/transcript-rotation.js.map +1 -1
  736. package/node_modules/@openrig/daemon/dist/domain/transcript-store.d.ts.map +1 -1
  737. package/node_modules/@openrig/daemon/dist/domain/transcript-store.js +9 -2
  738. package/node_modules/@openrig/daemon/dist/domain/transcript-store.js.map +1 -1
  739. package/node_modules/@openrig/daemon/dist/domain/types.d.ts +18 -0
  740. package/node_modules/@openrig/daemon/dist/domain/types.d.ts.map +1 -1
  741. package/node_modules/@openrig/daemon/dist/domain/types.js.map +1 -1
  742. package/node_modules/@openrig/daemon/dist/domain/user-settings/settings-store.d.ts +10 -1
  743. package/node_modules/@openrig/daemon/dist/domain/user-settings/settings-store.d.ts.map +1 -1
  744. package/node_modules/@openrig/daemon/dist/domain/user-settings/settings-store.js +59 -0
  745. package/node_modules/@openrig/daemon/dist/domain/user-settings/settings-store.js.map +1 -1
  746. package/node_modules/@openrig/daemon/dist/domain/watchdog-auto-registration.d.ts +7 -0
  747. package/node_modules/@openrig/daemon/dist/domain/watchdog-auto-registration.d.ts.map +1 -1
  748. package/node_modules/@openrig/daemon/dist/domain/watchdog-auto-registration.js +27 -0
  749. package/node_modules/@openrig/daemon/dist/domain/watchdog-auto-registration.js.map +1 -1
  750. package/node_modules/@openrig/daemon/dist/domain/workspace/workspace-doctor.d.ts.map +1 -1
  751. package/node_modules/@openrig/daemon/dist/domain/workspace/workspace-doctor.js +4 -3
  752. package/node_modules/@openrig/daemon/dist/domain/workspace/workspace-doctor.js.map +1 -1
  753. package/node_modules/@openrig/daemon/dist/routes/activity.js +11 -2
  754. package/node_modules/@openrig/daemon/dist/routes/activity.js.map +1 -1
  755. package/node_modules/@openrig/daemon/dist/routes/bundles.d.ts +27 -0
  756. package/node_modules/@openrig/daemon/dist/routes/bundles.d.ts.map +1 -1
  757. package/node_modules/@openrig/daemon/dist/routes/bundles.js +107 -26
  758. package/node_modules/@openrig/daemon/dist/routes/bundles.js.map +1 -1
  759. package/node_modules/@openrig/daemon/dist/routes/context-packs.d.ts.map +1 -1
  760. package/node_modules/@openrig/daemon/dist/routes/context-packs.js +205 -0
  761. package/node_modules/@openrig/daemon/dist/routes/context-packs.js.map +1 -1
  762. package/node_modules/@openrig/daemon/dist/routes/crash-cart.d.ts +4 -0
  763. package/node_modules/@openrig/daemon/dist/routes/crash-cart.d.ts.map +1 -0
  764. package/node_modules/@openrig/daemon/dist/routes/crash-cart.js +144 -0
  765. package/node_modules/@openrig/daemon/dist/routes/crash-cart.js.map +1 -0
  766. package/node_modules/@openrig/daemon/dist/routes/missions.d.ts.map +1 -1
  767. package/node_modules/@openrig/daemon/dist/routes/missions.js +10 -6
  768. package/node_modules/@openrig/daemon/dist/routes/missions.js.map +1 -1
  769. package/node_modules/@openrig/daemon/dist/routes/{rig-policy.d.ts → rig-mode.d.ts} +3 -3
  770. package/node_modules/@openrig/daemon/dist/routes/rig-mode.d.ts.map +1 -0
  771. package/{daemon/dist/routes/rig-policy.js → node_modules/@openrig/daemon/dist/routes/rig-mode.js} +13 -13
  772. package/node_modules/@openrig/daemon/dist/routes/rig-mode.js.map +1 -0
  773. package/node_modules/@openrig/daemon/dist/routes/scope-approve.d.ts.map +1 -1
  774. package/node_modules/@openrig/daemon/dist/routes/scope-approve.js +4 -0
  775. package/node_modules/@openrig/daemon/dist/routes/scope-approve.js.map +1 -1
  776. package/node_modules/@openrig/daemon/dist/routes/scope-audit.d.ts.map +1 -1
  777. package/node_modules/@openrig/daemon/dist/routes/scope-audit.js +29 -2
  778. package/node_modules/@openrig/daemon/dist/routes/scope-audit.js.map +1 -1
  779. package/node_modules/@openrig/daemon/dist/routes/seat.d.ts.map +1 -1
  780. package/node_modules/@openrig/daemon/dist/routes/seat.js +18 -2
  781. package/node_modules/@openrig/daemon/dist/routes/seat.js.map +1 -1
  782. package/node_modules/@openrig/daemon/dist/routes/sessions.d.ts.map +1 -1
  783. package/node_modules/@openrig/daemon/dist/routes/sessions.js +66 -1
  784. package/node_modules/@openrig/daemon/dist/routes/sessions.js.map +1 -1
  785. package/node_modules/@openrig/daemon/dist/routes/transport.d.ts.map +1 -1
  786. package/node_modules/@openrig/daemon/dist/routes/transport.js +12 -3
  787. package/node_modules/@openrig/daemon/dist/routes/transport.js.map +1 -1
  788. package/node_modules/@openrig/daemon/dist/seat-recap-store-surface.d.ts +2 -0
  789. package/node_modules/@openrig/daemon/dist/seat-recap-store-surface.d.ts.map +1 -0
  790. package/node_modules/@openrig/daemon/dist/seat-recap-store-surface.js +6 -0
  791. package/node_modules/@openrig/daemon/dist/seat-recap-store-surface.js.map +1 -0
  792. package/node_modules/@openrig/daemon/dist/server.d.ts +3 -1
  793. package/node_modules/@openrig/daemon/dist/server.d.ts.map +1 -1
  794. package/node_modules/@openrig/daemon/dist/server.js +15 -5
  795. package/node_modules/@openrig/daemon/dist/server.js.map +1 -1
  796. package/node_modules/@openrig/daemon/dist/startup.d.ts.map +1 -1
  797. package/node_modules/@openrig/daemon/dist/startup.js +166 -6
  798. package/node_modules/@openrig/daemon/dist/startup.js.map +1 -1
  799. package/node_modules/@openrig/daemon/package.json +6 -1
  800. package/package.json +1 -1
  801. package/tui/dist/crash-cart/from-emit.d.ts +9 -0
  802. package/tui/dist/crash-cart/from-emit.d.ts.map +1 -1
  803. package/tui/dist/crash-cart/from-emit.js.map +1 -1
  804. package/tui/dist/crash-cart/keys.d.ts +1 -1
  805. package/tui/dist/crash-cart/keys.d.ts.map +1 -1
  806. package/tui/dist/crash-cart/keys.js +13 -2
  807. package/tui/dist/crash-cart/keys.js.map +1 -1
  808. package/tui/dist/crash-cart/one-click-gate.d.ts +5 -0
  809. package/tui/dist/crash-cart/one-click-gate.d.ts.map +1 -1
  810. package/tui/dist/crash-cart/one-click-gate.js +8 -0
  811. package/tui/dist/crash-cart/one-click-gate.js.map +1 -1
  812. package/tui/dist/crash-cart/render-crash-cart.d.ts +11 -0
  813. package/tui/dist/crash-cart/render-crash-cart.d.ts.map +1 -1
  814. package/tui/dist/crash-cart/render-crash-cart.js +113 -0
  815. package/tui/dist/crash-cart/render-crash-cart.js.map +1 -1
  816. package/tui/dist/crash-cart/restore-input.d.ts +32 -0
  817. package/tui/dist/crash-cart/restore-input.d.ts.map +1 -0
  818. package/tui/dist/crash-cart/restore-input.js +37 -0
  819. package/tui/dist/crash-cart/restore-input.js.map +1 -0
  820. package/tui/dist/crash-cart/restore-lifecycle.d.ts +66 -0
  821. package/tui/dist/crash-cart/restore-lifecycle.d.ts.map +1 -0
  822. package/tui/dist/crash-cart/restore-lifecycle.js +96 -0
  823. package/tui/dist/crash-cart/restore-lifecycle.js.map +1 -0
  824. package/tui/dist/crash-cart/restore-scroll.d.ts +14 -0
  825. package/tui/dist/crash-cart/restore-scroll.d.ts.map +1 -0
  826. package/tui/dist/crash-cart/restore-scroll.js +27 -0
  827. package/tui/dist/crash-cart/restore-scroll.js.map +1 -0
  828. package/tui/dist/daemon-client.d.ts +38 -0
  829. package/tui/dist/daemon-client.d.ts.map +1 -1
  830. package/tui/dist/daemon-client.js +15 -0
  831. package/tui/dist/daemon-client.js.map +1 -1
  832. package/tui/dist/main.js +146 -2
  833. package/tui/dist/main.js.map +1 -1
  834. package/tui/dist/render.d.ts +10 -0
  835. package/tui/dist/render.d.ts.map +1 -1
  836. package/tui/dist/render.js +63 -10
  837. package/tui/dist/render.js.map +1 -1
  838. package/daemon/dist/domain/rig-policy/rig-policy-defaults.d.ts.map +0 -1
  839. package/daemon/dist/domain/rig-policy/rig-policy-defaults.js.map +0 -1
  840. package/daemon/dist/domain/rig-policy/rig-policy-store.d.ts.map +0 -1
  841. package/daemon/dist/domain/rig-policy/rig-policy-store.js.map +0 -1
  842. package/daemon/dist/domain/rig-policy/rig-policy-types.d.ts.map +0 -1
  843. package/daemon/dist/domain/rig-policy/rig-policy-types.js.map +0 -1
  844. package/daemon/dist/domain/rig-policy/rig-policy-validator.d.ts.map +0 -1
  845. package/daemon/dist/domain/rig-policy/rig-policy-validator.js.map +0 -1
  846. package/daemon/dist/routes/rig-policy.d.ts.map +0 -1
  847. package/daemon/dist/routes/rig-policy.js.map +0 -1
  848. package/dist/commands/rig-policy.d.ts.map +0 -1
  849. package/dist/commands/rig-policy.js.map +0 -1
  850. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-defaults.d.ts.map +0 -1
  851. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-defaults.js.map +0 -1
  852. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-store.d.ts.map +0 -1
  853. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-store.js.map +0 -1
  854. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-types.d.ts.map +0 -1
  855. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-types.js.map +0 -1
  856. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-validator.d.ts.map +0 -1
  857. package/node_modules/@openrig/daemon/dist/domain/rig-policy/rig-policy-validator.js.map +0 -1
  858. package/node_modules/@openrig/daemon/dist/routes/rig-policy.d.ts.map +0 -1
  859. package/node_modules/@openrig/daemon/dist/routes/rig-policy.js.map +0 -1
@@ -0,0 +1,479 @@
1
+ ---
2
+ name: context-engineering
3
+ description: >-
4
+ Use when designing, reviewing, or debugging how an agent's context window gets filled, pruned,
5
+ or shared — choosing what loads at boot versus on demand, sizing an install or an always-loaded
6
+ file, fixing an agent that drifts, repeats itself, or forgets constraints mid-task, planning
7
+ compaction or summarization, deciding single-agent versus subagents, engineering handoffs
8
+ between agents, or picking a tool loadout. NOT for rewording a prompt's tone, choosing which
9
+ model to pin, or debugging business logic — those are adjacent moments this skill does not
10
+ serve. Historical 2024–2025 snapshot; not normative for present-day frontier models — see the
11
+ Status section.
12
+ metadata:
13
+ openrig:
14
+ stage: provisional
15
+ ---
16
+
17
+ # Traditional Context Engineering — 2024–2025 Snapshot
18
+
19
+ ## Status: provisional historical research snapshot
20
+
21
+ This skill is a provisional historical research snapshot of context-engineering practice as
22
+ published in 2024–2025. It is NOT normative. Do not apply it prescriptively to current frontier
23
+ models without re-verification. On any conflict, OpenRig current skills, explicit user rulings,
24
+ and directly measured OpenRig practice PREVAIL over this document. Treat these areas as
25
+ particularly suspect pending re-verification: compaction/summarization guidance, minimal-upfront
26
+ versus broad orientation, just-in-time lookup assumptions, fixed context ceilings, and
27
+ single-agent versus multi-agent advice.
28
+
29
+ Curated distillation of the best publicly available expertise on context engineering for coding
30
+ agents, drawn from primary sources at Anthropic, OpenAI, and leading practitioners (Manus,
31
+ Cognition, Chroma, LangChain, Drew Breunig, and others). Load on the moments the description
32
+ names; it is deliberately not part of any base walk.
33
+
34
+ ---
35
+
36
+ ## 1. The mental model: what context engineering is
37
+
38
+ **Definition.** Context engineering is "the set of strategies for curating and maintaining the
39
+ optimal set of tokens (information) during LLM inference" — everything that lands in the window:
40
+ system instructions, tool definitions, retrieved data, message history, and tool outputs, not
41
+ just the prompt text (Anthropic, *Effective context engineering for AI agents*). Andrej
42
+ Karpathy's framing, popularized via LangChain: "the delicate art and science of filling the
43
+ context window with just the right information for the next step" — the LLM is a CPU and the
44
+ context window is its RAM, and your job is deciding what gets loaded into RAM at each step
45
+ (LangChain, *Context Engineering for Agents*).
46
+
47
+ **Why it superseded prompt engineering.** A chatbot answers one question with whatever fits in
48
+ one turn. An agent runs in a loop, accumulating tool results, file contents, and history across
49
+ dozens or hundreds of steps. The improvements stop coming from rewording instructions and start
50
+ coming from *rewiring* — what the agent retrieves, in what order, and what gets evicted when the
51
+ window fills (Anthropic, ibid.). Philipp Schmid's formulation of the practical consequence:
52
+ "Agent failures aren't only model failures; they are context failures." Most of the time when a
53
+ capable model does something dumb, the context it was given made the dumb thing likely
54
+ (Schmid, *The New Skill in AI is Context Engineering*).
55
+
56
+ **The physical constraint: attention is a budget, not a bucket.** Three mechanisms make context
57
+ a scarce resource rather than free storage:
58
+
59
+ 1. **Quadratic attention.** In a transformer, every token attends to every other token — n²
60
+ pairwise relationships. Longer sequences stretch the model's ability to capture them, and
61
+ models are trained on distributions where short sequences dominate, so they have fewer
62
+ specialized parameters for context-wide dependencies. The result is "a performance gradient
63
+ rather than a hard cliff" (Anthropic, *Effective context engineering*).
64
+ 2. **Context rot.** Chroma's study of 18 frontier models showed reliability degrades as input
65
+ length grows *even on trivially simple tasks* like retrieval and text replication — and
66
+ degradation starts well before the window is full. What matters is not just length: distractor
67
+ presence, needle–question similarity, and haystack structure all change how fast performance
68
+ collapses (Chroma, *Context Rot*).
69
+ 3. **Position effects.** Models exhibit a U-shaped attention curve: information at the beginning
70
+ or end of a long context is used far better than information in the middle (Liu et al.,
71
+ *Lost in the Middle*).
72
+
73
+ **The one-sentence discipline.** From Anthropic: **"Find the smallest set of high-signal tokens
74
+ that maximize the likelihood of some desired outcome."** Everything else in this pack is a
75
+ technique in service of that sentence.
76
+
77
+ **The components you are engineering.** Schmid's inventory is a useful checklist of what
78
+ actually occupies the window: (1) system instructions, (2) the user's immediate request,
79
+ (3) state/history of the current session, (4) long-term memory, (5) retrieved external
80
+ information, (6) tool definitions, (7) output-format specifications (Schmid, ibid.). Each is a
81
+ separate dial. When an agent misbehaves, walk this list asking "which of these is missing,
82
+ stale, bloated, or contradictory?"
83
+
84
+ ---
85
+
86
+ ## 2. Core principles (and the why behind each)
87
+
88
+ **P1 — Minimal ≠ short; curate for signal density.** The goal is the smallest *sufficient* set
89
+ of tokens, not the shortest prompt. A system prompt should fully outline expected behavior; the
90
+ sin is low-signal filler, not length (Anthropic, *Effective context engineering*).
91
+
92
+ **P2 — Engineer for the next step, not the whole task.** Context is curated per inference step
93
+ (Karpathy via LangChain). The question is never "what might the agent ever need" but "what does
94
+ this step need to succeed." This is why loading everything upfront loses to just-in-time
95
+ retrieval on long tasks.
96
+
97
+ **P3 — Degradation precedes exhaustion.** Budget context well below the marketed window.
98
+ Chroma showed serious degradation mid-window; Breunig collects the operational evidence: a
99
+ Gemini agent's planning quality collapsed beyond ~100K tokens *[perishable snapshot, 2025–2026: model/vendor-specific — teach the mechanism, re-verify the number]* into repeating past actions, and
100
+ Databricks found correctness falling around 32K for Llama 3.1 405B (Breunig, *How Long Contexts
101
+ Fail*). *[perishable snapshot, 2025–2026: model/vendor-specific — teach the mechanism, re-verify the number]* These specific ceilings are model- and time-specific — the durable lesson is that every
102
+ model has one, and it is lower than the spec sheet.
103
+
104
+ **P4 — Stability is money and latency: design append-only.** Manus calls KV-cache hit rate "the
105
+ single most important metric for a production-stage AI agent": cached input tokens can cost 10x
106
+ less than uncached (their figure: $0.30 vs $3.00/MTok). *[perishable snapshot, 2025–2026: model/vendor-specific — teach the mechanism, re-verify the number]* One changed token invalidates the cache
107
+ for everything after it. Therefore: stable prompt prefixes (never embed a timestamp at the top),
108
+ append-only context (never rewrite history mid-session), deterministic serialization (Manus,
109
+ *Context Engineering for AI Agents*). Anthropic's caching docs confirm the mechanics: exact
110
+ prefix matching, cache reads at 0.1x base price, and a strict tools → system → messages
111
+ hierarchy where a change at any level invalidates everything below it (Anthropic, prompt
112
+ caching docs).
113
+
114
+ **P5 — Attention has a shape; place and refresh accordingly.** Because of the U-curve (Liu et
115
+ al.) and recency effects, put durable instructions at the start, and re-surface the *current
116
+ objective* near the end. Manus operationalizes this as **recitation**: the agent rewrites a
117
+ todo.md and appends it late in context on every step, "reciting its objectives into the end of
118
+ the context" to prevent goal drift across ~50-tool-call tasks (Manus, ibid.).
119
+
120
+ **P6 — Failures are context, not garbage.** Keep failed actions and stack traces in context;
121
+ the model updates its implicit beliefs and stops repeating the mistake (Manus, ibid.). The
122
+ 12-Factor Agents version: "Compact Errors into Context Window" — represent failures efficiently
123
+ so they inform the next step rather than either vanishing or flooding the window (HumanLayer,
124
+ *12-Factor Agents*, Factor 9).
125
+
126
+ **P7 — Share decisions, not just facts.** Cognition's two principles: "Share context, and share
127
+ full agent traces, not just individual messages" and "Actions carry implicit decisions, and
128
+ conflicting decisions carry bad results." Two workers given the same task summary but not each
129
+ other's traces will make incompatible implicit choices (their example: subagents building
130
+ visually clashing pieces of the same game) (Cognition, *Don't Build Multi-Agents*). Any handoff
131
+ or summary that transmits conclusions without the decisions behind them is lossy in the way that
132
+ breaks systems.
133
+
134
+ **P8 — Calibrate instruction altitude.** System prompts fail in two directions: hardcoded
135
+ brittle if-else logic (fragile, high-maintenance) and vague high-level guidance that "falsely
136
+ assumes shared context." Aim for "specific enough to guide behavior effectively, yet flexible
137
+ enough to provide strong heuristics." Start minimal with a capable model, then add instructions
138
+ driven by observed failure modes — not speculation (Anthropic, *Effective context engineering*).
139
+
140
+ **P9 — Own the window; treat the agent as a function of its context.** Deliberately control
141
+ what the model receives rather than accepting framework defaults ("Own your context window,"
142
+ Factor 3), and design the agent as "a stateless reducer" — output is a pure function of the
143
+ context you assembled, which makes context bugs reproducible and testable (HumanLayer,
144
+ *12-Factor Agents*, Factors 3 and 12).
145
+
146
+ ---
147
+
148
+ ## 3. The technique catalog
149
+
150
+ LangChain's taxonomy organizes nearly everything into four moves: **write** (persist outside the
151
+ window), **select** (pull the right things in), **compress** (shrink what's there), **isolate**
152
+ (split across contexts) (LangChain, *Context Engineering for Agents*). The named techniques:
153
+
154
+ ### 3.1 Progressive disclosure
155
+
156
+ **What:** Structure knowledge in layers so the agent loads only what the current task needs.
157
+ Anthropic's Agent Skills are the canonical design: Level 1 is name + description metadata
158
+ (always in the system prompt — just enough to know *when* the skill applies), Level 2 is the
159
+ SKILL.md body (loaded when relevant), Level 3+ is bundled files and scripts the agent navigates
160
+ "only as needed." Context becomes "effectively unbounded" because nothing loads until demanded
161
+ (Anthropic, *Equipping agents for the real world with Agent Skills*).
162
+
163
+ **Why it works:** It converts a token cost into a pointer cost. The analogy Anthropic uses is
164
+ "an onboarding guide for a new hire" — compartmentalized knowledge absorbed progressively.
165
+
166
+ **When:** Any recurring domain knowledge, workflow, or reference material. The rule of thumb
167
+ from Claude Code's docs: always-loaded files (CLAUDE.md) get only what applies broadly to every
168
+ session; anything situational belongs in an on-demand skill (Claude Code best practices).
169
+
170
+ ### 3.2 Just-in-time retrieval (vs. pre-computed context)
171
+
172
+ **What:** The agent maintains lightweight identifiers — file paths, queries, URLs — and loads
173
+ data at runtime with tools, instead of receiving everything up front. This mirrors human
174
+ cognition: we don't memorize corpora, we keep organization systems and retrieve on demand.
175
+ Metadata itself (folder hierarchies, naming conventions, timestamps) is signal (Anthropic,
176
+ *Effective context engineering*).
177
+
178
+ **Trade-off:** Runtime exploration is slower than pre-computed retrieval (embeddings/RAG). The
179
+ production answer is usually **hybrid**: some context up front for speed, plus tools for
180
+ autonomous exploration — Claude Code's CLAUDE.md-plus-grep pattern (Anthropic, ibid.). Classic
181
+ RAG — "selectively adding relevant information to help the LLM generate a better response" —
182
+ remains the right tool when the corpus is large and unindexed by structure (Breunig, *How to
183
+ Fix Your Context*).
184
+
185
+ **When:** Prefer just-in-time for coding agents in navigable environments (filesystems, git,
186
+ APIs); prefer indexed retrieval for large unstructured corpora; hybridize when latency matters.
187
+
188
+ ### 3.3 Compaction and summarization
189
+
190
+ **What:** When the window approaches its limit, summarize the trajectory, reinitialize with the
191
+ summary, and continue. Claude Code auto-compacts near the window limit (LangChain reports at
192
+ ~95%); the model distills decisions, code patterns, and open threads while discarding redundant
193
+ tool outputs (Anthropic, *Effective context engineering*; LangChain, ibid.).
194
+
195
+ **How to tune it:** "Start by maximizing recall to ensure your compaction prompt captures every
196
+ relevant piece of information from the trace, then iterate to improve precision by eliminating
197
+ superfluous content" (Anthropic, ibid.). Good summarization prompts enforce temporal ordering,
198
+ structured sections (environment, steps tried, current status), and explicit "UNVERIFIED"
199
+ marking on uncertain facts — because "if a bad fact enters the summary, it can poison future
200
+ behavior" (OpenAI Cookbook, *Session memory*).
201
+
202
+ **Trimming vs. summarizing** (OpenAI Cookbook, ibid.): keep-last-N-turns trimming is
203
+ deterministic, zero-latency, easy to reason about — but loses old constraints abruptly. LLM
204
+ summarization preserves long-range decisions compactly — but adds latency spikes, drift risk,
205
+ and observability burden. Trimming fits tool-heavy, independent tasks; summarization fits
206
+ long-horizon work where accumulated decisions matter.
207
+
208
+ **Cognition's caution:** a dedicated compressor model that distills "key details, events, and
209
+ decisions" is their recommended path for long tasks — and they note it "is hard to get right."
210
+ Getting it right means capturing decisions and their rationale, not just facts (Cognition,
211
+ ibid.).
212
+
213
+ ### 3.4 Context editing / tool-result clearing
214
+
215
+ **What:** The lightest-touch compaction: automatically drop stale tool calls and results deep in
216
+ history while preserving the conversational thread. Anthropic ships this as "context editing";
217
+ measured effects: context editing alone gave 29% improvement on internal agentic-search evals,
218
+ combined with the memory tool 39%; on a 100-turn web-search eval it let agents complete
219
+ workflows that would otherwise die of context exhaustion while cutting token consumption 84%
220
+ (Anthropic/Claude, *Context management*).
221
+
222
+ **Tension to know:** this conflicts with P4 (append-only for cache) and P6 (keep errors). The
223
+ reconciliation: clear *bulky, stale, already-acted-upon* tool outputs (a 30K-token file read
224
+ from 40 turns ago), keep *decisions and failures*. Manus's version keeps information
225
+ *restorable* — drop a webpage's content but keep its URL, drop a document's body but keep its
226
+ path (Manus, ibid.).
227
+
228
+ ### 3.5 Structured note-taking (agentic memory)
229
+
230
+ **What:** The agent writes notes to persistent storage outside the window — a NOTES.md, a
231
+ todo.md, a memory directory — and pulls them back when relevant. Persistent memory with minimal
232
+ context overhead. Anthropic's example: Claude playing Pokémon "maintains precise tallies across
233
+ thousands of game steps," builds maps, and remembers strategies across multi-hour sessions
234
+ (Anthropic, *Effective context engineering*). Anthropic's memory tool productizes this as
235
+ file-based CRUD in a client-side memory directory persisting across conversations
236
+ (Anthropic/Claude, *Context management*).
237
+
238
+ **The general form — filesystem as ultimate context:** Manus treats the filesystem as memory
239
+ that is "unlimited in size, persistent by nature, and directly operable by the agent itself"
240
+ (Manus, ibid.). Breunig's name for the family is **context offloading**; even a simple
241
+ scratchpad ("think" tool) produced up to 54% improvement on specialized-agent benchmarks
242
+ (Breunig, *How to Fix Your Context*).
243
+
244
+ **Memory layers in practice** (synthesis of LangChain + Anthropic + OpenAI): (1) in-context
245
+ working memory — the current window; (2) session-scoped scratchpads/todo files; (3) persistent
246
+ cross-session memory — files or stores, retrieved by relevance; (4) always-loaded curated core
247
+ (CLAUDE.md-class files), kept ruthlessly small. Information should flow *down* this stack as it
248
+ proves durable, and each layer buys persistence at the price of retrieval reliability.
249
+
250
+ ### 3.6 Sub-agents and context isolation
251
+
252
+ **What:** Breunig's "context quarantine": isolate work in dedicated threads, each with its own
253
+ window (Breunig, *How to Fix Your Context*). Anthropic's research system is the flagship: an
254
+ orchestrator spawns parallel subagents, each exploring one facet with a clean window, each
255
+ returning a *condensed* summary — typically 1,000–2,000 tokens — to the coordinator.
256
+ "Subagents facilitate compression by operating in parallel with their own context windows"
257
+ (Anthropic, *Multi-agent research system*). The multi-agent system beat single-agent Claude
258
+ Opus 4 by 90.2% on their internal research eval, at the price of ~15x the tokens of a chat
259
+ (Anthropic, ibid.).
260
+
261
+ **When it wins:** read-heavy, parallelizable, breadth-first work — research, codebase
262
+ investigation, review — where workers' outputs are *reports* that the orchestrator integrates.
263
+ Claude Code's guidance is exactly this: "use subagents to investigate" so exploration burns a
264
+ disposable context, not your main one; and use a fresh-context subagent for adversarial review,
265
+ because "a fresh context improves code review since Claude won't be biased toward code it just
266
+ wrote" (Claude Code best practices).
267
+
268
+ **When it loses:** write-heavy, coherence-critical work. Cognition's argument (P7): parallel
269
+ workers make conflicting implicit decisions and current models can't negotiate them away;
270
+ "running multiple agents in collaboration only results in fragile systems" for building
271
+ software. Their prescription is a single agent with full traces plus a compressor (Cognition,
272
+ ibid.). OpenAI's builder guidance points the same direction: maximize a single agent's
273
+ capability first and reach for multi-agent orchestration only when single-agent complexity
274
+ demonstrably fails (OpenAI, *A practical guide to building agents*). See §6 for the
275
+ reconciliation.
276
+
277
+ ### 3.7 Structured handoffs and delegation contracts
278
+
279
+ **What:** When context must cross an agent boundary, the transfer is an engineered artifact,
280
+ not a vibe. Anthropic's hard-won spec for what every delegated task must contain: **an
281
+ objective, an output format, guidance on tools and sources, and clear task boundaries.**
282
+ Without it, "agents duplicate work, leave gaps, or fail to find necessary information"
283
+ (Anthropic, *Multi-agent research system*).
284
+
285
+ **Effort scaling belongs in the contract:** encode explicit rules — "simple fact-finding
286
+ requires just 1 agent with 3–10 tool calls, direct comparisons might need 2–4 subagents with
287
+ 10–15 calls each" — or orchestrators over-provision wildly (early versions spawned 50 subagents
288
+ for simple queries) (Anthropic, ibid.).
289
+
290
+ **Returns are contracts too:** the worker's report back is a compression step (1–2K tokens,
291
+ per §3.6) and inherits every summarization risk in §3.3 — a handoff that reports conclusions
292
+ without decisions violates P7. The spec-then-fresh-session pattern is the single-player
293
+ version: interview, write a self-contained SPEC.md (files, interfaces, out-of-scope,
294
+ end-to-end verification step), then start a clean session to execute it (Claude Code best
295
+ practices).
296
+
297
+ ### 3.8 Tool loadout and tool design
298
+
299
+ **Selection:** "Every model performs worse when provided with more than one tool" is the
300
+ provocative headline from Berkeley's function-calling data; a quantized Llama 3.1 8B failed
301
+ with 46 tools and succeeded with 19 (Breunig, *How Long Contexts Fail*). Dynamic tool
302
+ selection — RAG over tool descriptions — improved Llama 3.1 8B performance 44% (Breunig, *How
303
+ to Fix Your Context*); LangChain cites ~3x tool-selection accuracy from the same family of
304
+ techniques (LangChain, ibid.). Anthropic's design rule: tools must have minimal overlap — "if a
305
+ human engineer can't definitively say which tool should be used in a given situation, an agent
306
+ can't be expected to do better" (Anthropic, *Effective context engineering*).
307
+
308
+ **Response design:** tool outputs are context injections; engineer them. Paginate, filter, and
309
+ truncate with sensible defaults (Claude Code caps tool responses at 25,000 tokens *[perishable snapshot, 2025–2026: model/vendor-specific — teach the mechanism, re-verify the number]*); prefer
310
+ semantically meaningful names over UUIDs; offer a `response_format: concise|detailed` knob;
311
+ consolidate chains of granular calls into one higher-level tool (`schedule_event`, not
312
+ `list_users` + `list_events` + `create_event`); use error messages to steer the agent toward
313
+ efficient strategies like "many small targeted searches" (Anthropic, *Writing effective tools
314
+ for agents*). CLI tools are often the most context-efficient integration surface of all
315
+ (Claude Code best practices).
316
+
317
+ **Masking over removal:** dynamically removing tools mid-session invalidates the KV cache and
318
+ confuses the model about past references; prefer masking token logits to constrain choice
319
+ while keeping definitions stable (Manus, ibid.).
320
+
321
+ ### 3.9 Context budgets and caching discipline
322
+
323
+ **What:** Treat the window as a budgeted resource with an explicit spending plan: how much for
324
+ system + tools, how much reserved for the task, at what fill level compaction triggers. Claude
325
+ Code's docs are blunt: "The context window is the most important resource to manage," and its
326
+ UX (a /context inspector, status-line usage tracking, /clear, targeted /compact) is budget
327
+ tooling (Claude Code best practices). Chroma's practical corollary: set working budgets far
328
+ below the advertised window for high-accuracy work (Chroma, ibid.).
329
+
330
+ **Caching discipline (the mechanics behind P4):** structure prompts static-first (tools →
331
+ system → messages); place cache breakpoints on the last *stable* block, never on content that
332
+ changes per request; verify with cache-read/cache-write token counts rather than assuming.
333
+ A timestamp above the fold means you pay cache-write prices on every request forever
334
+ (Anthropic, prompt caching docs; Manus, ibid.).
335
+
336
+ **Few-shot rut:** uniform repeated action-observation patterns in context cause the model to
337
+ mimic rhythm over substance — "drift, overgeneralization, or sometimes hallucination." Inject
338
+ structured variation in serialization and phrasing (Manus, ibid.).
339
+
340
+ ---
341
+
342
+ ## 4. Failure modes
343
+
344
+ Breunig's four-way taxonomy (*How Long Contexts Fail*) is the field's shared vocabulary; know
345
+ these by name:
346
+
347
+ 1. **Context poisoning** — "a hallucination or other error makes it into the context, where it
348
+ is repeatedly referenced." The Gemini-plays-Pokémon agent poisoned its own goals section and
349
+ pursued impossible objectives. Nastiest via summaries: one bad fact in a compaction poisons
350
+ every future turn (OpenAI Cookbook, ibid.). *Mitigations:* validate before persisting, mark
351
+ uncertain facts UNVERIFIED, keep summaries auditable, quarantine risky exploration in
352
+ subagents.
353
+ 2. **Context distraction** — the context grows so long "the model over-focuses on the context,
354
+ neglecting what it learned during training." Symptom: repeating past actions instead of
355
+ synthesizing new plans (Gemini beyond ~100K *[perishable snapshot, 2025–2026: model/vendor-specific — teach the mechanism, re-verify the number]*). *Mitigations:* budgets, compaction, recitation.
356
+ 3. **Context confusion** — "superfluous content in the context is used by the model to generate
357
+ a low-quality response." Prime driver: oversized tool loadouts. *Mitigations:* tool loadout
358
+ selection, pruning, progressive disclosure.
359
+ 4. **Context clash** — accumulated information and instructions that contradict each other.
360
+ Microsoft/Salesforce measured a 39% average drop when prompts were sharded across turns; o3
361
+ fell 98.1 → 64.1, because models "make assumptions in early turns... when LLMs take a wrong
362
+ turn in a conversation, they get lost and do not recover." *Mitigations:* consolidate
363
+ requirements before executing (spec first), clear-and-restart over correcting repeatedly.
364
+
365
+ Add the operational failures from production systems:
366
+
367
+ 5. **Context rot at scale** — silent degradation well before the window is full (Chroma).
368
+ 6. **Coordination failures** — duplicated work, gaps, 50 subagents on a trivial query,
369
+ conflicting implicit decisions between parallel workers (Anthropic, *Multi-agent*;
370
+ Cognition).
371
+ 7. **Kitchen-sink sessions and correction spirals** — Claude Code's docs name the human-loop
372
+ versions: unrelated tasks sharing one window; and repeated corrections polluting context
373
+ with failed approaches — "after two failed corrections, /clear and write a better initial
374
+ prompt incorporating what you learned." Also the over-specified always-loaded file:
375
+ "Bloated CLAUDE.md files cause Claude to ignore your actual instructions" — for each line
376
+ ask "Would removing this cause mistakes?"; if not, cut (Claude Code best practices).
377
+ 8. **Lost-in-the-middle placement bugs** — the critical constraint buried at token 60,000 of
378
+ 120,000 (Liu et al.).
379
+
380
+ ---
381
+
382
+ ## 5. How the best teams operate
383
+
384
+ **They measure token-shaped things.** Anthropic found token usage alone explains 80% of
385
+ performance variance in their research eval (Anthropic, *Multi-agent*); Manus optimizes
386
+ KV-cache hit rate as the top-line production metric (Manus). Elite teams instrument context —
387
+ fill levels, cache hits, tokens per task — before theorizing.
388
+
389
+ **They iterate from observed failures, with the model in the loop.** Anthropic's tool and skill
390
+ guidance is evaluation-first: build representative tasks, watch real transcripts, let the model
391
+ critique its own failures, refine, re-run against held-out sets (Anthropic, *Writing effective
392
+ tools*; *Agent Skills*). Prompts start minimal and grow only where failures demand (P8). And
393
+ automated evals aren't sufficient: human testers caught Anthropic's agents "consistently
394
+ choosing SEO-optimized content farms over authoritative sources" — a context-quality failure no
395
+ programmatic eval flagged (Anthropic, *Multi-agent*).
396
+
397
+ **They keep the always-loaded core tiny and push everything else behind disclosure.** Concise
398
+ checked-in CLAUDE.md-class files for what applies every session; skills for everything
399
+ situational; pruning as routine maintenance ("treat CLAUDE.md like code") (Claude Code best
400
+ practices).
401
+
402
+ **They design the write path around verification and fresh contexts.** Explore → plan →
403
+ implement → verify, with plan mode separating research from execution; a check the agent can
404
+ run (tests, build, screenshot diff) so the loop closes without a human; specs executed in fresh
405
+ sessions; adversarial review in a fresh subagent context (Claude Code best practices).
406
+
407
+ **They engineer for the cache and the filesystem.** Stable prefixes, append-only histories,
408
+ masked (not removed) tools, files as unlimited restorable memory, recitation for goal
409
+ stability, errors left visible (Manus). These are production-economics practices as much as
410
+ quality practices.
411
+
412
+ **They match architecture to task shape.** Anthropic's own selection heuristic: compaction for
413
+ long conversational flows; note-taking for iterative work with milestones (coding fits here);
414
+ multi-agent for parallel-explorable research (Anthropic, *Effective context engineering*).
415
+
416
+ ---
417
+
418
+ ## 6. Decision guide
419
+
420
+ | Situation | Reach for | Source |
421
+ |---|---|---|
422
+ | Recurring domain knowledge, sometimes needed | Skill w/ progressive disclosure | Anthropic Skills |
423
+ | Rules needed every session | Tiny curated always-loaded file; prune ruthlessly | Claude Code docs |
424
+ | Large explorable environment (repo, filesystem) | Just-in-time retrieval via tools; hybrid if latency-bound | Anthropic CE |
425
+ | Large unstructured corpus | Indexed retrieval (RAG) | Breunig |
426
+ | Long task nearing window limit | Compaction (recall-first, then precision); or clear stale tool results | Anthropic CE / context mgmt |
427
+ | Long task with milestones | Structured notes + todo recitation | Anthropic CE, Manus |
428
+ | Cross-session persistence | File-based memory outside the window | Anthropic context mgmt, Manus |
429
+ | Breadth-first research / investigation / review | Parallel subagents, condensed returns, explicit delegation contract + effort scaling | Anthropic multi-agent |
430
+ | Coherent build/edit on one artifact | Single agent, full traces, compressor for length — not parallel workers | Cognition |
431
+ | Many tools available | Loadout selection; consolidate; namespace; no overlap | Breunig, Anthropic tools |
432
+ | Cost/latency pressure | Stable prefix + append-only + cache breakpoints; mask don't remove | Manus, Anthropic caching |
433
+ | Agent repeating itself / drifting | Suspect distraction: check fill level, compact or clear, recite goals | Breunig, Manus |
434
+ | Agent confidently wrong about earlier "facts" | Suspect poisoning: audit summaries and notes, restart from clean spec | Breunig, OpenAI Cookbook |
435
+
436
+ ---
437
+
438
+ ## 7. Contested territory and thin spots (curator flags)
439
+
440
+ - **Multi-agent vs. single-agent is genuinely contested.** Anthropic's 90.2% win (read-heavy
441
+ research) and Cognition's "don't build multi-agents" (write-heavy engineering) are both
442
+ primary, both credible, and resolve on task shape: parallelize *reads*, serialize *writes*,
443
+ and make every boundary-crossing an engineered contract. Present both; don't flatten this
444
+ into one rule.
445
+ - **All numeric ceilings are perishable.** 32K/100K distraction ceilings, minimum-cacheable
446
+ token counts, the 10x cache price ratio, 25K tool-response caps — model- and vendor-specific
447
+ snapshots (2025–2026). Teach the mechanism, re-verify the numbers.
448
+ - **Second-hand figures.** The 44% tool-selection gain, 54% think-tool gain, 39% sharded-prompt
449
+ drop, and Berkeley tool numbers arrive via Breunig's synthesis of third-party papers —
450
+ directionally solid, not independently verified here.
451
+ - **OpenAI's public context-engineering corpus is thinner than Anthropic's.** Their best
452
+ material is SDK cookbooks (trimming vs. summarization is genuinely good) and the general
453
+ agents guide; most named-technique literature comes from Anthropic and practitioners.
454
+ - **Long-context vs. retrieval is unsettled.** Growing windows keep re-raising "just stuff it
455
+ all in"; context rot is the standing rebuttal, but the equilibrium moves with every model
456
+ generation.
457
+
458
+ ---
459
+
460
+ ## Sources
461
+
462
+ 1. Anthropic — Effective context engineering for AI agents — https://www.anthropic.com/engineering/effective-context-engineering-for-ai-agents
463
+ 2. Anthropic — How we built our multi-agent research system — https://www.anthropic.com/engineering/multi-agent-research-system
464
+ 3. Anthropic — Equipping agents for the real world with Agent Skills — https://www.anthropic.com/engineering/equipping-agents-for-the-real-world-with-agent-skills
465
+ 4. Anthropic — Writing effective tools for agents — https://www.anthropic.com/engineering/writing-tools-for-agents
466
+ 5. Anthropic/Claude — Managing context on the Claude Developer Platform (context editing, memory tool) — https://claude.com/blog/context-management
467
+ 6. Anthropic — Claude Code best practices — https://code.claude.com/docs/en/best-practices
468
+ 7. Anthropic — Prompt caching documentation — https://platform.claude.com/docs/en/build-with-claude/prompt-caching
469
+ 8. Chroma — Context Rot: How Increasing Input Tokens Impacts LLM Performance — https://www.trychroma.com/research/context-rot
470
+ 9. Drew Breunig — How Long Contexts Fail — https://www.dbreunig.com/2025/06/22/how-contexts-fail-and-how-to-fix-them.html
471
+ 10. Drew Breunig — How to Fix Your Context — https://www.dbreunig.com/2025/06/26/how-to-fix-your-context.html
472
+ 11. Cognition — Don't Build Multi-Agents — https://cognition.com/blog/dont-build-multi-agents
473
+ 12. Manus (Yichao "Peak" Ji) — Context Engineering for AI Agents: Lessons from Building Manus — https://manus.im/blog/Context-Engineering-for-AI-Agents-Lessons-from-Building-Manus
474
+ 13. LangChain — Context Engineering for Agents — https://www.langchain.com/blog/context-engineering-for-agents
475
+ 14. Philipp Schmid — The New Skill in AI is Context Engineering — https://www.philschmid.de/context-engineering
476
+ 15. HumanLayer (Dex Horthy) — 12-Factor Agents — https://github.com/humanlayer/12-factor-agents
477
+ 16. Liu et al. — Lost in the Middle: How Language Models Use Long Contexts — https://arxiv.org/abs/2307.03172
478
+ 17. OpenAI — A practical guide to building agents — https://openai.com/business/guides-and-resources/a-practical-guide-to-building-ai-agents/
479
+ 18. OpenAI Cookbook — Context engineering: short-term memory management with Sessions — https://developers.openai.com/cookbook/examples/agents_sdk/session_memory
@@ -33,6 +33,15 @@ Write the test first. Watch it fail. Write minimal code to pass.
33
33
 
34
34
  Thinking "skip TDD just this once"? Stop. That's rationalization.
35
35
 
36
+ **Chunk size is a dial, and it points up (2026-08) — this is NOT "skip TDD".** *How much* you build per
37
+ red-green cycle is configurable, and with frontier agents handling hour-plus goal-oriented work it is
38
+ **much larger than the classic tiny ping-pong**, and rising. Keep everything below — the Iron Law, red
39
+ before green, two sets of eyes, the guard structure — **fully intact**; only the *cadence / granularity*
40
+ loosens. You still write the failing test(s) first for the chunk; the chunk is simply bigger. Tiny
41
+ back-and-forth is overhead, not virtue, once the SDLC's gates (QA, review, guards) bound a larger chunk's
42
+ risk. Match the chunk to the task; treat it as a configured lever — never as license to write code before
43
+ its test (that's the rationalization this skill exists to stop).
44
+
36
45
  ## The Iron Law
37
46
 
38
47
  ```
@@ -0,0 +1,25 @@
1
+ # Worked project-tree example (demo)
2
+
3
+ This folder is a WORKED EXAMPLE of the project tree's chain files — the other
4
+ tree from the topology defaults this rig also ships. Copy the shapes, not the
5
+ content.
6
+
7
+ **Why project context cannot ship as a default, plainly:** it describes what
8
+ *you* are building. A mission's intent, a slice's specification, a proof
9
+ contract — no vendor can author those in advance, and installing someone
10
+ else's would put a stranger's project in your agents' heads. That is why the
11
+ topology tree ships curated defaults (how a team runs well is largely
12
+ general) while the project tree ships only this example (what you build is
13
+ yours alone). See `docs/reference/chain-file-convention.md`.
14
+
15
+ The shape, one chain name per altitude:
16
+
17
+ ```
18
+ missions/<mission>/SPEC.md intent in frontmatter; context slices need
19
+ missions/<mission>/slices/<slice>/SPEC.md the ONLY altitude that specifies
20
+ .../PROGRESS.md derived progress rail
21
+ .../PROOF.md retained evidence: did it actually work
22
+ ```
23
+
24
+ `rig scope mission create` / `rig scope slice create` scaffold these for real
25
+ projects — prefer the tooling to hand-copying this folder.
@@ -0,0 +1,19 @@
1
+ ---
2
+ id: demo.improve-onboarding
3
+ intent: >-
4
+ EXAMPLE — New users reach a working first rig in under ten minutes without
5
+ reading reference docs. (A mission states an OUTCOME; it specifies nothing —
6
+ specification is a leaf property, down in the slices.)
7
+ status: example
8
+ created: 2026-08-23
9
+ ---
10
+
11
+ # Mission: improve-onboarding (worked example)
12
+
13
+ A mission is a folder of slices plus the context those slices need. Its
14
+ `intent:` frontmatter composes UP the chain — an agent walking leaf-to-root
15
+ reads the slice's intent, then this one, and knows why the leaf exists.
16
+
17
+ Keep the body short: links to the evidence that motivated the mission, the
18
+ constraint that bounds it, the person who owns the outcome. Everything
19
+ buildable belongs in a slice.
@@ -0,0 +1,6 @@
1
+ # Progress (worked example)
2
+
3
+ Progress is DERIVED from marks like these, never authored above them — a
4
+ stored summary drifts into a confident lie.
5
+
6
+ - 2026-08-23 EXAMPLE: slice scaffolded; proof contract authored.
@@ -0,0 +1,7 @@
1
+ # Proof (worked example)
2
+
3
+ Evidence lands here via `rig proof add … --evidences` (hand-placed files stay
4
+ permanently `unverified` in the DELIVERED view). Each proof-contract checkbox
5
+ cites its artifact by path. This example slice ships with its contract
6
+ unmet — exactly how a real slice looks before the work is proven, and why a
7
+ slice is never done until every item has evidence.
@@ -0,0 +1,31 @@
1
+ ---
2
+ id: demo.improve-onboarding.01
3
+ slice: 01-shorten-first-run
4
+ mission: improve-onboarding
5
+ intent: >-
6
+ EXAMPLE — The getting-started path launches a working rig with one command
7
+ and shows the user their first agent inside two minutes.
8
+ status: example
9
+ stage: wip
10
+ created: 2026-08-23
11
+ ---
12
+
13
+ # Slice: 01-shorten-first-run (worked example)
14
+
15
+ ## Intent
16
+
17
+ One command to a running rig; first visible agent within two minutes. (The
18
+ slice is the ONLY altitude that specifies — these exact section headings are
19
+ what the UI projects on.)
20
+
21
+ ## Mini-requirements
22
+
23
+ 1. `rig up demo` succeeds on a machine that has only run the installer.
24
+ 2. The attach hint lands the user in a seat that greets them.
25
+
26
+ ## Proof contract
27
+
28
+ - [ ] A timed transcript of the first run on a clean machine, under two
29
+ minutes from command to visible agent. (Each promise pairs with an
30
+ observable artifact — the one check that reliably goes unmade is "did
31
+ it actually work.")
@@ -0,0 +1,24 @@
1
+ # Instance Craft — shipped defaults
2
+
3
+ <!-- Shipped by the product-team rig spec (copy-if-absent; this file is yours
4
+ to append to — a later rig-up never overwrites it). Curated, generally
5
+ applicable practice for EVERY seat on this instance. Machine-wide facts
6
+ belong here; rig norms belong one level down; seat specifics at the seat. -->
7
+
8
+ - **Check, do not recall.** Anything you remember about a file, a queue, or a
9
+ seat is a claim about the past. `rig whoami`, `rig ps`, `rig queue list
10
+ --mine` before any opinion; the filesystem and database are always ahead of
11
+ your memory.
12
+ - **Derive paths from configuration.** `rig config get <key>` answers where
13
+ things live (`workspace.root`, `topology.root`, `db.path`). A literal path
14
+ copied from another machine is wrong on this one.
15
+ - **Two trees.** The topology tree (this file's tree: instance → rig → seat)
16
+ carries how work is done; the project tree (missions → slices) carries what
17
+ is being built. Confusing them is the most common orientation error.
18
+ - **Verify by effect, never by success message.** Re-read from disk, run the
19
+ consumer, count the rows. Zero is not a plausible success.
20
+ - **A scoped search is not a global absence.** "Not in the place I looked" and
21
+ "not anywhere" are different claims; say which one you have.
22
+ - **Trace before trusting context**: `rig context trace --rig <rig> --seat
23
+ <seat> --name <NAME>.md` walks this tree from where you stand. Your reads
24
+ ARE the walk.
@@ -0,0 +1,21 @@
1
+ # Rig Craft — shipped defaults (product-team)
2
+
3
+ <!-- Shipped by the product-team rig spec (copy-if-absent; append freely — a
4
+ later rig-up never overwrites). Rig-wide norms every member holds. -->
5
+
6
+ - **If another seat must ACT, it needs a queue row.** A send informs; only a
7
+ row creates an auditable obligation. Pass work with `rig queue handoff` so
8
+ the close and the create are one transaction.
9
+ - **A turn holding work ends by handing off or naming a live blocker.**
10
+ Ending a turn with a summary in your own terminal is going dark: from
11
+ outside, a clean finish and a crash are identical.
12
+ - **Triage your board by baton, never by count.** A claimed row with an owner
13
+ is work; an informational row is not. `rig queue transitions <id>` tells a
14
+ deliberate park from a strand — the row's face cannot.
15
+ - **Transport negatives lie.** A timeout is INDETERMINATE, not failed:
16
+ reconcile by ID before any retry, or you fork the row. Never re-send on a
17
+ negative signal; confirm by reading the far end.
18
+ - **Count methods, not votes.** Seats that ran the same command in the same
19
+ tree are one datapoint wearing several hats.
20
+ - **State the rigor level you chose for a dispatched task, in one line.**
21
+ Heavy process is earned by irreversibility, not importance.