@heidi-dang/oh-my-opencode 3.12.4 → 3.13.0

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 (499) hide show
  1. package/README.md +61 -367
  2. package/dist/agents/atlas/agent.d.ts +1 -1
  3. package/dist/agents/atlas/default.d.ts +1 -1
  4. package/dist/agents/atlas/gemini.d.ts +1 -1
  5. package/dist/agents/atlas/gpt.d.ts +1 -1
  6. package/dist/agents/atlas/prompt-section-builder.d.ts +1 -1
  7. package/dist/agents/builtin-agents/atlas-agent.d.ts +4 -1
  8. package/dist/agents/builtin-agents/available-skills.d.ts +1 -1
  9. package/dist/agents/builtin-agents/general-agents.d.ts +4 -1
  10. package/dist/agents/builtin-agents/hephaestus-agent.d.ts +5 -1
  11. package/dist/agents/builtin-agents/model-resolution.d.ts +2 -0
  12. package/dist/agents/builtin-agents/resolve-file-uri.test.d.ts +1 -0
  13. package/dist/agents/builtin-agents/sisyphus-agent.d.ts +4 -1
  14. package/dist/agents/builtin-agents.d.ts +3 -3
  15. package/dist/agents/chat.d.ts +7 -0
  16. package/dist/agents/dynamic-agent-prompt-builder.test.d.ts +1 -0
  17. package/dist/agents/env-context.test.d.ts +1 -0
  18. package/dist/agents/hephaestus/agent.d.ts +19 -0
  19. package/dist/agents/hephaestus/agent.test.d.ts +1 -0
  20. package/dist/agents/hephaestus/gpt-5-3-codex.d.ts +21 -0
  21. package/dist/agents/hephaestus/gpt-5-4.d.ts +3 -0
  22. package/dist/agents/hephaestus/gpt.d.ts +3 -0
  23. package/dist/agents/hephaestus/index.d.ts +2 -0
  24. package/dist/agents/hephaestus.d.ts +1 -1
  25. package/dist/agents/index.d.ts +1 -1
  26. package/dist/agents/metis.d.ts +1 -1
  27. package/dist/agents/momus.d.ts +1 -1
  28. package/dist/agents/momus.test.d.ts +1 -0
  29. package/dist/agents/prometheus-prompt.test.d.ts +1 -0
  30. package/dist/agents/prompts/agent-role.d.ts +2 -0
  31. package/dist/agents/prompts/anti-patterns.d.ts +2 -0
  32. package/dist/agents/prompts/base-system.d.ts +1 -0
  33. package/dist/agents/prompts/execution-rules.d.ts +2 -0
  34. package/dist/agents/prompts/hard-blocks.d.ts +2 -0
  35. package/dist/agents/prompts/index.d.ts +6 -0
  36. package/dist/agents/{dynamic-agent-prompt-builder.d.ts → prompts/orchestration.d.ts} +2 -23
  37. package/dist/agents/prompts/skill-context.d.ts +2 -0
  38. package/dist/agents/runtime/action-validator.d.ts +31 -0
  39. package/dist/agents/runtime/agent-logger.d.ts +15 -0
  40. package/dist/agents/runtime/loop-guard.d.ts +2 -0
  41. package/dist/agents/runtime/verify-action.d.ts +58 -0
  42. package/dist/agents/sisyphus/default.d.ts +9 -0
  43. package/dist/agents/sisyphus/gemini.d.ts +20 -0
  44. package/dist/agents/sisyphus/gpt-5-4.d.ts +16 -0
  45. package/dist/agents/sisyphus/index.d.ts +11 -0
  46. package/dist/agents/sisyphus-junior/index.test.d.ts +1 -0
  47. package/dist/agents/sisyphus.d.ts +1 -1
  48. package/dist/agents/tool-restrictions.test.d.ts +1 -0
  49. package/dist/agents/types.d.ts +24 -6
  50. package/dist/agents/types.test.d.ts +1 -0
  51. package/dist/agents/utils.test.d.ts +1 -0
  52. package/dist/cli/cli-installer.test.d.ts +1 -0
  53. package/dist/cli/config-manager/write-omo-config.test.d.ts +1 -0
  54. package/dist/cli/config-manager.test.d.ts +1 -0
  55. package/dist/cli/doctor/checks/config.test.d.ts +1 -0
  56. package/dist/cli/doctor/checks/dependencies.test.d.ts +1 -0
  57. package/dist/cli/doctor/checks/edit-atomicity.d.ts +5 -0
  58. package/dist/cli/doctor/checks/issue-resolution.d.ts +7 -0
  59. package/dist/cli/doctor/checks/model-resolution.test.d.ts +1 -0
  60. package/dist/cli/doctor/checks/plan-compiler.d.ts +8 -0
  61. package/dist/cli/doctor/checks/progress.d.ts +8 -0
  62. package/dist/cli/doctor/checks/run-state-watchdog.d.ts +2 -0
  63. package/dist/cli/doctor/checks/system-loaded-version.test.d.ts +1 -0
  64. package/dist/cli/doctor/checks/system.test.d.ts +1 -0
  65. package/dist/cli/doctor/checks/tool-contract.d.ts +8 -0
  66. package/dist/cli/doctor/checks/tool-metadata.d.ts +2 -0
  67. package/dist/cli/doctor/constants.d.ts +3 -0
  68. package/dist/cli/doctor/format-default.test.d.ts +1 -0
  69. package/dist/cli/doctor/formatter.test.d.ts +1 -0
  70. package/dist/cli/doctor/runner.test.d.ts +1 -0
  71. package/dist/cli/doctor/types.d.ts +3 -0
  72. package/dist/cli/index.js +2542 -214
  73. package/dist/cli/index.test.d.ts +1 -0
  74. package/dist/cli/install.test.d.ts +1 -0
  75. package/dist/cli/mcp-oauth/index.test.d.ts +1 -0
  76. package/dist/cli/mcp-oauth/login.test.d.ts +1 -0
  77. package/dist/cli/mcp-oauth/logout.test.d.ts +1 -0
  78. package/dist/cli/mcp-oauth/status.test.d.ts +1 -0
  79. package/dist/cli/model-fallback.test.d.ts +1 -0
  80. package/dist/cli/provider-model-id-transform.test.d.ts +1 -0
  81. package/dist/cli/run/completion-continuation.test.d.ts +1 -0
  82. package/dist/cli/run/completion-verbose-logging.test.d.ts +1 -0
  83. package/dist/cli/run/completion.test.d.ts +1 -0
  84. package/dist/cli/run/continuation-state-marker.test.d.ts +1 -0
  85. package/dist/cli/run/event-handlers.test.d.ts +1 -0
  86. package/dist/cli/run/events.test.d.ts +1 -0
  87. package/dist/cli/run/integration.test.d.ts +1 -0
  88. package/dist/cli/run/json-output.test.d.ts +1 -0
  89. package/dist/cli/run/message-part-delta.test.d.ts +1 -0
  90. package/dist/cli/run/on-complete-hook.test.d.ts +1 -0
  91. package/dist/cli/run/opencode-binary-resolver.test.d.ts +1 -0
  92. package/dist/cli/run/poll-for-completion.test.d.ts +1 -0
  93. package/dist/cli/run/runner.test.d.ts +1 -0
  94. package/dist/cli/run/server-connection.test.d.ts +1 -0
  95. package/dist/cli/run/session-resolver.test.d.ts +1 -0
  96. package/dist/cli/run/stdin-suppression.test.d.ts +1 -0
  97. package/dist/cli/run/timestamp-output.test.d.ts +1 -0
  98. package/dist/config/schema/agent-names.d.ts +6 -3
  99. package/dist/config/schema/agent-overrides.d.ts +150 -30
  100. package/dist/config/schema/background-task.test.d.ts +1 -0
  101. package/dist/config/schema/categories.d.ts +21 -3
  102. package/dist/config/schema/categories.test.d.ts +1 -0
  103. package/dist/config/schema/fallback-models.d.ts +11 -1
  104. package/dist/config/schema/hooks.d.ts +7 -0
  105. package/dist/config/schema/oh-my-opencode-config.d.ts +151 -29
  106. package/dist/config/schema.test.d.ts +1 -0
  107. package/dist/create-hooks.d.ts +11 -1
  108. package/dist/create-managers.d.ts +2 -0
  109. package/dist/create-tools.d.ts +1 -1
  110. package/dist/features/background-agent/compaction-aware-message-resolver.test.d.ts +1 -0
  111. package/dist/features/background-agent/concurrency.test.d.ts +1 -0
  112. package/dist/features/background-agent/error-classifier.test.d.ts +1 -0
  113. package/dist/features/background-agent/fallback-retry-handler.test.d.ts +1 -0
  114. package/dist/features/background-agent/manager.d.ts +13 -0
  115. package/dist/features/background-agent/manager.polling.test.d.ts +1 -0
  116. package/dist/features/background-agent/manager.test.d.ts +1 -0
  117. package/dist/features/background-agent/process-cleanup.test.d.ts +1 -0
  118. package/dist/features/background-agent/session-idle-event-handler.test.d.ts +1 -0
  119. package/dist/features/background-agent/spawner/parent-directory-resolver.test.d.ts +1 -0
  120. package/dist/features/background-agent/spawner.test.d.ts +1 -0
  121. package/dist/features/background-agent/task-history.test.d.ts +1 -0
  122. package/dist/features/background-agent/task-poller.test.d.ts +1 -0
  123. package/dist/features/background-agent/types.d.ts +9 -4
  124. package/dist/features/boulder-state/storage.test.d.ts +1 -0
  125. package/dist/features/builtin-commands/commands.test.d.ts +1 -0
  126. package/dist/features/builtin-commands/templates/stop-continuation.test.d.ts +1 -0
  127. package/dist/features/builtin-skills/skills/git/git-commit.d.ts +2 -0
  128. package/dist/features/builtin-skills/skills/git/git-history.d.ts +1 -0
  129. package/dist/features/builtin-skills/skills/git/git-push-pr.d.ts +1 -0
  130. package/dist/features/builtin-skills/skills/git/git-rebase.d.ts +1 -0
  131. package/dist/features/builtin-skills/skills/git/git-shared.d.ts +2 -0
  132. package/dist/features/builtin-skills/skills.test.d.ts +1 -0
  133. package/dist/features/claude-code-mcp-loader/loader.test.d.ts +1 -0
  134. package/dist/features/claude-code-session-state/state.d.ts +4 -0
  135. package/dist/features/claude-code-session-state/state.test.d.ts +1 -0
  136. package/dist/features/claude-tasks/session-storage.test.d.ts +1 -0
  137. package/dist/features/claude-tasks/storage.test.d.ts +1 -0
  138. package/dist/features/claude-tasks/types.test.d.ts +1 -0
  139. package/dist/features/context-injector/collector.test.d.ts +1 -0
  140. package/dist/features/context-injector/injector.test.d.ts +1 -0
  141. package/dist/features/hook-message-injector/injector.d.ts +2 -0
  142. package/dist/features/hook-message-injector/injector.test.d.ts +1 -0
  143. package/dist/features/issue-resolution/state.d.ts +12 -0
  144. package/dist/features/issue-resolution/tests/integration.test.d.ts +1 -0
  145. package/dist/features/mcp-oauth/callback-server.test.d.ts +1 -0
  146. package/dist/features/mcp-oauth/dcr.test.d.ts +1 -0
  147. package/dist/features/mcp-oauth/discovery.test.d.ts +1 -0
  148. package/dist/features/mcp-oauth/provider.test.d.ts +1 -0
  149. package/dist/features/mcp-oauth/resource-indicator.test.d.ts +1 -0
  150. package/dist/features/mcp-oauth/schema.test.d.ts +1 -0
  151. package/dist/features/mcp-oauth/step-up.test.d.ts +1 -0
  152. package/dist/features/mcp-oauth/storage.test.d.ts +1 -0
  153. package/dist/features/opencode-skill-loader/agents-skills-global.test.d.ts +1 -0
  154. package/dist/features/opencode-skill-loader/async-loader.test.d.ts +1 -0
  155. package/dist/features/opencode-skill-loader/blocking.test.d.ts +1 -0
  156. package/dist/features/opencode-skill-loader/config-source-discovery.test.d.ts +1 -0
  157. package/dist/features/opencode-skill-loader/loader.test.d.ts +1 -0
  158. package/dist/features/opencode-skill-loader/merger.test.d.ts +1 -0
  159. package/dist/features/opencode-skill-loader/skill-content.test.d.ts +1 -0
  160. package/dist/features/pr-state/storage.d.ts +10 -0
  161. package/dist/features/run-continuation-state/storage.test.d.ts +1 -0
  162. package/dist/features/run-state-watchdog/index.d.ts +1 -0
  163. package/dist/features/run-state-watchdog/manager.d.ts +31 -0
  164. package/dist/features/run-state-watchdog/manager.test.d.ts +1 -0
  165. package/dist/features/run-state-watchdog/reconnect.test.d.ts +1 -0
  166. package/dist/features/skill-mcp-manager/env-cleaner.test.d.ts +1 -0
  167. package/dist/features/skill-mcp-manager/manager.test.d.ts +1 -0
  168. package/dist/features/task-toast-manager/manager.d.ts +9 -0
  169. package/dist/features/task-toast-manager/manager.test.d.ts +1 -0
  170. package/dist/features/task-toast-manager/types.d.ts +5 -0
  171. package/dist/features/tmux-subagent/action-executor.test.d.ts +1 -0
  172. package/dist/features/tmux-subagent/decision-engine.test.d.ts +1 -0
  173. package/dist/features/tmux-subagent/layout-config.test.d.ts +1 -0
  174. package/dist/features/tmux-subagent/manager.test.d.ts +1 -0
  175. package/dist/features/tmux-subagent/polling-manager.test.d.ts +1 -0
  176. package/dist/features/tool-metadata-store/index.test.d.ts +1 -0
  177. package/dist/hooks/anthropic-context-window-limit-recovery/empty-content-recovery-sdk.test.d.ts +1 -0
  178. package/dist/hooks/anthropic-context-window-limit-recovery/executor.test.d.ts +1 -0
  179. package/dist/hooks/anthropic-context-window-limit-recovery/parser.test.d.ts +1 -0
  180. package/dist/hooks/anthropic-context-window-limit-recovery/pruning-deduplication.test.d.ts +1 -0
  181. package/dist/hooks/anthropic-context-window-limit-recovery/recovery-deduplication.test.d.ts +1 -0
  182. package/dist/hooks/anthropic-context-window-limit-recovery/recovery-hook.test.d.ts +1 -0
  183. package/dist/hooks/anthropic-context-window-limit-recovery/storage.test.d.ts +1 -0
  184. package/dist/hooks/anthropic-context-window-limit-recovery/summarize-retry-strategy.test.d.ts +1 -0
  185. package/dist/hooks/anthropic-effort/index.test.d.ts +1 -0
  186. package/dist/hooks/atlas/index.test.d.ts +1 -0
  187. package/dist/hooks/auto-slash-command/constants.test.d.ts +1 -0
  188. package/dist/hooks/auto-slash-command/detector.test.d.ts +1 -0
  189. package/dist/hooks/auto-slash-command/executor.test.d.ts +1 -0
  190. package/dist/hooks/auto-slash-command/index.test.d.ts +1 -0
  191. package/dist/hooks/auto-update-checker/checker/pinned-version-updater.test.d.ts +1 -0
  192. package/dist/hooks/auto-update-checker/checker/plugin-entry.test.d.ts +1 -0
  193. package/dist/hooks/auto-update-checker/checker.test.d.ts +1 -0
  194. package/dist/hooks/auto-update-checker/hook/background-update-check.test.d.ts +1 -0
  195. package/dist/hooks/auto-update-checker/hook.test.d.ts +1 -0
  196. package/dist/hooks/auto-update-checker/index.test.d.ts +1 -0
  197. package/dist/hooks/category-skill-reminder/formatter.d.ts +1 -1
  198. package/dist/hooks/category-skill-reminder/hook.d.ts +1 -1
  199. package/dist/hooks/category-skill-reminder/index.test.d.ts +1 -0
  200. package/dist/hooks/claude-code-hooks/execute-http-hook.test.d.ts +1 -0
  201. package/dist/hooks/claude-code-hooks/stop.test.d.ts +1 -0
  202. package/dist/hooks/claude-code-hooks/transcript.test.d.ts +1 -0
  203. package/dist/hooks/claude-code-hooks/user-prompt-submit.test.d.ts +1 -0
  204. package/dist/hooks/comment-checker/cli.test.d.ts +1 -0
  205. package/dist/hooks/comment-checker/hook.apply-patch.test.d.ts +1 -0
  206. package/dist/hooks/comment-checker/pending-calls.test.d.ts +1 -0
  207. package/dist/hooks/compaction-context-injector/index.test.d.ts +1 -0
  208. package/dist/hooks/compaction-todo-preserver/index.test.d.ts +1 -0
  209. package/dist/hooks/context-window-monitor.test.d.ts +1 -0
  210. package/dist/hooks/delegate-task-retry/index.test.d.ts +1 -0
  211. package/dist/hooks/directory-agents-injector/injector.test.d.ts +1 -0
  212. package/dist/hooks/directory-readme-injector/injector.test.d.ts +1 -0
  213. package/dist/hooks/edit-error-recovery/hook.d.ts +2 -1
  214. package/dist/hooks/edit-error-recovery/index.test.d.ts +1 -0
  215. package/dist/hooks/edit-safeguard/hook.d.ts +2 -0
  216. package/dist/hooks/execution-journal/hook.d.ts +19 -0
  217. package/dist/hooks/execution-journal/index.d.ts +1 -0
  218. package/dist/hooks/hashline-read-enhancer/index.test.d.ts +1 -0
  219. package/dist/hooks/index.d.ts +11 -3
  220. package/dist/hooks/json-error-recovery/index.test.d.ts +1 -0
  221. package/dist/hooks/keyword-detector/constants.d.ts +1 -0
  222. package/dist/hooks/keyword-detector/detector.d.ts +1 -1
  223. package/dist/hooks/keyword-detector/index.test.d.ts +1 -0
  224. package/dist/hooks/keyword-detector/issue.d.ts +2 -0
  225. package/dist/hooks/model-fallback/hook.test.d.ts +1 -0
  226. package/dist/hooks/no-hephaestus-non-gpt/index.test.d.ts +1 -0
  227. package/dist/hooks/no-sisyphus-gpt/index.test.d.ts +1 -0
  228. package/dist/hooks/non-interactive-env/index.test.d.ts +1 -0
  229. package/dist/hooks/plan-enforcement/hook.d.ts +29 -0
  230. package/dist/hooks/plan-enforcement/hook.test.d.ts +1 -0
  231. package/dist/hooks/plan-enforcement/index.d.ts +1 -0
  232. package/dist/hooks/preemptive-compaction.test.d.ts +1 -0
  233. package/dist/hooks/prometheus-md-only/index.test.d.ts +1 -0
  234. package/dist/hooks/question-label-truncator/index.test.d.ts +1 -0
  235. package/dist/hooks/ralph-loop/completion-handler.d.ts +14 -0
  236. package/dist/hooks/ralph-loop/completion-promise-detector.d.ts +1 -1
  237. package/dist/hooks/ralph-loop/completion-promise-detector.test.d.ts +1 -0
  238. package/dist/hooks/ralph-loop/constants.d.ts +1 -0
  239. package/dist/hooks/ralph-loop/index.test.d.ts +1 -0
  240. package/dist/hooks/ralph-loop/loop-state-controller.d.ts +2 -0
  241. package/dist/hooks/ralph-loop/ralph-loop-event-handler.d.ts +2 -0
  242. package/dist/hooks/ralph-loop/reset-strategy-race-condition.test.d.ts +1 -0
  243. package/dist/hooks/ralph-loop/session-event-handler.d.ts +12 -0
  244. package/dist/hooks/ralph-loop/types.d.ts +5 -1
  245. package/dist/hooks/ralph-loop/ulw-loop-verification.test.d.ts +1 -0
  246. package/dist/hooks/read-image-resizer/hook.test.d.ts +1 -0
  247. package/dist/hooks/read-image-resizer/image-dimensions.test.d.ts +1 -0
  248. package/dist/hooks/read-image-resizer/image-resizer.test.d.ts +1 -0
  249. package/dist/hooks/rules-injector/finder.test.d.ts +1 -0
  250. package/dist/hooks/rules-injector/injector.test.d.ts +1 -0
  251. package/dist/hooks/rules-injector/output-path.test.d.ts +1 -0
  252. package/dist/hooks/rules-injector/parser.test.d.ts +1 -0
  253. package/dist/hooks/run-state-watchdog/hook.d.ts +5 -0
  254. package/dist/hooks/run-state-watchdog/index.d.ts +1 -0
  255. package/dist/hooks/runtime-enforcement/hook.d.ts +10 -0
  256. package/dist/hooks/runtime-enforcement/hook.test.d.ts +1 -0
  257. package/dist/hooks/runtime-enforcement/index.d.ts +1 -0
  258. package/dist/hooks/runtime-enforcement/synthetic-injection.test.d.ts +1 -0
  259. package/dist/hooks/runtime-fallback/index.test.d.ts +1 -0
  260. package/dist/hooks/semantic-loop-guard/hook.d.ts +10 -0
  261. package/dist/hooks/semantic-loop-guard/hook.test.d.ts +1 -0
  262. package/dist/hooks/semantic-loop-guard/index.d.ts +1 -0
  263. package/dist/hooks/session-notification-input-needed.test.d.ts +1 -0
  264. package/dist/hooks/session-notification.test.d.ts +1 -0
  265. package/dist/hooks/session-recovery/detect-error-type.test.d.ts +1 -0
  266. package/dist/hooks/session-recovery/index.test.d.ts +1 -0
  267. package/dist/hooks/session-recovery/recover-empty-content-message-sdk.test.d.ts +1 -0
  268. package/dist/hooks/session-recovery/resume.test.d.ts +1 -0
  269. package/dist/hooks/session-recovery/storage/readers-from-sdk.test.d.ts +1 -0
  270. package/dist/hooks/start-work/index.test.d.ts +1 -0
  271. package/dist/hooks/start-work/parse-user-request.test.d.ts +1 -0
  272. package/dist/hooks/start-work/worktree-detector.test.d.ts +1 -0
  273. package/dist/hooks/stop-continuation-guard/index.test.d.ts +1 -0
  274. package/dist/hooks/task-reminder/index.test.d.ts +1 -0
  275. package/dist/hooks/task-resume-info/index.test.d.ts +1 -0
  276. package/dist/hooks/tasks-todowrite-disabler/index.test.d.ts +1 -0
  277. package/dist/hooks/think-mode/index.test.d.ts +1 -0
  278. package/dist/hooks/think-mode/switcher.test.d.ts +1 -0
  279. package/dist/hooks/todo-continuation-enforcer/continuation-injection.test.d.ts +1 -0
  280. package/dist/hooks/todo-continuation-enforcer/pending-question-detection.test.d.ts +1 -0
  281. package/dist/hooks/todo-continuation-enforcer/todo-continuation-enforcer.test.d.ts +1 -0
  282. package/dist/hooks/tool-contract/hook.d.ts +19 -0
  283. package/dist/hooks/tool-contract/hook.test.d.ts +1 -0
  284. package/dist/hooks/tool-contract/index.d.ts +1 -0
  285. package/dist/hooks/tool-output-truncator.test.d.ts +1 -0
  286. package/dist/hooks/unstable-agent-babysitter/index.test.d.ts +1 -0
  287. package/dist/hooks/write-existing-file-guard/index.test.d.ts +1 -0
  288. package/dist/hooks/xai-usage-patch/hook.d.ts +20 -0
  289. package/dist/hooks/xai-usage-patch/hook.test.d.ts +1 -0
  290. package/dist/index.compaction-model-agnostic.static.test.d.ts +1 -0
  291. package/dist/index.js +4980 -14453
  292. package/dist/index.test.d.ts +1 -0
  293. package/dist/mcp/index.test.d.ts +1 -0
  294. package/dist/mcp/websearch.test.d.ts +1 -0
  295. package/dist/oh-my-opencode.schema.json +622 -15
  296. package/dist/plugin/available-categories.d.ts +1 -1
  297. package/dist/plugin/chat-headers.test.d.ts +1 -0
  298. package/dist/plugin/chat-message.test.d.ts +1 -0
  299. package/dist/plugin/chat-params.test.d.ts +1 -0
  300. package/dist/plugin/event.model-fallback.test.d.ts +1 -0
  301. package/dist/plugin/event.test.d.ts +1 -0
  302. package/dist/plugin/hooks/create-core-hooks.d.ts +10 -0
  303. package/dist/plugin/hooks/create-session-hooks.d.ts +4 -1
  304. package/dist/plugin/hooks/create-skill-hooks.d.ts +1 -1
  305. package/dist/plugin/hooks/create-tool-guard-hooks.d.ts +7 -1
  306. package/dist/plugin/recent-synthetic-idles.test.d.ts +1 -0
  307. package/dist/plugin/session-agent-resolver.test.d.ts +1 -0
  308. package/dist/plugin/session-status-normalizer.test.d.ts +1 -0
  309. package/dist/plugin/skill-context.d.ts +1 -1
  310. package/dist/plugin/tool-execute-before-session-notification.test.d.ts +1 -0
  311. package/dist/plugin/tool-execute-before.test.d.ts +1 -0
  312. package/dist/plugin/tool-normalization.test.d.ts +1 -0
  313. package/dist/plugin/tool-registry.d.ts +1 -1
  314. package/dist/plugin/truth-model-integration.test.d.ts +1 -0
  315. package/dist/plugin/ultrawork-db-model-override.test.d.ts +1 -0
  316. package/dist/plugin/ultrawork-model-override.test.d.ts +1 -0
  317. package/dist/plugin-config.test.d.ts +1 -0
  318. package/dist/plugin-handlers/agent-key-remapper.test.d.ts +1 -0
  319. package/dist/plugin-handlers/config-handler-formatter.test.d.ts +1 -0
  320. package/dist/plugin-handlers/config-handler.test.d.ts +1 -0
  321. package/dist/plugin-handlers/mcp-config-handler.test.d.ts +1 -0
  322. package/dist/plugin-handlers/plan-model-inheritance.test.d.ts +1 -0
  323. package/dist/plugin-handlers/prometheus-agent-config-builder.d.ts +3 -2
  324. package/dist/plugin-handlers/tool-config-handler.test.d.ts +1 -0
  325. package/dist/runtime/journal.d.ts +33 -0
  326. package/dist/runtime/plan-compiler.d.ts +20 -0
  327. package/dist/runtime/plan-compiler.test.d.ts +1 -0
  328. package/dist/runtime/startup-validation.d.ts +7 -0
  329. package/dist/runtime/state-ledger.d.ts +52 -0
  330. package/dist/runtime/tools/complete-task.d.ts +4 -0
  331. package/dist/runtime/tools/fs-safe.contract.test.d.ts +1 -0
  332. package/dist/runtime/tools/fs-safe.d.ts +1 -0
  333. package/dist/runtime/tools/gh-safe.d.ts +1 -0
  334. package/dist/runtime/tools/git-safe.d.ts +1 -0
  335. package/dist/runtime/tools/index.d.ts +8 -0
  336. package/dist/runtime/tools/plan.d.ts +3 -0
  337. package/dist/runtime/tools/query-ledger.d.ts +3 -0
  338. package/dist/runtime/tools/registry.d.ts +8 -0
  339. package/dist/runtime/tools/report-issue-verification.d.ts +1 -0
  340. package/dist/runtime/tools/verify.d.ts +1 -0
  341. package/dist/runtime/truth-model.test.d.ts +1 -0
  342. package/dist/runtime/vcs-detection.test.d.ts +1 -0
  343. package/dist/shared/active-task-storage.d.ts +15 -0
  344. package/dist/shared/agent-config-integration.test.d.ts +1 -0
  345. package/dist/shared/agent-display-names.test.d.ts +1 -0
  346. package/dist/shared/agent-variant.test.d.ts +1 -0
  347. package/dist/shared/claude-config-dir.test.d.ts +1 -0
  348. package/dist/shared/connected-providers-cache.test.d.ts +1 -0
  349. package/dist/shared/deep-merge.test.d.ts +1 -0
  350. package/dist/shared/dynamic-truncator.test.d.ts +1 -0
  351. package/dist/shared/external-plugin-detector.test.d.ts +1 -0
  352. package/dist/shared/file-utils.test.d.ts +1 -0
  353. package/dist/shared/first-message-variant.test.d.ts +1 -0
  354. package/dist/shared/frontmatter.test.d.ts +1 -0
  355. package/dist/shared/git-worktree/collect-git-diff-stats.test.d.ts +1 -0
  356. package/dist/shared/git-worktree/git-worktree.test.d.ts +1 -0
  357. package/dist/shared/git-worktree/parse-status-porcelain-line.test.d.ts +1 -0
  358. package/dist/shared/index.d.ts +2 -0
  359. package/dist/shared/jsonc-parser.test.d.ts +1 -0
  360. package/dist/shared/merge-categories.test.d.ts +1 -0
  361. package/dist/shared/migration.test.d.ts +1 -0
  362. package/dist/shared/model-availability.d.ts +6 -0
  363. package/dist/shared/model-availability.test.d.ts +1 -0
  364. package/dist/shared/model-error-classifier.d.ts +5 -0
  365. package/dist/shared/model-error-classifier.test.d.ts +1 -0
  366. package/dist/shared/model-format-normalizer.test.d.ts +1 -0
  367. package/dist/shared/model-normalization.test.d.ts +1 -0
  368. package/dist/shared/model-requirements.d.ts +6 -0
  369. package/dist/shared/model-requirements.test.d.ts +1 -0
  370. package/dist/shared/model-resolution-acceptance.test.d.ts +1 -0
  371. package/dist/shared/model-resolution-pipeline.d.ts +5 -1
  372. package/dist/shared/model-resolution-pipeline.test.d.ts +1 -0
  373. package/dist/shared/model-resolution-tracker.d.ts +17 -0
  374. package/dist/shared/model-resolution-types.d.ts +7 -1
  375. package/dist/shared/model-resolver.d.ts +10 -3
  376. package/dist/shared/model-resolver.test.d.ts +1 -0
  377. package/dist/shared/model-suggestion-retry.test.d.ts +1 -0
  378. package/dist/shared/normalize-sdk-response.test.d.ts +1 -0
  379. package/dist/shared/opencode-config-dir.test.d.ts +1 -0
  380. package/dist/shared/opencode-http-api.test.d.ts +1 -0
  381. package/dist/shared/opencode-message-dir.test.d.ts +1 -0
  382. package/dist/shared/opencode-server-auth.test.d.ts +1 -0
  383. package/dist/shared/opencode-storage-detection.test.d.ts +1 -0
  384. package/dist/shared/opencode-version.test.d.ts +1 -0
  385. package/dist/shared/pattern-matcher.test.d.ts +1 -0
  386. package/dist/shared/permission-compat.test.d.ts +1 -0
  387. package/dist/shared/plugin-command-discovery.test.d.ts +1 -0
  388. package/dist/shared/port-utils.test.d.ts +1 -0
  389. package/dist/shared/prompt-tools.test.d.ts +1 -0
  390. package/dist/shared/read-permission-tracker.d.ts +15 -0
  391. package/dist/shared/safe-create-hook.test.d.ts +1 -0
  392. package/dist/shared/session-cursor.test.d.ts +1 -0
  393. package/dist/shared/session-directory-resolver.test.d.ts +1 -0
  394. package/dist/shared/session-model-state.test.d.ts +1 -0
  395. package/dist/shared/session-tools-store.test.d.ts +1 -0
  396. package/dist/shared/shell-env.test.d.ts +1 -0
  397. package/dist/shared/skill-path-resolver.test.d.ts +1 -0
  398. package/dist/shared/system-directive.test.d.ts +1 -0
  399. package/dist/shared/tmux/tmux-utils/layout.test.d.ts +1 -0
  400. package/dist/shared/tmux/tmux-utils.test.d.ts +1 -0
  401. package/dist/shared/tool-name.test.d.ts +1 -0
  402. package/dist/shared/truncate-description.test.d.ts +1 -0
  403. package/dist/shared/verify-task-completion.d.ts +1 -0
  404. package/dist/tools/background-task/create-background-output.blocking.test.d.ts +1 -0
  405. package/dist/tools/background-task/create-background-task.test.d.ts +1 -0
  406. package/dist/tools/background-task/tools.test.d.ts +1 -0
  407. package/dist/tools/call-omo-agent/background-agent-executor.test.d.ts +1 -0
  408. package/dist/tools/call-omo-agent/background-executor.test.d.ts +1 -0
  409. package/dist/tools/call-omo-agent/session-creator.test.d.ts +1 -0
  410. package/dist/tools/call-omo-agent/subagent-session-creator.test.d.ts +1 -0
  411. package/dist/tools/call-omo-agent/sync-executor.test.d.ts +1 -0
  412. package/dist/tools/call-omo-agent/tools.test.d.ts +1 -0
  413. package/dist/tools/delegate-task/background-continuation.test.d.ts +1 -0
  414. package/dist/tools/delegate-task/background-task.d.ts +1 -1
  415. package/dist/tools/delegate-task/background-task.test.d.ts +1 -0
  416. package/dist/tools/delegate-task/category-resolver.d.ts +1 -0
  417. package/dist/tools/delegate-task/category-resolver.test.d.ts +1 -0
  418. package/dist/tools/delegate-task/constants.d.ts +1 -1
  419. package/dist/tools/delegate-task/metadata-await.test.d.ts +1 -0
  420. package/dist/tools/delegate-task/metadata-model-unification.test.d.ts +1 -0
  421. package/dist/tools/delegate-task/model-selection.d.ts +2 -0
  422. package/dist/tools/delegate-task/subagent-resolver.d.ts +2 -1
  423. package/dist/tools/delegate-task/subagent-resolver.test.d.ts +1 -0
  424. package/dist/tools/delegate-task/sync-continuation.test.d.ts +1 -0
  425. package/dist/tools/delegate-task/sync-poll-timeout.test.d.ts +1 -0
  426. package/dist/tools/delegate-task/sync-prompt-sender.d.ts +1 -0
  427. package/dist/tools/delegate-task/sync-prompt-sender.test.d.ts +1 -0
  428. package/dist/tools/delegate-task/sync-result-fetcher.test.d.ts +1 -0
  429. package/dist/tools/delegate-task/sync-session-poller.test.d.ts +1 -0
  430. package/dist/tools/delegate-task/sync-task.d.ts +1 -1
  431. package/dist/tools/delegate-task/sync-task.test.d.ts +1 -0
  432. package/dist/tools/delegate-task/timing.test.d.ts +1 -0
  433. package/dist/tools/delegate-task/token-limiter.test.d.ts +1 -0
  434. package/dist/tools/delegate-task/tools.test.d.ts +1 -0
  435. package/dist/tools/delegate-task/types.d.ts +1 -1
  436. package/dist/tools/delegate-task/unstable-agent-task.test.d.ts +1 -0
  437. package/dist/tools/delegate-task/unstable-agent-timeout.test.d.ts +1 -0
  438. package/dist/tools/glob/cli.test.d.ts +1 -0
  439. package/dist/tools/grep/downloader.test.d.ts +1 -0
  440. package/dist/tools/grep/result-formatter.test.d.ts +1 -0
  441. package/dist/tools/hashline-edit/diff-utils.test.d.ts +1 -0
  442. package/dist/tools/hashline-edit/edit-operations.test.d.ts +1 -0
  443. package/dist/tools/hashline-edit/edit-text-normalization.test.d.ts +1 -0
  444. package/dist/tools/hashline-edit/hash-computation.test.d.ts +1 -0
  445. package/dist/tools/hashline-edit/normalize-edits.test.d.ts +1 -0
  446. package/dist/tools/hashline-edit/tools.test.d.ts +1 -0
  447. package/dist/tools/hashline-edit/validation.test.d.ts +1 -0
  448. package/dist/tools/look-at/create-look-at-error-handling.test.d.ts +1 -0
  449. package/dist/tools/look-at/create-look-at-image-data.test.d.ts +1 -0
  450. package/dist/tools/look-at/create-look-at-model-passthrough.test.d.ts +1 -0
  451. package/dist/tools/look-at/create-look-at-sync-prompt.test.d.ts +1 -0
  452. package/dist/tools/look-at/create-look-at-unhandled-error.test.d.ts +1 -0
  453. package/dist/tools/look-at/image-converter.test.d.ts +1 -0
  454. package/dist/tools/look-at/mime-type-inference.test.d.ts +1 -0
  455. package/dist/tools/look-at/normalize-args.test.d.ts +1 -0
  456. package/dist/tools/look-at/session-poller.test.d.ts +1 -0
  457. package/dist/tools/look-at/tools.test.d.ts +7 -0
  458. package/dist/tools/look-at/validate-args.test.d.ts +1 -0
  459. package/dist/tools/lsp/client.test.d.ts +1 -0
  460. package/dist/tools/lsp/config.test.d.ts +1 -0
  461. package/dist/tools/lsp/lsp-client-wrapper.d.ts +3 -0
  462. package/dist/tools/lsp/lsp-process.test.d.ts +1 -0
  463. package/dist/tools/lsp/server-config-loader.test.d.ts +1 -0
  464. package/dist/tools/lsp/utils.test.d.ts +1 -0
  465. package/dist/tools/session-manager/storage.test.d.ts +1 -0
  466. package/dist/tools/session-manager/tools.test.d.ts +1 -0
  467. package/dist/tools/session-manager/utils.test.d.ts +1 -0
  468. package/dist/tools/skill/tools.test.agent-restriction.d.ts +1 -0
  469. package/dist/tools/skill/tools.test.d.ts +1 -0
  470. package/dist/tools/skill/tools.test.description.d.ts +1 -0
  471. package/dist/tools/skill/tools.test.mcp-schema.d.ts +1 -0
  472. package/dist/tools/skill/tools.test.ordering.d.ts +1 -0
  473. package/dist/tools/skill/tools.test.utils.d.ts +10 -0
  474. package/dist/tools/skill-mcp/builtin-mcp-hint.test.d.ts +1 -0
  475. package/dist/tools/skill-mcp/tools.test.d.ts +1 -0
  476. package/dist/tools/slashcommand/command-discovery.test.d.ts +1 -0
  477. package/dist/tools/slashcommand/command-output-formatter.test.d.ts +1 -0
  478. package/dist/tools/slashcommand/index.test.d.ts +1 -0
  479. package/dist/tools/task/task-create-input.test.d.ts +1 -0
  480. package/dist/tools/task/task-create.test.d.ts +1 -0
  481. package/dist/tools/task/task-delete-input.test.d.ts +1 -0
  482. package/dist/tools/task/task-get-input.test.d.ts +1 -0
  483. package/dist/tools/task/task-get.test.d.ts +1 -0
  484. package/dist/tools/task/task-list-input.test.d.ts +1 -0
  485. package/dist/tools/task/task-list.test.d.ts +1 -0
  486. package/dist/tools/task/task-schema-core.test.d.ts +1 -0
  487. package/dist/tools/task/task-schema-fields.test.d.ts +1 -0
  488. package/dist/tools/task/task-status.test.d.ts +1 -0
  489. package/dist/tools/task/task-update-input.test.d.ts +1 -0
  490. package/dist/tools/task/task-update.test.d.ts +1 -0
  491. package/dist/tools/task/todo-sync-all-fetch.test.d.ts +1 -0
  492. package/dist/tools/task/todo-sync-all-write.test.d.ts +1 -0
  493. package/dist/tools/task/todo-sync-sync.test.d.ts +1 -0
  494. package/dist/tools/task/todo-sync-update.test.d.ts +1 -0
  495. package/dist/tools/task/todo-sync.test.d.ts +1 -0
  496. package/dist/utils/context-trimmer.d.ts +21 -0
  497. package/dist/utils/safety-tool-result.d.ts +31 -0
  498. package/dist/utils/tool-contract-wrapper.d.ts +10 -0
  499. package/package.json +17 -16
