mu-harness 0.16.15 → 0.16.16

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 (841) hide show
  1. package/package.json +14 -8
  2. package/esm/core/src/agent.d.ts +0 -39
  3. package/esm/core/src/agent.js +0 -96
  4. package/esm/core/src/index.d.ts +0 -4
  5. package/esm/core/src/index.js +0 -2
  6. package/esm/core/src/types.d.ts +0 -59
  7. package/esm/core/src/types.js +0 -3
  8. package/esm/harness/src/agents/index.d.ts +0 -4
  9. package/esm/harness/src/agents/index.js +0 -3
  10. package/esm/harness/src/agents/loader.d.ts +0 -2
  11. package/esm/harness/src/agents/loader.js +0 -24
  12. package/esm/harness/src/agents/parser.d.ts +0 -2
  13. package/esm/harness/src/agents/parser.js +0 -46
  14. package/esm/harness/src/agents/registry.d.ts +0 -9
  15. package/esm/harness/src/agents/registry.js +0 -88
  16. package/esm/harness/src/agents/types.js +0 -1
  17. package/esm/harness/src/channels/channel.d.ts +0 -7
  18. package/esm/harness/src/channels/channel.js +0 -25
  19. package/esm/harness/src/channels/index.d.ts +0 -3
  20. package/esm/harness/src/channels/index.js +0 -2
  21. package/esm/harness/src/channels/manager.d.ts +0 -6
  22. package/esm/harness/src/channels/manager.js +0 -28
  23. package/esm/harness/src/channels/types.d.ts +0 -30
  24. package/esm/harness/src/channels/types.js +0 -1
  25. package/esm/harness/src/commands/defaults.d.ts +0 -11
  26. package/esm/harness/src/commands/defaults.js +0 -53
  27. package/esm/harness/src/commands/index.d.ts +0 -3
  28. package/esm/harness/src/commands/index.js +0 -2
  29. package/esm/harness/src/commands/registry.d.ts +0 -2
  30. package/esm/harness/src/commands/registry.js +0 -59
  31. package/esm/harness/src/commands/types.js +0 -1
  32. package/esm/harness/src/common/frontmatter.js +0 -18
  33. package/esm/harness/src/common/index.d.ts +0 -2
  34. package/esm/harness/src/common/index.js +0 -2
  35. package/esm/harness/src/common/utils.js +0 -22
  36. package/esm/harness/src/config/index.d.ts +0 -2
  37. package/esm/harness/src/config/index.js +0 -1
  38. package/esm/harness/src/config/resolve.d.ts +0 -2
  39. package/esm/harness/src/config/resolve.js +0 -10
  40. package/esm/harness/src/config/types.js +0 -1
  41. package/esm/harness/src/harness/create.d.ts +0 -2
  42. package/esm/harness/src/harness/create.js +0 -167
  43. package/esm/harness/src/harness/index.d.ts +0 -3
  44. package/esm/harness/src/harness/index.js +0 -2
  45. package/esm/harness/src/harness/models.js +0 -30
  46. package/esm/harness/src/harness/types.d.ts +0 -50
  47. package/esm/harness/src/harness/types.js +0 -1
  48. package/esm/harness/src/hooks/index.d.ts +0 -3
  49. package/esm/harness/src/hooks/index.js +0 -2
  50. package/esm/harness/src/hooks/merge-hooks.d.ts +0 -2
  51. package/esm/harness/src/hooks/merge-hooks.js +0 -46
  52. package/esm/harness/src/hooks/types.js +0 -1
  53. package/esm/harness/src/hooks/with-hooks.d.ts +0 -3
  54. package/esm/harness/src/hooks/with-hooks.js +0 -12
  55. package/esm/harness/src/index.d.ts +0 -14
  56. package/esm/harness/src/index.js +0 -14
  57. package/esm/harness/src/permissions/allow-list.d.ts +0 -4
  58. package/esm/harness/src/permissions/allow-list.js +0 -8
  59. package/esm/harness/src/permissions/approval-manager.d.ts +0 -31
  60. package/esm/harness/src/permissions/approval-manager.js +0 -55
  61. package/esm/harness/src/permissions/approval.d.ts +0 -17
  62. package/esm/harness/src/permissions/approval.js +0 -13
  63. package/esm/harness/src/permissions/glob.js +0 -2
  64. package/esm/harness/src/permissions/index.d.ts +0 -4
  65. package/esm/harness/src/permissions/index.js +0 -4
  66. package/esm/harness/src/plugin/define.d.ts +0 -2
  67. package/esm/harness/src/plugin/define.js +0 -1
  68. package/esm/harness/src/plugin/import-ts.js +0 -85
  69. package/esm/harness/src/plugin/index.d.ts +0 -5
  70. package/esm/harness/src/plugin/index.js +0 -4
  71. package/esm/harness/src/plugin/resolve.d.ts +0 -13
  72. package/esm/harness/src/plugin/resolve.js +0 -17
  73. package/esm/harness/src/plugin/store.js +0 -26
  74. package/esm/harness/src/plugin/types.d.ts +0 -11
  75. package/esm/harness/src/plugin/types.js +0 -1
  76. package/esm/harness/src/scheduler/command.d.ts +0 -3
  77. package/esm/harness/src/scheduler/command.js +0 -19
  78. package/esm/harness/src/scheduler/engine/index.d.ts +0 -4
  79. package/esm/harness/src/scheduler/engine/index.js +0 -3
  80. package/esm/harness/src/scheduler/engine/memory-store.d.ts +0 -2
  81. package/esm/harness/src/scheduler/engine/memory-store.js +0 -23
  82. package/esm/harness/src/scheduler/engine/scheduler.d.ts +0 -13
  83. package/esm/harness/src/scheduler/engine/scheduler.js +0 -73
  84. package/esm/harness/src/scheduler/engine/store.d.ts +0 -4
  85. package/esm/harness/src/scheduler/engine/store.js +0 -55
  86. package/esm/harness/src/scheduler/engine/types.js +0 -1
  87. package/esm/harness/src/scheduler/index.d.ts +0 -4
  88. package/esm/harness/src/scheduler/index.js +0 -3
  89. package/esm/harness/src/scheduler/tool.d.ts +0 -8
  90. package/esm/harness/src/scheduler/tool.js +0 -48
  91. package/esm/harness/src/session/agent-session.d.ts +0 -15
  92. package/esm/harness/src/session/agent-session.js +0 -83
  93. package/esm/harness/src/session/catalog.js +0 -55
  94. package/esm/harness/src/session/index.d.ts +0 -7
  95. package/esm/harness/src/session/index.js +0 -6
  96. package/esm/harness/src/session/manager.d.ts +0 -39
  97. package/esm/harness/src/session/manager.js +0 -65
  98. package/esm/harness/src/session/persist.d.ts +0 -3
  99. package/esm/harness/src/session/persist.js +0 -24
  100. package/esm/harness/src/session/store.js +0 -24
  101. package/esm/harness/src/session/title.js +0 -24
  102. package/esm/harness/src/session/types.js +0 -1
  103. package/esm/harness/src/skills/index.d.ts +0 -8
  104. package/esm/harness/src/skills/index.js +0 -7
  105. package/esm/harness/src/skills/loader.d.ts +0 -10
  106. package/esm/harness/src/skills/loader.js +0 -59
  107. package/esm/harness/src/skills/parser.d.ts +0 -2
  108. package/esm/harness/src/skills/parser.js +0 -16
  109. package/esm/harness/src/skills/platform.js +0 -14
  110. package/esm/harness/src/skills/registry.d.ts +0 -8
  111. package/esm/harness/src/skills/registry.js +0 -16
  112. package/esm/harness/src/skills/run.d.ts +0 -14
  113. package/esm/harness/src/skills/run.js +0 -44
  114. package/esm/harness/src/skills/tool.d.ts +0 -3
  115. package/esm/harness/src/skills/tool.js +0 -31
  116. package/esm/harness/src/skills/types.js +0 -1
  117. package/esm/harness/src/skills/writer.d.ts +0 -8
  118. package/esm/harness/src/skills/writer.js +0 -55
  119. package/esm/harness/src/subAgents/index.d.ts +0 -4
  120. package/esm/harness/src/subAgents/index.js +0 -3
  121. package/esm/harness/src/subAgents/registry.d.ts +0 -2
  122. package/esm/harness/src/subAgents/registry.js +0 -18
  123. package/esm/harness/src/subAgents/runner.d.ts +0 -15
  124. package/esm/harness/src/subAgents/runner.js +0 -33
  125. package/esm/harness/src/subAgents/tool.d.ts +0 -6
  126. package/esm/harness/src/subAgents/tool.js +0 -64
  127. package/esm/harness/src/subAgents/types.d.ts +0 -18
  128. package/esm/harness/src/subAgents/types.js +0 -1
  129. package/esm/harness/src/tui/chat/ChatApp.d.ts +0 -188
  130. package/esm/harness/src/tui/chat/ChatApp.js +0 -1306
  131. package/esm/harness/src/tui/chat/commands.js +0 -21
  132. package/esm/harness/src/tui/chat/editor.js +0 -147
  133. package/esm/harness/src/tui/chat/index.d.ts +0 -9
  134. package/esm/harness/src/tui/chat/index.js +0 -7
  135. package/esm/harness/src/tui/chat/markdown.d.ts +0 -9
  136. package/esm/harness/src/tui/chat/markdown.js +0 -295
  137. package/esm/harness/src/tui/chat/picker.js +0 -123
  138. package/esm/harness/src/tui/chat/status.d.ts +0 -15
  139. package/esm/harness/src/tui/chat/status.js +0 -48
  140. package/esm/harness/src/tui/chat/theme.js +0 -201
  141. package/esm/harness/src/tui/chat/transcript.d.ts +0 -79
  142. package/esm/harness/src/tui/chat/transcript.js +0 -422
  143. package/esm/harness/src/tui/index.d.ts +0 -8
  144. package/esm/harness/src/tui/index.js +0 -12
  145. package/esm/tui/src/capabilities.d.ts +0 -72
  146. package/esm/tui/src/capabilities.js +0 -90
  147. package/esm/tui/src/components/command-palette.d.ts +0 -24
  148. package/esm/tui/src/components/command-palette.js +0 -60
  149. package/esm/tui/src/components/editor.d.ts +0 -26
  150. package/esm/tui/src/components/editor.js +0 -111
  151. package/esm/tui/src/components/scroll-view.d.ts +0 -26
  152. package/esm/tui/src/components/scroll-view.js +0 -70
  153. package/esm/tui/src/components/select-list.d.ts +0 -24
  154. package/esm/tui/src/components/select-list.js +0 -71
  155. package/esm/tui/src/events.d.ts +0 -56
  156. package/esm/tui/src/events.js +0 -6
  157. package/esm/tui/src/index.d.ts +0 -17
  158. package/esm/tui/src/index.js +0 -13
  159. package/esm/tui/src/inputRouter.d.ts +0 -28
  160. package/esm/tui/src/inputRouter.js +0 -128
  161. package/esm/tui/src/keybinds.d.ts +0 -13
  162. package/esm/tui/src/keybinds.js +0 -15
  163. package/esm/tui/src/keyboard.d.ts +0 -2
  164. package/esm/tui/src/keyboard.js +0 -319
  165. package/esm/tui/src/layout/ansi.d.ts +0 -3
  166. package/esm/tui/src/layout/ansi.js +0 -330
  167. package/esm/tui/src/layout/cell.d.ts +0 -24
  168. package/esm/tui/src/layout/cell.js +0 -46
  169. package/esm/tui/src/layout/cellbuffer.d.ts +0 -29
  170. package/esm/tui/src/layout/cellbuffer.js +0 -306
  171. package/esm/tui/src/layout/color.d.ts +0 -22
  172. package/esm/tui/src/layout/color.js +0 -163
  173. package/esm/tui/src/layout/insets.d.ts +0 -8
  174. package/esm/tui/src/layout/insets.js +0 -55
  175. package/esm/tui/src/layout/types.d.ts +0 -33
  176. package/esm/tui/src/layout/types.js +0 -8
  177. package/esm/tui/src/parser.d.ts +0 -18
  178. package/esm/tui/src/parser.js +0 -136
  179. package/esm/tui/src/renderer.d.ts +0 -32
  180. package/esm/tui/src/renderer.js +0 -168
  181. package/esm/tui/src/surface.d.ts +0 -27
  182. package/esm/tui/src/surface.js +0 -110
  183. package/esm/tui/src/terminal.d.ts +0 -48
  184. package/esm/tui/src/terminal.js +0 -255
  185. package/esm/tui/src/tui.d.ts +0 -60
  186. package/esm/tui/src/tui.js +0 -194
  187. package/esm/tui/src/types/terminal.d.ts +0 -20
  188. package/esm/tui/src/types/terminal.js +0 -1
  189. package/esm/tui/src/utils.d.ts +0 -6
  190. package/esm/tui/src/utils.js +0 -292
  191. package/esm/tui/src/views.d.ts +0 -35
  192. package/esm/tui/src/views.js +0 -112
  193. package/script/core/src/agent.d.ts +0 -39
  194. package/script/core/src/agent.js +0 -101
  195. package/script/core/src/index.d.ts +0 -4
  196. package/script/core/src/index.js +0 -10
  197. package/script/core/src/types.d.ts +0 -59
  198. package/script/core/src/types.js +0 -9
  199. package/script/harness/npm/src/agents/types.d.ts +0 -12
  200. package/script/harness/npm/src/commands/types.d.ts +0 -23
  201. package/script/harness/npm/src/common/frontmatter.d.ts +0 -6
  202. package/script/harness/npm/src/common/utils.d.ts +0 -7
  203. package/script/harness/npm/src/config/types.d.ts +0 -15
  204. package/script/harness/npm/src/harness/models.d.ts +0 -16
  205. package/script/harness/npm/src/hooks/types.d.ts +0 -21
  206. package/script/harness/npm/src/permissions/glob.d.ts +0 -1
  207. package/script/harness/npm/src/plugin/import-ts.d.ts +0 -1
  208. package/script/harness/npm/src/plugin/store.d.ts +0 -8
  209. package/script/harness/npm/src/scheduler/engine/types.d.ts +0 -55
  210. package/script/harness/npm/src/session/catalog.d.ts +0 -24
  211. package/script/harness/npm/src/session/store.d.ts +0 -13
  212. package/script/harness/npm/src/session/title.d.ts +0 -9
  213. package/script/harness/npm/src/session/types.d.ts +0 -18
  214. package/script/harness/npm/src/skills/platform.d.ts +0 -6
  215. package/script/harness/npm/src/skills/types.d.ts +0 -8
  216. package/script/harness/npm/src/tui/chat/commands.d.ts +0 -16
  217. package/script/harness/npm/src/tui/chat/editor.d.ts +0 -31
  218. package/script/harness/npm/src/tui/chat/picker.d.ts +0 -13
  219. package/script/harness/npm/src/tui/chat/theme.d.ts +0 -97
  220. package/script/harness/src/agents/index.d.ts +0 -4
  221. package/script/harness/src/agents/index.js +0 -12
  222. package/script/harness/src/agents/loader.d.ts +0 -2
  223. package/script/harness/src/agents/loader.js +0 -28
  224. package/script/harness/src/agents/parser.d.ts +0 -2
  225. package/script/harness/src/agents/parser.js +0 -50
  226. package/script/harness/src/agents/registry.d.ts +0 -9
  227. package/script/harness/src/agents/registry.js +0 -95
  228. package/script/harness/src/agents/types.d.ts +0 -12
  229. package/script/harness/src/agents/types.js +0 -2
  230. package/script/harness/src/channels/channel.d.ts +0 -7
  231. package/script/harness/src/channels/channel.js +0 -29
  232. package/script/harness/src/channels/index.d.ts +0 -3
  233. package/script/harness/src/channels/index.js +0 -7
  234. package/script/harness/src/channels/manager.d.ts +0 -6
  235. package/script/harness/src/channels/manager.js +0 -32
  236. package/script/harness/src/channels/types.d.ts +0 -30
  237. package/script/harness/src/channels/types.js +0 -2
  238. package/script/harness/src/commands/defaults.d.ts +0 -11
  239. package/script/harness/src/commands/defaults.js +0 -61
  240. package/script/harness/src/commands/index.d.ts +0 -3
  241. package/script/harness/src/commands/index.js +0 -11
  242. package/script/harness/src/commands/registry.d.ts +0 -2
  243. package/script/harness/src/commands/registry.js +0 -63
  244. package/script/harness/src/commands/types.d.ts +0 -23
  245. package/script/harness/src/commands/types.js +0 -2
  246. package/script/harness/src/common/frontmatter.d.ts +0 -6
  247. package/script/harness/src/common/frontmatter.js +0 -23
  248. package/script/harness/src/common/index.d.ts +0 -2
  249. package/script/harness/src/common/index.js +0 -9
  250. package/script/harness/src/common/utils.d.ts +0 -7
  251. package/script/harness/src/common/utils.js +0 -27
  252. package/script/harness/src/config/index.d.ts +0 -2
  253. package/script/harness/src/config/index.js +0 -5
  254. package/script/harness/src/config/resolve.d.ts +0 -2
  255. package/script/harness/src/config/resolve.js +0 -14
  256. package/script/harness/src/config/types.d.ts +0 -15
  257. package/script/harness/src/config/types.js +0 -2
  258. package/script/harness/src/harness/create.d.ts +0 -2
  259. package/script/harness/src/harness/create.js +0 -174
  260. package/script/harness/src/harness/index.d.ts +0 -3
  261. package/script/harness/src/harness/index.js +0 -7
  262. package/script/harness/src/harness/models.d.ts +0 -16
  263. package/script/harness/src/harness/models.js +0 -34
  264. package/script/harness/src/harness/types.d.ts +0 -50
  265. package/script/harness/src/harness/types.js +0 -2
  266. package/script/harness/src/hooks/index.d.ts +0 -3
  267. package/script/harness/src/hooks/index.js +0 -7
  268. package/script/harness/src/hooks/merge-hooks.d.ts +0 -2
  269. package/script/harness/src/hooks/merge-hooks.js +0 -50
  270. package/script/harness/src/hooks/types.d.ts +0 -21
  271. package/script/harness/src/hooks/types.js +0 -2
  272. package/script/harness/src/hooks/with-hooks.d.ts +0 -3
  273. package/script/harness/src/hooks/with-hooks.js +0 -16
  274. package/script/harness/src/index.d.ts +0 -14
  275. package/script/harness/src/index.js +0 -30
  276. package/script/harness/src/permissions/allow-list.d.ts +0 -4
  277. package/script/harness/src/permissions/allow-list.js +0 -13
  278. package/script/harness/src/permissions/approval-manager.d.ts +0 -31
  279. package/script/harness/src/permissions/approval-manager.js +0 -59
  280. package/script/harness/src/permissions/approval.d.ts +0 -17
  281. package/script/harness/src/permissions/approval.js +0 -17
  282. package/script/harness/src/permissions/glob.d.ts +0 -1
  283. package/script/harness/src/permissions/glob.js +0 -6
  284. package/script/harness/src/permissions/index.d.ts +0 -4
  285. package/script/harness/src/permissions/index.js +0 -12
  286. package/script/harness/src/plugin/define.d.ts +0 -2
  287. package/script/harness/src/plugin/define.js +0 -5
  288. package/script/harness/src/plugin/import-ts.d.ts +0 -1
  289. package/script/harness/src/plugin/import-ts.js +0 -122
  290. package/script/harness/src/plugin/index.d.ts +0 -5
  291. package/script/harness/src/plugin/index.js +0 -11
  292. package/script/harness/src/plugin/resolve.d.ts +0 -13
  293. package/script/harness/src/plugin/resolve.js +0 -21
  294. package/script/harness/src/plugin/store.d.ts +0 -8
  295. package/script/harness/src/plugin/store.js +0 -30
  296. package/script/harness/src/plugin/types.d.ts +0 -11
  297. package/script/harness/src/plugin/types.js +0 -2
  298. package/script/harness/src/scheduler/command.d.ts +0 -3
  299. package/script/harness/src/scheduler/command.js +0 -23
  300. package/script/harness/src/scheduler/engine/index.d.ts +0 -4
  301. package/script/harness/src/scheduler/engine/index.js +0 -9
  302. package/script/harness/src/scheduler/engine/memory-store.d.ts +0 -2
  303. package/script/harness/src/scheduler/engine/memory-store.js +0 -27
  304. package/script/harness/src/scheduler/engine/scheduler.d.ts +0 -13
  305. package/script/harness/src/scheduler/engine/scheduler.js +0 -77
  306. package/script/harness/src/scheduler/engine/store.d.ts +0 -4
  307. package/script/harness/src/scheduler/engine/store.js +0 -59
  308. package/script/harness/src/scheduler/engine/types.d.ts +0 -55
  309. package/script/harness/src/scheduler/engine/types.js +0 -2
  310. package/script/harness/src/scheduler/index.d.ts +0 -4
  311. package/script/harness/src/scheduler/index.js +0 -11
  312. package/script/harness/src/scheduler/tool.d.ts +0 -8
  313. package/script/harness/src/scheduler/tool.js +0 -52
  314. package/script/harness/src/session/agent-session.d.ts +0 -15
  315. package/script/harness/src/session/agent-session.js +0 -87
  316. package/script/harness/src/session/catalog.d.ts +0 -24
  317. package/script/harness/src/session/catalog.js +0 -59
  318. package/script/harness/src/session/index.d.ts +0 -7
  319. package/script/harness/src/session/index.js +0 -17
  320. package/script/harness/src/session/manager.d.ts +0 -39
  321. package/script/harness/src/session/manager.js +0 -69
  322. package/script/harness/src/session/persist.d.ts +0 -3
  323. package/script/harness/src/session/persist.js +0 -28
  324. package/script/harness/src/session/store.d.ts +0 -13
  325. package/script/harness/src/session/store.js +0 -28
  326. package/script/harness/src/session/title.d.ts +0 -9
  327. package/script/harness/src/session/title.js +0 -30
  328. package/script/harness/src/session/types.d.ts +0 -18
  329. package/script/harness/src/session/types.js +0 -2
  330. package/script/harness/src/skills/index.d.ts +0 -8
  331. package/script/harness/src/skills/index.js +0 -18
  332. package/script/harness/src/skills/loader.d.ts +0 -10
  333. package/script/harness/src/skills/loader.js +0 -63
  334. package/script/harness/src/skills/parser.d.ts +0 -2
  335. package/script/harness/src/skills/parser.js +0 -20
  336. package/script/harness/src/skills/platform.d.ts +0 -6
  337. package/script/harness/src/skills/platform.js +0 -18
  338. package/script/harness/src/skills/registry.d.ts +0 -8
  339. package/script/harness/src/skills/registry.js +0 -20
  340. package/script/harness/src/skills/run.d.ts +0 -14
  341. package/script/harness/src/skills/run.js +0 -49
  342. package/script/harness/src/skills/tool.d.ts +0 -3
  343. package/script/harness/src/skills/tool.js +0 -35
  344. package/script/harness/src/skills/types.d.ts +0 -8
  345. package/script/harness/src/skills/types.js +0 -2
  346. package/script/harness/src/skills/writer.d.ts +0 -8
  347. package/script/harness/src/skills/writer.js +0 -59
  348. package/script/harness/src/subAgents/index.d.ts +0 -4
  349. package/script/harness/src/subAgents/index.js +0 -9
  350. package/script/harness/src/subAgents/registry.d.ts +0 -2
  351. package/script/harness/src/subAgents/registry.js +0 -22
  352. package/script/harness/src/subAgents/runner.d.ts +0 -15
  353. package/script/harness/src/subAgents/runner.js +0 -37
  354. package/script/harness/src/subAgents/tool.d.ts +0 -6
  355. package/script/harness/src/subAgents/tool.js +0 -68
  356. package/script/harness/src/subAgents/types.d.ts +0 -18
  357. package/script/harness/src/subAgents/types.js +0 -2
  358. package/script/harness/src/tui/chat/ChatApp.d.ts +0 -188
  359. package/script/harness/src/tui/chat/ChatApp.js +0 -1310
  360. package/script/harness/src/tui/chat/commands.d.ts +0 -16
  361. package/script/harness/src/tui/chat/commands.js +0 -25
  362. package/script/harness/src/tui/chat/editor.d.ts +0 -31
  363. package/script/harness/src/tui/chat/editor.js +0 -151
  364. package/script/harness/src/tui/chat/index.d.ts +0 -9
  365. package/script/harness/src/tui/chat/index.js +0 -25
  366. package/script/harness/src/tui/chat/markdown.d.ts +0 -9
  367. package/script/harness/src/tui/chat/markdown.js +0 -300
  368. package/script/harness/src/tui/chat/picker.d.ts +0 -13
  369. package/script/harness/src/tui/chat/picker.js +0 -129
  370. package/script/harness/src/tui/chat/status.d.ts +0 -15
  371. package/script/harness/src/tui/chat/status.js +0 -55
  372. package/script/harness/src/tui/chat/theme.d.ts +0 -97
  373. package/script/harness/src/tui/chat/theme.js +0 -209
  374. package/script/harness/src/tui/chat/transcript.d.ts +0 -79
  375. package/script/harness/src/tui/chat/transcript.js +0 -430
  376. package/script/harness/src/tui/index.d.ts +0 -8
  377. package/script/harness/src/tui/index.js +0 -30
  378. package/script/tui/src/capabilities.d.ts +0 -72
  379. package/script/tui/src/capabilities.js +0 -98
  380. package/script/tui/src/components/command-palette.d.ts +0 -24
  381. package/script/tui/src/components/command-palette.js +0 -65
  382. package/script/tui/src/components/editor.d.ts +0 -26
  383. package/script/tui/src/components/editor.js +0 -116
  384. package/script/tui/src/components/scroll-view.d.ts +0 -26
  385. package/script/tui/src/components/scroll-view.js +0 -75
  386. package/script/tui/src/components/select-list.d.ts +0 -24
  387. package/script/tui/src/components/select-list.js +0 -76
  388. package/script/tui/src/events.d.ts +0 -56
  389. package/script/tui/src/events.js +0 -9
  390. package/script/tui/src/index.d.ts +0 -17
  391. package/script/tui/src/index.js +0 -46
  392. package/script/tui/src/inputRouter.d.ts +0 -28
  393. package/script/tui/src/inputRouter.js +0 -132
  394. package/script/tui/src/keybinds.d.ts +0 -13
  395. package/script/tui/src/keybinds.js +0 -18
  396. package/script/tui/src/keyboard.d.ts +0 -2
  397. package/script/tui/src/keyboard.js +0 -322
  398. package/script/tui/src/layout/ansi.d.ts +0 -3
  399. package/script/tui/src/layout/ansi.js +0 -334
  400. package/script/tui/src/layout/cell.d.ts +0 -24
  401. package/script/tui/src/layout/cell.js +0 -54
  402. package/script/tui/src/layout/cellbuffer.d.ts +0 -29
  403. package/script/tui/src/layout/cellbuffer.js +0 -321
  404. package/script/tui/src/layout/color.d.ts +0 -22
  405. package/script/tui/src/layout/color.js +0 -174
  406. package/script/tui/src/layout/insets.d.ts +0 -8
  407. package/script/tui/src/layout/insets.js +0 -64
  408. package/script/tui/src/layout/types.d.ts +0 -33
  409. package/script/tui/src/layout/types.js +0 -11
  410. package/script/tui/src/parser.d.ts +0 -18
  411. package/script/tui/src/parser.js +0 -140
  412. package/script/tui/src/renderer.d.ts +0 -32
  413. package/script/tui/src/renderer.js +0 -175
  414. package/script/tui/src/surface.d.ts +0 -27
  415. package/script/tui/src/surface.js +0 -115
  416. package/script/tui/src/terminal.d.ts +0 -48
  417. package/script/tui/src/terminal.js +0 -262
  418. package/script/tui/src/tui.d.ts +0 -60
  419. package/script/tui/src/tui.js +0 -198
  420. package/script/tui/src/types/terminal.d.ts +0 -20
  421. package/script/tui/src/types/terminal.js +0 -2
  422. package/script/tui/src/utils.d.ts +0 -6
  423. package/script/tui/src/utils.js +0 -300
  424. package/script/tui/src/views.d.ts +0 -35
  425. package/script/tui/src/views.js +0 -123
  426. /package/esm/{harness/npm/src/_dnt.polyfills.d.ts → _dnt.polyfills.d.ts} +0 -0
  427. /package/esm/{harness/npm/src/_dnt.polyfills.js → _dnt.polyfills.js} +0 -0
  428. /package/esm/{harness/npm/src/agents → agents}/index.d.ts +0 -0
  429. /package/esm/{harness/npm/src/agents → agents}/index.js +0 -0
  430. /package/esm/{harness/npm/src/agents → agents}/loader.d.ts +0 -0
  431. /package/esm/{harness/npm/src/agents → agents}/loader.js +0 -0
  432. /package/esm/{harness/npm/src/agents → agents}/parser.d.ts +0 -0
  433. /package/esm/{harness/npm/src/agents → agents}/parser.js +0 -0
  434. /package/esm/{harness/npm/src/agents → agents}/registry.d.ts +0 -0
  435. /package/esm/{harness/npm/src/agents → agents}/registry.js +0 -0
  436. /package/esm/{harness/npm/src/agents → agents}/types.d.ts +0 -0
  437. /package/esm/{harness/npm/src/agents → agents}/types.js +0 -0
  438. /package/esm/{harness/npm/src/channels → channels}/channel.d.ts +0 -0
  439. /package/esm/{harness/npm/src/channels → channels}/channel.js +0 -0
  440. /package/esm/{harness/npm/src/channels → channels}/index.d.ts +0 -0
  441. /package/esm/{harness/npm/src/channels → channels}/index.js +0 -0
  442. /package/esm/{harness/npm/src/channels → channels}/manager.d.ts +0 -0
  443. /package/esm/{harness/npm/src/channels → channels}/manager.js +0 -0
  444. /package/esm/{harness/npm/src/channels → channels}/types.d.ts +0 -0
  445. /package/esm/{harness/npm/src/channels → channels}/types.js +0 -0
  446. /package/esm/{harness/npm/src/commands → commands}/defaults.d.ts +0 -0
  447. /package/esm/{harness/npm/src/commands → commands}/defaults.js +0 -0
  448. /package/esm/{harness/npm/src/commands → commands}/index.d.ts +0 -0
  449. /package/esm/{harness/npm/src/commands → commands}/index.js +0 -0
  450. /package/esm/{harness/npm/src/commands → commands}/registry.d.ts +0 -0
  451. /package/esm/{harness/npm/src/commands → commands}/registry.js +0 -0
  452. /package/esm/{harness/npm/src/commands → commands}/types.d.ts +0 -0
  453. /package/esm/{harness/npm/src/commands → commands}/types.js +0 -0
  454. /package/esm/{harness/npm/src/common → common}/frontmatter.d.ts +0 -0
  455. /package/esm/{harness/npm/src/common → common}/frontmatter.js +0 -0
  456. /package/esm/{harness/npm/src/common → common}/index.d.ts +0 -0
  457. /package/esm/{harness/npm/src/common → common}/index.js +0 -0
  458. /package/esm/{harness/npm/src/common → common}/utils.d.ts +0 -0
  459. /package/esm/{harness/npm/src/common → common}/utils.js +0 -0
  460. /package/esm/{harness/npm/src/config → config}/index.d.ts +0 -0
  461. /package/esm/{harness/npm/src/config → config}/index.js +0 -0
  462. /package/esm/{harness/npm/src/config → config}/resolve.d.ts +0 -0
  463. /package/esm/{harness/npm/src/config → config}/resolve.js +0 -0
  464. /package/esm/{harness/npm/src/config → config}/types.d.ts +0 -0
  465. /package/esm/{harness/npm/src/config → config}/types.js +0 -0
  466. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_chars.d.ts +0 -0
  467. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_chars.js +0 -0
  468. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_dumper_state.d.ts +0 -0
  469. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_dumper_state.js +0 -0
  470. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_loader_state.d.ts +0 -0
  471. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_loader_state.js +0 -0
  472. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_schema.d.ts +0 -0
  473. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_schema.js +0 -0
  474. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/binary.d.ts +0 -0
  475. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/binary.js +0 -0
  476. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/bool.d.ts +0 -0
  477. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/bool.js +0 -0
  478. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/float.d.ts +0 -0
  479. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/float.js +0 -0
  480. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/int.d.ts +0 -0
  481. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/int.js +0 -0
  482. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/map.d.ts +0 -0
  483. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/map.js +0 -0
  484. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/merge.d.ts +0 -0
  485. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/merge.js +0 -0
  486. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/nil.d.ts +0 -0
  487. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/nil.js +0 -0
  488. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/omap.d.ts +0 -0
  489. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/omap.js +0 -0
  490. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/pairs.d.ts +0 -0
  491. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/pairs.js +0 -0
  492. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/regexp.d.ts +0 -0
  493. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/regexp.js +0 -0
  494. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/seq.d.ts +0 -0
  495. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/seq.js +0 -0
  496. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/set.d.ts +0 -0
  497. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/set.js +0 -0
  498. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/str.d.ts +0 -0
  499. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/str.js +0 -0
  500. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/timestamp.d.ts +0 -0
  501. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/timestamp.js +0 -0
  502. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/undefined.d.ts +0 -0
  503. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/undefined.js +0 -0
  504. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type.d.ts +0 -0
  505. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type.js +0 -0
  506. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_utils.d.ts +0 -0
  507. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_utils.js +0 -0
  508. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/mod.d.ts +0 -0
  509. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/mod.js +0 -0
  510. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/parse.d.ts +0 -0
  511. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/parse.js +0 -0
  512. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/stringify.d.ts +0 -0
  513. /package/esm/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/stringify.js +0 -0
  514. /package/esm/harness/{npm/src/harness/create.d.ts → create.d.ts} +0 -0
  515. /package/esm/harness/{npm/src/harness/create.js → create.js} +0 -0
  516. /package/esm/harness/{npm/src/harness/index.d.ts → index.d.ts} +0 -0
  517. /package/esm/harness/{npm/src/harness/index.js → index.js} +0 -0
  518. /package/esm/harness/{npm/src/harness/models.d.ts → models.d.ts} +0 -0
  519. /package/esm/harness/{npm/src/harness/models.js → models.js} +0 -0
  520. /package/esm/harness/{npm/src/harness/types.d.ts → types.d.ts} +0 -0
  521. /package/esm/harness/{npm/src/harness/types.js → types.js} +0 -0
  522. /package/esm/{harness/npm/src/hooks → hooks}/index.d.ts +0 -0
  523. /package/esm/{harness/npm/src/hooks → hooks}/index.js +0 -0
  524. /package/esm/{harness/npm/src/hooks → hooks}/merge-hooks.d.ts +0 -0
  525. /package/esm/{harness/npm/src/hooks → hooks}/merge-hooks.js +0 -0
  526. /package/esm/{harness/npm/src/hooks → hooks}/types.d.ts +0 -0
  527. /package/esm/{harness/npm/src/hooks → hooks}/types.js +0 -0
  528. /package/esm/{harness/npm/src/hooks → hooks}/with-hooks.d.ts +0 -0
  529. /package/esm/{harness/npm/src/hooks → hooks}/with-hooks.js +0 -0
  530. /package/esm/{harness/npm/src/index.d.ts → index.d.ts} +0 -0
  531. /package/esm/{harness/npm/src/index.js → index.js} +0 -0
  532. /package/esm/{harness/npm/src/permissions → permissions}/allow-list.d.ts +0 -0
  533. /package/esm/{harness/npm/src/permissions → permissions}/allow-list.js +0 -0
  534. /package/esm/{harness/npm/src/permissions → permissions}/approval-manager.d.ts +0 -0
  535. /package/esm/{harness/npm/src/permissions → permissions}/approval-manager.js +0 -0
  536. /package/esm/{harness/npm/src/permissions → permissions}/approval.d.ts +0 -0
  537. /package/esm/{harness/npm/src/permissions → permissions}/approval.js +0 -0
  538. /package/esm/{harness/npm/src/permissions → permissions}/glob.d.ts +0 -0
  539. /package/esm/{harness/npm/src/permissions → permissions}/glob.js +0 -0
  540. /package/esm/{harness/npm/src/permissions → permissions}/index.d.ts +0 -0
  541. /package/esm/{harness/npm/src/permissions → permissions}/index.js +0 -0
  542. /package/esm/{harness/npm/src/plugin → plugin}/define.d.ts +0 -0
  543. /package/esm/{harness/npm/src/plugin → plugin}/define.js +0 -0
  544. /package/esm/{harness/npm/src/plugin → plugin}/import-ts.d.ts +0 -0
  545. /package/esm/{harness/npm/src/plugin → plugin}/import-ts.js +0 -0
  546. /package/esm/{harness/npm/src/plugin → plugin}/index.d.ts +0 -0
  547. /package/esm/{harness/npm/src/plugin → plugin}/index.js +0 -0
  548. /package/esm/{harness/npm/src/plugin → plugin}/resolve.d.ts +0 -0
  549. /package/esm/{harness/npm/src/plugin → plugin}/resolve.js +0 -0
  550. /package/esm/{harness/npm/src/plugin → plugin}/store.d.ts +0 -0
  551. /package/esm/{harness/npm/src/plugin → plugin}/store.js +0 -0
  552. /package/esm/{harness/npm/src/plugin → plugin}/types.d.ts +0 -0
  553. /package/esm/{harness/npm/src/plugin → plugin}/types.js +0 -0
  554. /package/esm/{harness/npm/src/scheduler → scheduler}/command.d.ts +0 -0
  555. /package/esm/{harness/npm/src/scheduler → scheduler}/command.js +0 -0
  556. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/index.d.ts +0 -0
  557. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/index.js +0 -0
  558. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/memory-store.d.ts +0 -0
  559. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/memory-store.js +0 -0
  560. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/scheduler.d.ts +0 -0
  561. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/scheduler.js +0 -0
  562. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/store.d.ts +0 -0
  563. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/store.js +0 -0
  564. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/types.d.ts +0 -0
  565. /package/esm/{harness/npm/src/scheduler → scheduler}/engine/types.js +0 -0
  566. /package/esm/{harness/npm/src/scheduler → scheduler}/index.d.ts +0 -0
  567. /package/esm/{harness/npm/src/scheduler → scheduler}/index.js +0 -0
  568. /package/esm/{harness/npm/src/scheduler → scheduler}/tool.d.ts +0 -0
  569. /package/esm/{harness/npm/src/scheduler → scheduler}/tool.js +0 -0
  570. /package/esm/{harness/npm/src/session → session}/agent-session.d.ts +0 -0
  571. /package/esm/{harness/npm/src/session → session}/agent-session.js +0 -0
  572. /package/esm/{harness/npm/src/session → session}/catalog.d.ts +0 -0
  573. /package/esm/{harness/npm/src/session → session}/catalog.js +0 -0
  574. /package/esm/{harness/npm/src/session → session}/index.d.ts +0 -0
  575. /package/esm/{harness/npm/src/session → session}/index.js +0 -0
  576. /package/esm/{harness/npm/src/session → session}/manager.d.ts +0 -0
  577. /package/esm/{harness/npm/src/session → session}/manager.js +0 -0
  578. /package/esm/{harness/npm/src/session → session}/persist.d.ts +0 -0
  579. /package/esm/{harness/npm/src/session → session}/persist.js +0 -0
  580. /package/esm/{harness/npm/src/session → session}/store.d.ts +0 -0
  581. /package/esm/{harness/npm/src/session → session}/store.js +0 -0
  582. /package/esm/{harness/npm/src/session → session}/title.d.ts +0 -0
  583. /package/esm/{harness/npm/src/session → session}/title.js +0 -0
  584. /package/esm/{harness/npm/src/session → session}/types.d.ts +0 -0
  585. /package/esm/{harness/npm/src/session → session}/types.js +0 -0
  586. /package/esm/{harness/npm/src/skills → skills}/index.d.ts +0 -0
  587. /package/esm/{harness/npm/src/skills → skills}/index.js +0 -0
  588. /package/esm/{harness/npm/src/skills → skills}/loader.d.ts +0 -0
  589. /package/esm/{harness/npm/src/skills → skills}/loader.js +0 -0
  590. /package/esm/{harness/npm/src/skills → skills}/parser.d.ts +0 -0
  591. /package/esm/{harness/npm/src/skills → skills}/parser.js +0 -0
  592. /package/esm/{harness/npm/src/skills → skills}/platform.d.ts +0 -0
  593. /package/esm/{harness/npm/src/skills → skills}/platform.js +0 -0
  594. /package/esm/{harness/npm/src/skills → skills}/registry.d.ts +0 -0
  595. /package/esm/{harness/npm/src/skills → skills}/registry.js +0 -0
  596. /package/esm/{harness/npm/src/skills → skills}/run.d.ts +0 -0
  597. /package/esm/{harness/npm/src/skills → skills}/run.js +0 -0
  598. /package/esm/{harness/npm/src/skills → skills}/tool.d.ts +0 -0
  599. /package/esm/{harness/npm/src/skills → skills}/tool.js +0 -0
  600. /package/esm/{harness/npm/src/skills → skills}/types.d.ts +0 -0
  601. /package/esm/{harness/npm/src/skills → skills}/types.js +0 -0
  602. /package/esm/{harness/npm/src/skills → skills}/writer.d.ts +0 -0
  603. /package/esm/{harness/npm/src/skills → skills}/writer.js +0 -0
  604. /package/esm/{harness/npm/src/subAgents → subAgents}/index.d.ts +0 -0
  605. /package/esm/{harness/npm/src/subAgents → subAgents}/index.js +0 -0
  606. /package/esm/{harness/npm/src/subAgents → subAgents}/registry.d.ts +0 -0
  607. /package/esm/{harness/npm/src/subAgents → subAgents}/registry.js +0 -0
  608. /package/esm/{harness/npm/src/subAgents → subAgents}/runner.d.ts +0 -0
  609. /package/esm/{harness/npm/src/subAgents → subAgents}/runner.js +0 -0
  610. /package/esm/{harness/npm/src/subAgents → subAgents}/tool.d.ts +0 -0
  611. /package/esm/{harness/npm/src/subAgents → subAgents}/tool.js +0 -0
  612. /package/esm/{harness/npm/src/subAgents → subAgents}/types.d.ts +0 -0
  613. /package/esm/{harness/npm/src/subAgents → subAgents}/types.js +0 -0
  614. /package/esm/{harness/npm/src/tui → tui}/chat/ChatApp.d.ts +0 -0
  615. /package/esm/{harness/npm/src/tui → tui}/chat/ChatApp.js +0 -0
  616. /package/esm/{harness/npm/src/tui → tui}/chat/commands.d.ts +0 -0
  617. /package/esm/{harness/npm/src/tui → tui}/chat/commands.js +0 -0
  618. /package/esm/{harness/npm/src/tui → tui}/chat/editor.d.ts +0 -0
  619. /package/esm/{harness/npm/src/tui → tui}/chat/editor.js +0 -0
  620. /package/esm/{harness/npm/src/tui → tui}/chat/index.d.ts +0 -0
  621. /package/esm/{harness/npm/src/tui → tui}/chat/index.js +0 -0
  622. /package/esm/{harness/npm/src/tui → tui}/chat/markdown.d.ts +0 -0
  623. /package/esm/{harness/npm/src/tui → tui}/chat/markdown.js +0 -0
  624. /package/esm/{harness/npm/src/tui → tui}/chat/picker.d.ts +0 -0
  625. /package/esm/{harness/npm/src/tui → tui}/chat/picker.js +0 -0
  626. /package/esm/{harness/npm/src/tui → tui}/chat/status.d.ts +0 -0
  627. /package/esm/{harness/npm/src/tui → tui}/chat/status.js +0 -0
  628. /package/esm/{harness/npm/src/tui → tui}/chat/theme.d.ts +0 -0
  629. /package/esm/{harness/npm/src/tui → tui}/chat/theme.js +0 -0
  630. /package/esm/{harness/npm/src/tui → tui}/chat/transcript.d.ts +0 -0
  631. /package/esm/{harness/npm/src/tui → tui}/chat/transcript.js +0 -0
  632. /package/esm/{harness/npm/src/tui → tui}/index.d.ts +0 -0
  633. /package/esm/{harness/npm/src/tui → tui}/index.js +0 -0
  634. /package/script/{harness/npm/src/_dnt.polyfills.d.ts → _dnt.polyfills.d.ts} +0 -0
  635. /package/script/{harness/npm/src/_dnt.polyfills.js → _dnt.polyfills.js} +0 -0
  636. /package/script/{harness/npm/src/agents → agents}/index.d.ts +0 -0
  637. /package/script/{harness/npm/src/agents → agents}/index.js +0 -0
  638. /package/script/{harness/npm/src/agents → agents}/loader.d.ts +0 -0
  639. /package/script/{harness/npm/src/agents → agents}/loader.js +0 -0
  640. /package/script/{harness/npm/src/agents → agents}/parser.d.ts +0 -0
  641. /package/script/{harness/npm/src/agents → agents}/parser.js +0 -0
  642. /package/script/{harness/npm/src/agents → agents}/registry.d.ts +0 -0
  643. /package/script/{harness/npm/src/agents → agents}/registry.js +0 -0
  644. /package/{esm/harness/src → script}/agents/types.d.ts +0 -0
  645. /package/script/{harness/npm/src/agents → agents}/types.js +0 -0
  646. /package/script/{harness/npm/src/channels → channels}/channel.d.ts +0 -0
  647. /package/script/{harness/npm/src/channels → channels}/channel.js +0 -0
  648. /package/script/{harness/npm/src/channels → channels}/index.d.ts +0 -0
  649. /package/script/{harness/npm/src/channels → channels}/index.js +0 -0
  650. /package/script/{harness/npm/src/channels → channels}/manager.d.ts +0 -0
  651. /package/script/{harness/npm/src/channels → channels}/manager.js +0 -0
  652. /package/script/{harness/npm/src/channels → channels}/types.d.ts +0 -0
  653. /package/script/{harness/npm/src/channels → channels}/types.js +0 -0
  654. /package/script/{harness/npm/src/commands → commands}/defaults.d.ts +0 -0
  655. /package/script/{harness/npm/src/commands → commands}/defaults.js +0 -0
  656. /package/script/{harness/npm/src/commands → commands}/index.d.ts +0 -0
  657. /package/script/{harness/npm/src/commands → commands}/index.js +0 -0
  658. /package/script/{harness/npm/src/commands → commands}/registry.d.ts +0 -0
  659. /package/script/{harness/npm/src/commands → commands}/registry.js +0 -0
  660. /package/{esm/harness/src → script}/commands/types.d.ts +0 -0
  661. /package/script/{harness/npm/src/commands → commands}/types.js +0 -0
  662. /package/{esm/harness/src → script}/common/frontmatter.d.ts +0 -0
  663. /package/script/{harness/npm/src/common → common}/frontmatter.js +0 -0
  664. /package/script/{harness/npm/src/common → common}/index.d.ts +0 -0
  665. /package/script/{harness/npm/src/common → common}/index.js +0 -0
  666. /package/{esm/harness/src → script}/common/utils.d.ts +0 -0
  667. /package/script/{harness/npm/src/common → common}/utils.js +0 -0
  668. /package/script/{harness/npm/src/config → config}/index.d.ts +0 -0
  669. /package/script/{harness/npm/src/config → config}/index.js +0 -0
  670. /package/script/{harness/npm/src/config → config}/resolve.d.ts +0 -0
  671. /package/script/{harness/npm/src/config → config}/resolve.js +0 -0
  672. /package/{esm/harness/src → script}/config/types.d.ts +0 -0
  673. /package/script/{harness/npm/src/config → config}/types.js +0 -0
  674. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_chars.d.ts +0 -0
  675. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_chars.js +0 -0
  676. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_dumper_state.d.ts +0 -0
  677. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_dumper_state.js +0 -0
  678. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_loader_state.d.ts +0 -0
  679. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_loader_state.js +0 -0
  680. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_schema.d.ts +0 -0
  681. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_schema.js +0 -0
  682. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/binary.d.ts +0 -0
  683. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/binary.js +0 -0
  684. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/bool.d.ts +0 -0
  685. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/bool.js +0 -0
  686. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/float.d.ts +0 -0
  687. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/float.js +0 -0
  688. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/int.d.ts +0 -0
  689. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/int.js +0 -0
  690. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/map.d.ts +0 -0
  691. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/map.js +0 -0
  692. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/merge.d.ts +0 -0
  693. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/merge.js +0 -0
  694. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/nil.d.ts +0 -0
  695. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/nil.js +0 -0
  696. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/omap.d.ts +0 -0
  697. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/omap.js +0 -0
  698. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/pairs.d.ts +0 -0
  699. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/pairs.js +0 -0
  700. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/regexp.d.ts +0 -0
  701. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/regexp.js +0 -0
  702. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/seq.d.ts +0 -0
  703. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/seq.js +0 -0
  704. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/set.d.ts +0 -0
  705. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/set.js +0 -0
  706. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/str.d.ts +0 -0
  707. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/str.js +0 -0
  708. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/timestamp.d.ts +0 -0
  709. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/timestamp.js +0 -0
  710. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/undefined.d.ts +0 -0
  711. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type/undefined.js +0 -0
  712. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type.d.ts +0 -0
  713. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_type.js +0 -0
  714. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_utils.d.ts +0 -0
  715. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/_utils.js +0 -0
  716. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/mod.d.ts +0 -0
  717. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/mod.js +0 -0
  718. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/parse.d.ts +0 -0
  719. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/parse.js +0 -0
  720. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/stringify.d.ts +0 -0
  721. /package/script/{harness/npm/src/deps → deps}/jsr.io/@std/yaml/1.1.0/stringify.js +0 -0
  722. /package/script/harness/{npm/src/harness/create.d.ts → create.d.ts} +0 -0
  723. /package/script/harness/{npm/src/harness/create.js → create.js} +0 -0
  724. /package/script/harness/{npm/src/harness/index.d.ts → index.d.ts} +0 -0
  725. /package/script/harness/{npm/src/harness/index.js → index.js} +0 -0
  726. /package/{esm/harness/src → script}/harness/models.d.ts +0 -0
  727. /package/script/harness/{npm/src/harness/models.js → models.js} +0 -0
  728. /package/script/harness/{npm/src/harness/types.d.ts → types.d.ts} +0 -0
  729. /package/script/harness/{npm/src/harness/types.js → types.js} +0 -0
  730. /package/script/{harness/npm/src/hooks → hooks}/index.d.ts +0 -0
  731. /package/script/{harness/npm/src/hooks → hooks}/index.js +0 -0
  732. /package/script/{harness/npm/src/hooks → hooks}/merge-hooks.d.ts +0 -0
  733. /package/script/{harness/npm/src/hooks → hooks}/merge-hooks.js +0 -0
  734. /package/{esm/harness/src → script}/hooks/types.d.ts +0 -0
  735. /package/script/{harness/npm/src/hooks → hooks}/types.js +0 -0
  736. /package/script/{harness/npm/src/hooks → hooks}/with-hooks.d.ts +0 -0
  737. /package/script/{harness/npm/src/hooks → hooks}/with-hooks.js +0 -0
  738. /package/script/{harness/npm/src/index.d.ts → index.d.ts} +0 -0
  739. /package/script/{harness/npm/src/index.js → index.js} +0 -0
  740. /package/script/{harness/npm/src/permissions → permissions}/allow-list.d.ts +0 -0
  741. /package/script/{harness/npm/src/permissions → permissions}/allow-list.js +0 -0
  742. /package/script/{harness/npm/src/permissions → permissions}/approval-manager.d.ts +0 -0
  743. /package/script/{harness/npm/src/permissions → permissions}/approval-manager.js +0 -0
  744. /package/script/{harness/npm/src/permissions → permissions}/approval.d.ts +0 -0
  745. /package/script/{harness/npm/src/permissions → permissions}/approval.js +0 -0
  746. /package/{esm/harness/src → script}/permissions/glob.d.ts +0 -0
  747. /package/script/{harness/npm/src/permissions → permissions}/glob.js +0 -0
  748. /package/script/{harness/npm/src/permissions → permissions}/index.d.ts +0 -0
  749. /package/script/{harness/npm/src/permissions → permissions}/index.js +0 -0
  750. /package/script/{harness/npm/src/plugin → plugin}/define.d.ts +0 -0
  751. /package/script/{harness/npm/src/plugin → plugin}/define.js +0 -0
  752. /package/{esm/harness/src → script}/plugin/import-ts.d.ts +0 -0
  753. /package/script/{harness/npm/src/plugin → plugin}/import-ts.js +0 -0
  754. /package/script/{harness/npm/src/plugin → plugin}/index.d.ts +0 -0
  755. /package/script/{harness/npm/src/plugin → plugin}/index.js +0 -0
  756. /package/script/{harness/npm/src/plugin → plugin}/resolve.d.ts +0 -0
  757. /package/script/{harness/npm/src/plugin → plugin}/resolve.js +0 -0
  758. /package/{esm/harness/src → script}/plugin/store.d.ts +0 -0
  759. /package/script/{harness/npm/src/plugin → plugin}/store.js +0 -0
  760. /package/script/{harness/npm/src/plugin → plugin}/types.d.ts +0 -0
  761. /package/script/{harness/npm/src/plugin → plugin}/types.js +0 -0
  762. /package/script/{harness/npm/src/scheduler → scheduler}/command.d.ts +0 -0
  763. /package/script/{harness/npm/src/scheduler → scheduler}/command.js +0 -0
  764. /package/script/{harness/npm/src/scheduler → scheduler}/engine/index.d.ts +0 -0
  765. /package/script/{harness/npm/src/scheduler → scheduler}/engine/index.js +0 -0
  766. /package/script/{harness/npm/src/scheduler → scheduler}/engine/memory-store.d.ts +0 -0
  767. /package/script/{harness/npm/src/scheduler → scheduler}/engine/memory-store.js +0 -0
  768. /package/script/{harness/npm/src/scheduler → scheduler}/engine/scheduler.d.ts +0 -0
  769. /package/script/{harness/npm/src/scheduler → scheduler}/engine/scheduler.js +0 -0
  770. /package/script/{harness/npm/src/scheduler → scheduler}/engine/store.d.ts +0 -0
  771. /package/script/{harness/npm/src/scheduler → scheduler}/engine/store.js +0 -0
  772. /package/{esm/harness/src → script}/scheduler/engine/types.d.ts +0 -0
  773. /package/script/{harness/npm/src/scheduler → scheduler}/engine/types.js +0 -0
  774. /package/script/{harness/npm/src/scheduler → scheduler}/index.d.ts +0 -0
  775. /package/script/{harness/npm/src/scheduler → scheduler}/index.js +0 -0
  776. /package/script/{harness/npm/src/scheduler → scheduler}/tool.d.ts +0 -0
  777. /package/script/{harness/npm/src/scheduler → scheduler}/tool.js +0 -0
  778. /package/script/{harness/npm/src/session → session}/agent-session.d.ts +0 -0
  779. /package/script/{harness/npm/src/session → session}/agent-session.js +0 -0
  780. /package/{esm/harness/src → script}/session/catalog.d.ts +0 -0
  781. /package/script/{harness/npm/src/session → session}/catalog.js +0 -0
  782. /package/script/{harness/npm/src/session → session}/index.d.ts +0 -0
  783. /package/script/{harness/npm/src/session → session}/index.js +0 -0
  784. /package/script/{harness/npm/src/session → session}/manager.d.ts +0 -0
  785. /package/script/{harness/npm/src/session → session}/manager.js +0 -0
  786. /package/script/{harness/npm/src/session → session}/persist.d.ts +0 -0
  787. /package/script/{harness/npm/src/session → session}/persist.js +0 -0
  788. /package/{esm/harness/src → script}/session/store.d.ts +0 -0
  789. /package/script/{harness/npm/src/session → session}/store.js +0 -0
  790. /package/{esm/harness/src → script}/session/title.d.ts +0 -0
  791. /package/script/{harness/npm/src/session → session}/title.js +0 -0
  792. /package/{esm/harness/src → script}/session/types.d.ts +0 -0
  793. /package/script/{harness/npm/src/session → session}/types.js +0 -0
  794. /package/script/{harness/npm/src/skills → skills}/index.d.ts +0 -0
  795. /package/script/{harness/npm/src/skills → skills}/index.js +0 -0
  796. /package/script/{harness/npm/src/skills → skills}/loader.d.ts +0 -0
  797. /package/script/{harness/npm/src/skills → skills}/loader.js +0 -0
  798. /package/script/{harness/npm/src/skills → skills}/parser.d.ts +0 -0
  799. /package/script/{harness/npm/src/skills → skills}/parser.js +0 -0
  800. /package/{esm/harness/src → script}/skills/platform.d.ts +0 -0
  801. /package/script/{harness/npm/src/skills → skills}/platform.js +0 -0
  802. /package/script/{harness/npm/src/skills → skills}/registry.d.ts +0 -0
  803. /package/script/{harness/npm/src/skills → skills}/registry.js +0 -0
  804. /package/script/{harness/npm/src/skills → skills}/run.d.ts +0 -0
  805. /package/script/{harness/npm/src/skills → skills}/run.js +0 -0
  806. /package/script/{harness/npm/src/skills → skills}/tool.d.ts +0 -0
  807. /package/script/{harness/npm/src/skills → skills}/tool.js +0 -0
  808. /package/{esm/harness/src → script}/skills/types.d.ts +0 -0
  809. /package/script/{harness/npm/src/skills → skills}/types.js +0 -0
  810. /package/script/{harness/npm/src/skills → skills}/writer.d.ts +0 -0
  811. /package/script/{harness/npm/src/skills → skills}/writer.js +0 -0
  812. /package/script/{harness/npm/src/subAgents → subAgents}/index.d.ts +0 -0
  813. /package/script/{harness/npm/src/subAgents → subAgents}/index.js +0 -0
  814. /package/script/{harness/npm/src/subAgents → subAgents}/registry.d.ts +0 -0
  815. /package/script/{harness/npm/src/subAgents → subAgents}/registry.js +0 -0
  816. /package/script/{harness/npm/src/subAgents → subAgents}/runner.d.ts +0 -0
  817. /package/script/{harness/npm/src/subAgents → subAgents}/runner.js +0 -0
  818. /package/script/{harness/npm/src/subAgents → subAgents}/tool.d.ts +0 -0
  819. /package/script/{harness/npm/src/subAgents → subAgents}/tool.js +0 -0
  820. /package/script/{harness/npm/src/subAgents → subAgents}/types.d.ts +0 -0
  821. /package/script/{harness/npm/src/subAgents → subAgents}/types.js +0 -0
  822. /package/script/{harness/npm/src/tui → tui}/chat/ChatApp.d.ts +0 -0
  823. /package/script/{harness/npm/src/tui → tui}/chat/ChatApp.js +0 -0
  824. /package/{esm/harness/src → script}/tui/chat/commands.d.ts +0 -0
  825. /package/script/{harness/npm/src/tui → tui}/chat/commands.js +0 -0
  826. /package/{esm/harness/src → script}/tui/chat/editor.d.ts +0 -0
  827. /package/script/{harness/npm/src/tui → tui}/chat/editor.js +0 -0
  828. /package/script/{harness/npm/src/tui → tui}/chat/index.d.ts +0 -0
  829. /package/script/{harness/npm/src/tui → tui}/chat/index.js +0 -0
  830. /package/script/{harness/npm/src/tui → tui}/chat/markdown.d.ts +0 -0
  831. /package/script/{harness/npm/src/tui → tui}/chat/markdown.js +0 -0
  832. /package/{esm/harness/src → script}/tui/chat/picker.d.ts +0 -0
  833. /package/script/{harness/npm/src/tui → tui}/chat/picker.js +0 -0
  834. /package/script/{harness/npm/src/tui → tui}/chat/status.d.ts +0 -0
  835. /package/script/{harness/npm/src/tui → tui}/chat/status.js +0 -0
  836. /package/{esm/harness/src → script}/tui/chat/theme.d.ts +0 -0
  837. /package/script/{harness/npm/src/tui → tui}/chat/theme.js +0 -0
  838. /package/script/{harness/npm/src/tui → tui}/chat/transcript.d.ts +0 -0
  839. /package/script/{harness/npm/src/tui → tui}/chat/transcript.js +0 -0
  840. /package/script/{harness/npm/src/tui → tui}/index.d.ts +0 -0
  841. /package/script/{harness/npm/src/tui → tui}/index.js +0 -0
