agentix-cli 0.83.0 → 0.83.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{App-CREMUAHS.js → App-3CNSN65B.js} +2 -2
- package/dist/{ChatApp-YX3YNPNS.js → ChatApp-6RBH5UEC.js} +2 -2
- package/dist/{agent-3PJF4PUE.js → agent-C2DHSDPG.js} +2 -2
- package/dist/{board-dashboard-7B2GNISR.js → board-dashboard-DJMGIUXC.js} +21 -21
- package/dist/board-dashboard-DJMGIUXC.js.map +1 -0
- package/dist/{chunk-WMIQHJB5.js → chunk-7R6BHIPA.js} +2 -2
- package/dist/{chunk-JDXNHBGR.js → chunk-7UUPDBXP.js} +15 -15
- package/dist/chunk-7UUPDBXP.js.map +1 -0
- package/dist/{chunk-AACJ62ID.js → chunk-AO73YQRI.js} +2 -2
- package/dist/{chunk-AXQIFHOX.js → chunk-DGSLKE3Z.js} +2 -2
- package/dist/{chunk-ZUINXZPI.js → chunk-DJ57LID5.js} +2 -2
- package/dist/{chunk-MDYARXA4.js → chunk-DY4GWAG2.js} +2 -2
- package/dist/{chunk-KNSYKQKB.js → chunk-F2BICD4J.js} +2 -2
- package/dist/{chunk-K2NFNNDB.js → chunk-J2OPXEID.js} +2 -2
- package/dist/{chunk-DND5VBG5.js → chunk-NCY5Z7Y5.js} +225 -225
- package/dist/chunk-NCY5Z7Y5.js.map +1 -0
- package/dist/{chunk-IMFB2KTJ.js → chunk-O2CQ6HIH.js} +2 -2
- package/dist/{chunk-ZNLBF4ED.js → chunk-QD5HZPDN.js} +2 -2
- package/dist/{chunk-3AXSSYSY.js → chunk-QMXRZ7NZ.js} +2 -2
- package/dist/{chunk-IUQOOSD4.js → chunk-RMREPXEE.js} +2 -2
- package/dist/{chunk-QZ3CLHGL.js → chunk-SHYZJU73.js} +2 -2
- package/dist/{chunk-AK5J3DQY.js → chunk-SL4UN3MQ.js} +2 -2
- package/dist/{chunk-HJZFDQKD.js → chunk-SQAZ6XRV.js} +2 -2
- package/dist/{chunk-WYYNJTDC.js → chunk-TH7O37GJ.js} +72 -72
- package/dist/chunk-TH7O37GJ.js.map +1 -0
- package/dist/{chunk-WGZPKQNI.js → chunk-TIO5O5KS.js} +2 -2
- package/dist/{chunk-EBDUPZ7C.js → chunk-TXPRTOON.js} +38 -44
- package/dist/chunk-TXPRTOON.js.map +1 -0
- package/dist/{chunk-2W3UVIEG.js → chunk-VT7NIJVK.js} +23 -17
- package/dist/chunk-VT7NIJVK.js.map +1 -0
- package/dist/{chunk-XGTZMJUI.js → chunk-XWON33RF.js} +2 -2
- package/dist/cli.js +1 -1
- package/dist/{client-K5ZISLAI.js → client-CGZ3XXAA.js} +2 -2
- package/dist/{config-ZBNH2DMN.js → config-PTBPLRVQ.js} +2 -2
- package/dist/config-mutator-QVETJAFD.js +2 -0
- package/dist/{doctor-Y3GPTM3C.js → doctor-RGUJJURY.js} +2 -2
- package/dist/index.d.ts +20 -0
- package/dist/index.js +1 -1
- package/dist/{program-Y5BSOGQQ.js → program-QKNNDRP6.js} +132 -132
- package/dist/program-QKNNDRP6.js.map +1 -0
- package/dist/{promote-KLA3DBKX.js → promote-7BCIFXE7.js} +2 -2
- package/dist/{query-N3BRQU6S.js → query-QHUQDZ3P.js} +2 -2
- package/dist/{registry-GHOOAS2Z.js → registry-QJVKEZV6.js} +2 -2
- package/dist/{request-planner-ABXJ35NE.js → request-planner-LATURRJL.js} +2 -2
- package/dist/{review-candidates-UFVMO3IT.js → review-candidates-27LHBY44.js} +2 -2
- package/dist/{routing-GOOV7H7I.js → routing-O6PD6ULG.js} +2 -2
- package/dist/schedule-tool-FHWMYWVQ.js +2 -0
- package/dist/scheduler-BCLXHHPJ.js +2 -0
- package/dist/{seat-E4FYHBIC.js → seat-PUTTNNVU.js} +2 -2
- package/dist/{select-6QI65HKR.js → select-APGSUM4S.js} +2 -2
- package/dist/{set-enabled-XPIHHOPT.js → set-enabled-5LLEUDTZ.js} +2 -2
- package/dist/{tool-UK5MDLBQ.js → tool-7JH2ZKED.js} +2 -2
- package/dist/{tool-IX7B5CYT.js → tool-DQICJQ6Z.js} +2 -2
- package/dist/wiki-7ZTUI57I.js +2 -0
- package/package.json +1 -1
- package/dist/board-dashboard-7B2GNISR.js.map +0 -1
- package/dist/chunk-2W3UVIEG.js.map +0 -1
- package/dist/chunk-DND5VBG5.js.map +0 -1
- package/dist/chunk-EBDUPZ7C.js.map +0 -1
- package/dist/chunk-JDXNHBGR.js.map +0 -1
- package/dist/chunk-WYYNJTDC.js.map +0 -1
- package/dist/config-mutator-ENWFEDFU.js +0 -2
- package/dist/program-Y5BSOGQQ.js.map +0 -1
- package/dist/schedule-tool-KKH32REI.js +0 -2
- package/dist/scheduler-NBRWUJAD.js +0 -2
- package/dist/wiki-XSK3IIZE.js +0 -2
- /package/dist/{App-CREMUAHS.js.map → App-3CNSN65B.js.map} +0 -0
- /package/dist/{ChatApp-YX3YNPNS.js.map → ChatApp-6RBH5UEC.js.map} +0 -0
- /package/dist/{agent-3PJF4PUE.js.map → agent-C2DHSDPG.js.map} +0 -0
- /package/dist/{chunk-WMIQHJB5.js.map → chunk-7R6BHIPA.js.map} +0 -0
- /package/dist/{chunk-AACJ62ID.js.map → chunk-AO73YQRI.js.map} +0 -0
- /package/dist/{chunk-AXQIFHOX.js.map → chunk-DGSLKE3Z.js.map} +0 -0
- /package/dist/{chunk-ZUINXZPI.js.map → chunk-DJ57LID5.js.map} +0 -0
- /package/dist/{chunk-MDYARXA4.js.map → chunk-DY4GWAG2.js.map} +0 -0
- /package/dist/{chunk-KNSYKQKB.js.map → chunk-F2BICD4J.js.map} +0 -0
- /package/dist/{chunk-K2NFNNDB.js.map → chunk-J2OPXEID.js.map} +0 -0
- /package/dist/{chunk-IMFB2KTJ.js.map → chunk-O2CQ6HIH.js.map} +0 -0
- /package/dist/{chunk-ZNLBF4ED.js.map → chunk-QD5HZPDN.js.map} +0 -0
- /package/dist/{chunk-3AXSSYSY.js.map → chunk-QMXRZ7NZ.js.map} +0 -0
- /package/dist/{chunk-IUQOOSD4.js.map → chunk-RMREPXEE.js.map} +0 -0
- /package/dist/{chunk-QZ3CLHGL.js.map → chunk-SHYZJU73.js.map} +0 -0
- /package/dist/{chunk-AK5J3DQY.js.map → chunk-SL4UN3MQ.js.map} +0 -0
- /package/dist/{chunk-HJZFDQKD.js.map → chunk-SQAZ6XRV.js.map} +0 -0
- /package/dist/{chunk-WGZPKQNI.js.map → chunk-TIO5O5KS.js.map} +0 -0
- /package/dist/{chunk-XGTZMJUI.js.map → chunk-XWON33RF.js.map} +0 -0
- /package/dist/{client-K5ZISLAI.js.map → client-CGZ3XXAA.js.map} +0 -0
- /package/dist/{config-ZBNH2DMN.js.map → config-PTBPLRVQ.js.map} +0 -0
- /package/dist/{config-mutator-ENWFEDFU.js.map → config-mutator-QVETJAFD.js.map} +0 -0
- /package/dist/{doctor-Y3GPTM3C.js.map → doctor-RGUJJURY.js.map} +0 -0
- /package/dist/{promote-KLA3DBKX.js.map → promote-7BCIFXE7.js.map} +0 -0
- /package/dist/{query-N3BRQU6S.js.map → query-QHUQDZ3P.js.map} +0 -0
- /package/dist/{registry-GHOOAS2Z.js.map → registry-QJVKEZV6.js.map} +0 -0
- /package/dist/{request-planner-ABXJ35NE.js.map → request-planner-LATURRJL.js.map} +0 -0
- /package/dist/{review-candidates-UFVMO3IT.js.map → review-candidates-27LHBY44.js.map} +0 -0
- /package/dist/{routing-GOOV7H7I.js.map → routing-O6PD6ULG.js.map} +0 -0
- /package/dist/{schedule-tool-KKH32REI.js.map → schedule-tool-FHWMYWVQ.js.map} +0 -0
- /package/dist/{scheduler-NBRWUJAD.js.map → scheduler-BCLXHHPJ.js.map} +0 -0
- /package/dist/{seat-E4FYHBIC.js.map → seat-PUTTNNVU.js.map} +0 -0
- /package/dist/{select-6QI65HKR.js.map → select-APGSUM4S.js.map} +0 -0
- /package/dist/{set-enabled-XPIHHOPT.js.map → set-enabled-5LLEUDTZ.js.map} +0 -0
- /package/dist/{tool-UK5MDLBQ.js.map → tool-7JH2ZKED.js.map} +0 -0
- /package/dist/{tool-IX7B5CYT.js.map → tool-DQICJQ6Z.js.map} +0 -0
- /package/dist/{wiki-XSK3IIZE.js.map → wiki-7ZTUI57I.js.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{q as p}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{q as p}from"./chunk-RMREPXEE.js";import{b as i,c as u,d as l,e as c}from"./chunk-7R6BHIPA.js";import d from"cronstrue";var f=Intl.DateTimeFormat().resolvedOptions().timeZone,m=600,E='Try: "every morning at 9", "weekdays at 6pm", "every 15 minutes", "every monday at 10am", "1st of every month at noon", "daily at 9:30am", "every hour"',g=/^[A-Za-z0-9][A-Za-z0-9_-]{0,63}$/;function w(e){return g.test(e)}function x(e){try{return new Intl.DateTimeFormat("en-US",{timeZone:e}),!0}catch{return!1}}function $(e){return e?e.split(",").map(r=>r.trim().toLowerCase()).filter(r=>r==="log"||r==="notify"||r==="disable"):["log"]}function S(e){let r=[...e.onError??["log"]];e.notify&&!r.includes("notify")&&r.push("notify");let t={enabled:e.enabled??!0,schedule:e.parsed.cron,timezone:e.timezone||f,agent:e.agent,prompt:e.prompt,timeout:e.timeout??m,onError:r};return e.model&&(t.model=e.model),e.notify&&(t.notify=e.notify),e.createdBy&&(t.createdBy=e.createdBy),e.approval&&(t.approval=e.approval),t}function P(e){try{return d.toString(e,{use24HourTimeFormat:!1})}catch{return e}}function T(e,r,t=new Date){try{return p(e,t,r)}catch{return null}}function A(e,r){if(!e)return"unknown (no match within a year)";try{return`${new Intl.DateTimeFormat("en-GB",{timeZone:r,weekday:"short",day:"2-digit",month:"short",year:"numeric",hour:"2-digit",minute:"2-digit",hour12:!1}).format(e)} (${r})`}catch{return e.toISOString()}}function h(e){return e?.approval?.action==="create"}async function D(e,r={}){let t="",o=await i(n=>{let a=l(n,`crons.${e}`);if(!a)throw new Error(`cron "${e}" not found`);let s=a.approval;if(!s)throw new Error(`cron "${e}" has no pending request`);s.action==="create"?(delete a.approval,a.enabled=!0,t=`${e} approved and enabled (requested by ${s.requestedBy})`):(c(n,`crons.${e}`),t=`${e} deletion approved; job removed (requested by ${s.requestedBy})`)},{configPath:r.configPath,reload:r.reload});return o.success?{success:!0,message:t,result:o}:{success:!1,message:o.error||"failed",result:o}}async function I(e,r={}){let t="",o=await i(n=>{let a=l(n,`crons.${e}`);if(!a)throw new Error(`cron "${e}" not found`);let s=a.approval;if(!s)throw new Error(`cron "${e}" has no pending request`);s.action==="create"?(c(n,`crons.${e}`),t=`${e} rejected; pending job removed`):(delete a.approval,t=`${e} deletion rejected; job kept`)},{configPath:r.configPath,reload:r.reload});return o.success?{success:!0,message:t,result:o}:{success:!1,message:o.error||"failed",result:o}}async function O(e,r,t={}){return i(o=>{let n=l(o,`crons.${e}`);if(!n)throw new Error(`cron "${e}" not found`);if(r&&h(n))throw new Error(`cron "${e}" is awaiting approval; run \`agentx schedule approve ${e}\``);u(o,`crons.${e}.enabled`,r)},{configPath:t.configPath,reload:t.reload})}export{f as a,E as b,w as c,x as d,$ as e,S as f,P as g,T as h,A as i,h as j,D as k,I as l,O as m};
|
|
2
|
+
//# sourceMappingURL=chunk-XWON33RF.js.map
|
package/dist/cli.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{b as o}from"./chunk-JXF54PT7.js";import"./chunk-QIJLFPWE.js";var s=o(process.versions.node);s&&(console.error(s),process.exit(1));var{buildProgram:r}=await import("./program-
|
|
2
|
+
import{b as o}from"./chunk-JXF54PT7.js";import"./chunk-QIJLFPWE.js";var s=o(process.versions.node);s&&(console.error(s),process.exit(1));var{buildProgram:r}=await import("./program-QKNNDRP6.js"),{installCliSignalExit:i}=await import("./signal-exit-WL7G3EEZ.js");i();var e=await r();process.argv.slice(2).length===0?e.outputHelp():e.parse();
|
|
3
3
|
//# sourceMappingURL=cli.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b,c,d,e,f,g}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=client-
|
|
1
|
+
import{a,b,c,d,e,f,g}from"./chunk-QD5HZPDN.js";import"./chunk-7UUPDBXP.js";import"./chunk-PN6XHTG5.js";import"./chunk-BRK6M6LA.js";import"./chunk-2QNT5JDS.js";import"./chunk-QIJLFPWE.js";export{b as fetchAgents,d as fetchCrons,c as fetchProcesses,e as killProcess,a as resolveConn,f as sendTask,g as streamTask};
|
|
2
|
+
//# sourceMappingURL=client-CGZ3XXAA.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{$ as n,O as a,P as b,Q as c,R as d,S as e,T as f,U as g,V as h,W as i,X as j,Y as k,Z as l,_ as m,ba as o}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=config-
|
|
1
|
+
import{$ as n,O as a,P as b,Q as c,R as d,S as e,T as f,U as g,V as h,W as i,X as j,Y as k,Z as l,_ as m,ba as o}from"./chunk-7UUPDBXP.js";import"./chunk-PN6XHTG5.js";import"./chunk-BRK6M6LA.js";import"./chunk-2QNT5JDS.js";import"./chunk-QIJLFPWE.js";o();export{a as INTEGRATION_KINDS,j as approvalsConfigSchema,d as callsSchema,c as cameraBotSchema,k as daemonConfigSchema,b as eventSubscriptionSchema,l as expandEnvVars,m as loadDaemonConfig,h as membersConfigSchema,g as peopleConfigSchema,f as personSchema,i as requestStatusConfigSchema,e as requestsConfigSchema,n as validateWorkspaces};
|
|
2
|
+
//# sourceMappingURL=config-PTBPLRVQ.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a,b,c,d,e}from"./chunk-7R6BHIPA.js";import"./chunk-7UUPDBXP.js";import"./chunk-PN6XHTG5.js";import"./chunk-BRK6M6LA.js";import"./chunk-2QNT5JDS.js";import"./chunk-QIJLFPWE.js";export{b as applyConfigMutation,a as findConfigPath,d as getAtPath,c as setAtPath,e as unsetAtPath};
|
|
2
|
+
//# sourceMappingURL=config-mutator-QVETJAFD.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as a,c as b,d as c,e as d,f as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=doctor-
|
|
1
|
+
import{b as a,c as b,d as c,e as d,f as e}from"./chunk-SL4UN3MQ.js";import"./chunk-S2GAEH2F.js";import"./chunk-JXF54PT7.js";import"./chunk-7UUPDBXP.js";import"./chunk-PN6XHTG5.js";import"./chunk-BRK6M6LA.js";import"./chunk-2QNT5JDS.js";import"./chunk-QIJLFPWE.js";export{e as daemonVoiceCheck,b as doctor,a as runDoctorChecks,c as runNotificationChecks,d as runReminderChecks};
|
|
2
|
+
//# sourceMappingURL=doctor-RGUJJURY.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -8121,6 +8121,9 @@ declare class A2AMesh {
|
|
|
8121
8121
|
messageId?: string;
|
|
8122
8122
|
accountId?: string;
|
|
8123
8123
|
};
|
|
8124
|
+
/** This node checked its own operator key on the forward: tell the
|
|
8125
|
+
* peer the turn is the owner's (requests/operator, #407). */
|
|
8126
|
+
vouchOwner?: boolean;
|
|
8124
8127
|
}): Promise<string>;
|
|
8125
8128
|
/**
|
|
8126
8129
|
* Streaming variant of `sendTask`. POSTs to the peer's `/task` with
|
|
@@ -8142,6 +8145,8 @@ declare class A2AMesh {
|
|
|
8142
8145
|
/** Aborts the peer call; the peer's /task treats it as a disconnect
|
|
8143
8146
|
* and interrupts the run. */
|
|
8144
8147
|
signal?: AbortSignal;
|
|
8148
|
+
/** See sendTask. */
|
|
8149
|
+
vouchOwner?: boolean;
|
|
8145
8150
|
}): AsyncGenerator<{
|
|
8146
8151
|
event: string;
|
|
8147
8152
|
data: any;
|
|
@@ -8826,6 +8831,8 @@ declare class AgentXDaemon {
|
|
|
8826
8831
|
* such a channel gets an ordinary turn, never recorded as a request
|
|
8827
8832
|
* of the owner (#393). */
|
|
8828
8833
|
private markOperatorTurn;
|
|
8834
|
+
/** On a forward to a peer: did the owner's surface show this node's key? */
|
|
8835
|
+
private operatorVouchFor;
|
|
8829
8836
|
/** What the guest-mesh routes need from the daemon (guests/daemon-api.ts). */
|
|
8830
8837
|
private guestDeps;
|
|
8831
8838
|
private callerProof;
|
|
@@ -11301,6 +11308,15 @@ declare class AgentRegistry {
|
|
|
11301
11308
|
/** Swap the people list on a config reload (#384). Turns read it when
|
|
11302
11309
|
* they start, so the next turn is stamped from the new list. */
|
|
11303
11310
|
setPeople(people: DaemonConfig["people"]): void;
|
|
11311
|
+
/** People permissions (#379): the note a limited person is answered with
|
|
11312
|
+
* instead of reaching `agentId`, or null when the turn may go ahead. The
|
|
11313
|
+
* limit follows them through a delegation (the root's person). Every way
|
|
11314
|
+
* to an agent asks here before it starts: a run on this node, and the
|
|
11315
|
+
* router and delegation paths to a mesh peer, which cannot check for
|
|
11316
|
+
* itself (person ids are per machine). A refusal is kept in the
|
|
11317
|
+
* per-person trail. */
|
|
11318
|
+
refusalFor(agentId: string, ctx: unknown): string | null;
|
|
11319
|
+
private memberLog?;
|
|
11304
11320
|
/**
|
|
11305
11321
|
* If there's an active handover routing TO this agent for this (channel,
|
|
11306
11322
|
* chatId) pair AND the operator's summary hasn't been consumed yet, pull
|
|
@@ -12723,6 +12739,10 @@ declare class MessageRouter {
|
|
|
12723
12739
|
* task and a locally-routed task produce the same session keying and
|
|
12724
12740
|
* the same prompt context. */
|
|
12725
12741
|
private buildMeshContext;
|
|
12742
|
+
/** People permissions (#379): a limited person is answered here, before
|
|
12743
|
+
* the message leaves for a peer, which cannot check it (person ids are
|
|
12744
|
+
* per machine). True when refused. */
|
|
12745
|
+
private refusedForPerson;
|
|
12726
12746
|
private handleViaMesh;
|
|
12727
12747
|
/**
|
|
12728
12748
|
* Route to a mesh peer by resolved agentId (not text matching).
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as St,b as kt,c as vt,ca as Tt,d as xt,da as Mt,e as $t,f as Ct,g as Pt,h as bt}from"./chunk-
|
|
1
|
+
import{a as St,b as kt,c as vt,ca as Tt,d as xt,da as Mt,e as $t,f as Ct,g as Pt,h as bt}from"./chunk-NCY5Z7Y5.js";import"./chunk-O2CQ6HIH.js";import"./chunk-GTJIKXDB.js";import"./chunk-F2BICD4J.js";import"./chunk-CL53UVOF.js";import"./chunk-ZVP6GB4G.js";import"./chunk-S2GAEH2F.js";import"./chunk-VZLIBDLH.js";import"./chunk-EKJG63EJ.js";import"./chunk-DY4GWAG2.js";import"./chunk-2AXFYDWF.js";import"./chunk-AQASR6KR.js";import"./chunk-ACFQBLPX.js";import"./chunk-LQE73AZR.js";import"./chunk-2D3RYIDU.js";import"./chunk-4L244AW4.js";import"./chunk-XIYWXCNU.js";import"./chunk-PPUN7YHA.js";import{U as yt,l as lt,m as ct,n as dt,o as mt,p as pt}from"./chunk-TH7O37GJ.js";import"./chunk-VT7NIJVK.js";import"./chunk-GLQLCBJS.js";import"./chunk-DP7RTNDM.js";import{a as L}from"./chunk-C245D4BZ.js";import{A as D,B as z,C as V,a as ye,b as we,c as Se,d as Ae,e as Ie,f as Oe,g as Ne,h as He,i as je,j as Ue,k as _e,l as I,m as q,n as Be,o as qe,p as Ye,q as O,r as ze,s as Ve,t as Xe,u as x,v as Y,w as Qe,x as Ze,y as et,z as wt}from"./chunk-AO73YQRI.js";import{a as B,b as M,c as F}from"./chunk-SFQUP3BP.js";import"./chunk-Y4CYQV7G.js";import"./chunk-LLNPKE7H.js";import"./chunk-SHEUCITK.js";import"./chunk-XWON33RF.js";import"./chunk-SZDACK6O.js";import"./chunk-76Z4VHDX.js";import"./chunk-W4YR2RO2.js";import"./chunk-AFRHKA7B.js";import{s as ut}from"./chunk-RMREPXEE.js";import"./chunk-7R6BHIPA.js";import"./chunk-VWTBHLMX.js";import"./chunk-DJ57LID5.js";import{a as ht}from"./chunk-TIO5O5KS.js";import"./chunk-KA2UIZXG.js";import"./chunk-GQ76J72O.js";import"./chunk-ILEC3IAV.js";import"./chunk-J3SOEFRE.js";import"./chunk-SIU6STB2.js";import"./chunk-X5C5W3E4.js";import"./chunk-GV7S5BAX.js";import"./chunk-GSX4NK2N.js";import"./chunk-DGSLKE3Z.js";import"./chunk-MYVHVJWZ.js";import"./chunk-DWADWDMU.js";import"./chunk-23A5K5UW.js";import"./chunk-QD6IICK7.js";import"./chunk-CECHWYJ2.js";import"./chunk-SQAZ6XRV.js";import{f as gt,g as ft}from"./chunk-SHYZJU73.js";import"./chunk-WPNRDEHW.js";import"./chunk-2GIDVZ4H.js";import{j as it,k as rt,l as at}from"./chunk-J2OPXEID.js";import"./chunk-72SZI2UW.js";import"./chunk-FX3D7YON.js";import"./chunk-FCPTN6NF.js";import"./chunk-QOYAX2FT.js";import{a as ke,b as ve,c as xe,d as $e,e as Ce,f as Pe,g as be,h as Te,i as Me,j as Re,l as Ee,m as Ge,o as T,p as W}from"./chunk-5MUJZODV.js";import{a as m,b as G}from"./chunk-7I7IEX4S.js";import{b as Fe,c as Le,d as A,e as De}from"./chunk-JHCI6XCJ.js";import{a as Ke,b as Je,e as We}from"./chunk-DSYKYZMT.js";import{$ as ot,Y as tt,_ as st,ba as nt}from"./chunk-7UUPDBXP.js";import"./chunk-PN6XHTG5.js";import"./chunk-BRK6M6LA.js";import"./chunk-2QNT5JDS.js";import"./chunk-RGDKHYY2.js";import"./chunk-QIJLFPWE.js";W();G();import{execa as Rt}from"execa";import{existsSync as se,promises as X}from"fs";import S from"path";import ie from"node-fetch";async function Et(o,e){let t=o.split("/");if(t.length<2)throw new Error(`Invalid skill package ID: ${o}. Expected format: owner/repo`);let s=t[0],i=t[1],n=t[2];try{let a=n?`${s}/${i}/${n}`:`${s}/${i}`;await Rt("npx",["-y","skills","add",a],{cwd:e,stdio:"pipe"}),m.success(`Installed skill package: ${o}`);let r=S.resolve(e,".skills",`${s}_${i}`);if(se(r))return await ne(r,o);let d=S.resolve(e,".skills");return se(d)?await ne(d,o):[]}catch{return m.info(`Fetching skills directly from GitHub: ${s}/${i}`),await Gt(s,i,n,e)}}async function Gt(o,e,t,s){let i=[];try{let n=`https://api.github.com/repos/${o}/${e}/git/trees/main?recursive=1`,a=await ie(n);if(!a.ok)throw new Error(`GitHub API error: ${a.status}`);let d=(await a.json()).tree.filter(p=>p.type==="blob"&&p.path.endsWith("SKILL.md"));if(t){let p=d.find(f=>f.path.includes(`/${t}/`)||f.path===`${t}/SKILL.md`);if(p){let f=await oe(o,e,p.path,s);f&&i.push(f)}}else for(let p of d){let f=await oe(o,e,p.path,s);f&&i.push(f)}}catch(n){m.error(`Failed to fetch skills from GitHub: ${n.message}`)}return i}async function oe(o,e,t,s){try{let i=`https://raw.githubusercontent.com/${o}/${e}/main/${t}`,n=await ie(i);if(!n.ok)return null;let a=await n.text(),r=A(a);if(r){r.source="remote",r.packageId=`${o}/${e}`;let d=S.dirname(t),p=S.resolve(s,".skills",`${o}_${e}`,d);await X.mkdir(p,{recursive:!0}),await X.writeFile(S.resolve(p,"SKILL.md"),a),r.path=S.resolve(p,"SKILL.md")}return r}catch{return null}}async function ne(o,e){let t=[],{default:s}=await import("fast-glob"),i=await s.glob("**/SKILL.md",{cwd:o,deep:5});for(let n of i)try{let a=S.resolve(o,n),r=await X.readFile(a,"utf8"),d=A(r);d&&(d.source="remote",d.path=a,d.packageId=e,t.push(d))}catch{}return t}async function At(o,e,t,s,i){let n=["---",`name: ${o}`,`description: ${e}`];if(s?.length){n.push("tags:");for(let a of s)n.push(` - ${a}`)}if(i?.length){n.push("globs:");for(let a of i)n.push(` - ${a}`)}return n.push("---"),`${n.join(`
|
|
2
2
|
`)}
|
|
3
3
|
|
|
4
4
|
${t}`}async function It(o){let{loadLocalSkills:e}=await import("./loader-YFVSSYSL.js");return e(o)}async function Ot(o,e,t,s,i){let a=[{role:"system",content:`You are a skill author for the Agent Skills ecosystem (skills.sh).
|