dorkos 0.45.0 → 0.45.1

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 (91) hide show
  1. package/dist/bin/cli.js +6 -6
  2. package/dist/client/assets/{BaseTanStackRouterDevtoolsPanel-SWyE65Is-DbU6EhZc.js → BaseTanStackRouterDevtoolsPanel-SWyE65Is-DBeTmo8s.js} +1 -1
  3. package/dist/client/assets/BaseTanStackRouterDevtoolsPanel-SWyE65Is-DptF2Iv2.js +539 -0
  4. package/dist/client/assets/{BlintzCanvas-YWLFAfxE.js → BlintzCanvas-BC2wvdMT.js} +1 -1
  5. package/dist/client/assets/BlintzCanvas-tAgLU3aR.js +1160 -0
  6. package/dist/client/assets/{CanvasCsvContent-Dcuaf91X.js → CanvasCsvContent-B0IwcV_U.js} +1 -1
  7. package/dist/client/assets/CanvasCsvContent-RYl7B_ua.js +15 -0
  8. package/dist/client/assets/{CanvasFileContent-gn5aMM24.js → CanvasFileContent-BHJI0OTy.js} +2 -2
  9. package/dist/client/assets/CanvasFileContent-BsJsR4E1.js +2 -0
  10. package/dist/client/assets/{CanvasModel3dContent-C3PJHVs8.js → CanvasModel3dContent-BcdM2LJg.js} +2 -2
  11. package/dist/client/assets/CanvasModel3dContent-ohjBCAJd.js +2 -0
  12. package/dist/client/assets/{CodeMirrorEditor-f8fXFh5i.js → CodeMirrorEditor-C-gkWN8h.js} +1 -1
  13. package/dist/client/assets/CodeMirrorEditor-SHXbcVUy.js +1 -0
  14. package/dist/client/assets/{ConfigTab-Cetgg_6C.js → ConfigTab-DJu3oDC2.js} +1 -1
  15. package/dist/client/assets/ConfigTab-TuhuSOnv.js +17 -0
  16. package/dist/client/assets/{FloatingTanStackRouterDevtools-CnpwH7La-BOdQs4zz.js → FloatingTanStackRouterDevtools-CnpwH7La-BmSxRfr_.js} +1 -1
  17. package/dist/client/assets/FloatingTanStackRouterDevtools-CnpwH7La-Dk8iG4Hx.js +1 -0
  18. package/dist/client/assets/{Model3dViewer-qR1sbYAL.js → Model3dViewer-D6VCAF61.js} +1 -1
  19. package/dist/client/assets/Model3dViewer-K9pNJx1c.js +5372 -0
  20. package/dist/client/assets/{SessionsTab-BCsOP3gI.js → SessionsTab-BrqarM-T.js} +1 -1
  21. package/dist/client/assets/SessionsTab-Di1R_A1t.js +1 -0
  22. package/dist/client/assets/{ToolkitTab-BYtBugsk.js → ToolkitTab-BOaJEnPh.js} +1 -1
  23. package/dist/client/assets/ToolkitTab-a2dYMBx9.js +1 -0
  24. package/dist/client/assets/{TopologyGraph-xyvgCKHX.js → TopologyGraph-DUJWDhtI.js} +1 -1
  25. package/dist/client/assets/TopologyGraph-Dehijt2P.js +35 -0
  26. package/dist/client/assets/{highlighted-body-OFNGDK62-B8b-ZuJR.js → highlighted-body-OFNGDK62-B_0h6J6M.js} +1 -1
  27. package/dist/client/assets/highlighted-body-OFNGDK62-D85fxms5.js +1 -0
  28. package/dist/client/assets/{index-BrVLuO9-.js → index-5ALgrOFO.js} +1 -1
  29. package/dist/client/assets/{index-YPp3bUkv.js → index-B4Fq7yld.js} +1 -1
  30. package/dist/client/assets/{index-CZBlFw3s.js → index-B4_k9QZg.js} +1 -1
  31. package/dist/client/assets/{index-B-WBHpyv.js → index-B7ObcNSe.js} +1 -1
  32. package/dist/client/assets/{index-BzFClKht.js → index-B9VCOBmA.js} +2 -2
  33. package/dist/client/assets/{index-BaGiFKrR.js → index-BCp9aZet.js} +1 -1
  34. package/dist/client/assets/index-BDdd8Mqa.js +1 -0
  35. package/dist/client/assets/index-BNSNg7yH.js +1316 -0
  36. package/dist/client/assets/{index-aEzy0_Oi.js → index-BQk-ivFT.js} +1 -1
  37. package/dist/client/assets/{index-CCHYQVhi.js → index-BT9yFVeS.js} +3 -3
  38. package/dist/client/assets/{index-sKKm7yEm.js → index-BZYDK9c8.js} +8 -8
  39. package/dist/client/assets/{index-Djl0lRsF.js → index-Bbn2wn69.js} +1 -1
  40. package/dist/client/assets/{index-C27wAnIu.js → index-BcX7mUEk.js} +1 -1
  41. package/dist/client/assets/{index-BT9Vxyz4.js → index-Bcx7LFbL.js} +1 -1
  42. package/dist/client/assets/{index-CCqqyjKr.js → index-BdUsepd_.js} +1 -1
  43. package/dist/client/assets/index-BeWJN4g0.js +1 -0
  44. package/dist/client/assets/index-Bh6Wh5Du.js +1 -0
  45. package/dist/client/assets/index-BqqIE9sa.js +1 -0
  46. package/dist/client/assets/{index-CzJ4xEDL.js → index-Bvs4ET-I.js} +1 -1
  47. package/dist/client/assets/{index-Ced3HTl7.js → index-Bx073uVW.js} +1 -1
  48. package/dist/client/assets/{index-BJyMVoKM.js → index-C20-Z8l4.js} +1 -1
  49. package/dist/client/assets/{index-lFLNlOBz.js → index-C2NQ-Ck8.js} +1 -1
  50. package/dist/client/assets/index-C44W9aTS.js +2 -0
  51. package/dist/client/assets/index-C6SlFkyv.js +2 -0
  52. package/dist/client/assets/{index-DjSzGDon.js → index-C9IMI6L6.js} +1 -1
  53. package/dist/client/assets/{index-C2pa1dy_.js → index-CK2kZcMG.js} +1 -1
  54. package/dist/client/assets/index-CKCx_Kan.js +6 -0
  55. package/dist/client/assets/index-CQxDY4vU.js +6 -0
  56. package/dist/client/assets/{index-oZPvMe-H.js → index-CSZQyH2J.js} +1 -1
  57. package/dist/client/assets/{index-9i9Kxi6Z.js → index-CT-ZBhf1.js} +1 -1
  58. package/dist/client/assets/{index-BkmzUjFL.js → index-CaH1aFVg.js} +1 -1
  59. package/dist/client/assets/index-CdAooMjU.js +15 -0
  60. package/dist/client/assets/{index-BKp1QoTa.js → index-CvMyZRD2.js} +1 -1
  61. package/dist/client/assets/index-CyUySFAD.js +13 -0
  62. package/dist/client/assets/{index-BQ0KNUVJ.js → index-CyWkKBhZ.js} +1 -1
  63. package/dist/client/assets/{index-DWocbnZZ.js → index-D1ekLRaV.js} +1 -1
  64. package/dist/client/assets/{index-DRqPbLFU.js → index-D9MT2UpW.js} +1 -1
  65. package/dist/client/assets/index-DEA_Cy2Q.js +1 -0
  66. package/dist/client/assets/index-DLQOQsnm.js +1 -0
  67. package/dist/client/assets/index-DQD1r_S5.js +70 -0
  68. package/dist/client/assets/{index-BV2QuCxp.js → index-DUshTWP6.js} +1 -1
  69. package/dist/client/assets/index-DbAfUW6T.js +1 -0
  70. package/dist/client/assets/index-DhLhWBOz.js +1 -0
  71. package/dist/client/assets/index-DiQETlwd.js +71 -0
  72. package/dist/client/assets/index-Do63XgYk.js +1 -0
  73. package/dist/client/assets/index-DvPThthM.js +1 -0
  74. package/dist/client/assets/index-Dyl6ywSG.js +7 -0
  75. package/dist/client/assets/{index-CTqKf40t.js → index-MDyXRyeQ.js} +1 -1
  76. package/dist/client/assets/index-QFOwC8Sb.js +6 -0
  77. package/dist/client/assets/index-YNTMAxpK.js +1 -0
  78. package/dist/client/assets/index-ZZSS75im.js +1 -0
  79. package/dist/client/assets/index-_mq6ScXa.js +1 -0
  80. package/dist/client/assets/index-dj2DvPaa.js +1 -0
  81. package/dist/client/assets/index-oQeM2FOC.js +1 -0
  82. package/dist/client/assets/{index-ByyRHqai.js → index-rZ21sTqk.js} +1 -1
  83. package/dist/client/assets/index-sgPwXj8m.js +1 -0
  84. package/dist/client/assets/index-w2P-tT_0.js +1 -0
  85. package/dist/client/assets/{index-DQrSytvk.js → index-w2dnLgsj.js} +1 -1
  86. package/dist/client/assets/index-xIhoncSx.js +1 -0
  87. package/dist/client/assets/index-yXRJmHf-.js +3 -0
  88. package/dist/client/index.html +1 -1
  89. package/dist/server/index.js +2 -1
  90. package/dist/server/index.js.map +1 -1
  91. package/package.json +3 -3