package/package.json CHANGED
@@ -1,14 +1,20 @@
1
1
  {
2
2
  "name": "mu-harness",
3
- "version": "0.16.15",
3
+ "version": "0.16.16",
4
4
  "description": "Agent harness: createHarness wires mu-core into a host — XDG paths, model registry, plugins, disk-loaded agents & skills, sub-agents, sessions (JSONL + SQLite catalog), slash commands, permission/approval hooks, an optional scheduler, and a composable TUI chat app",
5
5
  "license": "MIT",
6
6
  "main": "./script/index.js",
7
7
  "module": "./esm/index.js",
8
8
  "exports": {
9
9
  ".": {
10
- "import": "./esm/index.js",
11
- "require": "./script/index.js"
10
+ "import": {
11
+ "types": "./esm/index.d.ts",
12
+ "default": "./esm/index.js"
13
+ },
14
+ "require": {
15
+ "types": "./script/index.d.ts",
16
+ "default": "./script/index.js"
17
+ }
12
18
  }
13
19
  },
14
20
  "scripts": {},
@@ -17,9 +23,9 @@
17
23
  "@swc/wasm-typescript": "^1.15.0",
18
24
  "cli-highlight": "^2.1.11",
19
25
  "croner": "^9.0.0",
20
- "mu-core": "^0.16.15",
21
- "mu-harness": "^0.16.15",
22
- "mu-tui": "^0.16.15"
26
+ "mu-core": "^0.16.16",
27
+ "mu-tui": "^0.16.16"
23
28
  },
