oh-my-opencode 5.1.84 → 5.1.86

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 (405) hide show
  1. package/.agents/command/remove-deadcode.md +1 -1
  2. package/.agents/skills/remove-deadcode/SKILL.md +1 -1
  3. package/.agents/skills/work-with-pr/SKILL.md +2 -2
  4. package/.opencode/command/remove-deadcode.md +1 -1
  5. package/.opencode/skills/work-with-pr/SKILL.md +2 -2
  6. package/THIRD-PARTY-NOTICES.md +9 -3
  7. package/dist/cli/index.js +1022 -842
  8. package/dist/cli/service-auth/devices.d.ts +5 -2
  9. package/dist/cli-node/index.js +1022 -842
  10. package/dist/config/schema/agent-names.d.ts +1 -0
  11. package/dist/index.js +180 -205
  12. package/dist/skills/browser/SKILL.md +4 -1
  13. package/dist/skills/browser/references/commands.md +5 -2
  14. package/dist/skills/browser/references/desktop.md +1 -0
  15. package/dist/skills/browser/references/owned-engine/README.md +2 -0
  16. package/dist/skills/browser/references/owned-engine/frames-and-humans.md +2 -0
  17. package/dist/skills/browser/references/owned-engine/network.md +10 -5
  18. package/dist/skills/browser/references/recipes/1password.md +2 -0
  19. package/dist/skills/browser/runtime/omowright/index.js +11 -11
  20. package/dist/skills/browser/runtime/omowright/manifest.json +4 -4
  21. package/dist/skills/debugging/SKILL.md +1 -1
  22. package/dist/skills/git/SKILL.md +62 -0
  23. package/dist/skills/git/agents/openai.yaml +13 -0
  24. package/dist/skills/github/SKILL.md +94 -0
  25. package/dist/skills/github/references/branch-rules.md +129 -0
  26. package/dist/skills/github/references/evidence-attachments.md +16 -0
  27. package/dist/skills/github/references/repo-setup.md +152 -0
  28. package/dist/skills/github/references/waiting.md +52 -0
  29. package/dist/skills/github/references/workflows.md +161 -0
  30. package/dist/skills/github/scripts/cli.ts +8 -0
  31. package/dist/skills/github/scripts/package.json +12 -0
  32. package/dist/skills/github/scripts/sdk.ts +11 -0
  33. package/dist/skills/github/scripts/src/account.ts +243 -0
  34. package/dist/skills/github/scripts/src/actions-write.ts +86 -0
  35. package/dist/skills/github/scripts/src/actions.ts +210 -0
  36. package/dist/skills/github/scripts/src/attestations.ts +136 -0
  37. package/dist/skills/github/scripts/src/blake2b.ts +102 -0
  38. package/dist/skills/github/scripts/src/branch-protection.ts +192 -0
  39. package/dist/skills/github/scripts/src/caches.ts +105 -0
  40. package/dist/skills/github/scripts/src/checks.ts +107 -0
  41. package/dist/skills/github/scripts/src/codespaces.ts +230 -0
  42. package/dist/skills/github/scripts/src/conversation-lock.ts +50 -0
  43. package/dist/skills/github/scripts/src/discussion-list.ts +126 -0
  44. package/dist/skills/github/scripts/src/discussion-lookup.ts +127 -0
  45. package/dist/skills/github/scripts/src/discussions.ts +234 -0
  46. package/dist/skills/github/scripts/src/env.ts +100 -0
  47. package/dist/skills/github/scripts/src/errors.ts +79 -0
  48. package/dist/skills/github/scripts/src/fields.ts +27 -0
  49. package/dist/skills/github/scripts/src/gist-shape.ts +58 -0
  50. package/dist/skills/github/scripts/src/gists-write.ts +130 -0
  51. package/dist/skills/github/scripts/src/gists.ts +118 -0
  52. package/dist/skills/github/scripts/src/git-auth.ts +46 -0
  53. package/dist/skills/github/scripts/src/http.ts +159 -0
  54. package/dist/skills/github/scripts/src/issue-develop.ts +118 -0
  55. package/dist/skills/github/scripts/src/issues-extra.ts +135 -0
  56. package/dist/skills/github/scripts/src/issues-write.ts +174 -0
  57. package/dist/skills/github/scripts/src/issues.ts +156 -0
  58. package/dist/skills/github/scripts/src/keys.ts +176 -0
  59. package/dist/skills/github/scripts/src/labels.ts +209 -0
  60. package/dist/skills/github/scripts/src/merge.ts +115 -0
  61. package/dist/skills/github/scripts/src/poly1305.ts +22 -0
  62. package/dist/skills/github/scripts/src/pr-checkout.ts +92 -0
  63. package/dist/skills/github/scripts/src/pr-view.ts +106 -0
  64. package/dist/skills/github/scripts/src/project-fields.ts +144 -0
  65. package/dist/skills/github/scripts/src/project-item-edit.ts +153 -0
  66. package/dist/skills/github/scripts/src/project-items.ts +191 -0
  67. package/dist/skills/github/scripts/src/project-links.ts +104 -0
  68. package/dist/skills/github/scripts/src/project-ref.ts +145 -0
  69. package/dist/skills/github/scripts/src/project-state.ts +99 -0
  70. package/dist/skills/github/scripts/src/projects.ts +158 -0
  71. package/dist/skills/github/scripts/src/pulls-extra.ts +165 -0
  72. package/dist/skills/github/scripts/src/pulls-read.ts +176 -0
  73. package/dist/skills/github/scripts/src/pulls-review.ts +206 -0
  74. package/dist/skills/github/scripts/src/pulls-write.ts +187 -0
  75. package/dist/skills/github/scripts/src/raw.ts +78 -0
  76. package/dist/skills/github/scripts/src/read.ts +77 -0
  77. package/dist/skills/github/scripts/src/release-assets.ts +111 -0
  78. package/dist/skills/github/scripts/src/release-download.ts +151 -0
  79. package/dist/skills/github/scripts/src/release-write.ts +197 -0
  80. package/dist/skills/github/scripts/src/repo-admin.ts +112 -0
  81. package/dist/skills/github/scripts/src/repo-content.ts +187 -0
  82. package/dist/skills/github/scripts/src/repo-create.ts +139 -0
  83. package/dist/skills/github/scripts/src/repo-extras.ts +217 -0
  84. package/dist/skills/github/scripts/src/repo-list.ts +143 -0
  85. package/dist/skills/github/scripts/src/repo-settings.ts +176 -0
  86. package/dist/skills/github/scripts/src/repo-sync.ts +81 -0
  87. package/dist/skills/github/scripts/src/repo-url.ts +104 -0
  88. package/dist/skills/github/scripts/src/repos.ts +87 -0
  89. package/dist/skills/github/scripts/src/ruleset-shape.ts +96 -0
  90. package/dist/skills/github/scripts/src/rulesets-write.ts +124 -0
  91. package/dist/skills/github/scripts/src/rulesets.ts +80 -0
  92. package/dist/skills/github/scripts/src/run-download.ts +88 -0
  93. package/dist/skills/github/scripts/src/salsa20.ts +97 -0
  94. package/dist/skills/github/scripts/src/scopes.ts +165 -0
  95. package/dist/skills/github/scripts/src/sealed-box.ts +75 -0
  96. package/dist/skills/github/scripts/src/search-commits.ts +114 -0
  97. package/dist/skills/github/scripts/src/search.ts +116 -0
  98. package/dist/skills/github/scripts/src/secrets.ts +131 -0
  99. package/dist/skills/github/scripts/src/snappy.ts +57 -0
  100. package/dist/skills/github/scripts/src/status-search.ts +55 -0
  101. package/dist/skills/github/scripts/src/transfer.ts +97 -0
  102. package/dist/skills/github/scripts/src/types.ts +75 -0
  103. package/dist/skills/github/scripts/src/variables.ts +86 -0
  104. package/dist/skills/github/scripts/src/wait.ts +164 -0
  105. package/dist/skills/github/scripts/src/wire.ts +159 -0
  106. package/dist/skills/github/scripts/src/workflows.ts +144 -0
  107. package/dist/skills/github/scripts/src/zip.ts +104 -0
  108. package/dist/skills/github/scripts/surface.ts +106 -0
  109. package/dist/skills/github/scripts/vendor/surface/SOURCE.json +15 -0
  110. package/dist/skills/github/scripts/vendor/surface/cli.ts +203 -0
  111. package/dist/skills/github/scripts/vendor/surface/flags.ts +195 -0
  112. package/dist/skills/github/scripts/vendor/surface/help.ts +89 -0
  113. package/dist/skills/github/scripts/vendor/surface/http.ts +180 -0
  114. package/dist/skills/github/scripts/vendor/surface/index.ts +44 -0
  115. package/dist/skills/github/scripts/vendor/surface/mcp.ts +241 -0
  116. package/dist/skills/github/scripts/vendor/surface/schema.ts +200 -0
  117. package/dist/skills/github/scripts/vendor/surface/stdio.ts +54 -0
  118. package/dist/skills/github/scripts/vendor/surface/surface.ts +250 -0
  119. package/dist/skills/github/scripts/vendor/surface/tools.ts +80 -0
  120. package/dist/skills/programming/SKILL.md +1 -1
  121. package/dist/skills/ulw-execute/SKILL.md +1 -1
  122. package/dist/tui.js +30 -27
  123. package/package.json +28 -26
  124. package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
  125. package/packages/omo-codex/plugin/components/bootstrap/hooks/hooks.json +1 -1
  126. package/packages/omo-codex/plugin/components/bootstrap/package.json +1 -1
  127. package/packages/omo-codex/plugin/components/comment-checker/hooks/hooks.json +1 -1
  128. package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
  129. package/packages/omo-codex/plugin/components/git-bash/hooks/hooks.json +2 -2
  130. package/packages/omo-codex/plugin/components/git-bash/package.json +1 -1
  131. package/packages/omo-codex/plugin/components/lazycodex-executor-verify/hooks/hooks.json +1 -1
  132. package/packages/omo-codex/plugin/components/lazycodex-executor-verify/package.json +1 -1
  133. package/packages/omo-codex/plugin/components/lsp/dist/.omo-runtime-manifest.json +2 -2
  134. package/packages/omo-codex/plugin/components/lsp/hooks/hooks.json +2 -2
  135. package/packages/omo-codex/plugin/components/lsp/package.json +1 -1
  136. package/packages/omo-codex/plugin/components/rules/hooks/hooks.json +4 -4
  137. package/packages/omo-codex/plugin/components/rules/package.json +1 -1
  138. package/packages/omo-codex/plugin/components/teammode/hooks/hooks.json +1 -1
  139. package/packages/omo-codex/plugin/components/teammode/package.json +1 -1
  140. package/packages/omo-codex/plugin/components/telemetry/hooks/hooks.json +1 -1
  141. package/packages/omo-codex/plugin/components/telemetry/package.json +1 -1
  142. package/packages/omo-codex/plugin/components/ultrawork/hooks/hooks.json +1 -1
  143. package/packages/omo-codex/plugin/components/ultrawork/package.json +1 -1
  144. package/packages/omo-codex/plugin/components/ulw-execute-continuation/hooks/hooks.json +1 -1
  145. package/packages/omo-codex/plugin/components/ulw-execute-continuation/package.json +1 -1
  146. package/packages/omo-codex/plugin/components/ulw-loop/hooks/hooks.json +5 -5
  147. package/packages/omo-codex/plugin/components/ulw-loop/package.json +1 -1
  148. package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/SKILL.md +1 -1
  149. package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/references/full-workflow.md +3 -3
  150. package/packages/omo-codex/plugin/hooks/post-compact-resetting-git-bash-mcp-reminder.json +1 -1
  151. package/packages/omo-codex/plugin/hooks/post-compact-resetting-lsp-diagnostics-cache.json +1 -1
  152. package/packages/omo-codex/plugin/hooks/post-compact-resetting-project-rule-cache.json +1 -1
  153. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-comments.json +1 -1
  154. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-lsp-diagnostics.json +1 -1
  155. package/packages/omo-codex/plugin/hooks/post-tool-use-checking-thread-title-hygiene.json +1 -1
  156. package/packages/omo-codex/plugin/hooks/post-tool-use-matching-project-rules.json +1 -1
  157. package/packages/omo-codex/plugin/hooks/post-tool-use-recording-spawn-admission.json +1 -1
  158. package/packages/omo-codex/plugin/hooks/pre-tool-use-enforcing-unlimited-goal-budget.json +1 -1
  159. package/packages/omo-codex/plugin/hooks/pre-tool-use-guarding-ulw-loop-spawns.json +1 -1
  160. package/packages/omo-codex/plugin/hooks/pre-tool-use-recommending-git-bash-mcp.json +1 -1
  161. package/packages/omo-codex/plugin/hooks/session-start-checking-auto-update.json +1 -1
  162. package/packages/omo-codex/plugin/hooks/session-start-checking-bootstrap-provisioning.json +1 -1
  163. package/packages/omo-codex/plugin/hooks/session-start-loading-project-rules.json +1 -1
  164. package/packages/omo-codex/plugin/hooks/session-start-recording-session-telemetry.json +1 -1
  165. package/packages/omo-codex/plugin/hooks/stop-checking-ulw-execute-continuation.json +1 -1
  166. package/packages/omo-codex/plugin/hooks/stop-checking-ulw-loop-resume.json +1 -1
  167. package/packages/omo-codex/plugin/hooks/subagent-stop-verifying-lazycodex-executor-evidence.json +1 -1
  168. package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ultrawork-trigger.json +1 -1
  169. package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ulw-loop-steering.json +1 -1
  170. package/packages/omo-codex/plugin/hooks/user-prompt-submit-loading-project-rules.json +1 -1
  171. package/packages/omo-codex/plugin/package-lock.json +12 -12
  172. package/packages/omo-codex/plugin/package.json +1 -1
  173. package/packages/omo-codex/plugin/skills/browser/SKILL.md +4 -1
  174. package/packages/omo-codex/plugin/skills/browser/references/commands.md +5 -2
  175. package/packages/omo-codex/plugin/skills/browser/references/desktop.md +1 -0
  176. package/packages/omo-codex/plugin/skills/browser/references/owned-engine/README.md +2 -0
  177. package/packages/omo-codex/plugin/skills/browser/references/owned-engine/frames-and-humans.md +2 -0
  178. package/packages/omo-codex/plugin/skills/browser/references/owned-engine/network.md +10 -5
  179. package/packages/omo-codex/plugin/skills/browser/references/recipes/1password.md +2 -0
  180. package/packages/omo-codex/plugin/skills/browser/runtime/omowright/index.js +11 -11
  181. package/packages/omo-codex/plugin/skills/browser/runtime/omowright/manifest.json +4 -4
  182. package/packages/omo-codex/plugin/skills/debugging/SKILL.md +1 -1
  183. package/packages/omo-codex/plugin/skills/git/SKILL.md +62 -0
  184. package/packages/omo-codex/plugin/skills/git/agents/openai.yaml +13 -0
  185. package/packages/omo-codex/plugin/skills/github/SKILL.md +94 -0
  186. package/packages/omo-codex/plugin/skills/github/agents/openai.yaml +2 -0
  187. package/packages/omo-codex/plugin/skills/github/references/branch-rules.md +129 -0
  188. package/packages/omo-codex/plugin/skills/github/references/evidence-attachments.md +16 -0
  189. package/packages/omo-codex/plugin/skills/github/references/repo-setup.md +152 -0
  190. package/packages/omo-codex/plugin/skills/github/references/waiting.md +52 -0
  191. package/packages/omo-codex/plugin/skills/github/references/workflows.md +161 -0
  192. package/packages/omo-codex/plugin/skills/github/scripts/cli.ts +8 -0
  193. package/packages/omo-codex/plugin/skills/github/scripts/package.json +12 -0
  194. package/packages/omo-codex/plugin/skills/github/scripts/sdk.ts +11 -0
  195. package/packages/omo-codex/plugin/skills/github/scripts/src/account.ts +243 -0
  196. package/packages/omo-codex/plugin/skills/github/scripts/src/actions-write.ts +86 -0
  197. package/packages/omo-codex/plugin/skills/github/scripts/src/actions.ts +210 -0
  198. package/packages/omo-codex/plugin/skills/github/scripts/src/attestations.ts +136 -0
  199. package/packages/omo-codex/plugin/skills/github/scripts/src/blake2b.ts +102 -0
  200. package/packages/omo-codex/plugin/skills/github/scripts/src/branch-protection.ts +192 -0
  201. package/packages/omo-codex/plugin/skills/github/scripts/src/caches.ts +105 -0
  202. package/packages/omo-codex/plugin/skills/github/scripts/src/checks.ts +107 -0
  203. package/packages/omo-codex/plugin/skills/github/scripts/src/codespaces.ts +230 -0
  204. package/packages/omo-codex/plugin/skills/github/scripts/src/conversation-lock.ts +50 -0
  205. package/packages/omo-codex/plugin/skills/github/scripts/src/discussion-list.ts +126 -0
  206. package/packages/omo-codex/plugin/skills/github/scripts/src/discussion-lookup.ts +127 -0
  207. package/packages/omo-codex/plugin/skills/github/scripts/src/discussions.ts +234 -0
  208. package/packages/omo-codex/plugin/skills/github/scripts/src/env.ts +100 -0
  209. package/packages/omo-codex/plugin/skills/github/scripts/src/errors.ts +79 -0
  210. package/packages/omo-codex/plugin/skills/github/scripts/src/fields.ts +27 -0
  211. package/packages/omo-codex/plugin/skills/github/scripts/src/gist-shape.ts +58 -0
  212. package/packages/omo-codex/plugin/skills/github/scripts/src/gists-write.ts +130 -0
  213. package/packages/omo-codex/plugin/skills/github/scripts/src/gists.ts +118 -0
  214. package/packages/omo-codex/plugin/skills/github/scripts/src/git-auth.ts +46 -0
  215. package/packages/omo-codex/plugin/skills/github/scripts/src/http.ts +159 -0
  216. package/packages/omo-codex/plugin/skills/github/scripts/src/issue-develop.ts +118 -0
  217. package/packages/omo-codex/plugin/skills/github/scripts/src/issues-extra.ts +135 -0
  218. package/packages/omo-codex/plugin/skills/github/scripts/src/issues-write.ts +174 -0
  219. package/packages/omo-codex/plugin/skills/github/scripts/src/issues.ts +156 -0
  220. package/packages/omo-codex/plugin/skills/github/scripts/src/keys.ts +176 -0
  221. package/packages/omo-codex/plugin/skills/github/scripts/src/labels.ts +209 -0
  222. package/packages/omo-codex/plugin/skills/github/scripts/src/merge.ts +115 -0
  223. package/packages/omo-codex/plugin/skills/github/scripts/src/poly1305.ts +22 -0
  224. package/packages/omo-codex/plugin/skills/github/scripts/src/pr-checkout.ts +92 -0
  225. package/packages/omo-codex/plugin/skills/github/scripts/src/pr-view.ts +106 -0
  226. package/packages/omo-codex/plugin/skills/github/scripts/src/project-fields.ts +144 -0
  227. package/packages/omo-codex/plugin/skills/github/scripts/src/project-item-edit.ts +153 -0
  228. package/packages/omo-codex/plugin/skills/github/scripts/src/project-items.ts +191 -0
  229. package/packages/omo-codex/plugin/skills/github/scripts/src/project-links.ts +104 -0
  230. package/packages/omo-codex/plugin/skills/github/scripts/src/project-ref.ts +145 -0
  231. package/packages/omo-codex/plugin/skills/github/scripts/src/project-state.ts +99 -0
  232. package/packages/omo-codex/plugin/skills/github/scripts/src/projects.ts +158 -0
  233. package/packages/omo-codex/plugin/skills/github/scripts/src/pulls-extra.ts +165 -0
  234. package/packages/omo-codex/plugin/skills/github/scripts/src/pulls-read.ts +176 -0
  235. package/packages/omo-codex/plugin/skills/github/scripts/src/pulls-review.ts +206 -0
  236. package/packages/omo-codex/plugin/skills/github/scripts/src/pulls-write.ts +187 -0
  237. package/packages/omo-codex/plugin/skills/github/scripts/src/raw.ts +78 -0
  238. package/packages/omo-codex/plugin/skills/github/scripts/src/read.ts +77 -0
  239. package/packages/omo-codex/plugin/skills/github/scripts/src/release-assets.ts +111 -0
  240. package/packages/omo-codex/plugin/skills/github/scripts/src/release-download.ts +151 -0
  241. package/packages/omo-codex/plugin/skills/github/scripts/src/release-write.ts +197 -0
  242. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-admin.ts +112 -0
  243. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-content.ts +187 -0
  244. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-create.ts +139 -0
  245. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-extras.ts +217 -0
  246. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-list.ts +143 -0
  247. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-settings.ts +176 -0
  248. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-sync.ts +81 -0
  249. package/packages/omo-codex/plugin/skills/github/scripts/src/repo-url.ts +104 -0
  250. package/packages/omo-codex/plugin/skills/github/scripts/src/repos.ts +87 -0
  251. package/packages/omo-codex/plugin/skills/github/scripts/src/ruleset-shape.ts +96 -0
  252. package/packages/omo-codex/plugin/skills/github/scripts/src/rulesets-write.ts +124 -0
  253. package/packages/omo-codex/plugin/skills/github/scripts/src/rulesets.ts +80 -0
  254. package/packages/omo-codex/plugin/skills/github/scripts/src/run-download.ts +88 -0
  255. package/packages/omo-codex/plugin/skills/github/scripts/src/salsa20.ts +97 -0
  256. package/packages/omo-codex/plugin/skills/github/scripts/src/scopes.ts +165 -0
  257. package/packages/omo-codex/plugin/skills/github/scripts/src/sealed-box.ts +75 -0
  258. package/packages/omo-codex/plugin/skills/github/scripts/src/search-commits.ts +114 -0
  259. package/packages/omo-codex/plugin/skills/github/scripts/src/search.ts +116 -0
  260. package/packages/omo-codex/plugin/skills/github/scripts/src/secrets.ts +131 -0
  261. package/packages/omo-codex/plugin/skills/github/scripts/src/snappy.ts +57 -0
  262. package/packages/omo-codex/plugin/skills/github/scripts/src/status-search.ts +55 -0
  263. package/packages/omo-codex/plugin/skills/github/scripts/src/transfer.ts +97 -0
  264. package/packages/omo-codex/plugin/skills/github/scripts/src/types.ts +75 -0
  265. package/packages/omo-codex/plugin/skills/github/scripts/src/variables.ts +86 -0
  266. package/packages/omo-codex/plugin/skills/github/scripts/src/wait.ts +164 -0
  267. package/packages/omo-codex/plugin/skills/github/scripts/src/wire.ts +159 -0
  268. package/packages/omo-codex/plugin/skills/github/scripts/src/workflows.ts +144 -0
  269. package/packages/omo-codex/plugin/skills/github/scripts/src/zip.ts +104 -0
  270. package/packages/omo-codex/plugin/skills/github/scripts/surface.ts +106 -0
  271. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/SOURCE.json +15 -0
  272. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/cli.ts +203 -0
  273. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/flags.ts +195 -0
  274. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/help.ts +89 -0
  275. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/http.ts +180 -0
  276. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/index.ts +44 -0
  277. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/mcp.ts +241 -0
  278. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/schema.ts +200 -0
  279. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/stdio.ts +54 -0
  280. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/surface.ts +250 -0
  281. package/packages/omo-codex/plugin/skills/github/scripts/vendor/surface/tools.ts +80 -0
  282. package/packages/omo-codex/plugin/skills/programming/SKILL.md +1 -1
  283. package/packages/omo-codex/plugin/skills/ulw-execute/SKILL.md +1 -1
  284. package/packages/omo-codex/plugin/skills/ulw-loop/SKILL.md +1 -1
  285. package/packages/omo-codex/plugin/skills/ulw-loop/references/full-workflow.md +3 -3
  286. package/packages/omo-codex/plugin/test/sync-skills-codex-compatibility.test.mjs +1 -1
  287. package/packages/omo-codex/plugin/test/sync-skills-test-support.mjs +2 -1
  288. package/packages/omo-codex/plugin/test/sync-skills.test.mjs +5 -5
  289. package/packages/omo-codex/scripts/install-dist/install-local.mjs +20 -15
  290. package/packages/shared-skills/skills/browser/SKILL.md +4 -1
  291. package/packages/shared-skills/skills/browser/references/commands.md +5 -2
  292. package/packages/shared-skills/skills/browser/references/desktop.md +1 -0
  293. package/packages/shared-skills/skills/browser/references/owned-engine/README.md +2 -0
  294. package/packages/shared-skills/skills/browser/references/owned-engine/frames-and-humans.md +2 -0
  295. package/packages/shared-skills/skills/browser/references/owned-engine/network.md +10 -5
  296. package/packages/shared-skills/skills/browser/references/recipes/1password.md +2 -0
  297. package/packages/shared-skills/skills/browser/runtime/omowright/index.js +11 -11
  298. package/packages/shared-skills/skills/browser/runtime/omowright/manifest.json +4 -4
  299. package/packages/shared-skills/skills/debugging/SKILL.md +1 -1
  300. package/packages/shared-skills/skills/git/SKILL.md +62 -0
  301. package/packages/shared-skills/skills/git/agents/openai.yaml +13 -0
  302. package/packages/shared-skills/skills/github/SKILL.md +94 -0
  303. package/packages/shared-skills/skills/github/references/branch-rules.md +129 -0
  304. package/packages/shared-skills/skills/github/references/evidence-attachments.md +16 -0
  305. package/packages/shared-skills/skills/github/references/repo-setup.md +152 -0
  306. package/packages/shared-skills/skills/github/references/waiting.md +52 -0
  307. package/packages/shared-skills/skills/github/references/workflows.md +161 -0
  308. package/packages/shared-skills/skills/github/scripts/cli.ts +8 -0
  309. package/packages/shared-skills/skills/github/scripts/package.json +12 -0
  310. package/packages/shared-skills/skills/github/scripts/sdk.ts +11 -0
  311. package/packages/shared-skills/skills/github/scripts/src/account.ts +243 -0
  312. package/packages/shared-skills/skills/github/scripts/src/actions-write.ts +86 -0
  313. package/packages/shared-skills/skills/github/scripts/src/actions.ts +210 -0
  314. package/packages/shared-skills/skills/github/scripts/src/attestations.ts +136 -0
  315. package/packages/shared-skills/skills/github/scripts/src/blake2b.ts +102 -0
  316. package/packages/shared-skills/skills/github/scripts/src/branch-protection.ts +192 -0
  317. package/packages/shared-skills/skills/github/scripts/src/caches.ts +105 -0
  318. package/packages/shared-skills/skills/github/scripts/src/checks.ts +107 -0
  319. package/packages/shared-skills/skills/github/scripts/src/codespaces.ts +230 -0
  320. package/packages/shared-skills/skills/github/scripts/src/conversation-lock.ts +50 -0
  321. package/packages/shared-skills/skills/github/scripts/src/discussion-list.ts +126 -0
  322. package/packages/shared-skills/skills/github/scripts/src/discussion-lookup.ts +127 -0
  323. package/packages/shared-skills/skills/github/scripts/src/discussions.ts +234 -0
  324. package/packages/shared-skills/skills/github/scripts/src/env.ts +100 -0
  325. package/packages/shared-skills/skills/github/scripts/src/errors.ts +79 -0
  326. package/packages/shared-skills/skills/github/scripts/src/fields.ts +27 -0
  327. package/packages/shared-skills/skills/github/scripts/src/gist-shape.ts +58 -0
  328. package/packages/shared-skills/skills/github/scripts/src/gists-write.ts +130 -0
  329. package/packages/shared-skills/skills/github/scripts/src/gists.ts +118 -0
  330. package/packages/shared-skills/skills/github/scripts/src/git-auth.ts +46 -0
  331. package/packages/shared-skills/skills/github/scripts/src/http.ts +159 -0
  332. package/packages/shared-skills/skills/github/scripts/src/issue-develop.ts +118 -0
  333. package/packages/shared-skills/skills/github/scripts/src/issues-extra.ts +135 -0
  334. package/packages/shared-skills/skills/github/scripts/src/issues-write.ts +174 -0
  335. package/packages/shared-skills/skills/github/scripts/src/issues.ts +156 -0
  336. package/packages/shared-skills/skills/github/scripts/src/keys.ts +176 -0
  337. package/packages/shared-skills/skills/github/scripts/src/labels.ts +209 -0
  338. package/packages/shared-skills/skills/github/scripts/src/merge.ts +115 -0
  339. package/packages/shared-skills/skills/github/scripts/src/poly1305.ts +22 -0
  340. package/packages/shared-skills/skills/github/scripts/src/pr-checkout.ts +92 -0
  341. package/packages/shared-skills/skills/github/scripts/src/pr-view.ts +106 -0
  342. package/packages/shared-skills/skills/github/scripts/src/project-fields.ts +144 -0
  343. package/packages/shared-skills/skills/github/scripts/src/project-item-edit.ts +153 -0
  344. package/packages/shared-skills/skills/github/scripts/src/project-items.ts +191 -0
  345. package/packages/shared-skills/skills/github/scripts/src/project-links.ts +104 -0
  346. package/packages/shared-skills/skills/github/scripts/src/project-ref.ts +145 -0
  347. package/packages/shared-skills/skills/github/scripts/src/project-state.ts +99 -0
  348. package/packages/shared-skills/skills/github/scripts/src/projects.ts +158 -0
  349. package/packages/shared-skills/skills/github/scripts/src/pulls-extra.ts +165 -0
  350. package/packages/shared-skills/skills/github/scripts/src/pulls-read.ts +176 -0
  351. package/packages/shared-skills/skills/github/scripts/src/pulls-review.ts +206 -0
  352. package/packages/shared-skills/skills/github/scripts/src/pulls-write.ts +187 -0
  353. package/packages/shared-skills/skills/github/scripts/src/raw.ts +78 -0
  354. package/packages/shared-skills/skills/github/scripts/src/read.ts +77 -0
  355. package/packages/shared-skills/skills/github/scripts/src/release-assets.ts +111 -0
  356. package/packages/shared-skills/skills/github/scripts/src/release-download.ts +151 -0
  357. package/packages/shared-skills/skills/github/scripts/src/release-write.ts +197 -0
  358. package/packages/shared-skills/skills/github/scripts/src/repo-admin.ts +112 -0
  359. package/packages/shared-skills/skills/github/scripts/src/repo-content.ts +187 -0
  360. package/packages/shared-skills/skills/github/scripts/src/repo-create.ts +139 -0
  361. package/packages/shared-skills/skills/github/scripts/src/repo-extras.ts +217 -0
  362. package/packages/shared-skills/skills/github/scripts/src/repo-list.ts +143 -0
  363. package/packages/shared-skills/skills/github/scripts/src/repo-settings.ts +176 -0
  364. package/packages/shared-skills/skills/github/scripts/src/repo-sync.ts +81 -0
  365. package/packages/shared-skills/skills/github/scripts/src/repo-url.ts +104 -0
  366. package/packages/shared-skills/skills/github/scripts/src/repos.ts +87 -0
  367. package/packages/shared-skills/skills/github/scripts/src/ruleset-shape.ts +96 -0
  368. package/packages/shared-skills/skills/github/scripts/src/rulesets-write.ts +124 -0
  369. package/packages/shared-skills/skills/github/scripts/src/rulesets.ts +80 -0
  370. package/packages/shared-skills/skills/github/scripts/src/run-download.ts +88 -0
  371. package/packages/shared-skills/skills/github/scripts/src/salsa20.ts +97 -0
  372. package/packages/shared-skills/skills/github/scripts/src/scopes.ts +165 -0
  373. package/packages/shared-skills/skills/github/scripts/src/sealed-box.ts +75 -0
  374. package/packages/shared-skills/skills/github/scripts/src/search-commits.ts +114 -0
  375. package/packages/shared-skills/skills/github/scripts/src/search.ts +116 -0
  376. package/packages/shared-skills/skills/github/scripts/src/secrets.ts +131 -0
  377. package/packages/shared-skills/skills/github/scripts/src/snappy.ts +57 -0
  378. package/packages/shared-skills/skills/github/scripts/src/status-search.ts +55 -0
  379. package/packages/shared-skills/skills/github/scripts/src/transfer.ts +97 -0
  380. package/packages/shared-skills/skills/github/scripts/src/types.ts +75 -0
  381. package/packages/shared-skills/skills/github/scripts/src/variables.ts +86 -0
  382. package/packages/shared-skills/skills/github/scripts/src/wait.ts +164 -0
  383. package/packages/shared-skills/skills/github/scripts/src/wire.ts +159 -0
  384. package/packages/shared-skills/skills/github/scripts/src/workflows.ts +144 -0
  385. package/packages/shared-skills/skills/github/scripts/src/zip.ts +104 -0
  386. package/packages/shared-skills/skills/github/scripts/surface.ts +106 -0
  387. package/packages/shared-skills/skills/github/scripts/vendor/surface/SOURCE.json +15 -0
  388. package/packages/shared-skills/skills/github/scripts/vendor/surface/cli.ts +203 -0
  389. package/packages/shared-skills/skills/github/scripts/vendor/surface/flags.ts +195 -0
  390. package/packages/shared-skills/skills/github/scripts/vendor/surface/help.ts +89 -0
  391. package/packages/shared-skills/skills/github/scripts/vendor/surface/http.ts +180 -0
  392. package/packages/shared-skills/skills/github/scripts/vendor/surface/index.ts +44 -0
  393. package/packages/shared-skills/skills/github/scripts/vendor/surface/mcp.ts +241 -0
  394. package/packages/shared-skills/skills/github/scripts/vendor/surface/schema.ts +200 -0
  395. package/packages/shared-skills/skills/github/scripts/vendor/surface/stdio.ts +54 -0
  396. package/packages/shared-skills/skills/github/scripts/vendor/surface/surface.ts +250 -0
  397. package/packages/shared-skills/skills/github/scripts/vendor/surface/tools.ts +80 -0
  398. package/packages/shared-skills/skills/programming/SKILL.md +1 -1
  399. package/packages/shared-skills/skills/ulw-execute/SKILL.md +1 -1
  400. package/dist/skills/git-master/SKILL.md +0 -114
  401. package/dist/skills/git-master/agents/openai.yaml +0 -13
  402. package/packages/omo-codex/plugin/skills/git-master/SKILL.md +0 -114
  403. package/packages/omo-codex/plugin/skills/git-master/agents/openai.yaml +0 -13
  404. package/packages/shared-skills/skills/git-master/SKILL.md +0 -114
  405. package/packages/shared-skills/skills/git-master/agents/openai.yaml +0 -13