@@ -1,3 +1,3 @@
1
- import type { AvailableCategory } from "../agents/dynamic-agent-prompt-builder";
1
+ import type { AvailableCategory } from "../agents/types";
2
2
  import type { OhMyOpenCodeConfig } from "../config";
3
3
  export declare function createAvailableCategories(pluginConfig: OhMyOpenCodeConfig): AvailableCategory[];
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -1,10 +1,12 @@
1
1
  import type { HookName, OhMyOpenCodeConfig } from "../../config";
2
2
  import type { PluginContext } from "../types";
3
3
  import type { ModelCacheState } from "../../plugin-state";
4
+ import type { RunStateWatchdogManager } from "../../features/run-state-watchdog";
4
5
  export declare function createCoreHooks(args: {
5
6
  ctx: PluginContext;
6
7
  pluginConfig: OhMyOpenCodeConfig;
7
8
  modelCacheState: ModelCacheState;
9
+ runStateWatchdogManager: RunStateWatchdogManager;
8
10
  isHookEnabled: (hookName: HookName) => boolean;
9
11
  safeHookEnabled: boolean;
10
12
  }): {
@@ -23,6 +25,12 @@ export declare function createCoreHooks(args: {
23
25
  hashlineReadEnhancer: ReturnType<typeof import("../../hooks").createHashlineReadEnhancerHook> | null;
24
26
  jsonErrorRecovery: ReturnType<typeof import("../../hooks").createJsonErrorRecoveryHook> | null;
25
27
  readImageResizer: ReturnType<typeof import("../../hooks").createReadImageResizerHook> | null;
28
+ executionJournal: ReturnType<typeof import("../../hooks").createExecutionJournalHook> | null;
29
+ toolContract: ReturnType<typeof import("../../hooks").createToolContractHook> | null;
30
+ runtimeEnforcement: ReturnType<typeof import("../../hooks").createRuntimeEnforcementHook> | null;
31
+ planEnforcement: ReturnType<typeof import("../../hooks").createPlanEnforcementHook> | null;
32
+ semanticLoopGuard: ReturnType<typeof import("../../hooks").createSemanticLoopGuardHook> | null;
33
+ editSafeguard: ReturnType<typeof import("../../hooks").createEditSafeguardHook> | null;
26
34
  contextWindowMonitor: ReturnType<typeof import("../../hooks").createContextWindowMonitorHook> | null;
27
35
  preemptiveCompaction: ReturnType<typeof import("../../hooks").createPreemptiveCompactionHook> | null;
28
36
  sessionRecovery: ReturnType<typeof import("../../hooks").createSessionRecoveryHook> | null;
@@ -46,4 +54,6 @@ export declare function createCoreHooks(args: {
46
54
  taskResumeInfo: ReturnType<typeof import("../../hooks").createTaskResumeInfoHook> | null;
47
55
  anthropicEffort: ReturnType<typeof import("../../hooks/anthropic-effort").createAnthropicEffortHook> | null;
48
56
  runtimeFallback: ReturnType<typeof import("../../hooks").createRuntimeFallbackHook> | null;
57
+ xaiUsagePatch: ReturnType<typeof import("../../hooks").createXaiUsagePatchHook> | null;
58
+ runStateWatchdog: ReturnType<typeof import("../../hooks").createRunStateWatchdogHook> | null;
49
59
  };
@@ -1,7 +1,7 @@
1
1
  import type { OhMyOpenCodeConfig, HookName } from "../../config";
2
2
  import type { ModelCacheState } from "../../plugin-state";
3
3
  import type { PluginContext } from "../types";
4
- import { createContextWindowMonitorHook, createSessionRecoveryHook, createSessionNotification, createThinkModeHook, createModelFallbackHook, createAnthropicContextWindowLimitRecoveryHook, createAutoUpdateCheckerHook, createAgentUsageReminderHook, createNonInteractiveEnvHook, createInteractiveBashSessionHook, createRalphLoopHook, createEditErrorRecoveryHook, createDelegateTaskRetryHook, createTaskResumeInfoHook, createStartWorkHook, createPrometheusMdOnlyHook, createSisyphusJuniorNotepadHook, createNoSisyphusGptHook, createNoHephaestusNonGptHook, createQuestionLabelTruncatorHook, createPreemptiveCompactionHook, createRuntimeFallbackHook } from "../../hooks";
4
+ import { createContextWindowMonitorHook, createSessionRecoveryHook, createSessionNotification, createThinkModeHook, createModelFallbackHook, createAnthropicContextWindowLimitRecoveryHook, createAutoUpdateCheckerHook, createAgentUsageReminderHook, createNonInteractiveEnvHook, createInteractiveBashSessionHook, createRalphLoopHook, createEditErrorRecoveryHook, createDelegateTaskRetryHook, createTaskResumeInfoHook, createStartWorkHook, createPrometheusMdOnlyHook, createSisyphusJuniorNotepadHook, createNoSisyphusGptHook, createNoHephaestusNonGptHook, createQuestionLabelTruncatorHook, createPreemptiveCompactionHook, createRuntimeFallbackHook, createXaiUsagePatchHook, createRunStateWatchdogHook } from "../../hooks";
5
5
  import { createAnthropicEffortHook } from "../../hooks/anthropic-effort";
6
6
  export type SessionHooks = {
7
7
  contextWindowMonitor: ReturnType<typeof createContextWindowMonitorHook> | null;
@@ -27,11 +27,14 @@ export type SessionHooks = {
27
27
  taskResumeInfo: ReturnType<typeof createTaskResumeInfoHook> | null;
28
28
  anthropicEffort: ReturnType<typeof createAnthropicEffortHook> | null;
29
29
  runtimeFallback: ReturnType<typeof createRuntimeFallbackHook> | null;
30
+ xaiUsagePatch: ReturnType<typeof createXaiUsagePatchHook> | null;
31
+ runStateWatchdog: ReturnType<typeof createRunStateWatchdogHook> | null;
30
32
  };
31
33
  export declare function createSessionHooks(args: {
32
34
  ctx: PluginContext;
33
35
  pluginConfig: OhMyOpenCodeConfig;
34
36
  modelCacheState: ModelCacheState;
37
+ runStateWatchdogManager: any;
35
38
  isHookEnabled: (hookName: HookName) => boolean;
36
39
  safeHookEnabled: boolean;
37
40
  }): SessionHooks;
@@ -1,4 +1,4 @@
1
- import type { AvailableSkill } from "../../agents/dynamic-agent-prompt-builder";
1
+ import type { AvailableSkill } from "../../agents/types";
2
2
  import type { HookName, OhMyOpenCodeConfig } from "../../config";
3
3
  import type { LoadedSkill } from "../../features/opencode-skill-loader/types";
4
4
  import type { PluginContext } from "../types";
@@ -1,7 +1,7 @@
1
1
  import type { HookName, OhMyOpenCodeConfig } from "../../config";
2
2
  import type { ModelCacheState } from "../../plugin-state";
3
3
  import type { PluginContext } from "../types";
4
- import { createCommentCheckerHooks, createToolOutputTruncatorHook, createDirectoryAgentsInjectorHook, createDirectoryReadmeInjectorHook, createEmptyTaskResponseDetectorHook, createRulesInjectorHook, createTasksTodowriteDisablerHook, createWriteExistingFileGuardHook, createHashlineReadEnhancerHook, createReadImageResizerHook, createJsonErrorRecoveryHook } from "../../hooks";
4
+ import { createCommentCheckerHooks, createToolOutputTruncatorHook, createDirectoryAgentsInjectorHook, createDirectoryReadmeInjectorHook, createEmptyTaskResponseDetectorHook, createRulesInjectorHook, createTasksTodowriteDisablerHook, createWriteExistingFileGuardHook, createHashlineReadEnhancerHook, createReadImageResizerHook, createJsonErrorRecoveryHook, createExecutionJournalHook, createToolContractHook, createRuntimeEnforcementHook, createPlanEnforcementHook, createSemanticLoopGuardHook, createEditSafeguardHook } from "../../hooks";
5
5
  export type ToolGuardHooks = {
6
6
  commentChecker: ReturnType<typeof createCommentCheckerHooks> | null;
7
7
  toolOutputTruncator: ReturnType<typeof createToolOutputTruncatorHook> | null;
@@ -14,6 +14,12 @@ export type ToolGuardHooks = {
14
14
  hashlineReadEnhancer: ReturnType<typeof createHashlineReadEnhancerHook> | null;
15
15
  jsonErrorRecovery: ReturnType<typeof createJsonErrorRecoveryHook> | null;
16
16
  readImageResizer: ReturnType<typeof createReadImageResizerHook> | null;
17
+ executionJournal: ReturnType<typeof createExecutionJournalHook> | null;
18
+ toolContract: ReturnType<typeof createToolContractHook> | null;
19
+ runtimeEnforcement: ReturnType<typeof createRuntimeEnforcementHook> | null;
20
+ planEnforcement: ReturnType<typeof createPlanEnforcementHook> | null;
21
+ semanticLoopGuard: ReturnType<typeof createSemanticLoopGuardHook> | null;
22
+ editSafeguard: ReturnType<typeof createEditSafeguardHook> | null;
17
23
  };
18
24
  export declare function createToolGuardHooks(args: {
19
25
  ctx: PluginContext;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -1,4 +1,4 @@
1
- import type { AvailableSkill } from "../agents/dynamic-agent-prompt-builder";
1
+ import type { AvailableSkill } from "../agents/types";
2
2
  import type { OhMyOpenCodeConfig } from "../config";
3
3
  import type { BrowserAutomationProvider } from "../config/schema/browser-automation";
4
4
  import type { LoadedSkill } from "../features/opencode-skill-loader/types";
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -1,4 +1,4 @@
1
- import type { AvailableCategory } from "../agents/dynamic-agent-prompt-builder";
1
+ import type { AvailableCategory } from "../agents/types";
2
2
  import type { OhMyOpenCodeConfig } from "../config";
3
3
  import type { PluginContext, ToolsRecord } from "./types";
4
4
  import type { Managers } from "../create-managers";
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -18,6 +18,7 @@ export declare function buildPrometheusAgentConfig(params: {
18
18
  configAgentPlan: Record<string, unknown> | undefined;
19
19
  pluginPrometheusOverride: PrometheusOverride | undefined;
20
20
  userCategories: Record<string, CategoryConfig> | undefined;
21
- currentModel: string | undefined;
22
- }): Promise<Record<string, unknown>>;
21
+ uiSelectedModel: string | undefined;
22
+ sessionModel: string | undefined;
23
+ } & Record<string, unknown>): Promise<Record<string, unknown>>;
23
24
  export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,33 @@
1
+ /**
2
+ * Execution Journal - Deterministic logging of every agent action and result.
3
+ *
4
+ * This provides replay debugging, anti-hallucination auditing,
5
+ * and high-quality training data generation.
6
+ */
7
+ export interface JournalEntry {
8
+ timestamp: string;
9
+ sessionID: string;
10
+ agent: string;
11
+ intent: "execute_tool" | "delegate" | "report" | "verify";
12
+ tool?: string;
13
+ args?: any;
14
+ stdout?: string;
15
+ stderr?: string;
16
+ verificationState?: boolean;
17
+ }
18
+ export declare class ExecutionJournal {
19
+ private static instance;
20
+ private journalPath;
21
+ private stream;
22
+ private constructor();
23
+ static getInstance(): ExecutionJournal;
24
+ /**
25
+ * Append directly to the JSONL format journal.
26
+ */
27
+ log(entry: Omit<JournalEntry, "timestamp">): void;
28
+ /**
29
+ * Close the journal stream cleanly.
30
+ */
31
+ close(): void;
32
+ }
33
+ export declare const journal: ExecutionJournal;
@@ -0,0 +1,20 @@
1
+ export interface ExecutionGraphNode {
2
+ id: string;
3
+ action: string;
4
+ dependencies: string[];
5
+ status: "pending" | "running" | "completed" | "failed";
6
+ }
7
+ export declare class PlanCompiler {
8
+ private static instance;
9
+ private sessionStates;
10
+ private constructor();
11
+ static getInstance(): PlanCompiler;
12
+ submit(sessionID: string, steps: Omit<ExecutionGraphNode, "status">[]): string;
13
+ getActiveStep(sessionID: string): ExecutionGraphNode | null;
14
+ markStepComplete(sessionID: string, id: string): void;
15
+ injectForcedReplan(sessionID: string, reason: string): void;
16
+ clear(sessionID: string): void;
17
+ resetAll(): void;
18
+ private injectVerificationDependencies;
19
+ }
20
+ export declare const compiler: PlanCompiler;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Runtime Startup Validation
3
+ *
4
+ * Ensures all safety-critical dependencies and environment configurations
5
+ * are present before the agent starts executing.
6
+ */
7
+ export declare function validateRuntimeEnvironment(): void;
@@ -0,0 +1,52 @@
1
+ /**
2
+ * State Ledger - The source of truth for all verified system state changes.
3
+ *
4
+ * Agents cannot claim success unless the State Ledger confirms the change.
5
+ * This completely eliminates hallucinated PR URLs, fake push confirmations,
6
+ * and assumed file writes.
7
+ */
8
+ export type LedgerEntryType = "file.write" | "file.delete" | "git.commit" | "git.push" | "git.pr" | "command.execute" | "package.install";
9
+ export interface LedgerEntry {
10
+ type: LedgerEntryType;
11
+ timestamp: number;
12
+ key: string;
13
+ success: boolean;
14
+ verified: boolean;
15
+ changedState: boolean;
16
+ stdout: string;
17
+ sessionID?: string;
18
+ metadata?: any;
19
+ }
20
+ export declare class StateLedger {
21
+ private static instance;
22
+ private entries;
23
+ private lastFlowStartTime;
24
+ private constructor();
25
+ static getInstance(): StateLedger;
26
+ /**
27
+ * Mark the absolute start of a new completion flow.
28
+ * All entries recorded before this timestamp will be ignored by has().
29
+ */
30
+ startNewFlow(): void;
31
+ /**
32
+ * Record a verified state change in the system.
33
+ */
34
+ record(type: LedgerEntryType, key: string, success: boolean, verified: boolean, changedState: boolean, stdout: string, metadata?: any, sessionID?: string): void;
35
+ /**
36
+ * Verify if a specific state change has actually occurred in the current flow.
37
+ */
38
+ has(type: LedgerEntryType, keyOrCondition: string | ((entry: LedgerEntry) => boolean)): boolean;
39
+ /**
40
+ * Get all entries of a specific type.
41
+ */
42
+ getEntries(type?: LedgerEntryType): LedgerEntry[];
43
+ /**
44
+ * Get the total number of state changes.
45
+ */
46
+ get count(): number;
47
+ /**
48
+ * Clear the ledger (usually for testing or a hard session reset).
49
+ */
50
+ clear(): void;
51
+ }
52
+ export declare const ledger: StateLedger;
@@ -0,0 +1,4 @@
1
+ export declare function createCompleteTaskTool(options?: {
2
+ client?: any;
3
+ backgroundManager?: any;
4
+ }): any;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export declare function createFsSafeTool(): any;
@@ -0,0 +1 @@
1
+ export declare function createGhSafeTool(): any;
@@ -0,0 +1 @@
1
+ export declare function createGitSafeTool(): any;
@@ -0,0 +1,8 @@
1
+ export { createGitSafeTool } from "./git-safe";
2
+ export { createFsSafeTool } from "./fs-safe";
3
+ export { createVerifyTool } from "./verify";
4
+ export { createSubmitPlanTool, createMarkStepCompleteTool, createUnlockPlanTool } from "./plan";
5
+ export { createQueryLedgerTool } from "./query-ledger";
6
+ export { createCompleteTaskTool } from "./complete-task";
7
+ export { createGhSafeTool } from "./gh-safe";
8
+ export { createReportIssueVerificationTool } from "./report-issue-verification";
@@ -0,0 +1,3 @@
1
+ export declare function createSubmitPlanTool(): any;
2
+ export declare function createMarkStepCompleteTool(): any;
3
+ export declare function createUnlockPlanTool(): any;
@@ -0,0 +1,3 @@
1
+ export declare function createQueryLedgerTool(options?: {
2
+ backgroundManager?: any;
3
+ }): any;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Centralized Deterministic Tool Registry
3
+ *
4
+ * Only tools registered here are allowed to be executed by the runtime.
5
+ * This prevents agents from calling unauthorized or arbitrary commands.
6
+ */
7
+ export declare const DETERMINISTIC_TOOLS: Record<string, (args?: any) => any>;
8
+ export declare function getToolFromRegistry(name: string): any;
@@ -0,0 +1 @@
1
+ export declare function createReportIssueVerificationTool(): any;
@@ -0,0 +1 @@
1
+ export declare function createVerifyTool(): any;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,15 @@
1
+ export interface ActiveTaskInfo {
2
+ id: string;
3
+ sessionID: string;
4
+ description: string;
5
+ agent: string;
6
+ status: string;
7
+ startedAt: string;
8
+ progress?: {
9
+ phase?: string;
10
+ percent?: number;
11
+ message?: string;
12
+ };
13
+ }
14
+ export declare function saveActiveTasks(tasks: ActiveTaskInfo[]): void;
15
+ export declare function readActiveTasks(): ActiveTaskInfo[];
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -33,6 +33,7 @@ export * from "./model-resolver";
33
33
  export { normalizeModel, normalizeModelID } from "./model-normalization";
34
34
  export { normalizeFallbackModels } from "./model-resolver";
35
35
  export { resolveModelPipeline } from "./model-resolution-pipeline";
36
+ export { modelResolutionTracker } from "./model-resolution-tracker";
36
37
  export type { ModelResolutionRequest, ModelResolutionProvenance, ModelResolutionResult, } from "./model-resolution-types";
37
38
  export * from "./model-availability";
38
39
  export * from "./fallback-model-availability";
@@ -55,3 +56,4 @@ export * from "./prompt-tools";
55
56
  export * from "./internal-initiator-marker";
56
57
  export * from "./plugin-command-discovery";
57
58
  export { SessionCategoryRegistry } from "./session-category-registry";
59
+ export { verifyTaskCompletionState } from "./verify-task-completion";
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -7,6 +7,12 @@ export declare function fuzzyMatchModel(target: string, available: Set<string>,
7
7
  * @returns true if model is available, false otherwise
8
8
  */
9
9
  export declare function isModelAvailable(targetModel: string, availableModels: Set<string>): boolean;
10
+ /**
11
+ * Perform a strict check for model support using the connected-providers cache.
12
+ * Returns true if the (providerID, modelID) pair is known to be supported.
13
+ * Returns true if the cache is missing (fail-open to allow for potentially stale cache).
14
+ */
15
+ export declare function isModelSupported(providerID: string, modelID: string): boolean;
10
16
  export declare function getConnectedProviders(client: any): Promise<string[]>;
11
17
  export declare function fetchAvailableModels(client?: any, options?: {
12
18
  connectedProviders?: string[] | null;
@@ -0,0 +1 @@
1
+ export {};
@@ -1,4 +1,9 @@
1
1
  import type { FallbackEntry } from "./model-requirements";
2
+ /**
3
+ * Returns true when the error is a deterministic "this model is not available on this provider" error.
4
+ * Used to emit richer UI messages and to distinguish unsupported-model from transient failures.
5
+ */
6
+ export declare function isUnsupportedModelError(error: unknown): boolean;
2
7
  export interface ErrorInfo {
3
8
  name?: string;
4
9
  message?: string;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -1,3 +1,4 @@
1
+ import type { OhMyOpenCodeConfig } from "../config";
1
2
  export type FallbackEntry = {
2
3
  providers: string[];
3
4
  model: string;
@@ -5,10 +6,15 @@ export type FallbackEntry = {
5
6
  };
6
7
  export type ModelRequirement = {
7
8
  fallbackChain: FallbackEntry[];
9
+ fallbackModel?: string;
8
10
  variant?: string;
9
11
  requiresModel?: string;
10
12
  requiresAnyModel?: boolean;
11
13
  requiresProvider?: string[];
12
14
  };
15
+ export declare function getAgentRequirement(config: OhMyOpenCodeConfig | undefined, agentName: string): ModelRequirement | undefined;
16
+ export declare function getCategoryRequirement(config: OhMyOpenCodeConfig | undefined, categoryName: string): ModelRequirement | undefined;
17
+ /** @deprecated Used strictly for transition - move to getAgentRequirement instead */
13
18
  export declare const AGENT_MODEL_REQUIREMENTS: Record<string, ModelRequirement>;
19
+ /** @deprecated Used strictly for transition - move to getCategoryRequirement instead */
14
20
  export declare const CATEGORY_MODEL_REQUIREMENTS: Record<string, ModelRequirement>;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -2,9 +2,12 @@ import type { FallbackEntry } from "./model-requirements";
2
2
  export type ModelResolutionRequest = {
3
3
  intent?: {
4
4
  uiSelectedModel?: string;
5
+ sessionModel?: string;
5
6
  userModel?: string;
7
+ userFallbackModel?: string;
6
8
  userFallbackModels?: string[];
7
9
  categoryDefaultModel?: string;
10
+ categoryFallbackModel?: string;
8
11
  };
9
12
  constraints: {
10
13
  availableModels: Set<string>;
@@ -13,9 +16,10 @@ export type ModelResolutionRequest = {
13
16
  policy?: {
14
17
  fallbackChain?: FallbackEntry[];
15
18
  systemDefaultModel?: string;
19
+ systemDefaultFallbackModel?: string;
16
20
  };
17
21
  };
18
- export type ModelResolutionProvenance = "override" | "category-default" | "provider-fallback" | "system-default";
22
+ export type ModelResolutionProvenance = "override" | "category-default" | "user-fallback" | "provider-fallback" | "system-default";
19
23
  export type ModelResolutionResult = {
20
24
  model: string;
21
25
  provenance: ModelResolutionProvenance;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,17 @@
1
+ import type { ModelResolutionRequest, ModelResolutionResult } from "./model-resolution-types";
2
+ /**
3
+ * Centrally tracks model resolutions to prevent log spam and ensure consistency.
4
+ * Only logs when the RESOLVED model actually changes.
5
+ */
6
+ declare class ModelResolutionTracker {
7
+ private lastResolved;
8
+ /**
9
+ * Resolves a model using the pipeline and tracks the result.
10
+ * @param contextKey A unique key for the resolution context (e.g. "sessionID:agentName")
11
+ * @param request The resolution request
12
+ */
13
+ resolve(contextKey: string, request: ModelResolutionRequest): ModelResolutionResult | undefined;
14
+ clear(contextKey: string): void;
15
+ }
16
+ export declare const modelResolutionTracker: ModelResolutionTracker;
17
+ export {};
@@ -2,18 +2,24 @@ import type { FallbackEntry } from "./model-requirements";
2
2
  export type ModelResolutionRequest = {
3
3
  intent?: {
4
4
  uiSelectedModel?: string;
5
+ sessionModel?: string;
5
6
  userModel?: string;
7
+ userFallbackModel?: string;
8
+ userFallbackModels?: string[];
6
9
  categoryDefaultModel?: string;
10
+ categoryFallbackModel?: string;
7
11
  };
8
12
  constraints: {
9
13
  availableModels: Set<string>;
14
+ connectedProviders?: string[] | null;
10
15
  };
11
16
  policy?: {
12
17
  fallbackChain?: FallbackEntry[];
13
18
  systemDefaultModel?: string;
19
+ systemDefaultFallbackModel?: string;
14
20
  };
15
21
  };
16
- export type ModelResolutionProvenance = "override" | "category-default" | "provider-fallback" | "system-default";
22
+ export type ModelResolutionProvenance = "override" | "category-default" | "user-fallback" | "provider-fallback" | "system-default";
17
23
  export type ModelResolutionResult = {
18
24
  model: string;
19
25
  provenance: ModelResolutionProvenance;