@chorus-aidlc/chorus 0.17.0 → 0.17.2

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 (481) hide show
  1. package/.next/standalone/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/app-build-manifest.json +519 -519
  3. package/.next/standalone/.next/app-path-routes-manifest.json +44 -44
  4. package/.next/standalone/.next/build-manifest.json +6 -6
  5. package/.next/standalone/.next/prerender-manifest.json +45 -45
  6. package/.next/standalone/.next/react-loadable-manifest.json +1 -1
  7. package/.next/standalone/.next/required-server-files.json +4 -4
  8. package/.next/standalone/.next/server/app/(dashboard)/project-groups/[uuid]/page.js +2 -2
  9. package/.next/standalone/.next/server/app/(dashboard)/project-groups/[uuid]/page.js.nft.json +1 -1
  10. package/.next/standalone/.next/server/app/(dashboard)/project-groups/[uuid]/page_client-reference-manifest.js +1 -1
  11. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/activity/page.js +2 -2
  12. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/activity/page.js.nft.json +1 -1
  13. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/activity/page_client-reference-manifest.js +1 -1
  14. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/[ideaUuid]/page.js +2 -2
  15. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/[ideaUuid]/page.js.nft.json +1 -1
  16. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/[ideaUuid]/page_client-reference-manifest.js +1 -1
  17. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/page.js +2 -2
  18. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/page.js.nft.json +1 -1
  19. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/dashboard/page_client-reference-manifest.js +1 -1
  20. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page.js +2 -2
  21. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page.js.nft.json +1 -1
  22. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page_client-reference-manifest.js +1 -1
  23. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/page.js +2 -2
  24. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/page.js.nft.json +1 -1
  25. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/documents/page_client-reference-manifest.js +1 -1
  26. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/graph/page.js +2 -2
  27. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/graph/page.js.nft.json +1 -1
  28. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/graph/page_client-reference-manifest.js +1 -1
  29. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page.js +2 -2
  30. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page.js.nft.json +1 -1
  31. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page_client-reference-manifest.js +1 -1
  32. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/new/page.js +2 -2
  33. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/new/page.js.nft.json +1 -1
  34. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/new/page_client-reference-manifest.js +1 -1
  35. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/page.js +2 -2
  36. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/page.js.nft.json +1 -1
  37. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/proposals/page_client-reference-manifest.js +1 -1
  38. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/page.js +2 -2
  39. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/page.js.nft.json +1 -1
  40. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/page_client-reference-manifest.js +1 -1
  41. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/page.js +2 -2
  42. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/page.js.nft.json +1 -1
  43. package/.next/standalone/.next/server/app/(dashboard)/projects/[uuid]/tasks/page_client-reference-manifest.js +1 -1
  44. package/.next/standalone/.next/server/app/(dashboard)/projects/page.js +3 -3
  45. package/.next/standalone/.next/server/app/(dashboard)/projects/page.js.nft.json +1 -1
  46. package/.next/standalone/.next/server/app/(dashboard)/projects/page_client-reference-manifest.js +1 -1
  47. package/.next/standalone/.next/server/app/(dashboard)/settings/page.js +2 -2
  48. package/.next/standalone/.next/server/app/(dashboard)/settings/page.js.nft.json +1 -1
  49. package/.next/standalone/.next/server/app/(dashboard)/settings/page_client-reference-manifest.js +1 -1
  50. package/.next/standalone/.next/server/app/_not-found/page.js +2 -2
  51. package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  52. package/.next/standalone/.next/server/app/_not-found.html +2 -2
  53. package/.next/standalone/.next/server/app/_not-found.rsc +5 -5
  54. package/.next/standalone/.next/server/app/admin/companies/[uuid]/page.js +2 -2
  55. package/.next/standalone/.next/server/app/admin/companies/[uuid]/page.js.nft.json +1 -1
  56. package/.next/standalone/.next/server/app/admin/companies/[uuid]/page_client-reference-manifest.js +1 -1
  57. package/.next/standalone/.next/server/app/admin/companies/new/page.js +2 -2
  58. package/.next/standalone/.next/server/app/admin/companies/new/page.js.nft.json +1 -1
  59. package/.next/standalone/.next/server/app/admin/companies/new/page_client-reference-manifest.js +1 -1
  60. package/.next/standalone/.next/server/app/admin/companies/new.html +2 -2
  61. package/.next/standalone/.next/server/app/admin/companies/new.rsc +7 -7
  62. package/.next/standalone/.next/server/app/admin/companies/page.js +2 -2
  63. package/.next/standalone/.next/server/app/admin/companies/page.js.nft.json +1 -1
  64. package/.next/standalone/.next/server/app/admin/companies/page_client-reference-manifest.js +1 -1
  65. package/.next/standalone/.next/server/app/admin/companies.html +2 -2
  66. package/.next/standalone/.next/server/app/admin/companies.rsc +7 -7
  67. package/.next/standalone/.next/server/app/admin/page.js +2 -2
  68. package/.next/standalone/.next/server/app/admin/page.js.nft.json +1 -1
  69. package/.next/standalone/.next/server/app/admin/page_client-reference-manifest.js +1 -1
  70. package/.next/standalone/.next/server/app/admin.html +2 -2
  71. package/.next/standalone/.next/server/app/admin.rsc +7 -7
  72. package/.next/standalone/.next/server/app/api/admin/companies/[uuid]/route.js +1 -1
  73. package/.next/standalone/.next/server/app/api/admin/companies/[uuid]/route_client-reference-manifest.js +1 -1
  74. package/.next/standalone/.next/server/app/api/admin/companies/route.js +1 -1
  75. package/.next/standalone/.next/server/app/api/admin/companies/route_client-reference-manifest.js +1 -1
  76. package/.next/standalone/.next/server/app/api/admin/login/route.js +1 -1
  77. package/.next/standalone/.next/server/app/api/admin/login/route_client-reference-manifest.js +1 -1
  78. package/.next/standalone/.next/server/app/api/admin/session/route.js +1 -1
  79. package/.next/standalone/.next/server/app/api/admin/session/route_client-reference-manifest.js +1 -1
  80. package/.next/standalone/.next/server/app/api/agent-connections/route.js +1 -1
  81. package/.next/standalone/.next/server/app/api/agent-connections/route_client-reference-manifest.js +1 -1
  82. package/.next/standalone/.next/server/app/api/agents/[uuid]/route.js +1 -1
  83. package/.next/standalone/.next/server/app/api/agents/[uuid]/route_client-reference-manifest.js +1 -1
  84. package/.next/standalone/.next/server/app/api/agents/[uuid]/sessions/route.js +1 -1
  85. package/.next/standalone/.next/server/app/api/agents/[uuid]/sessions/route_client-reference-manifest.js +1 -1
  86. package/.next/standalone/.next/server/app/api/agents/route.js +1 -1
  87. package/.next/standalone/.next/server/app/api/agents/route_client-reference-manifest.js +1 -1
  88. package/.next/standalone/.next/server/app/api/api-keys/[uuid]/route.js +1 -1
  89. package/.next/standalone/.next/server/app/api/api-keys/[uuid]/route_client-reference-manifest.js +1 -1
  90. package/.next/standalone/.next/server/app/api/api-keys/route.js +1 -1
  91. package/.next/standalone/.next/server/app/api/api-keys/route_client-reference-manifest.js +1 -1
  92. package/.next/standalone/.next/server/app/api/auth/callback/route.js +1 -1
  93. package/.next/standalone/.next/server/app/api/auth/callback/route_client-reference-manifest.js +1 -1
  94. package/.next/standalone/.next/server/app/api/auth/check-default/route.js +1 -1
  95. package/.next/standalone/.next/server/app/api/auth/check-default/route_client-reference-manifest.js +1 -1
  96. package/.next/standalone/.next/server/app/api/auth/company-oidc/route.js +1 -1
  97. package/.next/standalone/.next/server/app/api/auth/company-oidc/route_client-reference-manifest.js +1 -1
  98. package/.next/standalone/.next/server/app/api/auth/default-login/route.js +1 -1
  99. package/.next/standalone/.next/server/app/api/auth/default-login/route_client-reference-manifest.js +1 -1
  100. package/.next/standalone/.next/server/app/api/auth/identify/route.js +1 -1
  101. package/.next/standalone/.next/server/app/api/auth/identify/route_client-reference-manifest.js +1 -1
  102. package/.next/standalone/.next/server/app/api/auth/logout/route.js +1 -1
  103. package/.next/standalone/.next/server/app/api/auth/logout/route_client-reference-manifest.js +1 -1
  104. package/.next/standalone/.next/server/app/api/auth/me/route.js +1 -1
  105. package/.next/standalone/.next/server/app/api/auth/me/route_client-reference-manifest.js +1 -1
  106. package/.next/standalone/.next/server/app/api/auth/sync-token/route.js +1 -1
  107. package/.next/standalone/.next/server/app/api/auth/sync-token/route_client-reference-manifest.js +1 -1
  108. package/.next/standalone/.next/server/app/api/comments/route.js +1 -1
  109. package/.next/standalone/.next/server/app/api/comments/route_client-reference-manifest.js +1 -1
  110. package/.next/standalone/.next/server/app/api/daemon/connection-heartbeat/route.js +1 -1
  111. package/.next/standalone/.next/server/app/api/daemon/connection-heartbeat/route_client-reference-manifest.js +1 -1
  112. package/.next/standalone/.next/server/app/api/daemon/control/route.js +1 -1
  113. package/.next/standalone/.next/server/app/api/daemon/control/route_client-reference-manifest.js +1 -1
  114. package/.next/standalone/.next/server/app/api/daemon/directory-request/report/route.js +1 -1
  115. package/.next/standalone/.next/server/app/api/daemon/directory-request/report/route_client-reference-manifest.js +1 -1
  116. package/.next/standalone/.next/server/app/api/daemon/execution-state/route.js +1 -1
  117. package/.next/standalone/.next/server/app/api/daemon/execution-state/route_client-reference-manifest.js +1 -1
  118. package/.next/standalone/.next/server/app/api/daemon/executions/route.js +1 -1
  119. package/.next/standalone/.next/server/app/api/daemon/executions/route_client-reference-manifest.js +1 -1
  120. package/.next/standalone/.next/server/app/api/daemon/pending-turns/route.js +1 -1
  121. package/.next/standalone/.next/server/app/api/daemon/pending-turns/route_client-reference-manifest.js +1 -1
  122. package/.next/standalone/.next/server/app/api/daemon/report-interrupt/route.js +1 -1
  123. package/.next/standalone/.next/server/app/api/daemon/report-interrupt/route_client-reference-manifest.js +1 -1
  124. package/.next/standalone/.next/server/app/api/daemon/resume/route.js +1 -1
  125. package/.next/standalone/.next/server/app/api/daemon/resume/route_client-reference-manifest.js +1 -1
  126. package/.next/standalone/.next/server/app/api/daemon/transcript/route.js +1 -1
  127. package/.next/standalone/.next/server/app/api/daemon/transcript/route_client-reference-manifest.js +1 -1
  128. package/.next/standalone/.next/server/app/api/daemon/turn-advance/route.js +1 -1
  129. package/.next/standalone/.next/server/app/api/daemon/turn-advance/route_client-reference-manifest.js +1 -1
  130. package/.next/standalone/.next/server/app/api/daemon-directory-requests/[uuid]/route.js +1 -1
  131. package/.next/standalone/.next/server/app/api/daemon-directory-requests/[uuid]/route_client-reference-manifest.js +1 -1
  132. package/.next/standalone/.next/server/app/api/daemon-directory-requests/route.js +1 -1
  133. package/.next/standalone/.next/server/app/api/daemon-directory-requests/route_client-reference-manifest.js +1 -1
  134. package/.next/standalone/.next/server/app/api/daemon-sessions/[sessionUuid]/instruction/route.js +1 -1
  135. package/.next/standalone/.next/server/app/api/daemon-sessions/[sessionUuid]/instruction/route_client-reference-manifest.js +1 -1
  136. package/.next/standalone/.next/server/app/api/daemon-sessions/[sessionUuid]/repoint/route.js +1 -1
  137. package/.next/standalone/.next/server/app/api/daemon-sessions/[sessionUuid]/repoint/route_client-reference-manifest.js +1 -1
  138. package/.next/standalone/.next/server/app/api/daemon-sessions/[sessionUuid]/route.js +1 -1
  139. package/.next/standalone/.next/server/app/api/daemon-sessions/[sessionUuid]/route_client-reference-manifest.js +1 -1
  140. package/.next/standalone/.next/server/app/api/daemon-sessions/ad-hoc/route.js +1 -1
  141. package/.next/standalone/.next/server/app/api/daemon-sessions/ad-hoc/route_client-reference-manifest.js +1 -1
  142. package/.next/standalone/.next/server/app/api/daemon-sessions/route.js +1 -1
  143. package/.next/standalone/.next/server/app/api/daemon-sessions/route_client-reference-manifest.js +1 -1
  144. package/.next/standalone/.next/server/app/api/documents/[uuid]/route.js +1 -1
  145. package/.next/standalone/.next/server/app/api/documents/[uuid]/route_client-reference-manifest.js +1 -1
  146. package/.next/standalone/.next/server/app/api/entities/[type]/[uuid]/root-idea/route.js +1 -1
  147. package/.next/standalone/.next/server/app/api/entities/[type]/[uuid]/root-idea/route_client-reference-manifest.js +1 -1
  148. package/.next/standalone/.next/server/app/api/events/notifications/route.js +1 -1
  149. package/.next/standalone/.next/server/app/api/events/notifications/route_client-reference-manifest.js +1 -1
  150. package/.next/standalone/.next/server/app/api/events/route.js +14 -6
  151. package/.next/standalone/.next/server/app/api/events/route_client-reference-manifest.js +1 -1
  152. package/.next/standalone/.next/server/app/api/health/route.js +1 -1
  153. package/.next/standalone/.next/server/app/api/health/route_client-reference-manifest.js +1 -1
  154. package/.next/standalone/.next/server/app/api/ideas/[uuid]/claim/route.js +1 -1
  155. package/.next/standalone/.next/server/app/api/ideas/[uuid]/claim/route_client-reference-manifest.js +1 -1
  156. package/.next/standalone/.next/server/app/api/ideas/[uuid]/move/preview/route.js +1 -1
  157. package/.next/standalone/.next/server/app/api/ideas/[uuid]/move/preview/route_client-reference-manifest.js +1 -1
  158. package/.next/standalone/.next/server/app/api/ideas/[uuid]/move/route.js +1 -1
  159. package/.next/standalone/.next/server/app/api/ideas/[uuid]/move/route_client-reference-manifest.js +1 -1
  160. package/.next/standalone/.next/server/app/api/ideas/[uuid]/parent/route.js +1 -1
  161. package/.next/standalone/.next/server/app/api/ideas/[uuid]/parent/route_client-reference-manifest.js +1 -1
  162. package/.next/standalone/.next/server/app/api/ideas/[uuid]/release/route.js +1 -1
  163. package/.next/standalone/.next/server/app/api/ideas/[uuid]/release/route_client-reference-manifest.js +1 -1
  164. package/.next/standalone/.next/server/app/api/ideas/[uuid]/route.js +1 -1
  165. package/.next/standalone/.next/server/app/api/ideas/[uuid]/route_client-reference-manifest.js +1 -1
  166. package/.next/standalone/.next/server/app/api/ideas/[uuid]/wake-preview/route.js +1 -1
  167. package/.next/standalone/.next/server/app/api/ideas/[uuid]/wake-preview/route_client-reference-manifest.js +1 -1
  168. package/.next/standalone/.next/server/app/api/ideas/conversational/route.js +1 -1
  169. package/.next/standalone/.next/server/app/api/ideas/conversational/route_client-reference-manifest.js +1 -1
  170. package/.next/standalone/.next/server/app/api/mcp/route.js +4 -4
  171. package/.next/standalone/.next/server/app/api/mcp/route_client-reference-manifest.js +1 -1
  172. package/.next/standalone/.next/server/app/api/me/assignments/route.js +1 -1
  173. package/.next/standalone/.next/server/app/api/me/assignments/route_client-reference-manifest.js +1 -1
  174. package/.next/standalone/.next/server/app/api/mentionables/route.js +1 -1
  175. package/.next/standalone/.next/server/app/api/mentionables/route_client-reference-manifest.js +1 -1
  176. package/.next/standalone/.next/server/app/api/notifications/[uuid]/archive/route.js +1 -1
  177. package/.next/standalone/.next/server/app/api/notifications/[uuid]/archive/route_client-reference-manifest.js +1 -1
  178. package/.next/standalone/.next/server/app/api/notifications/[uuid]/read/route.js +1 -1
  179. package/.next/standalone/.next/server/app/api/notifications/[uuid]/read/route_client-reference-manifest.js +1 -1
  180. package/.next/standalone/.next/server/app/api/notifications/preferences/route.js +1 -1
  181. package/.next/standalone/.next/server/app/api/notifications/preferences/route_client-reference-manifest.js +1 -1
  182. package/.next/standalone/.next/server/app/api/notifications/read-all/route.js +1 -1
  183. package/.next/standalone/.next/server/app/api/notifications/read-all/route_client-reference-manifest.js +1 -1
  184. package/.next/standalone/.next/server/app/api/notifications/route.js +1 -1
  185. package/.next/standalone/.next/server/app/api/notifications/route_client-reference-manifest.js +1 -1
  186. package/.next/standalone/.next/server/app/api/notifications/unread-count/route.js +1 -1
  187. package/.next/standalone/.next/server/app/api/notifications/unread-count/route_client-reference-manifest.js +1 -1
  188. package/.next/standalone/.next/server/app/api/project-groups/[uuid]/dashboard/route.js +1 -1
  189. package/.next/standalone/.next/server/app/api/project-groups/[uuid]/dashboard/route_client-reference-manifest.js +1 -1
  190. package/.next/standalone/.next/server/app/api/project-groups/[uuid]/route.js +1 -1
  191. package/.next/standalone/.next/server/app/api/project-groups/[uuid]/route_client-reference-manifest.js +1 -1
  192. package/.next/standalone/.next/server/app/api/project-groups/route.js +1 -1
  193. package/.next/standalone/.next/server/app/api/project-groups/route_client-reference-manifest.js +1 -1
  194. package/.next/standalone/.next/server/app/api/project-visits/pin/route.js +1 -1
  195. package/.next/standalone/.next/server/app/api/project-visits/pin/route_client-reference-manifest.js +1 -1
  196. package/.next/standalone/.next/server/app/api/project-visits/route.js +1 -1
  197. package/.next/standalone/.next/server/app/api/project-visits/route_client-reference-manifest.js +1 -1
  198. package/.next/standalone/.next/server/app/api/project-visits/visit/route.js +1 -1
  199. package/.next/standalone/.next/server/app/api/project-visits/visit/route_client-reference-manifest.js +1 -1
  200. package/.next/standalone/.next/server/app/api/projects/[uuid]/activity/route.js +1 -1
  201. package/.next/standalone/.next/server/app/api/projects/[uuid]/activity/route_client-reference-manifest.js +1 -1
  202. package/.next/standalone/.next/server/app/api/projects/[uuid]/agent-cwds/route.js +1 -1
  203. package/.next/standalone/.next/server/app/api/projects/[uuid]/agent-cwds/route_client-reference-manifest.js +1 -1
  204. package/.next/standalone/.next/server/app/api/projects/[uuid]/available/route.js +1 -1
  205. package/.next/standalone/.next/server/app/api/projects/[uuid]/available/route_client-reference-manifest.js +1 -1
  206. package/.next/standalone/.next/server/app/api/projects/[uuid]/documents/route.js +1 -1
  207. package/.next/standalone/.next/server/app/api/projects/[uuid]/documents/route_client-reference-manifest.js +1 -1
  208. package/.next/standalone/.next/server/app/api/projects/[uuid]/group/route.js +1 -1
  209. package/.next/standalone/.next/server/app/api/projects/[uuid]/group/route_client-reference-manifest.js +1 -1
  210. package/.next/standalone/.next/server/app/api/projects/[uuid]/ideas/route.js +1 -1
  211. package/.next/standalone/.next/server/app/api/projects/[uuid]/ideas/route_client-reference-manifest.js +1 -1
  212. package/.next/standalone/.next/server/app/api/projects/[uuid]/ideas/tracker/route.js +1 -1
  213. package/.next/standalone/.next/server/app/api/projects/[uuid]/ideas/tracker/route_client-reference-manifest.js +1 -1
  214. package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/[proposalUuid]/validate/route.js +1 -1
  215. package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/[proposalUuid]/validate/route_client-reference-manifest.js +1 -1
  216. package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/route.js +1 -1
  217. package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/route_client-reference-manifest.js +1 -1
  218. package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/summary/route.js +1 -1
  219. package/.next/standalone/.next/server/app/api/projects/[uuid]/proposals/summary/route_client-reference-manifest.js +1 -1
  220. package/.next/standalone/.next/server/app/api/projects/[uuid]/resource-graph/route.js +1 -1
  221. package/.next/standalone/.next/server/app/api/projects/[uuid]/resource-graph/route_client-reference-manifest.js +1 -1
  222. package/.next/standalone/.next/server/app/api/projects/[uuid]/route.js +1 -1
  223. package/.next/standalone/.next/server/app/api/projects/[uuid]/route_client-reference-manifest.js +1 -1
  224. package/.next/standalone/.next/server/app/api/projects/[uuid]/stats/route.js +1 -1
  225. package/.next/standalone/.next/server/app/api/projects/[uuid]/stats/route_client-reference-manifest.js +1 -1
  226. package/.next/standalone/.next/server/app/api/projects/[uuid]/tasks/dependencies/route.js +1 -1
  227. package/.next/standalone/.next/server/app/api/projects/[uuid]/tasks/dependencies/route_client-reference-manifest.js +1 -1
  228. package/.next/standalone/.next/server/app/api/projects/[uuid]/tasks/route.js +1 -1
  229. package/.next/standalone/.next/server/app/api/projects/[uuid]/tasks/route_client-reference-manifest.js +1 -1
  230. package/.next/standalone/.next/server/app/api/projects/agent-cwd-options/route.js +1 -1
  231. package/.next/standalone/.next/server/app/api/projects/agent-cwd-options/route_client-reference-manifest.js +1 -1
  232. package/.next/standalone/.next/server/app/api/projects/route.js +1 -1
  233. package/.next/standalone/.next/server/app/api/projects/route_client-reference-manifest.js +1 -1
  234. package/.next/standalone/.next/server/app/api/proposals/[uuid]/approve/route.js +1 -1
  235. package/.next/standalone/.next/server/app/api/proposals/[uuid]/approve/route_client-reference-manifest.js +1 -1
  236. package/.next/standalone/.next/server/app/api/proposals/[uuid]/close/route.js +1 -1
  237. package/.next/standalone/.next/server/app/api/proposals/[uuid]/close/route_client-reference-manifest.js +1 -1
  238. package/.next/standalone/.next/server/app/api/proposals/[uuid]/reject/route.js +1 -1
  239. package/.next/standalone/.next/server/app/api/proposals/[uuid]/reject/route_client-reference-manifest.js +1 -1
  240. package/.next/standalone/.next/server/app/api/proposals/[uuid]/revoke/route.js +1 -1
  241. package/.next/standalone/.next/server/app/api/proposals/[uuid]/revoke/route_client-reference-manifest.js +1 -1
  242. package/.next/standalone/.next/server/app/api/proposals/[uuid]/route.js +1 -1
  243. package/.next/standalone/.next/server/app/api/proposals/[uuid]/route_client-reference-manifest.js +1 -1
  244. package/.next/standalone/.next/server/app/api/references/[uuid]/route.js +1 -1
  245. package/.next/standalone/.next/server/app/api/references/[uuid]/route_client-reference-manifest.js +1 -1
  246. package/.next/standalone/.next/server/app/api/references/route.js +1 -1
  247. package/.next/standalone/.next/server/app/api/references/route_client-reference-manifest.js +1 -1
  248. package/.next/standalone/.next/server/app/api/search/route.js +1 -1
  249. package/.next/standalone/.next/server/app/api/search/route_client-reference-manifest.js +1 -1
  250. package/.next/standalone/.next/server/app/api/session/route.js +1 -1
  251. package/.next/standalone/.next/server/app/api/session/route_client-reference-manifest.js +1 -1
  252. package/.next/standalone/.next/server/app/api/sessions/[uuid]/route.js +1 -1
  253. package/.next/standalone/.next/server/app/api/sessions/[uuid]/route_client-reference-manifest.js +1 -1
  254. package/.next/standalone/.next/server/app/api/tasks/[uuid]/claim/route.js +1 -1
  255. package/.next/standalone/.next/server/app/api/tasks/[uuid]/claim/route_client-reference-manifest.js +1 -1
  256. package/.next/standalone/.next/server/app/api/tasks/[uuid]/dependencies/[dependsOnUuid]/route.js +1 -1
  257. package/.next/standalone/.next/server/app/api/tasks/[uuid]/dependencies/[dependsOnUuid]/route_client-reference-manifest.js +1 -1
  258. package/.next/standalone/.next/server/app/api/tasks/[uuid]/dependencies/route.js +1 -1
  259. package/.next/standalone/.next/server/app/api/tasks/[uuid]/dependencies/route_client-reference-manifest.js +1 -1
  260. package/.next/standalone/.next/server/app/api/tasks/[uuid]/release/route.js +1 -1
  261. package/.next/standalone/.next/server/app/api/tasks/[uuid]/release/route_client-reference-manifest.js +1 -1
  262. package/.next/standalone/.next/server/app/api/tasks/[uuid]/route.js +1 -1
  263. package/.next/standalone/.next/server/app/api/tasks/[uuid]/route_client-reference-manifest.js +1 -1
  264. package/.next/standalone/.next/server/app/api/tasks/[uuid]/sessions/route.js +1 -1
  265. package/.next/standalone/.next/server/app/api/tasks/[uuid]/sessions/route_client-reference-manifest.js +1 -1
  266. package/.next/standalone/.next/server/app/favicon.ico/route.js +1 -1
  267. package/.next/standalone/.next/server/app/index.html +2 -2
  268. package/.next/standalone/.next/server/app/index.rsc +6 -6
  269. package/.next/standalone/.next/server/app/login/admin/page.js +2 -2
  270. package/.next/standalone/.next/server/app/login/admin/page.js.nft.json +1 -1
  271. package/.next/standalone/.next/server/app/login/admin/page_client-reference-manifest.js +1 -1
  272. package/.next/standalone/.next/server/app/login/admin.html +2 -2
  273. package/.next/standalone/.next/server/app/login/admin.rsc +6 -6
  274. package/.next/standalone/.next/server/app/login/callback/page.js +2 -2
  275. package/.next/standalone/.next/server/app/login/callback/page.js.nft.json +1 -1
  276. package/.next/standalone/.next/server/app/login/callback/page_client-reference-manifest.js +1 -1
  277. package/.next/standalone/.next/server/app/login/callback.html +2 -2
  278. package/.next/standalone/.next/server/app/login/callback.rsc +6 -6
  279. package/.next/standalone/.next/server/app/login/page.js +2 -2
  280. package/.next/standalone/.next/server/app/login/page.js.nft.json +1 -1
  281. package/.next/standalone/.next/server/app/login/page_client-reference-manifest.js +1 -1
  282. package/.next/standalone/.next/server/app/login/pick-workspace/page.js +2 -2
  283. package/.next/standalone/.next/server/app/login/pick-workspace/page.js.nft.json +1 -1
  284. package/.next/standalone/.next/server/app/login/pick-workspace/page_client-reference-manifest.js +1 -1
  285. package/.next/standalone/.next/server/app/login/pick-workspace.html +2 -2
  286. package/.next/standalone/.next/server/app/login/pick-workspace.rsc +6 -6
  287. package/.next/standalone/.next/server/app/login.html +2 -2
  288. package/.next/standalone/.next/server/app/login.rsc +6 -6
  289. package/.next/standalone/.next/server/app/onboarding/page.js +2 -2
  290. package/.next/standalone/.next/server/app/onboarding/page.js.nft.json +1 -1
  291. package/.next/standalone/.next/server/app/onboarding/page_client-reference-manifest.js +1 -1
  292. package/.next/standalone/.next/server/app/onboarding.html +2 -2
  293. package/.next/standalone/.next/server/app/onboarding.rsc +6 -6
  294. package/.next/standalone/.next/server/app/page.js +2 -2
  295. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  296. package/.next/standalone/.next/server/app/projects.html +2 -2
  297. package/.next/standalone/.next/server/app/projects.rsc +7 -7
  298. package/.next/standalone/.next/server/app/settings.html +2 -2
  299. package/.next/standalone/.next/server/app/settings.rsc +7 -7
  300. package/.next/standalone/.next/server/app-paths-manifest.json +44 -44
  301. package/.next/standalone/.next/server/chunks/1114.js +1 -1
  302. package/.next/standalone/.next/server/chunks/1267.js +1 -0
  303. package/.next/standalone/.next/server/chunks/1318.js +1 -1
  304. package/.next/standalone/.next/server/chunks/1559.js +2 -2
  305. package/.next/standalone/.next/server/chunks/{3831.js → 2536.js} +6 -4
  306. package/.next/standalone/.next/server/chunks/2570.js +2 -2
  307. package/.next/standalone/.next/server/chunks/2572.js +1 -1
  308. package/.next/standalone/.next/server/chunks/2940.js +1 -1
  309. package/.next/standalone/.next/server/chunks/2953.js +1 -0
  310. package/.next/standalone/.next/server/chunks/2961.js +1 -1
  311. package/.next/standalone/.next/server/chunks/3197.js +1 -1
  312. package/.next/standalone/.next/server/chunks/378.js +4 -4
  313. package/.next/standalone/.next/server/chunks/4827.js +1 -1
  314. package/.next/standalone/.next/server/chunks/5162.js +1 -0
  315. package/.next/standalone/.next/server/chunks/5245.js +1 -1
  316. package/.next/standalone/.next/server/chunks/{5706.js → 6080.js} +1 -1
  317. package/.next/standalone/.next/server/chunks/6113.js +1 -1
  318. package/.next/standalone/.next/server/chunks/6145.js +1 -0
  319. package/.next/standalone/.next/server/chunks/6506.js +1 -1
  320. package/.next/standalone/.next/server/chunks/6515.js +2 -2
  321. package/.next/standalone/.next/server/chunks/6689.js +1 -0
  322. package/.next/standalone/.next/server/chunks/6753.js +3 -3
  323. package/.next/standalone/.next/server/chunks/679.js +1 -1
  324. package/.next/standalone/.next/server/chunks/7368.js +1 -1
  325. package/.next/standalone/.next/server/chunks/7530.js +1 -1
  326. package/.next/standalone/.next/server/chunks/8454.js +1 -1
  327. package/.next/standalone/.next/server/chunks/920.js +1 -1
  328. package/.next/standalone/.next/server/chunks/9213.js +1 -1
  329. package/.next/standalone/.next/server/chunks/9378.js +1 -1
  330. package/.next/standalone/.next/server/chunks/9667.js +1 -0
  331. package/.next/standalone/.next/server/chunks/9931.js +1 -0
  332. package/.next/standalone/.next/server/middleware-build-manifest.js +1 -1
  333. package/.next/standalone/.next/server/middleware-manifest.json +5 -5
  334. package/.next/standalone/.next/server/middleware-react-loadable-manifest.js +1 -1
  335. package/.next/standalone/.next/server/next-font-manifest.js +1 -1
  336. package/.next/standalone/.next/server/next-font-manifest.json +1 -1
  337. package/.next/standalone/.next/server/pages/404.html +2 -2
  338. package/.next/standalone/.next/server/pages/500.html +1 -1
  339. package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
  340. package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
  341. package/.next/standalone/.next/server/src/middleware.js +2 -2
  342. package/.next/standalone/.next/static/chunks/{11595.bbe40924d18958bf.js → 11595.b81c0bf7732c3b62.js} +1 -1
  343. package/.next/standalone/.next/static/chunks/24808-e3d95efc7ec039c5.js +1 -0
  344. package/.next/standalone/.next/static/chunks/{31308-bb4a97b3f39c22dd.js → 31308-32614efb88305738.js} +1 -1
  345. package/.next/standalone/.next/static/chunks/{33456.5499eb8e892b110a.js → 33456.cfc9aa607a62e879.js} +1 -1
  346. package/.next/standalone/.next/static/chunks/38366.fb931fab9c756890.js +1 -0
  347. package/.next/standalone/.next/static/chunks/{4860.be77046fb2b3a2bd.js → 4860.41351a823cf400e4.js} +1 -1
  348. package/.next/standalone/.next/static/chunks/51468-194d894e563580dd.js +1 -0
  349. package/.next/standalone/.next/static/chunks/61570-527701d072d00a24.js +1 -0
  350. package/.next/standalone/.next/static/chunks/65066-6da35d5cb080c7f5.js +1 -0
  351. package/.next/standalone/.next/static/chunks/{65096-f756aac39efad7a3.js → 65096-8295f53f97c40d47.js} +1 -1
  352. package/.next/standalone/.next/static/chunks/72875-0987d09cd8406614.js +1 -0
  353. package/.next/standalone/.next/static/chunks/75936-79860953212592fd.js +1 -0
  354. package/.next/standalone/.next/static/chunks/{78917-a8a8dff98857c045.js → 79919-e02963faee5cb563.js} +1 -1
  355. package/.next/standalone/.next/static/chunks/94643-e8f5fa25e2340cc8.js +1 -0
  356. package/.next/standalone/.next/static/chunks/{99373.111493dc260a2a04.js → 99373.633f7c25e64bcdac.js} +1 -1
  357. package/.next/standalone/.next/static/chunks/app/(dashboard)/layout-bb5ef11586301c72.js +1 -0
  358. package/.next/standalone/.next/static/chunks/app/(dashboard)/project-groups/[uuid]/{page-974781e4886529f8.js → page-82e90e222d6bc547.js} +1 -1
  359. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/activity/page-f1eccb50d38d8982.js +1 -0
  360. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/dashboard/page-eecb38fa4b8eb4e8.js +1 -0
  361. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page-725373108da1b08c.js +1 -0
  362. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/documents/page-cd7ec77596304a07.js +1 -0
  363. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/graph/page-97a9e6f949002004.js +1 -0
  364. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page-7d2f4713697eb0a7.js +1 -0
  365. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/proposals/new/page-cec15f4b835d34fc.js +1 -0
  366. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/proposals/page-0225f87552b977d9.js +1 -0
  367. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/tasks/[taskUuid]/{page-15bb6e1696668512.js → page-4ee117e690fda56f.js} +1 -1
  368. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/tasks/{page-2bea97214b1595cc.js → page-7fbc46dfb7b22bd3.js} +1 -1
  369. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/page-069c9738e516436b.js +1 -0
  370. package/.next/standalone/.next/static/chunks/app/(dashboard)/settings/page-8b30678a58e7b2ee.js +1 -0
  371. package/.next/standalone/.next/static/chunks/app/_not-found/{page-166b410da84336d4.js → page-b9d672df79b35e87.js} +1 -1
  372. package/.next/standalone/.next/static/chunks/app/admin/companies/[uuid]/{page-b2458ed001dc8177.js → page-56118c51122ad639.js} +1 -1
  373. package/.next/standalone/.next/static/chunks/app/admin/companies/new/page-4e20deb41357171c.js +1 -0
  374. package/.next/standalone/.next/static/chunks/app/admin/companies/page-0632f245bf9c1c27.js +1 -0
  375. package/.next/standalone/.next/static/chunks/app/admin/layout-725ab2331c642f36.js +1 -0
  376. package/.next/standalone/.next/static/chunks/app/admin/{page-0cc8cf246db43e5d.js → page-5a0271dd2b8b36fd.js} +1 -1
  377. package/.next/standalone/.next/static/chunks/app/{layout-985054e973f66999.js → layout-098288cec4490c5d.js} +1 -1
  378. package/.next/standalone/.next/static/chunks/app/login/admin/page-c8e40259e5d3d9e0.js +1 -0
  379. package/.next/standalone/.next/static/chunks/app/login/callback/page-527652f6c1a39274.js +1 -0
  380. package/.next/standalone/.next/static/chunks/app/login/{page-9b34375d1b5579d7.js → page-0a16a64855b771ef.js} +1 -1
  381. package/.next/standalone/.next/static/chunks/app/login/pick-workspace/page-47375a86e2375202.js +1 -0
  382. package/.next/standalone/.next/static/chunks/app/onboarding/{page-540da64d7ba16dc7.js → page-4fce966dc96d4ff1.js} +1 -1
  383. package/.next/standalone/.next/static/chunks/app/{page-79e2d32e69788bd2.js → page-91dbf7dfd85f805f.js} +1 -1
  384. package/.next/standalone/.next/static/chunks/main-app-1a7cacecc8900a4d.js +1 -0
  385. package/.next/standalone/.next/static/chunks/{webpack-7cbb3ba6792f1fb3.js → webpack-1bfc783412a06fc5.js} +1 -1
  386. package/.next/standalone/.next/static/css/1d9cf83f50b6db00.css +1 -0
  387. package/.next/standalone/package.json +2 -1
  388. package/.next/standalone/public/chorus-plugin/.claude-plugin/plugin.json +1 -1
  389. package/.next/standalone/public/chorus-plugin/bin/chorus-api.sh +1 -1
  390. package/.next/standalone/public/chorus-plugin/skills/brainstorm/SKILL.md +1 -1
  391. package/.next/standalone/public/chorus-plugin/skills/chorus/SKILL.md +2 -2
  392. package/.next/standalone/public/chorus-plugin/skills/chorus-cli/SKILL.md +11 -1
  393. package/.next/standalone/public/chorus-plugin/skills/develop/SKILL.md +2 -2
  394. package/.next/standalone/public/chorus-plugin/skills/docs/SKILL.md +1 -1
  395. package/.next/standalone/public/chorus-plugin/skills/idea/SKILL.md +2 -2
  396. package/.next/standalone/public/chorus-plugin/skills/openspec-aware/SKILL.md +1 -1
  397. package/.next/standalone/public/chorus-plugin/skills/orchestrate/SKILL.md +1 -1
  398. package/.next/standalone/public/chorus-plugin/skills/proposal/SKILL.md +1 -1
  399. package/.next/standalone/public/chorus-plugin/skills/quick-dev/SKILL.md +1 -1
  400. package/.next/standalone/public/chorus-plugin/skills/review/SKILL.md +1 -1
  401. package/.next/standalone/public/chorus-plugin/skills/yolo/SKILL.md +3 -3
  402. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-brainstorm/SKILL.md +1 -1
  403. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-cli/SKILL.md +11 -1
  404. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-develop/SKILL.md +2 -2
  405. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-docs/SKILL.md +1 -1
  406. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-idea/SKILL.md +2 -2
  407. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-openspec-aware/SKILL.md +1 -1
  408. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-orchestrate/SKILL.md +1 -1
  409. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-proposal/SKILL.md +1 -1
  410. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-quick-dev/SKILL.md +1 -1
  411. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-review/SKILL.md +1 -1
  412. package/.next/standalone/public/kiro-plugin/.kiro/skills/chorus-yolo/SKILL.md +3 -3
  413. package/.next/standalone/public/kiro-plugin/.kiro/steering/chorus.md +1 -1
  414. package/.next/standalone/public/kiro-plugin/bin/chorus-api.sh +1 -1
  415. package/.next/standalone/public/kiro-plugin/manifest.txt +1 -0
  416. package/.next/standalone/public/skill/chorus/SKILL.md +1 -1
  417. package/.next/standalone/public/skill/develop-chorus/SKILL.md +1 -1
  418. package/.next/standalone/public/skill/idea-chorus/SKILL.md +1 -1
  419. package/.next/standalone/public/skill/yolo-chorus/SKILL.md +2 -2
  420. package/.next/standalone/server.js +1 -1
  421. package/README.ja.md +5 -1
  422. package/README.ko.md +5 -1
  423. package/README.md +5 -1
  424. package/README.zh.md +5 -1
  425. package/cli/agent-backend-prompt.mjs +5 -0
  426. package/cli/agent-launcher.mjs +341 -0
  427. package/cli/agents.mjs +12 -0
  428. package/cli/claude-spawner.mjs +52 -15
  429. package/cli/credentials.mjs +107 -1
  430. package/cli/daemon-agent.mjs +4 -2
  431. package/cli/init/adapters.mjs +5 -5
  432. package/cli/init/agent-type-map.mjs +5 -5
  433. package/cli/init/contracts.mjs +2 -0
  434. package/cli/init/install-methods.mjs +206 -31
  435. package/cli/init/pi-mcp-config.mjs +166 -0
  436. package/cli/init/steps/credential-seed.mjs +56 -3
  437. package/cli/init-args.mjs +4 -1
  438. package/cli/init.mjs +47 -2
  439. package/cli/kiro-spawner.mjs +1 -0
  440. package/cli/pi-spawner.mjs +286 -0
  441. package/cli/spawner-select.mjs +7 -1
  442. package/cli/upload-hooks.mjs +25 -1
  443. package/cli/waker.mjs +89 -38
  444. package/package.json +2 -1
  445. package/.next/standalone/.env +0 -18
  446. package/.next/standalone/.next/server/chunks/1437.js +0 -1
  447. package/.next/standalone/.next/server/chunks/3045.js +0 -1
  448. package/.next/standalone/.next/server/chunks/4545.js +0 -1
  449. package/.next/standalone/.next/server/chunks/6207.js +0 -1
  450. package/.next/standalone/.next/server/chunks/7091.js +0 -1
  451. package/.next/standalone/.next/server/chunks/9449.js +0 -1
  452. package/.next/standalone/.next/server/chunks/9458.js +0 -1
  453. package/.next/standalone/.next/static/chunks/18139-e6ef4b5869593f8e.js +0 -1
  454. package/.next/standalone/.next/static/chunks/28856-ef2cb58fbd404ef9.js +0 -1
  455. package/.next/standalone/.next/static/chunks/38366.e6e0132b8ba873d6.js +0 -1
  456. package/.next/standalone/.next/static/chunks/66873-e3be53f41b3f2255.js +0 -1
  457. package/.next/standalone/.next/static/chunks/70303-aec3d52ad87602a3.js +0 -1
  458. package/.next/standalone/.next/static/chunks/76201-83b26515f85ce37c.js +0 -1
  459. package/.next/standalone/.next/static/chunks/94643-ffa140f765c73daf.js +0 -1
  460. package/.next/standalone/.next/static/chunks/97663-9c3ae4fd60b353db.js +0 -1
  461. package/.next/standalone/.next/static/chunks/app/(dashboard)/layout-40fe7d026c5a7c6d.js +0 -1
  462. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/activity/page-20632dbec5a6dbc0.js +0 -1
  463. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/dashboard/page-87d4d0fe90fca28c.js +0 -1
  464. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/documents/[documentUuid]/page-1206abaee85dc915.js +0 -1
  465. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/documents/page-474e494097c8945f.js +0 -1
  466. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/graph/page-e902b19328092ccf.js +0 -1
  467. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/proposals/[proposalUuid]/page-f273288c3530aa0f.js +0 -1
  468. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/proposals/new/page-6568a7b08bf9a54b.js +0 -1
  469. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/[uuid]/proposals/page-fbd3c27b68666234.js +0 -1
  470. package/.next/standalone/.next/static/chunks/app/(dashboard)/projects/page-9d79e285b6fd2f8d.js +0 -1
  471. package/.next/standalone/.next/static/chunks/app/(dashboard)/settings/page-2bf7ceee62b574c7.js +0 -1
  472. package/.next/standalone/.next/static/chunks/app/admin/companies/new/page-e35dce890d6dfd8d.js +0 -1
  473. package/.next/standalone/.next/static/chunks/app/admin/companies/page-ef720c2b0856166c.js +0 -1
  474. package/.next/standalone/.next/static/chunks/app/admin/layout-c66ce38cbd88982a.js +0 -1
  475. package/.next/standalone/.next/static/chunks/app/login/admin/page-f032b6db3bd20a2c.js +0 -1
  476. package/.next/standalone/.next/static/chunks/app/login/callback/page-ec23211506e688ee.js +0 -1
  477. package/.next/standalone/.next/static/chunks/app/login/pick-workspace/page-7e4664af2c787d08.js +0 -1
  478. package/.next/standalone/.next/static/chunks/main-app-ec87f2c9ef083ff1.js +0 -1
  479. package/.next/standalone/.next/static/css/5f52bd39b284ccdf.css +0 -1
  480. /package/.next/standalone/.next/static/{0spgxl3lP26Fl1otd1D7R → WSN4XeA1kUCI6CeEHcaT_}/_buildManifest.js +0 -0
  481. /package/.next/standalone/.next/static/{0spgxl3lP26Fl1otd1D7R → WSN4XeA1kUCI6CeEHcaT_}/_ssgManifest.js +0 -0