@@ -1 +1 @@
1
- import{u as g,a as p,b,c as f,d as j,e as v,r as a,g as y,t as h,j as o,T as C,S as T}from"./index-sKKm7yEm.js";function A(){const{agent:S,projectPath:e}=g(),{sessions:i,activeSessionId:d,setActiveSession:n}=p(e),r=b(e),c=f(),u=j(),l=v(e),m=a.useMemo(()=>y(i),[i]),k=a.useCallback(async t=>{try{const s=await c.forkSession(t,void 0,e??void 0);await u.invalidateQueries({queryKey:["sessions"]}),n(s.id)}catch(s){h.error(s instanceof Error?s.message:"Failed to fork session")}},[c,e,u,n]),x=a.useCallback((t,s)=>{l.mutate({sessionId:t,title:s})},[l]);return o.jsxs("div",{className:"flex flex-col",children:[r.tasks==="enabled"&&o.jsx("div",{className:"border-b",children:o.jsx(C,{toolStatus:r.tasks,agentId:S.id})}),o.jsx(T,{activeSessionId:d,groupedSessions:m,onSessionClick:n,onForkSession:k,onRenameSession:x})]})}export{A as SessionsTab};
1
+ import{u as g,a as p,b,c as f,d as j,e as v,r as a,g as y,t as h,j as o,T as C,S as T}from"./index-BNSNg7yH.js";function A(){const{agent:S,projectPath:e}=g(),{sessions:i,activeSessionId:d,setActiveSession:n}=p(e),r=b(e),c=f(),u=j(),l=v(e),m=a.useMemo(()=>y(i),[i]),k=a.useCallback(async t=>{try{const s=await c.forkSession(t,void 0,e??void 0);await u.invalidateQueries({queryKey:["sessions"]}),n(s.id)}catch(s){h.error(s instanceof Error?s.message:"Failed to fork session")}},[c,e,u,n]),x=a.useCallback((t,s)=>{l.mutate({sessionId:t,title:s})},[l]);return o.jsxs("div",{className:"flex flex-col",children:[r.tasks==="enabled"&&o.jsx("div",{className:"border-b",children:o.jsx(C,{toolStatus:r.tasks,agentId:S.id})}),o.jsx(T,{activeSessionId:d,groupedSessions:m,onSessionClick:n,onForkSession:k,onRenameSession:x})]})}export{A as SessionsTab};
@@ -0,0 +1 @@
1
+ import{u as g,a as p,b,c as f,d as j,e as v,r as a,g as y,t as h,j as o,T as C,S as T}from"./index-BZYDK9c8.js";function A(){const{agent:S,projectPath:e}=g(),{sessions:i,activeSessionId:d,setActiveSession:n}=p(e),r=b(e),c=f(),u=j(),l=v(e),m=a.useMemo(()=>y(i),[i]),k=a.useCallback(async t=>{try{const s=await c.forkSession(t,void 0,e??void 0);await u.invalidateQueries({queryKey:["sessions"]}),n(s.id)}catch(s){h.error(s instanceof Error?s.message:"Failed to fork session")}},[c,e,u,n]),x=a.useCallback((t,s)=>{l.mutate({sessionId:t,title:s})},[l]);return o.jsxs("div",{className:"flex flex-col",children:[r.tasks==="enabled"&&o.jsx("div",{className:"border-b",children:o.jsx(C,{toolStatus:r.tasks,agentId:S.id})}),o.jsx(T,{activeSessionId:d,groupedSessions:m,onSessionClick:n,onForkSession:k,onRenameSession:x})]})}export{A as SessionsTab};
@@ -1 +1 @@
1
- import{r as x,U as F,V as H,W as I,X as K,Y as $,j as e,Z as p,$ as b,l as v,a0 as V,a1 as g,a2 as w,a3 as f,a4 as j,v as y,w as S,a5 as k,B as O,a6 as W,u as Y,a7 as M,a8 as q,a9 as D,aa as X,s as Z,ab as J}from"./index-sKKm7yEm.js";const u={tasks:["tasks_list","tasks_create","tasks_update","tasks_delete","tasks_get_run_history"],relay:["relay_send","relay_inbox","relay_list_endpoints","relay_register_endpoint","relay_send_and_wait","relay_send_async","relay_unregister_endpoint","relay_get_trace","relay_get_metrics"],mesh:["mesh_discover","mesh_register","mesh_list","mesh_deny","mesh_unregister","mesh_status","mesh_inspect","mesh_query_topology"],adapter:["relay_list_adapters","relay_enable_adapter","relay_disable_adapter","relay_reload_adapters","binding_list","binding_create","binding_delete","binding_list_sessions","relay_notify_user"]};function P({tools:s}){return e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsx(y,{variant:"outline",className:"text-muted-foreground shrink-0 cursor-default text-xs font-normal",children:s.length})}),e.jsx(k,{side:"top",className:"max-w-xs",children:e.jsx("p",{className:"font-mono text-xs",children:s.join(", ")})})]})}function Q({domain:s,agentOverride:l,globalDefault:n,onToggle:r,onReset:o}){const t=l!==void 0,i=l??n;return s.serverDisabled?e.jsx(g,{label:s.label,description:s.description,className:"py-1",children:e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(y,{variant:"secondary",className:"text-xs",children:"Disabled"}),e.jsx(P,{tools:s.tools}),e.jsx(S,{checked:!1,disabled:!0,"aria-label":`Toggle ${s.label} tools`})]})}),e.jsx(k,{side:"left",children:s.serverDisabledReason??"Disabled globally by server configuration."})]})}):e.jsx(g,{label:s.label,description:s.description,className:"py-1",children:e.jsxs("div",{className:"flex items-center gap-2",children:[!t&&e.jsx(y,{variant:"outline",className:"text-muted-foreground text-xs font-normal",children:"default"}),t&&e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsx(O,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o(s.key),"aria-label":`Reset ${s.label} to default`,children:e.jsx(W,{className:"size-3"})})}),e.jsx(k,{side:"top",children:"Reset to global default"})]}),e.jsx(P,{tools:s.tools}),e.jsx(S,{checked:i,onCheckedChange:c=>r(s.key,c),"aria-label":`Toggle ${s.label} tools`})]})})}const U={connected:"bg-green-500",failed:"bg-red-500","needs-auth":"bg-amber-500",pending:"bg-amber-500",disabled:"bg-muted-foreground/20"};function ee({agent:s,projectPath:l,onUpdate:n}){var N,T;const[r,o]=x.useState(!1),t=F(),i=H(),{config:c}=I(),{data:h}=K(l,s.runtime),m=$(s.runtime),E=(m==null?void 0:m.supportsMcp)??!0,L=x.useCallback((a,d)=>{const A=s.enabledToolGroups??{};n({enabledToolGroups:{...A,[a]:d}})},[s.enabledToolGroups,n]),G=x.useCallback(a=>{const d={...s.enabledToolGroups??{}};delete d[a],n({enabledToolGroups:d})},[s.enabledToolGroups,n]),B=[{key:"tasks",configKey:"tasksTools",label:"Scheduling",description:"Create and run scheduled agent tasks",tools:u.tasks,serverDisabled:!i,serverDisabledReason:"Disabled globally by server configuration."},{key:"relay",configKey:"relayTools",label:"Messaging",description:"Send and receive messages between agents",tools:u.relay,serverDisabled:!t,serverDisabledReason:"Disabled globally by server configuration."},{key:"mesh",configKey:"meshTools",label:"Agent Discovery",description:"Find and register agents on this machine",tools:u.mesh},{key:"adapter",configKey:"adapterTools",label:"External Channels",description:"Manage connections to Slack, Telegram, and other platforms",tools:u.adapter,serverDisabled:!t,serverDisabledReason:"Disabled globally by server configuration."}],z=s.enabledToolGroups??{},_=((N=s.budget)==null?void 0:N.maxHopsPerMessage)??5,C=((T=s.budget)==null?void 0:T.maxCallsPerHour)??100;return e.jsxs("div",{className:"space-y-4",children:[E?e.jsxs(e.Fragment,{children:[e.jsx("p",{className:"text-muted-foreground text-sm",children:"Control which tool groups are available to this agent. Leave unset to inherit global defaults."}),e.jsx(p,{children:e.jsx(b,{children:B.map(a=>e.jsx(Q,{domain:a,agentOverride:z[a.key],globalDefault:c[a.configKey],onToggle:L,onReset:G},a.key))})}),e.jsx("p",{className:"text-muted-foreground text-xs",children:"Core tools (ping, server info, agent identity) are always available."})]}):e.jsx(p,{children:e.jsx(b,{children:e.jsx("p",{className:"text-muted-foreground text-sm",children:"This agent’s runtime does not support DorkOS tool groups (Scheduling, Messaging, Agent Discovery, External Channels). These are delivered over MCP, which this runtime cannot consume."})})}),h&&h.servers.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h3",{className:"text-sm font-semibold",children:"MCP Servers"}),e.jsx(p,{children:e.jsx(b,{children:h.servers.map(a=>e.jsxs("div",{className:"flex items-center gap-2 py-0.5",children:[e.jsx("span",{className:v("size-2 shrink-0 rounded-full",U[a.status??""]??"bg-muted-foreground/40")}),e.jsx("span",{className:"min-w-0 truncate text-sm",children:a.name}),e.jsx("span",{className:"text-muted-foreground/50 ml-auto shrink-0 text-xs",children:a.type})]},a.name))})})]}),e.jsxs(V,{open:r,onOpenChange:o,trigger:"Limits",badge:e.jsxs("span",{className:"text-muted-foreground text-xs font-normal",children:[_," hops · ",C," calls/hr"]}),children:[e.jsx(g,{label:"Message forwarding depth",description:"Maximum agents a message can pass through before stopping",orientation:"vertical",children:e.jsx(w,{type:"number",min:1,value:_,onChange:a=>n({budget:{...s.budget,maxHopsPerMessage:parseInt(a.target.value)||5}}),className:"w-24"})}),e.jsx(g,{label:"Hourly rate limit",description:"Maximum tool invocations per hour. The agent pauses when exceeded.",orientation:"vertical",children:e.jsx(w,{type:"number",min:1,value:C,onChange:a=>n({budget:{...s.budget,maxCallsPerHour:parseInt(a.target.value)||100}}),className:"w-24"})})]})]})}const se={global:"global","agent-local":"local",override:"override"},te={global:"bg-muted text-muted-foreground","agent-local":"bg-blue-500/10 text-blue-600 dark:text-blue-400",override:"bg-amber-500/10 text-amber-600 dark:text-amber-400"};function ae({scope:s="global",className:l}){return e.jsx("span",{"data-slot":"scope-badge",className:v("inline-flex items-center rounded-full px-1.5 py-0.5 text-[9px] font-semibold tracking-wide uppercase",te[s],l),children:se[s]})}function R({title:s,icon:l,meta:n,defaultOpen:r=!1,children:o}){const[t,i]=x.useState(r);return e.jsxs("div",{className:"border-b last:border-b-0",children:[e.jsxs("button",{type:"button",onClick:()=>i(!t),className:v("hover:bg-accent/50 flex w-full items-center gap-2 px-4 py-2.5 text-left transition-colors"),"aria-expanded":t,children:[t?e.jsx(Z,{className:"text-muted-foreground size-3.5 shrink-0"}):e.jsx(J,{className:"text-muted-foreground size-3.5 shrink-0"}),e.jsx(l,{className:"text-muted-foreground size-3.5 shrink-0"}),e.jsx("span",{className:"text-[11px] font-semibold",children:s}),n&&e.jsx("span",{className:"text-muted-foreground ml-auto text-[9px]",children:n})]}),t&&e.jsx("div",{className:"px-4 pb-4",children:o})]})}function le({projectPath:s}){const{data:l,isLoading:n,error:r}=M(s);if(n)return e.jsx("p",{className:"text-muted-foreground py-2 text-xs",children:"Loading skills…"});if(r)return e.jsx("p",{className:"text-destructive py-2 text-xs",children:"Failed to load skills."});const o=(l==null?void 0:l.filter(t=>t.type==="skill-pack"))??[];return o.length===0?e.jsx("p",{className:"text-muted-foreground py-2 text-xs",children:"No skills installed. Browse the marketplace to add skills to this agent."}):e.jsx("ul",{className:"space-y-1.5 py-1",children:o.map(t=>e.jsxs("li",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"min-w-0 flex-1 truncate font-mono text-xs",children:t.name}),t.version&&e.jsxs("span",{className:"text-muted-foreground shrink-0 text-[10px]",children:["v",t.version]}),e.jsx(ae,{scope:t.scope})]},t.name))})}function re(){const{agent:s,projectPath:l,onUpdate:n}=Y(),{data:r}=M(l),o=(r==null?void 0:r.filter(c=>c.type==="skill-pack").length)??0,t=q(),i=()=>{t({to:"/marketplace",search:{type:"skill-pack"}})};return e.jsxs("div",{"data-slot":"toolkit-tab",className:"flex flex-col",children:[e.jsxs(R,{title:"Skills",icon:D,meta:o>0?`${o}`:void 0,defaultOpen:!0,children:[e.jsx(le,{projectPath:l}),e.jsxs(O,{variant:"ghost",size:"sm",onClick:i,className:"text-muted-foreground hover:text-foreground mt-2 w-full",children:[e.jsx(D,{className:"mr-1.5 size-3.5"}),"Browse skill-packs"]})]}),e.jsx(R,{title:"Tools & MCP",icon:X,children:e.jsx(ee,{agent:s,projectPath:l,onUpdate:n})})]})}export{re as ToolkitTab};
1
+ import{r as x,U as F,V as H,W as I,X as K,Y as $,j as e,Z as p,$ as b,l as v,a0 as V,a1 as g,a2 as w,a3 as f,a4 as j,v as y,w as S,a5 as k,B as O,a6 as W,u as Y,a7 as M,a8 as q,a9 as D,aa as X,s as Z,ab as J}from"./index-BNSNg7yH.js";const u={tasks:["tasks_list","tasks_create","tasks_update","tasks_delete","tasks_get_run_history"],relay:["relay_send","relay_inbox","relay_list_endpoints","relay_register_endpoint","relay_send_and_wait","relay_send_async","relay_unregister_endpoint","relay_get_trace","relay_get_metrics"],mesh:["mesh_discover","mesh_register","mesh_list","mesh_deny","mesh_unregister","mesh_status","mesh_inspect","mesh_query_topology"],adapter:["relay_list_adapters","relay_enable_adapter","relay_disable_adapter","relay_reload_adapters","binding_list","binding_create","binding_delete","binding_list_sessions","relay_notify_user"]};function P({tools:s}){return e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsx(y,{variant:"outline",className:"text-muted-foreground shrink-0 cursor-default text-xs font-normal",children:s.length})}),e.jsx(k,{side:"top",className:"max-w-xs",children:e.jsx("p",{className:"font-mono text-xs",children:s.join(", ")})})]})}function Q({domain:s,agentOverride:l,globalDefault:n,onToggle:r,onReset:o}){const t=l!==void 0,i=l??n;return s.serverDisabled?e.jsx(g,{label:s.label,description:s.description,className:"py-1",children:e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(y,{variant:"secondary",className:"text-xs",children:"Disabled"}),e.jsx(P,{tools:s.tools}),e.jsx(S,{checked:!1,disabled:!0,"aria-label":`Toggle ${s.label} tools`})]})}),e.jsx(k,{side:"left",children:s.serverDisabledReason??"Disabled globally by server configuration."})]})}):e.jsx(g,{label:s.label,description:s.description,className:"py-1",children:e.jsxs("div",{className:"flex items-center gap-2",children:[!t&&e.jsx(y,{variant:"outline",className:"text-muted-foreground text-xs font-normal",children:"default"}),t&&e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsx(O,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o(s.key),"aria-label":`Reset ${s.label} to default`,children:e.jsx(W,{className:"size-3"})})}),e.jsx(k,{side:"top",children:"Reset to global default"})]}),e.jsx(P,{tools:s.tools}),e.jsx(S,{checked:i,onCheckedChange:c=>r(s.key,c),"aria-label":`Toggle ${s.label} tools`})]})})}const U={connected:"bg-green-500",failed:"bg-red-500","needs-auth":"bg-amber-500",pending:"bg-amber-500",disabled:"bg-muted-foreground/20"};function ee({agent:s,projectPath:l,onUpdate:n}){var N,T;const[r,o]=x.useState(!1),t=F(),i=H(),{config:c}=I(),{data:h}=K(l,s.runtime),m=$(s.runtime),E=(m==null?void 0:m.supportsMcp)??!0,L=x.useCallback((a,d)=>{const A=s.enabledToolGroups??{};n({enabledToolGroups:{...A,[a]:d}})},[s.enabledToolGroups,n]),G=x.useCallback(a=>{const d={...s.enabledToolGroups??{}};delete d[a],n({enabledToolGroups:d})},[s.enabledToolGroups,n]),B=[{key:"tasks",configKey:"tasksTools",label:"Scheduling",description:"Create and run scheduled agent tasks",tools:u.tasks,serverDisabled:!i,serverDisabledReason:"Disabled globally by server configuration."},{key:"relay",configKey:"relayTools",label:"Messaging",description:"Send and receive messages between agents",tools:u.relay,serverDisabled:!t,serverDisabledReason:"Disabled globally by server configuration."},{key:"mesh",configKey:"meshTools",label:"Agent Discovery",description:"Find and register agents on this machine",tools:u.mesh},{key:"adapter",configKey:"adapterTools",label:"External Channels",description:"Manage connections to Slack, Telegram, and other platforms",tools:u.adapter,serverDisabled:!t,serverDisabledReason:"Disabled globally by server configuration."}],z=s.enabledToolGroups??{},_=((N=s.budget)==null?void 0:N.maxHopsPerMessage)??5,C=((T=s.budget)==null?void 0:T.maxCallsPerHour)??100;return e.jsxs("div",{className:"space-y-4",children:[E?e.jsxs(e.Fragment,{children:[e.jsx("p",{className:"text-muted-foreground text-sm",children:"Control which tool groups are available to this agent. Leave unset to inherit global defaults."}),e.jsx(p,{children:e.jsx(b,{children:B.map(a=>e.jsx(Q,{domain:a,agentOverride:z[a.key],globalDefault:c[a.configKey],onToggle:L,onReset:G},a.key))})}),e.jsx("p",{className:"text-muted-foreground text-xs",children:"Core tools (ping, server info, agent identity) are always available."})]}):e.jsx(p,{children:e.jsx(b,{children:e.jsx("p",{className:"text-muted-foreground text-sm",children:"This agent’s runtime does not support DorkOS tool groups (Scheduling, Messaging, Agent Discovery, External Channels). These are delivered over MCP, which this runtime cannot consume."})})}),h&&h.servers.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h3",{className:"text-sm font-semibold",children:"MCP Servers"}),e.jsx(p,{children:e.jsx(b,{children:h.servers.map(a=>e.jsxs("div",{className:"flex items-center gap-2 py-0.5",children:[e.jsx("span",{className:v("size-2 shrink-0 rounded-full",U[a.status??""]??"bg-muted-foreground/40")}),e.jsx("span",{className:"min-w-0 truncate text-sm",children:a.name}),e.jsx("span",{className:"text-muted-foreground/50 ml-auto shrink-0 text-xs",children:a.type})]},a.name))})})]}),e.jsxs(V,{open:r,onOpenChange:o,trigger:"Limits",badge:e.jsxs("span",{className:"text-muted-foreground text-xs font-normal",children:[_," hops · ",C," calls/hr"]}),children:[e.jsx(g,{label:"Message forwarding depth",description:"Maximum agents a message can pass through before stopping",orientation:"vertical",children:e.jsx(w,{type:"number",min:1,value:_,onChange:a=>n({budget:{...s.budget,maxHopsPerMessage:parseInt(a.target.value)||5}}),className:"w-24"})}),e.jsx(g,{label:"Hourly rate limit",description:"Maximum tool invocations per hour. The agent pauses when exceeded.",orientation:"vertical",children:e.jsx(w,{type:"number",min:1,value:C,onChange:a=>n({budget:{...s.budget,maxCallsPerHour:parseInt(a.target.value)||100}}),className:"w-24"})})]})]})}const se={global:"global","agent-local":"local",override:"override"},te={global:"bg-muted text-muted-foreground","agent-local":"bg-blue-500/10 text-blue-600 dark:text-blue-400",override:"bg-amber-500/10 text-amber-600 dark:text-amber-400"};function ae({scope:s="global",className:l}){return e.jsx("span",{"data-slot":"scope-badge",className:v("inline-flex items-center rounded-full px-1.5 py-0.5 text-[9px] font-semibold tracking-wide uppercase",te[s],l),children:se[s]})}function R({title:s,icon:l,meta:n,defaultOpen:r=!1,children:o}){const[t,i]=x.useState(r);return e.jsxs("div",{className:"border-b last:border-b-0",children:[e.jsxs("button",{type:"button",onClick:()=>i(!t),className:v("hover:bg-accent/50 flex w-full items-center gap-2 px-4 py-2.5 text-left transition-colors"),"aria-expanded":t,children:[t?e.jsx(Z,{className:"text-muted-foreground size-3.5 shrink-0"}):e.jsx(J,{className:"text-muted-foreground size-3.5 shrink-0"}),e.jsx(l,{className:"text-muted-foreground size-3.5 shrink-0"}),e.jsx("span",{className:"text-[11px] font-semibold",children:s}),n&&e.jsx("span",{className:"text-muted-foreground ml-auto text-[9px]",children:n})]}),t&&e.jsx("div",{className:"px-4 pb-4",children:o})]})}function le({projectPath:s}){const{data:l,isLoading:n,error:r}=M(s);if(n)return e.jsx("p",{className:"text-muted-foreground py-2 text-xs",children:"Loading skills…"});if(r)return e.jsx("p",{className:"text-destructive py-2 text-xs",children:"Failed to load skills."});const o=(l==null?void 0:l.filter(t=>t.type==="skill-pack"))??[];return o.length===0?e.jsx("p",{className:"text-muted-foreground py-2 text-xs",children:"No skills installed. Browse the marketplace to add skills to this agent."}):e.jsx("ul",{className:"space-y-1.5 py-1",children:o.map(t=>e.jsxs("li",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"min-w-0 flex-1 truncate font-mono text-xs",children:t.name}),t.version&&e.jsxs("span",{className:"text-muted-foreground shrink-0 text-[10px]",children:["v",t.version]}),e.jsx(ae,{scope:t.scope})]},t.name))})}function re(){const{agent:s,projectPath:l,onUpdate:n}=Y(),{data:r}=M(l),o=(r==null?void 0:r.filter(c=>c.type==="skill-pack").length)??0,t=q(),i=()=>{t({to:"/marketplace",search:{type:"skill-pack"}})};return e.jsxs("div",{"data-slot":"toolkit-tab",className:"flex flex-col",children:[e.jsxs(R,{title:"Skills",icon:D,meta:o>0?`${o}`:void 0,defaultOpen:!0,children:[e.jsx(le,{projectPath:l}),e.jsxs(O,{variant:"ghost",size:"sm",onClick:i,className:"text-muted-foreground hover:text-foreground mt-2 w-full",children:[e.jsx(D,{className:"mr-1.5 size-3.5"}),"Browse skill-packs"]})]}),e.jsx(R,{title:"Tools & MCP",icon:X,children:e.jsx(ee,{agent:s,projectPath:l,onUpdate:n})})]})}export{re as ToolkitTab};
@@ -0,0 +1 @@
1
+ import{r as x,U as F,V as H,W as I,X as K,Y as $,j as e,Z as p,$ as b,l as v,a0 as V,a1 as g,a2 as w,a3 as f,a4 as j,v as y,w as S,a5 as k,B as O,a6 as W,u as Y,a7 as M,a8 as q,a9 as D,aa as X,s as Z,ab as J}from"./index-BZYDK9c8.js";const u={tasks:["tasks_list","tasks_create","tasks_update","tasks_delete","tasks_get_run_history"],relay:["relay_send","relay_inbox","relay_list_endpoints","relay_register_endpoint","relay_send_and_wait","relay_send_async","relay_unregister_endpoint","relay_get_trace","relay_get_metrics"],mesh:["mesh_discover","mesh_register","mesh_list","mesh_deny","mesh_unregister","mesh_status","mesh_inspect","mesh_query_topology"],adapter:["relay_list_adapters","relay_enable_adapter","relay_disable_adapter","relay_reload_adapters","binding_list","binding_create","binding_delete","binding_list_sessions","relay_notify_user"]};function P({tools:s}){return e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsx(y,{variant:"outline",className:"text-muted-foreground shrink-0 cursor-default text-xs font-normal",children:s.length})}),e.jsx(k,{side:"top",className:"max-w-xs",children:e.jsx("p",{className:"font-mono text-xs",children:s.join(", ")})})]})}function Q({domain:s,agentOverride:l,globalDefault:n,onToggle:r,onReset:o}){const t=l!==void 0,i=l??n;return s.serverDisabled?e.jsx(g,{label:s.label,description:s.description,className:"py-1",children:e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(y,{variant:"secondary",className:"text-xs",children:"Disabled"}),e.jsx(P,{tools:s.tools}),e.jsx(S,{checked:!1,disabled:!0,"aria-label":`Toggle ${s.label} tools`})]})}),e.jsx(k,{side:"left",children:s.serverDisabledReason??"Disabled globally by server configuration."})]})}):e.jsx(g,{label:s.label,description:s.description,className:"py-1",children:e.jsxs("div",{className:"flex items-center gap-2",children:[!t&&e.jsx(y,{variant:"outline",className:"text-muted-foreground text-xs font-normal",children:"default"}),t&&e.jsxs(f,{children:[e.jsx(j,{asChild:!0,children:e.jsx(O,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o(s.key),"aria-label":`Reset ${s.label} to default`,children:e.jsx(W,{className:"size-3"})})}),e.jsx(k,{side:"top",children:"Reset to global default"})]}),e.jsx(P,{tools:s.tools}),e.jsx(S,{checked:i,onCheckedChange:c=>r(s.key,c),"aria-label":`Toggle ${s.label} tools`})]})})}const U={connected:"bg-green-500",failed:"bg-red-500","needs-auth":"bg-amber-500",pending:"bg-amber-500",disabled:"bg-muted-foreground/20"};function ee({agent:s,projectPath:l,onUpdate:n}){var N,T;const[r,o]=x.useState(!1),t=F(),i=H(),{config:c}=I(),{data:h}=K(l,s.runtime),m=$(s.runtime),E=(m==null?void 0:m.supportsMcp)??!0,L=x.useCallback((a,d)=>{const A=s.enabledToolGroups??{};n({enabledToolGroups:{...A,[a]:d}})},[s.enabledToolGroups,n]),G=x.useCallback(a=>{const d={...s.enabledToolGroups??{}};delete d[a],n({enabledToolGroups:d})},[s.enabledToolGroups,n]),B=[{key:"tasks",configKey:"tasksTools",label:"Scheduling",description:"Create and run scheduled agent tasks",tools:u.tasks,serverDisabled:!i,serverDisabledReason:"Disabled globally by server configuration."},{key:"relay",configKey:"relayTools",label:"Messaging",description:"Send and receive messages between agents",tools:u.relay,serverDisabled:!t,serverDisabledReason:"Disabled globally by server configuration."},{key:"mesh",configKey:"meshTools",label:"Agent Discovery",description:"Find and register agents on this machine",tools:u.mesh},{key:"adapter",configKey:"adapterTools",label:"External Channels",description:"Manage connections to Slack, Telegram, and other platforms",tools:u.adapter,serverDisabled:!t,serverDisabledReason:"Disabled globally by server configuration."}],z=s.enabledToolGroups??{},_=((N=s.budget)==null?void 0:N.maxHopsPerMessage)??5,C=((T=s.budget)==null?void 0:T.maxCallsPerHour)??100;return e.jsxs("div",{className:"space-y-4",children:[E?e.jsxs(e.Fragment,{children:[e.jsx("p",{className:"text-muted-foreground text-sm",children:"Control which tool groups are available to this agent. Leave unset to inherit global defaults."}),e.jsx(p,{children:e.jsx(b,{children:B.map(a=>e.jsx(Q,{domain:a,agentOverride:z[a.key],globalDefault:c[a.configKey],onToggle:L,onReset:G},a.key))})}),e.jsx("p",{className:"text-muted-foreground text-xs",children:"Core tools (ping, server info, agent identity) are always available."})]}):e.jsx(p,{children:e.jsx(b,{children:e.jsx("p",{className:"text-muted-foreground text-sm",children:"This agent’s runtime does not support DorkOS tool groups (Scheduling, Messaging, Agent Discovery, External Channels). These are delivered over MCP, which this runtime cannot consume."})})}),h&&h.servers.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("h3",{className:"text-sm font-semibold",children:"MCP Servers"}),e.jsx(p,{children:e.jsx(b,{children:h.servers.map(a=>e.jsxs("div",{className:"flex items-center gap-2 py-0.5",children:[e.jsx("span",{className:v("size-2 shrink-0 rounded-full",U[a.status??""]??"bg-muted-foreground/40")}),e.jsx("span",{className:"min-w-0 truncate text-sm",children:a.name}),e.jsx("span",{className:"text-muted-foreground/50 ml-auto shrink-0 text-xs",children:a.type})]},a.name))})})]}),e.jsxs(V,{open:r,onOpenChange:o,trigger:"Limits",badge:e.jsxs("span",{className:"text-muted-foreground text-xs font-normal",children:[_," hops · ",C," calls/hr"]}),children:[e.jsx(g,{label:"Message forwarding depth",description:"Maximum agents a message can pass through before stopping",orientation:"vertical",children:e.jsx(w,{type:"number",min:1,value:_,onChange:a=>n({budget:{...s.budget,maxHopsPerMessage:parseInt(a.target.value)||5}}),className:"w-24"})}),e.jsx(g,{label:"Hourly rate limit",description:"Maximum tool invocations per hour. The agent pauses when exceeded.",orientation:"vertical",children:e.jsx(w,{type:"number",min:1,value:C,onChange:a=>n({budget:{...s.budget,maxCallsPerHour:parseInt(a.target.value)||100}}),className:"w-24"})})]})]})}const se={global:"global","agent-local":"local",override:"override"},te={global:"bg-muted text-muted-foreground","agent-local":"bg-blue-500/10 text-blue-600 dark:text-blue-400",override:"bg-amber-500/10 text-amber-600 dark:text-amber-400"};function ae({scope:s="global",className:l}){return e.jsx("span",{"data-slot":"scope-badge",className:v("inline-flex items-center rounded-full px-1.5 py-0.5 text-[9px] font-semibold tracking-wide uppercase",te[s],l),children:se[s]})}function R({title:s,icon:l,meta:n,defaultOpen:r=!1,children:o}){const[t,i]=x.useState(r);return e.jsxs("div",{className:"border-b last:border-b-0",children:[e.jsxs("button",{type:"button",onClick:()=>i(!t),className:v("hover:bg-accent/50 flex w-full items-center gap-2 px-4 py-2.5 text-left transition-colors"),"aria-expanded":t,children:[t?e.jsx(Z,{className:"text-muted-foreground size-3.5 shrink-0"}):e.jsx(J,{className:"text-muted-foreground size-3.5 shrink-0"}),e.jsx(l,{className:"text-muted-foreground size-3.5 shrink-0"}),e.jsx("span",{className:"text-[11px] font-semibold",children:s}),n&&e.jsx("span",{className:"text-muted-foreground ml-auto text-[9px]",children:n})]}),t&&e.jsx("div",{className:"px-4 pb-4",children:o})]})}function le({projectPath:s}){const{data:l,isLoading:n,error:r}=M(s);if(n)return e.jsx("p",{className:"text-muted-foreground py-2 text-xs",children:"Loading skills…"});if(r)return e.jsx("p",{className:"text-destructive py-2 text-xs",children:"Failed to load skills."});const o=(l==null?void 0:l.filter(t=>t.type==="skill-pack"))??[];return o.length===0?e.jsx("p",{className:"text-muted-foreground py-2 text-xs",children:"No skills installed. Browse the marketplace to add skills to this agent."}):e.jsx("ul",{className:"space-y-1.5 py-1",children:o.map(t=>e.jsxs("li",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"min-w-0 flex-1 truncate font-mono text-xs",children:t.name}),t.version&&e.jsxs("span",{className:"text-muted-foreground shrink-0 text-[10px]",children:["v",t.version]}),e.jsx(ae,{scope:t.scope})]},t.name))})}function re(){const{agent:s,projectPath:l,onUpdate:n}=Y(),{data:r}=M(l),o=(r==null?void 0:r.filter(c=>c.type==="skill-pack").length)??0,t=q(),i=()=>{t({to:"/marketplace",search:{type:"skill-pack"}})};return e.jsxs("div",{"data-slot":"toolkit-tab",className:"flex flex-col",children:[e.jsxs(R,{title:"Skills",icon:D,meta:o>0?`${o}`:void 0,defaultOpen:!0,children:[e.jsx(le,{projectPath:l}),e.jsxs(O,{variant:"ghost",size:"sm",onClick:i,className:"text-muted-foreground hover:text-foreground mt-2 w-full",children:[e.jsx(D,{className:"mr-1.5 size-3.5"}),"Browse skill-packs"]})]}),e.jsx(R,{title:"Tools & MCP",icon:X,children:e.jsx(ee,{agent:s,projectPath:l,onUpdate:n})})]})}export{re as ToolkitTab};
@@ -1,4 +1,4 @@
1
- import{ag as hRn,cv as aRn,cc as dRn,r as sn,j as le,cd as Oan,t as bRn,bn as wRn,cw as gRn,cx as pRn,bR as oK,bS as Nan,B as sK,bT as $an,l as Km,cy as p2e,cz as m2e,aU as mRn,v as Rx,b6 as vRn,aW as Uge,aV as yRn,bm as kRn,cA as jRn,cB as ERn,cC as Ahn,ac as xRn,cD as ARn,bN as MRn,cE as CRn,U as TRn,cF as SRn,b9 as IRn,bb as PRn,bc as ORn,al as Mhn,a6 as NRn,bf as $Rn,as as DRn,at as LRn,au as _Rn,av as FRn,aw as RRn,ax as BRn,ay as JRn,az as GRn}from"./index-sKKm7yEm.js";/**
1
+ import{ag as hRn,cv as aRn,cc as dRn,r as sn,j as le,cd as Oan,t as bRn,bn as wRn,cw as gRn,cx as pRn,bR as oK,bS as Nan,B as sK,bT as $an,l as Km,cy as p2e,cz as m2e,aU as mRn,v as Rx,b6 as vRn,aW as Uge,aV as yRn,bm as kRn,cA as jRn,cB as ERn,cC as Ahn,ac as xRn,cD as ARn,bN as MRn,cE as CRn,U as TRn,cF as SRn,b9 as IRn,bb as PRn,bc as ORn,al as Mhn,a6 as NRn,bf as $Rn,as as DRn,at as LRn,au as _Rn,av as FRn,aw as RRn,ax as BRn,ay as JRn,az as GRn}from"./index-BNSNg7yH.js";/**
2
2
  * @license lucide-react v1.21.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.