@shepai/cli 1.151.2-pr438.6135e39 → 1.151.2-pr470.ec33cce

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 (197) hide show
  1. package/apis/json-schema/WorkflowConfig.yaml +0 -5
  2. package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.d.ts +0 -28
  3. package/dist/packages/core/src/application/ports/output/services/git-pr-service.interface.d.ts.map +1 -1
  4. package/dist/packages/core/src/application/ports/output/services/github-repository-service.interface.d.ts +0 -37
  5. package/dist/packages/core/src/application/ports/output/services/github-repository-service.interface.d.ts.map +1 -1
  6. package/dist/packages/core/src/application/ports/output/services/github-repository-service.interface.js +0 -12
  7. package/dist/packages/core/src/application/ports/output/services/index.d.ts +3 -5
  8. package/dist/packages/core/src/application/ports/output/services/index.d.ts.map +1 -1
  9. package/dist/packages/core/src/application/ports/output/services/index.js +1 -2
  10. package/dist/packages/core/src/domain/generated/output.d.ts +0 -185
  11. package/dist/packages/core/src/domain/generated/output.d.ts.map +1 -1
  12. package/dist/packages/core/src/infrastructure/di/container.d.ts.map +1 -1
  13. package/dist/packages/core/src/infrastructure/di/container.js +0 -4
  14. package/dist/packages/core/src/infrastructure/services/external/github-repository.service.d.ts +1 -3
  15. package/dist/packages/core/src/infrastructure/services/external/github-repository.service.d.ts.map +1 -1
  16. package/dist/packages/core/src/infrastructure/services/external/github-repository.service.js +1 -37
  17. package/dist/packages/core/src/infrastructure/services/git/git-pr.service.d.ts +1 -2
  18. package/dist/packages/core/src/infrastructure/services/git/git-pr.service.d.ts.map +1 -1
  19. package/dist/packages/core/src/infrastructure/services/git/git-pr.service.js +0 -21
  20. package/dist/src/presentation/cli/index.js +0 -2
  21. package/dist/src/presentation/web/components/common/evidence-lightbox/evidence-lightbox.d.ts +15 -0
  22. package/dist/src/presentation/web/components/common/evidence-lightbox/evidence-lightbox.d.ts.map +1 -0
  23. package/dist/src/presentation/web/components/common/evidence-lightbox/evidence-lightbox.js +43 -0
  24. package/dist/src/presentation/web/components/common/evidence-lightbox/evidence-lightbox.stories.d.ts +18 -0
  25. package/dist/src/presentation/web/components/common/evidence-lightbox/evidence-lightbox.stories.d.ts.map +1 -0
  26. package/dist/src/presentation/web/components/common/evidence-lightbox/evidence-lightbox.stories.js +125 -0
  27. package/dist/src/presentation/web/components/common/evidence-lightbox/index.d.ts +3 -0
  28. package/dist/src/presentation/web/components/common/evidence-lightbox/index.d.ts.map +1 -0
  29. package/dist/src/presentation/web/components/common/evidence-lightbox/index.js +1 -0
  30. package/dist/src/presentation/web/components/common/merge-review/merge-review.d.ts.map +1 -1
  31. package/dist/src/presentation/web/components/common/merge-review/merge-review.js +28 -2
  32. package/dist/tsconfig.build.tsbuildinfo +1 -1
  33. package/package.json +1 -1
  34. package/web/.next/BUILD_ID +1 -1
  35. package/web/.next/build-manifest.json +2 -2
  36. package/web/.next/fallback-build-manifest.json +2 -2
  37. package/web/.next/prerender-manifest.json +3 -3
  38. package/web/.next/required-server-files.js +1 -1
  39. package/web/.next/required-server-files.json +1 -1
  40. package/web/.next/server/app/(dashboard)/@drawer/adopt/page/server-reference-manifest.json +28 -28
  41. package/web/.next/server/app/(dashboard)/@drawer/adopt/page.js.nft.json +1 -1
  42. package/web/.next/server/app/(dashboard)/@drawer/adopt/page_client-reference-manifest.js +1 -1
  43. package/web/.next/server/app/(dashboard)/@drawer/create/page/server-reference-manifest.json +29 -29
  44. package/web/.next/server/app/(dashboard)/@drawer/create/page.js.nft.json +1 -1
  45. package/web/.next/server/app/(dashboard)/@drawer/create/page_client-reference-manifest.js +1 -1
  46. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page/server-reference-manifest.json +36 -36
  47. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page.js.nft.json +1 -1
  48. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
  49. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page/server-reference-manifest.json +36 -36
  50. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page.js.nft.json +1 -1
  51. package/web/.next/server/app/(dashboard)/@drawer/feature/[featureId]/page_client-reference-manifest.js +1 -1
  52. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page/server-reference-manifest.json +26 -26
  53. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page.js.nft.json +1 -1
  54. package/web/.next/server/app/(dashboard)/@drawer/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
  55. package/web/.next/server/app/(dashboard)/create/page/server-reference-manifest.json +29 -29
  56. package/web/.next/server/app/(dashboard)/create/page.js.nft.json +1 -1
  57. package/web/.next/server/app/(dashboard)/create/page_client-reference-manifest.js +1 -1
  58. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page/server-reference-manifest.json +36 -36
  59. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page.js.nft.json +1 -1
  60. package/web/.next/server/app/(dashboard)/feature/[featureId]/[tab]/page_client-reference-manifest.js +1 -1
  61. package/web/.next/server/app/(dashboard)/feature/[featureId]/page/server-reference-manifest.json +36 -36
  62. package/web/.next/server/app/(dashboard)/feature/[featureId]/page.js.nft.json +1 -1
  63. package/web/.next/server/app/(dashboard)/feature/[featureId]/page_client-reference-manifest.js +1 -1
  64. package/web/.next/server/app/(dashboard)/page/server-reference-manifest.json +26 -26
  65. package/web/.next/server/app/(dashboard)/page.js.nft.json +1 -1
  66. package/web/.next/server/app/(dashboard)/page_client-reference-manifest.js +1 -1
  67. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page/server-reference-manifest.json +26 -26
  68. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page.js.nft.json +1 -1
  69. package/web/.next/server/app/(dashboard)/repository/[repositoryId]/page_client-reference-manifest.js +1 -1
  70. package/web/.next/server/app/_global-error.html +2 -2
  71. package/web/.next/server/app/_global-error.rsc +1 -1
  72. package/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  73. package/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  74. package/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  75. package/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  76. package/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  77. package/web/.next/server/app/_not-found/page/server-reference-manifest.json +3 -3
  78. package/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  79. package/web/.next/server/app/api/attachments/preview/route.js.nft.json +1 -1
  80. package/web/.next/server/app/api/evidence/route.js.nft.json +1 -1
  81. package/web/.next/server/app/api/graph-data/route.js.nft.json +1 -1
  82. package/web/.next/server/app/settings/page/server-reference-manifest.json +8 -8
  83. package/web/.next/server/app/settings/page.js.nft.json +1 -1
  84. package/web/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  85. package/web/.next/server/app/skills/page/server-reference-manifest.json +8 -8
  86. package/web/.next/server/app/skills/page.js.nft.json +1 -1
  87. package/web/.next/server/app/skills/page_client-reference-manifest.js +1 -1
  88. package/web/.next/server/app/tools/page/server-reference-manifest.json +8 -8
  89. package/web/.next/server/app/tools/page.js.nft.json +1 -1
  90. package/web/.next/server/app/tools/page_client-reference-manifest.js +1 -1
  91. package/web/.next/server/app/version/page/server-reference-manifest.json +3 -3
  92. package/web/.next/server/app/version/page_client-reference-manifest.js +1 -1
  93. package/web/.next/server/chunks/[root-of-the-server]__a402b567._.js +1 -1
  94. package/web/.next/server/chunks/[root-of-the-server]__c6e32a23._.js.map +1 -1
  95. package/web/.next/server/chunks/[root-of-the-server]__cd67a84c._.js.map +1 -1
  96. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js +1 -1
  97. package/web/.next/server/chunks/ssr/744ca_web_components_common_control-center-drawer_create-drawer-client_tsx_5e26fc0a._.js.map +1 -1
  98. package/web/.next/server/chunks/ssr/[root-of-the-server]__0b150ddf._.js.map +1 -1
  99. package/web/.next/server/chunks/ssr/[root-of-the-server]__2138fa7e._.js +2 -2
  100. package/web/.next/server/chunks/ssr/[root-of-the-server]__2138fa7e._.js.map +1 -1
  101. package/web/.next/server/chunks/ssr/[root-of-the-server]__29580090._.js +1 -1
  102. package/web/.next/server/chunks/ssr/[root-of-the-server]__29580090._.js.map +1 -1
  103. package/web/.next/server/chunks/ssr/[root-of-the-server]__357d99f9._.js +1 -1
  104. package/web/.next/server/chunks/ssr/[root-of-the-server]__3ef34e4c._.js +1 -1
  105. package/web/.next/server/chunks/ssr/[root-of-the-server]__3ef34e4c._.js.map +1 -1
  106. package/web/.next/server/chunks/ssr/[root-of-the-server]__43f51aa6._.js +1 -1
  107. package/web/.next/server/chunks/ssr/[root-of-the-server]__43f51aa6._.js.map +1 -1
  108. package/web/.next/server/chunks/ssr/[root-of-the-server]__815546bd._.js +1 -1
  109. package/web/.next/server/chunks/ssr/[root-of-the-server]__815546bd._.js.map +1 -1
  110. package/web/.next/server/chunks/ssr/[root-of-the-server]__aad040c0._.js +3 -3
  111. package/web/.next/server/chunks/ssr/[root-of-the-server]__aad040c0._.js.map +1 -1
  112. package/web/.next/server/chunks/ssr/[root-of-the-server]__c094882b._.js +1 -1
  113. package/web/.next/server/chunks/ssr/[root-of-the-server]__c094882b._.js.map +1 -1
  114. package/web/.next/server/chunks/ssr/[root-of-the-server]__d48c5b11._.js +1 -1
  115. package/web/.next/server/chunks/ssr/[root-of-the-server]__d48c5b11._.js.map +1 -1
  116. package/web/.next/server/chunks/ssr/[root-of-the-server]__dac5dbf1._.js +1 -1
  117. package/web/.next/server/chunks/ssr/[root-of-the-server]__dac5dbf1._.js.map +1 -1
  118. package/web/.next/server/chunks/ssr/[root-of-the-server]__fae8b355._.js +1 -1
  119. package/web/.next/server/chunks/ssr/[root-of-the-server]__fae8b355._.js.map +1 -1
  120. package/web/.next/server/chunks/ssr/_05c23ad9._.js +1 -1
  121. package/web/.next/server/chunks/ssr/_05c23ad9._.js.map +1 -1
  122. package/web/.next/server/chunks/ssr/_0c473fef._.js +2 -2
  123. package/web/.next/server/chunks/ssr/_0c473fef._.js.map +1 -1
  124. package/web/.next/server/chunks/ssr/_16eb4fec._.js +1 -1
  125. package/web/.next/server/chunks/ssr/_16eb4fec._.js.map +1 -1
  126. package/web/.next/server/chunks/ssr/_1b719e7f._.js +1 -1
  127. package/web/.next/server/chunks/ssr/_1b719e7f._.js.map +1 -1
  128. package/web/.next/server/chunks/ssr/{_c2ca0f1b._.js → _34a8a162._.js} +2 -2
  129. package/web/.next/server/chunks/ssr/{_c2ca0f1b._.js.map → _34a8a162._.js.map} +1 -1
  130. package/web/.next/server/chunks/ssr/_37e8548b._.js +1 -1
  131. package/web/.next/server/chunks/ssr/_37e8548b._.js.map +1 -1
  132. package/web/.next/server/chunks/ssr/_55d763e2._.js +1 -1
  133. package/web/.next/server/chunks/ssr/_55d763e2._.js.map +1 -1
  134. package/web/.next/server/chunks/ssr/_6256a985._.js +1 -1
  135. package/web/.next/server/chunks/ssr/_6256a985._.js.map +1 -1
  136. package/web/.next/server/chunks/ssr/{_dc9a9d32._.js → _762bbdd5._.js} +2 -2
  137. package/web/.next/server/chunks/ssr/{_dc9a9d32._.js.map → _762bbdd5._.js.map} +1 -1
  138. package/web/.next/server/chunks/ssr/_8fcc39d4._.js +1 -1
  139. package/web/.next/server/chunks/ssr/_8fcc39d4._.js.map +1 -1
  140. package/web/.next/server/chunks/ssr/_b71645b4._.js +1 -1
  141. package/web/.next/server/chunks/ssr/_b71645b4._.js.map +1 -1
  142. package/web/.next/server/chunks/ssr/_d4b20e29._.js.map +1 -1
  143. package/web/.next/server/chunks/ssr/_d8575088._.js +1 -1
  144. package/web/.next/server/chunks/ssr/_d8575088._.js.map +1 -1
  145. package/web/.next/server/chunks/ssr/_e9e9ed20._.js +2 -2
  146. package/web/.next/server/chunks/ssr/_e9e9ed20._.js.map +1 -1
  147. package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js +1 -1
  148. package/web/.next/server/chunks/ssr/b1a17_presentation_web_components_features_settings_settings-page-client_tsx_6ed9d5f8._.js.map +1 -1
  149. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_skills_page_actions_1b176e3c.js +1 -1
  150. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_skills_page_actions_1b176e3c.js.map +1 -1
  151. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_tools_page_actions_bd9f0dda.js +1 -1
  152. package/web/.next/server/chunks/ssr/src_presentation_web__next-internal_server_app_tools_page_actions_bd9f0dda.js.map +1 -1
  153. package/web/.next/server/chunks/ssr/src_presentation_web_app_actions_open-ide_ts_baaca5d5._.js +1 -1
  154. package/web/.next/server/chunks/ssr/src_presentation_web_b437e763._.js +3 -0
  155. package/web/.next/server/chunks/ssr/{src_presentation_web_aa941041._.js.map → src_presentation_web_b437e763._.js.map} +1 -1
  156. package/web/.next/server/chunks/ssr/src_presentation_web_components_e599bb8c._.js +1 -1
  157. package/web/.next/server/chunks/ssr/src_presentation_web_components_e599bb8c._.js.map +1 -1
  158. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js +1 -1
  159. package/web/.next/server/chunks/ssr/src_presentation_web_components_features_control-center_7ac3562e._.js.map +1 -1
  160. package/web/.next/server/pages/500.html +2 -2
  161. package/web/.next/server/server-reference-manifest.js +1 -1
  162. package/web/.next/server/server-reference-manifest.json +45 -45
  163. package/web/.next/static/chunks/{359b2815c5ed39cc.js → 0d473fbdf724361c.js} +1 -1
  164. package/web/.next/static/chunks/{e760b952ba1a10d4.js → 1ef9dfc624cdd5c0.js} +1 -1
  165. package/web/.next/static/chunks/{79eae02d0342fb73.js → 2c4e4027386847dc.js} +1 -1
  166. package/web/.next/static/chunks/{87b72b8a10f8255b.js → 331e2a1232d9f855.js} +3 -3
  167. package/web/.next/static/chunks/{80915095cec414bf.js → 48a36b37fc27443b.js} +1 -1
  168. package/web/.next/static/chunks/52470bcbe2e8198d.css +1 -0
  169. package/web/.next/static/chunks/{5e1877d1f1bcfd77.js → 6e406c42f179f73f.js} +1 -1
  170. package/web/.next/static/chunks/{c2388f8bc58b2a21.js → 706819c360883af1.js} +1 -1
  171. package/web/.next/static/chunks/{4a28fd1bca225386.js → 7bf35c5612fdba16.js} +1 -1
  172. package/web/.next/static/chunks/{76a3f345f8cf2608.js → c286aae364899eae.js} +1 -1
  173. package/web/.next/static/chunks/{25889ca8401d1bc0.js → d8685c1bf2415bc5.js} +1 -1
  174. package/web/.next/static/chunks/{091de81012e2bc48.js → e558b4b9d066763c.js} +1 -1
  175. package/web/.next/static/chunks/{ed9408f100149c34.js → ebebc7a215e04768.js} +1 -1
  176. package/apis/json-schema/AgentRunDetail.yaml +0 -28
  177. package/apis/json-schema/DoctorDiagnosticReport.yaml +0 -76
  178. package/apis/json-schema/FailedRunSummary.yaml +0 -22
  179. package/apis/json-schema/SystemInfo.yaml +0 -22
  180. package/apis/json-schema/WorkerLogEntry.yaml +0 -27
  181. package/dist/packages/core/src/application/ports/output/services/github-issue-service.interface.d.ts +0 -57
  182. package/dist/packages/core/src/application/ports/output/services/github-issue-service.interface.d.ts.map +0 -1
  183. package/dist/packages/core/src/application/ports/output/services/github-issue-service.interface.js +0 -39
  184. package/dist/packages/core/src/application/use-cases/doctor/doctor-diagnose.use-case.d.ts +0 -64
  185. package/dist/packages/core/src/application/use-cases/doctor/doctor-diagnose.use-case.d.ts.map +0 -1
  186. package/dist/packages/core/src/application/use-cases/doctor/doctor-diagnose.use-case.js +0 -493
  187. package/dist/packages/core/src/infrastructure/services/external/github-issue-creator.service.d.ts +0 -17
  188. package/dist/packages/core/src/infrastructure/services/external/github-issue-creator.service.d.ts.map +0 -1
  189. package/dist/packages/core/src/infrastructure/services/external/github-issue-creator.service.js +0 -69
  190. package/dist/src/presentation/cli/commands/doctor.command.d.ts +0 -20
  191. package/dist/src/presentation/cli/commands/doctor.command.d.ts.map +0 -1
  192. package/dist/src/presentation/cli/commands/doctor.command.js +0 -129
  193. package/web/.next/server/chunks/ssr/src_presentation_web_aa941041._.js +0 -3
  194. package/web/.next/static/chunks/9b8678597fa1db84.css +0 -1
  195. /package/web/.next/static/{-o7QIcv1p5C722dwF4EFd → crqlqgDegiKDLReFt70L0}/_buildManifest.js +0 -0
  196. /package/web/.next/static/{-o7QIcv1p5C722dwF4EFd → crqlqgDegiKDLReFt70L0}/_clientMiddlewareManifest.json +0 -0
  197. /package/web/.next/static/{-o7QIcv1p5C722dwF4EFd → crqlqgDegiKDLReFt70L0}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,24270,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"warnOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},68304,e=>{"use strict";var t=e.i(20314),r=e.i(79054),n=e.i(91967),i=e.i(22528),o=e.i(51080),a=e.i(85995),s=e.i(87620),l=e.i(66033),u=e.i(36589),c=e.i(13123),d="Tabs",[f,p]=(0,i.createContextScope)(d,[o.createRovingFocusGroupScope]),h=(0,o.createRovingFocusGroupScope)(),[y,m]=f(d),g=r.forwardRef((e,r)=>{let{__scopeTabs:n,value:i,onValueChange:o,defaultValue:a,orientation:f="horizontal",dir:p,activationMode:h="automatic",...m}=e,g=(0,l.useDirection)(p),[v,b]=(0,u.useControllableState)({prop:i,onChange:o,defaultProp:a??"",caller:d});return(0,t.jsx)(y,{scope:n,baseId:(0,c.useId)(),value:v,onValueChange:b,orientation:f,dir:g,activationMode:h,children:(0,t.jsx)(s.Primitive.div,{dir:g,"data-orientation":f,...m,ref:r})})});g.displayName=d;var v="TabsList",b=r.forwardRef((e,r)=>{let{__scopeTabs:n,loop:i=!0,...a}=e,l=m(v,n),u=h(n);return(0,t.jsx)(o.Root,{asChild:!0,...u,orientation:l.orientation,dir:l.dir,loop:i,children:(0,t.jsx)(s.Primitive.div,{role:"tablist","aria-orientation":l.orientation,...a,ref:r})})});b.displayName=v;var x="TabsTrigger",w=r.forwardRef((e,r)=>{let{__scopeTabs:i,value:a,disabled:l=!1,...u}=e,c=m(x,i),d=h(i),f=C(c.baseId,a),p=S(c.baseId,a),y=a===c.value;return(0,t.jsx)(o.Item,{asChild:!0,...d,focusable:!l,active:y,children:(0,t.jsx)(s.Primitive.button,{type:"button",role:"tab","aria-selected":y,"aria-controls":p,"data-state":y?"active":"inactive","data-disabled":l?"":void 0,disabled:l,id:f,...u,ref:r,onMouseDown:(0,n.composeEventHandlers)(e.onMouseDown,e=>{l||0!==e.button||!1!==e.ctrlKey?e.preventDefault():c.onValueChange(a)}),onKeyDown:(0,n.composeEventHandlers)(e.onKeyDown,e=>{[" ","Enter"].includes(e.key)&&c.onValueChange(a)}),onFocus:(0,n.composeEventHandlers)(e.onFocus,()=>{let e="manual"!==c.activationMode;y||l||!e||c.onValueChange(a)})})})});w.displayName=x;var k="TabsContent",j=r.forwardRef((e,n)=>{let{__scopeTabs:i,value:o,forceMount:l,children:u,...c}=e,d=m(k,i),f=C(d.baseId,o),p=S(d.baseId,o),h=o===d.value,y=r.useRef(h);return r.useEffect(()=>{let e=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,t.jsx)(a.Presence,{present:l||h,children:({present:r})=>(0,t.jsx)(s.Primitive.div,{"data-state":h?"active":"inactive","data-orientation":d.orientation,role:"tabpanel","aria-labelledby":f,hidden:!r,id:p,tabIndex:0,...c,ref:n,style:{...e.style,animationDuration:y.current?"0s":void 0},children:r&&u})})});function C(e,t){return`${e}-trigger-${t}`}function S(e,t){return`${e}-content-${t}`}j.displayName=k,e.s(["Content",()=>j,"List",()=>b,"Root",()=>g,"Tabs",()=>g,"TabsContent",()=>j,"TabsList",()=>b,"TabsTrigger",()=>w,"Trigger",()=>w,"createTabsScope",()=>p],43133);var P=e.i(43133),P=P,R=e.i(31777);let E=P.Root,T=r.forwardRef(({className:e,...r},n)=>(0,t.jsx)(P.List,{ref:n,className:(0,R.cn)("bg-muted text-muted-foreground inline-flex h-9 items-center justify-center rounded-lg p-1",e),...r}));T.displayName=P.List.displayName;let O=r.forwardRef(({className:e,...r},n)=>(0,t.jsx)(P.Trigger,{ref:n,className:(0,R.cn)("ring-offset-background focus-visible:ring-ring data-[state=active]:bg-background data-[state=active]:text-foreground inline-flex items-center justify-center rounded-md px-3 py-1 text-sm font-medium whitespace-nowrap transition-all focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow",e),...r}));O.displayName=P.Trigger.displayName;let M=r.forwardRef(({className:e,...r},n)=>(0,t.jsx)(P.Content,{ref:n,className:(0,R.cn)("ring-offset-background focus-visible:ring-ring mt-2 focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",e),...r}));M.displayName=P.Content.displayName,e.s(["Tabs",()=>E,"TabsContent",()=>M,"TabsList",()=>T,"TabsTrigger",()=>O],68304)},10942,94819,e=>{"use strict";var t=e.i(80986);e.s(["CircleCheck",()=>t.default],10942);let r=(0,e.i(3645).default)("ban",[["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);e.s(["Ban",()=>r],94819)},32494,e=>{"use strict";let t=(0,e.i(3645).default)("globe",[["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"}]]);e.s(["Globe",()=>t],32494)},79687,e=>{"use strict";var t=e.i(14748);e.s(["AlertCircle",()=>t.default])},39443,e=>{"use strict";var t=e.i(20314),r=e.i(79054);let n=(0,e.i(18354).createLogger)("[SSE]");function i(e,t,r,n){if("u"<typeof EventSource)return()=>{};let i=null,o=!1,a=1e3,s=null,l=null;return!function u(){o||(i=new EventSource(e?`/api/agent-events?runId=${encodeURIComponent(e)}`:"/api/agent-events"),n("connecting"),i.onopen=()=>{n("connected"),l=setTimeout(()=>{l=null,a=1e3},5e3)},i.onerror=()=>{i?.close(),i=null,n("disconnected"),null!==l&&(clearTimeout(l),l=null);let e=a;a=Math.min(2*e,3e4),s=setTimeout(()=>{s=null,u()},e)},i.addEventListener("notification",e=>{let n=JSON.parse(e.data);t(e=>{let t=[...e,n];return t.length>500?t.slice(-250):t}),r(n)}))}(),()=>{o=!0,null!==s&&(clearTimeout(s),s=null),null!==l&&(clearTimeout(l),l=null),i&&(i.close(),i=null)}}let o=(0,r.createContext)(null);function a({children:e,runId:a}){let{events:s,lastEvent:l,connectionStatus:u}=function(e){let[t,o]=(0,r.useState)([]),[a,s]=(0,r.useState)(null),[l,u]=(0,r.useState)("disconnected"),c=e?.runId,d=(0,r.useRef)(null),f=(0,r.useCallback)(e=>{let t=e.data;if(t&&"object"==typeof t)if("notification"===t.type){let e=t.data;n.debug("event received:",e.eventType,e),o(t=>{let r=[...t,e];return r.length>500?r.slice(-250):r}),s(e)}else"status"===t.type&&u(t.status)},[]);return(0,r.useEffect)(()=>{let e="u">typeof location&&new URLSearchParams(location.search).has("sse");if(!navigator.serviceWorker||e)return i(c,o,s,u);let t=!1,r={current:void 0};function n(e){t||(d.current=e,e.postMessage({type:"subscribe",runId:c}),u("connecting"))}function a(){if(t)return;let e=navigator.serviceWorker.controller;e&&(d.current=e,e.postMessage({type:"subscribe",runId:c}),u("connecting"))}return navigator.serviceWorker.addEventListener("message",f),navigator.serviceWorker.addEventListener("controllerchange",a),navigator.serviceWorker.register("/agent-events-sw.js",{scope:"/"}).then(e=>{if(t)return;let a=e.active??e.installing??e.waiting;if(!a){r.current=i(c,o,s,u);return}if("activated"===a.state)n(a);else{let e=()=>{"activated"===a.state&&(a.removeEventListener("statechange",e),n(a))};a.addEventListener("statechange",e)}}).catch(()=>{t||(r.current=i(c,o,s,u))}),()=>{t=!0,navigator.serviceWorker.removeEventListener("message",f),navigator.serviceWorker.removeEventListener("controllerchange",a),d.current?.postMessage({type:"unsubscribe"}),d.current=null,r.current?.()}},[c,f]),{events:t,lastEvent:a,connectionStatus:l}}({runId:a}),c=(0,r.useMemo)(()=>({events:s,lastEvent:l,connectionStatus:u}),[s,l,u]);return(0,t.jsx)(o.Provider,{value:c,children:e})}function s(){let e=(0,r.useContext)(o);if(!e)throw Error("useAgentEventsContext must be used within an <AgentEventsProvider>");return e}e.s(["AgentEventsProvider",()=>a,"useAgentEventsContext",()=>s],39443)},3214,e=>{"use strict";let t=(0,e.i(3645).default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",()=>t],3214)},80986,e=>{"use strict";let t=(0,e.i(3645).default)("circle-check",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);e.s(["default",()=>t])},54277,30090,e=>{"use strict";let t=(0,e.i(3645).default)("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);e.s(["default",()=>t],30090),e.s(["CircleX",()=>t],54277)},51080,e=>{"use strict";var t=e.i(79054),r=e.i(91967),n=e.i(87342),i=e.i(5978),o=e.i(22528),a=e.i(13123),s=e.i(87620),l=e.i(29297),u=e.i(36589),c=e.i(66033),d=e.i(20314),f="rovingFocusGroup.onEntryFocus",p={bubbles:!1,cancelable:!0},h="RovingFocusGroup",[y,m,g]=(0,n.createCollection)(h),[v,b]=(0,o.createContextScope)(h,[g]),[x,w]=v(h),k=t.forwardRef((e,t)=>(0,d.jsx)(y.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,d.jsx)(y.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,d.jsx)(j,{...e,ref:t})})}));k.displayName=h;var j=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:o,orientation:a,loop:y=!1,dir:g,currentTabStopId:v,defaultCurrentTabStopId:b,onCurrentTabStopIdChange:w,onEntryFocus:k,preventScrollOnEntryFocus:j=!1,...C}=e,S=t.useRef(null),P=(0,i.useComposedRefs)(n,S),E=(0,c.useDirection)(g),[T,O]=(0,u.useControllableState)({prop:v,defaultProp:b??null,onChange:w,caller:h}),[M,A]=t.useState(!1),_=(0,l.useCallbackRef)(k),F=m(o),L=t.useRef(!1),[I,N]=t.useState(0);return t.useEffect(()=>{let e=S.current;if(e)return e.addEventListener(f,_),()=>e.removeEventListener(f,_)},[_]),(0,d.jsx)(x,{scope:o,orientation:a,dir:E,loop:y,currentTabStopId:T,onItemFocus:t.useCallback(e=>O(e),[O]),onItemShiftTab:t.useCallback(()=>A(!0),[]),onFocusableItemAdd:t.useCallback(()=>N(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>N(e=>e-1),[]),children:(0,d.jsx)(s.Primitive.div,{tabIndex:M||0===I?-1:0,"data-orientation":a,...C,ref:P,style:{outline:"none",...e.style},onMouseDown:(0,r.composeEventHandlers)(e.onMouseDown,()=>{L.current=!0}),onFocus:(0,r.composeEventHandlers)(e.onFocus,e=>{let t=!L.current;if(e.target===e.currentTarget&&t&&!M){let t=new CustomEvent(f,p);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=F().filter(e=>e.focusable);R([e.find(e=>e.active),e.find(e=>e.id===T),...e].filter(Boolean).map(e=>e.ref.current),j)}}L.current=!1}),onBlur:(0,r.composeEventHandlers)(e.onBlur,()=>A(!1))})})}),C="RovingFocusGroupItem",S=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:i,focusable:o=!0,active:l=!1,tabStopId:u,children:c,...f}=e,p=(0,a.useId)(),h=u||p,g=w(C,i),v=g.currentTabStopId===h,b=m(i),{onFocusableItemAdd:x,onFocusableItemRemove:k,currentTabStopId:j}=g;return t.useEffect(()=>{if(o)return x(),()=>k()},[o,x,k]),(0,d.jsx)(y.ItemSlot,{scope:i,id:h,focusable:o,active:l,children:(0,d.jsx)(s.Primitive.span,{tabIndex:v?0:-1,"data-orientation":g.orientation,...f,ref:n,onMouseDown:(0,r.composeEventHandlers)(e.onMouseDown,e=>{o?g.onItemFocus(h):e.preventDefault()}),onFocus:(0,r.composeEventHandlers)(e.onFocus,()=>g.onItemFocus(h)),onKeyDown:(0,r.composeEventHandlers)(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void g.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var n;let i=(n=e.key,"rtl"!==r?n:"ArrowLeft"===n?"ArrowRight":"ArrowRight"===n?"ArrowLeft":n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(i))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(i)))return P[i]}(e,g.orientation,g.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let i=b().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)i.reverse();else if("prev"===t||"next"===t){var r,n;"prev"===t&&i.reverse();let o=i.indexOf(e.currentTarget);i=g.loop?(r=i,n=o+1,r.map((e,t)=>r[(n+t)%r.length])):i.slice(o+1)}setTimeout(()=>R(i))}}),children:"function"==typeof c?c({isCurrentTabStop:v,hasTabStop:null!=j}):c})})});S.displayName=C;var P={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function R(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",()=>S,"Root",()=>k,"createRovingFocusGroupScope",()=>b])},49228,e=>{"use strict";let t=(0,e.i(3645).default)("git-branch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);e.s(["GitBranch",()=>t],49228)},66033,e=>{"use strict";var t=e.i(79054);e.i(20314);var r=t.createContext(void 0);function n(e){let n=t.useContext(r);return e||n||"ltr"}e.s(["useDirection",()=>n])},87342,e=>{"use strict";var t=e.i(79054),r=e.i(22528),n=e.i(5978),i=e.i(86874),o=e.i(20314);function a(e){let a=e+"CollectionProvider",[s,l]=(0,r.createContextScope)(a),[u,c]=s(a,{collectionRef:{current:null},itemMap:new Map}),d=e=>{let{scope:r,children:n}=e,i=t.default.useRef(null),a=t.default.useRef(new Map).current;return(0,o.jsx)(u,{scope:r,itemMap:a,collectionRef:i,children:n})};d.displayName=a;let f=e+"CollectionSlot",p=(0,i.createSlot)(f),h=t.default.forwardRef((e,t)=>{let{scope:r,children:i}=e,a=c(f,r),s=(0,n.useComposedRefs)(t,a.collectionRef);return(0,o.jsx)(p,{ref:s,children:i})});h.displayName=f;let y=e+"CollectionItemSlot",m="data-radix-collection-item",g=(0,i.createSlot)(y),v=t.default.forwardRef((e,r)=>{let{scope:i,children:a,...s}=e,l=t.default.useRef(null),u=(0,n.useComposedRefs)(r,l),d=c(y,i);return t.default.useEffect(()=>(d.itemMap.set(l,{ref:l,...s}),()=>void d.itemMap.delete(l))),(0,o.jsx)(g,{...{[m]:""},ref:u,children:a})});return v.displayName=y,[{Provider:d,Slot:h,ItemSlot:v},function(r){let n=c(e+"CollectionConsumer",r);return t.default.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${m}]`));return Array.from(n.itemMap.values()).sort((e,r)=>t.indexOf(e.ref.current)-t.indexOf(r.ref.current))},[n.collectionRef,n.itemMap])},l]}var s=new WeakMap;function l(e,t){var r,n;let i,o,a;if("at"in Array.prototype)return Array.prototype.at.call(e,t);let s=(r=e,n=t,i=r.length,(a=(o=u(n))>=0?o:i+o)<0||a>=i?-1:a);return -1===s?void 0:e[s]}function u(e){return e!=e||0===e?0:Math.trunc(e)}(class e extends Map{#e;constructor(e){super(e),this.#e=[...super.keys()],s.set(this,!0)}set(e,t){return s.get(this)&&(this.has(e)?this.#e[this.#e.indexOf(e)]=e:this.#e.push(e)),super.set(e,t),this}insert(e,t,r){let n,i=this.has(t),o=this.#e.length,a=u(e),s=a>=0?a:o+a,l=s<0||s>=o?-1:s;if(l===this.size||i&&l===this.size-1||-1===l)return this.set(t,r),this;let c=this.size+ +!i;a<0&&s++;let d=[...this.#e],f=!1;for(let e=s;e<c;e++)if(s===e){let o=d[e];d[e]===t&&(o=d[e+1]),i&&this.delete(t),n=this.get(o),this.set(t,r)}else{f||d[e-1]!==t||(f=!0);let r=d[f?e:e-1],i=n;n=this.get(r),this.delete(r),this.set(r,i)}return this}with(t,r,n){let i=new e(this);return i.insert(t,r,n),i}before(e){let t=this.#e.indexOf(e)-1;if(!(t<0))return this.entryAt(t)}setBefore(e,t,r){let n=this.#e.indexOf(e);return -1===n?this:this.insert(n,t,r)}after(e){let t=this.#e.indexOf(e);if(-1!==(t=-1===t||t===this.size-1?-1:t+1))return this.entryAt(t)}setAfter(e,t,r){let n=this.#e.indexOf(e);return -1===n?this:this.insert(n+1,t,r)}first(){return this.entryAt(0)}last(){return this.entryAt(-1)}clear(){return this.#e=[],super.clear()}delete(e){let t=super.delete(e);return t&&this.#e.splice(this.#e.indexOf(e),1),t}deleteAt(e){let t=this.keyAt(e);return void 0!==t&&this.delete(t)}at(e){let t=l(this.#e,e);if(void 0!==t)return this.get(t)}entryAt(e){let t=l(this.#e,e);if(void 0!==t)return[t,this.get(t)]}indexOf(e){return this.#e.indexOf(e)}keyAt(e){return l(this.#e,e)}from(e,t){let r=this.indexOf(e);if(-1===r)return;let n=r+t;return n<0&&(n=0),n>=this.size&&(n=this.size-1),this.at(n)}keyFrom(e,t){let r=this.indexOf(e);if(-1===r)return;let n=r+t;return n<0&&(n=0),n>=this.size&&(n=this.size-1),this.keyAt(n)}find(e,t){let r=0;for(let n of this){if(Reflect.apply(e,t,[n,r,this]))return n;r++}}findIndex(e,t){let r=0;for(let n of this){if(Reflect.apply(e,t,[n,r,this]))return r;r++}return -1}filter(t,r){let n=[],i=0;for(let e of this)Reflect.apply(t,r,[e,i,this])&&n.push(e),i++;return new e(n)}map(t,r){let n=[],i=0;for(let e of this)n.push([e[0],Reflect.apply(t,r,[e,i,this])]),i++;return new e(n)}reduce(...e){let[t,r]=e,n=0,i=r??this.at(0);for(let r of this)i=0===n&&1===e.length?r:Reflect.apply(t,this,[i,r,n,this]),n++;return i}reduceRight(...e){let[t,r]=e,n=r??this.at(-1);for(let r=this.size-1;r>=0;r--){let i=this.at(r);n=r===this.size-1&&1===e.length?i:Reflect.apply(t,this,[n,i,r,this])}return n}toSorted(t){return new e([...this.entries()].sort(t))}toReversed(){let t=new e;for(let e=this.size-1;e>=0;e--){let r=this.keyAt(e),n=this.get(r);t.set(r,n)}return t}toSpliced(...t){let r=[...this.entries()];return r.splice(...t),new e(r)}slice(t,r){let n=new e,i=this.size-1;if(void 0===t)return n;t<0&&(t+=this.size),void 0!==r&&r>0&&(i=r-1);for(let e=t;e<=i;e++){let t=this.keyAt(e),r=this.get(t);n.set(t,r)}return n}every(e,t){let r=0;for(let n of this){if(!Reflect.apply(e,t,[n,r,this]))return!1;r++}return!0}some(e,t){let r=0;for(let n of this){if(Reflect.apply(e,t,[n,r,this]))return!0;r++}return!1}}),e.s(["createCollection",()=>a])},27069,e=>{"use strict";function t(e,[t,r]){return Math.min(r,Math.max(t,e))}e.s(["clamp",()=>t])},81975,e=>{"use strict";let t=(0,e.i(3645).default)("wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]);e.s(["Wrench",()=>t],81975)},82569,5147,e=>{"use strict";let t=(0,e.i(3645).default)("github",[["path",{d:"M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4",key:"tonef"}],["path",{d:"M9 18c-4.51 2-5-2-7-2",key:"9comsn"}]]);e.s(["Github",()=>t],82569);var r=e.i(20314),n=e.i(79054);let i={"action-required":"action-needed",running:"in-progress",done:"done",blocked:"blocked",pending:"pending",error:"error",creating:null,deleting:null,archived:null};function o(e){return i[e]}let a=(0,n.createContext)(null);function s({children:e}){let[t,i]=(0,n.useState)([]),[o,s]=(0,n.useState)(!1),l=(0,n.useMemo)(()=>({features:t,setFeatures:i,hasRepositories:o,setHasRepositories:s}),[t,o]);return(0,r.jsx)(a.Provider,{value:l,children:e})}function l(){let e=(0,n.useContext)(a);if(!e)throw Error("useSidebarFeaturesContext must be used within a <SidebarFeaturesProvider>");return e}e.s(["SidebarFeaturesProvider",()=>s,"mapNodeStateToSidebarStatus",()=>o,"useSidebarFeaturesContext",()=>l],5147)},98127,e=>{"use strict";var t=e.i(20314),r=e.i(31777);function n({className:e,type:n,...i}){return(0,t.jsx)("input",{type:n,"data-slot":"input",className:(0,r.cn)("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",e),...i})}e.s(["Input",()=>n])},66459,e=>{"use strict";let t=(0,e.i(3645).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["Search",()=>t],66459)},12103,e=>{"use strict";let t=(0,e.i(3645).default)("puzzle",[["path",{d:"M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",key:"w46dr5"}]]);e.s(["Puzzle",()=>t],12103)},83241,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"BailoutToCSR",{enumerable:!0,get:function(){return i}});let n=e.r(9328);function i({reason:e,children:t}){if("u"<typeof window)throw Object.defineProperty(new n.BailoutToCSRError(e),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return t}},90891,(e,t,r)=>{"use strict";function n(e){return e.split("/").map(e=>encodeURIComponent(e)).join("/")}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"encodeURIPath",{enumerable:!0,get:function(){return n}})},31218,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"PreloadChunks",{enumerable:!0,get:function(){return l}});let n=e.r(20314),i=e.r(26036),o=e.r(58988),a=e.r(90891),s=e.r(22193);function l({moduleIds:e}){if("u">typeof window)return null;let t=o.workAsyncStorage.getStore();if(void 0===t)return null;let r=[];if(t.reactLoadableManifest&&e){let n=t.reactLoadableManifest;for(let t of e){if(!n[t])continue;let e=n[t].files;r.push(...e)}}if(0===r.length)return null;let l=(0,s.getDeploymentIdQueryOrEmptyString)();return(0,n.jsx)(n.Fragment,{children:r.map(e=>{let r=`${t.assetPrefix}/_next/${(0,a.encodeURIPath)(e)}${l}`;return e.endsWith(".css")?(0,n.jsx)("link",{precedence:"dynamic",href:r,rel:"stylesheet",as:"style",nonce:t.nonce},e):((0,i.preload)(r,{as:"script",fetchPriority:"low",nonce:t.nonce}),null)})})}},84929,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return u}});let n=e.r(20314),i=e.r(79054),o=e.r(83241),a=e.r(31218);function s(e){return{default:e&&"default"in e?e.default:e}}let l={loader:()=>Promise.resolve(s(()=>null)),loading:null,ssr:!0},u=function(e){let t={...l,...e},r=(0,i.lazy)(()=>t.loader().then(s)),u=t.loading;function c(e){let s=u?(0,n.jsx)(u,{isLoading:!0,pastDelay:!0,error:null}):null,l=!t.ssr||!!t.loading,c=l?i.Suspense:i.Fragment,d=t.ssr?(0,n.jsxs)(n.Fragment,{children:["u"<typeof window?(0,n.jsx)(a.PreloadChunks,{moduleIds:t.modules}):null,(0,n.jsx)(r,{...e})]}):(0,n.jsx)(o.BailoutToCSR,{reason:"next/dynamic",children:(0,n.jsx)(r,{...e})});return(0,n.jsx)(c,{...l?{fallback:s}:{},children:d})}return c.displayName="LoadableComponent",c}},47901,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return i}});let n=e.r(81258)._(e.r(84929));function i(e,t){let r={};"function"==typeof e&&(r.loader=e);let i={...r,...t};return(0,n.default)({...i,modules:i.loadableGenerated?.modules})}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},13322,61201,e=>{"use strict";var t=e.i(20314),r=e.i(79054),n=e.i(47901),i=e.i(83428),o=e.i(60112),a=e.i(2287),s=e.i(35364);let l=(0,n.default)(()=>e.A(89305).then(e=>e.FileManager),{loadableGenerated:{modules:[15567]},ssr:!1,loading:()=>(0,t.jsx)(u,{})});function u(){return(0,t.jsx)("div",{className:"flex h-full w-full items-center justify-center",children:(0,t.jsx)(i.Loader2,{className:"text-muted-foreground h-8 w-8 animate-spin"})})}async function c(e){let t=new URLSearchParams;e&&t.set("path",e);let r=await fetch(`/api/directory/list?${t.toString()}`);if(!r.ok)throw Error((await r.json().catch(()=>({error:"Failed to load directory"}))).error??"Failed to load directory");return r.json()}function d({open:e,onOpenChange:n,onSelect:i,initialPath:u}){let[d,f]=(0,r.useState)([]),[p,h]=(0,r.useState)(""),[y,m]=(0,r.useState)(!1),[g,v]=(0,r.useState)(null),b=(0,r.useRef)(!1),x=(0,r.useCallback)(async e=>{m(!0),v(null);try{let t=await c(e);f(t.entries),h(t.currentPath)}catch(t){let e=t instanceof Error?t.message:"Failed to load directory";o.toast.error(e)}finally{m(!1)}},[]);(0,r.useEffect)(()=>{e&&!b.current&&(b.current=!0,x(u)),e||(b.current=!1)},[e,u,x]);let w=(0,r.useCallback)(e=>{let t=e.absolutePath;e.isDirectory&&t&&x(t)},[x]),k=(0,r.useCallback)(e=>{1===e.length&&e[0].isDirectory?v(e[0].absolutePath??null):v(null)},[]);function j(){i(null),n(!1)}return(0,t.jsx)(a.Dialog,{open:e,onOpenChange:e=>{e||j()},children:(0,t.jsxs)(a.DialogContent,{className:"flex h-[95dvh] max-w-[95vw] flex-col",onCloseAutoFocus:e=>e.preventDefault(),children:[(0,t.jsxs)(a.DialogHeader,{children:[(0,t.jsx)(a.DialogTitle,{children:"Select Folder"}),(0,t.jsx)(a.DialogDescription,{className:"truncate font-mono text-xs",children:p||"Loading..."})]}),(0,t.jsx)("div",{className:"shep-file-manager min-h-0 flex-1 overflow-hidden rounded-md border",children:(0,t.jsx)(l,{files:d.map(e=>({name:e.name,isDirectory:!0,path:`/${e.name}`,absolutePath:e.path,updatedAt:e.updatedAt})),isLoading:y,height:"100%",width:"100%",layout:"list",enableFilePreview:!1,permissions:{upload:!1,delete:!1,create:!1,download:!1,copy:!1,move:!1,rename:!1},onFileOpen:w,onSelectionChange:k,onRefresh:()=>x(p)},p)}),(0,t.jsxs)(a.DialogFooter,{children:[(0,t.jsx)(s.Button,{variant:"outline",onClick:j,children:"Cancel"}),(0,t.jsx)(s.Button,{variant:"secondary",onClick:function(){p&&(i(p),n(!1))},disabled:!p,children:"Select Current Folder"}),(0,t.jsx)(s.Button,{onClick:function(){g&&(i(g),n(!1))},disabled:!g,children:"Select Folder"})]})]})})}e.s(["ReactFileManagerDialog",()=>d],61201),e.s([],13322)},78521,e=>{"use strict";var t=e.i(21023);let r=(0,t.createServerReference)("00e1e11607e431aa191317334111361bf74393293f",t.callServer,void 0,t.findSourceMapURL,"pickFolder");async function n(){let e=await r();if(e.error)throw Error(e.error);return e.path}e.s(["pickFolder",()=>n],78521)},91925,e=>{"use strict";let t=(0,e.i(3645).default)("folder-plus",[["path",{d:"M12 10v6",key:"1bos4e"}],["path",{d:"M9 13h6",key:"1uhe8q"}],["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"}]]);e.s(["FolderPlus",()=>t],91925)},76314,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={assign:function(){return l},searchParamsToUrlQuery:function(){return o},urlQueryToSearchParams:function(){return s}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});function o(e){let t={};for(let[r,n]of e.entries()){let e=t[r];void 0===e?t[r]=n:Array.isArray(e)?e.push(n):t[r]=[e,n]}return t}function a(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function s(e){let t=new URLSearchParams;for(let[r,n]of Object.entries(e))if(Array.isArray(n))for(let e of n)t.append(r,a(e));else t.set(r,a(n));return t}function l(e,...t){for(let r of t){for(let t of r.keys())e.delete(t);for(let[t,n]of r.entries())e.append(t,n)}return e}},95889,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={formatUrl:function(){return s},formatWithValidation:function(){return u},urlObjectKeys:function(){return l}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});let o=e.r(44066)._(e.r(76314)),a=/https?|ftp|gopher|file/;function s(e){let{auth:t,hostname:r}=e,n=e.protocol||"",i=e.pathname||"",s=e.hash||"",l=e.query||"",u=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?u=t+e.host:r&&(u=t+(~r.indexOf(":")?`[${r}]`:r),e.port&&(u+=":"+e.port)),l&&"object"==typeof l&&(l=String(o.urlQueryToSearchParams(l)));let c=e.search||l&&`?${l}`||"";return n&&!n.endsWith(":")&&(n+=":"),e.slashes||(!n||a.test(n))&&!1!==u?(u="//"+(u||""),i&&"/"!==i[0]&&(i="/"+i)):u||(u=""),s&&"#"!==s[0]&&(s="#"+s),c&&"?"!==c[0]&&(c="?"+c),i=i.replace(/[?#]/g,encodeURIComponent),c=c.replace("#","%23"),`${n}${u}${i}${c}${s}`}let l=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function u(e){return s(e)}},58464,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={DecodeError:function(){return g},MiddlewareNotFoundError:function(){return w},MissingStaticPage:function(){return x},NormalizeError:function(){return v},PageNotFoundError:function(){return b},SP:function(){return y},ST:function(){return m},WEB_VITALS:function(){return o},execOnce:function(){return a},getDisplayName:function(){return d},getLocationOrigin:function(){return u},getURL:function(){return c},isAbsoluteUrl:function(){return l},isResSent:function(){return f},loadGetInitialProps:function(){return h},normalizeRepeatedSlashes:function(){return p},stringifyError:function(){return k}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});let o=["CLS","FCP","FID","INP","LCP","TTFB"];function a(e){let t,r=!1;return(...n)=>(r||(r=!0,t=e(...n)),t)}let s=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,l=e=>s.test(e);function u(){let{protocol:e,hostname:t,port:r}=window.location;return`${e}//${t}${r?":"+r:""}`}function c(){let{href:e}=window.location,t=u();return e.substring(t.length)}function d(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function f(e){return e.finished||e.headersSent}function p(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?`?${t.slice(1).join("?")}`:"")}async function h(e,t){let r=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await h(t.Component,t.ctx)}:{};let n=await e.getInitialProps(t);if(r&&f(r))return n;if(!n)throw Object.defineProperty(Error(`"${d(e)}.getInitialProps()" should resolve to an object. But found "${n}" instead.`),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return n}let y="u">typeof performance,m=y&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class g extends Error{}class v extends Error{}class b extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message=`Cannot find module for page: ${e}`}}class x extends Error{constructor(e,t){super(),this.message=`Failed to load static file for page: ${e} ${t}`}}class w extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function k(e){return JSON.stringify({message:e.message,stack:e.stack})}},51380,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"isLocalURL",{enumerable:!0,get:function(){return o}});let n=e.r(58464),i=e.r(53626);function o(e){if(!(0,n.isAbsoluteUrl)(e))return!0;try{let t=(0,n.getLocationOrigin)(),r=new URL(e,t);return r.origin===t&&(0,i.hasBasePath)(r.pathname)}catch(e){return!1}}},38670,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"errorOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},24035,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={default:function(){return g},useLinkStatus:function(){return b}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});let o=e.r(44066),a=e.r(20314),s=o._(e.r(79054)),l=e.r(95889),u=e.r(18152),c=e.r(80764),d=e.r(58464),f=e.r(99267);e.r(24270);let p=e.r(59624),h=e.r(51380),y=e.r(95555);function m(e){return"string"==typeof e?e:(0,l.formatUrl)(e)}function g(t){var r;let n,i,o,[l,g]=(0,s.useOptimistic)(p.IDLE_LINK_STATUS),b=(0,s.useRef)(null),{href:x,as:w,children:k,prefetch:j=null,passHref:C,replace:S,shallow:P,scroll:R,onClick:E,onMouseEnter:T,onTouchStart:O,legacyBehavior:M=!1,onNavigate:A,ref:_,unstable_dynamicOnHover:F,...L}=t;n=k,M&&("string"==typeof n||"number"==typeof n)&&(n=(0,a.jsx)("a",{children:n}));let I=s.default.useContext(u.AppRouterContext),N=!1!==j,D=!1!==j?null===(r=j)||"auto"===r?y.FetchStrategy.PPR:y.FetchStrategy.Full:y.FetchStrategy.PPR,{href:z,as:U}=s.default.useMemo(()=>{let e=m(x);return{href:e,as:w?m(w):e}},[x,w]);if(M){if(n?.$$typeof===Symbol.for("react.lazy"))throw Object.defineProperty(Error("`<Link legacyBehavior>` received a direct child that is either a Server Component, or JSX that was loaded with React.lazy(). This is not supported. Either remove legacyBehavior, or make the direct child a Client Component that renders the Link's `<a>` tag."),"__NEXT_ERROR_CODE",{value:"E863",enumerable:!1,configurable:!0});i=s.default.Children.only(n)}let $=M?i&&"object"==typeof i&&i.ref:_,B=s.default.useCallback(e=>(null!==I&&(b.current=(0,p.mountLinkInstance)(e,z,I,D,N,g)),()=>{b.current&&((0,p.unmountLinkForCurrentNavigation)(b.current),b.current=null),(0,p.unmountPrefetchableInstance)(e)}),[N,z,I,D,g]),K={ref:(0,c.useMergedRef)(B,$),onClick(t){M||"function"!=typeof E||E(t),M&&i.props&&"function"==typeof i.props.onClick&&i.props.onClick(t),!I||t.defaultPrevented||function(t,r,n,i,o,a,l){if("u">typeof window){let u,{nodeName:c}=t.currentTarget;if("A"===c.toUpperCase()&&((u=t.currentTarget.getAttribute("target"))&&"_self"!==u||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.nativeEvent&&2===t.nativeEvent.which)||t.currentTarget.hasAttribute("download"))return;if(!(0,h.isLocalURL)(r)){o&&(t.preventDefault(),location.replace(r));return}if(t.preventDefault(),l){let e=!1;if(l({preventDefault:()=>{e=!0}}),e)return}let{dispatchNavigateAction:d}=e.r(81574);s.default.startTransition(()=>{d(n||r,o?"replace":"push",a??!0,i.current)})}}(t,z,U,b,S,R,A)},onMouseEnter(e){M||"function"!=typeof T||T(e),M&&i.props&&"function"==typeof i.props.onMouseEnter&&i.props.onMouseEnter(e),I&&N&&(0,p.onNavigationIntent)(e.currentTarget,!0===F)},onTouchStart:function(e){M||"function"!=typeof O||O(e),M&&i.props&&"function"==typeof i.props.onTouchStart&&i.props.onTouchStart(e),I&&N&&(0,p.onNavigationIntent)(e.currentTarget,!0===F)}};return(0,d.isAbsoluteUrl)(U)?K.href=U:M&&!C&&("a"!==i.type||"href"in i.props)||(K.href=(0,f.addBasePath)(U)),o=M?s.default.cloneElement(i,K):(0,a.jsx)("a",{...L,...K,children:n}),(0,a.jsx)(v.Provider,{value:l,children:o})}e.r(38670);let v=(0,s.createContext)(p.IDLE_LINK_STATUS),b=()=>(0,s.useContext)(v);("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},89305,e=>{e.v(t=>Promise.all(["static/chunks/6d7b999c99d6d175.js"].map(t=>e.l(t))).then(()=>t(15567)))}]);
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,24270,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"warnOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},68304,e=>{"use strict";var t=e.i(20314),r=e.i(79054),n=e.i(91967),i=e.i(22528),o=e.i(51080),a=e.i(85995),s=e.i(87620),l=e.i(66033),u=e.i(36589),c=e.i(13123),d="Tabs",[f,p]=(0,i.createContextScope)(d,[o.createRovingFocusGroupScope]),h=(0,o.createRovingFocusGroupScope)(),[y,m]=f(d),g=r.forwardRef((e,r)=>{let{__scopeTabs:n,value:i,onValueChange:o,defaultValue:a,orientation:f="horizontal",dir:p,activationMode:h="automatic",...m}=e,g=(0,l.useDirection)(p),[v,b]=(0,u.useControllableState)({prop:i,onChange:o,defaultProp:a??"",caller:d});return(0,t.jsx)(y,{scope:n,baseId:(0,c.useId)(),value:v,onValueChange:b,orientation:f,dir:g,activationMode:h,children:(0,t.jsx)(s.Primitive.div,{dir:g,"data-orientation":f,...m,ref:r})})});g.displayName=d;var v="TabsList",b=r.forwardRef((e,r)=>{let{__scopeTabs:n,loop:i=!0,...a}=e,l=m(v,n),u=h(n);return(0,t.jsx)(o.Root,{asChild:!0,...u,orientation:l.orientation,dir:l.dir,loop:i,children:(0,t.jsx)(s.Primitive.div,{role:"tablist","aria-orientation":l.orientation,...a,ref:r})})});b.displayName=v;var x="TabsTrigger",w=r.forwardRef((e,r)=>{let{__scopeTabs:i,value:a,disabled:l=!1,...u}=e,c=m(x,i),d=h(i),f=C(c.baseId,a),p=S(c.baseId,a),y=a===c.value;return(0,t.jsx)(o.Item,{asChild:!0,...d,focusable:!l,active:y,children:(0,t.jsx)(s.Primitive.button,{type:"button",role:"tab","aria-selected":y,"aria-controls":p,"data-state":y?"active":"inactive","data-disabled":l?"":void 0,disabled:l,id:f,...u,ref:r,onMouseDown:(0,n.composeEventHandlers)(e.onMouseDown,e=>{l||0!==e.button||!1!==e.ctrlKey?e.preventDefault():c.onValueChange(a)}),onKeyDown:(0,n.composeEventHandlers)(e.onKeyDown,e=>{[" ","Enter"].includes(e.key)&&c.onValueChange(a)}),onFocus:(0,n.composeEventHandlers)(e.onFocus,()=>{let e="manual"!==c.activationMode;y||l||!e||c.onValueChange(a)})})})});w.displayName=x;var k="TabsContent",j=r.forwardRef((e,n)=>{let{__scopeTabs:i,value:o,forceMount:l,children:u,...c}=e,d=m(k,i),f=C(d.baseId,o),p=S(d.baseId,o),h=o===d.value,y=r.useRef(h);return r.useEffect(()=>{let e=requestAnimationFrame(()=>y.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,t.jsx)(a.Presence,{present:l||h,children:({present:r})=>(0,t.jsx)(s.Primitive.div,{"data-state":h?"active":"inactive","data-orientation":d.orientation,role:"tabpanel","aria-labelledby":f,hidden:!r,id:p,tabIndex:0,...c,ref:n,style:{...e.style,animationDuration:y.current?"0s":void 0},children:r&&u})})});function C(e,t){return`${e}-trigger-${t}`}function S(e,t){return`${e}-content-${t}`}j.displayName=k,e.s(["Content",()=>j,"List",()=>b,"Root",()=>g,"Tabs",()=>g,"TabsContent",()=>j,"TabsList",()=>b,"TabsTrigger",()=>w,"Trigger",()=>w,"createTabsScope",()=>p],43133);var P=e.i(43133),P=P,R=e.i(31777);let E=P.Root,T=r.forwardRef(({className:e,...r},n)=>(0,t.jsx)(P.List,{ref:n,className:(0,R.cn)("bg-muted text-muted-foreground inline-flex h-9 items-center justify-center rounded-lg p-1",e),...r}));T.displayName=P.List.displayName;let O=r.forwardRef(({className:e,...r},n)=>(0,t.jsx)(P.Trigger,{ref:n,className:(0,R.cn)("ring-offset-background focus-visible:ring-ring data-[state=active]:bg-background data-[state=active]:text-foreground inline-flex items-center justify-center rounded-md px-3 py-1 text-sm font-medium whitespace-nowrap transition-all focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow",e),...r}));O.displayName=P.Trigger.displayName;let M=r.forwardRef(({className:e,...r},n)=>(0,t.jsx)(P.Content,{ref:n,className:(0,R.cn)("ring-offset-background focus-visible:ring-ring mt-2 focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",e),...r}));M.displayName=P.Content.displayName,e.s(["Tabs",()=>E,"TabsContent",()=>M,"TabsList",()=>T,"TabsTrigger",()=>O],68304)},10942,94819,e=>{"use strict";var t=e.i(80986);e.s(["CircleCheck",()=>t.default],10942);let r=(0,e.i(3645).default)("ban",[["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);e.s(["Ban",()=>r],94819)},32494,e=>{"use strict";let t=(0,e.i(3645).default)("globe",[["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"}]]);e.s(["Globe",()=>t],32494)},79687,e=>{"use strict";var t=e.i(14748);e.s(["AlertCircle",()=>t.default])},39443,e=>{"use strict";var t=e.i(20314),r=e.i(79054);let n=(0,e.i(18354).createLogger)("[SSE]");function i(e,t,r,n){if("u"<typeof EventSource)return()=>{};let i=null,o=!1,a=1e3,s=null,l=null;return!function u(){o||(i=new EventSource(e?`/api/agent-events?runId=${encodeURIComponent(e)}`:"/api/agent-events"),n("connecting"),i.onopen=()=>{n("connected"),l=setTimeout(()=>{l=null,a=1e3},5e3)},i.onerror=()=>{i?.close(),i=null,n("disconnected"),null!==l&&(clearTimeout(l),l=null);let e=a;a=Math.min(2*e,3e4),s=setTimeout(()=>{s=null,u()},e)},i.addEventListener("notification",e=>{let n=JSON.parse(e.data);t(e=>{let t=[...e,n];return t.length>500?t.slice(-250):t}),r(n)}))}(),()=>{o=!0,null!==s&&(clearTimeout(s),s=null),null!==l&&(clearTimeout(l),l=null),i&&(i.close(),i=null)}}let o=(0,r.createContext)(null);function a({children:e,runId:a}){let{events:s,lastEvent:l,connectionStatus:u}=function(e){let[t,o]=(0,r.useState)([]),[a,s]=(0,r.useState)(null),[l,u]=(0,r.useState)("disconnected"),c=e?.runId,d=(0,r.useRef)(null),f=(0,r.useCallback)(e=>{let t=e.data;if(t&&"object"==typeof t)if("notification"===t.type){let e=t.data;n.debug("event received:",e.eventType,e),o(t=>{let r=[...t,e];return r.length>500?r.slice(-250):r}),s(e)}else"status"===t.type&&u(t.status)},[]);return(0,r.useEffect)(()=>{let e="u">typeof location&&new URLSearchParams(location.search).has("sse");if(!navigator.serviceWorker||e)return i(c,o,s,u);let t=!1,r={current:void 0};function n(e){t||(d.current=e,e.postMessage({type:"subscribe",runId:c}),u("connecting"))}function a(){if(t)return;let e=navigator.serviceWorker.controller;e&&(d.current=e,e.postMessage({type:"subscribe",runId:c}),u("connecting"))}return navigator.serviceWorker.addEventListener("message",f),navigator.serviceWorker.addEventListener("controllerchange",a),navigator.serviceWorker.register("/agent-events-sw.js",{scope:"/"}).then(e=>{if(t)return;let a=e.active??e.installing??e.waiting;if(!a){r.current=i(c,o,s,u);return}if("activated"===a.state)n(a);else{let e=()=>{"activated"===a.state&&(a.removeEventListener("statechange",e),n(a))};a.addEventListener("statechange",e)}}).catch(()=>{t||(r.current=i(c,o,s,u))}),()=>{t=!0,navigator.serviceWorker.removeEventListener("message",f),navigator.serviceWorker.removeEventListener("controllerchange",a),d.current?.postMessage({type:"unsubscribe"}),d.current=null,r.current?.()}},[c,f]),{events:t,lastEvent:a,connectionStatus:l}}({runId:a}),c=(0,r.useMemo)(()=>({events:s,lastEvent:l,connectionStatus:u}),[s,l,u]);return(0,t.jsx)(o.Provider,{value:c,children:e})}function s(){let e=(0,r.useContext)(o);if(!e)throw Error("useAgentEventsContext must be used within an <AgentEventsProvider>");return e}e.s(["AgentEventsProvider",()=>a,"useAgentEventsContext",()=>s],39443)},3214,e=>{"use strict";let t=(0,e.i(3645).default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",()=>t],3214)},80986,e=>{"use strict";let t=(0,e.i(3645).default)("circle-check",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);e.s(["default",()=>t])},54277,30090,e=>{"use strict";let t=(0,e.i(3645).default)("circle-x",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);e.s(["default",()=>t],30090),e.s(["CircleX",()=>t],54277)},51080,e=>{"use strict";var t=e.i(79054),r=e.i(91967),n=e.i(87342),i=e.i(5978),o=e.i(22528),a=e.i(13123),s=e.i(87620),l=e.i(29297),u=e.i(36589),c=e.i(66033),d=e.i(20314),f="rovingFocusGroup.onEntryFocus",p={bubbles:!1,cancelable:!0},h="RovingFocusGroup",[y,m,g]=(0,n.createCollection)(h),[v,b]=(0,o.createContextScope)(h,[g]),[x,w]=v(h),k=t.forwardRef((e,t)=>(0,d.jsx)(y.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,d.jsx)(y.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,d.jsx)(j,{...e,ref:t})})}));k.displayName=h;var j=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:o,orientation:a,loop:y=!1,dir:g,currentTabStopId:v,defaultCurrentTabStopId:b,onCurrentTabStopIdChange:w,onEntryFocus:k,preventScrollOnEntryFocus:j=!1,...C}=e,S=t.useRef(null),P=(0,i.useComposedRefs)(n,S),E=(0,c.useDirection)(g),[T,O]=(0,u.useControllableState)({prop:v,defaultProp:b??null,onChange:w,caller:h}),[M,A]=t.useState(!1),_=(0,l.useCallbackRef)(k),F=m(o),L=t.useRef(!1),[I,N]=t.useState(0);return t.useEffect(()=>{let e=S.current;if(e)return e.addEventListener(f,_),()=>e.removeEventListener(f,_)},[_]),(0,d.jsx)(x,{scope:o,orientation:a,dir:E,loop:y,currentTabStopId:T,onItemFocus:t.useCallback(e=>O(e),[O]),onItemShiftTab:t.useCallback(()=>A(!0),[]),onFocusableItemAdd:t.useCallback(()=>N(e=>e+1),[]),onFocusableItemRemove:t.useCallback(()=>N(e=>e-1),[]),children:(0,d.jsx)(s.Primitive.div,{tabIndex:M||0===I?-1:0,"data-orientation":a,...C,ref:P,style:{outline:"none",...e.style},onMouseDown:(0,r.composeEventHandlers)(e.onMouseDown,()=>{L.current=!0}),onFocus:(0,r.composeEventHandlers)(e.onFocus,e=>{let t=!L.current;if(e.target===e.currentTarget&&t&&!M){let t=new CustomEvent(f,p);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=F().filter(e=>e.focusable);R([e.find(e=>e.active),e.find(e=>e.id===T),...e].filter(Boolean).map(e=>e.ref.current),j)}}L.current=!1}),onBlur:(0,r.composeEventHandlers)(e.onBlur,()=>A(!1))})})}),C="RovingFocusGroupItem",S=t.forwardRef((e,n)=>{let{__scopeRovingFocusGroup:i,focusable:o=!0,active:l=!1,tabStopId:u,children:c,...f}=e,p=(0,a.useId)(),h=u||p,g=w(C,i),v=g.currentTabStopId===h,b=m(i),{onFocusableItemAdd:x,onFocusableItemRemove:k,currentTabStopId:j}=g;return t.useEffect(()=>{if(o)return x(),()=>k()},[o,x,k]),(0,d.jsx)(y.ItemSlot,{scope:i,id:h,focusable:o,active:l,children:(0,d.jsx)(s.Primitive.span,{tabIndex:v?0:-1,"data-orientation":g.orientation,...f,ref:n,onMouseDown:(0,r.composeEventHandlers)(e.onMouseDown,e=>{o?g.onItemFocus(h):e.preventDefault()}),onFocus:(0,r.composeEventHandlers)(e.onFocus,()=>g.onItemFocus(h)),onKeyDown:(0,r.composeEventHandlers)(e.onKeyDown,e=>{if("Tab"===e.key&&e.shiftKey)return void g.onItemShiftTab();if(e.target!==e.currentTarget)return;let t=function(e,t,r){var n;let i=(n=e.key,"rtl"!==r?n:"ArrowLeft"===n?"ArrowRight":"ArrowRight"===n?"ArrowLeft":n);if(!("vertical"===t&&["ArrowLeft","ArrowRight"].includes(i))&&!("horizontal"===t&&["ArrowUp","ArrowDown"].includes(i)))return P[i]}(e,g.orientation,g.dir);if(void 0!==t){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let i=b().filter(e=>e.focusable).map(e=>e.ref.current);if("last"===t)i.reverse();else if("prev"===t||"next"===t){var r,n;"prev"===t&&i.reverse();let o=i.indexOf(e.currentTarget);i=g.loop?(r=i,n=o+1,r.map((e,t)=>r[(n+t)%r.length])):i.slice(o+1)}setTimeout(()=>R(i))}}),children:"function"==typeof c?c({isCurrentTabStop:v,hasTabStop:null!=j}):c})})});S.displayName=C;var P={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function R(e,t=!1){let r=document.activeElement;for(let n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}e.s(["Item",()=>S,"Root",()=>k,"createRovingFocusGroupScope",()=>b])},49228,e=>{"use strict";let t=(0,e.i(3645).default)("git-branch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);e.s(["GitBranch",()=>t],49228)},66033,e=>{"use strict";var t=e.i(79054);e.i(20314);var r=t.createContext(void 0);function n(e){let n=t.useContext(r);return e||n||"ltr"}e.s(["useDirection",()=>n])},87342,e=>{"use strict";var t=e.i(79054),r=e.i(22528),n=e.i(5978),i=e.i(86874),o=e.i(20314);function a(e){let a=e+"CollectionProvider",[s,l]=(0,r.createContextScope)(a),[u,c]=s(a,{collectionRef:{current:null},itemMap:new Map}),d=e=>{let{scope:r,children:n}=e,i=t.default.useRef(null),a=t.default.useRef(new Map).current;return(0,o.jsx)(u,{scope:r,itemMap:a,collectionRef:i,children:n})};d.displayName=a;let f=e+"CollectionSlot",p=(0,i.createSlot)(f),h=t.default.forwardRef((e,t)=>{let{scope:r,children:i}=e,a=c(f,r),s=(0,n.useComposedRefs)(t,a.collectionRef);return(0,o.jsx)(p,{ref:s,children:i})});h.displayName=f;let y=e+"CollectionItemSlot",m="data-radix-collection-item",g=(0,i.createSlot)(y),v=t.default.forwardRef((e,r)=>{let{scope:i,children:a,...s}=e,l=t.default.useRef(null),u=(0,n.useComposedRefs)(r,l),d=c(y,i);return t.default.useEffect(()=>(d.itemMap.set(l,{ref:l,...s}),()=>void d.itemMap.delete(l))),(0,o.jsx)(g,{...{[m]:""},ref:u,children:a})});return v.displayName=y,[{Provider:d,Slot:h,ItemSlot:v},function(r){let n=c(e+"CollectionConsumer",r);return t.default.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${m}]`));return Array.from(n.itemMap.values()).sort((e,r)=>t.indexOf(e.ref.current)-t.indexOf(r.ref.current))},[n.collectionRef,n.itemMap])},l]}var s=new WeakMap;function l(e,t){var r,n;let i,o,a;if("at"in Array.prototype)return Array.prototype.at.call(e,t);let s=(r=e,n=t,i=r.length,(a=(o=u(n))>=0?o:i+o)<0||a>=i?-1:a);return -1===s?void 0:e[s]}function u(e){return e!=e||0===e?0:Math.trunc(e)}(class e extends Map{#e;constructor(e){super(e),this.#e=[...super.keys()],s.set(this,!0)}set(e,t){return s.get(this)&&(this.has(e)?this.#e[this.#e.indexOf(e)]=e:this.#e.push(e)),super.set(e,t),this}insert(e,t,r){let n,i=this.has(t),o=this.#e.length,a=u(e),s=a>=0?a:o+a,l=s<0||s>=o?-1:s;if(l===this.size||i&&l===this.size-1||-1===l)return this.set(t,r),this;let c=this.size+ +!i;a<0&&s++;let d=[...this.#e],f=!1;for(let e=s;e<c;e++)if(s===e){let o=d[e];d[e]===t&&(o=d[e+1]),i&&this.delete(t),n=this.get(o),this.set(t,r)}else{f||d[e-1]!==t||(f=!0);let r=d[f?e:e-1],i=n;n=this.get(r),this.delete(r),this.set(r,i)}return this}with(t,r,n){let i=new e(this);return i.insert(t,r,n),i}before(e){let t=this.#e.indexOf(e)-1;if(!(t<0))return this.entryAt(t)}setBefore(e,t,r){let n=this.#e.indexOf(e);return -1===n?this:this.insert(n,t,r)}after(e){let t=this.#e.indexOf(e);if(-1!==(t=-1===t||t===this.size-1?-1:t+1))return this.entryAt(t)}setAfter(e,t,r){let n=this.#e.indexOf(e);return -1===n?this:this.insert(n+1,t,r)}first(){return this.entryAt(0)}last(){return this.entryAt(-1)}clear(){return this.#e=[],super.clear()}delete(e){let t=super.delete(e);return t&&this.#e.splice(this.#e.indexOf(e),1),t}deleteAt(e){let t=this.keyAt(e);return void 0!==t&&this.delete(t)}at(e){let t=l(this.#e,e);if(void 0!==t)return this.get(t)}entryAt(e){let t=l(this.#e,e);if(void 0!==t)return[t,this.get(t)]}indexOf(e){return this.#e.indexOf(e)}keyAt(e){return l(this.#e,e)}from(e,t){let r=this.indexOf(e);if(-1===r)return;let n=r+t;return n<0&&(n=0),n>=this.size&&(n=this.size-1),this.at(n)}keyFrom(e,t){let r=this.indexOf(e);if(-1===r)return;let n=r+t;return n<0&&(n=0),n>=this.size&&(n=this.size-1),this.keyAt(n)}find(e,t){let r=0;for(let n of this){if(Reflect.apply(e,t,[n,r,this]))return n;r++}}findIndex(e,t){let r=0;for(let n of this){if(Reflect.apply(e,t,[n,r,this]))return r;r++}return -1}filter(t,r){let n=[],i=0;for(let e of this)Reflect.apply(t,r,[e,i,this])&&n.push(e),i++;return new e(n)}map(t,r){let n=[],i=0;for(let e of this)n.push([e[0],Reflect.apply(t,r,[e,i,this])]),i++;return new e(n)}reduce(...e){let[t,r]=e,n=0,i=r??this.at(0);for(let r of this)i=0===n&&1===e.length?r:Reflect.apply(t,this,[i,r,n,this]),n++;return i}reduceRight(...e){let[t,r]=e,n=r??this.at(-1);for(let r=this.size-1;r>=0;r--){let i=this.at(r);n=r===this.size-1&&1===e.length?i:Reflect.apply(t,this,[n,i,r,this])}return n}toSorted(t){return new e([...this.entries()].sort(t))}toReversed(){let t=new e;for(let e=this.size-1;e>=0;e--){let r=this.keyAt(e),n=this.get(r);t.set(r,n)}return t}toSpliced(...t){let r=[...this.entries()];return r.splice(...t),new e(r)}slice(t,r){let n=new e,i=this.size-1;if(void 0===t)return n;t<0&&(t+=this.size),void 0!==r&&r>0&&(i=r-1);for(let e=t;e<=i;e++){let t=this.keyAt(e),r=this.get(t);n.set(t,r)}return n}every(e,t){let r=0;for(let n of this){if(!Reflect.apply(e,t,[n,r,this]))return!1;r++}return!0}some(e,t){let r=0;for(let n of this){if(Reflect.apply(e,t,[n,r,this]))return!0;r++}return!1}}),e.s(["createCollection",()=>a])},27069,e=>{"use strict";function t(e,[t,r]){return Math.min(r,Math.max(t,e))}e.s(["clamp",()=>t])},81975,e=>{"use strict";let t=(0,e.i(3645).default)("wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]);e.s(["Wrench",()=>t],81975)},82569,5147,e=>{"use strict";let t=(0,e.i(3645).default)("github",[["path",{d:"M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4",key:"tonef"}],["path",{d:"M9 18c-4.51 2-5-2-7-2",key:"9comsn"}]]);e.s(["Github",()=>t],82569);var r=e.i(20314),n=e.i(79054);let i={"action-required":"action-needed",running:"in-progress",done:"done",blocked:"blocked",pending:"pending",error:"error",creating:null,deleting:null,archived:null};function o(e){return i[e]}let a=(0,n.createContext)(null);function s({children:e}){let[t,i]=(0,n.useState)([]),[o,s]=(0,n.useState)(!1),l=(0,n.useMemo)(()=>({features:t,setFeatures:i,hasRepositories:o,setHasRepositories:s}),[t,o]);return(0,r.jsx)(a.Provider,{value:l,children:e})}function l(){let e=(0,n.useContext)(a);if(!e)throw Error("useSidebarFeaturesContext must be used within a <SidebarFeaturesProvider>");return e}e.s(["SidebarFeaturesProvider",()=>s,"mapNodeStateToSidebarStatus",()=>o,"useSidebarFeaturesContext",()=>l],5147)},98127,e=>{"use strict";var t=e.i(20314),r=e.i(31777);function n({className:e,type:n,...i}){return(0,t.jsx)("input",{type:n,"data-slot":"input",className:(0,r.cn)("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",e),...i})}e.s(["Input",()=>n])},66459,e=>{"use strict";let t=(0,e.i(3645).default)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]);e.s(["Search",()=>t],66459)},12103,e=>{"use strict";let t=(0,e.i(3645).default)("puzzle",[["path",{d:"M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",key:"w46dr5"}]]);e.s(["Puzzle",()=>t],12103)},83241,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"BailoutToCSR",{enumerable:!0,get:function(){return i}});let n=e.r(9328);function i({reason:e,children:t}){if("u"<typeof window)throw Object.defineProperty(new n.BailoutToCSRError(e),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return t}},90891,(e,t,r)=>{"use strict";function n(e){return e.split("/").map(e=>encodeURIComponent(e)).join("/")}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"encodeURIPath",{enumerable:!0,get:function(){return n}})},31218,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"PreloadChunks",{enumerable:!0,get:function(){return l}});let n=e.r(20314),i=e.r(26036),o=e.r(58988),a=e.r(90891),s=e.r(22193);function l({moduleIds:e}){if("u">typeof window)return null;let t=o.workAsyncStorage.getStore();if(void 0===t)return null;let r=[];if(t.reactLoadableManifest&&e){let n=t.reactLoadableManifest;for(let t of e){if(!n[t])continue;let e=n[t].files;r.push(...e)}}if(0===r.length)return null;let l=(0,s.getDeploymentIdQueryOrEmptyString)();return(0,n.jsx)(n.Fragment,{children:r.map(e=>{let r=`${t.assetPrefix}/_next/${(0,a.encodeURIPath)(e)}${l}`;return e.endsWith(".css")?(0,n.jsx)("link",{precedence:"dynamic",href:r,rel:"stylesheet",as:"style",nonce:t.nonce},e):((0,i.preload)(r,{as:"script",fetchPriority:"low",nonce:t.nonce}),null)})})}},84929,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return u}});let n=e.r(20314),i=e.r(79054),o=e.r(83241),a=e.r(31218);function s(e){return{default:e&&"default"in e?e.default:e}}let l={loader:()=>Promise.resolve(s(()=>null)),loading:null,ssr:!0},u=function(e){let t={...l,...e},r=(0,i.lazy)(()=>t.loader().then(s)),u=t.loading;function c(e){let s=u?(0,n.jsx)(u,{isLoading:!0,pastDelay:!0,error:null}):null,l=!t.ssr||!!t.loading,c=l?i.Suspense:i.Fragment,d=t.ssr?(0,n.jsxs)(n.Fragment,{children:["u"<typeof window?(0,n.jsx)(a.PreloadChunks,{moduleIds:t.modules}):null,(0,n.jsx)(r,{...e})]}):(0,n.jsx)(o.BailoutToCSR,{reason:"next/dynamic",children:(0,n.jsx)(r,{...e})});return(0,n.jsx)(c,{...l?{fallback:s}:{},children:d})}return c.displayName="LoadableComponent",c}},47901,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return i}});let n=e.r(81258)._(e.r(84929));function i(e,t){let r={};"function"==typeof e&&(r.loader=e);let i={...r,...t};return(0,n.default)({...i,modules:i.loadableGenerated?.modules})}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},13322,61201,e=>{"use strict";var t=e.i(20314),r=e.i(79054),n=e.i(47901),i=e.i(83428),o=e.i(60112),a=e.i(2287),s=e.i(35364);let l=(0,n.default)(()=>e.A(89305).then(e=>e.FileManager),{loadableGenerated:{modules:[15567]},ssr:!1,loading:()=>(0,t.jsx)(u,{})});function u(){return(0,t.jsx)("div",{className:"flex h-full w-full items-center justify-center",children:(0,t.jsx)(i.Loader2,{className:"text-muted-foreground h-8 w-8 animate-spin"})})}async function c(e){let t=new URLSearchParams;e&&t.set("path",e);let r=await fetch(`/api/directory/list?${t.toString()}`);if(!r.ok)throw Error((await r.json().catch(()=>({error:"Failed to load directory"}))).error??"Failed to load directory");return r.json()}function d({open:e,onOpenChange:n,onSelect:i,initialPath:u}){let[d,f]=(0,r.useState)([]),[p,h]=(0,r.useState)(""),[y,m]=(0,r.useState)(!1),[g,v]=(0,r.useState)(null),b=(0,r.useRef)(!1),x=(0,r.useCallback)(async e=>{m(!0),v(null);try{let t=await c(e);f(t.entries),h(t.currentPath)}catch(t){let e=t instanceof Error?t.message:"Failed to load directory";o.toast.error(e)}finally{m(!1)}},[]);(0,r.useEffect)(()=>{e&&!b.current&&(b.current=!0,x(u)),e||(b.current=!1)},[e,u,x]);let w=(0,r.useCallback)(e=>{let t=e.absolutePath;e.isDirectory&&t&&x(t)},[x]),k=(0,r.useCallback)(e=>{1===e.length&&e[0].isDirectory?v(e[0].absolutePath??null):v(null)},[]);function j(){i(null),n(!1)}return(0,t.jsx)(a.Dialog,{open:e,onOpenChange:e=>{e||j()},children:(0,t.jsxs)(a.DialogContent,{className:"flex h-[95dvh] max-w-[95vw] flex-col",onCloseAutoFocus:e=>e.preventDefault(),children:[(0,t.jsxs)(a.DialogHeader,{children:[(0,t.jsx)(a.DialogTitle,{children:"Select Folder"}),(0,t.jsx)(a.DialogDescription,{className:"truncate font-mono text-xs",children:p||"Loading..."})]}),(0,t.jsx)("div",{className:"shep-file-manager min-h-0 flex-1 overflow-hidden rounded-md border",children:(0,t.jsx)(l,{files:d.map(e=>({name:e.name,isDirectory:!0,path:`/${e.name}`,absolutePath:e.path,updatedAt:e.updatedAt})),isLoading:y,height:"100%",width:"100%",layout:"list",enableFilePreview:!1,permissions:{upload:!1,delete:!1,create:!1,download:!1,copy:!1,move:!1,rename:!1},onFileOpen:w,onSelectionChange:k,onRefresh:()=>x(p)},p)}),(0,t.jsxs)(a.DialogFooter,{children:[(0,t.jsx)(s.Button,{variant:"outline",onClick:j,children:"Cancel"}),(0,t.jsx)(s.Button,{variant:"secondary",onClick:function(){p&&(i(p),n(!1))},disabled:!p,children:"Select Current Folder"}),(0,t.jsx)(s.Button,{onClick:function(){g&&(i(g),n(!1))},disabled:!g,children:"Select Folder"})]})]})})}e.s(["ReactFileManagerDialog",()=>d],61201),e.s([],13322)},78521,e=>{"use strict";var t=e.i(21023);let r=(0,t.createServerReference)("000cadf83786639a64ccb5d3098d28a3f6d9f4be06",t.callServer,void 0,t.findSourceMapURL,"pickFolder");async function n(){let e=await r();if(e.error)throw Error(e.error);return e.path}e.s(["pickFolder",()=>n],78521)},91925,e=>{"use strict";let t=(0,e.i(3645).default)("folder-plus",[["path",{d:"M12 10v6",key:"1bos4e"}],["path",{d:"M9 13h6",key:"1uhe8q"}],["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"}]]);e.s(["FolderPlus",()=>t],91925)},76314,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={assign:function(){return l},searchParamsToUrlQuery:function(){return o},urlQueryToSearchParams:function(){return s}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});function o(e){let t={};for(let[r,n]of e.entries()){let e=t[r];void 0===e?t[r]=n:Array.isArray(e)?e.push(n):t[r]=[e,n]}return t}function a(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function s(e){let t=new URLSearchParams;for(let[r,n]of Object.entries(e))if(Array.isArray(n))for(let e of n)t.append(r,a(e));else t.set(r,a(n));return t}function l(e,...t){for(let r of t){for(let t of r.keys())e.delete(t);for(let[t,n]of r.entries())e.append(t,n)}return e}},95889,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={formatUrl:function(){return s},formatWithValidation:function(){return u},urlObjectKeys:function(){return l}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});let o=e.r(44066)._(e.r(76314)),a=/https?|ftp|gopher|file/;function s(e){let{auth:t,hostname:r}=e,n=e.protocol||"",i=e.pathname||"",s=e.hash||"",l=e.query||"",u=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?u=t+e.host:r&&(u=t+(~r.indexOf(":")?`[${r}]`:r),e.port&&(u+=":"+e.port)),l&&"object"==typeof l&&(l=String(o.urlQueryToSearchParams(l)));let c=e.search||l&&`?${l}`||"";return n&&!n.endsWith(":")&&(n+=":"),e.slashes||(!n||a.test(n))&&!1!==u?(u="//"+(u||""),i&&"/"!==i[0]&&(i="/"+i)):u||(u=""),s&&"#"!==s[0]&&(s="#"+s),c&&"?"!==c[0]&&(c="?"+c),i=i.replace(/[?#]/g,encodeURIComponent),c=c.replace("#","%23"),`${n}${u}${i}${c}${s}`}let l=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function u(e){return s(e)}},58464,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={DecodeError:function(){return g},MiddlewareNotFoundError:function(){return w},MissingStaticPage:function(){return x},NormalizeError:function(){return v},PageNotFoundError:function(){return b},SP:function(){return y},ST:function(){return m},WEB_VITALS:function(){return o},execOnce:function(){return a},getDisplayName:function(){return d},getLocationOrigin:function(){return u},getURL:function(){return c},isAbsoluteUrl:function(){return l},isResSent:function(){return f},loadGetInitialProps:function(){return h},normalizeRepeatedSlashes:function(){return p},stringifyError:function(){return k}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});let o=["CLS","FCP","FID","INP","LCP","TTFB"];function a(e){let t,r=!1;return(...n)=>(r||(r=!0,t=e(...n)),t)}let s=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,l=e=>s.test(e);function u(){let{protocol:e,hostname:t,port:r}=window.location;return`${e}//${t}${r?":"+r:""}`}function c(){let{href:e}=window.location,t=u();return e.substring(t.length)}function d(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function f(e){return e.finished||e.headersSent}function p(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?`?${t.slice(1).join("?")}`:"")}async function h(e,t){let r=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await h(t.Component,t.ctx)}:{};let n=await e.getInitialProps(t);if(r&&f(r))return n;if(!n)throw Object.defineProperty(Error(`"${d(e)}.getInitialProps()" should resolve to an object. But found "${n}" instead.`),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return n}let y="u">typeof performance,m=y&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class g extends Error{}class v extends Error{}class b extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message=`Cannot find module for page: ${e}`}}class x extends Error{constructor(e,t){super(),this.message=`Failed to load static file for page: ${e} ${t}`}}class w extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function k(e){return JSON.stringify({message:e.message,stack:e.stack})}},51380,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"isLocalURL",{enumerable:!0,get:function(){return o}});let n=e.r(58464),i=e.r(53626);function o(e){if(!(0,n.isAbsoluteUrl)(e))return!0;try{let t=(0,n.getLocationOrigin)(),r=new URL(e,t);return r.origin===t&&(0,i.hasBasePath)(r.pathname)}catch(e){return!1}}},38670,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"errorOnce",{enumerable:!0,get:function(){return n}});let n=e=>{}},24035,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n={default:function(){return g},useLinkStatus:function(){return b}};for(var i in n)Object.defineProperty(r,i,{enumerable:!0,get:n[i]});let o=e.r(44066),a=e.r(20314),s=o._(e.r(79054)),l=e.r(95889),u=e.r(18152),c=e.r(80764),d=e.r(58464),f=e.r(99267);e.r(24270);let p=e.r(59624),h=e.r(51380),y=e.r(95555);function m(e){return"string"==typeof e?e:(0,l.formatUrl)(e)}function g(t){var r;let n,i,o,[l,g]=(0,s.useOptimistic)(p.IDLE_LINK_STATUS),b=(0,s.useRef)(null),{href:x,as:w,children:k,prefetch:j=null,passHref:C,replace:S,shallow:P,scroll:R,onClick:E,onMouseEnter:T,onTouchStart:O,legacyBehavior:M=!1,onNavigate:A,ref:_,unstable_dynamicOnHover:F,...L}=t;n=k,M&&("string"==typeof n||"number"==typeof n)&&(n=(0,a.jsx)("a",{children:n}));let I=s.default.useContext(u.AppRouterContext),N=!1!==j,D=!1!==j?null===(r=j)||"auto"===r?y.FetchStrategy.PPR:y.FetchStrategy.Full:y.FetchStrategy.PPR,{href:z,as:U}=s.default.useMemo(()=>{let e=m(x);return{href:e,as:w?m(w):e}},[x,w]);if(M){if(n?.$$typeof===Symbol.for("react.lazy"))throw Object.defineProperty(Error("`<Link legacyBehavior>` received a direct child that is either a Server Component, or JSX that was loaded with React.lazy(). This is not supported. Either remove legacyBehavior, or make the direct child a Client Component that renders the Link's `<a>` tag."),"__NEXT_ERROR_CODE",{value:"E863",enumerable:!1,configurable:!0});i=s.default.Children.only(n)}let $=M?i&&"object"==typeof i&&i.ref:_,B=s.default.useCallback(e=>(null!==I&&(b.current=(0,p.mountLinkInstance)(e,z,I,D,N,g)),()=>{b.current&&((0,p.unmountLinkForCurrentNavigation)(b.current),b.current=null),(0,p.unmountPrefetchableInstance)(e)}),[N,z,I,D,g]),K={ref:(0,c.useMergedRef)(B,$),onClick(t){M||"function"!=typeof E||E(t),M&&i.props&&"function"==typeof i.props.onClick&&i.props.onClick(t),!I||t.defaultPrevented||function(t,r,n,i,o,a,l){if("u">typeof window){let u,{nodeName:c}=t.currentTarget;if("A"===c.toUpperCase()&&((u=t.currentTarget.getAttribute("target"))&&"_self"!==u||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.nativeEvent&&2===t.nativeEvent.which)||t.currentTarget.hasAttribute("download"))return;if(!(0,h.isLocalURL)(r)){o&&(t.preventDefault(),location.replace(r));return}if(t.preventDefault(),l){let e=!1;if(l({preventDefault:()=>{e=!0}}),e)return}let{dispatchNavigateAction:d}=e.r(81574);s.default.startTransition(()=>{d(n||r,o?"replace":"push",a??!0,i.current)})}}(t,z,U,b,S,R,A)},onMouseEnter(e){M||"function"!=typeof T||T(e),M&&i.props&&"function"==typeof i.props.onMouseEnter&&i.props.onMouseEnter(e),I&&N&&(0,p.onNavigationIntent)(e.currentTarget,!0===F)},onTouchStart:function(e){M||"function"!=typeof O||O(e),M&&i.props&&"function"==typeof i.props.onTouchStart&&i.props.onTouchStart(e),I&&N&&(0,p.onNavigationIntent)(e.currentTarget,!0===F)}};return(0,d.isAbsoluteUrl)(U)?K.href=U:M&&!C&&("a"!==i.type||"href"in i.props)||(K.href=(0,f.addBasePath)(U)),o=M?s.default.cloneElement(i,K):(0,a.jsx)("a",{...L,...K,children:n}),(0,a.jsx)(v.Provider,{value:l,children:o})}e.r(38670);let v=(0,s.createContext)(p.IDLE_LINK_STATUS),b=()=>(0,s.useContext)(v);("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},89305,e=>{e.v(t=>Promise.all(["static/chunks/6d7b999c99d6d175.js"].map(t=>e.l(t))).then(()=>t(15567)))}]);
@@ -1,28 +0,0 @@
1
- $schema: https://json-schema.org/draft/2020-12/schema
2
- $id: AgentRunDetail.yaml
3
- type: object
4
- properties:
5
- agentType:
6
- type: string
7
- description: Type of agent (e.g. claude-code, gemini-cli)
8
- agentName:
9
- type: string
10
- description: Name/identifier of the agent run
11
- prompt:
12
- type: string
13
- description: Input prompt sent to the agent executor
14
- result:
15
- type: string
16
- description: Final result output from the agent (if available)
17
- error:
18
- type: string
19
- description: Error message if the run failed
20
- timestamp:
21
- type: string
22
- description: ISO 8601 timestamp of the run
23
- required:
24
- - agentType
25
- - agentName
26
- - prompt
27
- - timestamp
28
- description: Detailed agent run information including prompt and result for diagnostic reporting
@@ -1,76 +0,0 @@
1
- $schema: https://json-schema.org/draft/2020-12/schema
2
- $id: DoctorDiagnosticReport.yaml
3
- type: object
4
- properties:
5
- userDescription:
6
- type: string
7
- description: User-provided description of the problem
8
- failedRunSummaries:
9
- type: array
10
- items:
11
- $ref: FailedRunSummary.yaml
12
- description: Summaries of recent failed agent runs
13
- systemInfo:
14
- $ref: SystemInfo.yaml
15
- description: System environment information
16
- cliVersion:
17
- type: string
18
- description: Current shep CLI version
19
- featureId:
20
- type: string
21
- description: Feature ID when diagnosing a specific feature (optional)
22
- featureName:
23
- type: string
24
- description: Feature name when diagnosing a specific feature (optional)
25
- featureLifecycle:
26
- type: string
27
- description: Feature lifecycle phase (e.g. Implementation, Review)
28
- featureBranch:
29
- type: string
30
- description: Feature git branch name
31
- featureDescription:
32
- type: string
33
- description: Feature description
34
- featureWorkflowConfig:
35
- type: string
36
- description: JSON-serialized feature workflow configuration (fast, push, openPr, approvalGates)
37
- specYaml:
38
- type: string
39
- description: Raw spec.yaml content
40
- researchYaml:
41
- type: string
42
- description: Raw research.yaml content
43
- planYaml:
44
- type: string
45
- description: Raw plan.yaml content
46
- tasksYaml:
47
- type: string
48
- description: Raw tasks.yaml content
49
- featureStatusYaml:
50
- type: string
51
- description: Raw feature.yaml (status tracking) content
52
- agentRunDetails:
53
- type: array
54
- items:
55
- $ref: AgentRunDetail.yaml
56
- description: Detailed agent run information including prompts and results
57
- conversationMessages:
58
- type: string
59
- description: JSON-serialized conversation messages (Feature.messages[])
60
- featurePlan:
61
- type: string
62
- description: JSON-serialized feature plan (Feature.plan)
63
- workerLogs:
64
- type: array
65
- items:
66
- $ref: WorkerLogEntry.yaml
67
- description: Worker execution logs for agent runs associated with this feature
68
- phaseTimings:
69
- type: string
70
- description: JSON-serialized phase timing records
71
- required:
72
- - userDescription
73
- - failedRunSummaries
74
- - systemInfo
75
- - cliVersion
76
- description: Structured diagnostic report collected by shep doctor for issue creation
@@ -1,22 +0,0 @@
1
- $schema: https://json-schema.org/draft/2020-12/schema
2
- $id: FailedRunSummary.yaml
3
- type: object
4
- properties:
5
- agentType:
6
- type: string
7
- description: Type of agent that failed (e.g. claude-code, gemini-cli)
8
- agentName:
9
- type: string
10
- description: Name/identifier of the agent run
11
- error:
12
- type: string
13
- description: Error message from the failed run
14
- timestamp:
15
- type: string
16
- description: ISO 8601 timestamp when the failure occurred
17
- required:
18
- - agentType
19
- - agentName
20
- - error
21
- - timestamp
22
- description: Summary of a failed agent run for diagnostic reporting
@@ -1,22 +0,0 @@
1
- $schema: https://json-schema.org/draft/2020-12/schema
2
- $id: SystemInfo.yaml
3
- type: object
4
- properties:
5
- nodeVersion:
6
- type: string
7
- description: Node.js version (e.g. v20.11.0)
8
- platform:
9
- type: string
10
- description: Operating system platform (e.g. darwin, linux, win32)
11
- arch:
12
- type: string
13
- description: CPU architecture (e.g. x64, arm64)
14
- ghVersion:
15
- type: string
16
- description: gh CLI version string
17
- required:
18
- - nodeVersion
19
- - platform
20
- - arch
21
- - ghVersion
22
- description: System environment information for diagnostic reporting
@@ -1,27 +0,0 @@
1
- $schema: https://json-schema.org/draft/2020-12/schema
2
- $id: WorkerLogEntry.yaml
3
- type: object
4
- properties:
5
- agentRunId:
6
- type: string
7
- description: Agent run ID this log belongs to
8
- agentName:
9
- type: string
10
- description: Name of the agent that produced this log
11
- content:
12
- type: string
13
- description: Full log file content (may be truncated)
14
- truncated:
15
- type: boolean
16
- description: Whether the content was truncated due to size limits
17
- originalLength:
18
- type: integer
19
- minimum: -2147483648
20
- maximum: 2147483647
21
- description: Original character count before truncation (only set when truncated)
22
- required:
23
- - agentRunId
24
- - agentName
25
- - content
26
- - truncated
27
- description: Worker log entry for a specific agent run
@@ -1,57 +0,0 @@
1
- /**
2
- * GitHub Issue Service Interface
3
- *
4
- * Output port for creating GitHub issues via the gh CLI.
5
- * Implementations wrap `gh issue create` for issue creation on
6
- * any GitHub repository. Separate from IExternalIssueFetcher which
7
- * is a read-only fetcher — this service handles write operations.
8
- */
9
- /**
10
- * Error codes for GitHub issue creation operations.
11
- */
12
- export declare enum GitHubIssueErrorCode {
13
- /** The target repository was not found or the user lacks access */
14
- GH_NOT_FOUND = "GH_NOT_FOUND",
15
- /** GitHub CLI authentication failure */
16
- AUTH_FAILURE = "AUTH_FAILURE",
17
- /** Network connectivity error during API call */
18
- NETWORK_ERROR = "NETWORK_ERROR",
19
- /** Issue creation failed for an unspecified reason */
20
- CREATE_FAILED = "CREATE_FAILED"
21
- }
22
- /**
23
- * Typed error for GitHub issue creation operations.
24
- */
25
- export declare class GitHubIssueError extends Error {
26
- readonly code: GitHubIssueErrorCode;
27
- readonly cause?: Error | undefined;
28
- constructor(message: string, code: GitHubIssueErrorCode, cause?: Error | undefined);
29
- }
30
- /**
31
- * Result of creating a GitHub issue.
32
- */
33
- export interface GitHubIssueCreateResult {
34
- /** URL of the created issue (e.g. "https://github.com/owner/repo/issues/42") */
35
- url: string;
36
- /** Issue number */
37
- number: number;
38
- }
39
- /**
40
- * Output port for GitHub issue creation.
41
- *
42
- * Implementations use the `gh` CLI for all GitHub interactions.
43
- */
44
- export interface IGitHubIssueService {
45
- /**
46
- * Create a new issue on a GitHub repository.
47
- *
48
- * @param repo - Full owner/repo identifier (e.g. "shep-ai/cli")
49
- * @param title - Issue title
50
- * @param body - Issue body (Markdown)
51
- * @param labels - Labels to apply to the issue (e.g. ["bug", "shep-doctor"])
52
- * @returns The created issue's URL and number
53
- * @throws {GitHubIssueError} with appropriate error code on failure
54
- */
55
- createIssue(repo: string, title: string, body: string, labels: string[]): Promise<GitHubIssueCreateResult>;
56
- }
57
- //# sourceMappingURL=github-issue-service.interface.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"github-issue-service.interface.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/core/src/application/ports/output/services/github-issue-service.interface.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAMH;;GAEG;AACH,oBAAY,oBAAoB;IAC9B,mEAAmE;IACnE,YAAY,iBAAiB;IAC7B,wCAAwC;IACxC,YAAY,iBAAiB;IAC7B,iDAAiD;IACjD,aAAa,kBAAkB;IAC/B,sDAAsD;IACtD,aAAa,kBAAkB;CAChC;AAED;;GAEG;AACH,qBAAa,gBAAiB,SAAQ,KAAK;aAGvB,IAAI,EAAE,oBAAoB;aAC1B,KAAK,CAAC,EAAE,KAAK;gBAF7B,OAAO,EAAE,MAAM,EACC,IAAI,EAAE,oBAAoB,EAC1B,KAAK,CAAC,EAAE,KAAK,YAAA;CAMhC;AAMD;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC,gFAAgF;IAChF,GAAG,EAAE,MAAM,CAAC;IACZ,mBAAmB;IACnB,MAAM,EAAE,MAAM,CAAC;CAChB;AAMD;;;;GAIG;AACH,MAAM,WAAW,mBAAmB;IAClC;;;;;;;;;OASG;IACH,WAAW,CACT,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,MAAM,EACb,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,EAAE,GACf,OAAO,CAAC,uBAAuB,CAAC,CAAC;CACrC"}
@@ -1,39 +0,0 @@
1
- /**
2
- * GitHub Issue Service Interface
3
- *
4
- * Output port for creating GitHub issues via the gh CLI.
5
- * Implementations wrap `gh issue create` for issue creation on
6
- * any GitHub repository. Separate from IExternalIssueFetcher which
7
- * is a read-only fetcher — this service handles write operations.
8
- */
9
- // ---------------------------------------------------------------------------
10
- // Error types
11
- // ---------------------------------------------------------------------------
12
- /**
13
- * Error codes for GitHub issue creation operations.
14
- */
15
- export var GitHubIssueErrorCode;
16
- (function (GitHubIssueErrorCode) {
17
- /** The target repository was not found or the user lacks access */
18
- GitHubIssueErrorCode["GH_NOT_FOUND"] = "GH_NOT_FOUND";
19
- /** GitHub CLI authentication failure */
20
- GitHubIssueErrorCode["AUTH_FAILURE"] = "AUTH_FAILURE";
21
- /** Network connectivity error during API call */
22
- GitHubIssueErrorCode["NETWORK_ERROR"] = "NETWORK_ERROR";
23
- /** Issue creation failed for an unspecified reason */
24
- GitHubIssueErrorCode["CREATE_FAILED"] = "CREATE_FAILED";
25
- })(GitHubIssueErrorCode || (GitHubIssueErrorCode = {}));
26
- /**
27
- * Typed error for GitHub issue creation operations.
28
- */
29
- export class GitHubIssueError extends Error {
30
- code;
31
- cause;
32
- constructor(message, code, cause) {
33
- super(message);
34
- this.code = code;
35
- this.cause = cause;
36
- this.name = 'GitHubIssueError';
37
- Object.setPrototypeOf(this, new.target.prototype);
38
- }
39
- }
@@ -1,64 +0,0 @@
1
- /**
2
- * Doctor Diagnose Use Case
3
- *
4
- * Orchestrates the shep doctor workflow:
5
- * 1. Collect diagnostic context (failed agent runs, version, system info)
6
- * 2. Create a structured GitHub issue on shep-ai/cli
7
- * 3. Optionally attempt a fix via AI agent
8
- * 4. Open a PR with the fix (direct push for maintainers, fork for contributors)
9
- *
10
- * Following Clean Architecture: all external operations are injected via interfaces.
11
- */
12
- import type { IAgentRunRepository } from '../../ports/output/agents/agent-run-repository.interface.js';
13
- import type { IPhaseTimingRepository } from '../../ports/output/agents/phase-timing-repository.interface.js';
14
- import type { IVersionService } from '../../ports/output/services/version-service.interface.js';
15
- import type { IGitHubIssueService } from '../../ports/output/services/github-issue-service.interface.js';
16
- import type { IGitHubRepositoryService } from '../../ports/output/services/github-repository-service.interface.js';
17
- import type { IGitPrService } from '../../ports/output/services/git-pr-service.interface.js';
18
- import type { IAgentExecutorProvider } from '../../ports/output/agents/agent-executor-provider.interface.js';
19
- import type { IFeatureRepository } from '../../ports/output/repositories/feature-repository.interface.js';
20
- import type { ExecFunction } from '../../../infrastructure/services/git/worktree.service.js';
21
- import type { DoctorDiagnosticReport } from '../../../domain/generated/output.js';
22
- export interface DoctorDiagnoseInput {
23
- description: string;
24
- fix: boolean;
25
- workdir?: string;
26
- featureId?: string;
27
- }
28
- export interface DoctorDiagnoseResult {
29
- diagnosticReport: DoctorDiagnosticReport;
30
- issueUrl: string;
31
- issueNumber: number;
32
- prUrl?: string;
33
- flowType?: 'maintainer' | 'contributor';
34
- error?: string;
35
- cleanedUp: boolean;
36
- }
37
- export declare class DoctorDiagnoseUseCase {
38
- private readonly agentRunRepo;
39
- private readonly versionService;
40
- private readonly issueService;
41
- private readonly repoService;
42
- private readonly prService;
43
- private readonly agentExecutorProvider;
44
- private readonly execFile;
45
- private readonly featureRepo;
46
- private readonly phaseTimingRepo;
47
- constructor(agentRunRepo: IAgentRunRepository, versionService: IVersionService, issueService: IGitHubIssueService, repoService: IGitHubRepositoryService, prService: IGitPrService, agentExecutorProvider: IAgentExecutorProvider, execFile: ExecFunction, featureRepo: IFeatureRepository, phaseTimingRepo: IPhaseTimingRepository);
48
- execute(input: DoctorDiagnoseInput): Promise<DoctorDiagnoseResult>;
49
- private collectDiagnostics;
50
- private filterFailedRuns;
51
- private sanitizeRunSummary;
52
- private collectSystemInfo;
53
- private truncate;
54
- private collectSpecYamls;
55
- private collectWorkerLogs;
56
- private collectPhaseTimings;
57
- private buildAgentRunDetails;
58
- private readFileSafe;
59
- private formatIssueTitle;
60
- private formatIssueBody;
61
- private attemptFix;
62
- private buildFixPrompt;
63
- }
64
- //# sourceMappingURL=doctor-diagnose.use-case.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"doctor-diagnose.use-case.d.ts","sourceRoot":"","sources":["../../../../../../../packages/core/src/application/use-cases/doctor/doctor-diagnose.use-case.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAQH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,6DAA6D,CAAC;AACvG,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gEAAgE,CAAC;AAC7G,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0DAA0D,CAAC;AAChG,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,+DAA+D,CAAC;AACzG,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,oEAAoE,CAAC;AACnH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yDAAyD,CAAC;AAC7F,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gEAAgE,CAAC;AAC7G,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iEAAiE,CAAC;AAC1G,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0DAA0D,CAAC;AAC7F,OAAO,KAAK,EACV,sBAAsB,EAMvB,MAAM,qCAAqC,CAAC;AAO7C,MAAM,WAAW,mBAAmB;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,OAAO,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,oBAAoB;IACnC,gBAAgB,EAAE,sBAAsB,CAAC;IACzC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,YAAY,GAAG,aAAa,CAAC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,OAAO,CAAC;CACpB;AAoBD,qBACa,qBAAqB;IAG9B,OAAO,CAAC,QAAQ,CAAC,YAAY;IAE7B,OAAO,CAAC,QAAQ,CAAC,cAAc;IAE/B,OAAO,CAAC,QAAQ,CAAC,YAAY;IAE7B,OAAO,CAAC,QAAQ,CAAC,WAAW;IAE5B,OAAO,CAAC,QAAQ,CAAC,SAAS;IAE1B,OAAO,CAAC,QAAQ,CAAC,qBAAqB;IAEtC,OAAO,CAAC,QAAQ,CAAC,QAAQ;IAEzB,OAAO,CAAC,QAAQ,CAAC,WAAW;IAE5B,OAAO,CAAC,QAAQ,CAAC,eAAe;gBAhBf,YAAY,EAAE,mBAAmB,EAEjC,cAAc,EAAE,eAAe,EAE/B,YAAY,EAAE,mBAAmB,EAEjC,WAAW,EAAE,wBAAwB,EAErC,SAAS,EAAE,aAAa,EAExB,qBAAqB,EAAE,sBAAsB,EAE7C,QAAQ,EAAE,YAAY,EAEtB,WAAW,EAAE,kBAAkB,EAE/B,eAAe,EAAE,sBAAsB;IAGpD,OAAO,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,oBAAoB,CAAC;YAgC1D,kBAAkB;IA0EhC,OAAO,CAAC,gBAAgB;IAQxB,OAAO,CAAC,kBAAkB;YAUZ,iBAAiB;IAqB/B,OAAO,CAAC,QAAQ;YAcF,gBAAgB;YA4BhB,iBAAiB;YAqBjB,mBAAmB;IASjC,OAAO,CAAC,oBAAoB;YAad,YAAY;IAY1B,OAAO,CAAC,gBAAgB;IAMxB,OAAO,CAAC,eAAe;YAsHT,UAAU;IA8FxB,OAAO,CAAC,cAAc;CAyBvB"}