@@ -0,0 +1,341 @@
1
+ // cli/agent-launcher.mjs
2
+ // `chorus agents run` — launch a configured coding-agent binary in the FOREGROUND
3
+ // with the selected Chorus agent's connection + identity injected into the child
4
+ // environment only. This is the interactive counterpart to the daemon's headless
5
+ // spawners (claude-spawner / codex-spawner / …): it reuses the SAME env-injection
6
+ // contract (CHORUS_URL / CHORUS_API_KEY / CHORUS_AGENT_PROFILE) and the SAME
7
+ // shell-free PATH resolution, but differs deliberately —
8
+ // • stdio is INHERITED (the agent gets the real TTY; Ctrl-C reaches it directly),
9
+ // • CHORUS_DAEMON_HEADLESS is NOT set (and is cleared if it leaked in),
10
+ // • every token after `--` is passed to the agent VERBATIM, with no validation,
11
+ // • the child's exit (code or signal) is forwarded as this command's exit code.
12
+ //
13
+ // SECRET RULE: the `cho_` API key is injected into the child env only. It is NEVER
14
+ // written to stdout, stderr, or any log — diagnostics name the agent by
15
+ // name/UUID and the resolved binary, nothing else.
16
+
17
+ import { spawn } from "node:child_process";
18
+ import { statSync } from "node:fs";
19
+ import { win32 as pathWin32, posix as pathPosix } from "node:path";
20
+ import { resolveLaunchAgent } from "./credentials.mjs";
21
+
22
+ /**
23
+ * Launch agent-type → executable base name. Launch is a SUPERSET of daemon wake:
24
+ * it can start ANY known agent, including the ones the daemon classifies
25
+ * "offline" (opencode / openclaw / dsh) and therefore never auto-wakes. The
26
+ * "offline" value itself is intentionally ABSENT: it is a wake classification,
27
+ * not a concrete backend, so it cannot name a binary — a user who added such an
28
+ * agent must pass an explicit `--type` (see resolveBinaryName).
29
+ * @type {Readonly<Record<string,string>>}
30
+ */
31
+ export const TYPE_TO_BINARY = Object.freeze({
32
+ "claude-code": "claude",
33
+ claude: "claude",
34
+ codex: "codex",
35
+ kiro: "kiro-cli",
36
+ pi: "pi",
37
+ opencode: "opencode",
38
+ openclaw: "openclaw",
39
+ dsh: "dsh-jsonrpc-agent",
40
+ });
41
+
42
+ /** Human list of accepted --type values, for help + error text. */
43
+ export const SUPPORTED_TYPES = "claude-code, codex, kiro, pi, opencode, openclaw, dsh";
44
+
45
+ /**
46
+ * POSIX signal name → number, for the shell `128 + signum` exit convention when
47
+ * the launched agent is terminated by a signal (e.g. Ctrl-C = SIGINT → 130).
48
+ * Node's `close` event yields a signal NAME (or null); a naive `exit(code)` with
49
+ * code=null would collapse a signal death to exit 0 and hide it.
50
+ */
51
+ const SIGNUM = Object.freeze({
52
+ SIGHUP: 1,
53
+ SIGINT: 2,
54
+ SIGQUIT: 3,
55
+ SIGILL: 4,
56
+ SIGABRT: 6,
57
+ SIGFPE: 8,
58
+ SIGKILL: 9,
59
+ SIGSEGV: 11,
60
+ SIGPIPE: 13,
61
+ SIGALRM: 14,
62
+ SIGTERM: 15,
63
+ });
64
+
65
+ /** A non-empty trimmed string, or undefined. */
66
+ function nonEmpty(value) {
67
+ return typeof value === "string" && value.trim() ? value.trim() : undefined;
68
+ }
69
+
70
+ /**
71
+ * Split raw `chorus agents run` argv into chorus-owned flags and verbatim
72
+ * passthrough. The FIRST bare `--` terminates chorus-flag parsing; everything
73
+ * after it is passthrough, untouched. Chorus flags (before `--`): `--name <v>` /
74
+ * `--name=<v>`, its `--agent` alias, `--type <v>` / `--type=<v>`, and `--help`/`-h`.
75
+ * The first token that is NOT a recognized chorus flag also starts the
76
+ * passthrough (lenient) — so `chorus agents run --name x foo --bar` treats
77
+ * `foo --bar` as passthrough even without an explicit `--`.
78
+ *
79
+ * @param {string[]} argv argv AFTER the `run` sub-verb.
80
+ * @returns {{ name?: string, type?: string, help: boolean, passthrough: string[], error?: string }}
81
+ */
82
+ export function parseRunArgs(argv = []) {
83
+ const out = { help: false, passthrough: [] };
84
+ let i = 0;
85
+ for (; i < argv.length; i += 1) {
86
+ const tok = argv[i];
87
+ if (tok === "--") {
88
+ i += 1; // consume the separator; the rest is passthrough
89
+ break;
90
+ }
91
+ if (tok === "--help" || tok === "-h") {
92
+ out.help = true;
93
+ continue;
94
+ }
95
+ if (tok === "--name" || tok === "--agent") {
96
+ const v = argv[i + 1];
97
+ if (v === undefined) return { ...out, error: `flag ${tok} needs a value` };
98
+ out.name = v;
99
+ i += 1;
100
+ continue;
101
+ }
102
+ if (tok.startsWith("--name=")) {
103
+ out.name = tok.slice("--name=".length);
104
+ continue;
105
+ }
106
+ if (tok.startsWith("--agent=")) {
107
+ out.name = tok.slice("--agent=".length);
108
+ continue;
109
+ }
110
+ if (tok === "--type") {
111
+ const v = argv[i + 1];
112
+ if (v === undefined) return { ...out, error: `flag --type needs a value` };
113
+ out.type = v;
114
+ i += 1;
115
+ continue;
116
+ }
117
+ if (tok.startsWith("--type=")) {
118
+ out.type = tok.slice("--type=".length);
119
+ continue;
120
+ }
121
+ // Unrecognized token → start of verbatim passthrough.
122
+ break;
123
+ }
124
+ out.passthrough = argv.slice(i);
125
+ return out;
126
+ }
127
+
128
+ /**
129
+ * Resolve the agent type (explicit `--type` wins over the stored `agentType`)
130
+ * and map it to a binary base name. An `offline` classification or any unknown
131
+ * type has no launchable binary → returns an `error` string instructing the user
132
+ * to pass an explicit `--type`.
133
+ * @param {string|undefined} explicitType the `--type` flag value
134
+ * @param {string|undefined} configType the agent's stored agentType
135
+ * @returns {{ type: string, binary: string } | { error: string }}
136
+ */
137
+ export function resolveBinaryName(explicitType, configType) {
138
+ const type = nonEmpty(explicitType) ?? nonEmpty(configType);
139
+ if (!type) {
140
+ return { error: `no agent type given and none is configured — pass --type <${SUPPORTED_TYPES}>` };
141
+ }
142
+ const binary = TYPE_TO_BINARY[type];
143
+ if (!binary) {
144
+ const reason =
145
+ type === "offline"
146
+ ? `agent is configured as "offline" (the daemon does not auto-wake it, so its concrete backend is not stored)`
147
+ : `unknown agent type "${type}"`;
148
+ return { error: `${reason} — pass an explicit --type <${SUPPORTED_TYPES}>` };
149
+ }
150
+ return { type, binary };
151
+ }
152
+
153
+ /**
154
+ * Resolve an executable base name to a full path WITHOUT a shell, walking PATH.
155
+ * On Windows, tries `.cmd` / `.exe` / bare (npm shims are `.cmd`); on POSIX just
156
+ * the bare name. Mirrors resolveClaudePath's shape. Returns null when not found.
157
+ * @param {string} binName
158
+ * @param {{ env?: NodeJS.ProcessEnv, platform?: NodeJS.Platform, isFile?: (p: string) => boolean }} [deps]
159
+ * @returns {string | null}
160
+ */
161
+ export function resolveBinaryPath(binName, deps = {}) {
162
+ const env = deps.env ?? process.env;
163
+ const platform = deps.platform ?? process.platform;
164
+ const isFile =
165
+ deps.isFile ??
166
+ ((p) => {
167
+ try {
168
+ return statSync(p).isFile();
169
+ } catch {
170
+ return false;
171
+ }
172
+ });
173
+ const isWin = platform === "win32";
174
+ const p = isWin ? pathWin32 : pathPosix;
175
+ const names = isWin ? [`${binName}.cmd`, `${binName}.exe`, binName] : [binName];
176
+ const pathVar = env.PATH || env.Path || "";
177
+ const dirs = pathVar.split(p.delimiter).filter(Boolean);
178
+ for (const dir of dirs) {
179
+ for (const name of names) {
180
+ const candidate = p.join(dir, name);
181
+ if (isFile(candidate)) return candidate;
182
+ }
183
+ }
184
+ return null;
185
+ }
186
+
187
+ /**
188
+ * Resolve the actual command + argv to spawn. A Windows `.cmd`/`.bat` shim is not
189
+ * a PE executable, so it must run via `cmd.exe /d /s /c <path> …args`; keep
190
+ * shell:false and pass argv as an array (no shell word-splitting/injection). On
191
+ * POSIX (and a real `.exe`) spawn the path directly.
192
+ * @param {string} binPath @param {string[]} args
193
+ * @param {NodeJS.Platform} [platform] @param {NodeJS.ProcessEnv} [env]
194
+ * @returns {{ command: string, argv: string[] }}
195
+ */
196
+ export function resolveSpawnCommand(binPath, args, platform = process.platform, env = process.env) {
197
+ const isWin = platform === "win32";
198
+ const lower = binPath.toLowerCase();
199
+ if (isWin && (lower.endsWith(".cmd") || lower.endsWith(".bat"))) {
200
+ const comspec = env.ComSpec || env.COMSPEC || "cmd.exe";
201
+ return { command: comspec, argv: ["/d", "/s", "/c", binPath, ...args] };
202
+ }
203
+ return { command: binPath, argv: args };
204
+ }
205
+
206
+ /**
207
+ * Build the child environment: the inherited env plus the selected agent's Chorus
208
+ * connection + identity. NO CHORUS_DAEMON_HEADLESS — this is an interactive run;
209
+ * a leaked value from a daemon-run parent is cleared so the agent does not adopt
210
+ * headless behavior. Only non-empty fields are set.
211
+ * @param {import("./credentials.mjs").LaunchAgent} agent
212
+ * @param {NodeJS.ProcessEnv} [baseEnv]
213
+ * @returns {NodeJS.ProcessEnv}
214
+ */
215
+ export function buildChildEnv(agent, baseEnv = process.env) {
216
+ const childEnv = { ...baseEnv };
217
+ if (agent.url) childEnv.CHORUS_URL = agent.url;
218
+ if (agent.apiKey) childEnv.CHORUS_API_KEY = agent.apiKey;
219
+ const profile = agent.agentUuid || agent.agentName;
220
+ if (profile) childEnv.CHORUS_AGENT_PROFILE = profile;
221
+ delete childEnv.CHORUS_DAEMON_HEADLESS;
222
+ return childEnv;
223
+ }
224
+
225
+ /** Usage text for `chorus agents run`. */
226
+ export function runHelpText(version = "") {
227
+ const v = version ? ` v${version}` : "";
228
+ return `\
229
+ Chorus${v} — launch a configured agent
230
+
231
+ USAGE
232
+ chorus agents run --name <name|uuid> [--type <type>] [--] [agent args…]
233
+
234
+ Launches the agent's binary in the FOREGROUND with this agent's Chorus connection
235
+ injected into the child (CHORUS_URL / CHORUS_API_KEY / CHORUS_AGENT_PROFILE).
236
+ Everything after \`--\` is passed to the agent verbatim — the agent's full flag
237
+ surface is available and is never inspected by chorus.
238
+
239
+ FLAGS
240
+ --name <name|uuid> Which configured agent to launch (default: the only one).
241
+ --type <type> Override the agent's backend: ${SUPPORTED_TYPES}.
242
+ -h, --help Show this help.
243
+
244
+ Notes
245
+ • Agents added as opencode / openclaw / dsh are stored as "offline"; pass
246
+ --type explicitly to launch them.
247
+ • The API key is injected into the launched process only — never printed.
248
+ `;
249
+ }
250
+
251
+ /**
252
+ * Run `chorus agents run …`. Selects the agent, resolves its binary, injects the
253
+ * Chorus env, and spawns it in the foreground. Resolves with an exit code (never
254
+ * calls process.exit): the launched agent's code, `128 + signum` on signal death,
255
+ * `1` on any launch failure, `2` on a usage error, `0` on --help.
256
+ *
257
+ * @param {string[]} argv argv AFTER the `run` sub-verb.
258
+ * @param {{ stdout?: {write:(s:string)=>void}, stderr?: {write:(s:string)=>void},
259
+ * env?: NodeJS.ProcessEnv, readJson?: (p:string)=>any, loginPath?: string,
260
+ * platform?: NodeJS.Platform, cwd?: string, version?: string,
261
+ * spawnImpl?: Function, isFile?: (p:string)=>boolean }} [opts]
262
+ * @returns {Promise<number>}
263
+ */
264
+ export async function runAgentLaunch(argv = [], opts = {}) {
265
+ const out = opts.stdout ?? process.stdout;
266
+ const err = opts.stderr ?? process.stderr;
267
+ const env = opts.env ?? process.env;
268
+ const platform = opts.platform ?? process.platform;
269
+ const spawnImpl = opts.spawnImpl ?? spawn;
270
+ const version = opts.version ?? "";
271
+
272
+ const parsed = parseRunArgs(argv);
273
+ if (parsed.help) {
274
+ out.write(runHelpText(version));
275
+ return 0;
276
+ }
277
+ if (parsed.error) {
278
+ err.write(`error: ${parsed.error}\n\n${runHelpText(version)}`);
279
+ return 2;
280
+ }
281
+
282
+ // 1. Select which configured agent to launch.
283
+ let agent;
284
+ try {
285
+ agent = resolveLaunchAgent({ name: parsed.name }, opts);
286
+ } catch (e) {
287
+ err.write(`error: ${e.message}\n`);
288
+ return 1;
289
+ }
290
+
291
+ // 2. Resolve the type → binary (explicit --type wins over stored agentType).
292
+ const typeRes = resolveBinaryName(parsed.type, agent.agentType);
293
+ if (typeRes.error) {
294
+ err.write(`error: ${agent.label}: ${typeRes.error}\n`);
295
+ return 1;
296
+ }
297
+
298
+ // 3. Locate the binary on PATH.
299
+ const binPath = resolveBinaryPath(typeRes.binary, { env, platform, isFile: opts.isFile });
300
+ if (!binPath) {
301
+ err.write(
302
+ `error: could not find the \`${typeRes.binary}\` executable on PATH ` +
303
+ `(agent "${agent.label}", type "${typeRes.type}"). Is it installed?\n`,
304
+ );
305
+ return 1;
306
+ }
307
+
308
+ // 4. Build the child env and the spawn command.
309
+ const childEnv = buildChildEnv(agent, env);
310
+ const { command, argv: spawnArgv } = resolveSpawnCommand(binPath, parsed.passthrough, platform, env);
311
+
312
+ // Diagnostic — agent name/uuid + binary ONLY. Never the key or url userinfo.
313
+ out.write(`Launching ${agent.label} (${agent.agentUuid ?? "no uuid"}) → ${typeRes.binary}\n`);
314
+
315
+ return new Promise((resolve) => {
316
+ let child;
317
+ try {
318
+ child = spawnImpl(command, spawnArgv, {
319
+ cwd: opts.cwd ?? process.cwd(),
320
+ stdio: "inherit",
321
+ env: childEnv,
322
+ shell: false,
323
+ });
324
+ } catch (e) {
325
+ err.write(`error: failed to launch ${typeRes.binary}: ${e.message}\n`);
326
+ resolve(1);
327
+ return;
328
+ }
329
+ child.on("error", (e) => {
330
+ err.write(`error: ${typeRes.binary} failed to start: ${e.message}\n`);
331
+ resolve(1);
332
+ });
333
+ child.on("close", (code, signal) => {
334
+ if (signal) {
335
+ resolve(128 + (SIGNUM[signal] ?? 0));
336
+ return;
337
+ }
338
+ resolve(typeof code === "number" ? code : 0);
339
+ });
340
+ });
341
+ }
package/cli/agents.mjs CHANGED
@@ -67,6 +67,10 @@ USAGE
67
67
  chorus agents add [flags] Configure agent(s): detect, install plugin, seed
