thursday-agent 0.4.0 → 0.6.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 (657) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-path-routes-manifest.json +3 -2
  3. package/.next/build-manifest.json +3 -3
  4. package/.next/prerender-manifest.json +3 -3
  5. package/.next/required-server-files.json +8 -1
  6. package/.next/routes-manifest.json +18 -6
  7. package/.next/server/app/_global-error/page.js.nft.json +1 -1
  8. package/.next/server/app/_global-error.html +1 -1
  9. package/.next/server/app/_global-error.rsc +1 -1
  10. package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  11. package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  12. package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  13. package/.next/server/app/_not-found/page.js.nft.json +1 -1
  14. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  15. package/.next/server/app/_not-found.html +1 -1
  16. package/.next/server/app/_not-found.rsc +13 -13
  17. package/.next/server/app/_not-found.segments/_full.segment.rsc +13 -13
  18. package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +12 -12
  19. package/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  20. package/.next/server/app/api/artifact/route.js +10 -6
  21. package/.next/server/app/api/artifact/route.js.nft.json +1 -1
  22. package/.next/server/app/api/bot/memory/files/route.js +6 -5
  23. package/.next/server/app/api/bot/memory/files/route.js.nft.json +1 -1
  24. package/.next/server/app/api/bot/memory/route.js +8 -8
  25. package/.next/server/app/api/bot/memory/route.js.nft.json +1 -1
  26. package/.next/server/app/api/bot/route.js +8 -8
  27. package/.next/server/app/api/bot/route.js.nft.json +1 -1
  28. package/.next/server/app/api/bot/thread/[id]/route/app-paths-manifest.json +3 -0
  29. package/.next/server/app/api/bot/thread/[id]/route.js +15 -0
  30. package/.next/server/app/api/bot/thread/[id]/route.js.nft.json +1 -0
  31. package/.next/server/app/api/bot/thread/[id]/route_client-reference-manifest.js +3 -0
  32. package/.next/server/app/api/bot/thread/route/app-paths-manifest.json +3 -0
  33. package/.next/server/app/api/bot/thread/route.js +15 -0
  34. package/.next/server/app/api/bot/thread/route.js.nft.json +1 -0
  35. package/.next/server/app/api/bot/thread/route_client-reference-manifest.js +3 -0
  36. package/.next/server/app/api/config/route.js +7 -7
  37. package/.next/server/app/api/config/route.js.nft.json +1 -1
  38. package/.next/server/app/api/events/route.js +3 -3
  39. package/.next/server/app/api/events/route.js.nft.json +1 -1
  40. package/.next/server/app/api/file/[...path]/route.js +5 -5
  41. package/.next/server/app/api/file/[...path]/route.js.nft.json +1 -1
  42. package/.next/server/app/api/llm-model/catalog/route.js +8 -8
  43. package/.next/server/app/api/llm-model/catalog/route.js.nft.json +1 -1
  44. package/.next/server/app/api/llm-model/credits/route.js +8 -8
  45. package/.next/server/app/api/llm-model/credits/route.js.nft.json +1 -1
  46. package/.next/server/app/api/llm-model/route.js +8 -8
  47. package/.next/server/app/api/llm-model/route.js.nft.json +1 -1
  48. package/.next/server/app/api/llm-model/subscription/route.js +8 -8
  49. package/.next/server/app/api/llm-model/subscription/route.js.nft.json +1 -1
  50. package/.next/server/app/api/mcp/[name]/route.js +6 -6
  51. package/.next/server/app/api/mcp/[name]/route.js.nft.json +1 -1
  52. package/.next/server/app/api/mcp/oauth/callback/route.js +4 -4
  53. package/.next/server/app/api/mcp/oauth/callback/route.js.nft.json +1 -1
  54. package/.next/server/app/api/mcp/route.js +6 -6
  55. package/.next/server/app/api/mcp/route.js.nft.json +1 -1
  56. package/.next/server/app/api/mcp/tools/route.js +6 -6
  57. package/.next/server/app/api/mcp/tools/route.js.nft.json +1 -1
  58. package/.next/server/app/api/memory/edit/route.js +13 -13
  59. package/.next/server/app/api/memory/edit/route.js.nft.json +1 -1
  60. package/.next/server/app/api/memory/route.js +7 -6
  61. package/.next/server/app/api/memory/route.js.nft.json +1 -1
  62. package/.next/server/app/api/skills/[source]/[name]/route.js +6 -6
  63. package/.next/server/app/api/skills/[source]/[name]/route.js.nft.json +1 -1
  64. package/.next/server/app/api/skills/route.js +6 -6
  65. package/.next/server/app/api/skills/route.js.nft.json +1 -1
  66. package/.next/server/app/api/thursday/call/route.js +10 -11
  67. package/.next/server/app/api/thursday/call/route.js.nft.json +1 -1
  68. package/.next/server/app/api/thursday/skills/route.js +10 -11
  69. package/.next/server/app/api/thursday/skills/route.js.nft.json +1 -1
  70. package/.next/server/app/api/thursday/tool-call/route.js +15 -15
  71. package/.next/server/app/api/thursday/tool-call/route.js.nft.json +1 -1
  72. package/.next/server/app/api/workspace/missing/route/app-paths-manifest.json +3 -0
  73. package/.next/server/app/api/workspace/missing/route/build-manifest.json +12 -0
  74. package/.next/server/app/api/workspace/missing/route/server-reference-manifest.json +4 -0
  75. package/.next/server/app/api/workspace/missing/route.js +12 -0
  76. package/.next/server/app/api/workspace/missing/route.js.map +5 -0
  77. package/.next/server/app/api/workspace/missing/route.js.nft.json +1 -0
  78. package/.next/server/app/api/workspace/missing/route_client-reference-manifest.js +3 -0
  79. package/.next/server/app/api/workspace/route.js +5 -4
  80. package/.next/server/app/api/workspace/route.js.nft.json +1 -1
  81. package/.next/server/app/artifact/[...path]/page/server-reference-manifest.json +1 -1
  82. package/.next/server/app/artifact/[...path]/page.js +4 -3
  83. package/.next/server/app/artifact/[...path]/page.js.nft.json +1 -1
  84. package/.next/server/app/artifact/[...path]/page_client-reference-manifest.js +1 -1
  85. package/.next/server/app/favicon.ico/route.js.nft.json +1 -1
  86. package/.next/server/app/page/server-reference-manifest.json +67 -45
  87. package/.next/server/app/page.js +10 -9
  88. package/.next/server/app/page.js.nft.json +1 -1
  89. package/.next/server/app/page_client-reference-manifest.js +1 -1
  90. package/.next/server/app-paths-manifest.json +3 -2
  91. package/.next/server/chunks/[root-of-the-server]__02846fb._.js +8 -0
  92. package/.next/server/chunks/[root-of-the-server]__049f521._.js +3 -0
  93. package/.next/server/chunks/[root-of-the-server]__05luceg._.js +3 -0
  94. package/.next/server/chunks/[root-of-the-server]__06--3q3._.js +8 -0
  95. package/.next/server/chunks/[root-of-the-server]__07bnah_._.js +3 -0
  96. package/.next/server/chunks/[root-of-the-server]__08eae20._.js +8 -0
  97. package/.next/server/chunks/[root-of-the-server]__0_ue8oe._.js +3 -0
  98. package/.next/server/chunks/[root-of-the-server]__0c9fgca._.js +5 -0
  99. package/.next/server/chunks/[root-of-the-server]__0g-ueei._.js +8 -0
  100. package/.next/server/chunks/[root-of-the-server]__0h_x6q6._.js +5 -0
  101. package/.next/server/chunks/{[root-of-the-server]__0pa2n68._.js → [root-of-the-server]__0kxrvxf._.js} +2 -2
  102. package/.next/server/chunks/{[root-of-the-server]__0q0vvt2._.js → [root-of-the-server]__0ov3iir._.js} +2 -2
  103. package/.next/server/chunks/[root-of-the-server]__0qwtlmx._.js +8 -0
  104. package/.next/server/chunks/[root-of-the-server]__0sm5xvm._.js +3 -0
  105. package/.next/server/chunks/[root-of-the-server]__0ye3da2._.js +3 -0
  106. package/.next/server/chunks/[root-of-the-server]__0zp35ul._.js +5 -0
  107. package/.next/server/chunks/[root-of-the-server]__144u9d_._.js +3 -0
  108. package/.next/server/chunks/[root-of-the-server]__18-2tsq._.js +5 -0
  109. package/.next/server/chunks/[root-of-the-server]__1e-ci13._.js +3 -0
  110. package/.next/server/chunks/[root-of-the-server]__1e2365e._.js +8 -0
  111. package/.next/server/chunks/[root-of-the-server]__1fix932._.js +8 -0
  112. package/.next/server/chunks/{[root-of-the-server]__0ce8nf8._.js → [root-of-the-server]__1g3t7vn._.js} +3 -3
  113. package/.next/server/chunks/[root-of-the-server]__1kp-83u._.js +5 -0
  114. package/.next/server/chunks/[root-of-the-server]__1kv8p3e._.js +5 -0
  115. package/.next/server/chunks/[root-of-the-server]__1orn-5b._.js +2 -3
  116. package/.next/server/chunks/_02szwk8._.js +5 -0
  117. package/.next/server/chunks/_05h2cii._.js +1 -1
  118. package/.next/server/chunks/_06c9kie._.js +216 -0
  119. package/.next/server/chunks/{_1x6kd1r._.js → _07y2gj-._.js} +1 -1
  120. package/.next/server/chunks/_0a43a-0._.js +3 -0
  121. package/.next/server/chunks/_0bujjey._.js +5 -0
  122. package/.next/server/chunks/_0c9j6rb._.js +1 -1
  123. package/.next/server/chunks/_0dkd549._.js +3 -0
  124. package/.next/server/chunks/_0ej1kvv._.js +3 -0
  125. package/.next/server/chunks/_0f6ts7z._.js +3 -0
  126. package/.next/server/chunks/_0gm9hyv._.js +55 -0
  127. package/.next/server/chunks/_0i55en5._.js +25 -0
  128. package/.next/server/chunks/_0k50n27._.js +18 -0
  129. package/.next/server/chunks/_0khihjk._.js +3 -3
  130. package/.next/server/chunks/_0n74zsf._.js +5 -5
  131. package/.next/server/chunks/_0nvm9ef._.js +3 -0
  132. package/.next/server/chunks/_0p56fn0._.js +3 -0
  133. package/.next/server/chunks/_0recufk._.js +1 -1
  134. package/.next/server/chunks/_0xbkz10._.js +3 -0
  135. package/.next/server/chunks/_10tkr26._.js +3 -0
  136. package/.next/server/chunks/{_0ioz3nd._.js → _11u2kp7._.js} +1 -1
  137. package/.next/server/chunks/_11ujpya._.js +3 -0
  138. package/.next/server/chunks/_127nx_p._.js +5 -0
  139. package/.next/server/chunks/_17l5ygt._.js +1 -1
  140. package/.next/server/chunks/_19uauj6._.js +3 -0
  141. package/.next/server/chunks/_1_5mnq4._.js +5 -5
  142. package/.next/server/chunks/_1abl6t9._.js +55 -0
  143. package/.next/server/chunks/_1d0j961._.js +3 -3
  144. package/.next/server/chunks/_1dbixxz._.js +3 -0
  145. package/.next/server/chunks/_1dc_d1q._.js +98 -0
  146. package/.next/server/chunks/_1drgfx4._.js +5 -5
  147. package/.next/server/chunks/_1e48czp._.js +3 -3
  148. package/.next/server/chunks/_1f31u5x._.js +5 -0
  149. package/.next/server/chunks/_1kg70wc._.js +3 -3
  150. package/.next/server/chunks/_1klbcft._.js +5 -0
  151. package/.next/server/chunks/_1krd9rf._.js +4 -1
  152. package/.next/server/chunks/_1kwmzab._.js +3 -0
  153. package/.next/server/chunks/{_1pf4qe-._.js → _1oxj9fa._.js} +1 -1
  154. package/.next/server/chunks/{_1f46eie._.js → _1pcmdbb._.js} +1 -1
  155. package/.next/server/chunks/_1qgix-j._.js +3 -0
  156. package/.next/server/chunks/{lib_logger_ts_1exwjut._.js → _1rpchta._.js} +5 -5
  157. package/.next/server/chunks/_1vsej-s._.js +5 -0
  158. package/.next/server/chunks/_1yx0p_s._.js +5 -0
  159. package/.next/server/chunks/{_0rnf-6n._.js → _20fsr_z._.js} +6 -6
  160. package/.next/server/chunks/_2128hkj._.js +5 -0
  161. package/.next/server/chunks/_next-internal_server_app_api_bot_thread_[id]_route_actions_1fstjn2.js +3 -0
  162. package/.next/server/chunks/_next-internal_server_app_api_bot_thread_route_actions_003ccso.js +3 -0
  163. package/.next/server/chunks/_next-internal_server_app_api_workspace_missing_route_actions_1fidi6p.js +3 -0
  164. package/.next/server/chunks/config_ts_1g4sz5o._.js +1 -1
  165. package/.next/server/chunks/features_0-cnt0l._.js +4 -0
  166. package/.next/server/chunks/features_0hdaci0._.js +4 -0
  167. package/.next/server/chunks/features_1e39j7-._.js +8 -0
  168. package/.next/server/chunks/features_bot_bot_query_ts_12mgkl2._.js +1 -1
  169. package/.next/server/chunks/features_memory_1uqvksn._.js +1 -1
  170. package/.next/server/chunks/{node_modules_consola_dist_chunks_prompt_mjs_0r28-sm._.js → node_modules_consola_dist_chunks_prompt_mjs_0a7-pbw._.js} +1 -1
  171. package/.next/server/chunks/{node_modules_consola_dist_chunks_prompt_mjs_0v_7drq._.js → node_modules_consola_dist_chunks_prompt_mjs_0gzvgfv._.js} +1 -1
  172. package/.next/server/chunks/{node_modules_consola_dist_chunks_prompt_mjs_0i7cvml._.js → node_modules_consola_dist_chunks_prompt_mjs_107pxfn._.js} +1 -1
  173. package/.next/server/chunks/{node_modules_consola_dist_chunks_prompt_mjs_0icqaqw._.js → node_modules_consola_dist_chunks_prompt_mjs_15hbel8._.js} +1 -1
  174. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_18i-23e._.js +3 -0
  175. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_1bewgf3._.js +3 -0
  176. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_1kipdeo._.js +3 -0
  177. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_1nlww1m._.js +3 -0
  178. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_1q77nfx._.js +3 -0
  179. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_1xqdzx_._.js +3 -0
  180. package/.next/server/chunks/{node_modules_zod_v4_1801ax7._.js → node_modules_zod_v4_0lkux5-._.js} +2 -2
  181. package/.next/server/chunks/{node_modules_zod_v4_1cha_bw._.js → node_modules_zod_v4_1jmr9cq._.js} +2 -2
  182. package/.next/server/chunks/{node_modules_zod_v4_0ubdflj._.js → node_modules_zod_v4_1yrxmek._.js} +2 -2
  183. package/.next/server/chunks/node_modules_zod_v4_classic_errors_0tp0y-q.js +3 -0
  184. package/.next/server/chunks/ssr/[root-of-the-server]__09q9med._.js +1 -1
  185. package/.next/server/chunks/ssr/[root-of-the-server]__0bxsfyn._.js +101 -0
  186. package/.next/server/chunks/ssr/[root-of-the-server]__0lyi8i2._.js +1 -1
  187. package/.next/server/chunks/ssr/[root-of-the-server]__16jc196._.js +1 -1
  188. package/.next/server/chunks/ssr/[root-of-the-server]__172cq4x._.js +3 -0
  189. package/.next/server/chunks/ssr/[root-of-the-server]__18dthbp._.js +3 -0
  190. package/.next/server/chunks/ssr/[root-of-the-server]__18e68w8._.js +3 -0
  191. package/.next/server/chunks/ssr/[root-of-the-server]__1fll8dc._.js +3 -0
  192. package/.next/server/chunks/ssr/[root-of-the-server]__1mzi-ju._.js +1 -1
  193. package/.next/server/chunks/ssr/[root-of-the-server]__1nygfik._.js +5 -0
  194. package/.next/server/chunks/ssr/[root-of-the-server]__1sdphb0._.js +8 -0
  195. package/.next/server/chunks/ssr/[root-of-the-server]__1waa3rc._.js +100 -0
  196. package/.next/server/chunks/ssr/_00rehl_._.js +3 -0
  197. package/.next/server/chunks/ssr/{_1lz_cq2._.js → _02oc_h5._.js} +76 -89
  198. package/.next/server/chunks/ssr/_03_928f._.js +3 -0
  199. package/.next/server/chunks/ssr/_05yghx6._.js +3 -0
  200. package/.next/server/chunks/ssr/_08c4z-9._.js +3 -0
  201. package/.next/server/chunks/ssr/_0_qfdlw._.js +4 -0
  202. package/.next/server/chunks/ssr/_0c9e5w6._.js +9 -0
  203. package/.next/server/chunks/ssr/{_0s99bgb._.js → _0dh2e1j._.js} +9 -3
  204. package/.next/server/chunks/ssr/_0dr-ddg._.js +3 -0
  205. package/.next/server/chunks/ssr/_0eaog6_._.js +3 -0
  206. package/.next/server/chunks/ssr/_0evkpto._.js +3 -0
  207. package/.next/server/chunks/ssr/_0g_rlog._.js +3 -0
  208. package/.next/server/chunks/ssr/_0geg212._.js +3 -0
  209. package/.next/server/chunks/ssr/{_1gd8q8l._.js → _0hxt2ul._.js} +2 -2
  210. package/.next/server/chunks/ssr/_0i_6q1w._.js +2 -2
  211. package/.next/server/chunks/ssr/_0lu1n_x._.js +1 -1
  212. package/.next/server/chunks/ssr/{_15j2_8f._.js → _0wzaht-._.js} +2 -2
  213. package/.next/server/chunks/ssr/_0z-g0uy._.js +3 -0
  214. package/.next/server/chunks/ssr/_123ttsf._.js +3 -0
  215. package/.next/server/chunks/ssr/_123y-ah._.js +3 -0
  216. package/.next/server/chunks/ssr/_12w42gi._.js +3 -0
  217. package/.next/server/chunks/ssr/_161kqav._.js +3 -0
  218. package/.next/server/chunks/ssr/{_0ap2fzn._.js → _16c6_xm._.js} +2 -2
  219. package/.next/server/chunks/ssr/_18opah7._.js +3 -0
  220. package/.next/server/chunks/ssr/_18xqmny._.js +3 -0
  221. package/.next/server/chunks/ssr/_1_krfph._.js +3 -0
  222. package/.next/server/chunks/ssr/{_1-_etts._.js → _1anqots._.js} +2 -2
  223. package/.next/server/chunks/ssr/_1ey7qn-._.js +70 -0
  224. package/.next/server/chunks/ssr/_1g9vs7q._.js +3 -0
  225. package/.next/server/chunks/ssr/_1jmz33w._.js +3 -0
  226. package/.next/server/chunks/ssr/{_0n3toaw._.js → _1k0spz7._.js} +2 -2
  227. package/.next/server/chunks/ssr/_1rgtxhr._.js +5 -0
  228. package/.next/server/chunks/ssr/_1slp25y._.js +3 -0
  229. package/.next/server/chunks/ssr/{_1fojd41._.js → _1x9pskj._.js} +3 -3
  230. package/.next/server/chunks/ssr/_1y6b5mr._.js +101 -0
  231. package/.next/server/chunks/ssr/_1ztk7p6._.js +7 -0
  232. package/.next/server/chunks/ssr/components_ui_tabs_tsx_0ej40b4._.js +3 -0
  233. package/.next/server/chunks/ssr/features_bot_thread_query_ts_023eklt._.js +4 -0
  234. package/.next/server/chunks/ssr/features_config_components_config-setting_tsx_0xfwqdg._.js +1 -1
  235. package/.next/server/chunks/ssr/features_connectors_components_mcp-setting_tsx_0jmbgvp._.js +1 -1
  236. package/.next/server/chunks/ssr/{_1-teee5._.js → lib_logger_ts_0-olsze._.js} +2 -7
  237. package/.next/server/chunks/ssr/{node_modules_0cxaxk9._.js → node_modules_00_51_v._.js} +1 -1
  238. package/.next/server/chunks/ssr/{node_modules_04jf_m8._.js → node_modules_022sipm._.js} +1 -1
  239. package/.next/server/chunks/ssr/{node_modules_0g7fzk3._.js → node_modules_0332gw4._.js} +1 -1
  240. package/.next/server/chunks/ssr/{node_modules_1cx_ql6._.js → node_modules_04vxchl._.js} +1 -1
  241. package/.next/server/chunks/ssr/{node_modules_1vh5ntv._.js → node_modules_0746rzi._.js} +1 -1
  242. package/.next/server/chunks/ssr/{node_modules_0yugy6m._.js → node_modules_0d5uzof._.js} +1 -1
  243. package/.next/server/chunks/ssr/{node_modules_09q35v_._.js → node_modules_0exkwcm._.js} +1 -1
  244. package/.next/server/chunks/ssr/{node_modules_08dhkiq._.js → node_modules_0fr-ml8._.js} +1 -1
  245. package/.next/server/chunks/ssr/{node_modules_14q6g4n._.js → node_modules_0mxvg8h._.js} +1 -1
  246. package/.next/server/chunks/ssr/{node_modules_0arus10._.js → node_modules_0qapgjr._.js} +1 -1
  247. package/.next/server/chunks/ssr/{node_modules_1eg7m6c._.js → node_modules_0qbfyjh._.js} +1 -1
  248. package/.next/server/chunks/ssr/{node_modules_1cz2hle._.js → node_modules_0t-9nup._.js} +1 -1
  249. package/.next/server/chunks/ssr/{node_modules_17bwo43._.js → node_modules_0tusx4d._.js} +3 -3
  250. package/.next/server/chunks/ssr/{node_modules_1efrqxi._.js → node_modules_0vsxbzp._.js} +1 -1
  251. package/.next/server/chunks/ssr/{node_modules_0_-_a--._.js → node_modules_0vv0-fg._.js} +1 -1
  252. package/.next/server/chunks/ssr/{node_modules_1gdh31p._.js → node_modules_0wsvp00._.js} +1 -1
  253. package/.next/server/chunks/ssr/{node_modules_1hpopmo._.js → node_modules_1-urho9._.js} +1 -1
  254. package/.next/server/chunks/ssr/{node_modules_1_pc9kq._.js → node_modules_16pi_dd._.js} +1 -1
  255. package/.next/server/chunks/ssr/{node_modules_00etblx._.js → node_modules_1d53yiq._.js} +1 -1
  256. package/.next/server/chunks/ssr/{node_modules_1aaxuef._.js → node_modules_1g1eihe._.js} +1 -1
  257. package/.next/server/chunks/ssr/{node_modules_198nmll._.js → node_modules_1gpednh._.js} +1 -1
  258. package/.next/server/chunks/ssr/{node_modules_0pvd7q-._.js → node_modules_1gu1pph._.js} +1 -1
  259. package/.next/server/chunks/ssr/{node_modules_0b__sgl._.js → node_modules_1he1w8_._.js} +1 -1
  260. package/.next/server/chunks/ssr/{node_modules_1qpjvy5._.js → node_modules_1lnjapm._.js} +1 -1
  261. package/.next/server/chunks/ssr/{node_modules_0940ns5._.js → node_modules_1lynj9m._.js} +1 -1
  262. package/.next/server/chunks/ssr/{node_modules_0x3-ply._.js → node_modules_1seuurl._.js} +2 -2
  263. package/.next/server/chunks/ssr/{node_modules_14om4ar._.js → node_modules_1u6w1pb._.js} +1 -1
  264. package/.next/server/chunks/ssr/{node_modules_0had7xd._.js → node_modules_1xn6saw._.js} +1 -1
  265. package/.next/server/chunks/ssr/{node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_1b748ic._.js → node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_067_exa._.js} +1 -1
  266. package/.next/server/chunks/ssr/{node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_1z4hm5e._.js → node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_0nrrdaq._.js} +1 -1
  267. package/.next/server/chunks/ssr/{node_modules_@vercel_oidc_dist_06mk8id._.js → node_modules_@vercel_oidc_dist_21a5haa._.js} +1 -1
  268. package/.next/server/chunks/ssr/node_modules_lucide-react_dist_esm_icons_trash_mjs_0px2gzr._.js +3 -0
  269. package/.next/server/middleware-build-manifest.js +3 -3
  270. package/.next/server/pages/404.html +1 -1
  271. package/.next/server/pages/500.html +1 -1
  272. package/.next/server/server-reference-manifest.js +1 -1
  273. package/.next/server/server-reference-manifest.json +68 -46
  274. package/.next/static/chunks/0dr16v67vj4n7.js +2 -0
  275. package/.next/static/chunks/0g4b348l0pve7.js +1 -0
  276. package/.next/static/chunks/0joan-69kbspd.js +1 -0
  277. package/.next/static/chunks/0vlgzqo9ka90v.js +1 -0
  278. package/.next/static/chunks/0zrupxgci5gqc.js +1 -0
  279. package/.next/static/chunks/10k2xvap03z20.css +1 -0
  280. package/.next/static/chunks/18mkhstgiqcbt.js +1 -0
  281. package/.next/static/chunks/{15m575979un5f.js → 1i-u2wzub_to1.js} +2 -2
  282. package/.next/static/chunks/1kp5nfp06nj9h.js +5 -0
  283. package/.next/static/chunks/1ohslk4568tm3.js +1 -0
  284. package/.next/static/chunks/1sbmwswc9k2-1.js +1 -0
  285. package/.next/static/chunks/1t9qms5pwwa3n.js +1 -0
  286. package/.next/static/chunks/1vj_5bnbxx84e.js +1 -0
  287. package/.next/static/chunks/1vqezbhjm3goq.js +1 -0
  288. package/.next/static/chunks/{3akmqm77muj4-.js → 1wlo979mx-y3w.js} +1 -1
  289. package/.next/static/chunks/26ql4y-43xwhp.js +1 -0
  290. package/.next/static/chunks/{0fl3gwe4-l6tz.js → 2_pnccjp6j1ca.js} +1 -1
  291. package/.next/static/chunks/2a51-ywz9b2a3.js +1 -0
  292. package/.next/static/chunks/2fvdgxih7x7hr.js +1 -0
  293. package/.next/static/chunks/2jlz8zp4jax_m.js +18 -0
  294. package/.next/static/chunks/2nvepds1fu2ux.js +1 -0
  295. package/.next/static/chunks/3addj3i4-izma.js +1 -0
  296. package/.next/static/chunks/3bfwpww3m3x4u.js +1 -0
  297. package/.next/static/chunks/3gfh7nxwusbt0.js +1 -0
  298. package/.next/static/chunks/3gwa44cvz4qoi.js +1 -0
  299. package/.next/static/chunks/{38gweqdo4jpfj.js → 3izg0a3k87q1-.js} +5 -5
  300. package/.next/static/chunks/3zk6q3-3f9swq.js +99 -0
  301. package/.next/static/chunks/3zkg5iup3v4a2.js +12 -0
  302. package/.next/static/chunks/405m0bqtoihev.js +1 -0
  303. package/.next/static/chunks/42wcg3wfg_m_p.js +1 -0
  304. package/README.md +27 -216
  305. package/app/api/events/app-event.ts +6 -4
  306. package/app/api/query-key.ts +25 -16
  307. package/bin/database.mjs +37 -0
  308. package/bin/thursday.mjs +44 -28
  309. package/components/ui/custom-icon.tsx +0 -60
  310. package/components/ui/radio-group.tsx +37 -0
  311. package/components/ui/shiny-text.tsx +33 -6
  312. package/database/migrations/{20260910173049_numerous_spirit → 20260916145701_clever_multiple_man}/migration.sql +80 -24
  313. package/database/migrations/{20260910173049_numerous_spirit → 20260916145701_clever_multiple_man}/snapshot.json +689 -110
  314. package/database/migrations/20260916160713_thread_cancelled/migration.sql +2 -0
  315. package/database/migrations/{20260911030320_opposite_jack_power → 20260916160713_thread_cancelled}/snapshot.json +706 -84
  316. package/docs/how-it-works.md +39 -36
  317. package/docs/images/keeps-going.png +0 -0
  318. package/docs/images/two-minds.png +0 -0
  319. package/docs/live-calls.md +231 -0
  320. package/docs/thread-rooms.md +71 -0
  321. package/features/ai/chatgpt.ts +1 -2
  322. package/features/ai/live.schema.ts +128 -0
  323. package/features/ai/load-tools.ts +148 -77
  324. package/features/ai/model.schema.ts +2 -120
  325. package/features/ai/model.ts +52 -88
  326. package/features/ai/prompts/bot.prompt.ts +91 -214
  327. package/features/ai/prompts/live.prompt.ts +265 -0
  328. package/features/ai/prompts/prompt-helper.ts +91 -32
  329. package/features/ai/prompts/thursday.prompt.ts +125 -172
  330. package/features/ai/tools/bot.tool.ts +38 -145
  331. package/features/ai/tools/call.tool.ts +1 -1
  332. package/features/ai/tools/connected.ts +5 -3
  333. package/features/ai/tools/mcp.tool.ts +7 -4
  334. package/features/ai/tools/memory.tool.ts +35 -31
  335. package/features/ai/tools/skills.tool.ts +36 -14
  336. package/features/ai/tools/studio.tool.ts +26 -21
  337. package/features/ai/tools/tool-name.ts +2 -5
  338. package/features/ai/tools/workspace.tool.ts +33 -10
  339. package/features/artifact/artifact.action.ts +2 -2
  340. package/features/artifact/artifact.query.ts +112 -61
  341. package/features/artifact/artifact.schema.ts +8 -6
  342. package/features/artifact/components/artifact-setting.tsx +83 -33
  343. package/features/bot/bot.action.ts +43 -36
  344. package/features/bot/bot.memory.ts +137 -20
  345. package/features/bot/bot.query.ts +28 -11
  346. package/features/bot/bot.run.ts +299 -636
  347. package/features/bot/bot.runner.ts +468 -844
  348. package/features/bot/bot.schema.ts +93 -82
  349. package/features/bot/bot.seed.ts +141 -64
  350. package/features/bot/components/bot-mark.tsx +324 -232
  351. package/features/bot/components/bot-room.tsx +1613 -697
  352. package/features/bot/components/bot-roster.tsx +8 -13
  353. package/features/bot/components/bot-setting.tsx +58 -42
  354. package/features/bot/components/bot-tool.tsx +55 -87
  355. package/features/bot/components/mark-palette.tsx +35 -32
  356. package/features/bot/components/path-chips.tsx +33 -3
  357. package/features/bot/components/thread-badge.tsx +34 -0
  358. package/features/bot/components/thread-reply.tsx +639 -0
  359. package/features/bot/components/thread-setting.tsx +674 -0
  360. package/features/bot/mark.const.ts +79 -31
  361. package/features/bot/room.query.ts +889 -0
  362. package/features/bot/room.schema.ts +64 -0
  363. package/features/bot/seed-bots.ts +2 -1
  364. package/features/bot/thread.query.ts +971 -0
  365. package/features/bot/thread.store.ts +587 -0
  366. package/features/config/components/voice-key.tsx +113 -88
  367. package/features/config/config.const.ts +5 -9
  368. package/features/connectors/mcp.schema.ts +0 -2
  369. package/features/intro/components/intro.tsx +169 -139
  370. package/features/memory/components/memory-setting.tsx +2 -7
  371. package/features/memory/memory.schema.ts +14 -23
  372. package/features/settings/components/setting-ui.tsx +0 -44
  373. package/features/settings/components/settings.tsx +12 -12
  374. package/features/settings/settings.alert.ts +3 -3
  375. package/features/settings/settings.store.ts +1 -1
  376. package/features/skills/skills.schema.ts +0 -2
  377. package/features/thursday/components/ascii-field.tsx +24 -44
  378. package/features/thursday/components/ascii-orb.tsx +359 -358
  379. package/features/thursday/components/call-log.tsx +46 -44
  380. package/features/thursday/components/face.tsx +35 -10
  381. package/features/thursday/components/tab-state.tsx +3 -3
  382. package/features/thursday/components/thursday-mark.tsx +1 -0
  383. package/features/thursday/components/thursday-setting.tsx +631 -332
  384. package/features/thursday/components/thursday.tsx +106 -41
  385. package/features/thursday/components/voice-picker.tsx +255 -0
  386. package/features/thursday/thursday.action.ts +94 -68
  387. package/features/thursday/thursday.query.ts +49 -30
  388. package/features/thursday/thursday.schema.ts +27 -30
  389. package/features/thursday/thursday.store.ts +11 -7
  390. package/features/thursday/tool-call.ts +3 -3
  391. package/features/thursday/tool-line.ts +5 -3
  392. package/features/thursday/use-thursday.ts +725 -450
  393. package/features/workspace/workspace.query.ts +17 -0
  394. package/features/workspace/workspace.ts +103 -50
  395. package/lib/live/live.schema.ts +47 -0
  396. package/lib/live/live.server.ts +155 -0
  397. package/lib/live/live.session.ts +574 -0
  398. package/lib/{realtime/realtime.tap.ts → live/live.tap.ts} +41 -12
  399. package/lib/live/live.transport.ts +152 -0
  400. package/lib/protocol/use-server-pages.ts +9 -5
  401. package/lib/utils.ts +21 -20
  402. package/package.json +2 -2
  403. package/public/voices/alloy.ogg +0 -0
  404. package/public/voices/ash.ogg +0 -0
  405. package/public/voices/ballad.ogg +0 -0
  406. package/public/voices/beacon.ogg +0 -0
  407. package/public/voices/bossa.ogg +0 -0
  408. package/public/voices/cedar.ogg +0 -0
  409. package/public/voices/cinder.ogg +0 -0
  410. package/public/voices/coral.ogg +0 -0
  411. package/public/voices/delta.ogg +0 -0
  412. package/public/voices/echo.ogg +0 -0
  413. package/public/voices/gleam.ogg +0 -0
  414. package/public/voices/marin.ogg +0 -0
  415. package/public/voices/meridian.ogg +0 -0
  416. package/public/voices/quartz.ogg +0 -0
  417. package/public/voices/ripple.ogg +0 -0
  418. package/public/voices/sage.ogg +0 -0
  419. package/public/voices/shimmer.ogg +0 -0
  420. package/public/voices/stone.ogg +0 -0
  421. package/public/voices/tempo.ogg +0 -0
  422. package/public/voices/verse.ogg +0 -0
  423. package/public/voices/vesper.ogg +0 -0
  424. package/public/voices/willow.ogg +0 -0
  425. package/scripts/artifact-paths.test.mts +25 -0
  426. package/scripts/bot-context.test.mts +1408 -0
  427. package/scripts/live-history.test.mts +115 -0
  428. package/scripts/live-session.test.mts +948 -0
  429. package/server.js +1 -1
  430. package/skills/browser/SKILL.md +17 -6
  431. package/skills/computer/SKILL.md +1 -1
  432. package/skills/find-skills/SKILL.md +3 -8
  433. package/skills/interactive-page/SKILL.md +12 -7
  434. package/skills/interactive-page/references/diagram.md +89 -0
  435. package/skills/interactive-page/scripts/archify/LICENSE +22 -0
  436. package/skills/interactive-page/scripts/archify/README.md +25 -0
  437. package/skills/interactive-page/scripts/archify/assets/JetBrainsMono-OFL.txt +93 -0
  438. package/skills/interactive-page/scripts/archify/assets/template.html +14934 -0
  439. package/skills/interactive-page/scripts/archify/bin/archify.mjs +2126 -0
  440. package/skills/interactive-page/scripts/archify/bin/open-artifact.mjs +86 -0
  441. package/skills/interactive-page/scripts/archify/bin/preview.mjs +653 -0
  442. package/skills/interactive-page/scripts/archify/bin/visual-check.mjs +829 -0
  443. package/skills/interactive-page/scripts/archify/delta/architecture-delta.mjs +1223 -0
  444. package/skills/interactive-page/scripts/archify/examples/agent-run.lifecycle.json +60 -0
  445. package/skills/interactive-page/scripts/archify/examples/agent-tool-call.workflow.json +94 -0
  446. package/skills/interactive-page/scripts/archify/examples/async-job-roundtrip.sequence.json +61 -0
  447. package/skills/interactive-page/scripts/archify/examples/cache-miss-request.sequence.json +82 -0
  448. package/skills/interactive-page/scripts/archify/examples/checkout-platform.base.architecture.json +31 -0
  449. package/skills/interactive-page/scripts/archify/examples/checkout-platform.head.architecture.json +31 -0
  450. package/skills/interactive-page/scripts/archify/examples/deployment-release.lifecycle.json +49 -0
  451. package/skills/interactive-page/scripts/archify/examples/event-stream.dataflow.json +57 -0
  452. package/skills/interactive-page/scripts/archify/examples/incident-response.workflow.json +64 -0
  453. package/skills/interactive-page/scripts/archify/examples/product-analytics.dataflow.json +76 -0
  454. package/skills/interactive-page/scripts/archify/examples/production-deployment.architecture.json +71 -0
  455. package/skills/interactive-page/scripts/archify/examples/release-delivery.workflow.json +62 -0
  456. package/skills/interactive-page/scripts/archify/examples/web-app.architecture.json +46 -0
  457. package/skills/interactive-page/scripts/archify/migrations/workflow-v2.mjs +279 -0
  458. package/skills/interactive-page/scripts/archify/recipes/scenarios.mjs +284 -0
  459. package/skills/interactive-page/scripts/archify/references/authoring-contract.md +243 -0
  460. package/skills/interactive-page/scripts/archify/references/delivery-contract.md +120 -0
  461. package/skills/interactive-page/scripts/archify/references/viewer-runtime.md +45 -0
  462. package/skills/interactive-page/scripts/archify/renderers/architecture/grid.mjs +62 -0
  463. package/skills/interactive-page/scripts/archify/renderers/architecture/render-architecture.mjs +1078 -0
  464. package/skills/interactive-page/scripts/archify/renderers/dataflow/README.md +104 -0
  465. package/skills/interactive-page/scripts/archify/renderers/dataflow/render-dataflow.mjs +483 -0
  466. package/skills/interactive-page/scripts/archify/renderers/lifecycle/README.md +115 -0
  467. package/skills/interactive-page/scripts/archify/renderers/lifecycle/render-lifecycle.mjs +561 -0
  468. package/skills/interactive-page/scripts/archify/renderers/sequence/README.md +114 -0
  469. package/skills/interactive-page/scripts/archify/renderers/sequence/render-sequence.mjs +464 -0
  470. package/skills/interactive-page/scripts/archify/renderers/shared/brand-marks.mjs +563 -0
  471. package/skills/interactive-page/scripts/archify/renderers/shared/cli.mjs +218 -0
  472. package/skills/interactive-page/scripts/archify/renderers/shared/desktop-readability.mjs +26 -0
  473. package/skills/interactive-page/scripts/archify/renderers/shared/diagnostics.mjs +127 -0
  474. package/skills/interactive-page/scripts/archify/renderers/shared/engineering-profiles.mjs +157 -0
  475. package/skills/interactive-page/scripts/archify/renderers/shared/generated-brand-marks.mjs +3 -0
  476. package/skills/interactive-page/scripts/archify/renderers/shared/generated-validators.mjs +13 -0
  477. package/skills/interactive-page/scripts/archify/renderers/shared/geometry.mjs +1423 -0
  478. package/skills/interactive-page/scripts/archify/renderers/shared/i18n.mjs +595 -0
  479. package/skills/interactive-page/scripts/archify/renderers/shared/layout-report.mjs +40 -0
  480. package/skills/interactive-page/scripts/archify/renderers/shared/legend.mjs +217 -0
  481. package/skills/interactive-page/scripts/archify/renderers/shared/output-path.mjs +340 -0
  482. package/skills/interactive-page/scripts/archify/renderers/shared/repository-evidence.mjs +238 -0
  483. package/skills/interactive-page/scripts/archify/renderers/shared/repository-location.mjs +58 -0
  484. package/skills/interactive-page/scripts/archify/renderers/shared/text-fit.mjs +49 -0
  485. package/skills/interactive-page/scripts/archify/renderers/shared/utils.mjs +232 -0
  486. package/skills/interactive-page/scripts/archify/renderers/shared/validator.mjs +86 -0
  487. package/skills/interactive-page/scripts/archify/renderers/workflow/README.md +223 -0
  488. package/skills/interactive-page/scripts/archify/renderers/workflow/render-workflow.mjs +35 -0
  489. package/skills/interactive-page/scripts/archify/renderers/workflow/workflow-compiler.mjs +4400 -0
  490. package/skills/interactive-page/scripts/archify/renderers/workflow/workflow-migration-geometry.mjs +144 -0
  491. package/skills/interactive-page/scripts/archify/schemas/README.md +211 -0
  492. package/skills/interactive-page/scripts/archify/schemas/architecture.schema.json +178 -0
  493. package/skills/interactive-page/scripts/archify/schemas/common.schema.json +115 -0
  494. package/skills/interactive-page/scripts/archify/schemas/dataflow.schema.json +243 -0
  495. package/skills/interactive-page/scripts/archify/schemas/lifecycle.schema.json +266 -0
  496. package/skills/interactive-page/scripts/archify/schemas/sequence.schema.json +223 -0
  497. package/skills/interactive-page/scripts/archify/schemas/workflow.schema.json +428 -0
  498. package/skills/interactive-page/scripts/archify/scripts/check-render-output.mjs +916 -0
  499. package/skills/interactive-page/scripts/archify/scripts/render-examples.mjs +26 -0
  500. package/skills/interactive-page/scripts/bundle-artifact.sh +9 -8
  501. package/skills/skill-creator/SKILL.md +4 -5
  502. package/.next/server/app/api/bot/task/[id]/route/app-paths-manifest.json +0 -3
  503. package/.next/server/app/api/bot/task/[id]/route.js +0 -16
  504. package/.next/server/app/api/bot/task/[id]/route.js.nft.json +0 -1
  505. package/.next/server/app/api/bot/task/[id]/route_client-reference-manifest.js +0 -3
  506. package/.next/server/app/api/bot/task/route/app-paths-manifest.json +0 -3
  507. package/.next/server/app/api/bot/task/route.js +0 -16
  508. package/.next/server/app/api/bot/task/route.js.nft.json +0 -1
  509. package/.next/server/app/api/bot/task/route_client-reference-manifest.js +0 -3
  510. package/.next/server/chunks/[root-of-the-server]__01dkp4a._.js +0 -3
  511. package/.next/server/chunks/[root-of-the-server]__02va5wz._.js +0 -3
  512. package/.next/server/chunks/[root-of-the-server]__02xjoto._.js +0 -3
  513. package/.next/server/chunks/[root-of-the-server]__04q--0f._.js +0 -8
  514. package/.next/server/chunks/[root-of-the-server]__0bl-e63._.js +0 -3
  515. package/.next/server/chunks/[root-of-the-server]__0ffbg85._.js +0 -3
  516. package/.next/server/chunks/[root-of-the-server]__0jq4ohy._.js +0 -8
  517. package/.next/server/chunks/[root-of-the-server]__0ls6_8y._.js +0 -8
  518. package/.next/server/chunks/[root-of-the-server]__0ncs9uu._.js +0 -3
  519. package/.next/server/chunks/[root-of-the-server]__1-ga0kh._.js +0 -5
  520. package/.next/server/chunks/[root-of-the-server]__11n256_._.js +0 -5
  521. package/.next/server/chunks/[root-of-the-server]__12cabg9._.js +0 -3
  522. package/.next/server/chunks/[root-of-the-server]__1339jnv._.js +0 -8
  523. package/.next/server/chunks/[root-of-the-server]__18_teo8._.js +0 -8
  524. package/.next/server/chunks/[root-of-the-server]__1_04mcf._.js +0 -5
  525. package/.next/server/chunks/[root-of-the-server]__1anc1p9._.js +0 -3
  526. package/.next/server/chunks/[root-of-the-server]__1ccon1w._.js +0 -10
  527. package/.next/server/chunks/[root-of-the-server]__1fizn31._.js +0 -3
  528. package/.next/server/chunks/[root-of-the-server]__1llj3-b._.js +0 -3
  529. package/.next/server/chunks/[root-of-the-server]__1p8m3f4._.js +0 -3
  530. package/.next/server/chunks/[root-of-the-server]__1wa1k7r._.js +0 -8
  531. package/.next/server/chunks/_0-73of8._.js +0 -55
  532. package/.next/server/chunks/_0-fjql4._.js +0 -26
  533. package/.next/server/chunks/_00xh_q0._.js +0 -25
  534. package/.next/server/chunks/_03a0897._.js +0 -3
  535. package/.next/server/chunks/_051qh8u._.js +0 -3
  536. package/.next/server/chunks/_05sovvj._.js +0 -3
  537. package/.next/server/chunks/_0fzqt2y._.js +0 -134
  538. package/.next/server/chunks/_0mecv0f._.js +0 -26
  539. package/.next/server/chunks/_0mh8j4m._.js +0 -3
  540. package/.next/server/chunks/_0obojvv._.js +0 -3
  541. package/.next/server/chunks/_0sb7tlz._.js +0 -3
  542. package/.next/server/chunks/_0sbynis._.js +0 -3
  543. package/.next/server/chunks/_0u10wmw._.js +0 -55
  544. package/.next/server/chunks/_0u4aiy2._.js +0 -3
  545. package/.next/server/chunks/_0wp4le3._.js +0 -3
  546. package/.next/server/chunks/_0y5fg-x._.js +0 -3
  547. package/.next/server/chunks/_1230wbx._.js +0 -10
  548. package/.next/server/chunks/_12nheja._.js +0 -3
  549. package/.next/server/chunks/_13510xh._.js +0 -3
  550. package/.next/server/chunks/_15hq89o._.js +0 -3
  551. package/.next/server/chunks/_18-1wcc._.js +0 -55
  552. package/.next/server/chunks/_1_9mjx-._.js +0 -3
  553. package/.next/server/chunks/_1c78vw5._.js +0 -229
  554. package/.next/server/chunks/_1h5_8sk._.js +0 -3
  555. package/.next/server/chunks/_1hdnxb7._.js +0 -3
  556. package/.next/server/chunks/_1j8k_j5._.js +0 -3
  557. package/.next/server/chunks/_1nula3v._.js +0 -3
  558. package/.next/server/chunks/_1php4eq._.js +0 -3
  559. package/.next/server/chunks/_1yuv4vp._.js +0 -3
  560. package/.next/server/chunks/_1zjrdag._.js +0 -3
  561. package/.next/server/chunks/_next-internal_server_app_api_bot_task_[id]_route_actions_1_k_8u3.js +0 -3
  562. package/.next/server/chunks/_next-internal_server_app_api_bot_task_route_actions_0xln6ra.js +0 -3
  563. package/.next/server/chunks/features_0rpfxbk._.js +0 -3
  564. package/.next/server/chunks/features_1qf3cei._.js +0 -3
  565. package/.next/server/chunks/features_bot_0zt92oh._.js +0 -3
  566. package/.next/server/chunks/node_modules_consola_dist_chunks_prompt_mjs_1xoq2rl._.js +0 -3
  567. package/.next/server/chunks/ssr/[externals]__0dizgek._.js +0 -3
  568. package/.next/server/chunks/ssr/[root-of-the-server]__092knlj._.js +0 -3
  569. package/.next/server/chunks/ssr/[root-of-the-server]__0mz33a7._.js +0 -3
  570. package/.next/server/chunks/ssr/[root-of-the-server]__0s9dq5u._.js +0 -3
  571. package/.next/server/chunks/ssr/[root-of-the-server]__0s9l2sv._.js +0 -3
  572. package/.next/server/chunks/ssr/[root-of-the-server]__0vnmv-s._.js +0 -3
  573. package/.next/server/chunks/ssr/[root-of-the-server]__0xsog8n._.js +0 -3
  574. package/.next/server/chunks/ssr/[root-of-the-server]__10-dz5o._.js +0 -61
  575. package/.next/server/chunks/ssr/[root-of-the-server]__1gtlw6v._.js +0 -43
  576. package/.next/server/chunks/ssr/[root-of-the-server]__1ox7hbk._.js +0 -4
  577. package/.next/server/chunks/ssr/[root-of-the-server]__202p40z._.js +0 -3
  578. package/.next/server/chunks/ssr/_001_ms1._.js +0 -28
  579. package/.next/server/chunks/ssr/_01n3o0m._.js +0 -3
  580. package/.next/server/chunks/ssr/_0fz4mf_._.js +0 -3
  581. package/.next/server/chunks/ssr/_0gb4gmf._.js +0 -3
  582. package/.next/server/chunks/ssr/_0h42fze._.js +0 -3
  583. package/.next/server/chunks/ssr/_0h7zdni._.js +0 -3
  584. package/.next/server/chunks/ssr/_0ilna52._.js +0 -42
  585. package/.next/server/chunks/ssr/_0q0zan6._.js +0 -70
  586. package/.next/server/chunks/ssr/_0zcjrbg._.js +0 -3
  587. package/.next/server/chunks/ssr/_0zhoc3r._.js +0 -3
  588. package/.next/server/chunks/ssr/_13fke0x._.js +0 -3
  589. package/.next/server/chunks/ssr/_18cymkq._.js +0 -3
  590. package/.next/server/chunks/ssr/_1b2mjwr._.js +0 -3
  591. package/.next/server/chunks/ssr/_1f-dg-6._.js +0 -3
  592. package/.next/server/chunks/ssr/_1h0rw11._.js +0 -3
  593. package/.next/server/chunks/ssr/_1jhd09t._.js +0 -3
  594. package/.next/server/chunks/ssr/_1nnsk7z._.js +0 -3
  595. package/.next/server/chunks/ssr/_1ov37if._.js +0 -3
  596. package/.next/server/chunks/ssr/_1sji22n._.js +0 -3
  597. package/.next/server/chunks/ssr/_1vi_uo7._.js +0 -3
  598. package/.next/server/chunks/ssr/_1vyd1ji._.js +0 -3
  599. package/.next/server/chunks/ssr/_1xx4zlb._.js +0 -3
  600. package/.next/server/chunks/ssr/components_ui_1y1l7yj._.js +0 -3
  601. package/.next/server/chunks/ssr/features_bot_1s_-2vj._.js +0 -3
  602. package/.next/server/chunks/ssr/lib_realtime_12wg_dd._.js +0 -27
  603. package/.next/server/chunks/ssr/lib_realtime_15h_v1v._.js +0 -27
  604. package/.next/server/chunks/ssr/node_modules_lucide-react_dist_esm_icons_0npjf8-._.js +0 -3
  605. package/.next/static/chunks/00rd4-v8r7axp.js +0 -1
  606. package/.next/static/chunks/08qe4as2q428z.js +0 -3
  607. package/.next/static/chunks/0gnqdjn2lvdad.js +0 -2
  608. package/.next/static/chunks/0hwap1-p0m5sa.js +0 -1
  609. package/.next/static/chunks/0r5qcctujhxli.js +0 -1
  610. package/.next/static/chunks/0w52rrrmuj9r9.js +0 -1
  611. package/.next/static/chunks/0wcprt5ot5she.js +0 -1
  612. package/.next/static/chunks/10teww7wt-f6h.js +0 -1
  613. package/.next/static/chunks/17p6tk6k88dq6.js +0 -1
  614. package/.next/static/chunks/18a96rkhi4_yd.js +0 -1
  615. package/.next/static/chunks/1dkjg87pxk0n9.js +0 -28
  616. package/.next/static/chunks/1jd09sxcjddu1.js +0 -1
  617. package/.next/static/chunks/1w73ece_6bheu.js +0 -18
  618. package/.next/static/chunks/214ya3n5gxeih.js +0 -1
  619. package/.next/static/chunks/22_zkas21rpna.js +0 -1
  620. package/.next/static/chunks/2fh4-3z_q8b_w.js +0 -1
  621. package/.next/static/chunks/2h0sd2vumhb15.js +0 -1
  622. package/.next/static/chunks/2t4vhi3m8ahya.js +0 -1
  623. package/.next/static/chunks/2tigdtz3dpcy8.js +0 -1
  624. package/.next/static/chunks/2u7xt6mxg44lf.js +0 -1
  625. package/.next/static/chunks/3786h5vayt80-.js +0 -28
  626. package/.next/static/chunks/39j0fvpybzabl.js +0 -40
  627. package/.next/static/chunks/3cq5g494yuke8.css +0 -1
  628. package/.next/static/chunks/3hibbjnt85-k6.js +0 -1
  629. package/.next/static/chunks/3woj-xd7ki5_i.js +0 -1
  630. package/.next/static/chunks/3xk7yqgomx7yq.js +0 -1
  631. package/.next/static/chunks/3zmcsnuo25zvq.js +0 -1
  632. package/database/migrations/20260911030320_opposite_jack_power/migration.sql +0 -1
  633. package/docs/images/task-thread.png +0 -0
  634. package/features/bot/components/task-badge.tsx +0 -42
  635. package/features/bot/components/task-reply.tsx +0 -328
  636. package/features/bot/components/task-setting.tsx +0 -524
  637. package/features/bot/task.query.ts +0 -976
  638. package/features/bot/task.store.ts +0 -489
  639. package/lib/realtime/client-secret.ts +0 -86
  640. package/lib/realtime/open-session.ts +0 -31
  641. package/lib/realtime/openai.ts +0 -35
  642. package/lib/realtime/realtime.audio.ts +0 -196
  643. package/lib/realtime/realtime.driver.ts +0 -489
  644. package/lib/realtime/realtime.protocol.ts +0 -393
  645. package/lib/realtime/realtime.schema.ts +0 -37
  646. package/lib/realtime/realtime.session.ts +0 -106
  647. package/lib/realtime/realtime.transport.ts +0 -384
  648. package/lib/realtime/xai.ts +0 -39
  649. /package/.next/server/app/api/bot/{task → thread}/[id]/route/build-manifest.json +0 -0
  650. /package/.next/server/app/api/bot/{task → thread}/[id]/route/server-reference-manifest.json +0 -0
  651. /package/.next/server/app/api/bot/{task → thread}/[id]/route.js.map +0 -0
  652. /package/.next/server/app/api/bot/{task → thread}/route/build-manifest.json +0 -0
  653. /package/.next/server/app/api/bot/{task → thread}/route/server-reference-manifest.json +0 -0
  654. /package/.next/server/app/api/bot/{task → thread}/route.js.map +0 -0
  655. /package/.next/static/{kaTO0UHqF1bMnWgCDik2f → 0qzGoKn2wTERVZtblX1tp}/_buildManifest.js +0 -0
  656. /package/.next/static/{kaTO0UHqF1bMnWgCDik2f → 0qzGoKn2wTERVZtblX1tp}/_clientMiddlewareManifest.js +0 -0
  657. /package/.next/static/{kaTO0UHqF1bMnWgCDik2f → 0qzGoKn2wTERVZtblX1tp}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,222055,218964,991322,852116,589128,e=>{"use strict";var t=e.i(843476),a=e.i(689664),r=e.i(716327),i=e.i(482022),l=e.i(456420);let n={name:"file-pen",size:24,node:[["path",{d:"M12.659 22H18a2 2 0 0 0 2-2V8a2.4 2.4 0 0 0-.706-1.706l-3.588-3.588A2.4 2.4 0 0 0 14 2H6a2 2 0 0 0-2 2v9.34",key:"o6klzx"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10.378 12.622a1 1 0 0 1 3 3.003L8.36 20.637a2 2 0 0 1-.854.506l-2.867.837a.5.5 0 0 1-.62-.62l.836-2.869a2 2 0 0 1 .506-.853z",key:"zhnas1"}]],aliases:["file-edit"]};n.node;let s=(0,l.default)(n),o={name:"list-checks",size:24,node:[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}]]};o.node;let d=(0,l.default)(o);e.s(["ListChecks",0,d],218964);var c=e.i(632781);let h={name:"message-square",size:24,node:[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]]};h.node;let u=(0,l.default)(h),f={name:"phone-off",size:24,node:[["path",{d:"M10.1 13.9a14 14 0 0 0 3.732 2.668 1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2 18 18 0 0 1-12.728-5.272",key:"1wngk7"}],["path",{d:"M22 2 2 22",key:"y4kqgn"}],["path",{d:"M4.76 13.582A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 .244.473",key:"10hv5p"}]]};f.node;let m=(0,l.default)(f);var p=e.i(566595);let g={name:"send",size:24,node:[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]};g.node;let x=(0,l.default)(g),y={name:"terminal",size:24,node:[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]]};y.node;let w=(0,l.default)(y);var k=e.i(747925),b=e.i(271645),v=e.i(798120),j=e.i(660302),N=e.i(671428),_=e.i(213377);let S={name:"cable",size:24,node:[["path",{d:"M17 19a1 1 0 0 1-1-1v-2a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v2a1 1 0 0 1-1 1z",key:"trhst0"}],["path",{d:"M17 21v-2",key:"ds4u3f"}],["path",{d:"M19 14V6.5a1 1 0 0 0-7 0v11a1 1 0 0 1-7 0V10",key:"1mo9zo"}],["path",{d:"M21 21v-2",key:"eo0ou"}],["path",{d:"M3 5V3",key:"1k5hjh"}],["path",{d:"M4 10a2 2 0 0 1-2-2V6a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2a2 2 0 0 1-2 2z",key:"1dd30t"}],["path",{d:"M7 5V3",key:"1t1388"}]]};S.node;let M=(0,l.default)(S);e.s(["McpMark",0,M],991322);let C={name:"cpu",size:24,node:[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]]};C.node;let A=(0,l.default)(C);e.s(["MemoryMark",0,A],852116);let E=e.i(328256).BookMarked;e.s(["SkillsMark",0,E],589128);var L=e.i(621285),O=e.i(283653),T=e.i(647163);let B={[_.TOOL_NAMES.web_search]:function({tool:e,threadId:a,collapsed:r}){let i=q(e.results);return(0,t.jsxs)(R,{tool:e,threadId:a,icon:p.Search,collapsed:r,children:[(0,t.jsxs)("p",{className:"px-3 pt-1 pb-1.5 text-[13px] leading-snug break-keep",children:["“",e.input,"”"]}),i.length>0&&(0,t.jsx)("ol",{className:"space-y-0.5 px-3 pb-2",children:i.map((e,a)=>(0,t.jsxs)("li",{className:"flex gap-2 text-[11.5px] leading-snug text-muted-foreground",children:[(0,t.jsx)("span",{className:"mt-1.25 size-1 shrink-0 rounded-full bg-muted-foreground/50"}),(0,t.jsx)("span",{className:"truncate",children:e})]},`${a}-${e}`))})]})},[_.TOOL_NAMES.bash]:function({tool:e,threadId:a,collapsed:r}){let i=q(e.results);return(0,t.jsx)(R,{tool:e,threadId:a,icon:w,collapsed:r,children:(0,t.jsxs)("pre",{className:"mx-3 overflow-x-auto rounded-lg bg-foreground/5 px-2.5 py-1.5 font-mono text-[11px] leading-relaxed scrollbar-none dark:bg-black/25",children:[(0,t.jsx)("span",{className:"text-muted-foreground/60",children:"$ "}),e.input,i.length>0&&(0,t.jsx)("span",{className:"block text-muted-foreground",children:i.join("\n")})]})})},[_.TOOL_NAMES.write_file]:e=>(0,t.jsx)(F,{icon:s,...e})},z={[_.TOOL_NAMES.web_search]:p.Search,[_.TOOL_NAMES.bash]:w,[_.TOOL_NAMES.write_file]:s,[_.TOOL_NAMES.memory_recall]:A,[_.TOOL_NAMES.memory_remember]:A,[_.TOOL_NAMES.memory_forget]:A,[_.TOOL_NAMES.memory_conversation]:A,[_.TOOL_NAMES.load_skill]:E,[_.TOOL_NAMES.tool_search]:M,[_.TOOL_NAMES.tool_call]:M,[_.TOOL_NAMES.delegate]:x,[_.TOOL_NAMES.thread]:d,[_.TOOL_NAMES.send_message]:u,[_.TOOL_NAMES.end_call]:m},$=e=>z[e]??k.Wrench;function F({icon:e,tool:a,threadId:r,collapsed:l}){let n=a.path??a.input;return(0,t.jsxs)(R,{tool:a,threadId:r,icon:e,collapsed:l,children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 px-3 pt-1 pb-1.5",children:[(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-[11px]",children:a.input}),(0,t.jsxs)(L.FileLink,{path:n,label:`Open ${n}`,className:"flex shrink-0 items-center gap-1 rounded-md px-1.5 py-0.5 font-mono text-[10px] text-muted-foreground outline-none transition-colors hover:bg-background hover:text-foreground focus-visible:ring-3 focus-visible:ring-ring/50 disabled:opacity-50",children:[(0,t.jsx)(i.ExternalLink,{className:"size-3"}),"Open"]})]}),(0,t.jsx)(K,{lines:q(a.results),mono:!0})]})}function I({tool:e,threadId:a,collapsed:r}){return(0,t.jsxs)(R,{tool:e,threadId:a,icon:$(e.name),collapsed:r,children:[(0,t.jsx)("p",{className:"px-3 pt-1 pb-1.5 text-[12px] leading-snug break-keep",children:e.input}),(0,t.jsx)(K,{lines:q(e.results)})]})}function R({tool:e,threadId:i,icon:l,collapsed:n=!1,children:s}){let o=void 0===e.results,[d,h]=(0,b.useState)(!n),u=d||o,f=i&&e.callId&&((e.results?.length??0)>0||e.more);return(0,t.jsxs)("div",{className:(0,T.cn)("@container w-full overflow-hidden rounded-xl transition-colors",u?"bg-background/80 dark:bg-white/4":"hover:bg-foreground/4"),children:[(0,t.jsxs)("button",{type:"button",onClick:()=>h(e=>!e),"aria-expanded":u,className:"flex w-full items-center gap-2 rounded-xl px-2.5 py-1.5 text-left outline-none focus-visible:ring-3 focus-visible:ring-ring/50",children:[(0,t.jsx)("span",{className:"grid size-5 shrink-0 place-items-center rounded-[7px] bg-foreground/8 text-muted-foreground",children:o?(0,t.jsx)(c.Loader2,{className:"size-3 animate-spin"}):(0,t.jsx)(l,{className:"size-3"})}),e.note?(0,t.jsxs)(t.Fragment,{children:[o?(0,t.jsx)(j.ShinyText,{text:e.note,speed:2.4,className:"min-w-0 flex-1 truncate text-[12px] leading-4 break-keep"}):(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate text-[12px] leading-4 break-keep",children:e.note}),(0,t.jsx)("span",{className:"hidden min-w-0 flex-1 truncate font-mono text-[11px] leading-4 text-muted-foreground/85 @lg:block",children:e.input})]}):o?(0,t.jsx)(j.ShinyText,{text:e.input,speed:2.4,className:"min-w-0 flex-1 truncate font-mono text-[11px] leading-4"}):(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-[11px] leading-4 text-foreground/80",children:e.input}),(0,t.jsx)("span",{className:"shrink-0 font-mono text-[10px] text-muted-foreground/70",children:e.name}),!o&&(0,t.jsx)(a.Check,{className:"size-3 shrink-0 text-muted-foreground/50"}),(0,t.jsx)(r.ChevronDown,{className:(0,T.cn)("size-3 shrink-0 text-muted-foreground/50 transition-transform",u&&"rotate-180")})]}),u&&(0,t.jsxs)("div",{className:"pb-1.5 pl-[1.625rem]",children:[s,f&&(0,t.jsx)(D,{threadId:i,callId:e.callId})]})]})}function D({threadId:e,callId:a}){let[i,l]=(0,b.useState)(!1),{data:n,isLoading:s}=(0,O.useServerRoute)(i?v.queryKey.toolResult(e,a):null);return(0,t.jsxs)("div",{className:"px-3 pb-1",children:[(0,t.jsxs)("button",{type:"button",onClick:()=>l(e=>!e),className:"flex items-center gap-1 rounded-md py-0.5 font-mono text-[10px] text-muted-foreground outline-none transition-colors hover:text-foreground focus-visible:ring-3 focus-visible:ring-ring/50",children:[(0,t.jsx)(r.ChevronDown,{className:(0,T.cn)("size-3",i&&"rotate-180")}),i?"Less":"Everything"]}),i&&(s||!n?(0,t.jsx)(N.Skeleton,{className:"mt-1.5 h-12 w-full rounded-lg"}):(0,t.jsxs)("div",{className:"mt-1.5 space-y-1.5",children:[V(n).map((e,a)=>(0,t.jsx)(H,{src:e},`${a}-${e.length}`)),q(n).length>0&&(0,t.jsx)("pre",{className:"max-h-72 overflow-auto rounded-lg bg-foreground/5 px-2.5 py-2 font-mono text-[11px] leading-relaxed break-all whitespace-pre-wrap dark:bg-black/25",children:q(n).join("\n")})]}))]})}function H({src:e}){return(0,t.jsx)("img",{src:e,alt:"",className:"block w-full rounded-lg bg-muted object-contain"})}function K({lines:e,mono:a}){return 0===e.length?null:(0,t.jsx)("ul",{className:"px-3 pb-1.5",children:e.map((e,r)=>(0,t.jsx)("li",{className:(0,T.cn)("truncate text-[11px] leading-relaxed text-muted-foreground",a&&"font-mono"),children:e},`${r}-${e}`))})}let q=e=>e?.flatMap(e=>"text"===e.type?[e.text]:[])??[],V=e=>e?.flatMap(e=>"image"===e.type?[e.src]:[])??[];e.s(["BotTool",0,function(e){let a=B[e.tool.name]??I;return(0,t.jsx)(a,{...e})},"toolIcon",0,$],222055)},256604,933916,671228,762074,e=>{"use strict";var t=e.i(843476),a=e.i(635963),r=e.i(271645),i=e.i(504565),l=e.i(41533),n=e.i(149666),s=e.i(451888);let o=["mark","ascii"],d=["ascii","emoji","emojiOnly"];e.s(["ASCII_CHARSETS",0,d,"FACE_KINDS",0,o],933916);var c=e.i(413168);let h=n.LiveSettingsSchema.extend({locale:i.default.string().max(35).nullish()}),u=s.botIconSchema.extend({kind:i.default.enum(o).default("ascii"),charset:i.default.enum(d).default(l.ASCII_FACE.charset),fontSize:i.default.number().min(l.ASCII_FACE.fontSize.min).max(l.ASCII_FACE.fontSize.max).default(l.ASCII_FACE.fontSize.default),density:i.default.number().min(l.ASCII_FACE.density.min).max(l.ASCII_FACE.density.max).default(l.ASCII_FACE.density.default)}),f=u.parse({}),m={min:3,max:32},p=i.default.object({enabled:i.default.boolean(),phrase:i.default.string().trim().min(m.min).max(m.max)}),g=i.default.object({enabled:i.default.boolean(),combo:i.default.string().trim().min(1).max(64)}),x=["off","waiting","any"],y=i.default.enum(x),w=["center","sides"],k=i.default.enum(w);i.default.object({id:i.default.string().min(1),role:i.default.enum(["user","assistant","tool"]),tool:i.default.string().nullish(),text:i.default.string(),seq:i.default.number().int().min(0),fragments:i.default.array(c.LiveFragmentSchema).nullish()}),i.default.object({id:i.default.string().min(1),text:i.default.string(),seq:i.default.number().int().min(0)}),e.s(["CALL_BACK_DEFAULT",0,"off","CALL_BACK_LABEL",0,{off:"Never",waiting:"When a job needs me",any:"Whenever a job ends"},"CALL_BACK_MODES",0,x,"CAPTION_VIEWS",0,w,"CallBackSchema",0,y,"CaptionViewSchema",0,k,"FACE_DEFAULT",0,f,"HOTKEY_DEFAULT",0,{enabled:!0,combo:"alt+shift+KeyT"},"HotkeySchema",0,g,"ThursdayFaceSchema",0,u,"ThursdaySettingsSchema",0,h,"WAKE_DEFAULT",0,{enabled:!0,phrase:"hey thursday"},"WAKE_PHRASE",0,m,"WakeSchema",0,p],671228);let b="thursday.icon";function v(){try{let e=window.localStorage.getItem(b);return u.parse(e?JSON.parse(e):{})}catch{return f}}let j=v(),N=new Set;function _(){for(let e of N)e()}function S(){return(0,r.useSyncExternalStore)(e=>{N.add(e);let t=e=>{e.key===b&&(j=v(),_())};return window.addEventListener("storage",t),()=>{N.delete(e),window.removeEventListener("storage",t)}},()=>j,()=>f)}e.s(["setThursdayFace",0,function(e){j=e;try{window.localStorage.setItem(b,JSON.stringify(e))}catch{}_()},"useThursdayFace",0,S],762074);let M="thursday";e.s(["THURSDAY_SEED",0,M,"ThursdayMark",0,function({size:e=16,className:r}){let i=S();return(0,t.jsx)(a.BotMark,{size:e,seed:M,color:i.color,shape:i.shape,outline:i.outline,paint:i.paint,notify:!1,className:r})}],256604)},621285,616172,67268,e=>{"use strict";var t=e.i(843476),a=e.i(271645),r=e.i(798120),i=e.i(167881),l=e.i(630374),n=e.i(683408),s=e.i(671428),o=e.i(647163);function d({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:(0,t.jsx)("table",{"data-slot":"table",className:(0,o.cn)("w-full caption-bottom text-sm",e),...a})})}function c({className:e,...a}){return(0,t.jsx)("thead",{"data-slot":"table-header",className:(0,o.cn)("[&_tr]:border-b",e),...a})}function h({className:e,...a}){return(0,t.jsx)("tbody",{"data-slot":"table-body",className:(0,o.cn)("[&_tr:last-child]:border-0",e),...a})}function u({className:e,...a}){return(0,t.jsx)("tr",{"data-slot":"table-row",className:(0,o.cn)("border-b border-border/60 transition-colors data-[state=selected]:bg-muted hover:bg-muted/40",e),...a})}function f({className:e,...a}){return(0,t.jsx)("th",{"data-slot":"table-head",className:(0,o.cn)("h-9 px-2 text-left align-middle font-mono text-[11px] font-normal tracking-[0.1em] whitespace-nowrap text-muted-foreground uppercase [&:has([role=checkbox])]:pr-0",e),...a})}function m({className:e,...a}){return(0,t.jsx)("td",{"data-slot":"table-cell",className:(0,o.cn)("p-2 align-middle [&:has([role=checkbox])]:pr-0",e),...a})}var p=e.i(41533);let g=e=>`text/${e}; charset=utf-8`,x={md:{kind:"markdown",mime:g("markdown")},markdown:{kind:"markdown",mime:g("markdown")},csv:{kind:"csv",mime:g("csv")},json:{kind:"json",mime:"application/json; charset=utf-8"},txt:{kind:"text",mime:g("plain")},log:{kind:"text",mime:g("plain")},html:{kind:"frame",mime:g("html")},htm:{kind:"frame",mime:g("html")},pdf:{kind:"frame",mime:"application/pdf"},png:{kind:"image",mime:"image/png"},jpg:{kind:"image",mime:"image/jpeg"},jpeg:{kind:"image",mime:"image/jpeg"},gif:{kind:"image",mime:"image/gif"},webp:{kind:"image",mime:"image/webp"},svg:{kind:"image",mime:"image/svg+xml"},mp3:{kind:"audio",mime:"audio/mpeg"},wav:{kind:"audio",mime:"audio/wav"},mp4:{kind:"video",mime:"video/mp4"},webm:{kind:"video",mime:"video/webm"},css:{kind:"none",mime:g("css")},js:{kind:"none",mime:g("javascript")},woff2:{kind:"none",mime:"font/woff2"}},y=e=>x[e.split(".").pop()?.toLowerCase()??""]?.kind??"none",w=Object.entries(x).filter(([,e])=>"none"!==e.kind).map(([e])=>e),k=RegExp(String.raw`(?<![\p{L}\p{N}_/:@%-])(?:[\p{L}\p{N}_.@%-]+/)*[\p{L}\p{N}_@%-]+(?:\.[\p{L}\p{N}_-]+)*\.(?:${w.join("|")})\b`,"giu"),b=`${p.PATHS.workspace}/`;function v(e){let t=e.trim(),a=t.indexOf(b);return a>=0?t.slice(a+b.length)||null:t.startsWith("/")||/^[A-Za-z]:/.test(t)||t.split("/").includes("..")?null:t||null}e.s(["pathsIn",0,function(e){let t=e.replace(/\b[a-z][\w+.-]*:\/\/\S+/gi," "),a=new Set;for(let e of t.match(k)??[]){let t=function(e){let t=v(e);if(!t)return null;let[a,...r]=t.split("/");return r.length&&a.includes(".")?null:t}(e);t&&a.add(t)}return[...a].slice(0,6)},"viewKindOf",0,y,"workspaceRelative",0,v],616172);var j=e.i(95187);let N=(0,j.createServerReference)("7fbd6f0e49811eccb94c49c5cb9f649b9a03d6a678",j.callServer,void 0,j.findSourceMapURL,"openFileAction");e.s(["openFileAction",0,N],67268);var _=e.i(609856);let S=new Set(["frame","image","audio","video"]);function M(e){let t=v(e);if(!t)return{how:"os"};let a=y(t);return S.has(a)?{how:"tab",path:t,href:r.queryKey.fileView(t)}:"none"===a?{how:"os"}:{how:"dialog",path:t}}let C=(0,a.createContext)(null),A={dialog:{prose:"px-5 py-4",block:"px-4 py-3"},page:{prose:"px-5 py-6 sm:px-8",block:"px-5 py-5"},inline:{prose:"pb-3",block:"pb-3"}};function E({kind:e,content:a,truncated:r,where:i="dialog"}){return(0,t.jsxs)(t.Fragment,{children:[null!=r&&(0,t.jsx)(L,{of:r}),(0,t.jsx)(O,{kind:e,content:a,where:i})]})}function L({of:e}){return(0,t.jsxs)("p",{className:"border-b border-border/60 px-5 py-2.5 font-mono text-[11px] text-muted-foreground",children:[`Showing the first ${(0,o.formatBytes)(p.WORKSPACE_VIEW.textMax)} of ${(0,o.formatBytes)(e)}. `,"Open the file itself for the rest."]})}function O({kind:e,content:a,where:r}){let i=A[r];switch(e){case"markdown":return(0,t.jsx)("div",{className:(0,o.cn)("min-w-0 text-sm leading-relaxed",i.prose),children:(0,t.jsx)(n.Markdown,{children:a})});case"csv":return(0,t.jsx)(F,{content:a,className:i.block});case"json":return(0,t.jsx)($,{text:function(e){try{return JSON.stringify(JSON.parse(e),null,2)}catch{return e}}(a),className:i.block});default:return(0,t.jsx)($,{text:a,className:i.block})}}function T(e){let[t,i]=(0,a.useState)(null),[l,n]=(0,a.useState)(null),[s,d]=(0,a.useState)(null);return(0,a.useEffect)(()=>{if(!e)return;i(null),n(null),d(null);let t=!1;return fetch(r.queryKey.file(e),{headers:{range:`bytes=0-${p.WORKSPACE_VIEW.textMax-1}`}}).then(async e=>{if(!e.ok)throw Error(await e.text());return{text:await e.text(),of:function(e){let t=e.headers.get("content-range")?.match(/^bytes \d+-(\d+)\/(\d+)$/);if(!t)return null;let[,a,r]=t.map(Number);return a+1<r?r:null}(e)}}).then(({text:e,of:a})=>{t||(i(null===a?e:e.slice(0,e.lastIndexOf("\n")+1||void 0)),d(a))}).catch(e=>!t&&n((0,o.errorToString)(e))),()=>{t=!0}},[e]),{content:t,failure:l,truncated:s}}function B({path:e,bytes:a}){let[r,l]=(0,_.useServerAction)(N);return(0,t.jsxs)("div",{className:"space-y-4 p-8",children:[(0,t.jsxs)("p",{className:"max-w-lg text-sm leading-relaxed text-muted-foreground",children:[`This file is ${(0,o.formatBytes)(a)} — too big to draw here without `,"taking the window with it. Open it where it is instead."]}),(0,t.jsx)(i.Button,{variant:"outline",loading:l,onClick:()=>r(e),children:"Reveal in the file manager"})]})}function z({path:e,kind:a,onClose:r}){let{content:i,failure:n,truncated:o}=T(e),d=e?.split("/").pop()??"";return(0,t.jsx)(l.Dialog,{open:null!==e,onOpenChange:e=>!e&&r(),children:(0,t.jsxs)(l.DialogContent,{className:"flex max-h-[calc(100vh-3rem)] flex-col gap-0 overflow-hidden p-0 sm:max-w-4xl",children:[(0,t.jsx)(l.DialogTitle,{className:"sr-only",children:d}),(0,t.jsx)("div",{className:"flex shrink-0 items-center gap-2 border-b border-border/60 px-4 py-2.5 pr-12",children:(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-[12px]",children:e})}),(0,t.jsx)("div",{className:"min-h-0 flex-1 overflow-auto",children:n?(0,t.jsx)("p",{className:"p-5 font-mono text-xs text-destructive",children:n}):null===i?(0,t.jsxs)("div",{className:"space-y-3 p-5",children:[(0,t.jsx)(s.Skeleton,{className:"h-5 w-2/3"}),(0,t.jsx)(s.Skeleton,{className:"h-4 w-full"}),(0,t.jsx)(s.Skeleton,{className:"h-4 w-5/6"})]}):(0,t.jsx)(E,{kind:a,content:i,truncated:o})})]})})}function $({text:e,className:a}){return(0,t.jsx)("pre",{className:(0,o.cn)("overflow-x-auto font-mono text-[12px] leading-relaxed whitespace-pre-wrap text-foreground/90",a),children:e})}function F({content:e,className:r}){let[i,...l]=(0,a.useMemo)(()=>(function(e){let t=[],a=[],r="",i=!1;for(let l=0;l<e.length;l++){let n=e[l];i?'"'===n&&'"'===e[l+1]?(r+='"',l++):'"'===n?i=!1:r+=n:'"'===n?i=!0:","===n?(a.push(r),r=""):"\n"===n||"\r"===n?("\r"===n&&"\n"===e[l+1]&&l++,a.push(r),t.push(a),a=[],r=""):r+=n}return(r.length||a.length)&&(a.push(r),t.push(a)),t.filter(e=>e.some(e=>e.trim()))})(e),[e]);return i?(0,t.jsx)("div",{className:(0,o.cn)("overflow-x-auto",r),children:(0,t.jsxs)(d,{children:[(0,t.jsx)(c,{children:(0,t.jsx)(u,{children:i.map((e,a)=>(0,t.jsx)(f,{className:"whitespace-nowrap",children:e},`${a}-${e}`))})}),(0,t.jsx)(h,{children:l.map((e,a)=>(0,t.jsx)(u,{children:i.map((r,i)=>(0,t.jsx)(m,{className:"whitespace-nowrap",children:e[i]??""},`${a}-${i}`))},`${a}-${e[0]??""}`))})]})}):(0,t.jsx)($,{text:e,className:r})}e.s(["FileBody",0,E,"FileDialog",0,z,"FileLink",0,function({path:e,className:i,title:l,label:n,children:s}){let o=M(e),d=(0,a.useContext)(C),[c,h]=(0,_.useServerAction)(N);return"tab"===o.how?(0,t.jsx)("a",{href:o.href,target:"_blank",rel:"noreferrer",title:l??e,"aria-label":n,className:i,children:s}):(0,t.jsx)("button",{type:"button",disabled:h,title:l??e,"aria-label":n,className:i,onClick:()=>{"dialog"===o.how?d?d(o.path):window.open(r.queryKey.fileView(o.path),"_blank"):c(e)},children:s})},"FilePreview",0,function({path:e,bytes:a}){let i=y(e),{content:l,failure:n,truncated:o}=T(S.has(i)?null:e);return("frame"===i||"image"===i)&&a>p.WORKSPACE_VIEW.elementMax?(0,t.jsx)(B,{path:e,bytes:a}):"frame"===i?(0,t.jsx)("iframe",{title:e,src:r.queryKey.file(e),allow:"clipboard-read; clipboard-write; fullscreen; autoplay",className:"h-full w-full bg-white"}):"image"===i?(0,t.jsx)("img",{src:r.queryKey.file(e),alt:e,className:"mx-auto max-w-full p-6"}):"audio"===i||"video"===i?"audio"===i?(0,t.jsx)("audio",{controls:!0,src:r.queryKey.file(e),className:"w-full p-6",children:(0,t.jsx)("track",{kind:"captions"})}):(0,t.jsx)("video",{controls:!0,src:r.queryKey.file(e),className:"max-w-full p-6",children:(0,t.jsx)("track",{kind:"captions"})}):n?(0,t.jsx)("p",{className:"p-5 font-mono text-xs text-destructive",children:n}):null===l?(0,t.jsxs)("div",{className:"space-y-3 p-5",children:[(0,t.jsx)(s.Skeleton,{className:"h-5 w-2/3"}),(0,t.jsx)(s.Skeleton,{className:"h-4 w-full"}),(0,t.jsx)(s.Skeleton,{className:"h-4 w-5/6"})]}):(0,t.jsx)(E,{kind:i,content:l,truncated:o})},"FileViewer",0,function({children:e}){let[r,i]=(0,a.useState)(null);return(0,t.jsxs)(C,{value:i,children:[e,(0,t.jsx)(z,{path:r,kind:r?y(r):"text",onClose:()=>i(null)})]})},"fileTarget",0,M,"useFileText",0,T,"useOpenFile",0,function(){let e=(0,a.useContext)(C);return(0,a.useCallback)(t=>{let a=M(t);if("os"===a.how)return!1;if("dialog"===a.how&&e)return e(a.path),!0;let i="tab"===a.how?a.href:r.queryKey.fileView(a.path);return null!==window.open(i,"_blank")},[e])}],621285)},328256,e=>{"use strict";var t=e.i(456420);let a={name:"book-marked",size:24,node:[["path",{d:"M10 2v8l3-3 3 3V2",key:"sqw3rj"}],["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}]]};a.node;let r=(0,t.default)(a);e.s(["BookMarked",0,r],328256)},24071,829600,226091,e=>{"use strict";var t=e.i(456420);let a={name:"chevron-left",size:24,node:[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]};a.node;let r=(0,t.default)(a);e.s(["ChevronLeft",0,r],24071);let i={name:"file",size:24,node:[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]]};i.node;let l=(0,t.default)(i);e.s(["File",0,l],829600);let n={name:"file-text",size:24,node:[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]};n.node;let s=(0,t.default)(n);e.s(["FileText",0,s],226091)},482022,e=>{"use strict";var t=e.i(456420);let a={name:"external-link",size:24,node:[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]};a.node;let r=(0,t.default)(a);e.s(["ExternalLink",0,r],482022)},905015,e=>{"use strict";var t=e.i(456420);let a={name:"file-braces",size:24,node:[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1",key:"1oajmo"}],["path",{d:"M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1",key:"mpwhp6"}]],aliases:["file-json"]};a.node;let r=(0,t.default)(a);e.s(["FileJson",0,r],905015)},569644,e=>{"use strict";var t=e.i(456420);let a={name:"folder-open",size:24,node:[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]};a.node;let r=(0,t.default)(a);e.s(["FolderOpen",0,r],569644)},696017,e=>{"use strict";var t=e.i(60231),a=e.i(419524);e.i(947716);var r=e.i(723685),i=(0,a.__name)(e=>{let{securityLevel:a}=(0,t.getConfig2)(),i=(0,r.select)("body");if("sandbox"===a){let t=(0,r.select)(`#i${e}`),a=t.node()?.contentDocument??document;i=(0,r.select)(a.body)}return i.select(`#${e}`)},"selectSvgElement");e.s(["selectSvgElement",0,i])},502056,e=>{"use strict";var t=e.i(217248),a=e.i(447804),r=e.i(508324),i=e.i(419524),l=(0,i.__name)(({flowchart:e})=>{let t=e?.subGraphTitleMargin?.top??0,a=e?.subGraphTitleMargin?.bottom??0;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:a,subGraphTitleTotalMargin:t+a}},"getSubGraphTitleMargins"),n=new Map;async function s(e,r,i){let l,s;"rect"===r.shape&&(r.rx&&r.ry?r.shape="roundedRect":r.shape="squareRect");let o=r.shape?t.shapes[r.shape]:void 0;if(!o)throw Error(`No such shape: ${r.shape}. Please check your syntax.`);if(r.link){let t;"sandbox"===i.config.securityLevel?t="_top":r.linkTarget&&(t=r.linkTarget||"_blank"),l=e.insert("svg:a").attr("xlink:href",r.link).attr("target",t??null),s=await o(l,r,i)}else l=s=await o(e,r,i);return l.attr("data-look",(0,a.handleUndefinedAttr)(r.look)),r.tooltip&&s.attr("title",r.tooltip),n.set(r.id,l),r.haveCallback&&l.attr("class",l.attr("class")+" clickable"),l}(0,i.__name)(s,"insertNode");var o=(0,i.__name)((e,t)=>{n.set(t.id,e)},"setNodeElem"),d=(0,i.__name)(()=>{n.clear()},"clear"),c=(0,i.__name)(e=>{let t=n.get(e.id);r.log.trace("Transforming node",e.diff,e,"translate("+(e.x-e.width/2-5)+", "+e.width/2+")");let a=e.diff||0;return e.clusterNode?t.attr("transform","translate("+(e.x+a-e.width/2)+", "+(e.y-e.height/2-8)+")"):t.attr("transform","translate("+e.x+", "+e.y+")"),a},"positionNode");e.s(["clear",0,d,"getSubGraphTitleMargins",0,l,"insertNode",0,s,"positionNode",0,c,"setNodeElem",0,o])},369110,e=>{"use strict";var t=e.i(502056),a=e.i(217248),r=e.i(224797),i=e.i(836333),l=e.i(60231),n=e.i(508324),s=e.i(419524);e.i(947716);var o=e.i(723685),d=e.i(883272),c=(0,s.__name)(async(e,t)=>{let s,c,h=(0,l.getConfig2)(),{themeVariables:u,handDrawnSeed:f}=h,{clusterBkg:m,clusterBorder:p}=u,{labelStyles:g,nodeStyles:x,borderStyles:y,backgroundStyles:w}=(0,r.styles2String)(t),k=e.insert("g").attr("class","cluster swimlane "+(t.cssClasses||"")).attr("id",t.id).attr("data-id",t.id).attr("data-et","cluster").attr("data-look",t.look),b=(0,l.evaluate)(h.flowchart.htmlLabels),v="LR"===t.direction,j=k.insert("g").attr("class","cluster-label swimlane-label"),N=await (0,i.createText)(j,t.label,{style:t.labelStyle,useHtmlLabels:b,isNode:!0,width:t.width}),_=N.getBBox();if(b){let e=N.children[0],t=(0,o.select)(N);_=e.getBoundingClientRect(),t.attr("width",_.width),t.attr("height",_.height)}let S=t.padding??0,M=t.width<=_.width+S?_.width+S:t.width;t.width<=_.width+S?t.diff=(M-t.width)/2-S:t.diff=-S;let C=t.height,A=t.y-C/2,E=t.y+C/2,L=t.x-M/2,O=void 0!==t.swimlaneContentTop?t.swimlaneContentTop:A+C/3,T=4*!!v,B=_.height+2*T;if(v){let e=Math.max(B,_.height+2*T),a=L+e,i=Math.max(0,M-e);if("handDrawn"===t.look){let l=d.default.svg(k),n=(0,r.userNodeOverrides)(t,{roughness:.7,fill:m,stroke:p,fillWeight:3,seed:f}),o=(0,r.userNodeOverrides)(t,{roughness:.7,fill:"none",stroke:p,seed:f}),h=l.rectangle(L,A,e,C,n);s=k.insert(()=>h,":first-child");let u=l.rectangle(a,A,i,C,o);c=k.insert(()=>u,":first-child"),s.select("path:nth-child(2)").attr("style",y.join(";")),s.select("path").attr("style",w.join(";").replace("fill","stroke"))}else s=k.insert("rect",":first-child"),c=k.insert("rect",":first-child"),s.attr("class","swimlane-title").attr("style",x).attr("x",L).attr("y",A).attr("width",e).attr("height",C).attr("fill",m).attr("stroke",p),c.attr("class","swimlane-body").attr("style",x).attr("x",a).attr("y",A).attr("width",i).attr("height",C).attr("fill","none").attr("stroke",p);let l=L+e/2,n=t.y;j.attr("transform",`translate(${l}, ${n}) rotate(-90) translate(${-_.width/2}, ${-_.height/2})`)}else{let e=Math.min(B,Math.max(0,O-A)),a=A+e,i=Math.max(0,E-a),l=t.x-M/2;if("handDrawn"===t.look){let n=d.default.svg(k),o=(0,r.userNodeOverrides)(t,{roughness:.7,fill:m,stroke:p,fillWeight:3,seed:f}),h=(0,r.userNodeOverrides)(t,{roughness:.7,fill:"none",stroke:p,seed:f}),u=n.rectangle(l,A,M,e,o);s=k.insert(()=>u,":first-child");let g=n.rectangle(l,a,M,i,h);c=k.insert(()=>g,":first-child"),s.select("path:nth-child(2)").attr("style",y.join(";")),s.select("path").attr("style",w.join(";").replace("fill","stroke"))}else s=k.insert("rect",":first-child"),c=k.insert("rect",":first-child"),s.attr("class","swimlane-title").attr("style",x).attr("x",l).attr("y",A).attr("width",M).attr("height",e).attr("fill",m).attr("stroke",p),c.attr("class","swimlane-body").attr("style",x).attr("x",l).attr("y",a).attr("width",M).attr("height",i).attr("fill","none").attr("stroke",p);let n=t.x-_.width/2,o=A+(e-_.height)/2;j.attr("transform",`translate(${n}, ${o})`)}if(n.log.trace("Swimlane data ",t,JSON.stringify(t)),g){let e=j.select("span");e&&e.attr("style",g)}return t.offsetX=0,t.width=M,t.height=C,t.offsetY=_.height-S/2,t.intersect=function(e){return(0,a.intersect_rect_default)(t,e)},{cluster:k,labelBBox:_}},"swimlane"),h=(0,s.__name)(async(e,s)=>{let c,h;n.log.info("Creating subgraph rect for ",s.id,s);let u=(0,l.getConfig2)(),{themeVariables:f,handDrawnSeed:m}=u,{clusterBkg:p,clusterBorder:g}=f,{labelStyles:x,nodeStyles:y,borderStyles:w,backgroundStyles:k}=(0,r.styles2String)(s),b=e.insert("g").attr("class","cluster "+s.cssClasses).attr("id",s.domId).attr("data-look",s.look),v=(0,l.getEffectiveHtmlLabels)(u),j=b.insert("g").attr("class","cluster-label "),N=(c="markdown"===s.labelType?await (0,i.createText)(j,s.label,{style:s.labelStyle,useHtmlLabels:v,isNode:!0,width:s.width}):await (0,a.createLabel_default)(j,s.label,s.labelStyle||"",!1,!0)).getBBox();if((0,l.getEffectiveHtmlLabels)(u)){let e=c.children[0],t=(0,o.select)(c);N=e.getBoundingClientRect(),t.attr("width",N.width),t.attr("height",N.height)}let _=s.width<=N.width+s.padding?N.width+s.padding:s.width;s.width<=N.width+s.padding?s.diff=(_-s.width)/2-s.padding:s.diff=-s.padding;let S=s.height,M=s.x-_/2,C=s.y-S/2;if(n.log.trace("Data ",s,JSON.stringify(s)),"handDrawn"===s.look){let e=d.default.svg(b),t=(0,r.userNodeOverrides)(s,{roughness:.7,fill:p,stroke:g,fillWeight:3,seed:m}),i=e.path((0,a.createRoundedRectPathD)(M,C,_,S,0),t);(h=b.insert(()=>(n.log.debug("Rough node insert CXC",i),i),":first-child")).select("path:nth-child(2)").attr("style",w.join(";")),h.select("path").attr("style",k.join(";").replace("fill","stroke"))}else(h=b.insert("rect",":first-child")).attr("style",y).attr("rx",s.rx).attr("ry",s.ry).attr("x",M).attr("y",C).attr("width",_).attr("height",S);let{subGraphTitleTopMargin:A}=(0,t.getSubGraphTitleMargins)(u);if(j.attr("transform",`translate(${s.x-N.width/2}, ${s.y-s.height/2+A})`),x){let e=j.select("span");e&&e.attr("style",x)}let E=h.node().getBBox();return s.offsetX=0,s.width=E.width,s.height=E.height,s.offsetY=N.height-s.padding/2,s.intersect=function(e){return(0,a.intersect_rect_default)(s,e)},{cluster:b,labelBBox:N}},"rect"),u=(0,s.__name)((e,t)=>{let r=e.insert("g").attr("class","note-cluster").attr("id",t.domId),i=r.insert("rect",":first-child"),l=0*t.padding,n=l/2;i.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-n).attr("y",t.y-t.height/2-n).attr("width",t.width+l).attr("height",t.height+l).attr("fill","none");let s=i.node().getBBox();return t.width=s.width,t.height=s.height,t.intersect=function(e){return(0,a.intersect_rect_default)(t,e)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),f=(0,s.__name)(async(e,t)=>{let r,i=(0,l.getConfig2)(),{themeVariables:n,handDrawnSeed:s}=i,{altBackground:c,compositeBackground:h,compositeTitleBackground:u,nodeBorder:f}=n,m=e.insert("g").attr("class",t.cssClasses).attr("id",t.domId).attr("data-id",t.id).attr("data-look",t.look),p=m.insert("g",":first-child"),g=m.insert("g").attr("class","cluster-label"),x=m.append("rect"),y=await (0,a.createLabel_default)(g,t.label,t.labelStyle,void 0,!0),w=y.getBBox();if((0,l.getEffectiveHtmlLabels)(i)){let e=y.children[0],t=(0,o.select)(y);w=e.getBoundingClientRect(),t.attr("width",w.width),t.attr("height",w.height)}let k=0*t.padding,b=(t.width<=w.width+t.padding?w.width+t.padding:t.width)+k;t.width<=w.width+t.padding?t.diff=(b-t.width)/2-t.padding:t.diff=-t.padding;let v=t.height+k,j=t.height+k-w.height-6,N=t.x-b/2,_=t.y-v/2;t.width=b;let S=t.y-t.height/2-k/2+w.height+2;if("handDrawn"===t.look){let e=t.cssClasses.includes("statediagram-cluster-alt"),i=d.default.svg(m),l=t.rx||t.ry?i.path((0,a.createRoundedRectPathD)(N,_,b,v,10),{roughness:.7,fill:u,fillStyle:"solid",stroke:f,seed:s}):i.rectangle(N,_,b,v,{seed:s});r=m.insert(()=>l,":first-child");let n=i.rectangle(N,S,b,j,{fill:e?c:h,fillStyle:e?"hachure":"solid",stroke:f,seed:s});r=m.insert(()=>l,":first-child"),x=m.insert(()=>n)}else(r=p.insert("rect",":first-child")).attr("class","outer").attr("x",N).attr("y",_).attr("width",b).attr("height",v).attr("data-look",t.look),x.attr("class","inner").attr("x",N).attr("y",S).attr("width",b).attr("height",j);return g.attr("transform",`translate(${t.x-w.width/2}, ${_+1-3*!(0,l.getEffectiveHtmlLabels)(i)})`),t.height=r.node().getBBox().height,t.offsetX=0,t.offsetY=w.height-t.padding/2,t.labelBBox=w,t.intersect=function(e){return(0,a.intersect_rect_default)(t,e)},{cluster:m,labelBBox:w}},"roundedWithTitle"),m=(0,s.__name)(async(e,s)=>{let c;n.log.info("Creating subgraph rect for ",s.id,s);let h=(0,l.getConfig2)(),{themeVariables:u,handDrawnSeed:f}=h,{clusterBkg:m,clusterBorder:p}=u,{labelStyles:g,nodeStyles:x,borderStyles:y,backgroundStyles:w}=(0,r.styles2String)(s),k=e.insert("g").attr("class","cluster "+s.cssClasses).attr("id",s.domId).attr("data-look",s.look),b=(0,l.getEffectiveHtmlLabels)(h),v=k.insert("g").attr("class","cluster-label "),j=await (0,i.createText)(v,s.label,{style:s.labelStyle,useHtmlLabels:b,isNode:!0,width:s.width}),N=j.getBBox();if((0,l.getEffectiveHtmlLabels)(h)){let e=j.children[0],t=(0,o.select)(j);N=e.getBoundingClientRect(),t.attr("width",N.width),t.attr("height",N.height)}let _=s.width<=N.width+s.padding?N.width+s.padding:s.width;s.width<=N.width+s.padding?s.diff=(_-s.width)/2-s.padding:s.diff=-s.padding;let S=s.height,M=s.x-_/2,C=s.y-S/2;if(n.log.trace("Data ",s,JSON.stringify(s)),"handDrawn"===s.look){let e=d.default.svg(k),t=(0,r.userNodeOverrides)(s,{roughness:.7,fill:m,stroke:p,fillWeight:4,seed:f}),i=e.path((0,a.createRoundedRectPathD)(M,C,_,S,s.rx),t);(c=k.insert(()=>(n.log.debug("Rough node insert CXC",i),i),":first-child")).select("path:nth-child(2)").attr("style",y.join(";")),c.select("path").attr("style",w.join(";").replace("fill","stroke"))}else(c=k.insert("rect",":first-child")).attr("style",x).attr("rx",s.rx).attr("ry",s.ry).attr("x",M).attr("y",C).attr("width",_).attr("height",S);let{subGraphTitleTopMargin:A}=(0,t.getSubGraphTitleMargins)(h);if(v.attr("transform",`translate(${s.x-N.width/2}, ${s.y-s.height/2+A})`),g){let e=v.select("span");e&&e.attr("style",g)}let E=c.node().getBBox();return s.offsetX=0,s.width=E.width,s.height=E.height,s.offsetY=N.height-s.padding/2,s.intersect=function(e){return(0,a.intersect_rect_default)(s,e)},{cluster:k,labelBBox:N}},"kanbanSection"),p={rect:h,squareRect:h,roundedWithTitle:f,noteGroup:u,divider:(0,s.__name)((e,t)=>{let r,{themeVariables:i,handDrawnSeed:n}=(0,l.getConfig2)(),{nodeBorder:s}=i,o=e.insert("g").attr("class",t.cssClasses).attr("id",t.domId).attr("data-look",t.look),c=o.insert("g",":first-child"),h=0*t.padding,u=t.width+h;t.diff=-t.padding;let f=t.height+h,m=t.x-u/2,p=t.y-f/2;if(t.width=u,"handDrawn"===t.look){let e=d.default.svg(o).rectangle(m,p,u,f,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:s,seed:n});r=o.insert(()=>e,":first-child")}else{r=c.insert("rect",":first-child");let e="outer";t.look,e="divider",r.attr("class",e).attr("x",m).attr("y",p).attr("width",u).attr("height",f).attr("data-look",t.look)}return t.height=r.node().getBBox().height,t.offsetX=0,t.offsetY=0,t.intersect=function(e){return(0,a.intersect_rect_default)(t,e)},{cluster:o,labelBBox:{}}},"divider"),kanbanSection:m,swimlane:c},g=new Map,x=(0,s.__name)(async(e,t)=>{let a=t.shape||"rect",r=await p[a](e,t);return g.set(t.id,r),r},"insertCluster"),y=(0,s.__name)(()=>{g=new Map},"clear");e.s(["clear",0,y,"insertCluster",0,x])},121292,e=>{"use strict";var t=e.i(369110),a=e.i(382793),r=e.i(502056),i=e.i(217248),l=e.i(447804),n=e.i(60231),s=e.i(508324),o=e.i(419524),d={common:n.common_default,getConfig:n.getConfig,insertCluster:t.insertCluster,insertEdge:a.insertEdge,insertEdgeLabel:a.insertEdgeLabel,insertMarkers:a.markers_default,insertNode:r.insertNode,interpolateToCurve:l.interpolateToCurve,labelHelper:i.labelHelper,log:s.log,positionEdgeLabel:a.positionEdgeLabel},c={},h=(0,o.__name)(e=>{for(let t of e)c[t.name]=t},"registerLayoutLoaders");(0,o.__name)(()=>{h([{name:"dagre",loader:(0,o.__name)(async()=>await e.A(555153),"loader")},{name:"swimlane",loader:(0,o.__name)(async()=>await e.A(12782),"loader")},{name:"cose-bilkent",loader:(0,o.__name)(async()=>await e.A(208503),"loader")}])},"registerDefaultLayoutLoaders")();var u=(0,o.__name)(async(e,t)=>{if(!(e.layoutAlgorithm in c))throw Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);if(e.diagramId)for(let t of e.nodes){let a=t.domId||t.id;t.domId=`${e.diagramId}-${a}`}let a=c[e.layoutAlgorithm],r=await a.loader(),{theme:i,themeVariables:l}=e.config,{useGradient:n,gradientStart:s,gradientStop:o}=l,h=t.attr("id");if(t.append("defs").append("filter").attr("id",`${h}-drop-shadow`).attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${i?.includes("dark")?"#FFFFFF":"#000000"}`),t.append("defs").append("filter").attr("id",`${h}-drop-shadow-small`).attr("height","150%").attr("width","150%").append("feDropShadow").attr("dx","2").attr("dy","2").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${i?.includes("dark")?"#FFFFFF":"#000000"}`),n){let e=t.append("linearGradient").attr("id",t.attr("id")+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");e.append("svg:stop").attr("offset","0%").attr("stop-color",s).attr("stop-opacity",1),e.append("svg:stop").attr("offset","100%").attr("stop-color",o).attr("stop-opacity",1)}return r.render(e,t,d,{algorithm:a.algorithm})},"render"),f=(0,o.__name)((e="",{fallback:t="dagre"}={})=>{if(e in c)return e;if(t in c)return s.log.warn(`Layout algorithm ${e} is not registered. Using ${t} as fallback.`),t;throw Error(`Both layout algorithms ${e} and ${t} are not registered.`)},"getRegisteredLayoutAlgorithm");e.s(["getRegisteredLayoutAlgorithm",0,f,"registerLayoutLoaders",0,h,"render",0,u])}]);
@@ -0,0 +1 @@
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,986530,e=>{"use strict";var t=e.i(843476),a=e.i(225913);e.i(271645);var i=e.i(647163);function s({className:e,...a}){return(0,t.jsx)("label",{"data-slot":"label",className:(0,i.cn)("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",e),...a})}e.i(652225);let r=(0,a.cva)("group/field flex w-full gap-2 data-[invalid=true]:text-destructive",{variants:{orientation:{vertical:"flex-col *:w-full [&>.sr-only]:w-auto",horizontal:"flex-row items-center has-[>[data-slot=field-content]]:items-start *:data-[slot=field-label]:flex-auto has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",responsive:"flex-col *:w-full @md/field-group:flex-row @md/field-group:items-center @md/field-group:*:w-auto @md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:*:data-[slot=field-label]:flex-auto [&>.sr-only]:w-auto @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"}},defaultVariants:{orientation:"vertical"}});e.s(["Field",0,function({className:e,orientation:a="vertical",...s}){return(0,t.jsx)("div",{role:"group","data-slot":"field","data-orientation":a,className:(0,i.cn)(r({orientation:a}),e),...s})},"FieldContent",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"field-content",className:(0,i.cn)("group/field-content flex flex-1 flex-col gap-0.5 leading-snug",e),...a})},"FieldLabel",0,function({className:e,...a}){return(0,t.jsx)(s,{"data-slot":"field-label",className:(0,i.cn)("group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50 has-data-checked:border-primary/30 has-data-checked:bg-primary/5 has-[>[data-slot=field]]:rounded-lg has-[>[data-slot=field]]:border has-[>[data-slot=field]]:not-has-[:disabled,[data-disabled]]:hover:bg-muted/50 has-[>[data-slot=field]]:has-[:focus-visible]:border-ring has-[>[data-slot=field]]:has-[:focus-visible]:ring-3 has-[>[data-slot=field]]:has-[:focus-visible]:ring-ring/50 *:data-[slot=field]:p-2.5 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10","has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col",e),...a})}],986530)},319036,e=>{"use strict";var t=e.i(843476);e.i(924305);var a=e.i(271645),i=e.i(951437),s=e.i(828918),r=e.i(146376),n=e.i(502077),l=e.i(956789),o=e.i(552245),d=e.i(788015),c=e.i(540886),u=e.i(951849),f=e.i(133438),h=e.i(64350),m=e.i(469690),p=e.i(381104),x=e.i(884708),g=e.i(247778),v=e.i(31421),b=e.i(538489),k=e.i(675606),j=e.i(56434),y=e.i(606039);let w=a.forwardRef(function(e,w){let{checked:N,className:S,defaultChecked:C,"aria-labelledby":z,form:R,id:M,inputRef:F,name:L,nativeButton:T=!1,onCheckedChange:A,readOnly:D=!1,required:E=!1,disabled:B=!1,render:P,uncheckedValue:I,value:$,style:q,...K}=e,{clearErrors:O}=(0,x.useFormContext)(),{state:U,setTouched:V,setDirty:H,validityData:W,setFilled:G,setFocused:Y,validationMode:_,disabled:J,name:Z,validation:Q}=(0,m.useFieldRootContext)(),{labelId:X}=(0,g.useLabelableContext)(),ee=J||B,et=Z??L,ea=a.useRef(null),ei=(0,s.useMergedRefs)(ea,F,Q.inputRef),es=a.useRef(null),er=(0,d.useBaseUiId)(),en=(0,b.useLabelableId)({id:M}),el=T?void 0:en,[eo,ed]=(0,i.useControlled)({controlled:N,default:!!C,name:"Switch",state:"checked"});(0,p.useRegisterFieldControl)(es,er,eo,void 0,!ee,L),(0,r.useIsoLayoutEffect)(()=>{G(eo)},[eo,G]),(0,y.useValueChanged)(eo,()=>{O(et),H(eo!==W.initialValue),Q.change(eo)});let{getButtonProps:ec,buttonRef:eu}=(0,c.useButton)({disabled:ee,native:T}),ef=(0,v.useAriaLabelledBy)(z,X,ea,!T,el),eh={...Q.getValidationProps(ee),checked:eo,disabled:ee,form:R,id:el,name:et,required:E,style:et?n.visuallyHiddenInput:n.visuallyHidden,tabIndex:-1,type:"checkbox","aria-hidden":!0,ref:ei,onChange(e){if(e.nativeEvent.defaultPrevented)return;if(D)return void e.preventDefault();let t=e.currentTarget.checked,a=(0,k.createChangeEventDetails)(j.REASONS.none,e.nativeEvent);A?.(t,a),a.isCanceled||ed(t)},onClick(e){e.stopPropagation()},onFocus(){es.current?.focus()},...void 0!==$?{value:$}:l.EMPTY_OBJECT},em=a.useMemo(()=>({...U,checked:eo,disabled:ee,readOnly:D,required:E}),[U,eo,ee,D,E]),ep=(0,o.useRenderElement)("span",e,{state:em,ref:[w,es,eu],props:[{id:T?en:er,role:"switch","aria-checked":eo,"aria-readonly":D||void 0,"aria-required":E||void 0,"aria-labelledby":ef,onFocus(){ee||Y(!0)},onBlur(){let e=ea.current;e&&!ee&&(V(!0),Y(!1),"onBlur"===_&&Q.commit(e.checked))},onClick(e){if(D||ee)return;e.preventDefault();let t=ea.current;t&&(0,h.dispatchClickWithModifiers)(t,e)}},K,ec,e=>Q.getValidationProps(ee,e)],stateAttributesMapping:f.stateAttributesMapping});return(0,t.jsxs)(u.SwitchRootContext.Provider,{value:em,children:[ep,!eo&&et&&void 0!==I&&(0,t.jsx)("input",{type:"hidden",form:R,name:et,value:I,disabled:ee}),(0,t.jsx)("input",{...eh,suppressHydrationWarning:!0})]})}),N=a.forwardRef(function(e,t){let{render:a,className:i,style:s,...r}=e,n=(0,u.useSwitchRootContext)();return(0,o.useRenderElement)("span",e,{state:n,ref:t,stateAttributesMapping:f.stateAttributesMapping,props:r})});e.s(["Root",0,w,"Thumb",0,N],450994);var S=e.i(450994),S=S,C=e.i(647163);e.s(["Switch",0,function({className:e,size:a="default",...i}){return(0,t.jsx)(S.Root,{"data-slot":"switch","data-size":a,className:(0,C.cn)("cursor-pointer peer group/switch relative inline-flex shrink-0 items-center rounded-full border border-transparent transition-all outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-[size=default]:h-[18.4px] data-[size=default]:w-[32px] data-[size=sm]:h-[14px] data-[size=sm]:w-[24px] dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:bg-primary data-unchecked:bg-input dark:data-unchecked:bg-input/80 data-disabled:cursor-not-allowed data-disabled:opacity-50",e),...i,children:(0,t.jsx)(S.Thumb,{"data-slot":"switch-thumb",className:"pointer-events-none block rounded-full bg-background ring-0 transition-transform group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=sm]/switch:data-checked:translate-x-[calc(100%-2px)] dark:data-checked:bg-primary-foreground group-data-[size=default]/switch:data-unchecked:translate-x-0 group-data-[size=sm]/switch:data-unchecked:translate-x-0 dark:data-unchecked:bg-foreground"})})}],319036)},833959,e=>{"use strict";var t=e.i(843476),a=e.i(456420);let i={name:"app-window",size:24,node:[["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}],["path",{d:"M10 4v4",key:"pp8u80"}],["path",{d:"M2 8h20",key:"d11cs7"}],["path",{d:"M6 4v4",key:"1svtjw"}]]};i.node;let s=(0,a.default)(i);var r=e.i(328256),n=e.i(24071),l=e.i(867927),o=e.i(829600),d=e.i(226091),c=e.i(726067);let u={name:"globe",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]};u.node;let f=(0,a.default)(u),h={name:"mouse-pointer-2",size:24,node:[["path",{d:"M4.037 4.688a.495.495 0 0 1 .651-.651l16 6.5a.5.5 0 0 1-.063.947l-6.124 1.58a2 2 0 0 0-1.438 1.435l-1.579 6.126a.5.5 0 0 1-.947.063z",key:"edeuup"}]]};h.node;let m=(0,a.default)(h);var p=e.i(77071),x=e.i(566595);let g={name:"square-pen",size:24,node:[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],aliases:["pen-box","edit","pen-square"]};g.node;let v=(0,a.default)(g);var b=e.i(759659);let k={name:"upload",size:24,node:[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]]};k.node;let j=(0,a.default)(k);var y=e.i(271645),w=e.i(798120),N=e.i(167881),S=e.i(986530),C=e.i(23750),z=e.i(683408),R=e.i(917162),M=e.i(671428),F=e.i(319036),L=e.i(127341),T=e.i(184762),A=e.i(41533),D=e.i(895836),E=e.i(95187);let B=(0,E.createServerReference)("7f98b9d85dd58ad1d3e9b53a3a1799b27bffc75e94",E.callServer,void 0,E.findSourceMapURL,"createSkillAction"),P=(0,E.createServerReference)("7ffe58353e8a289deea66dd070a79a480a2ef64a81",E.callServer,void 0,E.findSourceMapURL,"deleteSkillAction"),I=(0,E.createServerReference)("7f52bfec15b438c9480ce2a68692632c2afb3f006a",E.callServer,void 0,E.findSourceMapURL,"setSkillDisabledAction"),$=(0,E.createServerReference)("7fd39b524aaead025e24a9b83ba354398abecf491b",E.callServer,void 0,E.findSourceMapURL,"uploadSkillAction");var q=e.i(609856),K=e.i(283653),O=e.i(647163);let U={browser:f,computer:s,"find-skills":x.Search,"interactive-page":m,"skill-creator":v};function V({skill:e}){let[a,i]=(0,q.useServerAction)(P,{onOk:()=>(0,K.revalidate)(w.queryKey.skills)}),[s]=(0,q.useServerAction)(I,{onOk:()=>(0,K.revalidate)(w.queryKey.skills)}),n=async()=>{await R.notify.confirm({title:`Delete ${e.name}?`,description:"Every file in this skill is deleted for good.",okText:"Delete",destructive:!0})&&a(e.dir)},o="default"===e.source&&U[e.dir]||r.BookMarked;return(0,t.jsxs)("div",{className:"group flex items-center transition-colors hover:bg-muted/50",children:[(0,t.jsxs)("button",{type:"button",onClick:()=>{var a;return a=e,R.notify.component({className:"sm:max-w-4xl",renderer:()=>(0,t.jsx)(H,{skill:a})})},className:"flex min-w-0 flex-1 items-center gap-3 py-4 pl-4 text-left outline-none focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",children:[(0,t.jsx)("span",{className:(0,O.cn)("grid size-10 shrink-0 place-items-center rounded-lg bg-muted text-muted-foreground",e.disabled&&"opacity-45"),children:(0,t.jsx)(o,{className:"size-4"})}),(0,t.jsxs)("span",{className:(0,O.cn)("min-w-0 flex-1 space-y-0.5",e.disabled&&"opacity-45"),children:[(0,t.jsx)("span",{className:"block truncate text-sm font-medium",children:e.name}),(0,t.jsx)("span",{className:"line-clamp-2 text-xs leading-relaxed text-muted-foreground",children:e.description})]}),(0,t.jsx)(l.ChevronRight,{className:"size-4 shrink-0 text-muted-foreground/60 group-hover:text-foreground"})]}),(0,t.jsxs)("div",{className:"mr-4 ml-5 flex w-18 shrink-0 items-center justify-end gap-3",children:[(0,t.jsx)(F.Switch,{checked:!e.disabled,onCheckedChange:t=>s(e.source,e.dir,!t),"aria-label":`${e.name} on or off`,className:"shrink-0"}),"custom"===e.source?(0,t.jsx)(N.Button,{size:"icon-sm",variant:"ghost",loading:i,onClick:n,className:"shrink-0 text-muted-foreground",children:(0,t.jsx)(b.Trash2,{})}):(0,t.jsx)("span",{className:"size-7 shrink-0"})]})]})}function H({skill:e}){let[a,i]=(0,y.useState)(""),[s,r]=(0,y.useState)("SKILL.md");return(0,t.jsx)(D.SettingDialogContent,{title:e.name,description:(0,t.jsx)(W,{skill:e,path:s??a}),children:(0,t.jsxs)("div",{className:"flex h-[36rem] divide-x divide-border/60 overflow-hidden rounded-xl border border-border/60 bg-background",children:[(0,t.jsxs)("div",{className:"flex w-44 shrink-0 flex-col overflow-y-auto bg-muted/20 py-1",children:[a&&(0,t.jsxs)("button",{type:"button",onClick:()=>i(a.split("/").slice(0,-1).join("/")),className:"mx-1 mb-1 flex items-center gap-1 rounded-md px-2 py-1 text-left font-mono text-[11px] text-muted-foreground outline-none hover:bg-muted/50 hover:text-foreground focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",children:[(0,t.jsx)(n.ChevronLeft,{className:"size-3 shrink-0"}),(0,t.jsx)("span",{className:"truncate",children:a.split("/").pop()})]}),(0,t.jsx)(Y,{source:e.source,dir:e.dir,path:a,current:s,onPick:e=>{let t=a?`${a}/${e.name}`:e.name;"dir"===e.kind?i(t):r(t)}})]}),(0,t.jsx)("div",{className:"min-w-0 flex-1 overflow-y-auto",children:s?(0,t.jsx)(J,{source:e.source,dir:e.dir,path:s}):(0,t.jsx)("p",{className:"p-6 text-sm text-muted-foreground/60",children:"Pick a file"})})]})})}function W({skill:e,path:a}){if(!e)return(0,t.jsx)("span",{className:"truncate font-mono text-[11px] text-muted-foreground/60",children:"Pick a skill"});let i=[e.name,...a.split("/").filter(Boolean)];return(0,t.jsx)("span",{className:"flex min-w-0 items-center gap-1 font-mono text-[11px] text-muted-foreground",children:i.map((e,a)=>(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1",children:[a>0&&(0,t.jsx)(l.ChevronRight,{className:"size-3 shrink-0 opacity-50"}),(0,t.jsx)("span",{className:(0,O.cn)("truncate",a===i.length-1&&"text-foreground"),children:e})]},`${a}-${e}`))})}function G({icon:e,label:a,active:i,hasChildren:s,onClick:r}){return(0,t.jsxs)("button",{type:"button",onClick:r,className:(0,O.cn)("mx-1 flex items-center gap-1.5 rounded-md px-2 py-1 text-left text-xs outline-none focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",i?"bg-secondary text-foreground":"text-muted-foreground hover:bg-muted/50 hover:text-foreground"),children:[(0,t.jsx)("span",{className:"shrink-0 text-muted-foreground/70 [&>svg]:size-3",children:e}),(0,t.jsx)("span",{className:"min-w-0 flex-1 truncate",children:a}),s&&(0,t.jsx)(l.ChevronRight,{className:"size-3 shrink-0 text-muted-foreground/50"})]})}function Y({source:e,dir:a,path:i,current:s,onPick:r}){let{data:n,isLoading:l,error:u}=(0,K.useServerRoute)(w.queryKey.skillNode(e,a,i));return u?(0,t.jsx)("p",{className:"p-3 font-mono text-xs text-destructive",children:u.message}):l||!n?(0,t.jsxs)("div",{className:"space-y-2 p-2",children:[(0,t.jsx)(M.Skeleton,{className:"h-5 w-full"}),(0,t.jsx)(M.Skeleton,{className:"h-5 w-4/5"})]}):"dir"!==n.kind?null:(0,t.jsxs)(t.Fragment,{children:[n.entries.map(e=>(0,t.jsx)(G,{icon:"dir"===e.kind?(0,t.jsx)(c.Folder,{}):e.name.endsWith(".md")?(0,t.jsx)(d.FileText,{}):(0,t.jsx)(o.File,{}),label:e.name,hasChildren:"dir"===e.kind,active:(i?`${i}/${e.name}`:e.name)===s,onClick:()=>r(e)},e.name)),0===n.entries.length&&(0,t.jsx)("p",{className:"p-3 text-xs text-muted-foreground/60",children:"Empty folder"})]})}function _({content:e}){let a=/^---\r?\n([\s\S]*?)\r?\n---[ \t]*\r?\n?/.exec(e),i=a?.[1].trim(),s=a?e.slice(a[0].length):e;return(0,t.jsxs)("div",{className:"min-w-0",children:[i&&(0,t.jsx)("pre",{className:"border-b border-border/60 bg-muted/20 px-5 py-3 font-mono text-[11px] leading-relaxed whitespace-pre-wrap text-muted-foreground",children:i}),(0,t.jsx)("div",{className:"px-5 py-4 text-sm leading-relaxed",children:(0,t.jsx)(z.Markdown,{children:s})})]})}function J({source:e,dir:a,path:i}){let{data:s,isLoading:r,error:n}=(0,K.useServerRoute)(w.queryKey.skillNode(e,a,i));if(n)return(0,t.jsx)("p",{className:"p-4 font-mono text-xs text-destructive",children:n.message});if(r||!s)return(0,t.jsxs)("div",{className:"space-y-3 p-5",children:[(0,t.jsx)(M.Skeleton,{className:"h-5 w-2/3"}),(0,t.jsx)(M.Skeleton,{className:"h-4 w-full"}),(0,t.jsx)(M.Skeleton,{className:"h-4 w-5/6"})]});if("file"!==s.kind)return null;let l=i.split("/").pop()??"";return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{className:"sticky top-0 z-20 flex items-center justify-between gap-2 border-b border-border/60 bg-background/90 px-5 py-2 font-mono text-[11px] text-muted-foreground backdrop-blur",children:[(0,t.jsx)("span",{className:"truncate",children:l}),(0,t.jsx)("span",{className:"shrink-0",children:(0,O.formatBytes)(s.size)})]}),null===s.content?(0,t.jsx)("p",{className:"px-5 py-4 text-sm text-muted-foreground/60",children:"Not a text file — the agent can still read it from disk."}):l.toLowerCase().endsWith(".md")?(0,t.jsx)(_,{content:s.content}):(0,t.jsx)("pre",{className:"overflow-x-auto px-5 py-4 font-mono text-[13px] leading-relaxed whitespace-pre text-foreground/90",children:s.content})]})}function Z(){return R.notify.component({className:"sm:max-w-lg",renderer:({close:e})=>(0,t.jsx)(Q,{onDone:e})})}function Q({onDone:e}){let[a,i]=(0,y.useState)("write"),[s,r]=(0,y.useState)(""),[n,l]=(0,y.useState)(""),[o,d]=(0,y.useState)(""),[c,u]=(0,y.useState)(null),[f,h]=(0,y.useState)(!1),m=(0,y.useRef)(null),x={errorMessage:!1,onOk:()=>{(0,K.revalidate)(w.queryKey.skills),e()}},[g,v,,b]=(0,q.useServerAction)(B,x),[k,z,,R]=(0,q.useServerAction)($,x),M=v||z,F="write"===a?b:R,E=!M&&("write"===a?s.trim()&&n.trim()&&o.trim():null!==c),P=async()=>{var e;!E||("write"===a?g({name:s.trim(),description:n.trim(),content:o}):c&&k({fileName:c.name,base64:await (e=c,new Promise((t,a)=>{let i=new FileReader;i.onload=()=>{let e=i.result;t(e.slice(e.indexOf(",")+1))},i.onerror=()=>a(i.error),i.readAsDataURL(e)}))}))},I=e=>{let t=e?.[0]??null;t&&u(t)};return(0,t.jsxs)(D.SettingDialogContent,{title:"New skill",description:"Instructions the agent loads by name when a task calls for them.",footer:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(N.Button,{variant:"ghost",onClick:e,children:"Cancel"}),(0,t.jsxs)(N.Button,{disabled:!E,loading:M,onClick:P,children:[!M&&("write"===a?(0,t.jsx)(p.Plus,{}):(0,t.jsx)(j,{})),"write"===a?"Create":"Upload"]})]}),children:[(0,t.jsxs)(L.Tabs,{value:a,onValueChange:e=>i(e),children:[(0,t.jsxs)(L.TabsList,{className:"w-full",children:[(0,t.jsx)(L.TabsTrigger,{value:"write",children:"Write"}),(0,t.jsx)(L.TabsTrigger,{value:"upload",children:"Upload"})]}),(0,t.jsxs)(L.TabsContent,{value:"write",className:"space-y-5 pt-4",children:[(0,t.jsxs)(S.Field,{children:[(0,t.jsx)(S.FieldLabel,{htmlFor:"skill-name",children:"Name"}),(0,t.jsxs)(S.FieldContent,{children:[(0,t.jsx)(C.Input,{id:"skill-name",value:s,onChange:e=>r(e.target.value),placeholder:"deploy-checklist",spellCheck:!1,autoFocus:!0}),(0,t.jsxs)("p",{className:"font-mono text-[11px] text-muted-foreground",children:[A.PATHS.skills.custom,"/",s.trim()||"…","/SKILL.md"]})]})]}),(0,t.jsxs)(S.Field,{children:[(0,t.jsx)(S.FieldLabel,{htmlFor:"skill-description",children:"Description"}),(0,t.jsx)(S.FieldContent,{children:(0,t.jsx)(C.Input,{id:"skill-description",value:n,onChange:e=>l(e.target.value),placeholder:"When to use it — this is how the agent decides to load it"})})]}),(0,t.jsxs)(S.Field,{children:[(0,t.jsx)(S.FieldLabel,{htmlFor:"skill-content",children:"Content"}),(0,t.jsx)(T.Textarea,{id:"skill-content",value:o,onChange:e=>d(e.target.value),placeholder:"Markdown. The steps, the rules, the examples.",className:"min-h-40 resize-none font-mono text-xs"})]})]}),(0,t.jsxs)(L.TabsContent,{value:"upload",className:"space-y-4 pt-4",children:[(0,t.jsxs)("button",{type:"button",onClick:()=>m.current?.click(),onDragOver:e=>{e.preventDefault(),h(!0)},onDragLeave:()=>h(!1),onDrop:e=>{e.preventDefault(),h(!1),I(e.dataTransfer.files)},className:(0,O.cn)("flex w-full flex-col items-center gap-2 rounded-xl border border-dashed px-6 py-10 text-center outline-none transition-colors focus-visible:ring-3 focus-visible:ring-ring/50",f?"border-foreground/60 bg-muted/60":"border-border hover:bg-muted/40"),children:[(0,t.jsx)(j,{className:"size-5 text-muted-foreground"}),c?(0,t.jsxs)("span",{className:"text-sm",children:[c.name,(0,t.jsx)("span",{className:"ml-2 font-mono text-[11px] text-muted-foreground",children:(0,O.formatBytes)(c.size)})]}):(0,t.jsx)("span",{className:"text-sm text-muted-foreground",children:"Drop a file here, or click to choose"})]}),(0,t.jsx)("input",{ref:m,type:"file",accept:".md,.zip,.skill",className:"hidden",onChange:e=>I(e.target.files)}),(0,t.jsxs)("div",{className:"space-y-1 text-xs text-muted-foreground",children:[(0,t.jsx)("p",{className:"font-medium text-foreground/80",children:"File requirements"}),(0,t.jsxs)("p",{children:["A ",(0,t.jsx)("span",{className:"font-mono",children:".md"})," file needs a YAML block with the skill's name and description."]}),(0,t.jsxs)("p",{children:["A ",(0,t.jsx)("span",{className:"font-mono",children:".zip"})," or"," ",(0,t.jsx)("span",{className:"font-mono",children:".skill"})," archive needs a SKILL.md inside — the rest of its folder comes along."]})]})]})]}),F&&(0,t.jsx)("p",{className:"font-mono text-xs text-destructive",children:F})]})}e.s(["SkillsSetting",0,function(){let[e,a]=(0,y.useState)(""),{data:i,isLoading:s,error:r}=(0,K.useServerRoute)(w.queryKey.skills),n=i??[];if(s)return(0,t.jsx)(D.SettingSkeleton,{rows:4});if(r)return(0,t.jsx)(D.SettingError,{message:r.message});let l=e.trim().toLowerCase(),o=n.filter(e=>!l||`${e.name} ${e.description}`.toLowerCase().includes(l)),d=n.filter(e=>!e.disabled).length;return(0,t.jsxs)(D.SettingScreen,{footer:(0,t.jsxs)(D.SettingRailNote,{children:[n.filter(e=>"default"===e.source).length," shipped · ",n.filter(e=>"custom"===e.source).length," ","installed"]}),children:[(0,t.jsx)(D.SettingToolbar,{count:`${d} on \xb7 ${n.length-d} off`,children:(0,t.jsx)(D.SettingFilter,{value:e,onChange:a,placeholder:"Filter skills"})}),(0,t.jsx)(D.SettingGroup,{label:"Custom",hint:"yours — added here · wins a name clash",children:(0,t.jsx)(D.SettingItems,{addRow:{label:"Add skill",onClick:Z},children:o.filter(e=>"custom"===e.source).map(e=>(0,t.jsx)(V,{skill:e},`custom/${e.dir}`))})}),(0,t.jsx)(D.SettingGroup,{label:"Default",hint:"ships with the app · switch off, can't edit or delete",children:(0,t.jsx)(D.SettingItems,{children:o.filter(e=>"default"===e.source).map(e=>(0,t.jsx)(V,{skill:e},`default/${e.dir}`))})}),d>A.PROMPT_CROWDED.skills&&(0,t.jsxs)(D.SettingNote,{children:[d," skills are on. Each is a line in every prompt a bot reads, and one more to look past when it picks."]})]})},"openSkillCreate",0,Z],833959)},31421,e=>{"use strict";var t=e.i(271645),a=e.i(146376),i=e.i(788015);e.s(["useAriaLabelledBy",0,function(e,s,r,n=!0,l){let[o,d]=t.useState(),c=(0,i.useBaseUiId)(l?`${l}-label`:void 0),u=e??s??o;return(0,a.useIsoLayoutEffect)(()=>{let t=e||s||!n?void 0:function(e,t){let a=function(e){if(!e)return;let t=e.parentElement;if(t&&"LABEL"===t.tagName)return t;let a=e.id;if(a){let t=e.nextElementSibling;if(t&&t.htmlFor===a)return t}let i=e.labels;return i&&i[0]}(e);if(a)return!a.id&&t&&(a.id=t),a.id||void 0}(r.current,c);o!==t&&d(t)}),u}])},924305,951849,133438,e=>{"use strict";e.s([],924305);var t=e.i(733332),a=e.i(271645);let i=a.createContext(void 0);e.s(["SwitchRootContext",0,i,"useSwitchRootContext",0,function(){let e=a.useContext(i);if(void 0===e)throw Error((0,t.default)(63));return e}],951849);let s={...e.i(875812).fieldValidityMapping,checked:e=>e?{"data-checked":""}:{"data-unchecked":""}};e.s(["stateAttributesMapping",0,s],133438)},726067,e=>{"use strict";var t=e.i(456420);let a={name:"folder",size:24,node:[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]};a.node;let i=(0,t.default)(a);e.s(["Folder",0,i],726067)},759659,e=>{"use strict";var t=e.i(456420);let a={name:"trash",size:24,node:[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],aliases:["trash-2"]};a.node;let i=(0,t.default)(a);e.s(["Trash2",0,i],759659)}]);
package/README.md CHANGED
@@ -4,7 +4,8 @@
4
4
 