@@ -2133,7 +2133,7 @@ var package_default;
2133
2133
  var init_package = __esm(() => {
2134
2134
  package_default = {
2135
2135
  name: "oh-my-opencode",
2136
- version: "5.1.84",
2136
+ version: "5.1.86",
2137
2137
  description: "The Best AI Agent Harness - Batteries-Included OpenCode Plugin with Multi-Model Orchestration, Parallel Background Agents, and Crafted LSP/AST Tools",
2138
2138
  main: "./dist/index.js",
2139
2139
  types: "dist/index.d.ts",
@@ -2327,8 +2327,9 @@ var init_package = __esm(() => {
2327
2327
  },
2328
2328
  homepage: "https://github.com/code-yeongyu/oh-my-openagent#readme",
2329
2329
  dependencies: {
2330
- "@opentui/solid": "^0.5.11",
2330
+ "@opentui/solid": "^0.9.9",
2331
2331
  "detect-libc": "^2.1.2",
2332
+ "solid-js": "^1.9.20",
2332
2333
  zod: "^4.6.6"
2333
2334
  },
2334
2335
  devDependencies: {
@@ -2338,11 +2339,10 @@ var init_package = __esm(() => {
2338
2339
  "@oh-my-opencode/agents-md-core": "workspace:*",
2339
2340
  "@oh-my-opencode/ast-grep-mcp": "workspace:*",
2340
2341
  "@oh-my-opencode/boulder-state": "workspace:*",
2341
- "@oh-my-opencode/device-service-core": "workspace:*",
2342
2342
  "@oh-my-opencode/claude-code-compat-core": "workspace:*",
2343
2343
  "@oh-my-opencode/comment-checker-core": "workspace:*",
2344
2344
  "@oh-my-opencode/delegate-core": "workspace:*",
2345
- "@oh-my-opencode/thread-address-core": "workspace:*",
2345
+ "@oh-my-opencode/device-service-core": "workspace:*",
2346
2346
  "@oh-my-opencode/git-bash-mcp": "workspace:*",
2347
2347
  "@oh-my-opencode/hashline-core": "workspace:*",
2348
2348
  "@oh-my-opencode/isolation-core": "workspace:*",
@@ -2352,6 +2352,13 @@ var init_package = __esm(() => {
2352
2352
  "@oh-my-opencode/memory-core": "workspace:*",
2353
2353
  "@oh-my-opencode/model-core": "workspace:*",
2354
2354
  "@oh-my-opencode/omo-codex": "workspace:*",
2355
+ "@oh-my-opencode/omo-computer-carriers": "workspace:*",
2356
+ "@oh-my-opencode/omo-computer-engine": "workspace:*",
2357
+ "@oh-my-opencode/omo-computer-hand": "workspace:*",
2358
+ "@oh-my-opencode/omo-computer-prelude": "workspace:*",
2359
+ "@oh-my-opencode/omo-computer-protocol": "workspace:*",
2360
+ "@oh-my-opencode/omo-computer-sdk": "workspace:*",
2361
+ "@oh-my-opencode/omo-computer-tool": "workspace:*",
2355
2362
  "@oh-my-opencode/omo-config-core": "workspace:*",
2356
2363
  "@oh-my-opencode/omo-opencode": "workspace:*",
2357
2364
  "@oh-my-opencode/omo-senpi": "workspace:*",
@@ -2364,25 +2371,19 @@ var init_package = __esm(() => {
2364
2371
  "@oh-my-opencode/senpi-desktop-sdk": "workspace:*",
2365
2372
  "@oh-my-opencode/senpi-desktop-service": "workspace:*",
2366
2373
  "@oh-my-opencode/senpi-desktop-tool": "workspace:*",
2367
- "@oh-my-opencode/omo-computer-protocol": "workspace:*",
2368
- "@oh-my-opencode/omo-computer-sdk": "workspace:*",
2369
- "@oh-my-opencode/omo-computer-engine": "workspace:*",
2370
- "@oh-my-opencode/omo-computer-hand": "workspace:*",
2371
- "@oh-my-opencode/omo-computer-carriers": "workspace:*",
2372
- "@oh-my-opencode/omo-computer-tool": "workspace:*",
2373
- "@oh-my-opencode/omo-computer-prelude": "workspace:*",
2374
2374
  "@oh-my-opencode/senpi-task": "workspace:*",
2375
2375
  "@oh-my-opencode/shared-skills": "workspace:*",
2376
2376
  "@oh-my-opencode/skills-loader-core": "workspace:*",
2377
2377
  "@oh-my-opencode/team-core": "workspace:*",
2378
2378
  "@oh-my-opencode/telemetry-core": "workspace:*",
2379
+ "@oh-my-opencode/thread-address-core": "workspace:*",
2379
2380
  "@oh-my-opencode/tmux-core": "workspace:*",
2380
2381
  "@oh-my-opencode/utils": "workspace:*",
2381
2382
  "@opencode-ai/plugin": "1.18.31",
2382
2383
  "@opencode-ai/sdk": "1.18.31",
2383
2384
  "@opencode/plugin": "2.0.32",
2384
- "@opentui/core": "^0.5.11",
2385
- "@opentui/keymap": "^0.5.11",
2385
+ "@opentui/core": "^0.9.9",
2386
+ "@opentui/keymap": "^0.9.9",
2386
2387
  "@types/js-yaml": "^4.0.9",
2387
2388
  "@types/node": "26.6.2",
2388
2389
  "@types/picomatch": "^4.0.3",
@@ -2396,8 +2397,9 @@ var init_package = __esm(() => {
2396
2397
  "js-yaml": "^5.4.2",
2397
2398
  "jsonc-parser": "^3.3.1",
2398
2399
  knip: "6.43.0",
2400
+ "libsodium-wrappers": "^0.8.4",
2399
2401
  "node-pty": "^1.1.0",
2400
- omowright: "^0.3.4",
2402
+ omowright: "^0.3.10",
2401
2403
  "oxc-parser": "0.148.0",
2402
2404
  oxlint: "1.89.0",
2403
2405
  picocolors: "^1.1.1",
@@ -2407,18 +2409,18 @@ var init_package = __esm(() => {
2407
2409
  typescript: "^7.0.2"
2408
2410
  },
2409
2411
  optionalDependencies: {
2410
- "oh-my-opencode-darwin-arm64": "5.1.84",
2411
- "oh-my-opencode-darwin-x64": "5.1.84",
2412
- "oh-my-opencode-darwin-x64-baseline": "5.1.84",
2413
- "oh-my-opencode-linux-arm64": "5.1.84",
2414
- "oh-my-opencode-linux-arm64-musl": "5.1.84",
2415
- "oh-my-opencode-linux-x64": "5.1.84",
2416
- "oh-my-opencode-linux-x64-baseline": "5.1.84",
2417
- "oh-my-opencode-linux-x64-musl": "5.1.84",
2418
- "oh-my-opencode-linux-x64-musl-baseline": "5.1.84",
2419
- "oh-my-opencode-windows-arm64": "5.1.84",
2420
- "oh-my-opencode-windows-x64": "5.1.84",
2421
- "oh-my-opencode-windows-x64-baseline": "5.1.84"
2412
+ "oh-my-opencode-darwin-arm64": "5.1.86",
2413
+ "oh-my-opencode-darwin-x64": "5.1.86",
2414
+ "oh-my-opencode-darwin-x64-baseline": "5.1.86",
2415
+ "oh-my-opencode-linux-arm64": "5.1.86",
2416
+ "oh-my-opencode-linux-arm64-musl": "5.1.86",
2417
+ "oh-my-opencode-linux-x64": "5.1.86",
2418
+ "oh-my-opencode-linux-x64-baseline": "5.1.86",
2419
+ "oh-my-opencode-linux-x64-musl": "5.1.86",
2420
+ "oh-my-opencode-linux-x64-musl-baseline": "5.1.86",
2421
+ "oh-my-opencode-windows-arm64": "5.1.86",
2422
+ "oh-my-opencode-windows-x64": "5.1.86",
2423
+ "oh-my-opencode-windows-x64-baseline": "5.1.86"
2422
2424
  },
2423
2425
  overrides: {
2424
2426
  hono: "^4.13.8",
@@ -93065,7 +93067,7 @@ var package_default2;
93065
93067
  var init_package2 = __esm(() => {
93066
93068
  package_default2 = {
93067
93069
  name: "@oh-my-opencode/omo-codex",
93068
- version: "5.1.84",
93070
+ version: "5.1.86",
93069
93071
  type: "module",
93070
93072
  private: true,
93071
93073
  description: "Codex harness adapter for oh-my-openagent. Vendored Codex plugin namespace (omo) + TypeScript installer + telemetry.",
@@ -94314,6 +94316,29 @@ var init_auto_update_checker = __esm(() => {
94314
94316
  init_cache();
94315
94317
  });
94316
94318
 
94319
+ // packages/device-service-core/src/local-only.ts
94320
+ function state3() {
94321
+ const holder = globalThis;
94322
+ holder[KEY2] ??= { marked: false };
94323
+ return holder[KEY2];
94324
+ }
94325
+ function refuseIfLocalOnly(site) {
94326
+ if (state3().marked)
94327
+ throw new LocalOnlyNetworkRefused(site);
94328
+ }
94329
+ var KEY2, LocalOnlyNetworkRefused;
94330
+ var init_local_only = __esm(() => {
94331
+ KEY2 = Symbol.for("omo.local-only-process.v1");
94332
+ LocalOnlyNetworkRefused = class LocalOnlyNetworkRefused extends Error {
94333
+ code = "local_only_network_refused";
94334
+ site;
94335
+ constructor(site) {
94336
+ super(`a local-only omo remote command reached the network at ${site}`);
94337
+ this.site = site;
94338
+ }
94339
+ };
94340
+ });
94341
+
94317
94342
  // packages/device-service-core/src/local-api/errors.ts
94318
94343
  var LocalApiError, protocolViolation = (detail) => {
94319
94344
  throw new LocalApiError("protocol_violation", detail);
@@ -98231,7 +98256,7 @@ var init_engine_endpoint = __esm(() => {
98231
98256
  NoPrimaryEndpointError = class NoPrimaryEndpointError extends NotSentError {
98232
98257
  constructor(device, listed) {
98233
98258
  super("unsupported", `${device} lists ${listed} engine endpoint(s) and names none as its own engine; nothing was opened`, {
98234
- action: `Start or restart omo on ${device}; if that does not help, update the device service on both devices.`
98259
+ action: `On ${device} run \`omo host ensure\`; if it answers primary_without_product_plugin, run \`omo host handoff\` once that host's sessions are idle; if it refuses, save its output and \`omo host status --json\`, stop only the primary host (\`omo host stop\`; never \`--force\`, which ends its live sessions) and ensure again; with no \`omo host\` command (omob), restart that omo; if it still names no engine, update the device service on both devices.`
98235
98260
  });
98236
98261
  }
98237
98262
  };
@@ -98433,6 +98458,616 @@ var init_device_service2 = __esm(() => {
98433
98458
  UPDATE_IN_FLIGHT = new Set(["pending", "trial"]);
98434
98459
  });
98435
98460
 
98461
+ // packages/device-service-core/src/delivery-consumer.ts
98462
+ var init_delivery_consumer = __esm(() => {
98463
+ init_client4();
98464
+ init_background_transport();
98465
+ init_device_service2();
98466
+ });
98467
+
98468
+ // packages/device-service-core/src/account-state.ts
98469
+ var init_account_state = () => {};
98470
+
98471
+ // packages/device-service-core/src/hand-device-keys.ts
98472
+ import { existsSync as existsSync65 } from "node:fs";
98473
+ var DEAD_ENDPOINT_CODES, connectFailure = (error) => {
98474
+ const detail = error instanceof Error ? error.message : String(error);
98475
+ if (error instanceof LocalApiError) {
98476
+ if (error.code === "refused" || error.code === "server_proof_invalid")
98477
+ return { cause: "refused", detail };
98478
+ if (error.code === "insecure_state_dir")
98479
+ return { cause: "unreadable", detail };
98480
+ if (error.code === "handshake_timeout" || error.code === "request_timeout")
98481
+ return { cause: "timed_out", detail };
98482
+ return { cause: "failed", detail };
98483
+ }
98484
+ const code = error instanceof Error && "code" in error ? String(error.code) : "";
98485
+ return { cause: DEAD_ENDPOINT_CODES.has(code) ? "dead_endpoint" : "failed", detail };
98486
+ }, connectOrNotRunning = async (connect, log) => {
98487
+ try {
98488
+ return await connect();
98489
+ } catch (error) {
98490
+ const { cause, detail } = connectFailure(error);
98491
+ log?.(`OmO device service: ${cause}, treated as not running (${detail}).`);
98492
+ return "not_running";
98493
+ }
98494
+ }, adopted = (status) => status.device !== null && status.state !== "sign_in_required", handDeviceKeys = async (options) => {
98495
+ if (!existsSync65(deviceServiceEndpointPath(options.stateDir)))
98496
+ return "not_running";
98497
+ const service = await connectOrNotRunning(options.connect, options.log);
98498
+ if (service === "not_running")
98499
+ return "not_running";
98500
+ try {
98501
+ if (options.when === "not_adopted" && adopted(await service.status()))
98502
+ return "already_adopted";
98503
+ await service.adopt(options.credential);
98504
+ return "adopted";
98505
+ } finally {
98506
+ service.close();
98507
+ }
98508
+ };
98509
+ var init_hand_device_keys = __esm(() => {
98510
+ init_device_service2();
98511
+ DEAD_ENDPOINT_CODES = new Set(["ENOENT", "ECONNREFUSED", "ECONNRESET", "EPIPE"]);
98512
+ });
98513
+
98514
+ // packages/device-service-core/src/bootstrap.ts
98515
+ import { existsSync as existsSync66 } from "node:fs";
98516
+ var forgetDeviceService = async (options) => {
98517
+ if (!existsSync66(deviceServiceEndpointPath(options.stateDir)))
98518
+ return "not_running";
98519
+ const service = await connectOrNotRunning(options.connect, options.log);
98520
+ if (service === "not_running")
98521
+ return "not_running";
98522
+ try {
98523
+ await service.forget();
98524
+ } finally {
98525
+ service.close();
98526
+ }
98527
+ return "forgotten";
98528
+ };
98529
+ var init_bootstrap = __esm(() => {
98530
+ init_account_state();
98531
+ init_device_service2();
98532
+ init_hand_device_keys();
98533
+ init_version2();
98534
+ });
98535
+
98536
+ // packages/device-service-core/src/cold-wake/host.ts
98537
+ var UNREPAIRABLE;
98538
+ var init_host = __esm(() => {
98539
+ UNREPAIRABLE = new Set(["EPERM", "EACCES", "EROFS"]);
98540
+ });
98541
+
98542
+ // packages/device-service-core/src/cold-wake/pinned-host.ts
98543
+ var init_pinned_host = __esm(() => {
98544
+ init_host();
98545
+ });
98546
+
98547
+ // packages/device-service-core/src/cold-wake/session-host-unit.ts
98548
+ var init_session_host_unit = () => {};
98549
+
98550
+ // packages/device-service-core/src/cold-wake/service-table.ts
98551
+ var SERVICE_TABLE_ENV = "OMO_RELAYD_SERVICES";
98552
+ var init_service_table = __esm(() => {
98553
+ init_session_host_unit();
98554
+ });
98555
+
98556
+ // packages/device-service-core/src/cold-wake/darwin.ts
98557
+ var TABLE_KEY;
98558
+ var init_darwin = __esm(() => {
98559
+ init_host();
98560
+ init_pinned_host();
98561
+ init_service_table();
98562
+ init_session_host_unit();
98563
+ TABLE_KEY = `EnvironmentVariables.${SERVICE_TABLE_ENV}`;
98564
+ });
98565
+
98566
+ // packages/device-service-core/src/cold-wake/linux.ts
98567
+ var init_linux = __esm(() => {
98568
+ init_host();
98569
+ init_pinned_host();
98570
+ init_service_table();
98571
+ init_session_host_unit();
98572
+ });
98573
+
98574
+ // packages/device-service-core/src/cold-wake/readback.ts
98575
+ var init_readback = __esm(() => {
98576
+ init_linux();
98577
+ init_pinned_host();
98578
+ init_service_table();
98579
+ init_session_host_unit();
98580
+ });
98581
+
98582
+ // packages/device-service-core/src/cold-wake/installed-unit.ts
98583
+ var init_installed_unit = () => {};
98584
+
98585
+ // packages/device-service-core/src/cold-wake/refresh.ts
98586
+ var init_refresh = __esm(() => {
98587
+ init_darwin();
98588
+ init_host();
98589
+ init_installed_unit();
98590
+ init_linux();
98591
+ init_session_host_unit();
98592
+ });
98593
+
98594
+ // packages/device-service-core/src/cold-wake/index.ts
98595
+ var init_cold_wake = __esm(() => {
98596
+ init_darwin();
98597
+ init_linux();
98598
+ init_readback();
98599
+ init_refresh();
98600
+ init_session_host_unit();
98601
+ });
98602
+
98603
+ // packages/device-service-core/src/release/windows-dacl.ts
98604
+ var SID_TOKEN_SCRIPT, userSidToken = async (userSid, run = runPowerShell) => {
98605
+ const { code, out } = await run(SID_TOKEN_SCRIPT, { LA_SID: userSid });
98606
+ const match = code === 0 ? /^O:(S-1-\d+(?:-\d+)+|[A-Z]{2})$/.exec(out.trim()) : null;
98607
+ return match?.[1];
98608
+ }, aliasedDaclVerdict = (dacl, userSid, kind, userAlias) => {
98609
+ const asSid = (token) => userAlias !== undefined && token === userAlias ? userSid : token;
98610
+ return exactDaclVerdict({ ...dacl, owner: asSid(dacl.owner), aces: dacl.aces.map((ace) => ({ ...ace, sid: asSid(ace.sid) })) }, userSid, kind);
98611
+ }, verifyExactDacl2 = async (path, userSid, kind, run = runPowerShell) => {
98612
+ let dacl;
98613
+ try {
98614
+ dacl = await describeDacl(path, run);
98615
+ } catch (error) {
98616
+ if (error instanceof LocalApiError)
98617
+ return false;
98618
+ throw error;
98619
+ }
98620
+ return aliasedDaclVerdict(dacl, userSid, kind, await userSidToken(userSid, run));
98621
+ }, windowsSecureFile2 = (userSid, run = runPowerShell) => async (path, kind) => {
98622
+ const target = kind === "dir" ? "dir" : "file";
98623
+ await applyExactDacl(path, userSid, target, run);
98624
+ if (!await verifyExactDacl2(path, userSid, target, run))
98625
+ throw new LocalApiError("insecure_state_dir", "the DACL is not exactly one ACE for the user");
98626
+ };
98627
+ var init_windows_dacl = __esm(() => {
98628
+ init_errors4();
98629
+ init_dacl();
98630
+ SID_TOKEN_SCRIPT = String.raw`
98631
+ $ErrorActionPreference = 'Stop'
98632
+ (New-Object System.Security.AccessControl.RawSecurityDescriptor("O:$env:LA_SID")).GetSddlForm('Owner')
98633
+ `;
98634
+ });
98635
+
98636
+ // packages/device-service-core/src/release/release-assets.ts
98637
+ var MANIFEST = "latest.json", CHECKSUMS_MAX_BYTES, MANIFEST_MAX_BYTES, BINARY_MAX_BYTES, DEVICE_SERVICE_HOSTS, deviceServiceAssetName = (host) => host.startsWith("windows-") ? `omo-device-service-${host}.exe` : `omo-device-service-${host}`, RELEASE_FILES;
98638
+ var init_release_assets = __esm(() => {
98639
+ init_version2();
98640
+ CHECKSUMS_MAX_BYTES = 64 * 1024;
98641
+ MANIFEST_MAX_BYTES = 4 * 1024;
98642
+ BINARY_MAX_BYTES = 512 * 1024 * 1024;
98643
+ DEVICE_SERVICE_HOSTS = [
98644
+ "darwin-arm64",
98645
+ "darwin-x64",
98646
+ "linux-x64",
98647
+ "linux-arm64",
98648
+ "windows-x64",
98649
+ "windows-arm64"
98650
+ ];
98651
+ RELEASE_FILES = new Set([MANIFEST, ...DEVICE_SERVICE_HOSTS.map(deviceServiceAssetName)]);
98652
+ });
98653
+
98654
+ // packages/device-service-core/src/strict-ed25519/strict-ed25519.ts
98655
+ var P, L, mod = (n) => {
98656
+ const r = n % P;
98657
+ return r < 0n ? r + P : r;
98658
+ }, power = (base, exponent) => {
98659
+ let result = 1n;
98660
+ let b = mod(base);
98661
+ for (let n = exponent;n > 0n; n >>= 1n) {
98662
+ if (n & 1n)
98663
+ result = mod(result * b);
98664
+ b = mod(b * b);
98665
+ }
98666
+ return result;
98667
+ }, D, SQRT_MINUS_ONE, keyCache;
98668
+ var init_strict_ed25519 = __esm(() => {
98669
+ P = (1n << 255n) - 19n;
98670
+ L = (1n << 252n) + 27742317777372353535851937790883648493n;
98671
+ D = mod(-121665n * power(121666n, P - 2n));
98672
+ SQRT_MINUS_ONE = power(2n, (P - 1n) / 4n);
98673
+ keyCache = new Map;
98674
+ });
98675
+
98676
+ // packages/device-service-core/src/release/release-key.json
98677
+ var release_key_default;
98678
+ var init_release_key = __esm(() => {
98679
+ release_key_default = {
98680
+ alg: "Ed25519",
98681
+ public_keys_hex: ["6c6781a91888e3e5be10d1b27466319a7d5adf2a7d2b254f4118eda9cbcb4465", "ca9407b484a30ac7f09cb152455176f1e03fc6ca3446ff930bc7587215759016"]
98682
+ };
98683
+ });
98684
+
98685
+ // packages/device-service-core/src/release/release-signature.ts
98686
+ var HEX_KEY, parseReleaseKeySet = (value) => {
98687
+ if (typeof value !== "object" || value === null || Array.isArray(value))
98688
+ throw new Error("release key: not an object");
98689
+ if (Object.keys(value).toSorted().join(",") !== "alg,public_keys_hex")
98690
+ throw new Error("release key: fields must be exactly alg and public_keys_hex");
98691
+ const alg = Reflect.get(value, "alg");
98692
+ const hexes = Reflect.get(value, "public_keys_hex");
98693
+ if (alg !== "Ed25519")
98694
+ throw new Error("release key: alg must be Ed25519");
98695
+ if (!Array.isArray(hexes))
98696
+ throw new Error("release key: public_keys_hex must be an array");
98697
+ if (new Set(hexes).size !== hexes.length)
98698
+ throw new Error("release key: public_keys_hex must not repeat a key");
98699
+ return hexes.map((hex) => {
98700
+ if (typeof hex !== "string" || !HEX_KEY.test(hex))
98701
+ throw new Error("release key: each public_keys_hex entry must be 64 lowercase hex characters");
98702
+ return hex;
98703
+ });
98704
+ }, DEVICE_SERVICE_RELEASE_KEYS;
98705
+ var init_release_signature = __esm(() => {
98706
+ init_strict_ed25519();
98707
+ init_release_key();
98708
+ HEX_KEY = /^[0-9a-f]{64}$/;
98709
+ DEVICE_SERVICE_RELEASE_KEYS = parseReleaseKeySet(release_key_default);
98710
+ });
98711
+
98712
+ // packages/device-service-core/src/release/acquire.ts
98713
+ var platformSecure;
98714
+ var init_acquire = __esm(() => {
98715
+ init_access();
98716
+ init_local_only();
98717
+ init_dacl();
98718
+ init_windows_dacl();
98719
+ init_release_assets();
98720
+ init_release_signature();
98721
+ init_version2();
98722
+ init_release_assets();
98723
+ init_release_signature();
98724
+ platformSecure = process.platform === "win32" ? async (path, kind, origin) => windowsSecureFile2(await currentUserSid())(path, kind, origin) : posixSecureFile;
98725
+ });
98726
+
98727
+ // packages/device-service-core/src/install.ts
98728
+ var init_install = __esm(() => {
98729
+ init_acquire();
98730
+ });
98731
+ // packages/device-service-core/src/registrant-watch.ts
98732
+ var init_registrant_watch = () => {};
98733
+
98734
+ // packages/device-service-core/src/registrant.ts
98735
+ var NONE2;
98736
+ var init_registrant = __esm(() => {
98737
+ init_device_service2();
98738
+ init_registrant_watch();
98739
+ NONE2 = Symbol("none registered");
98740
+ });
98741
+
98742
+ // packages/device-service-core/src/index.ts
98743
+ var init_src6 = __esm(() => {
98744
+ init_delivery_consumer();
98745
+ init_account_state();
98746
+ init_bootstrap();
98747
+ init_hand_device_keys();
98748
+ init_cold_wake();
98749
+ init_install();
98750
+ init_registrant();
98751
+ init_timers();
98752
+ init_acquire();
98753
+ init_device_service2();
98754
+ });
98755
+
98756
+ // packages/device-service-core/src/wire.ts
98757
+ var init_wire = __esm(() => {
98758
+ init_errors4();
98759
+ });
98760
+
98761
+ // packages/omo-senpi/src/components/thread/errors.ts
98762
+ function isThreadErrorCode(value) {
98763
+ return typeof value === "string" && CODE_SET.has(value);
98764
+ }
98765
+ function threadToolFailure(code, message, nextAction, details) {
98766
+ if (!isThreadErrorCode(code)) {
98767
+ throw new Error(`unknown thread error code: ${String(code)}`);
98768
+ }
98769
+ return { code, message, next_action: nextAction, ...details === undefined ? {} : { details } };
98770
+ }
98771
+ var THREAD_ERROR_CODES, CODE_SET;
98772
+ var init_errors5 = __esm(() => {
98773
+ THREAD_ERROR_CODES = [
98774
+ "invalid_arguments",
98775
+ "caller_context_missing",
98776
+ "not_found",
98777
+ "reply_target_mismatch",
98778
+ "ambiguous_target",
98779
+ "scope_denied",
98780
+ "name_conflict",
98781
+ "not_resumable",
98782
+ "orphaned",
98783
+ "foreign_live_owner",
98784
+ "no_active_turn",
98785
+ "turn_conflict",
98786
+ "turn_active",
98787
+ "not_steerable",
98788
+ "message_too_large",
98789
+ "queue_full",
98790
+ "cursor_invalid",
98791
+ "cursor_stale",
98792
+ "idempotency_conflict",
98793
+ "idempotency_in_progress",
98794
+ "idempotency_uncertain",
98795
+ "delivered_unconfirmed",
98796
+ "prompt_not_started",
98797
+ "approval_unavailable",
98798
+ "approval_route_locked",
98799
+ "partial_commit",
98800
+ "unsupported",
98801
+ "overloaded",
98802
+ "transport_closed",
98803
+ "host_unavailable",
98804
+ "internal_error",
98805
+ "model_not_found",
98806
+ "model_ambiguous",
98807
+ "thinking_level_unsupported",
98808
+ "loop_detected",
98809
+ "pair_loop_guard",
98810
+ "chain_count_limit",
98811
+ "device_offline",
98812
+ "relay_requires_paid_plan",
98813
+ "alias_taken",
98814
+ "gateway_schema_too_new"
98815
+ ];
98816
+ CODE_SET = new Set(THREAD_ERROR_CODES);
98817
+ });
98818
+
98819
+ // packages/omo-senpi/src/components/remote/codes.ts
98820
+ var REMOTE_CODES, ENGINE_CODES;
98821
+ var init_codes = __esm(() => {
98822
+ init_wire();
98823
+ init_errors5();
98824
+ REMOTE_CODES = [
98825
+ ...THREAD_ERROR_CODES,
98826
+ "timeout",
98827
+ "cancelled",
98828
+ "session_ended",
98829
+ "sender_not_allowed",
98830
+ "local_only",
98831
+ "host_not_answering",
98832
+ "no_transport",
98833
+ "device_offline",
98834
+ "undelivered",
98835
+ "transport_expired",
98836
+ "unconfirmed",
98837
+ "host_error"
98838
+ ];
98839
+ ENGINE_CODES = new Map([
98840
+ ["model_unavailable", { code: "model_not_found" }],
98841
+ ["invalid_level", { code: "thinking_level_unsupported" }],
98842
+ ["worktree_failed", { code: "unsupported", details: { feature: "worktree" } }],
98843
+ ["not_running", { code: "not_resumable" }],
98844
+ ["handle_lost", { code: "not_found", details: { kind: "handle" } }]
98845
+ ]);
98846
+ });
98847
+
98848
+ // packages/omo-senpi/src/components/remote/connection-of.ts
98849
+ var lenders;
98850
+ var init_connection_of = __esm(() => {
98851
+ lenders = new WeakMap;
98852
+ });
98853
+
98854
+ // packages/omo-senpi/src/components/remote/deadlines.ts
98855
+ var init_deadlines = __esm(() => {
98856
+ init_codes();
98857
+ });
98858
+
98859
+ // packages/omo-senpi/src/components/remote/seams.ts
98860
+ var init_seams = __esm(() => {
98861
+ init_codes();
98862
+ });
98863
+
98864
+ // packages/omo-senpi/src/components/remote/resolve.ts
98865
+ var init_resolve = __esm(() => {
98866
+ init_client5();
98867
+ init_deadlines();
98868
+ init_codes();
98869
+ init_seams();
98870
+ });
98871
+
98872
+ // packages/omo-senpi/src/components/remote/aliases.ts
98873
+ var init_aliases = __esm(() => {
98874
+ init_codes();
98875
+ init_deadlines();
98876
+ init_resolve();
98877
+ init_seams();
98878
+ });
98879
+
98880
+ // packages/omo-senpi/src/components/thread/gateway/result.ts
98881
+ var init_result = __esm(() => {
98882
+ init_errors5();
98883
+ });
98884
+
98885
+ // packages/omo-senpi/src/components/thread/remote/outcome.ts
98886
+ var READ_UNCERTAIN, UNANSWERED, NOT_SIGNED_IN, ENGINE_NOT_READY;
98887
+ var init_outcome = __esm(() => {
98888
+ init_errors5();
98889
+ init_result();
98890
+ READ_UNCERTAIN = {
98891
+ request_gone: "retry",
98892
+ no_receipt: "retry",
98893
+ engine_restarted: "retry",
98894
+ recipient_revoked: "retry",
98895
+ transport_expired: "retry",
98896
+ unconfirmed: "retry",
98897
+ lease_expired: "retry",
98898
+ cancelled: "retry",
98899
+ hand_restarted: "retry",
98900
+ result_expired: "retry",
98901
+ record_too_large: "too_large",
98902
+ result_undecodable: "retry"
98903
+ };
98904
+ UNANSWERED = new Set([
98905
+ "closed",
98906
+ "protocol_violation",
98907
+ "internal",
98908
+ "read_failed",
98909
+ "request_timeout",
98910
+ "handshake_timeout",
98911
+ "attach_failed",
98912
+ "reply_lost",
98913
+ "delivered_unconfirmed",
98914
+ "host_not_answering",
98915
+ "peer_not_found",
98916
+ "engine_stale",
98917
+ ...Object.entries(READ_UNCERTAIN).filter(([, answer]) => answer === "retry").map(([reason]) => reason)
98918
+ ]);
98919
+ NOT_SIGNED_IN = new Set(["sign_in_required", "signed_out"]);
98920
+ ENGINE_NOT_READY = new Set(["attach_required", "daemon_unavailable"]);
98921
+ });
98922
+
98923
+ // packages/omo-senpi/src/components/thread/remote/attach-pool.ts
98924
+ var CATALOG_RECORD = "get_available_models", HELD_RECORDS;
98925
+ var init_attach_pool = __esm(() => {
98926
+ HELD_RECORDS = new Set([CATALOG_RECORD, "get_protocol_info"]);
98927
+ });
98928
+
98929
+ // packages/omo-senpi/src/components/thread/remote/ports.ts
98930
+ var init_ports = () => {};
98931
+
98932
+ // packages/omo-senpi/src/components/thread/remote/session-state.ts
98933
+ var ACCESS_ENDED, ACCESS_REFUSED, SESSION_LEFT, SESSION_GONE;
98934
+ var init_session_state = __esm(() => {
98935
+ ACCESS_ENDED = new Set([
98936
+ "authorization_expired",
98937
+ "peer_revoked",
98938
+ "owner_transfer",
98939
+ "service_disabled"
98940
+ ]);
98941
+ ACCESS_REFUSED = new Set([
98942
+ "unauthenticated",
98943
+ "forbidden",
98944
+ "owner_transfer",
98945
+ "signed_out",
98946
+ "service_disabled",
98947
+ "sign_in_required",
98948
+ "plan_required",
98949
+ "peer_not_found",
98950
+ "peer_not_session_client",
98951
+ "account_changed",
98952
+ "device_changed",
98953
+ "capability_missing",
98954
+ "engine_too_old"
98955
+ ]);
98956
+ SESSION_LEFT = new Set(["session_closed", "session_replaced"]);
98957
+ SESSION_GONE = new Set([
98958
+ "session_not_found",
98959
+ "unknown_session",
98960
+ "session_identity_mismatch"
98961
+ ]);
98962
+ });
98963
+ // packages/omo-senpi/src/components/thread/remote/remote-watch.ts
98964
+ var init_remote_watch = __esm(() => {
98965
+ init_device_service2();
98966
+ init_ports();
98967
+ init_session_state();
98968
+ });
98969
+
98970
+ // packages/omo-senpi/src/components/call-budget/call-deadline.ts
98971
+ import { AsyncLocalStorage as AsyncLocalStorage4 } from "node:async_hooks";
98972
+ var scope;
98973
+ var init_call_deadline = __esm(() => {
98974
+ scope = new AsyncLocalStorage4;
98975
+ });
98976
+ // packages/omo-senpi/src/components/remote/port/lookup-gate.ts
98977
+ var init_lookup_gate = __esm(() => {
98978
+ init_ports();
98979
+ });
98980
+
98981
+ // packages/omo-senpi/src/components/remote/port/device-service.ts
98982
+ var READ_ONLY_RECORDS, MARKED_RECORDS, LOOKUP_NONE;
98983
+ var init_device_service3 = __esm(() => {
98984
+ init_outcome();
98985
+ init_device_service2();
98986
+ init_attach_pool();
98987
+ init_remote_watch();
98988
+ init_call_deadline();
98989
+ init_lookup_gate();
98990
+ READ_ONLY_RECORDS = new Set([
98991
+ "get_state",
98992
+ "get_messages",
98993
+ "get_entries",
98994
+ "get_protocol_info"
98995
+ ]);
98996
+ MARKED_RECORDS = new Set(["admit_external_message"]);
98997
+ LOOKUP_NONE = new Set(["session_not_found", "peer_not_found", "peer_not_session_client"]);
98998
+ });
98999
+
99000
+ // packages/omo-senpi/src/components/remote/attach.ts
99001
+ var DIALOG_KINDS;
99002
+ var init_attach = __esm(() => {
99003
+ init_device_service2();
99004
+ init_outcome();
99005
+ init_client5();
99006
+ init_codes();
99007
+ init_deadlines();
99008
+ init_device_service3();
99009
+ init_resolve();
99010
+ init_seams();
99011
+ DIALOG_KINDS = new Set(["select", "confirm", "input", "editor", "question"]);
99012
+ });
99013
+
99014
+ // packages/omo-senpi/src/components/thread/address/refusals.ts
99015
+ var init_refusals = __esm(() => {
99016
+ init_errors5();
99017
+ });
99018
+
99019
+ // packages/omo-senpi/src/components/thread/remote/address-book.ts
99020
+ var REMOTE_NOT_SET_UP;
99021
+ var init_address_book = __esm(() => {
99022
+ init_ports();
99023
+ REMOTE_NOT_SET_UP = new Set(["not_configured", "disabled", "signed_out", "sign_in_required"]);
99024
+ });
99025
+
99026
+ // packages/omo-senpi/src/components/thread/address/account.ts
99027
+ var NOT_SET_UP, lastListed;
99028
+ var init_account = __esm(() => {
99029
+ init_remote_ops();
99030
+ init_address_book();
99031
+ NOT_SET_UP = new Set(["not_configured", "disabled", "signed_out", "sign_in_required"]);
99032
+ lastListed = new WeakMap;
99033
+ });
99034
+
99035
+ // packages/omo-senpi/src/components/thread/address/device.ts
99036
+ var init_device = __esm(() => {
99037
+ init_errors5();
99038
+ init_account();
99039
+ init_refusals();
99040
+ });
99041
+
99042
+ // packages/omo-senpi/src/components/thread/remote/remote-ops.ts
99043
+ var init_remote_ops = __esm(() => {
99044
+ init_refusals();
99045
+ init_device();
99046
+ init_account();
99047
+ init_outcome();
99048
+ });
99049
+
99050
+ // packages/omo-senpi/src/components/remote/send-transcript.ts
99051
+ var awaiting, views;
99052
+ var init_send_transcript = __esm(() => {
99053
+ init_remote_ops();
99054
+ awaiting = new WeakMap;
99055
+ views = new WeakMap;
99056
+ });
99057
+
99058
+ // packages/omo-senpi/src/components/remote/follow.ts
99059
+ var RUN_OVER;
99060
+ var init_follow = __esm(() => {
99061
+ init_outcome();
99062
+ init_attach();
99063
+ init_client5();
99064
+ init_codes();
99065
+ init_deadlines();
99066
+ init_seams();
99067
+ init_send_transcript();
99068
+ RUN_OVER = new Set(["waiting_children", "waiting_background", "done", "failed", "cancelled"]);
99069
+ });
99070
+
98436
99071
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/system/memory/metrics.mjs
98437
99072
  var Metrics;
98438
99073
  var init_metrics2 = __esm(() => {
@@ -100759,7 +101394,7 @@ function IsExtendsTrueLike(value) {
100759
101394
  function Match3(result, true_, false_) {
100760
101395
  return IsExtendsTrueLike(result) ? true_(result.inferred) : false_();
100761
101396
  }
100762
- var init_result = __esm(() => {
101397
+ var init_result2 = __esm(() => {
100763
101398
  init_guard2();
100764
101399
  init_memory3();
100765
101400
  });
@@ -100803,7 +101438,7 @@ var init_extends_right = __esm(() => {
100803
101438
  init_union();
100804
101439
  init_unknown();
100805
101440
  init_extends_left();
100806
- init_result();
101441
+ init_result2();
100807
101442
  init_evaluate2();
100808
101443
  init_evaluate2();
100809
101444
  });
@@ -100817,7 +101452,7 @@ var init_any2 = __esm(() => {
100817
101452
  init_any();
100818
101453
  init_unknown();
100819
101454
  init_extends_right();
100820
- init_result();
101455
+ init_result2();
100821
101456
  });
100822
101457
 
100823
101458
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/array.mjs
@@ -100834,7 +101469,7 @@ var init_array2 = __esm(() => {
100834
101469
  init__immutable();
100835
101470
  init_extends_right();
100836
101471
  init_extends_left();
100837
- init_result();
101472
+ init_result2();
100838
101473
  });
100839
101474
 
100840
101475
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/bigint.mjs
@@ -100844,7 +101479,7 @@ function ExtendsBigInt(inferred, left, right) {
100844
101479
  var init_bigint3 = __esm(() => {
100845
101480
  init_bigint();
100846
101481
  init_extends_right();
100847
- init_result();
101482
+ init_result2();
100848
101483
  });
100849
101484
 
100850
101485
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/boolean.mjs
@@ -100854,7 +101489,7 @@ function ExtendsBoolean(inferred, left, right) {
100854
101489
  var init_boolean2 = __esm(() => {
100855
101490
  init_boolean();
100856
101491
  init_extends_right();
100857
- init_result();
101492
+ init_result2();
100858
101493
  });
100859
101494
 
100860
101495
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/parameters.mjs
@@ -100879,7 +101514,7 @@ var init_parameters = __esm(() => {
100879
101514
  init_infer();
100880
101515
  init__optional();
100881
101516
  init_extends_left();
100882
- init_result();
101517
+ init_result2();
100883
101518
  });
100884
101519
 
100885
101520
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/return_type.mjs
@@ -100889,7 +101524,7 @@ function ExtendsReturnType(inferred, left, right) {
100889
101524
  var init_return_type = __esm(() => {
100890
101525
  init_void();
100891
101526
  init_extends_left();
100892
- init_result();
101527
+ init_result2();
100893
101528
  });
100894
101529
 
100895
101530
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/constructor.mjs
@@ -100900,7 +101535,7 @@ var init_constructor2 = __esm(() => {
100900
101535
  init_any();
100901
101536
  init_constructor();
100902
101537
  init_unknown();
100903
- init_result();
101538
+ init_result2();
100904
101539
  init_parameters();
100905
101540
  init_return_type();
100906
101541
  });
@@ -100911,7 +101546,7 @@ function ExtendsDependent(inferred, if_, then_, else_, right) {
100911
101546
  }
100912
101547
  var init_dependent2 = __esm(() => {
100913
101548
  init_extends_left();
100914
- init_result();
101549
+ init_result2();
100915
101550
  });
100916
101551
 
100917
101552
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/enum.mjs
@@ -100932,7 +101567,7 @@ var init_function2 = __esm(() => {
100932
101567
  init_any();
100933
101568
  init_function();
100934
101569
  init_unknown();
100935
- init_result();
101570
+ init_result2();
100936
101571
  init_parameters();
100937
101572
  init_return_type();
100938
101573
  });
@@ -100945,7 +101580,7 @@ var init_integer3 = __esm(() => {
100945
101580
  init_integer();
100946
101581
  init_number();
100947
101582
  init_extends_right();
100948
- init_result();
101583
+ init_result2();
100949
101584
  });
100950
101585
 
100951
101586
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/intersect.mjs
@@ -100985,7 +101620,7 @@ var init_literal2 = __esm(() => {
100985
101620
  init_number();
100986
101621
  init_string();
100987
101622
  init_extends_right();
100988
- init_result();
101623
+ init_result2();
100989
101624
  });
100990
101625
 
100991
101626
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/never.mjs
@@ -100995,7 +101630,7 @@ function ExtendsNever(inferred, left, right) {
100995
101630
  var init_never2 = __esm(() => {
100996
101631
  init_infer();
100997
101632
  init_extends_right();
100998
- init_result();
101633
+ init_result2();
100999
101634
  });
101000
101635
 
101001
101636
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/null.mjs
@@ -101005,7 +101640,7 @@ function ExtendsNull(inferred, left, right) {
101005
101640
  var init_null2 = __esm(() => {
101006
101641
  init_null();
101007
101642
  init_extends_right();
101008
- init_result();
101643
+ init_result2();
101009
101644
  });
101010
101645
 
101011
101646
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/number.mjs
@@ -101015,7 +101650,7 @@ function ExtendsNumber(inferred, left, right) {
101015
101650
  var init_number3 = __esm(() => {
101016
101651
  init_number();
101017
101652
  init_extends_right();
101018
- init_result();
101653
+ init_result2();
101019
101654
  });
101020
101655
 
101021
101656
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/object.mjs
@@ -101077,7 +101712,7 @@ var init_object2 = __esm(() => {
101077
101712
  init_union();
101078
101713
  init_extends_left();
101079
101714
  init_extends_right();
101080
- init_result();
101715
+ init_result2();
101081
101716
  });
101082
101717
 
101083
101718
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/record.mjs
@@ -101097,7 +101732,7 @@ var init_record2 = __esm(() => {
101097
101732
  init_object();
101098
101733
  init_record();
101099
101734
  init_extends_left();
101100
- init_result();
101735
+ init_result2();
101101
101736
  });
101102
101737
 
101103
101738
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/string.mjs
@@ -101107,7 +101742,7 @@ function ExtendsString(inferred, left, right) {
101107
101742
  var init_string3 = __esm(() => {
101108
101743
  init_string();
101109
101744
  init_extends_right();
101110
- init_result();
101745
+ init_result2();
101111
101746
  });
101112
101747
 
101113
101748
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/symbol.mjs
@@ -101117,7 +101752,7 @@ function ExtendsSymbol(inferred, left, right) {
101117
101752
  var init_symbol2 = __esm(() => {
101118
101753
  init_symbol();
101119
101754
  init_extends_right();
101120
- init_result();
101755
+ init_result2();
101121
101756
  });
101122
101757
 
101123
101758
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/template_literal.mjs
@@ -101171,7 +101806,7 @@ var init_inference = __esm(() => {
101171
101806
  init_union();
101172
101807
  init_infer();
101173
101808
  init_rest();
101174
- init_result();
101809
+ init_result2();
101175
101810
  });
101176
101811
 
101177
101812
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/tuple.mjs
@@ -101228,7 +101863,7 @@ var init_tuple2 = __esm(() => {
101228
101863
  init_tuple();
101229
101864
  init_extends_left();
101230
101865
  init_extends_right();
101231
- init_result();
101866
+ init_result2();
101232
101867
  init_instantiate27();
101233
101868
  init_instantiate27();
101234
101869
  init_inference();
@@ -101242,7 +101877,7 @@ var init_undefined2 = __esm(() => {
101242
101877
  init_undefined();
101243
101878
  init_void();
101244
101879
  init_extends_right();
101245
- init_result();
101880
+ init_result2();
101246
101881
  });
101247
101882
 
101248
101883
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/union.mjs
@@ -101260,7 +101895,7 @@ var init_union2 = __esm(() => {
101260
101895
  init_guard2();
101261
101896
  init_union();
101262
101897
  init_extends_left();
101263
- init_result();
101898
+ init_result2();
101264
101899
  init_inference();
101265
101900
  });
101266
101901
 
@@ -101273,7 +101908,7 @@ var init_unknown2 = __esm(() => {
101273
101908
  init_unknown();
101274
101909
  init_infer();
101275
101910
  init_extends_right();
101276
- init_result();
101911
+ init_result2();
101277
101912
  });
101278
101913
 
101279
101914
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/void.mjs
@@ -101283,7 +101918,7 @@ function ExtendsVoid(inferred, left, right) {
101283
101918
  var init_void2 = __esm(() => {
101284
101919
  init_void();
101285
101920
  init_extends_right();
101286
- init_result();
101921
+ init_result2();
101287
101922
  });
101288
101923
 
101289
101924
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/extends_left.mjs
@@ -101339,7 +101974,7 @@ var init_extends_left = __esm(() => {
101339
101974
  init_unknown();
101340
101975
  init_union();
101341
101976
  init_void();
101342
- init_result();
101977
+ init_result2();
101343
101978
  });
101344
101979
 
101345
101980
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/engine/interface/instantiate.mjs
@@ -101578,7 +102213,7 @@ var init_extends2 = __esm(() => {
101578
102213
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/extends/index.mjs
101579
102214
  var init_extends3 = __esm(() => {
101580
102215
  init_extends2();
101581
- init_result();
102216
+ init_result2();
101582
102217
  });
101583
102218
 
101584
102219
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/type/engine/evaluate/compare.mjs
@@ -103957,154 +104592,103 @@ var init_permission_presets = __esm(() => {
103957
104592
  PERMISSION_PRESETS = ["full-access", "workspace", "accept-edits", "auto", "read-only", "ask"];
103958
104593
  });
103959
104594
 
103960
- // packages/omo-senpi/src/components/thread/remote/ports.ts
103961
- var init_ports = () => {};
103962
-
103963
- // packages/omo-senpi/src/components/thread/errors.ts
103964
- function isThreadErrorCode(value) {
103965
- return typeof value === "string" && CODE_SET.has(value);
103966
- }
103967
- function threadToolFailure(code, message, nextAction, details) {
103968
- if (!isThreadErrorCode(code)) {
103969
- throw new Error(`unknown thread error code: ${String(code)}`);
103970
- }
103971
- return { code, message, next_action: nextAction, ...details === undefined ? {} : { details } };
103972
- }
103973
- var THREAD_ERROR_CODES, CODE_SET;
103974
- var init_errors5 = __esm(() => {
103975
- THREAD_ERROR_CODES = [
103976
- "invalid_arguments",
103977
- "caller_context_missing",
103978
- "not_found",
103979
- "reply_target_mismatch",
103980
- "ambiguous_target",
103981
- "scope_denied",
103982
- "name_conflict",
103983
- "not_resumable",
103984
- "orphaned",
103985
- "foreign_live_owner",
103986
- "no_active_turn",
103987
- "turn_conflict",
103988
- "turn_active",
103989
- "not_steerable",
103990
- "message_too_large",
103991
- "queue_full",
103992
- "cursor_invalid",
103993
- "cursor_stale",
103994
- "idempotency_conflict",
103995
- "idempotency_in_progress",
103996
- "idempotency_uncertain",
103997
- "delivered_unconfirmed",
103998
- "prompt_not_started",
103999
- "approval_unavailable",
104000
- "approval_route_locked",
104001
- "partial_commit",
104002
- "unsupported",
104003
- "overloaded",
104004
- "transport_closed",
104005
- "host_unavailable",
104006
- "internal_error",
104007
- "model_not_found",
104008
- "model_ambiguous",
104009
- "thinking_level_unsupported",
104010
- "loop_detected",
104011
- "pair_loop_guard",
104012
- "chain_count_limit",
104013
- "device_offline",
104014
- "relay_requires_paid_plan",
104015
- "alias_taken",
104016
- "gateway_schema_too_new"
104017
- ];
104018
- CODE_SET = new Set(THREAD_ERROR_CODES);
104019
- });
104020
-
104021
- // packages/omo-senpi/src/components/thread/initial-skills.ts
104022
- var init_initial_skills = () => {};
104023
-
104024
- // packages/omo-senpi/src/components/thread/gateway/result.ts
104025
- var init_result2 = __esm(() => {
104026
- init_errors5();
104027
- });
104028
-
104029
- // packages/omo-senpi/src/components/thread/remote/outcome.ts
104030
- var READ_UNCERTAIN, UNANSWERED, NOT_SIGNED_IN, ENGINE_NOT_READY;
104031
- var init_outcome = __esm(() => {
104032
- init_errors5();
104033
- init_result2();
104034
- READ_UNCERTAIN = {
104035
- request_gone: "retry",
104036
- no_receipt: "retry",
104037
- engine_restarted: "retry",
104038
- recipient_revoked: "retry",
104039
- transport_expired: "retry",
104040
- unconfirmed: "retry",
104041
- lease_expired: "retry",
104042
- cancelled: "retry",
104043
- hand_restarted: "retry",
104044
- result_expired: "retry",
104045
- record_too_large: "too_large",
104046
- result_undecodable: "retry"
104047
- };
104048
- UNANSWERED = new Set([
104049
- "closed",
104050
- "protocol_violation",
104051
- "internal",
104052
- "read_failed",
104053
- "request_timeout",
104054
- "handshake_timeout",
104055
- "attach_failed",
104056
- "reply_lost",
104057
- "delivered_unconfirmed",
104058
- "host_not_answering",
104059
- "peer_not_found",
104060
- "engine_stale",
104061
- ...Object.entries(READ_UNCERTAIN).filter(([, answer]) => answer === "retry").map(([reason]) => reason)
104062
- ]);
104063
- NOT_SIGNED_IN = new Set(["sign_in_required", "signed_out"]);
104064
- ENGINE_NOT_READY = new Set(["attach_required", "daemon_unavailable"]);
104065
- });
104066
-
104067
- // packages/omo-senpi/src/components/thread/address/refusals.ts
104068
- var init_refusals = __esm(() => {
104595
+ // packages/omo-senpi/src/components/thread/addressing.ts
104596
+ var init_addressing = __esm(() => {
104069
104597
  init_errors5();
104070
104598
  });
104071
104599
 
104072
- // packages/omo-senpi/src/components/thread/remote/address-book.ts
104073
- var REMOTE_NOT_SET_UP;
104074
- var init_address_book = __esm(() => {
104075
- init_ports();
104076
- REMOTE_NOT_SET_UP = new Set(["not_configured", "disabled", "signed_out", "sign_in_required"]);
104600
+ // packages/omo-senpi/src/components/thread/session-facts.ts
104601
+ var SESSION_FACTS_WINDOW_BYTES, SESSION_FACTS_LAST_LINE_MAX_BYTES;
104602
+ var init_session_facts = __esm(() => {
104603
+ SESSION_FACTS_WINDOW_BYTES = 64 * 1024;
104604
+ SESSION_FACTS_LAST_LINE_MAX_BYTES = SESSION_FACTS_WINDOW_BYTES * 4;
104077
104605
  });
104078
-
104079
- // packages/omo-senpi/src/components/thread/address/account.ts
104080
- var NOT_SET_UP, lastListed;
104081
- var init_account = __esm(() => {
104082
- init_remote_ops();
104083
- init_address_book();
104084
- NOT_SET_UP = new Set(["not_configured", "disabled", "signed_out", "sign_in_required"]);
104085
- lastListed = new WeakMap;
104606
+ // packages/omo-senpi/src/components/thread/address-book.ts
104607
+ var init_address_book2 = __esm(() => {
104608
+ init_addressing();
104609
+ init_session_facts();
104086
104610
  });
104087
104611
 
104088
- // packages/omo-senpi/src/components/thread/address/device.ts
104089
- var init_device = __esm(() => {
104090
- init_errors5();
104091
- init_account();
104092
- init_refusals();
104093
- });
104612
+ // packages/omo-senpi/src/components/thread/contracts/send-result-order.ts
104613
+ var init_send_result_order = () => {};
104094
104614
 
104095
- // packages/omo-senpi/src/components/thread/remote/remote-ops.ts
104096
- var init_remote_ops = __esm(() => {
104097
- init_refusals();
104098
- init_device();
104099
- init_account();
104100
- init_outcome();
104615
+ // packages/omo-senpi/src/components/thread/metadata.ts
104616
+ var THREAD_TOOL_EXPOSURE = "eval", ROUTE_TO_TASK = "; to spawn a child task instead, use task.", THREAD_TOOL_METADATA;
104617
+ var init_metadata = __esm(() => {
104618
+ THREAD_TOOL_METADATA = [
104619
+ {
104620
+ name: "thread_create",
104621
+ label: "Create session",
104622
+ description: "Starts a fresh agent session that runs alongside this one, for when the user wants a second session working in parallel" + ROUTE_TO_TASK,
104623
+ exposure: THREAD_TOOL_EXPOSURE
104624
+ },
104625
+ {
104626
+ name: "thread_list",
104627
+ label: "List sessions",
104628
+ description: "Shows every addressable session on this device and the account's other devices with its id, name, status and device, plus the account's devices, for when the user needs a valid target address before acting on a session" + ROUTE_TO_TASK,
104629
+ exposure: THREAD_TOOL_EXPOSURE
104630
+ },
104631
+ {
104632
+ name: "thread_read",
104633
+ label: "Read session",
104634
+ description: "Returns the transcript and latest output of another session, for when the user asks what another session said or produced" + ROUTE_TO_TASK,
104635
+ exposure: THREAD_TOOL_EXPOSURE
104636
+ },
104637
+ {
104638
+ name: "thread_send",
104639
+ label: "Send message to session",
104640
+ description: "Delivers a message into another session that is already running, for when the user wants to talk to that session mid-task; its reply comes back through thread_read (tool.thread_read() in an eval cell)" + ROUTE_TO_TASK,
104641
+ exposure: THREAD_TOOL_EXPOSURE
104642
+ },
104643
+ {
104644
+ name: "thread_interrupt",
104645
+ label: "Interrupt session turn",
104646
+ description: "Stops the turn running in another session, and the background jobs that turn started, for when the user wants to halt a session that is going down the wrong path; the result's background lists what was stopped" + ROUTE_TO_TASK,
104647
+ exposure: THREAD_TOOL_EXPOSURE
104648
+ },
104649
+ {
104650
+ name: "thread_close",
104651
+ label: "Close session",
104652
+ description: "Closes a session. Omit thread or pass self to close this session. thread accepts the thread value of a thread_list row (tool.thread_list() in an eval cell), an alias, or a unique name; the result is closed true or false plus a reason. A thread with messages it has not read is refused, naming them; pass force: true to close it anyway (dropped_deliveries lists them)" + ROUTE_TO_TASK,
104653
+ exposure: THREAD_TOOL_EXPOSURE
104654
+ },
104655
+ {
104656
+ name: "thread_handoff",
104657
+ label: "Hand off session",
104658
+ description: "Moves the current request to an old session that has the context, for when the user says to hand this off or reopen that earlier conversation" + ROUTE_TO_TASK,
104659
+ exposure: THREAD_TOOL_EXPOSURE
104660
+ },
104661
+ {
104662
+ name: "thread_rename",
104663
+ label: "Rename session",
104664
+ description: "Renames a session's label, for when the user asks to call a session something clearer. Omit thread or pass self to rename this session. thread accepts the thread value of a thread_list row (tool.thread_list() in an eval cell), an alias, or a unique name; a miss names the thread value to pass",
104665
+ exposure: THREAD_TOOL_EXPOSURE
104666
+ },
104667
+ {
104668
+ name: "thread_set_model",
104669
+ label: "Switch session model",
104670
+ description: "Moves a session onto a different model, for when the user asks to switch that session to another model or a cheaper one",
104671
+ exposure: THREAD_TOOL_EXPOSURE
104672
+ },
104673
+ {
104674
+ name: "thread_set_reasoning",
104675
+ label: "Set session reasoning level",
104676
+ description: "Sets how much reasoning a session applies, for when the user asks to raise or lower the thinking effort of a session",
104677
+ exposure: THREAD_TOOL_EXPOSURE
104678
+ },
104679
+ {
104680
+ name: "thread_archive",
104681
+ label: "Archive session",
104682
+ description: "Archives or unarchives a session so the session list hides or shows it again, for when the user is finished with a session but wants to keep it",
104683
+ exposure: THREAD_TOOL_EXPOSURE
104684
+ }
104685
+ ];
104101
104686
  });
104102
104687
 
104103
- // packages/omo-senpi/src/components/call-budget/call-deadline.ts
104104
- import { AsyncLocalStorage as AsyncLocalStorage4 } from "node:async_hooks";
104105
- var scope;
104106
- var init_call_deadline = __esm(() => {
104107
- scope = new AsyncLocalStorage4;
104688
+ // packages/omo-senpi/src/components/thread/thread-link.ts
104689
+ var THREAD_LINK_SCHEME = "omo-thread", PREFIX;
104690
+ var init_thread_link = __esm(() => {
104691
+ PREFIX = `${THREAD_LINK_SCHEME}://v1/`;
104108
104692
  });
104109
104693
 
104110
104694
  // packages/omo-senpi/src/components/thread/contracts/create-params.ts
@@ -104188,6 +104772,8 @@ var init_params = __esm(() => {
104188
104772
  Literal("opening"),
104189
104773
  Literal("running"),
104190
104774
  Literal("idle"),
104775
+ Literal("held"),
104776
+ Literal("unknown"),
104191
104777
  Literal("inactive"),
104192
104778
  Literal("archived")
104193
104779
  ]), {
@@ -105501,7 +106087,7 @@ function DynamicRef(stack, dynamicRef) {
105501
106087
  const fragmentTarget = RefInternal(stack.context, fragmentRoot, stack.lexicalBase, dynamicRef.$dynamicRef);
105502
106088
  return IsUndefined(fragmentTarget) ? DynamicRefWhenNotFound(stack, dynamicRef) : DynamicRefWhenFound(stack, dynamicRef, fragmentTarget);
105503
106089
  }
105504
- var init_resolve = __esm(() => {
106090
+ var init_resolve2 = __esm(() => {
105505
106091
  init_guard2();
105506
106092
  init_pointer2();
105507
106093
  init_types11();
@@ -105509,8 +106095,8 @@ var init_resolve = __esm(() => {
105509
106095
  });
105510
106096
 
105511
106097
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/schema/resolve/index.mjs
105512
- var init_resolve2 = __esm(() => {
105513
- init_resolve();
106098
+ var init_resolve3 = __esm(() => {
106099
+ init_resolve2();
105514
106100
  });
105515
106101
 
105516
106102
  // node_modules/.bun/typebox@1.3.34/node_modules/typebox/build/schema/engine/dynamicRef.mjs
@@ -105527,7 +106113,7 @@ function ErrorDynamicRef(stack, context, schemaPath, instancePath, schema, value
105527
106113
  var init_dynamicRef2 = __esm(() => {
105528
106114
  init_types11();
105529
106115
  init__functions();
105530
- init_resolve2();
106116
+ init_resolve3();
105531
106117
  init_schema4();
105532
106118
  });
105533
106119
 
@@ -106626,7 +107212,7 @@ function ErrorRecursiveRef(stack, context, schemaPath, instancePath, schema, val
106626
107212
  var init_recursiveRef2 = __esm(() => {
106627
107213
  init_types11();
106628
107214
  init__functions();
106629
- init_resolve2();
107215
+ init_resolve3();
106630
107216
  init_schema4();
106631
107217
  });
106632
107218
 
@@ -106654,7 +107240,7 @@ function ErrorRef(stack, context, schemaPath, instancePath, schema, value) {
106654
107240
  var init_ref4 = __esm(() => {
106655
107241
  init__functions();
106656
107242
  init_types11();
106657
- init_resolve2();
107243
+ init_resolve3();
106658
107244
  init__context();
106659
107245
  init_guard2();
106660
107246
  init_schema4();
@@ -106913,7 +107499,7 @@ var init_intern = __esm(() => {
106913
107499
  init_types11();
106914
107500
  init__stack();
106915
107501
  init_guard2();
106916
- init_resolve2();
107502
+ init_resolve3();
106917
107503
  registry2 = new Map;
106918
107504
  resolved = new Map;
106919
107505
  });
@@ -107044,7 +107630,7 @@ var init_schema6 = __esm(() => {
107044
107630
  init_intern2();
107045
107631
  init_meta2();
107046
107632
  init_pointer2();
107047
- init_resolve2();
107633
+ init_resolve3();
107048
107634
  init_static3();
107049
107635
  init_types11();
107050
107636
  init_build2();
@@ -108831,146 +109417,8 @@ var init_thread_state = __esm(() => {
108831
109417
  RETRY_WAIT_KINDS = new Set(["rate_limit", "retry"]);
108832
109418
  });
108833
109419
 
108834
- // packages/omo-senpi/src/components/thread/control/port.ts
108835
- var REFUSAL;
108836
- var init_port = __esm(() => {
108837
- init_errors5();
108838
- init_thread_state();
108839
- REFUSAL = Symbol.for("omo.thread.control.refusal");
108840
- });
108841
-
108842
- // packages/omo-senpi/src/components/thread/control/close-ladder.ts
108843
- var SESSION_GONE;
108844
- var init_close_ladder = __esm(() => {
108845
- init_call_deadline();
108846
- init_port();
108847
- SESSION_GONE = new Set([
108848
- "unknown_session",
108849
- "route_unlisted",
108850
- "session_identity_mismatch",
108851
- "session_not_attached",
108852
- "not_attached"
108853
- ]);
108854
- });
108855
-
108856
- // packages/omo-senpi/src/components/thread/worktree/failures.ts
108857
- var init_failures = __esm(() => {
108858
- init_errors5();
108859
- });
108860
-
108861
- // packages/omo-senpi/src/components/thread/control/open-reply.ts
108862
- var init_open_reply = __esm(() => {
108863
- init_errors5();
108864
- init_outcome();
108865
- init_failures();
108866
- });
108867
- // packages/omo-senpi/src/components/thread/worktree/remote-worktree.ts
108868
- var init_remote_worktree = __esm(() => {
108869
- init_close_ladder();
108870
- init_open_reply();
108871
- init_port();
108872
- init_errors5();
108873
- init_outcome();
108874
- init_remote_ops();
108875
- init_failures();
108876
- });
108877
-
108878
- // packages/omo-senpi/src/components/thread/thread-link.ts
108879
- var THREAD_LINK_SCHEME = "omo-thread", PREFIX;
108880
- var init_thread_link = __esm(() => {
108881
- PREFIX = `${THREAD_LINK_SCHEME}://v1/`;
108882
- });
108883
-
108884
- // packages/omo-senpi/src/components/thread/addressing.ts
108885
- var init_addressing = __esm(() => {
108886
- init_errors5();
108887
- });
108888
-
108889
- // packages/omo-senpi/src/components/thread/session-facts.ts
108890
- var SESSION_FACTS_WINDOW_BYTES, SESSION_FACTS_LAST_LINE_MAX_BYTES;
108891
- var init_session_facts = __esm(() => {
108892
- SESSION_FACTS_WINDOW_BYTES = 64 * 1024;
108893
- SESSION_FACTS_LAST_LINE_MAX_BYTES = SESSION_FACTS_WINDOW_BYTES * 4;
108894
- });
108895
-
108896
- // packages/omo-senpi/src/components/thread/address-book.ts
108897
- var init_address_book2 = __esm(() => {
108898
- init_addressing();
108899
- init_session_facts();
108900
- });
108901
-
108902
- // packages/omo-senpi/src/components/thread/metadata.ts
108903
- var THREAD_TOOL_EXPOSURE = "eval", ROUTE_TO_TASK = "; to spawn a child task instead, use task.", THREAD_TOOL_METADATA;
108904
- var init_metadata = __esm(() => {
108905
- THREAD_TOOL_METADATA = [
108906
- {
108907
- name: "thread_create",
108908
- label: "Create session",
108909
- description: "Starts a fresh agent session that runs alongside this one, for when the user wants a second session working in parallel" + ROUTE_TO_TASK,
108910
- exposure: THREAD_TOOL_EXPOSURE
108911
- },
108912
- {
108913
- name: "thread_list",
108914
- label: "List sessions",
108915
- description: "Shows every addressable session on this device and the account's other devices with its id, name, status and device, plus the account's devices, for when the user needs a valid target address before acting on a session" + ROUTE_TO_TASK,
108916
- exposure: THREAD_TOOL_EXPOSURE
108917
- },
108918
- {
108919
- name: "thread_read",
108920
- label: "Read session",
108921
- description: "Returns the transcript and latest output of another session, for when the user asks what another session said or produced" + ROUTE_TO_TASK,
108922
- exposure: THREAD_TOOL_EXPOSURE
108923
- },
108924
- {
108925
- name: "thread_send",
108926
- label: "Send message to session",
108927
- description: "Delivers a message into another session that is already running, for when the user wants to talk to that session mid-task; its reply comes back through thread_read (tool.thread_read() in an eval cell)" + ROUTE_TO_TASK,
108928
- exposure: THREAD_TOOL_EXPOSURE
108929
- },
108930
- {
108931
- name: "thread_interrupt",
108932
- label: "Interrupt session turn",
108933
- description: "Stops the turn running in another session, and the background jobs that turn started, for when the user wants to halt a session that is going down the wrong path; the result's background lists what was stopped" + ROUTE_TO_TASK,
108934
- exposure: THREAD_TOOL_EXPOSURE
108935
- },
108936
- {
108937
- name: "thread_close",
108938
- label: "Close session",
108939
- description: "Closes a session. Omit thread or pass self to close this session. thread accepts the thread value of a thread_list row (tool.thread_list() in an eval cell), an alias, or a unique name; the result is closed true or false plus a reason. A thread with messages it has not read is refused, naming them; pass force: true to close it anyway (dropped_deliveries lists them)" + ROUTE_TO_TASK,
108940
- exposure: THREAD_TOOL_EXPOSURE
108941
- },
108942
- {
108943
- name: "thread_handoff",
108944
- label: "Hand off session",
108945
- description: "Moves the current request to an old session that has the context, for when the user says to hand this off or reopen that earlier conversation" + ROUTE_TO_TASK,
108946
- exposure: THREAD_TOOL_EXPOSURE
108947
- },
108948
- {
108949
- name: "thread_rename",
108950
- label: "Rename session",
108951
- description: "Renames a session's label, for when the user asks to call a session something clearer. Omit thread or pass self to rename this session. thread accepts the thread value of a thread_list row (tool.thread_list() in an eval cell), an alias, or a unique name; a miss names the thread value to pass",
108952
- exposure: THREAD_TOOL_EXPOSURE
108953
- },
108954
- {
108955
- name: "thread_set_model",
108956
- label: "Switch session model",
108957
- description: "Moves a session onto a different model, for when the user asks to switch that session to another model or a cheaper one",
108958
- exposure: THREAD_TOOL_EXPOSURE
108959
- },
108960
- {
108961
- name: "thread_set_reasoning",
108962
- label: "Set session reasoning level",
108963
- description: "Sets how much reasoning a session applies, for when the user asks to raise or lower the thinking effort of a session",
108964
- exposure: THREAD_TOOL_EXPOSURE
108965
- },
108966
- {
108967
- name: "thread_archive",
108968
- label: "Archive session",
108969
- description: "Archives or unarchives a session so the session list hides or shows it again, for when the user is finished with a session but wants to keep it",
108970
- exposure: THREAD_TOOL_EXPOSURE
108971
- }
108972
- ];
108973
- });
109420
+ // packages/omo-senpi/src/components/thread/tools/row-liveness.ts
109421
+ var init_row_liveness = () => {};
108974
109422
 
108975
109423
  // packages/omo-senpi/src/components/thread/tools/internals.ts
108976
109424
  function failure3(code, message, next, details) {
@@ -108979,36 +109427,26 @@ function failure3(code, message, next, details) {
108979
109427
  var init_internals = __esm(() => {
108980
109428
  init_address_book2();
108981
109429
  init_addressing();
109430
+ init_send_result_order();
108982
109431
  init_errors5();
108983
109432
  init_metadata();
108984
109433
  init_session_facts();
108985
109434
  init_thread_link();
108986
109435
  init_thread_state();
109436
+ init_row_liveness();
108987
109437
  });
108988
109438
 
108989
- // packages/omo-senpi/src/components/thread/control/session-host.ts
108990
- var init_session_host = __esm(() => {
109439
+ // packages/omo-senpi/src/components/thread/tools/model-match.ts
109440
+ var init_model_match = __esm(() => {
108991
109441
  init_internals();
108992
109442
  });
108993
109443
 
108994
- // packages/omo-senpi/src/components/thread/control/relay-session-host.ts
108995
- var init_relay_session_host = __esm(() => {
108996
- init_ports();
109444
+ // packages/omo-senpi/src/components/thread/control/port.ts
109445
+ var REFUSAL;
109446
+ var init_port = __esm(() => {
108997
109447
  init_errors5();
108998
- init_initial_skills();
108999
- init_outcome();
109000
- init_remote_ops();
109001
- init_device();
109002
- init_remote_worktree();
109003
- init_open_reply();
109004
- init_thread_link();
109005
109448
  init_thread_state();
109006
- init_session_host();
109007
- });
109008
-
109009
- // packages/omo-senpi/src/components/thread/tools/model-match.ts
109010
- var init_model_match = __esm(() => {
109011
- init_internals();
109449
+ REFUSAL = Symbol.for("omo.thread.control.refusal");
109012
109450
  });
109013
109451
 
109014
109452
  // packages/omo-senpi/src/components/thread/control/operations.ts
@@ -109060,6 +109498,20 @@ var init_transcript_tail = __esm(() => {
109060
109498
  kept = new WeakMap;
109061
109499
  unpaged = new WeakMap;
109062
109500
  });
109501
+
109502
+ // packages/omo-senpi/src/components/thread/control/close-ladder.ts
109503
+ var SESSION_GONE2;
109504
+ var init_close_ladder = __esm(() => {
109505
+ init_call_deadline();
109506
+ init_port();
109507
+ SESSION_GONE2 = new Set([
109508
+ "unknown_session",
109509
+ "route_unlisted",
109510
+ "session_identity_mismatch",
109511
+ "session_not_attached",
109512
+ "not_attached"
109513
+ ]);
109514
+ });
109063
109515
  // packages/omo-senpi/src/components/thread/control/wait-settled.ts
109064
109516
  var IN_PROGRESS, RUN_RECORDS;
109065
109517
  var init_wait_settled = __esm(() => {
@@ -109080,6 +109532,58 @@ var init_wait_settled = __esm(() => {
109080
109532
  ]);
109081
109533
  });
109082
109534
 
109535
+ // packages/omo-senpi/src/components/thread/initial-skills.ts
109536
+ var init_initial_skills = () => {};
109537
+
109538
+ // packages/omo-senpi/src/components/thread/worktree/failures.ts
109539
+ var init_failures = __esm(() => {
109540
+ init_errors5();
109541
+ });
109542
+
109543
+ // packages/omo-senpi/src/components/thread/control/open-reply.ts
109544
+ var init_open_reply = __esm(() => {
109545
+ init_errors5();
109546
+ init_outcome();
109547
+ init_failures();
109548
+ });
109549
+ // packages/omo-senpi/src/components/thread/worktree/remote-worktree.ts
109550
+ var init_remote_worktree = __esm(() => {
109551
+ init_close_ladder();
109552
+ init_open_reply();
109553
+ init_port();
109554
+ init_errors5();
109555
+ init_outcome();
109556
+ init_remote_ops();
109557
+ init_failures();
109558
+ });
109559
+
109560
+ // packages/omo-senpi/src/components/thread/remote/listing-liveness.ts
109561
+ var init_listing_liveness = __esm(() => {
109562
+ init_row_liveness();
109563
+ init_thread_state();
109564
+ });
109565
+
109566
+ // packages/omo-senpi/src/components/thread/control/session-host.ts
109567
+ var init_session_host = __esm(() => {
109568
+ init_internals();
109569
+ });
109570
+
109571
+ // packages/omo-senpi/src/components/thread/control/relay-session-host.ts
109572
+ var init_relay_session_host = __esm(() => {
109573
+ init_ports();
109574
+ init_errors5();
109575
+ init_initial_skills();
109576
+ init_outcome();
109577
+ init_remote_ops();
109578
+ init_device();
109579
+ init_remote_worktree();
109580
+ init_open_reply();
109581
+ init_thread_link();
109582
+ init_thread_state();
109583
+ init_listing_liveness();
109584
+ init_session_host();
109585
+ });
109586
+
109083
109587
  // packages/omo-senpi/src/components/thread/tools/thread-row.ts
109084
109588
  var init_thread_row = __esm(() => {
109085
109589
  init_thread_link();
@@ -109101,165 +109605,6 @@ var init_relay_control = __esm(() => {
109101
109605
  init_thread_row();
109102
109606
  });
109103
109607
 
109104
- // packages/omo-senpi/src/components/thread/remote/attach-pool.ts
109105
- var CATALOG_RECORD = "get_available_models", HELD_RECORDS;
109106
- var init_attach_pool = __esm(() => {
109107
- HELD_RECORDS = new Set([CATALOG_RECORD, "get_protocol_info"]);
109108
- });
109109
-
109110
- // packages/omo-senpi/src/components/thread/remote/session-state.ts
109111
- var ACCESS_ENDED, ACCESS_REFUSED, SESSION_LEFT, SESSION_GONE2;
109112
- var init_session_state = __esm(() => {
109113
- ACCESS_ENDED = new Set([
109114
- "authorization_expired",
109115
- "peer_revoked",
109116
- "owner_transfer",
109117
- "service_disabled"
109118
- ]);
109119
- ACCESS_REFUSED = new Set([
109120
- "unauthenticated",
109121
- "forbidden",
109122
- "owner_transfer",
109123
- "signed_out",
109124
- "service_disabled",
109125
- "sign_in_required",
109126
- "plan_required",
109127
- "peer_not_found",
109128
- "peer_not_session_client",
109129
- "account_changed",
109130
- "device_changed",
109131
- "capability_missing",
109132
- "engine_too_old"
109133
- ]);
109134
- SESSION_LEFT = new Set(["session_closed", "session_replaced"]);
109135
- SESSION_GONE2 = new Set([
109136
- "session_not_found",
109137
- "unknown_session",
109138
- "session_identity_mismatch"
109139
- ]);
109140
- });
109141
- // packages/omo-senpi/src/components/thread/remote/remote-watch.ts
109142
- var init_remote_watch = __esm(() => {
109143
- init_device_service2();
109144
- init_ports();
109145
- init_session_state();
109146
- });
109147
- // packages/omo-senpi/src/components/remote/port/lookup-gate.ts
109148
- var init_lookup_gate = __esm(() => {
109149
- init_ports();
109150
- });
109151
-
109152
- // packages/omo-senpi/src/components/remote/port/device-service.ts
109153
- var READ_ONLY_RECORDS, MARKED_RECORDS, LOOKUP_NONE;
109154
- var init_device_service3 = __esm(() => {
109155
- init_outcome();
109156
- init_device_service2();
109157
- init_attach_pool();
109158
- init_remote_watch();
109159
- init_call_deadline();
109160
- init_lookup_gate();
109161
- READ_ONLY_RECORDS = new Set([
109162
- "get_state",
109163
- "get_messages",
109164
- "get_entries",
109165
- "get_protocol_info"
109166
- ]);
109167
- MARKED_RECORDS = new Set(["admit_external_message"]);
109168
- LOOKUP_NONE = new Set(["session_not_found", "peer_not_found", "peer_not_session_client"]);
109169
- });
109170
-
109171
- // packages/device-service-core/src/wire.ts
109172
- var init_wire = __esm(() => {
109173
- init_errors4();
109174
- });
109175
-
109176
- // packages/omo-senpi/src/components/remote/codes.ts
109177
- var REMOTE_CODES, ENGINE_CODES;
109178
- var init_codes = __esm(() => {
109179
- init_wire();
109180
- init_errors5();
109181
- REMOTE_CODES = [
109182
- ...THREAD_ERROR_CODES,
109183
- "timeout",
109184
- "cancelled",
109185
- "session_ended",
109186
- "sender_not_allowed",
109187
- "local_only",
109188
- "host_not_answering",
109189
- "no_transport",
109190
- "device_offline",
109191
- "undelivered",
109192
- "transport_expired",
109193
- "unconfirmed",
109194
- "host_error"
109195
- ];
109196
- ENGINE_CODES = new Map([
109197
- ["model_unavailable", { code: "model_not_found" }],
109198
- ["invalid_level", { code: "thinking_level_unsupported" }],
109199
- ["worktree_failed", { code: "unsupported", details: { feature: "worktree" } }],
109200
- ["not_running", { code: "not_resumable" }],
109201
- ["handle_lost", { code: "not_found", details: { kind: "handle" } }]
109202
- ]);
109203
- });
109204
-
109205
- // packages/omo-senpi/src/components/remote/connection-of.ts
109206
- var lenders;
109207
- var init_connection_of = __esm(() => {
109208
- lenders = new WeakMap;
109209
- });
109210
-
109211
- // packages/omo-senpi/src/components/remote/deadlines.ts
109212
- var init_deadlines = __esm(() => {
109213
- init_codes();
109214
- });
109215
-
109216
- // packages/omo-senpi/src/components/remote/seams.ts
109217
- var init_seams = __esm(() => {
109218
- init_codes();
109219
- });
109220
-
109221
- // packages/omo-senpi/src/components/remote/resolve.ts
109222
- var init_resolve3 = __esm(() => {
109223
- init_client5();
109224
- init_deadlines();
109225
- init_codes();
109226
- init_seams();
109227
- });
109228
-
109229
- // packages/omo-senpi/src/components/remote/aliases.ts
109230
- var init_aliases = __esm(() => {
109231
- init_codes();
109232
- init_deadlines();
109233
- init_resolve3();
109234
- init_seams();
109235
- });
109236
-
109237
- // packages/omo-senpi/src/components/remote/attach.ts
109238
- var DIALOG_KINDS;
109239
- var init_attach = __esm(() => {
109240
- init_device_service2();
109241
- init_outcome();
109242
- init_client5();
109243
- init_codes();
109244
- init_deadlines();
109245
- init_device_service3();
109246
- init_resolve3();
109247
- init_seams();
109248
- DIALOG_KINDS = new Set(["select", "confirm", "input", "editor", "question"]);
109249
- });
109250
-
109251
- // packages/omo-senpi/src/components/remote/follow.ts
109252
- var RUN_OVER;
109253
- var init_follow = __esm(() => {
109254
- init_outcome();
109255
- init_attach();
109256
- init_client5();
109257
- init_codes();
109258
- init_deadlines();
109259
- init_seams();
109260
- RUN_OVER = new Set(["waiting_children", "waiting_background", "done", "failed", "cancelled"]);
109261
- });
109262
-
109263
109608
  // packages/omo-senpi/src/components/thread/gateway/hash-args.ts
109264
109609
  var init_hash_args = () => {};
109265
109610
 
@@ -109317,7 +109662,7 @@ var init_relay_transport = __esm(() => {
109317
109662
  init_errors5();
109318
109663
  init_hash_args();
109319
109664
  init_provenance2();
109320
- init_result2();
109665
+ init_result();
109321
109666
  init_remote_ops();
109322
109667
  init_device();
109323
109668
  init_outcome();
@@ -109365,9 +109710,10 @@ var init_sessions = __esm(() => {
109365
109710
  init_codes();
109366
109711
  init_deadlines();
109367
109712
  init_device_service3();
109368
- init_resolve3();
109713
+ init_resolve();
109369
109714
  init_seams();
109370
109715
  init_client_message_id();
109716
+ init_send_transcript();
109371
109717
  NO_SESSION = new Set(["unknown_session", "session_not_found"]);
109372
109718
  });
109373
109719
  // packages/omo-senpi/src/components/remote/unknown-device.ts
@@ -109384,7 +109730,7 @@ var init_client5 = __esm(() => {
109384
109730
  init_codes();
109385
109731
  init_deadlines();
109386
109732
  init_follow();
109387
- init_resolve3();
109733
+ init_resolve();
109388
109734
  init_seams();
109389
109735
  init_sessions();
109390
109736
  init_unknown_device();
@@ -109468,6 +109814,54 @@ var init_address = __esm(() => {
109468
109814
  init_resolve4();
109469
109815
  });
109470
109816
 
109817
+ // packages/omo-senpi/src/components/remote/device-address.ts
109818
+ var init_device_address = __esm(() => {
109819
+ init_address();
109820
+ init_errors5();
109821
+ });
109822
+
109823
+ // packages/omo-senpi/src/components/remote/port/sessions-port.ts
109824
+ var init_sessions_port = __esm(() => {
109825
+ init_connection_of();
109826
+ init_device_service3();
109827
+ });
109828
+
109829
+ // packages/omo-senpi/src/components/remote/person-surface.ts
109830
+ var init_person_surface = __esm(() => {
109831
+ init_sessions_port();
109832
+ });
109833
+
109834
+ // packages/omo-senpi/src/components/remote/relay-availability.ts
109835
+ var init_relay_availability = __esm(() => {
109836
+ init_remote_ops();
109837
+ });
109838
+
109839
+ // packages/omo-senpi/src/components/remote/local-service.ts
109840
+ var init_local_service = __esm(() => {
109841
+ init_device_service2();
109842
+ });
109843
+
109844
+ // packages/omo-senpi/src/components/remote/port/thread-runtime.ts
109845
+ var init_thread_runtime = __esm(() => {
109846
+ init_factories();
109847
+ init_sessions_port();
109848
+ });
109849
+
109850
+ // packages/omo-senpi/src/components/remote/index.ts
109851
+ var init_remote = __esm(() => {
109852
+ init_codes();
109853
+ init_factories();
109854
+ init_seams();
109855
+ init_address();
109856
+ init_device_address();
109857
+ init_person_surface();
109858
+ init_relay_availability();
109859
+ init_account_state();
109860
+ init_device_service2();
109861
+ init_local_service();
109862
+ init_thread_runtime();
109863
+ });
109864
+
109471
109865
  // packages/omo-opencode/src/cli/cli-program.ts
109472
109866
  init_commander();
109473
109867
 
@@ -110778,25 +111172,30 @@ async function rewriteCachedManifestRoot(pluginRoot, fromRoot, toRoot) {
110778
111172
  }
110779
111173
 
110780
111174
  // packages/omo-codex/src/install/codex-cache-payload.ts
110781
- import { cp as cp2, lstat as lstat5, mkdtemp, readdir as readdir4, rename, rm as rm4 } from "node:fs/promises";
111175
+ import { cp as cp2, lstat as lstat5, mkdtemp, readdir as readdir4, rename, rm as rm4, stat as stat4 } from "node:fs/promises";
110782
111176
  import { join as join31, relative as relative4, sep as sep4 } from "node:path";
110783
111177
  var NPM_BIN_PATH_SEGMENT = `${sep4}node_modules${sep4}.bin${sep4}`;
111178
+ var isNpmBinEntry = (pluginRoot, path) => `${sep4}${relative4(pluginRoot, path)}`.includes(NPM_BIN_PATH_SEGMENT);
110784
111179
  async function finalizeCachedPluginPayload(pluginRoot) {
110785
- await materializeDirectory(pluginRoot);
111180
+ await materializeDirectory(pluginRoot, pluginRoot);
110786
111181
  const unsupported = await unsupportedEntries(pluginRoot, pluginRoot);
110787
- if (unsupported.length > 0) {
110788
- throw new Error(`Codex plugin contains unsupported entry types: ${unsupported.sort().join(", ")}`);
110789
- }
111182
+ if (unsupported.length > 0)
111183
+ throw unsupportedEntryError(unsupported);
110790
111184
  }
110791
- async function materializeDirectory(directory) {
111185
+ var unsupportedEntryError = (paths) => new Error(`Codex plugin contains unsupported entry types: ${[...paths].sort().join(", ")}`);
111186
+ async function materializeDirectory(pluginRoot, directory) {
110792
111187
  for (const name of await readdir4(directory)) {
110793
111188
  const path = join31(directory, name);
110794
111189
  let entry = await lstat5(path);
110795
- if (path.includes(NPM_BIN_PATH_SEGMENT) && !entry.isFile() && !entry.isDirectory()) {
111190
+ if (isNpmBinEntry(pluginRoot, path) && !entry.isFile() && !entry.isDirectory()) {
110796
111191
  await rm4(path, { recursive: true, force: true });
110797
111192
  continue;
110798
111193
  }
110799
111194
  if (entry.isSymbolicLink()) {
111195
+ if (await stat4(path).catch(() => {
111196
+ return;
111197
+ }) === undefined)
111198
+ throw unsupportedEntryError([relative4(pluginRoot, path)]);
110800
111199
  const staging = await mkdtemp(join31(directory, ".omo-materialize-"));
110801
111200
  try {
110802
111201
  const copyPath = join31(staging, "entry");
@@ -110804,7 +111203,7 @@ async function materializeDirectory(directory) {
110804
111203
  recursive: true,
110805
111204
  dereference: true,
110806
111205
  filter: async (source) => {
110807
- if (!source.includes(NPM_BIN_PATH_SEGMENT))
111206
+ if (!isNpmBinEntry(pluginRoot, source))
110808
111207
  return true;
110809
111208
  const sourceEntry = await lstat5(source);
110810
111209
  return sourceEntry.isFile() || sourceEntry.isDirectory();
@@ -110818,7 +111217,7 @@ async function materializeDirectory(directory) {
110818
111217
  entry = await lstat5(path);
110819
111218
  }
110820
111219
  if (entry.isDirectory())
110821
- await materializeDirectory(path);
111220
+ await materializeDirectory(pluginRoot, path);
110822
111221
  }
110823
111222
  }
110824
111223
  async function unsupportedEntries(root, directory) {
@@ -111112,7 +111511,7 @@ function repoRootForCodexPluginSource(sourcePath) {
111112
111511
  return dirname13(packagesRoot);
111113
111512
  }
111114
111513
  // packages/omo-codex/src/install/codex-cache-prune.ts
111115
- import { lstat as lstat6, readdir as readdir6, rm as rm6, stat as stat4 } from "node:fs/promises";
111514
+ import { lstat as lstat6, readdir as readdir6, rm as rm6, stat as stat5 } from "node:fs/promises";
111116
111515
  import { join as join34 } from "node:path";
111117
111516
  async function pruneMarketplaceCache(input) {
111118
111517
  const cacheRoot = join34(input.codexHome, "plugins", "cache", input.marketplaceName);
@@ -111168,7 +111567,7 @@ async function isBrokenCacheSymlink(path) {
111168
111567
  throw error;
111169
111568
  }
111170
111569
  try {
111171
- await stat4(path);
111570
+ await stat5(path);
111172
111571
  return false;
111173
111572
  } catch (error) {
111174
111573
  if (isNodeErrorWithCode(error) && error.code === "ENOENT")
@@ -111177,7 +111576,7 @@ async function isBrokenCacheSymlink(path) {
111177
111576
  }
111178
111577
  }
111179
111578
  // packages/omo-codex/src/install/codex-cached-marketplace-manifest.ts
111180
- import { mkdir as mkdir4, rename as rename3, rm as rm7, stat as stat5, writeFile as writeFile5 } from "node:fs/promises";
111579
+ import { mkdir as mkdir4, rename as rename3, rm as rm7, stat as stat6, writeFile as writeFile5 } from "node:fs/promises";
111181
111580
  import { join as join35 } from "node:path";
111182
111581
  async function writeCachedMarketplaceManifest(input) {
111183
111582
  const marketplaceDir = join35(input.marketplaceRoot, ".agents", "plugins");
@@ -111206,7 +111605,7 @@ async function writeCachedMarketplaceManifest(input) {
111206
111605
  }
111207
111606
  async function isDirectory2(path) {
111208
111607
  try {
111209
- return (await stat5(path)).isDirectory();
111608
+ return (await stat6(path)).isDirectory();
111210
111609
  } catch (error) {
111211
111610
  if (error instanceof Error && "code" in error && error.code === "ENOENT")
111212
111611
  return false;
@@ -115593,7 +115992,7 @@ function installLocalLauncher(options) {
115593
115992
  // packages/omo-senpi/src/install/plugin-artifacts.ts
115594
115993
  import { createHash as createHash7 } from "node:crypto";
115595
115994
  import { constants as constants9 } from "node:fs";
115596
- import { access as access3, readFile as readFile30, stat as stat6 } from "node:fs/promises";
115995
+ import { access as access3, readFile as readFile30, stat as stat7 } from "node:fs/promises";
115597
115996
  import { dirname as dirname25, join as join66 } from "node:path";
115598
115997
 
115599
115998
  // packages/memory-core/src/personas/manifest.ts
@@ -115740,6 +116139,7 @@ var REQUIRED_PLUGIN_ARTIFACTS = [
115740
116139
  join66("extensions", "omo-telemetry-posthog.js"),
115741
116140
  join66("extensions", "omo-telemetry-otlp.js"),
115742
116141
  join66("extensions", "omo-memory-sync.js"),
116142
+ join66("extensions", "omo-memory-sync-rpc.js"),
115743
116143
  join66("extensions", "loro_wasm_bg.wasm"),
115744
116144
  join66("extensions", "CaseFolding.txt"),
115745
116145
  join66("extensions", "omo-thread-client.js"),
@@ -115762,7 +116162,8 @@ var REQUIRED_PLUGIN_ARTIFACTS = [
115762
116162
  join66("skills", "coding-agent-sessions", "SKILL.md"),
115763
116163
  join66("skills", "debugging", "SKILL.md"),
115764
116164
  join66("skills", "frontend", "SKILL.md"),
115765
- join66("skills", "git-master", "SKILL.md"),
116165
+ join66("skills", "git", "SKILL.md"),
116166
+ join66("skills", "github", "SKILL.md"),
115766
116167
  join66("skills", "init-deep", "SKILL.md"),
115767
116168
  join66("skills", "lsp-setup", "SKILL.md"),
115768
116169
  join66("skills", "programming", "SKILL.md"),
@@ -115831,7 +116232,7 @@ async function verifyAstGrepRuntimeIntegrity(pluginPath, platform) {
115831
116232
  const manifestPath = join66(dirname25(runtimeEntry), "manifest.json");
115832
116233
  let runtimeStat;
115833
116234
  try {
115834
- runtimeStat = await stat6(runtimeEntry);
116235
+ runtimeStat = await stat7(runtimeEntry);
115835
116236
  if (!runtimeStat.isFile())
115836
116237
  throw new Error("runtime is not a file");
115837
116238
  await access3(runtimeEntry, constants9.R_OK | constants9.X_OK);
@@ -120078,6 +120479,7 @@ var BuiltinSkillNameSchema = _enum([
120078
120479
  "playwright",
120079
120480
  "dev-browser",
120080
120481
  "frontend",
120482
+ "git",
120081
120483
  "git-master",
120082
120484
  "review-work",
120083
120485
  "remove-ai-slops",
@@ -125515,7 +125917,7 @@ function resolveLatestVersion(input) {
125515
125917
 
125516
125918
  // packages/omo-opencode/src/cli/doctor/checks/codex-components.ts
125517
125919
  init_src();
125518
- import { readdir as readdir16, readFile as readFile32, stat as stat7 } from "node:fs/promises";
125920
+ import { readdir as readdir16, readFile as readFile32, stat as stat8 } from "node:fs/promises";
125519
125921
  import { homedir as homedir27 } from "node:os";
125520
125922
  import { dirname as dirname40, isAbsolute as isAbsolute15, join as join100, relative as relative10, resolve as resolve28, sep as sep11 } from "node:path";
125521
125923
  var CODEX_COMPONENTS_CHECK_ID = "codex-components";
@@ -125780,7 +126182,7 @@ async function readJson2(path) {
125780
126182
  }
125781
126183
  async function fileSize(path) {
125782
126184
  try {
125783
- const stats = await stat7(path);
126185
+ const stats = await stat8(path);
125784
126186
  return stats.isFile() ? stats.size : undefined;
125785
126187
  } catch {
125786
126188
  return;
@@ -128531,7 +128933,7 @@ var {
128531
128933
  realpath: realpath2,
128532
128934
  rm: rm16,
128533
128935
  rmdir: rmdir2,
128534
- stat: stat8,
128936
+ stat: stat9,
128535
128937
  statfs,
128536
128938
  unlink: unlink3
128537
128939
  } = promises;
@@ -128880,7 +129282,7 @@ async function locateHelper(candidates, verify) {
128880
129282
  // packages/omo-opencode/src/cli/service-auth/keychain-helper/pin.ts
128881
129283
  import { createHash as createHash11 } from "node:crypto";
128882
129284
  import { readdirSync as readdirSync15, rmSync as rmSync9 } from "node:fs";
128883
- import { chmod as chmod3, copyFile as copyFile5, constants as constants14, mkdir as mkdir11, readFile as readFile35, rename as rename9, rm as rm17, stat as stat9 } from "node:fs/promises";
129285
+ import { chmod as chmod3, copyFile as copyFile5, constants as constants14, mkdir as mkdir11, readFile as readFile35, rename as rename9, rm as rm17, stat as stat10 } from "node:fs/promises";
128884
129286
  import { tmpdir as tmpdir6 } from "node:os";
128885
129287
  import { basename as basename15, join as join108 } from "node:path";
128886
129288
  var DIR_PREFIX = "omo-keychain-";
@@ -128927,7 +129329,7 @@ async function defaultPinDir() {
128927
129329
  }
128928
129330
  async function fileVerdict(path, verify) {
128929
129331
  try {
128930
- if (!(await stat9(path)).isFile())
129332
+ if (!(await stat10(path)).isFile())
128931
129333
  return "absent";
128932
129334
  } catch {
128933
129335
  return "absent";
@@ -128936,7 +129338,7 @@ async function fileVerdict(path, verify) {
128936
129338
  }
128937
129339
  var pinned = new Map;
128938
129340
  async function sourceIdentity(source) {
128939
- const info = await stat9(source);
129341
+ const info = await stat10(source);
128940
129342
  return `${source}\x00${info.dev}\x00${info.ino}\x00${info.size}\x00${info.mtimeMs}\x00${info.ctimeMs}`;
128941
129343
  }
128942
129344
  async function copyAndVerify(source, verify, dir) {
@@ -129025,7 +129427,7 @@ async function pinVerifiedCopy(source, verify, dir) {
129025
129427
  }
129026
129428
 
129027
129429
  // packages/omo-opencode/src/cli/service-auth/keychain-helper/signature.ts
129028
- import { stat as stat10 } from "node:fs/promises";
129430
+ import { stat as stat11 } from "node:fs/promises";
129029
129431
  init_bun_spawn_shim();
129030
129432
  var KEYCHAIN_HELPER_REQUIREMENT = 'identifier "com.mengmota.omo-keychain-helper" and anchor apple generic and certificate 1[field.1.2.840.113635.100.6.2.6] ' + 'and certificate leaf[field.1.2.840.113635.100.6.1.13] and certificate leaf[subject.OU] = "523JNR86LZ"';
129031
129433
  var STRICT_ALL_ARCHITECTURES = 1 << 4 | 1 << 0;
@@ -129096,7 +129498,7 @@ var verifyWithSecurityFramework = async (path, requirement) => {
129096
129498
  };
129097
129499
  async function fileIdentity(path) {
129098
129500
  try {
129099
- const info = await stat10(path);
129501
+ const info = await stat11(path);
129100
129502
  if (!info.isFile())
129101
129503
  return null;
129102
129504
  return `${path}\x00${info.dev}\x00${info.ino}\x00${info.size}\x00${info.mtimeMs}\x00${info.ctimeMs}`;
@@ -129549,7 +129951,7 @@ import { dirname as dirname43 } from "node:path";
129549
129951
 
129550
129952
  // packages/team-core/src/team-state-store/lock-record.ts
129551
129953
  import { randomUUID as randomUUID6 } from "node:crypto";
129552
- import { readFile as readFile36, stat as stat11 } from "node:fs/promises";
129954
+ import { readFile as readFile36, stat as stat12 } from "node:fs/promises";
129553
129955
 
129554
129956
  // packages/memory-core/src/locks/process-identity.ts
129555
129957
  import { execFile as execFile8 } from "node:child_process";
@@ -129648,9 +130050,9 @@ function errorCode(error) {
129648
130050
  return;
129649
130051
  return typeof error.code === "string" ? error.code : undefined;
129650
130052
  }
129651
- async function execFileText(command, args) {
130053
+ async function execFileText(command, args, env) {
129652
130054
  return await new Promise((resolve) => {
129653
- execFile8(command, args, { encoding: "utf8", timeout: 2000, windowsHide: true }, (error, stdout) => {
130055
+ execFile8(command, args, { encoding: "utf8", timeout: 2000, windowsHide: true, env }, (error, stdout) => {
129654
130056
  if (error !== null) {
129655
130057
  resolve(null);
129656
130058
  return;
@@ -129719,13 +130121,17 @@ async function readProcessStartIdentity(pid) {
129719
130121
  const startSeconds = await readDarwinProcessStartSeconds(pid);
129720
130122
  if (startSeconds !== null)
129721
130123
  return `proc-start-epoch:${startSeconds}`;
129722
- const value = await execFileText("/bin/ps", ["-o", "lstart=", "-p", String(pid)]);
129723
- return value === null ? null : `ps-lstart:${value.replace(/\s+/g, " ")}`;
130124
+ return await readPsLstartIdentity(pid);
129724
130125
  }
129725
130126
  if (process.platform === "win32")
129726
130127
  return await readWin32StartIdentity(pid);
129727
130128
  return null;
129728
130129
  }
130130
+ async function readPsLstartIdentity(pid, exec = execFileText) {
130131
+ const env = { ...process.env, TZ: "UTC", LC_ALL: "C", LANG: "C" };
130132
+ const value = await exec("/bin/ps", ["-o", "lstart=", "-p", String(pid)], env);
130133
+ return value === null ? null : `ps-lstart-utc:${value.replace(/\s+/g, " ")}`;
130134
+ }
129729
130135
  async function getProcessCommandName(pid) {
129730
130136
  let argv0;
129731
130137
  if (process.platform === "linux") {
@@ -129746,9 +130152,35 @@ function identityScheme(identity) {
129746
130152
  const separator = identity.indexOf(":");
129747
130153
  return separator <= 0 ? null : identity.slice(0, separator);
129748
130154
  }
130155
+ var LSTART_MONTHS = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
130156
+ var LSTART_C_RENDERING = /^[A-Z][a-z]{2} ([A-Z][a-z]{2}) (\d{1,2}) (\d{2}):(\d{2}):(\d{2}) (\d{4})$/;
130157
+ function lstartWallClockMs(rendering) {
130158
+ const match = LSTART_C_RENDERING.exec(rendering);
130159
+ if (match === null)
130160
+ return null;
130161
+ const [, month, day, hours, minutes, seconds, year] = match;
130162
+ const monthIndex = LSTART_MONTHS.indexOf(month ?? "");
130163
+ if (monthIndex < 0)
130164
+ return null;
130165
+ return Date.UTC(Number(year), monthIndex, Number(day), Number(hours), Number(minutes), Number(seconds));
130166
+ }
130167
+ var MIN_ZONE_OFFSET_MS = -12 * 3600000;
130168
+ var MAX_ZONE_OFFSET_MS = 14 * 3600000;
130169
+ var ZONE_OFFSET_STEP_MS = 15 * 60000;
130170
+ function legacyPsLstartConflict(recorded, actual) {
130171
+ const recordedWall = lstartWallClockMs(recorded.slice("ps-lstart:".length));
130172
+ const actualUtc = lstartWallClockMs(actual.slice("ps-lstart-utc:".length));
130173
+ if (recordedWall === null || actualUtc === null)
130174
+ return false;
130175
+ const offset = recordedWall - actualUtc;
130176
+ return offset < MIN_ZONE_OFFSET_MS || offset > MAX_ZONE_OFFSET_MS || offset % ZONE_OFFSET_STEP_MS !== 0;
130177
+ }
129749
130178
  function startIdentitiesConflict(recorded, actual) {
129750
130179
  const recordedScheme = identityScheme(recorded);
129751
- if (recordedScheme === null || recordedScheme !== identityScheme(actual))
130180
+ const actualScheme = identityScheme(actual);
130181
+ if (recordedScheme === "ps-lstart" && actualScheme === "ps-lstart-utc")
130182
+ return legacyPsLstartConflict(recorded, actual);
130183
+ if (recordedScheme === null || recordedScheme !== actualScheme)
129752
130184
  return false;
129753
130185
  return recorded !== actual;
129754
130186
  }
@@ -129968,7 +130400,7 @@ function parseLockHolder(content) {
129968
130400
  async function readLockRecord(lockPath) {
129969
130401
  try {
129970
130402
  const content = await readFile36(lockPath, "utf8");
129971
- const { mtimeMs } = await stat11(lockPath);
130403
+ const { mtimeMs } = await stat12(lockPath);
129972
130404
  return { content, modifiedAtEpochMs: mtimeMs };
129973
130405
  } catch (error) {
129974
130406
  if (!(error instanceof Error))
@@ -131292,29 +131724,9 @@ ${key.name}`;
131292
131724
  }
131293
131725
 
131294
131726
  // packages/omo-opencode/src/cli/service-auth/session.ts
131727
+ init_local_only();
131295
131728
  import { homedir as homedir34 } from "node:os";
131296
131729
 
131297
- // packages/device-service-core/src/local-only.ts
131298
- var KEY2 = Symbol.for("omo.local-only-process.v1");
131299
- function state3() {
131300
- const holder = globalThis;
131301
- holder[KEY2] ??= { marked: false };
131302
- return holder[KEY2];
131303
- }
131304
-
131305
- class LocalOnlyNetworkRefused extends Error {
131306
- code = "local_only_network_refused";
131307
- site;
131308
- constructor(site) {
131309
- super(`a local-only omo remote command reached the network at ${site}`);
131310
- this.site = site;
131311
- }
131312
- }
131313
- function refuseIfLocalOnly(site) {
131314
- if (state3().marked)
131315
- throw new LocalOnlyNetworkRefused(site);
131316
- }
131317
-
131318
131730
  // packages/memory-core/src/sync/contract-version.ts
131319
131731
  var SYNC_CONTRACT_VERSION = "1.44.0";
131320
131732
  var SYNC_CAPABILITIES = "phrase";
@@ -131325,6 +131737,7 @@ var syncRequestHeaders = (token) => ({
131325
131737
  });
131326
131738
 
131327
131739
  // packages/omo-opencode/src/cli/service-auth/protocol-request.ts
131740
+ init_local_only();
131328
131741
  init_zod();
131329
131742
  class InvalidApiResponse extends SignInError {
131330
131743
  status;
@@ -132460,208 +132873,26 @@ function configureServiceAuthCommands(program, open = serviceAccountsOpen(), hoo
132460
132873
  }
132461
132874
 
132462
132875
  // packages/omo-native/device-service-handoff.ts
132876
+ init_src6();
132877
+ init_hand_device_keys();
132878
+ init_local_only();
132463
132879
  import { existsSync as existsSync67 } from "node:fs";
132464
-
132465
- // packages/device-service-core/src/index.ts
132466
- init_device_service2();
132467
-
132468
- // packages/device-service-core/src/delivery-consumer.ts
132469
- init_client4();
132470
- init_background_transport();
132471
- init_device_service2();
132472
- // packages/device-service-core/src/bootstrap.ts
132473
- import { existsSync as existsSync66 } from "node:fs";
132474
- init_device_service2();
132475
-
132476
- // packages/device-service-core/src/hand-device-keys.ts
132477
- init_device_service2();
132478
- import { existsSync as existsSync65 } from "node:fs";
132479
- var DEAD_ENDPOINT_CODES = new Set(["ENOENT", "ECONNREFUSED", "ECONNRESET", "EPIPE"]);
132480
- var connectFailure = (error) => {
132481
- const detail = error instanceof Error ? error.message : String(error);
132482
- if (error instanceof LocalApiError) {
132483
- if (error.code === "refused" || error.code === "server_proof_invalid")
132484
- return { cause: "refused", detail };
132485
- if (error.code === "insecure_state_dir")
132486
- return { cause: "unreadable", detail };
132487
- if (error.code === "handshake_timeout" || error.code === "request_timeout")
132488
- return { cause: "timed_out", detail };
132489
- return { cause: "failed", detail };
132490
- }
132491
- const code = error instanceof Error && "code" in error ? String(error.code) : "";
132492
- return { cause: DEAD_ENDPOINT_CODES.has(code) ? "dead_endpoint" : "failed", detail };
132493
- };
132494
- var connectOrNotRunning = async (connect, log) => {
132495
- try {
132496
- return await connect();
132497
- } catch (error) {
132498
- const { cause, detail } = connectFailure(error);
132499
- log?.(`OmO device service: ${cause}, treated as not running (${detail}).`);
132500
- return "not_running";
132501
- }
132502
- };
132503
- var adopted = (status) => status.device !== null && status.state !== "sign_in_required";
132504
- var handDeviceKeys = async (options) => {
132505
- if (!existsSync65(deviceServiceEndpointPath(options.stateDir)))
132506
- return "not_running";
132507
- const service = await connectOrNotRunning(options.connect, options.log);
132508
- if (service === "not_running")
132509
- return "not_running";
132510
- try {
132511
- if (options.when === "not_adopted" && adopted(await service.status()))
132512
- return "already_adopted";
132513
- await service.adopt(options.credential);
132514
- return "adopted";
132515
- } finally {
132516
- service.close();
132517
- }
132518
- };
132519
-
132520
- // packages/device-service-core/src/bootstrap.ts
132521
- init_version2();
132522
- var forgetDeviceService = async (options) => {
132523
- if (!existsSync66(deviceServiceEndpointPath(options.stateDir)))
132524
- return "not_running";
132525
- const service = await connectOrNotRunning(options.connect, options.log);
132526
- if (service === "not_running")
132527
- return "not_running";
132528
- try {
132529
- await service.forget();
132530
- } finally {
132531
- service.close();
132532
- }
132533
- return "forgotten";
132534
- };
132535
- // packages/device-service-core/src/cold-wake/host.ts
132536
- var UNREPAIRABLE = new Set(["EPERM", "EACCES", "EROFS"]);
132537
-
132538
- // packages/device-service-core/src/cold-wake/service-table.ts
132539
- var SERVICE_TABLE_ENV = "OMO_RELAYD_SERVICES";
132540
-
132541
- // packages/device-service-core/src/cold-wake/darwin.ts
132542
- var TABLE_KEY = `EnvironmentVariables.${SERVICE_TABLE_ENV}`;
132543
- // packages/device-service-core/src/release/acquire.ts
132544
- init_access();
132545
- init_dacl();
132546
-
132547
- // packages/device-service-core/src/release/windows-dacl.ts
132548
- init_errors4();
132549
- init_dacl();
132550
- var SID_TOKEN_SCRIPT = String.raw`
132551
- $ErrorActionPreference = 'Stop'
132552
- (New-Object System.Security.AccessControl.RawSecurityDescriptor("O:$env:LA_SID")).GetSddlForm('Owner')
132553
- `;
132554
- var userSidToken = async (userSid, run = runPowerShell) => {
132555
- const { code, out } = await run(SID_TOKEN_SCRIPT, { LA_SID: userSid });
132556
- const match = code === 0 ? /^O:(S-1-\d+(?:-\d+)+|[A-Z]{2})$/.exec(out.trim()) : null;
132557
- return match?.[1];
132558
- };
132559
- var aliasedDaclVerdict = (dacl, userSid, kind, userAlias) => {
132560
- const asSid = (token) => userAlias !== undefined && token === userAlias ? userSid : token;
132561
- return exactDaclVerdict({ ...dacl, owner: asSid(dacl.owner), aces: dacl.aces.map((ace) => ({ ...ace, sid: asSid(ace.sid) })) }, userSid, kind);
132562
- };
132563
- var verifyExactDacl2 = async (path, userSid, kind, run = runPowerShell) => {
132564
- let dacl;
132565
- try {
132566
- dacl = await describeDacl(path, run);
132567
- } catch (error) {
132568
- if (error instanceof LocalApiError)
132569
- return false;
132570
- throw error;
132571
- }
132572
- return aliasedDaclVerdict(dacl, userSid, kind, await userSidToken(userSid, run));
132573
- };
132574
- var windowsSecureFile2 = (userSid, run = runPowerShell) => async (path, kind) => {
132575
- const target = kind === "dir" ? "dir" : "file";
132576
- await applyExactDacl(path, userSid, target, run);
132577
- if (!await verifyExactDacl2(path, userSid, target, run))
132578
- throw new LocalApiError("insecure_state_dir", "the DACL is not exactly one ACE for the user");
132579
- };
132580
-
132581
- // packages/device-service-core/src/release/release-assets.ts
132582
- init_version2();
132583
- var MANIFEST = "latest.json";
132584
- var CHECKSUMS_MAX_BYTES = 64 * 1024;
132585
- var MANIFEST_MAX_BYTES = 4 * 1024;
132586
- var BINARY_MAX_BYTES = 512 * 1024 * 1024;
132587
- var DEVICE_SERVICE_HOSTS = [
132588
- "darwin-arm64",
132589
- "darwin-x64",
132590
- "linux-x64",
132591
- "linux-arm64",
132592
- "windows-x64",
132593
- "windows-arm64"
132594
- ];
132595
- var deviceServiceAssetName = (host) => host.startsWith("windows-") ? `omo-device-service-${host}.exe` : `omo-device-service-${host}`;
132596
- var RELEASE_FILES = new Set([MANIFEST, ...DEVICE_SERVICE_HOSTS.map(deviceServiceAssetName)]);
132597
-
132598
- // packages/device-service-core/src/strict-ed25519/strict-ed25519.ts
132599
- var P = (1n << 255n) - 19n;
132600
- var L = (1n << 252n) + 27742317777372353535851937790883648493n;
132601
- var mod = (n) => {
132602
- const r = n % P;
132603
- return r < 0n ? r + P : r;
132604
- };
132605
- var power = (base, exponent) => {
132606
- let result = 1n;
132607
- let b = mod(base);
132608
- for (let n = exponent;n > 0n; n >>= 1n) {
132609
- if (n & 1n)
132610
- result = mod(result * b);
132611
- b = mod(b * b);
132612
- }
132613
- return result;
132614
- };
132615
- var D = mod(-121665n * power(121666n, P - 2n));
132616
- var SQRT_MINUS_ONE = power(2n, (P - 1n) / 4n);
132617
- var keyCache = new Map;
132618
- // packages/device-service-core/src/release/release-key.json
132619
- var release_key_default = {
132620
- alg: "Ed25519",
132621
- public_keys_hex: ["6c6781a91888e3e5be10d1b27466319a7d5adf2a7d2b254f4118eda9cbcb4465", "ca9407b484a30ac7f09cb152455176f1e03fc6ca3446ff930bc7587215759016"]
132622
- };
132623
-
132624
- // packages/device-service-core/src/release/release-signature.ts
132625
- var HEX_KEY = /^[0-9a-f]{64}$/;
132626
- var parseReleaseKeySet = (value) => {
132627
- if (typeof value !== "object" || value === null || Array.isArray(value))
132628
- throw new Error("release key: not an object");
132629
- if (Object.keys(value).toSorted().join(",") !== "alg,public_keys_hex")
132630
- throw new Error("release key: fields must be exactly alg and public_keys_hex");
132631
- const alg = Reflect.get(value, "alg");
132632
- const hexes = Reflect.get(value, "public_keys_hex");
132633
- if (alg !== "Ed25519")
132634
- throw new Error("release key: alg must be Ed25519");
132635
- if (!Array.isArray(hexes))
132636
- throw new Error("release key: public_keys_hex must be an array");
132637
- if (new Set(hexes).size !== hexes.length)
132638
- throw new Error("release key: public_keys_hex must not repeat a key");
132639
- return hexes.map((hex) => {
132640
- if (typeof hex !== "string" || !HEX_KEY.test(hex))
132641
- throw new Error("release key: each public_keys_hex entry must be 64 lowercase hex characters");
132642
- return hex;
132643
- });
132644
- };
132645
- var DEVICE_SERVICE_RELEASE_KEYS = parseReleaseKeySet(release_key_default);
132646
-
132647
- // packages/device-service-core/src/release/acquire.ts
132648
- init_version2();
132649
- var platformSecure = process.platform === "win32" ? async (path, kind, origin) => windowsSecureFile2(await currentUserSid())(path, kind, origin) : posixSecureFile;
132650
- // packages/device-service-core/src/registrant.ts
132651
- init_device_service2();
132652
- var NONE2 = Symbol("none registered");
132653
-
132654
- // packages/device-service-core/src/index.ts
132655
- init_timers();
132656
132880
  // packages/omo-native/package.json
132657
132881
  var package_default4 = {
132658
132882
  name: "omo-ai",
132659
- version: "5.1.84",
132883
+ version: "5.1.86",
132660
132884
  type: "module",
132661
132885
  description: "OmO Native - the standalone omo command with the OMO extension built in: bun add -g omo-ai",
132662
132886
  bin: {
132663
132887
  omo: "bin/omo.js"
132664
132888
  },
132889
+ exports: {
132890
+ "./remote": {
132891
+ types: "./bin/lib/remote-sdk.generated.d.ts",
132892
+ default: "./bin/lib/remote-sdk.generated.js"
132893
+ },
132894
+ "./package.json": "./package.json"
132895
+ },
132665
132896
  files: [
132666
132897
  "bin",
132667
132898
  "plugin"
@@ -132759,7 +132990,7 @@ function cliDeviceServiceHandoff(options) {
132759
132990
  }
132760
132991
 
132761
132992
  // packages/omo-native/remote-entry.ts
132762
- init_device_service2();
132993
+ init_remote();
132763
132994
 
132764
132995
  // packages/memory-core/src/journal/fsync.ts
132765
132996
  var SKIPPABLE_SYNC_CODES = new Set(["ENOENT", "EISDIR", "EPERM", "EACCES", "EINVAL"]);
@@ -132773,7 +133004,7 @@ var ED25519_PKCS8_PREFIX = hexBytes("302e020100300506032b657004220420");
132773
133004
  var ED25519_SPKI_PREFIX = hexBytes("302a300506032b6570032100");
132774
133005
  // packages/memory-core/src/sync/crypto/anchor.ts
132775
133006
  var anchors = new WeakSet;
132776
- var candidates = new WeakSet;
133007
+ var candidates2 = new WeakSet;
132777
133008
  var bootstraps = new WeakSet;
132778
133009
 
132779
133010
  // packages/memory-core/src/sync/crypto/strict-ed25519/strict-ed25519.ts
@@ -132819,6 +133050,12 @@ var refreshAttemptSchema = object({
132819
133050
  state: _enum(["ready", "sent_unknown", "successor_received_uncommitted", "exhausted"])
132820
133051
  });
132821
133052
 
133053
+ // packages/omo-native/remote-bootstrap.ts
133054
+ init_src6();
133055
+
133056
+ // packages/omo-native/remote-cold-wake.ts
133057
+ init_src6();
133058
+
132822
133059
  // packages/omo-native/remote-session-args.ts
132823
133060
  init_fields();
132824
133061
 
@@ -132841,82 +133078,29 @@ var VERBS = [
132841
133078
  ...SESSION_VERBS
132842
133079
  ];
132843
133080
 
132844
- // packages/omo-native/remote-session-verbs.ts
132845
- init_relay_session_host();
132846
- init_operations();
132847
- init_relay_control();
132848
- init_device_service3();
132849
-
132850
- // packages/omo-senpi/src/components/remote/index.ts
132851
- init_codes();
132852
- init_factories();
132853
- init_seams();
132854
- init_address();
132855
-
132856
- // packages/omo-senpi/src/components/remote/device-address.ts
132857
- init_address();
132858
- init_errors5();
132859
- // packages/omo-senpi/src/components/thread/gateway/store.ts
132860
- init_constants6();
132861
-
132862
- // packages/omo-senpi/src/components/thread/gateway/session-args-schema.ts
132863
- var TYPES = new Set(["object", "string", "number", "integer", "boolean", "array", "null"]);
132864
- var ANNOTATIONS = new Set(["title", "description", "default", "examples"]);
132865
- var COUNTS = ["minLength", "maxLength", "minItems", "maxItems"];
132866
- var BOUNDS2 = ["minimum", "maximum", "exclusiveMinimum", "exclusiveMaximum"];
132867
- var KEYWORDS = new Set([
132868
- "type",
132869
- "properties",
132870
- "required",
132871
- "additionalProperties",
132872
- "enum",
132873
- "const",
132874
- "pattern",
132875
- "items",
132876
- "anyOf",
132877
- ...COUNTS,
132878
- ...BOUNDS2,
132879
- ...ANNOTATIONS
132880
- ]);
133081
+ // packages/omo-native/remote-cli.ts
133082
+ init_remote();
132881
133083
 
132882
- // packages/omo-native/remote-session-verbs.ts
132883
- init_provenance_resolver();
132884
- init_relay_transport();
133084
+ // packages/omo-native/remote-attach-presentation.ts
133085
+ init_outcome();
133086
+ var FORWARD_WAIT_MS = 60 * 60000;
132885
133087
 
132886
- // packages/omo-senpi/src/components/thread/gateway/engine.ts
132887
- init_addressing();
132888
- init_errors5();
132889
- init_fields();
132890
- init_constants6();
132891
- init_result2();
132892
- init_provenance_resolver();
133088
+ // packages/omo-native/remote-attach.ts
133089
+ var MAX_LINE_CHARS = 64 * 1024 * 1024;
132893
133090
 
132894
- // packages/omo-senpi/src/components/thread/gateway/local-transport.ts
132895
- init_errors5();
133091
+ // packages/omo-native/remote-local.ts
133092
+ init_remote();
132896
133093
 
132897
133094
  // packages/omo-native/remote-session-verbs.ts
132898
- init_address_book();
132899
- init_this_device();
132900
- init_thread_link();
132901
- init_thread_row();
133095
+ init_remote();
132902
133096
 
132903
- // packages/omo-native/bin/lib/package-paths.js
132904
- import { fileURLToPath as fileURLToPath9 } from "node:url";
132905
- var packageRoot = fileURLToPath9(new URL("../..", import.meta.url));
132906
-
132907
- // packages/omo-native/remote-session-verbs.ts
132908
- init_remote_ops();
133097
+ // packages/omo-native/remote-session-answer.ts
132909
133098
  var NO_SUCH_SESSION = new Set(["session_not_found", "unknown_session"]);
132910
133099
 
132911
- // packages/omo-native/remote-attach-presentation.ts
132912
- init_outcome();
132913
- var FORWARD_WAIT_MS = 60 * 60000;
132914
-
132915
- // packages/omo-native/remote-attach.ts
132916
- var MAX_LINE_CHARS = 64 * 1024 * 1024;
133100
+ // packages/omo-native/remote-session-open.ts
133101
+ init_remote();
132917
133102
 
132918
133103
  // packages/omo-native/remote-local.ts
132919
- init_device_service2();
132920
133104
  var READ_VERBS = new Set(["status", "devices", "sessions", "disable", "control", "wake"]);
132921
133105
 
132922
133106
  // packages/omo-native/remote-usage.ts
@@ -132988,10 +133172,6 @@ var USAGE_ENTRIES = [
132988
133172
  ];
132989
133173
  var REMOTE_USAGE = [USAGE_HEAD, ...USAGE_ENTRIES.map((entry) => entry.text)].join(`
132990
133174
  `);
132991
-
132992
- // packages/omo-native/remote-cli.ts
132993
- init_device_service3();
132994
-
132995
133175
  // packages/omo-native/remote-entry.ts
132996
133176
  var testSkipKey = Symbol.for("omo.test.skipRemoteLoginSetup");
132997
133177
 
@@ -133450,7 +133630,7 @@ function linkedWorktrees(records) {
133450
133630
  }
133451
133631
  // packages/omo-opencode/src/cli/worktree-sweep/sweep.ts
133452
133632
  import { existsSync as existsSync70 } from "node:fs";
133453
- import { stat as stat12 } from "node:fs/promises";
133633
+ import { stat as stat13 } from "node:fs/promises";
133454
133634
  import os7 from "node:os";
133455
133635
  import { normalize as normalize2 } from "node:path";
133456
133636
 
@@ -133522,7 +133702,7 @@ async function isOlderThan(worktreePath, days, now) {
133522
133702
  if (days <= 0)
133523
133703
  return false;
133524
133704
  try {
133525
- const stats = await stat12(worktreePath);
133705
+ const stats = await stat13(worktreePath);
133526
133706
  return now - stats.mtimeMs > days * DAY_MS;
133527
133707
  } catch {
133528
133708
  return false;