68
68
  credentials (formerly \`chorus init\`; same flags —
69
69
  see \`chorus agents add --help\`)
70
+ chorus agents run --name <n> [--type <t>] -- [args…]
71
+ Launch an agent's binary in the foreground with its
72
+ Chorus connection injected; args after \`--\` pass
73
+ through verbatim (see \`chorus agents run --help\`)
70
74
  chorus agents remove <name|uuid> Remove a configured agent from ~/.chorus/daemon.json
71
75
 
72
76
  Each listed UUID or name is a valid value for \`chorus mcp --agent <name|uuid>\` or the
@@ -316,6 +320,14 @@ export function runAgents(argv = [], opts = {}) {
316
320
  const runInit = opts.runInit ?? (async (a, o) => (await import("./init.mjs")).runInit(a, o));
317
321
  return runInit(argv.slice(1), { version });
318
322
  }
323
+ if (first === "run") {
324
+ // Foreground agent launch. Dynamic import keeps the list/remove paths from
325
+ // loading the launcher (and its child_process import). Forward the full opts
326
+ // (env/readJson/loginPath/spawnImpl/stdio) so tests can inject them.
327
+ const runAgentLaunch =
328
+ opts.runAgentLaunch ?? (async (a, o) => (await import("./agent-launcher.mjs")).runAgentLaunch(a, o));
329
+ return runAgentLaunch(argv.slice(1), { ...opts, version });
330
+ }
319
331
  if (first === "remove") {
320
332
  return removeAgent(argv.slice(1), opts);
321
333
  }
@@ -3,7 +3,7 @@
3
3
  // engineering point of the daemon: parsing stream-json is plain JS and
4
4
  // platform-neutral; the real work is spawning, and it is all Windows.
5
5
  //
6
- // Verified against Claude Code CLI 2.1.177:
6
+ // Verified against Claude Code CLI 2.1.251:
7
7
  // • `-p/--print` + `--output-format stream-json` emits NDJSON (one JSON object
8
8
  // per line); every line carries `session_id`.
9
9
  // • `--session-id <uuid>` sets the session id for a fresh run, and
@@ -32,6 +32,28 @@ const NOOP_LOGGER = { info() {}, warn() {}, error() {} };
32
32
  /** Matches a canonical lowercase UUID (any version). Chorus idea uuids are v4. */
33
33
  const UUID_RE = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;
34
34
 
35
+ /** Backend-neutral failure classification consumed by the wake orchestrator. */
36
+ export const SESSION_CONFLICT_FAILURE = "session_conflict";
37
+
38
+ const STDERR_BUFFER_LIMIT = 64 * 1024;
39
+ const SESSION_CONFLICT_RE = /\bsession id\b[^\r\n]{0,200}\bis already in use\b/i;
40
+ const CLAUDE_PROJECT_KEY_CAP = 200;
41
+
42
+ /**
43
+ * Claude Code 2.1.251's Java-style signed 32-bit string hash, rendered as the
44
+ * absolute value in base36. Iterating by index intentionally hashes UTF-16 code
45
+ * units (including each surrogate in an astral character) rather than code points.
46
+ * @param {string} value
47
+ * @returns {string}
48
+ */
49
+ function projectKeyHash(value) {
50
+ let hash = 0;
51
+ for (let index = 0; index < value.length; index += 1) {
52
+ hash = ((hash << 5) - hash + value.charCodeAt(index)) | 0;
53
+ }
54
+ return Math.abs(hash).toString(36);
55
+ }
56
+
35
57
  /**
36
58
  * True iff `id` is a well-formed, lowercase UUID. The daemon anchors the Claude
37
59
  * session id on a Chorus idea uuid (already lowercase v4); we validate before
@@ -45,22 +67,27 @@ export function isValidSessionId(id) {
45
67
  }
46
68
 
47
69
  /**
48
- * Claude Code's transcript directory for a working directory. Verified against the
49
- * live install: claude escapes the ABSOLUTE cwd by replacing both `/` and `.` with
50
- * `-` (e.g. `/home/u/dev/ai-pm` `-home-u-dev-ai-pm`,
51
- * `/home/u/.cfg/x` `-home-u--cfg-x`). On Windows the separators/drive differ, so
52
- * we escape backslashes and colons too; the rule there is best-effort and must be
53
- * re-verified against a Windows claude before claiming Windows resume support.
70
+ * Claude Code's transcript directory for a working directory. Verified against
71
+ * Claude Code 2.1.251's live Linux install and on-disk transcripts: every
72
+ * non-ASCII-alphanumeric UTF-16 code unit becomes `-`. That includes separators,
73
+ * dots, spaces, underscores, and non-ASCII characters; existing hyphens remain
74
+ * byte-identical because replacing `-` with `-` is a no-op. Escaped keys longer
75
+ * than 200 characters use the first 200 characters plus `-` and the base36
76
+ * Java-style signed 32-bit hash of the original cwd. The same expression produces
77
+ * the established Windows fixture, though the Windows on-disk layout remains
78
+ * best-effort until verified on a Windows Claude installation.
54
79
  * @param {string} cwd Absolute working directory.
55
80
  * @param {NodeJS.Platform} [platform]
56
81
  * @returns {string}
57
82
  */
58
83
  export function escapeCwd(cwd, platform = process.platform) {
59
- // Replace path separators and dots with `-`. On POSIX that's `/` and `.`; on
60
- // Windows also `\` and the drive-colon. Collapsing both `/` and `.` is what
61
- // produces the verified double-dash on a leading-dot segment.
62
- const re = platform === "win32" ? /[\\/.:]/g : /[/.]/g;
63
- return cwd.replace(re, "-");
84
+ // `platform` remains in the signature for fixture/API compatibility. Claude's
85
+ // observed sanitizer is platform-independent; platform path syntax supplies
86
+ // the differing separator/drive characters that this expression normalizes.
87
+ void platform;
88
+ const escaped = cwd.replace(/[^a-zA-Z0-9]/g, "-");
89
+ if (escaped.length <= CLAUDE_PROJECT_KEY_CAP) return escaped;
90
+ return `${escaped.slice(0, CLAUDE_PROJECT_KEY_CAP)}-${projectKeyHash(cwd)}`;
64
91
  }
65
92
 
66
93
  /**
@@ -284,7 +311,8 @@ export class ClaudeSpawner {
284
311
  * so the waker can store the handle in its execution registry for the interrupt
285
312
  * path BEFORE this promise resolves. It is invoked once, synchronously, only on a
286
313
  * successful spawn; a spawn failure never calls it.
287
- * @returns {Promise<{ sessionId: string, backendSessionId: string|null, exitCode: number|null, isNew: boolean }>}
314
+ * @returns {Promise<{ sessionId: string, backendSessionId: string|null, exitCode: number|null, isNew: boolean,
315
+ * failureClassification?: "session_conflict" }>}
288
316
  * `backendSessionId` is the Claude `--resume` anchor (the input `sessionId`) on a
289
317
  * terminal resolution after a spawn, so the conversation UI can offer a resumable
290
318
  * id — mirrors codex-spawner's shape. `null` on the pre-spawn failure paths (no
@@ -369,6 +397,8 @@ export class ClaudeSpawner {
369
397
  }
370
398
 
371
399
  let stdoutBuf = "";
400
+ let stderrBuf = "";
401
+ let sessionConflictSeen = false;
372
402
  let observedSessionId = id;
373
403
 
374
404
  child.stdout?.setEncoding?.("utf8");
@@ -392,7 +422,10 @@ export class ClaudeSpawner {
392
422
 
393
423
  child.stderr?.setEncoding?.("utf8");
394
424
  child.stderr?.on("data", (chunk) => {
395
- const text = String(chunk).trim();
425
+ const rawText = String(chunk);
426
+ stderrBuf = (stderrBuf + rawText).slice(-STDERR_BUFFER_LIMIT);
427
+ if (SESSION_CONFLICT_RE.test(stderrBuf)) sessionConflictSeen = true;
428
+ const text = rawText.trim();
396
429
  if (text) this.logger.warn(`[Chorus] claude stderr: ${text}`);
397
430
  });
398
431
 
@@ -411,7 +444,11 @@ export class ClaudeSpawner {
411
444
  }
412
445
  // backendSessionId is the `--resume` anchor (`id`), NOT observedSessionId (see
413
446
  // the process-error handler above for why the anchor is the resumable value).
414
- resolve({ sessionId: observedSessionId, backendSessionId: id, exitCode: code, isNew });
447
+ const result = { sessionId: observedSessionId, backendSessionId: id, exitCode: code, isNew };
448
+ if (code !== null && code !== 0 && sessionConflictSeen) {
449
+ result.failureClassification = SESSION_CONFLICT_FAILURE;
450
+ }
451
+ resolve(result);
415
452
  });
416
453
 
417
454
  // Guard against an ASYNC stdin error (EPIPE): if claude exits/closes
@@ -18,15 +18,19 @@
18
18
 
19
19
  import { readFileSync } from "node:fs";
20
20
  import { homedir } from "node:os";
21
- import { join } from "node:path";
21
+ import { join, resolve } from "node:path";
22
22
 
23
23
  /** Absolute path to the login file written by `chorus login`. */
24
24
  export function loginFilePath() {
25
+ const override = process.env.CHORUS_DAEMON_CONFIG_PATH?.trim();
26
+ if (override) return resolve(override);
25
27
  return join(homedir(), ".chorus", "daemon.json");
26
28
  }
27
29
 
28
30
  /** Absolute path to the Claude Code user settings file (plugin fallback source). */
29
31
  export function claudeSettingsPath() {
32
+ const override = process.env.CHORUS_CLAUDE_SETTINGS_PATH?.trim();
33
+ if (override) return resolve(override);
30
34
  return join(homedir(), ".claude", "settings.json");
31
35
  }
32
36
 
@@ -376,3 +380,105 @@ export function resolveMcpCredentials(flags = {}, deps = {}) {
376
380
  const flat = resolveCredentials(flags, deps);
377
381
  return { url: flat.url, apiKey: flat.apiKey, label: flat.source };
378
382
  }
383
+
384
+ /**
385
+ * @typedef {Object} LaunchAgent
386
+ * @property {string|undefined} url
387
+ * @property {string|undefined} apiKey
388
+ * @property {string|undefined} agentUuid
389
+ * @property {string|undefined} agentName
390
+ * @property {string|undefined} agentType The daemon agentType stored in daemon.json
391
+ * ("claude-code" | "codex" | "kiro" | "pi" | "offline" | …). The launcher maps this
392
+ * (or an explicit --type) to a binary.
393
+ * @property {string} label Diagnostic display label (name/uuid), never the key.
394
+ */
395
+
396
+ /**
397
+ * Resolve WHICH configured agent to launch (`chorus agents run`), returning the
398
+ * selected `agents[]` entry INCLUDING its `agentType` — the field the launcher
399
+ * needs to pick a binary and which `resolveMcpCredentials` deliberately drops.
400
+ *
401
+ * Selection precedence (mirrors `resolveMcpCredentials`, minus the url+key env/flag
402
+ * fallbacks — a launch always acts as a configured agent):
403
+ * 1. explicit selector: `flags.name` (the `--name` flag) or `flags.agent`
404
+ * (`--agent` alias), matched against each entry's agentUuid / agentName /
405
+ * label / name (exact). No match → error; >1 match → ambiguity error.
406
+ * 2. `CHORUS_AGENT_PROFILE` env, same matching.
407
+ * 3. exactly one configured agent → that agent.
408
+ * 4. more than one and nothing specified → error (never pick silently).
409
+ * No `agents[]` at all → error telling the user to configure one.
410
+ *
411
+ * Each entry's url/apiKey merges over the top-level per-field defaults
412
+ * (`resolveCredentialDefaults`), same as `resolveMcpCredentials`. This never
413
+ * imports daemon-config.mjs (which imports this module) — it reads `agents[]`
414
+ * directly to stay cycle-free.
415
+ *
416
+ * @param {{ name?: string, agent?: string, url?: string, apiKey?: string }} flags
417
+ * @param {ResolveDeps} [deps]
418
+ * @returns {LaunchAgent}
419
+ * @throws {Error} on ambiguity, no match, or no configured agents.
420
+ */
421
+ export function resolveLaunchAgent(flags = {}, deps = {}) {
422
+ const env = deps.env ?? process.env;
423
+ const readJson = deps.readJson ?? readJsonSafe;
424
+ const loginPath = deps.loginPath ?? loginFilePath();
425
+ const wanted = nonEmpty(flags.name) ?? nonEmpty(flags.agent) ?? nonEmpty(env.CHORUS_AGENT_PROFILE);
426
+
427
+ const file = readJson(loginPath);
428
+ const agentEntries =
429
+ file && Array.isArray(file.agents)
430
+ ? file.agents.filter((a) => a && typeof a === "object")
431
+ : [];
432
+ if (agentEntries.length === 0) {
433
+ throw new Error(
434
+ `No agents are configured in ${loginPath}. Run \`chorus agents add\` to configure one.`,
435
+ );
436
+ }
437
+
438
+ const defaults = resolveCredentialDefaults(flags, deps);
439
+ const labelOf = (entry, i) =>
440
+ nonEmpty(entry.agentName) ?? nonEmpty(entry.label) ?? nonEmpty(entry.name) ?? `agents[${i}]`;
441
+ const resolved = agentEntries.map((entry, i) => ({
442
+ label: labelOf(entry, i),
443
+ keys: [entry.agentUuid, entry.agentName, entry.label, entry.name]
444
+ .map((k) => nonEmpty(k))
445
+ .filter((k) => k !== undefined),
446
+ url: nonEmpty(entry.url) ?? defaults.url,
447
+ apiKey: nonEmpty(entry.apiKey) ?? defaults.apiKey,
448
+ agentUuid: nonEmpty(entry.agentUuid),
449
+ agentName: nonEmpty(entry.agentName) ?? nonEmpty(entry.name),
450
+ agentType: nonEmpty(entry.agentType),
451
+ }));
452
+ const labels = resolved.map((a) => a.label).join(", ");
453
+
454
+ let selected;
455
+ if (wanted) {
456
+ const matches = resolved.filter((a) => a.keys.includes(wanted));
457
+ if (matches.length === 0) {
458
+ throw new Error(`No configured agent matches "${wanted}" in ${loginPath}. Available: ${labels}.`);
459
+ }
460
+ if (matches.length > 1) {
461
+ throw new Error(
462
+ `"${wanted}" is ambiguous in ${loginPath} — it matches ${matches.length} agents ` +
463
+ `(${matches.map((m) => m.label).join(", ")}). Use the agent UUID to disambiguate.`,
464
+ );
465
+ }
466
+ selected = matches[0];
467
+ } else if (resolved.length === 1) {
468
+ selected = resolved[0];
469
+ } else {
470
+ throw new Error(
471
+ `Multiple agents are configured in ${loginPath} (${labels}). ` +
472
+ `Specify which one to launch with --name <name|uuid> or CHORUS_AGENT_PROFILE.`,
473
+ );
474
+ }
475
+
476
+ return {
477
+ url: selected.url,
478
+ apiKey: selected.apiKey,
479
+ agentUuid: selected.agentUuid,
480
+ agentName: selected.agentName,
481
+ agentType: selected.agentType,
482
+ label: selected.label,
483
+ };
484
+ }
@@ -27,8 +27,8 @@ import { loginFilePath } from "./credentials.mjs";
27
27
  * fail-closed no-wake handling lives in spawner-select.mjs (selectSpawner returns
28
28
  * an OfflineSpawner that refuses to spawn) — an offline value MUST NOT fall through