5
5
  ### Everyone wanted Friday. This is Thursday.
6
6
 
7
- **An open-source voice agent that lives on your machine.** You talk. It works. You keep talking.
7
+ Talk to your computer. Thursday talks back while bots do the work.<br>
8
+ An open-source agent like [OpenClaw](https://github.com/openclaw/openclaw) and [Hermes](https://github.com/NousResearch/hermes-agent), built around your voice and running on your own machine.
8
9
 
9
10
  [![npm](https://img.shields.io/npm/v/thursday-agent?style=flat-square&color=111&label=npm)](https://www.npmjs.com/package/thursday-agent)
10
11
  [![CI](https://img.shields.io/github/actions/workflow/status/cgoinglove/thursday/ci.yml?style=flat-square&label=ci)](https://github.com/cgoinglove/thursday/actions/workflows/ci.yml)
@@ -15,174 +16,40 @@
15
16
 
16
17
  </div>
17
18
 
18
- !![video: 60-second demo, 1440×900, light theme, no browser chrome. One call, start to finish: say "Hey Thursday", ask "I'm going to Kyoto next week, find me a coat under $200 and put the options on one page", she answers "On it — Navigator went to look", keep talking about something else while the job line appears under the call, the page opens by itself, she says "It's back". Cut a 12-second GIF of that take (from "On it" to the page opening) for right here → `docs/images/demo.gif`; the full take goes to YouTube, linked underneath.]
19
+ ## Quick start
19
20
 
20
21
  ```bash
21
22
  npx thursday-agent
22
23
  ```
23
24
 
24
- One API key, typed into the first screen. Then say **"hey thursday."** No `.env`, no account, no cloud. That is the whole setup.
25
+ Paste an OpenAI API key, pick your starter bots, and say **“hey thursday.”**
25
26
 
26
- <br>
27
-
28
- ## Say this out loud
29
-
30
- > **"I'm going to Kyoto next week — find me a coat under $200 and put the options on one page."**
31
-
32
- She answers *"On it — Navigator went to look"* and **keeps talking to you.** A bot opens the shops in a real browser, reads the pages, builds the page. Two minutes later it opens on your screen.
33
-
34
- You never watched a spinner. You never stopped talking.
35
-
36
- <br>
37
-
38
- ## She has a face, and it is made of emoji
39
-
40
- <div align="center">
41
- <picture>
42
- <source media="(prefers-color-scheme: dark)" srcset="docs/images/face-dark.png">
43
- <img src="docs/images/face-light.png" alt="Thursday's face: an orb of emoji that swells when she speaks" width="280">
44
- </picture>
45
- </div>
46
-
47
- Hundreds of them, packed into one orb. When she talks, the rim swells with her voice and every syllable shakes a few loose — you can tell she is speaking with the sound off.
48
-
49
- Rather have letters, a sprinkle, or a plain mark with two eyes? Settings › Thursday.
27
+ ![The call keeps going while a bot does the work](docs/images/two-minds.png)
50
28
 
51
- <br>
52
-
53
- ## A harness you talk to
54
-
55
- A **harness** is the layer around a model that decides what it sees, which tools it may call, where its commands run, and what survives the session. Claude Code, [OpenClaw](https://github.com/openclaw/openclaw) and [Hermes](https://github.com/NousResearch/hermes-agent) are harnesses, and they got very good this year.
56
-
57
- **Every one of them is typed at.**
58
-
59
- Not because nobody thought of speech. Because speech breaks the one thing a harness does: run a long loop. A voice model that opens a browser goes quiet for ninety seconds — and a quiet call is a dead call. Nobody holds a phone through that.
60
-
61
- ![Why a voice agent needs two minds](docs/images/two-minds.png)
62
-
63
- So Thursday puts **two minds on one line.** A realtime speech model holds the conversation and may only touch what it can answer in a glance. Everything slower goes to a **bot** — a text model with your whole machine — that runs in the background and reports back in one sentence, out loud.
29
+ ## Features
64
30
 
65
- The conversation never stops, because the thing holding it never does the slow part.
31
+ - **Just talk.** A real-time voice call you can interrupt. Start one with “hey thursday” or a hotkey.
32
+ - **Bots do the slow work.** Anything that takes more than a few seconds goes to a bot in the background, and the conversation keeps going.
33
+ - **Your real computer.** Bots get a shell, your files, and a real browser — even the Chrome you are already signed into. It stops at a Pay button and leaves it to you.
34
+ - **Results you can open.** Pages, docs, charts, images, audio, and video, saved as files and opened on your screen.
35
+ - **Hang up, it keeps going.** Jobs run on your machine and Thursday tells you when they are done.
36
+ - **A team you build.** Make a bot with a name and one sentence. Bots pass work to each other and ask you when a decision is yours.
37
+ - **Memory you can read.** What Thursday knows about you is plain notes. Open, edit, or delete any line.
38
+ - **Skills and MCP.** Add Agent Skills and connect MCP servers.
39
+ - **Any model.** OpenAI, Anthropic, Google, xAI, Vercel AI Gateway, or your ChatGPT sign-in, with a different model per bot.
40
+ - **Local-first.** No Thursday account. The app, your data, and your keys stay on your computer.
66
41
 
67
- ### And the call can read a skill
42
+ ## Requirements
68
43
 
69
- A **skill** is a folder with a `SKILL.md` in it — a page of your instructions that a model opens only when it turns out to need them. It is how Claude Code, Codex and OpenClaw learn a house style without carrying it in every prompt.
44
+ - Node.js 22.18+
45
+ - An OpenAI API key for the voice
46
+ - macOS. Linux should work; Windows is not tested yet.
70
47
 
71
- Skills were built for agents you type at. Switch it on in Settings and **the voice model reads one mid-sentence** — so "book the usual place" stops being a sentence you have to finish. Bots have their own, always.
72
-
73
- As far as I can find, nothing else lets a realtime speech model do this. The traffic goes the other way: the skills written *about* voice are instructions for a coding agent building a voice app. If you know of one, open an issue and this paragraph changes.
48
+ > [!NOTE]
49
+ > Bots run real commands on your computer. Thursday is not a sandbox — read [SECURITY.md](SECURITY.md) before giving it access to anything sensitive.
74
50
 
75
51
  <details>
76
- <summary><b>Isn't this what LiveKit and the Realtime API examples do?</b></summary>
77
-
78
- The split is not new. OpenAI's own [realtime-agents](https://github.com/openai/openai-realtime-agents) demonstrates it as the "chat-supervisor" pattern, and [LiveKit Agents](https://github.com/livekit/agents) attaches MCP tools to a realtime session in a line.
79
-
80
- They are frameworks and demonstrations: excellent parts for building a voice agent. What they hand the supervisor is a tool list.
81
-
82
- Thursday hands it a machine — a shell, a real browser, skills, connectors, a workspace, and jobs that keep running after you hang up. It is a harness first, and speech is how you operate it. That is the whole difference, and it is the half that takes the work.
83
-
84
- </details>
85
-
86
- <br>
87
-
88
- ## What a bot actually has
89
-
90
- Not an API sandbox. **Your computer** — down to the Chrome you are already signed into, which no agent in someone else's cloud can borrow.
91
-
92
- - **A shell** — real commands on your real files
93
- - **A real browser** — its own, or attached to your Chrome. When there is something for you to see — a checkout, a map, a sign-in — it opens a window on your screen and leaves it there
94
- - **Skills** — the browser, this Mac, building a page; `npx skills add` for the rest
95
- - **46 connectors** — Notion, GitHub, Linear, Slack, Figma, Stripe, Supabase… one click each
96
- - **A studio** — image, video, speech, transcription
97
- - **Its own memory** — what it learned doing the job, kept as files you can open on its page
98
- - **Each other** — a bot hands a part of its job to the bot that exists for it
99
-
100
- ![A bot gets your shell, your skills and a real browser — and leaves the checkout for you](docs/images/machine.png)
101
-
102
- It signs in the way you would let it: a session it kept, your own Chrome, you in the window it opened, or the login you gave it — after asking. And there is one button it never presses: **pay.** It takes the order to the last screen, leaves it open in front of you, and tells you what it buys and for how much.
103
-
104
- <br>
105
-
106
- ## One sentence. Three bots. You typed none of it.
107
-
108
- ![The room they sorted it out in](docs/images/task-thread.png)
109
-
110
- Jarvis holds the job and decides neither half is his. Navigator opens six shops and reads them. Scribe builds the page out of what came back. It reaches you as one line, out loud — and the room is there to read if you ever want to know how.
111
-
112
- Those three come with her. Two more are ready-made in Settings — **Insta** draws the post, writes the caption and puts it up once you say so; **Voyage** plans the trip with a map for each day — and one of your own takes a name and a sentence.
113
-
114
- <br>
115
-
116
- ## Hang up. It keeps going.
117
-
118
- The job is not in the call. It runs on the server and the screen is a projection of it — so hang up mid-sentence, open a new tab, come back in ten minutes. She tells you what came in, or rings you, if you let her. The tab says it too: `(2) Thursday` means two things are waiting on you.
119
-
120
- ![The call ends at 0:12; the job runs to 2:41](docs/images/keeps-going.png)
121
-
122
- Close the app and it does the honest thing: ten seconds with no browser on it and every running job stops where it stands. **Nothing spends your keys while you are not looking.** Open it again and they pick themselves back up — the same after a restart, a `Ctrl+C`, or a model that went quiet for a minute.
123
-
124
- <br>
125
-
126
- ## It remembers you, and you can read it
127
-
128
- One fact per line, in the database on your disk. Open the Memory screen and read every one — where it came from, when it landed, whether it rides in every call — and delete any of them. Or type what changed, *"I moved to Busan"*, and watch the edit land.
129
-
130
- Every fact remembers the call it was said in, so when one line is not enough she can go back and read the conversation.
131
-
132
- <br>
133
-
134
- ## Local-first, and here it is not a slogan
135
-
136
- | | |
137
- |---|---|
138
- | **Your browser** | Bots drive a real browser on your machine — and can attach to the Chrome already open on your desk |
139
- | **Your machine** | Real commands on real files. Not a VM with a copy |
140
- | **Your keys** | A SQLite file on your disk, stripped from the shell a bot runs in |
141
- | **Your memory** | Facts in a database on your disk. Read, edit and delete them on the screen |
142
- | **No account** | Nothing to sign up for. The "server" is a Node process on `127.0.0.1` |
143
-
144
- **Honest caveat:** the *intelligence* is remote. There is no local realtime speech model worth putting a call on yet, so the audio goes to OpenAI or xAI. Everything else never leaves the machine. When a local voice model lands, this is the app that is ready for it.
145
-
146
- <br>
147
-
148
- ## Install
149
-
150
- ```bash
151
- npx thursday-agent
152
- ```
153
-
154
- Opens at `localhost:3000`, or the next free port if something already has it. One OpenAI or xAI key opens the call — a voice key is also a text key, so one is enough to run everything.
155
-
156
- ### Running it
157
-
158
- It runs in the terminal you started it in, like `n8n`. There is no daemon and nothing is installed into your login items.
159
-
160
- | | |
161
- |---|---|
162
- | **Stop it** | `Ctrl+C` — running jobs are parked and pick up at the next start |
163
- | **Start it again** | the same `npx thursday-agent` |
164
- | **Close the terminal** | it stops with the terminal — nothing is left running |
165
- | **Keep it up while you work** | run it in its own tab, or `npx thursday-agent &` |
166
- | **Another port** | `npx thursday-agent --port 4000` |
167
- | **Somewhere else on disk** | `npx thursday-agent --home ~/work/thursday` |
168
-
169
- **Your data outlives all of it.** Everything you say, everything the bots write, your keys and your memory live in `~/.thursday`, never inside the package — so restarting, rebooting, or upgrading to the next version keeps every call and every file. Deleting that folder is the uninstall.
170
-
171
- ```
172
- ~/.thursday
173
- ├── local.db calls, memory, bots, jobs, keys
174
- └── .ai-workspace
175
- ├── artifacts/ what the bots made for you
176
- ├── projects/ code they build
177
- ├── bots/ each bot's own memory and kept sign-ins
178
- ├── .agents/ skills you installed
179
- └── scratch/ one folder per job, cleared three days after it ends
180
- ```
181
-
182
- The first run also fetches the browser bots drive (~280 MB) in the background, once. That one lands in Playwright's own cache — `~/Library/Caches/ms-playwright`, or `~/.cache/ms-playwright` on Linux — so every run after it, and every upgrade, skips the download.
183
-
184
- <details>
185
- <summary><b>From source</b></summary>
52
+ <summary><b>Run from source</b></summary>
186
53
 
187
54
  ```bash
188
55
  git clone https://github.com/cgoinglove/thursday.git
@@ -191,72 +58,16 @@ pnpm install
191
58
  pnpm dev
192
59
  ```
193
60
 
194
- Node 22.18+ and pnpm 10+. The first run fetches the browser bots drive (~280 MB) in the background.
195
-
196
- </details>
197
-
198
- <details>
199
- <summary><b>Which models can I use?</b></summary>
200
-
201
- | | Providers |
202
- |---|---|
203
- | **Voice** (the call) | OpenAI Realtime · xAI Grok Voice |
204
- | **Text** (the bots) | OpenAI · Anthropic · Google · xAI · Vercel AI Gateway — every model it carries, live · your ChatGPT plan, by signing in |
205
- | **Studio** | OpenAI · Google · xAI · Vercel AI Gateway |
206
-
207
- Every bot can run on its own model. Give the errand-runner something cheap and the planner something good.
61
+ Requires pnpm 10+.
208
62
 
209
63
  </details>
210
64
 
211
- <details>
212
- <summary><b>Ten more things to try saying</b></summary>
213
-
214
- - "What did I download this week?" — one command, run while you talk
215
- - "Remember my sister's birthday is March 3rd." — saved the moment it lands
216
- - "Anything from my landlord in my email?" — read in the Chrome you are signed into
217
- - "Find the cheapest flight to Osaka on the 14th." — left at the pay button, on your screen
218
- - "Plan three days in Kyoto, with a map for each day." — Voyage
219
- - "Make a post about Friday's gig and put it on Instagram." — Insta, once you say so
220
- - "Write up what we decided today as a one-pager." — opens as a document, not a chat bubble
221
- - "Go through my card statements and list every subscription I am paying for."
222
- - "Watch this page and tell me when the price drops."
223
- - "Build me a page of thirty wedding pose photos."
224
-
225
- </details>
226
-
227
- <br>
228
-
229
- ## Where this is going
230
-
231
- **0.x** — this web app. More harness: better bots, more skills, a wider studio, and whatever the first people who actually talk to her ask for.
232
-
233
- **1.0** — a desktop app. The same server in a window, with the microphone and the machine one step closer.
234
-
235
- Tell me what you said to her and where it stopped. That is the roadmap.
236
-
237
- <br>
238
-
239
- ## The part where I am honest with you
240
-
241
- She is a language model with a shell, a browser and your API keys. **That is the product, not an accident.** Keys are stripped from the environment the shell runs in. The server is localhost-only. A login you gave a bot is asked about before it is used, and a payment is left for you to press — instructions a skill carries, not a lock the code holds.
242
-
243
- The shell is not fenced, and it is not meant to be — a bot that cannot look around cannot do the job, and a command writes wherever you can. That includes the database your keys sit in.
244
-
245
- It is not a sandbox and it does not pretend to be. → [SECURITY.md](SECURITY.md)
246
-
247
- Built on macOS. Linux should work; Windows is untested.
248
-
249
- <br>
250
-
251
- ---
252
-
253
65
  <div align="center">
254
66
 
255
- **If you have ever wanted to just talk to your computer while it worked — star it.**<br>
256
- That is how I know to keep going.
67
+ <br>
257
68
 
258
- [![Star History](https://api.star-history.com/svg?repos=cgoinglove/thursday&type=Date)](https://star-history.com/#cgoinglove/thursday&Date)
69
+ **[How it works](docs/how-it-works.md)** · [Contributing](CONTRIBUTING.md) · [Security](SECURITY.md) · [MIT](LICENSE)
259
70
 
260
- [How it works](docs/how-it-works.md) · [Contributing](CONTRIBUTING.md) · [Architecture](CLAUDE.md) · [MIT](LICENSE)
71
+ If you want an assistant you can talk to while it works, [star Thursday](https://github.com/cgoinglove/thursday).
261
72
 
262
73
  </div>
@@ -6,8 +6,8 @@
6
6
  export type AppEvent =
7
7
  /** Sent on connect. A changed `boot` means the server restarted; re-read everything. */
8
8
  | { type: "hello"; boot: string }
9
- /** Signal: a task changed (every write in bot.query). */
10
- | { type: "tasks" }
9
+ /** Signal: a thread changed (every write in thread.query and room.query). */
10
+ | { type: "threads" }
11
11
  /** Signal: a note or fact changed. */
12
12
  | { type: "memory" }
13
13
  /** Signal: a server was registered, removed, synced, or finished OAuth. */
@@ -15,7 +15,9 @@ export type AppEvent =
15
15
  /** Signal: a sign-in was written away from the settings screen (ai/chatgpt's sign-in answer). */
16
16
  | { type: "config" }
17
17
  /** Data: a finished job produced a document; `path` is workspace-relative. */
18
- | { type: "artifact"; taskId: string; label: string; path: string };
18
+ | { type: "artifact"; threadId: string; label: string; path: string }
19
+ /** Data: Thursday puts a job in front of the user (`thread` `open` on a call). */
20
+ | { type: "showThread"; threadId: string };
19
21
 
20
22
  /** Union members carrying nothing but `type`. */
21
23
  type Signal<E = AppEvent> = E extends AppEvent
@@ -29,7 +31,7 @@ type Signal<E = AppEvent> = E extends AppEvent
29
31
  * makes a signal missing here a compile error.
30
32
  */
31
33
  export const SIGNALS: Record<Signal, true> = {
32
- tasks: true,
34
+ threads: true,
33
35
  memory: true,
34
36
  mcp: true,
35
37
  config: true,
@@ -8,11 +8,15 @@ const encodePath = (path: string) =>
8
8
  path.split("/").map(encodeURIComponent).join("/");
9
9
 
10
10
  /**
11
- * Inverse of encodePath for catch-all segments. No decoding: Next already
11
+ * Inverse of encodePath for route-handler segments. No decoding: Next already
12
12
  * decodes segments, and decoding again throws on names containing `%`.
13
13
  */
14
14
  export const decodePath = (segments: string[]) => segments.join("/");
15
15
 
16
+ /** Next.js page params retain URL encoding; decode once, including literal percent signs. */
17
+ export const decodePagePath = (segments: string[]) =>
18
+ segments.map(decodeURIComponent).join("/");
19
+
16
20
  export const queryKey = {
17
21
  /** MemoryNote[] first page: pinned first, then by warmth */
18
22
  memory: "/api/memory",
@@ -49,7 +53,7 @@ export const queryKey = {
49
53
  }),
50
54
 
51
55
  /**
52
- * Bot[]. `tasks` and `taskHistory` sit under this prefix, so editing a bot
56
+ * Bot[]. `threads` and `threadHistory` sit under this prefix, so editing a bot
53
57
  * also revalidates the inbox and loaded history pages.
54
58
  */
55
59
  bot: "/api/bot",
@@ -63,23 +67,23 @@ export const queryKey = {
63
67
  }),
64
68
 
65
69
  /**
66
- * Inbox: Task[] newest first with threads, everything running or asking plus
67
- * the most recent finished few. Read by use-thursday only; the `tasks` signal
70
+ * Inbox: Thread[] newest first with their lines, everything running or asking plus
71
+ * the most recent finished few. Read by use-thursday only; the `threads` signal
68
72
  * triggers revalidation, with a 30s poll as fallback.
69
73
  */
70
- tasks: "/api/bot/task",
74
+ threads: "/api/bot/thread",
71
75
  /**
72
- * History page: Task[] newest first. `before` is the last page's final
76
+ * History page: Thread[] newest first. `before` is the last page's final
73
77
  * updatedAt (ISO), null for the first page.
74
78
  */
75
- taskHistory: (before: string | null) => ({
76
- url: "/api/bot/task",
79
+ threadHistory: (before: string | null) => ({
80
+ url: "/api/bot/thread",
77
81
  query: { history: 1, before },
78
82
  }),
79
83
  /** ResultPart[]: the full result of one tool call; lists carry only a few lines. */
80
- toolResult: (taskId: string | null, callId: string | null) => ({
81
- url: "/api/bot/task",
82
- pathVariable: [taskId],
84
+ toolResult: (threadId: string | null, callId: string | null) => ({
85
+ url: "/api/bot/thread",
86
+ pathVariable: [threadId],
83
87
  query: { call: callId },
84
88
  }),
85
89
  /**
@@ -91,20 +95,25 @@ export const queryKey = {
91
95
  url: "/api/workspace",
92
96
  query: { path: path || null, rows },
93
97
  }),
98
+ /** PathChips: which of the paths one message names have no file. Under `workspace`, so it refreshes with it. */
99
+ workspaceMissing: (paths: string[]) => ({
100
+ url: "/api/workspace/missing",
101
+ query: { paths: JSON.stringify(paths) },
102
+ }),
94
103
 
95
104
  /**
96
- * ArtifactShelf: the top of `artifacts/`, one row per artifact.
97
- * `artifactSet` opens one of those rows. The bare key is the menu, so
98
- * invalidating it refreshes an open set too.
105
+ * ArtifactShelf: every bot's folder in `artifacts/` and what is loose there,
106
+ * one row per artifact. `artifactSet` opens one of those rows by its path.
107
+ * The bare key is the menu, so invalidating it refreshes an open set too.
99
108
  */
100
109
  artifacts: "/api/artifact",
101
110
  artifactShelf: (rows: number) => ({
102
111
  url: "/api/artifact",
103
112
  query: { rows },
104
113
  }),
105
- artifactSet: (name: string, rows: number) => ({
114
+ artifactSet: (path: string, rows: number) => ({
106
115
  url: "/api/artifact",
107
- query: { set: name, rows },
116
+ query: { set: path, rows },
108
117
  }),
109
118
 
110
119
  /** Raw workspace file, no Result envelope; for iframe, img and fetch, not SWR. */
@@ -0,0 +1,37 @@
1
+ // What both starters do when the server exits because it could not migrate the
2
+ // database. Plain JavaScript and no app imports: `thursday` (bin/thursday.mjs)
3
+ // and `pnpm dev` (scripts/dev.mts) load it before anything is built.
4
+
5
+ import { rmSync } from "node:fs";
6
+ import { createInterface } from "node:readline/promises";
7
+
8
+ /**
9
+ * How boot exits when migrating fails (instrumentation-node.ts), so a starter
10
+ * can tell it from any other crash. Not 77: `next dev` restarts on that.
11
+ */
12
+ export const MIGRATION_FAILED_EXIT = 65;
13
+
14
+ /**
15
+ * Asks to remove the database the server could not migrate. The server has
16
+ * already printed why and exited, so nothing holds the file. True once it is
17
+ * gone and the server can start again on an empty one. With no terminal there
18
+ * is nobody to ask, and the server's message already names the files.
19
+ */
20
+ export async function askToRemoveDatabase(dbPath) {
21
+ if (!process.stdin.isTTY) return false;
22
+ const rl = createInterface({ input: process.stdin, output: process.stdout });
23
+ // Raw mode: Ctrl+C arrives here as a key, not as a signal
24
+ rl.on("SIGINT", () => {
25
+ console.log();
26
+ process.exit(130);
27
+ });
28
+ const answer = await rl.question(" Remove it and start over? [y/N] ");
29
+ rl.close();
30
+ if (!/^y/i.test(answer.trim())) return false;
31
+ // WAL mode keeps two sidecars next to the file.
32
+ for (const file of [dbPath, `${dbPath}-wal`, `${dbPath}-shm`]) {
33
+ rmSync(file, { force: true });
34
+ }
35
+ console.log(" Removed. Starting again.\n");
36
+ return true;
37
+ }