24
- "_generatedBy": "dnt@dev"
25
- }
29
+ "_generatedBy": "dnt@dev",
30
+ "types": "./esm/index.d.ts"
31
+ }
@@ -1,39 +0,0 @@
1
- import type { ContentPart, Message, Provider, Tool, Usage } from './types';
2
- export type LoopEvent = ContentPart | {
3
- type: 'usage';
4
- usage: Usage;
5
- } | {
6
- type: 'reasoning';
7
- text: string;
8
- } | {
9
- type: 'message';
10
- message: Message;
11
- } | {
12
- type: 'done';
13
- messages: Message[];
14
- };
15
- export interface RunOptions {
16
- provider: Provider;
17
- model: string;
18
- messages: Message[];
19
- tools?: Tool[];
20
- signal?: AbortSignal;
21
- }
22
- export declare function run(opts: RunOptions): AsyncIterable<LoopEvent>;
23
- export interface AgentConfig {
24
- provider: Provider;
25
- model: string;
26
- tools?: Tool[];
27
- system?: string;
28
- signal?: AbortSignal;
29
- }
30
- export type Input = string | ContentPart[] | Message[];
31
- export interface AgentResult {
32
- message: Message;
33
- messages: Message[];
34
- }
35
- export interface Agent {
36
- stream(input: Input): AsyncIterable<LoopEvent>;
37
- run(input: Input): Promise<AgentResult>;
38
- }
39
- export declare const createAgent: (config: AgentConfig) => Agent;
@@ -1,96 +0,0 @@
1
- const append = (parts, part) => {
2
- const last = parts[parts.length - 1];
3
- if (part.type === 'text' && last?.type === 'text') {
4
- last.text += part.text;
5
- }
6
- else if (part.type === 'audio' && last?.type === 'audio' && last.mime === part.mime) {
7
- const merged = new Uint8Array(last.data.length + part.data.length);
8
- merged.set(last.data);
9
- merged.set(part.data, last.data.length);
10
- last.data = merged;
11
- }
12
- else if (part.type === 'text') {
13
- parts.push({ type: 'text', text: part.text });
14
- }
15
- else if (part.type === 'audio') {
16
- parts.push({ type: 'audio', mime: part.mime, data: part.data });
17
- }
18
- else {
19
- parts.push(part);
20
- }
21
- };
22
- const execute = async (tools, call, signal) => {
23
- const tool = tools.get(call.name);
24
- if (!tool)
25
- return [{ type: 'text', text: `Unknown tool: ${call.name}` }];
26
- try {
27
- return await tool.run(call.input, { signal });
28
- }
29
- catch (err) {
30
- return [{ type: 'text', text: err instanceof Error ? err.message : String(err) }];
31
- }
32
- };
33
- export async function* run(opts) {
34
- const { provider, model, signal } = opts;
35
- const tools = opts.tools ?? [];
36
- const registry = new Map(tools.map((t) => [t.name, t]));
37
- const messages = [...opts.messages];
38
- while (true) {
39
- const content = [];
40
- const calls = [];
41
- for await (const event of provider.stream({ model, messages, tools, signal })) {
42
- if (event.type === 'usage' || event.type === 'reasoning') {
43
- yield event;
44
- continue;
45
- }
46
- yield event;
47
- append(content, event);
48
- if (event.type === 'tool_call')
49
- calls.push(event);
50
- }
51
- const message = { role: 'assistant', content };
52
- messages.push(message);
53
- yield { type: 'message', message };
54
- if (calls.length === 0)
55
- break;
56
- const results = await Promise.all(calls.map(async (call) => ({
57
- type: 'tool_result',
58
- id: call.id,
59
- content: await execute(registry, call, signal),
60
- })));
61
- const toolMessage = { role: 'user', content: results };
62
- messages.push(toolMessage);
63
- yield { type: 'message', message: toolMessage };
64
- }
65
- yield { type: 'done', messages };
66
- }
67
- const isMessages = (input) => input.length > 0 && 'role' in input[0];
68
- const toMessages = (input) => {
69
- if (typeof input === 'string')
70
- return [{ role: 'user', content: [{ type: 'text', text: input }] }];
71
- if (isMessages(input))
72
- return input;
73
- return [{ role: 'user', content: input }];
74
- };
75
- export const createAgent = (config) => {
76
- const tools = config.tools ?? [];
77
- const build = (input) => {
78
- const messages = toMessages(input);
79
- if (!config.system)
80
- return messages;
81
- return [{ role: 'system', content: [{ type: 'text', text: config.system }] }, ...messages];
82
- };
83
- const stream = (input) => run({ provider: config.provider, model: config.model, tools, messages: build(input), signal: config.signal });
84
- const runToEnd = async (input) => {
85
- let message = { role: 'assistant', content: [] };
86
- let messages = [];
87
- for await (const event of stream(input)) {
88
- if (event.type === 'message' && event.message.role === 'assistant')
89
- message = event.message;
90
- else if (event.type === 'done')
91
- messages = event.messages;
92
- }
93
- return { message, messages };
94
- };
95
- return { stream, run: runToEnd };
96
- };
@@ -1,4 +0,0 @@
1
- export type { ContentPart, Message, Provider, Role, StreamEvent, Tool, Usage } from './types';
2
- export { audio, image, text } from './types';
3
- export type { Agent, AgentConfig, AgentResult, Input, LoopEvent, RunOptions } from './agent';
4
- export { createAgent, run } from './agent';
@@ -1,2 +0,0 @@
1
- export { audio, image, text } from './types';
2
- export { createAgent, run } from './agent';
@@ -1,59 +0,0 @@
1
- export type ContentPart = {
2
- type: 'text';
3
- text: string;
4
- } | {
5
- type: 'image';
6
- mime: string;
7
- data: Uint8Array;
8
- } | {
9
- type: 'audio';
10
- mime: string;
11
- data: Uint8Array;
12
- } | {
13
- type: 'tool_call';
14
- id: string;
15
- name: string;
16
- input: unknown;
17
- } | {
18
- type: 'tool_result';
19
- id: string;
20
- content: ContentPart[];
21
- };
22
- export type Role = 'system' | 'user' | 'assistant';
23
- export type Message = {
24
- role: Role;
25
- content: ContentPart[];
26
- };
27
- export declare const text: (value: string) => ContentPart;
28
- export declare const image: (mime: string, data: Uint8Array) => ContentPart;
29
- export declare const audio: (mime: string, data: Uint8Array) => ContentPart;
30
- export interface Tool {
31
- name: string;
32
- description: string;
33
- parameters: Record<string, unknown>;
34
- prompt?: string;
35
- run(input: unknown, ctx: {
36
- signal?: AbortSignal;
37
- }): Promise<ContentPart[]>;
38
- }
39
- export interface Usage {
40
- input?: number;
41
- output?: number;
42
- total?: number;
43
- contextWindow?: number;
44
- }
45
- export type StreamEvent = ContentPart | {
46
- type: 'usage';
47
- usage: Usage;
48
- } | {
49
- type: 'reasoning';
50
- text: string;
51
- };
52
- export interface Provider {
53
- stream(req: {
54
- model: string;
55
- messages: Message[];
56
- tools: Tool[];
57
- signal?: AbortSignal;
58
- }): AsyncIterable<StreamEvent>;
59
- }
@@ -1,3 +0,0 @@
1
- export const text = (value) => ({ type: 'text', text: value });
2
- export const image = (mime, data) => ({ type: 'image', mime, data });
3
- export const audio = (mime, data) => ({ type: 'audio', mime, data });
@@ -1,4 +0,0 @@
1
- export type { Agent, GrantValue, ToolDecision, ToolGrants } from './types';
2
- export { type AgentRegistry, createAgentRegistry, grantArg, toolDecision, toolNames } from './registry';
3
- export { parseAgent } from './parser';
4
- export { loadAgents } from './loader';
@@ -1,3 +0,0 @@
1
- export { createAgentRegistry, grantArg, toolDecision, toolNames } from './registry';
2
- export { parseAgent } from './parser';
3
- export { loadAgents } from './loader';
@@ -1,2 +0,0 @@
1
- import type { Agent } from './types';
2
- export declare const loadAgents: (dir: string) => Promise<Agent[]>;
@@ -1,24 +0,0 @@
1
- import { readdir, readFile } from 'node:fs/promises';
2
- import { basename, join } from 'node:path';
3
- import { parseAgent } from './parser';
4
- export const loadAgents = async (dir) => {
5
- let entries;
6
- try {
7
- entries = await readdir(dir);
8
- }
9
- catch {
10
- return [];
11
- }
12
- const files = entries.filter((name) => name.endsWith('.md')).sort();
13
- const agents = [];
14
- for (const file of files) {
15
- try {
16
- const source = await readFile(join(dir, file), 'utf-8');
17
- agents.push(parseAgent(source, basename(file, '.md')));
18
- }
19
- catch {
20
- continue;
21
- }
22
- }
23
- return agents;
24
- };
@@ -1,2 +0,0 @@
1
- import type { Agent } from './types';
2
- export declare const parseAgent: (source: string, fallbackName: string) => Agent;
@@ -1,46 +0,0 @@
1
- import { parseFrontmatter, str } from '../common';
2
- const DECISIONS = new Set(['allow', 'ask', 'deny']);
3
- const isDecision = (value) => typeof value === 'string' && DECISIONS.has(value);
4
- const parseStringList = (raw) => (Array.isArray(raw) ? raw : raw.split(','))
5
- .filter((entry) => typeof entry === 'string')
6
- .map((entry) => entry.trim())
7
- .filter(Boolean);
8
- const parseDecisionMap = (raw) => {
9
- const out = {};
10
- for (const [key, value] of Object.entries(raw))
11
- if (isDecision(value))
12
- out[key] = value;
13
- return Object.keys(out).length > 0 ? out : undefined;
14
- };
15
- const parseTools = (raw) => {
16
- if (Array.isArray(raw) || typeof raw === 'string') {
17
- const list = parseStringList(raw);
18
- return list.length > 0 ? list : undefined;
19
- }
20
- if (raw && typeof raw === 'object') {
21
- const out = {};
22
- for (const [tool, value] of Object.entries(raw)) {
23
- if (isDecision(value))
24
- out[tool] = value;
25
- else if (value && typeof value === 'object' && !Array.isArray(value)) {
26
- const nested = parseDecisionMap(value);
27
- if (nested)
28
- out[tool] = nested;
29
- }
30
- }
31
- return Object.keys(out).length > 0 ? out : undefined;
32
- }
33
- return undefined;
34
- };
35
- export const parseAgent = (source, fallbackName) => {
36
- const { fields, body } = parseFrontmatter(source);
37
- return {
38
- name: str(fields.name) ?? fallbackName,
39
- description: str(fields.description) ?? '',
40
- prompt: body,
41
- tools: parseTools(fields.tools),
42
- model: str(fields.model),
43
- color: str(fields.color),
44
- extends: str(fields.extends),
45
- };
46
- };
@@ -1,9 +0,0 @@
1
- import type { Agent, ToolDecision } from './types';
2
- export interface AgentRegistry {
3
- list(): Agent[];
4
- get(name: string): Agent | undefined;
5
- }
6
- export declare const grantArg: (tool: string, input: unknown) => string | undefined;
7
- export declare const toolDecision: (agent: Agent, tool: string, arg?: string) => ToolDecision;
8
- export declare const toolNames: (agent: Agent) => string[] | undefined;
9
- export declare const createAgentRegistry: (agents?: Agent[]) => AgentRegistry;
@@ -1,88 +0,0 @@
1
- import { matchesGlob } from 'node:path';
2
- const asMap = (grants) => {
3
- if (!grants)
4
- return undefined;
5
- if (Array.isArray(grants))
6
- return Object.fromEntries(grants.map((name) => [name, 'allow']));
7
- return grants;
8
- };
9
- const matchKey = (keys, name) => {
10
- if (keys.includes(name))
11
- return name;
12
- let glob;
13
- for (const key of keys) {
14
- if (key === '*' || key === name)
15
- continue;
16
- if (matchesGlob(name, key) && (glob === undefined || key.length > glob.length))
17
- glob = key;
18
- }
19
- if (glob !== undefined)
20
- return glob;
21
- return keys.includes('*') ? '*' : undefined;
22
- };
23
- const resolveGrant = (grants, tool, arg) => {
24
- const map = asMap(grants);
25
- if (!map)
26
- return 'allow';
27
- const key = matchKey(Object.keys(map), tool);
28
- if (key === undefined)
29
- return 'deny';
30
- const value = map[key];
31
- if (typeof value === 'string')
32
- return value;
33
- if (arg === undefined)
34
- return 'allow';
35
- const inner = matchKey(Object.keys(value), arg);
36
- return inner === undefined ? 'deny' : value[inner];
37
- };
38
- const grantNames = (grants) => {
39
- const map = asMap(grants);
40
- if (!map)
41
- return undefined;
42
- const wildcard = map['*'];
43
- if (wildcard !== undefined && wildcard !== 'deny')
44
- return ['*'];
45
- return Object.entries(map).filter(([, value]) => value !== 'deny').map(([name]) => name);
46
- };
47
- const GRANT_ARG = { skill: 'name', bash: 'command' };
48
- export const grantArg = (tool, input) => {
49
- const field = GRANT_ARG[tool];
50
- if (!field || typeof input !== 'object' || input === null)
51
- return undefined;
52
- const value = input[field];
53
- return typeof value === 'string' ? value : undefined;
54
- };
55
- export const toolDecision = (agent, tool, arg) => resolveGrant(agent.tools, tool, arg);
56
- export const toolNames = (agent) => grantNames(agent.tools);
57
- const merge = (base, child) => ({
58
- name: child.name,
59
- description: child.description || base.description,
60
- prompt: child.prompt || base.prompt,
61
- tools: child.tools ?? base.tools,
62
- model: child.model ?? base.model,
63
- color: child.color ?? base.color,
64
- });
65
- export const createAgentRegistry = (agents = []) => {
66
- const raw = new Map();
67
- for (const agent of agents)
68
- if (!raw.has(agent.name))
69
- raw.set(agent.name, agent);
70
- const resolve = (name, seen) => {
71
- const agent = raw.get(name);
72
- if (!agent.extends)
73
- return agent;
74
- if (seen.has(name))
75
- throw new Error(`AgentRegistry: "extends" cycle at "${name}"`);
76
- const base = raw.get(agent.extends);
77
- if (!base)
78
- throw new Error(`AgentRegistry: "${name}" extends unknown agent "${agent.extends}"`);
79
- return merge(resolve(agent.extends, new Set(seen).add(name)), agent);
80
- };
81
- const byName = new Map();
82
- for (const name of raw.keys())
83
- byName.set(name, resolve(name, new Set()));
84
- return {
85
- list: () => [...byName.values()],
86
- get: (name) => byName.get(name),
87
- };
88
- };
@@ -1 +0,0 @@
1
- export {};
@@ -1,7 +0,0 @@
1
- import type { AgentSession } from '../session';
2
- import type { Channel } from './types';
3
- export declare const createChannel: (config: {
4
- id: string;
5
- title: string;
6
- createSession: () => AgentSession;
7
- }) => Channel;
@@ -1,25 +0,0 @@
1
- import { createEmitter } from '../common';
2
- export const createChannel = (config) => {
3
- let session;
4
- const emitter = createEmitter();
5
- const ensure = () => {
6
- if (!session) {
7
- session = config.createSession();
8
- session.subscribe(emitter.emit);
9
- }
10
- return session;
11
- };
12
- return {
13
- id: config.id,
14
- title: config.title,
15
- get started() {
16
- return session !== undefined;
17
- },
18
- get messages() {
19
- return session?.messages ?? [];
20
- },
21
- send: (input) => ensure().send(input),
22
- abort: () => session?.abort(),
23
- subscribe: emitter.subscribe,
24
- };
25
- };
@@ -1,3 +0,0 @@
1
- export type { Channel, ChannelEvent, ChannelManager, ChannelManagerEvent } from './types';
2
- export { createChannel } from './channel';
3
- export { createChannelManager } from './manager';
@@ -1,2 +0,0 @@
1
- export { createChannel } from './channel';
2
- export { createChannelManager } from './manager';
@@ -1,6 +0,0 @@
1
- import type { AgentSession } from '../session';
2
- import type { ChannelManager } from './types';
3
- export declare const createChannelManager: (config: {
4
- createSession: () => AgentSession;
5
- idGen?: () => string;
6
- }) => ChannelManager;
@@ -1,28 +0,0 @@
1
- import { createEmitter } from '../common';
2
- import { createChannel } from './channel';
3
- export const createChannelManager = (config) => {
4
- const channels = new Map();
5
- const unsubs = new Map();
6
- const emitter = createEmitter();
7
- const idGen = config.idGen ?? (() => crypto.randomUUID());
8
- return {
9
- open(opts) {
10
- const id = opts?.id ?? idGen();
11
- const title = opts?.title ?? id;
12
- const channel = createChannel({ id, title, createSession: config.createSession });
13
- channels.set(id, channel);
14
- unsubs.set(id, channel.subscribe((event) => emitter.emit({ channelId: id, ...event })));
15
- emitter.emit({ channelId: id, type: 'channel_open', title });
16
- return channel;
17
- },
18
- get: (id) => channels.get(id),
19
- list: () => [...channels.values()],
20
- close(id) {
21
- unsubs.get(id)?.();
22
- unsubs.delete(id);
23
- if (channels.delete(id))
24
- emitter.emit({ channelId: id, type: 'channel_close' });
25
- },
26
- subscribe: emitter.subscribe,
27
- };
28
- };
@@ -1,30 +0,0 @@
1
- import type { ContentPart, Message } from 'mu-core';
2
- import type { AgentSessionEvent } from '../session';
3
- export type ChannelEvent = AgentSessionEvent | {
4
- type: 'channel_open';
5
- title: string;
6
- } | {
7
- type: 'channel_close';
8
- };
9
- export type ChannelManagerEvent = {
10
- channelId: string;
11
- } & ChannelEvent;
12
- export interface Channel {
13
- readonly id: string;
14
- readonly title: string;
15
- readonly started: boolean;
16
- readonly messages: readonly Message[];
17
- send(input: string | ContentPart[]): Promise<void>;
18
- abort(): void;
19
- subscribe(listener: (event: AgentSessionEvent) => void): () => void;
20
- }
21
- export interface ChannelManager {
22
- open(opts?: {
23
- id?: string;
24
- title?: string;
25
- }): Channel;
26
- get(id: string): Channel | undefined;
27
- list(): Channel[];
28
- close(id: string): void;
29
- subscribe(listener: (event: ChannelManagerEvent) => void): () => void;
30
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,11 +0,0 @@
1
- import type { AgentRegistry } from '../agents';
2
- import type { SessionManager } from '../session';
3
- import type { SkillRegistry } from '../skills';
4
- import type { Command } from './types';
5
- export declare const createAgentsCommand: (agents: AgentRegistry) => Command;
6
- export declare const createSkillsCommand: (skills: SkillRegistry) => Command;
7
- export declare const createSessionsCommand: (sessions: SessionManager, options?: {
8
- cwd?: string;
9
- }) => Command;
10
- export declare const createQuitCommand: (onQuit: () => void | Promise<void>) => Command;
11
- export declare const createHelpCommand: (list: () => Command[]) => Command;
@@ -1,53 +0,0 @@
1
- export const createAgentsCommand = (agents) => ({
2
- name: 'agents',
3
- description: 'List available agents',
4
- run: () => {
5
- const list = agents.list();
6
- if (list.length === 0)
7
- return { ok: true, output: 'No agents configured.' };
8
- const lines = list.map((a) => `- ${a.name}${a.description ? ` — ${a.description}` : ''}`);
9
- return { ok: true, output: lines.join('\n') };
10
- },
11
- });
12
- export const createSkillsCommand = (skills) => ({
13
- name: 'skills',
14
- description: 'List available skills',
15
- run: () => {
16
- const list = skills.list();
17
- if (list.length === 0)
18
- return { ok: true, output: 'No skills configured.' };
19
- const lines = list.map((s) => `- ${s.name}${s.description ? ` — ${s.description}` : ''}`);
20
- return { ok: true, output: lines.join('\n') };
21
- },
22
- });
23
- export const createSessionsCommand = (sessions, options) => ({
24
- name: 'sessions',
25
- description: 'List saved sessions',
26
- run: async () => {
27
- const list = await sessions.list(options?.cwd ? { cwd: options.cwd } : undefined);
28
- if (list.length === 0)
29
- return { ok: true, output: 'No sessions yet.' };
30
- const lines = list.map((s) => `- ${s.title || s.id}`);
31
- return { ok: true, output: lines.join('\n') };
32
- },
33
- });
34
- export const createQuitCommand = (onQuit) => ({
35
- name: 'quit',
36
- description: 'Exit the session',
37
- aliases: ['q'],
38
- run: async () => {
39
- await onQuit();
40
- return { ok: true };
41
- },
42
- });
43
- export const createHelpCommand = (list) => ({
44
- name: 'help',
45
- description: 'Show available commands',
46
- run: () => {
47
- const commands = list();
48
- if (commands.length === 0)
49
- return { ok: true, output: 'No commands registered.' };
50
- const lines = commands.map((c) => `/${c.name} — ${c.description}`);
51
- return { ok: true, output: lines.join('\n') };
52
- },
53
- });
@@ -1,3 +0,0 @@
1
- export { createAgentsCommand, createHelpCommand, createQuitCommand, createSessionsCommand, createSkillsCommand, } from './defaults';
2
- export { createCommandRegistry } from './registry';
3
- export type { Command, CommandContext, CommandRegistry, CommandResult } from './types';
@@ -1,2 +0,0 @@
1
- export { createAgentsCommand, createHelpCommand, createQuitCommand, createSessionsCommand, createSkillsCommand, } from './defaults';
2
- export { createCommandRegistry } from './registry';
@@ -1,2 +0,0 @@
1
- import type { Command, CommandRegistry } from './types';
2
- export declare const createCommandRegistry: (commands?: Command[]) => CommandRegistry;