29
29
  * to the claude-code default and wake it. `chorus agents add` maps every non-wakeable
30
- * selected agent (opencode/openclaw/pi/dsh) to this classification. */
31
- export const KNOWN_AGENTS = ["claude-code", "codex", "kiro", "dsh", "offline"];
30
+ * selected agent (opencode/openclaw) to this classification. */
31
+ export const KNOWN_AGENTS = ["claude-code", "codex", "kiro", "dsh", "pi", "offline"];
32
32
 
33
33
  /** The default agent backend when neither --agent nor CHORUS_AGENT is set. */
34
34
  export const DEFAULT_AGENT = "claude-code";
@@ -45,6 +45,7 @@ export function backendCli(agentType) {
45
45
  if (agentType === "codex") return { name: "codex", envVar: "CHORUS_CODEX_PATH" };
46
46
  if (agentType === "kiro") return { name: "kiro-cli", envVar: "CHORUS_KIRO_PATH" };
47
47
  if (agentType === "dsh") return { name: "dsh-jsonrpc-agent", envVar: "CHORUS_DSH_PATH" };
48
+ if (agentType === "pi") return { name: "pi", envVar: "CHORUS_PI_PATH" };
48
49
  // `offline` has no CLI to resolve — it is never woken (see backendClientType).
49
50
  // The daemon does not probe a binary for it; this explicit descriptor keeps the
50
51
  // return sensible if some banner path ever reads it (CHORUS_AGENT selects the
@@ -65,6 +66,7 @@ export function backendClientType(agentType) {
65
66
  if (agentType === "codex") return "codex";
66
67
  if (agentType === "kiro") return "kiro";
67
68
  if (agentType === "dsh") return "dsh";
69
+ if (agentType === "pi") return "pi";
68
70
  // `offline` is a non-wakeable classification — the daemon SHALL NOT register it
69
71
  // as a wakeable connection (daemon-multi-agent spec). It must therefore NOT
70
72
  // fall through to the `claude_code` default (which would make an offline agent
@@ -35,13 +35,13 @@ import {
35
35
  installDsh,
36
36
  installOpenclaw,
37
37
  installKiro,
38
+ installPi,
38
39
  readCodexInstallState,
39
40
  readOpencodeInstallState,
40
41
  readDshInstallState,
41
42
  readOpenclawInstallState,
42
43
  readKiroInstallState,
43
- guided,
44
- GUIDED_MESSAGES,
44
+ readPiInstallState,
45
45
  } from "./install-methods.mjs";
46
46
 
47
47
  // Re-export the shared marketplace identifiers from their canonical home so
@@ -95,7 +95,7 @@ export const AGENT_DESCRIPTORS = [
95
95
  { id: "kiro", displayName: "Kiro CLI", binaries: ["kiro"], configDirs: ["~/.kiro"], readState: readKiroInstallState, install: installKiro },
96
96
  { id: "opencode", displayName: "opencode", binaries: ["opencode"], configDirs: ["~/.config/opencode", "~/.opencode"], readState: readOpencodeInstallState, install: installOpencode },
97
97
  { id: "openclaw", displayName: "OpenClaw", binaries: ["openclaw"], configDirs: ["~/.openclaw", "~/.config/openclaw"], readState: readOpenclawInstallState, install: installOpenclaw },
98
- { id: "pi", displayName: "Pi", binaries: ["pi"], configDirs: ["~/.pi", "~/.config/pi"], install: guided("pi", GUIDED_MESSAGES.pi) },
98
+ { id: "pi", displayName: "Pi", binaries: ["pi"], configDirs: ["~/.pi", "~/.config/pi"], readState: readPiInstallState, install: installPi },
99
99
  { id: "dsh", displayName: "DeepSeek Harness (dsh)", binaries: ["dsh"], configDirs: ["$DSH_HOME", "~/.dsh"], readState: readDshInstallState, install: installDsh },
100
100
  ];
101
101
 
@@ -117,8 +117,8 @@ export function buildAdapter(d) {
117
117
  // `guided()` fallback also returns a function (so `typeof d.install ===
118
118
  // "function"` alone would report every fallback agent as supported — the
119
119
  // pre-existing latent bug); guided installers are tagged `.guided === true`,
120
- // so exclude them here. Real installers (claude/codex/opencode + dsh/openclaw/
121
- // kiro) → true; guided (pi) → false.
120
+ // so exclude them here. Every current agent (claude/codex/opencode + dsh/
121
+ // openclaw/kiro/pi) has a real installer → true; a future guided fallback → false.
122
122
  return { supported: typeof d.install === "function" && d.install.guided !== true, ...base };
123
123
  },
124
124
  installPlugin: (ctx = {}) =>