noskills 4.5.2 → 5.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -646
- package/dist/launcher.js +162 -0
- package/dist/noskills.js +38 -0
- package/package.json +33 -5
- package/chunks/ajan-bridge-BNPC757J.js +0 -1
- package/chunks/anthropic-ZKOMTKX2.js +0 -1
- package/chunks/approve-3TKOHYHH.js +0 -1
- package/chunks/ask-UB26SBWQ.js +0 -2
- package/chunks/block-Q4WAIX7X.js +0 -1
- package/chunks/browser-BGFD24RX.js +0 -1
- package/chunks/bun-WZ7BVR7Y.js +0 -1
- package/chunks/cancel-DY76ADX4.js +0 -1
- package/chunks/chunk-34RPTI4K.js +0 -29
- package/chunks/chunk-3JTDWOAJ.js +0 -2
- package/chunks/chunk-5FX4EBFY.js +0 -5
- package/chunks/chunk-5OTECUN7.js +0 -1
- package/chunks/chunk-5RLCKUIF.js +0 -2
- package/chunks/chunk-7PBHRFOZ.js +0 -3
- package/chunks/chunk-7PPUGTKL.js +0 -4
- package/chunks/chunk-AB3N327V.js +0 -1
- package/chunks/chunk-AUZWXMWA.js +0 -27
- package/chunks/chunk-BYPCI5VU.js +0 -1
- package/chunks/chunk-CH6A3LES.js +0 -91
- package/chunks/chunk-CKIZYL4O.js +0 -3
- package/chunks/chunk-CTTMQSHF.js +0 -1
- package/chunks/chunk-DEHRWREM.js +0 -1
- package/chunks/chunk-DYCGJ4RY.js +0 -4
- package/chunks/chunk-EJYSOUEA.js +0 -1
- package/chunks/chunk-ENP4P2YH.js +0 -0
- package/chunks/chunk-EROZRDGT.js +0 -2
- package/chunks/chunk-EVJYA7S3.js +0 -21
- package/chunks/chunk-FE4MKOI4.js +0 -1
- package/chunks/chunk-FYFUEK4U.js +0 -3
- package/chunks/chunk-GNMOE7H3.js +0 -48
- package/chunks/chunk-HB62UGZI.js +0 -2
- package/chunks/chunk-HISXAZ4Y.js +0 -1
- package/chunks/chunk-I4Z2RF7L.js +0 -31
- package/chunks/chunk-IFE5SYGK.js +0 -1
- package/chunks/chunk-IM73MYMS.js +0 -1
- package/chunks/chunk-J25XTDQQ.js +0 -1
- package/chunks/chunk-JYVB6UAV.js +0 -1
- package/chunks/chunk-KJLEPI7T.js +0 -1
- package/chunks/chunk-KRRPOVQG.js +0 -1
- package/chunks/chunk-LGQEWL5X.js +0 -1
- package/chunks/chunk-LJEWPIEI.js +0 -1
- package/chunks/chunk-LKZZ4JN5.js +0 -110
- package/chunks/chunk-NGCBWJML.js +0 -2
- package/chunks/chunk-NPWXEWRN.js +0 -4
- package/chunks/chunk-O4KKKYCH.js +0 -1
- package/chunks/chunk-OAWYVETM.js +0 -1
- package/chunks/chunk-ONJVI5AZ.js +0 -23
- package/chunks/chunk-OP4XAIGW.js +0 -1
- package/chunks/chunk-PSX63TYP.js +0 -2
- package/chunks/chunk-Q4TI7EYT.js +0 -5
- package/chunks/chunk-SLO22P65.js +0 -1
- package/chunks/chunk-T6NZVA6P.js +0 -7
- package/chunks/chunk-TCSIXKUD.js +0 -3
- package/chunks/chunk-VJRCTYGL.js +0 -1
- package/chunks/chunk-VXU6XZ66.js +0 -39
- package/chunks/chunk-WDKWHGJU.js +0 -146
- package/chunks/chunk-XDPATEP5.js +0 -1
- package/chunks/chunk-XDRX4ZBJ.js +0 -5
- package/chunks/chunk-Y45DQJSS.js +0 -3
- package/chunks/chunk-Y5E7ZCCX.js +0 -1
- package/chunks/chunk-YUTDPPXX.js +0 -1
- package/chunks/chunk-Z7OYXH3J.js +0 -1
- package/chunks/claude-code-OQJIUKZP.js +0 -1
- package/chunks/cmd-46ZIHXLB.js +0 -1
- package/chunks/concern-UIGVWDFS.js +0 -1
- package/chunks/config-72Z4PIJN.js +0 -1
- package/chunks/decision-ledger-5IPPTRT7.js +0 -1
- package/chunks/delegate-OV6NY434.js +0 -1
- package/chunks/deno-YM5PW6ZM.js +0 -1
- package/chunks/diagrams-CBCUA47B.js +0 -1
- package/chunks/diagrams-OX4FBDGP.js +0 -1
- package/chunks/dist-3MH5UCQU.js +0 -12
- package/chunks/done-V54GSSTY.js +0 -1
- package/chunks/followup-NL7EPIGF.js +0 -1
- package/chunks/free-KD344KRL.js +0 -1
- package/chunks/gemini-23EOEXSF.js +0 -1
- package/chunks/init-WDRNFT57.js +0 -1
- package/chunks/invoke-hook-I3NTD36Q.js +0 -13
- package/chunks/kiro-TPAAIMY6.js +0 -1
- package/chunks/learn-WBWNJEB2.js +0 -7
- package/chunks/ledger-QYK252DV.js +0 -1
- package/chunks/list-WO6RS7JX.js +0 -1
- package/chunks/loader-command-3A5FK2RF.js +0 -1
- package/chunks/loader-reactor-YZM7HO4G.js +0 -1
- package/chunks/manager-ZSPRC5R4.js +0 -3
- package/chunks/mod-7VTKN6Q5.js +0 -1
- package/chunks/mod-B6LBGYON.js +0 -1
- package/chunks/mod-MMHDQRNF.js +0 -1
- package/chunks/mod-RBGAMGZA.js +0 -1
- package/chunks/mod-SFSUQWSB.js +0 -8
- package/chunks/mod-SV4VELMH.js +0 -1
- package/chunks/multipart-parser-DKDFOZKD.js +0 -2
- package/chunks/next-QXCLZ7P3.js +0 -15
- package/chunks/node-2XIHQ2M4.js +0 -1
- package/chunks/node-BXYZKSJY.js +0 -15
- package/chunks/node-DMUOWFGA.js +0 -69
- package/chunks/node-J4GTOSL2.js +0 -1
- package/chunks/ollama-MXRDGQDF.js +0 -1
- package/chunks/openai-LE47IWMQ.js +0 -30
- package/chunks/openai-MSJF4B6H.js +0 -1
- package/chunks/opencode-ZDHKR2P6.js +0 -1
- package/chunks/pack-NS64WU6M.js +0 -5
- package/chunks/plan-export-HECAF7D4.js +0 -3
- package/chunks/purge-PSQNN42H.js +0 -4
- package/chunks/reopen-L37M5XUI.js +0 -1
- package/chunks/reset-OOTZXW6Q.js +0 -1
- package/chunks/review-QLD6WSOB.js +0 -1
- package/chunks/rule-OOANQBHB.js +0 -6
- package/chunks/run-YHCIRY7Z.js +0 -3
- package/chunks/sdk-OQIHH3OY.js +0 -1
- package/chunks/session-OWWDH7KA.js +0 -1
- package/chunks/spec-O7F525UN.js +0 -1
- package/chunks/src-HXQVVTGQ.js +0 -3
- package/chunks/status-SZZXY7V3.js +0 -1
- package/chunks/sync-3RYRGTEA.js +0 -1
- package/chunks/unstable_chmod-44MCKF3B.js +0 -1
- package/chunks/validate-UZD6JBSG.js +0 -1
- package/chunks/vertexai-CVCRCO24.js +0 -1
- package/chunks/watch-5DNM646U.js +0 -8
- package/chunks/web-662LNB3K.js +0 -1
- package/chunks/wontfix-UDCTLHNB.js +0 -1
- package/chunks/workerd-I7MLRCLJ.js +0 -1
- package/noskills.js +0 -2
package/chunks/chunk-I4Z2RF7L.js
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import{a as wt,b as Ct,c as mr,e as $n}from"./chunk-HISXAZ4Y.js";var Qn=mr((Tt,Nn)=>{(function(f,s){typeof Tt=="object"&&typeof Nn<"u"?s(Tt):typeof define=="function"&&define.amd?define(["exports"],s):(f=typeof globalThis<"u"?globalThis:f||self,s(f.WebStreamsPolyfill={}))})(Tt,(function(f){"use strict";function s(){}function l(e){return typeof e=="object"&&e!==null||typeof e=="function"}let b=s;function d(e,t){try{Object.defineProperty(e,"name",{value:t,configurable:!0})}catch{}}let R=Promise,C=Promise.prototype.then,ue=Promise.reject.bind(R);function P(e){return new R(e)}function S(e){return P(t=>t(e))}function c(e){return ue(e)}function W(e,t,r){return C.call(e,t,r)}function v(e,t,r){W(W(e,t,r),void 0,b)}function M(e,t){v(e,t)}function N(e,t){v(e,void 0,t)}function Q(e,t,r){return W(e,t,r)}function we(e){W(e,void 0,b)}let fe=e=>{if(typeof queueMicrotask=="function")fe=queueMicrotask;else{let t=S(void 0);fe=r=>W(t,r)}return fe(e)};function de(e,t,r){if(typeof e!="function")throw new TypeError("Argument is not a function");return Function.prototype.apply.call(e,t,r)}function J(e,t,r){try{return S(de(e,t,r))}catch(n){return c(n)}}let Rr=16384;class k{constructor(){this._cursor=0,this._size=0,this._front={_elements:[],_next:void 0},this._back=this._front,this._cursor=0,this._size=0}get length(){return this._size}push(t){let r=this._back,n=r;r._elements.length===Rr-1&&(n={_elements:[],_next:void 0}),r._elements.push(t),n!==r&&(this._back=n,r._next=n),++this._size}shift(){let t=this._front,r=t,n=this._cursor,o=n+1,a=t._elements,i=a[n];return o===Rr&&(r=t._next,o=0),--this._size,this._cursor=o,t!==r&&(this._front=r),a[n]=void 0,i}forEach(t){let r=this._cursor,n=this._front,o=n._elements;for(;(r!==o.length||n._next!==void 0)&&!(r===o.length&&(n=n._next,o=n._elements,r=0,o.length===0));)t(o[r]),++r}peek(){let t=this._front,r=this._cursor;return t._elements[r]}}let wr=Symbol("[[AbortSteps]]"),Cr=Symbol("[[ErrorSteps]]"),qt=Symbol("[[CancelSteps]]"),At=Symbol("[[PullSteps]]"),Wt=Symbol("[[ReleaseSteps]]");function Tr(e,t){e._ownerReadableStream=t,t._reader=e,t._state==="readable"?kt(e):t._state==="closed"?to(e):Pr(e,t._storedError)}function Bt(e,t){let r=e._ownerReadableStream;return j(r,t)}function U(e){let t=e._ownerReadableStream;t._state==="readable"?Ot(e,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):ro(e,new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),t._readableStreamController[Wt](),t._reader=void 0,e._ownerReadableStream=void 0}function Ve(e){return new TypeError("Cannot "+e+" a stream using a released reader")}function kt(e){e._closedPromise=P((t,r)=>{e._closedPromise_resolve=t,e._closedPromise_reject=r})}function Pr(e,t){kt(e),Ot(e,t)}function to(e){kt(e),vr(e)}function Ot(e,t){e._closedPromise_reject!==void 0&&(we(e._closedPromise),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0)}function ro(e,t){Pr(e,t)}function vr(e){e._closedPromise_resolve!==void 0&&(e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0)}let Er=Number.isFinite||function(e){return typeof e=="number"&&isFinite(e)},no=Math.trunc||function(e){return e<0?Math.ceil(e):Math.floor(e)};function oo(e){return typeof e=="object"||typeof e=="function"}function L(e,t){if(e!==void 0&&!oo(e))throw new TypeError(`${t} is not an object.`)}function O(e,t){if(typeof e!="function")throw new TypeError(`${t} is not a function.`)}function ao(e){return typeof e=="object"&&e!==null||typeof e=="function"}function qr(e,t){if(!ao(e))throw new TypeError(`${t} is not an object.`)}function Y(e,t,r){if(e===void 0)throw new TypeError(`Parameter ${t} is required in '${r}'.`)}function Ft(e,t,r){if(e===void 0)throw new TypeError(`${t} is required in '${r}'.`)}function zt(e){return Number(e)}function Ar(e){return e===0?0:e}function io(e){return Ar(no(e))}function It(e,t){let n=Number.MAX_SAFE_INTEGER,o=Number(e);if(o=Ar(o),!Er(o))throw new TypeError(`${t} is not a finite number`);if(o=io(o),o<0||o>n)throw new TypeError(`${t} is outside the accepted range of 0 to ${n}, inclusive`);return!Er(o)||o===0?0:o}function jt(e,t){if(!ae(e))throw new TypeError(`${t} is not a ReadableStream.`)}function Ce(e){return new K(e)}function Wr(e,t){e._reader._readRequests.push(t)}function Dt(e,t,r){let o=e._reader._readRequests.shift();r?o._closeSteps():o._chunkSteps(t)}function He(e){return e._reader._readRequests.length}function Br(e){let t=e._reader;return!(t===void 0||!ee(t))}class K{constructor(t){if(Y(t,1,"ReadableStreamDefaultReader"),jt(t,"First parameter"),ie(t))throw new TypeError("This stream has already been locked for exclusive reading by another reader");Tr(this,t),this._readRequests=new k}get closed(){return ee(this)?this._closedPromise:c(Ge("closed"))}cancel(t=void 0){return ee(this)?this._ownerReadableStream===void 0?c(Ve("cancel")):Bt(this,t):c(Ge("cancel"))}read(){if(!ee(this))return c(Ge("read"));if(this._ownerReadableStream===void 0)return c(Ve("read from"));let t,r,n=P((a,i)=>{t=a,r=i});return ze(this,{_chunkSteps:a=>t({value:a,done:!1}),_closeSteps:()=>t({value:void 0,done:!0}),_errorSteps:a=>r(a)}),n}releaseLock(){if(!ee(this))throw Ge("releaseLock");this._ownerReadableStream!==void 0&&so(this)}}Object.defineProperties(K.prototype,{cancel:{enumerable:!0},read:{enumerable:!0},releaseLock:{enumerable:!0},closed:{enumerable:!0}}),d(K.prototype.cancel,"cancel"),d(K.prototype.read,"read"),d(K.prototype.releaseLock,"releaseLock"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(K.prototype,Symbol.toStringTag,{value:"ReadableStreamDefaultReader",configurable:!0});function ee(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_readRequests")?!1:e instanceof K}function ze(e,t){let r=e._ownerReadableStream;r._disturbed=!0,r._state==="closed"?t._closeSteps():r._state==="errored"?t._errorSteps(r._storedError):r._readableStreamController[At](t)}function so(e){U(e);let t=new TypeError("Reader was released");kr(e,t)}function kr(e,t){let r=e._readRequests;e._readRequests=new k,r.forEach(n=>{n._errorSteps(t)})}function Ge(e){return new TypeError(`ReadableStreamDefaultReader.prototype.${e} can only be used on a ReadableStreamDefaultReader`)}let lo=Object.getPrototypeOf(Object.getPrototypeOf(async function*(){}).prototype);class Or{constructor(t,r){this._ongoingPromise=void 0,this._isFinished=!1,this._reader=t,this._preventCancel=r}next(){let t=()=>this._nextSteps();return this._ongoingPromise=this._ongoingPromise?Q(this._ongoingPromise,t,t):t(),this._ongoingPromise}return(t){let r=()=>this._returnSteps(t);return this._ongoingPromise?Q(this._ongoingPromise,r,r):r()}_nextSteps(){if(this._isFinished)return Promise.resolve({value:void 0,done:!0});let t=this._reader,r,n,o=P((i,u)=>{r=i,n=u});return ze(t,{_chunkSteps:i=>{this._ongoingPromise=void 0,fe(()=>r({value:i,done:!1}))},_closeSteps:()=>{this._ongoingPromise=void 0,this._isFinished=!0,U(t),r({value:void 0,done:!0})},_errorSteps:i=>{this._ongoingPromise=void 0,this._isFinished=!0,U(t),n(i)}}),o}_returnSteps(t){if(this._isFinished)return Promise.resolve({value:t,done:!0});this._isFinished=!0;let r=this._reader;if(!this._preventCancel){let n=Bt(r,t);return U(r),Q(n,()=>({value:t,done:!0}))}return U(r),S({value:t,done:!0})}}let Fr={next(){return zr(this)?this._asyncIteratorImpl.next():c(Ir("next"))},return(e){return zr(this)?this._asyncIteratorImpl.return(e):c(Ir("return"))}};Object.setPrototypeOf(Fr,lo);function uo(e,t){let r=Ce(e),n=new Or(r,t),o=Object.create(Fr);return o._asyncIteratorImpl=n,o}function zr(e){if(!l(e)||!Object.prototype.hasOwnProperty.call(e,"_asyncIteratorImpl"))return!1;try{return e._asyncIteratorImpl instanceof Or}catch{return!1}}function Ir(e){return new TypeError(`ReadableStreamAsyncIterator.${e} can only be used on a ReadableSteamAsyncIterator`)}let jr=Number.isNaN||function(e){return e!==e};var Mt,Lt,$t;function Ie(e){return e.slice()}function Dr(e,t,r,n,o){new Uint8Array(e).set(new Uint8Array(r,n,o),t)}let V=e=>(typeof e.transfer=="function"?V=t=>t.transfer():typeof structuredClone=="function"?V=t=>structuredClone(t,{transfer:[t]}):V=t=>t,V(e)),te=e=>(typeof e.detached=="boolean"?te=t=>t.detached:te=t=>t.byteLength===0,te(e));function Mr(e,t,r){if(e.slice)return e.slice(t,r);let n=r-t,o=new ArrayBuffer(n);return Dr(o,0,e,t,n),o}function xe(e,t){let r=e[t];if(r!=null){if(typeof r!="function")throw new TypeError(`${String(t)} is not a function`);return r}}function fo(e){let t={[Symbol.iterator]:()=>e.iterator},r=(async function*(){return yield*t})(),n=r.next;return{iterator:r,nextMethod:n,done:!1}}let Nt=($t=(Mt=Symbol.asyncIterator)!==null&&Mt!==void 0?Mt:(Lt=Symbol.for)===null||Lt===void 0?void 0:Lt.call(Symbol,"Symbol.asyncIterator"))!==null&&$t!==void 0?$t:"@@asyncIterator";function Lr(e,t="sync",r){if(r===void 0)if(t==="async"){if(r=xe(e,Nt),r===void 0){let a=xe(e,Symbol.iterator),i=Lr(e,"sync",a);return fo(i)}}else r=xe(e,Symbol.iterator);if(r===void 0)throw new TypeError("The object is not iterable");let n=de(r,e,[]);if(!l(n))throw new TypeError("The iterator method must return an object");let o=n.next;return{iterator:n,nextMethod:o,done:!1}}function co(e){let t=de(e.nextMethod,e.iterator,[]);if(!l(t))throw new TypeError("The iterator.next() method must return an object");return t}function ho(e){return!!e.done}function bo(e){return e.value}function mo(e){return!(typeof e!="number"||jr(e)||e<0)}function $r(e){let t=Mr(e.buffer,e.byteOffset,e.byteOffset+e.byteLength);return new Uint8Array(t)}function Qt(e){let t=e._queue.shift();return e._queueTotalSize-=t.size,e._queueTotalSize<0&&(e._queueTotalSize=0),t.value}function Ut(e,t,r){if(!mo(r)||r===1/0)throw new RangeError("Size must be a finite, non-NaN, non-negative number.");e._queue.push({value:t,size:r}),e._queueTotalSize+=r}function po(e){return e._queue.peek().value}function re(e){e._queue=new k,e._queueTotalSize=0}function Nr(e){return e===DataView}function yo(e){return Nr(e.constructor)}function _o(e){return Nr(e)?1:e.BYTES_PER_ELEMENT}class ce{constructor(){throw new TypeError("Illegal constructor")}get view(){if(!Yt(this))throw Zt("view");return this._view}respond(t){if(!Yt(this))throw Zt("respond");if(Y(t,1,"respond"),t=It(t,"First parameter"),this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(te(this._view.buffer))throw new TypeError("The BYOB request's buffer has been detached and so cannot be used as a response");Ke(this._associatedReadableByteStreamController,t)}respondWithNewView(t){if(!Yt(this))throw Zt("respondWithNewView");if(Y(t,1,"respondWithNewView"),!ArrayBuffer.isView(t))throw new TypeError("You can only respond with array buffer views");if(this._associatedReadableByteStreamController===void 0)throw new TypeError("This BYOB request has been invalidated");if(te(t.buffer))throw new TypeError("The given view's buffer has been detached and so cannot be used as a response");et(this._associatedReadableByteStreamController,t)}}Object.defineProperties(ce.prototype,{respond:{enumerable:!0},respondWithNewView:{enumerable:!0},view:{enumerable:!0}}),d(ce.prototype.respond,"respond"),d(ce.prototype.respondWithNewView,"respondWithNewView"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(ce.prototype,Symbol.toStringTag,{value:"ReadableStreamBYOBRequest",configurable:!0});class H{constructor(){throw new TypeError("Illegal constructor")}get byobRequest(){if(!he(this))throw De("byobRequest");return xt(this)}get desiredSize(){if(!he(this))throw De("desiredSize");return Jr(this)}close(){if(!he(this))throw De("close");if(this._closeRequested)throw new TypeError("The stream has already been closed; do not close it again!");let t=this._controlledReadableByteStream._state;if(t!=="readable")throw new TypeError(`The stream (in ${t} state) is not in the readable state and cannot be closed`);je(this)}enqueue(t){if(!he(this))throw De("enqueue");if(Y(t,1,"enqueue"),!ArrayBuffer.isView(t))throw new TypeError("chunk must be an array buffer view");if(t.byteLength===0)throw new TypeError("chunk must have non-zero byteLength");if(t.buffer.byteLength===0)throw new TypeError("chunk's buffer must have non-zero byteLength");if(this._closeRequested)throw new TypeError("stream is closed or draining");let r=this._controlledReadableByteStream._state;if(r!=="readable")throw new TypeError(`The stream (in ${r} state) is not in the readable state and cannot be enqueued to`);Je(this,t)}error(t=void 0){if(!he(this))throw De("error");F(this,t)}[qt](t){Qr(this),re(this);let r=this._cancelAlgorithm(t);return Xe(this),r}[At](t){let r=this._controlledReadableByteStream;if(this._queueTotalSize>0){Xr(this,t);return}let n=this._autoAllocateChunkSize;if(n!==void 0){let o;try{o=new ArrayBuffer(n)}catch(i){t._errorSteps(i);return}let a={buffer:o,bufferByteLength:n,byteOffset:0,byteLength:n,bytesFilled:0,minimumFill:1,elementSize:1,viewConstructor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(a)}Wr(r,t),be(this)}[Wt](){if(this._pendingPullIntos.length>0){let t=this._pendingPullIntos.peek();t.readerType="none",this._pendingPullIntos=new k,this._pendingPullIntos.push(t)}}}Object.defineProperties(H.prototype,{close:{enumerable:!0},enqueue:{enumerable:!0},error:{enumerable:!0},byobRequest:{enumerable:!0},desiredSize:{enumerable:!0}}),d(H.prototype.close,"close"),d(H.prototype.enqueue,"enqueue"),d(H.prototype.error,"error"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(H.prototype,Symbol.toStringTag,{value:"ReadableByteStreamController",configurable:!0});function he(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_controlledReadableByteStream")?!1:e instanceof H}function Yt(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_associatedReadableByteStreamController")?!1:e instanceof ce}function be(e){if(!Co(e))return;if(e._pulling){e._pullAgain=!0;return}e._pulling=!0;let r=e._pullAlgorithm();v(r,()=>(e._pulling=!1,e._pullAgain&&(e._pullAgain=!1,be(e)),null),n=>(F(e,n),null))}function Qr(e){Ht(e),e._pendingPullIntos=new k}function Vt(e,t){let r=!1;e._state==="closed"&&(r=!0);let n=Ur(t);t.readerType==="default"?Dt(e,n,r):Ao(e,n,r)}function Ur(e){let t=e.bytesFilled,r=e.elementSize;return new e.viewConstructor(e.buffer,e.byteOffset,t/r)}function Ze(e,t,r,n){e._queue.push({buffer:t,byteOffset:r,byteLength:n}),e._queueTotalSize+=n}function Yr(e,t,r,n){let o;try{o=Mr(t,r,r+n)}catch(a){throw F(e,a),a}Ze(e,o,0,n)}function Vr(e,t){t.bytesFilled>0&&Yr(e,t.buffer,t.byteOffset,t.bytesFilled),Te(e)}function Hr(e,t){let r=Math.min(e._queueTotalSize,t.byteLength-t.bytesFilled),n=t.bytesFilled+r,o=r,a=!1,i=n%t.elementSize,u=n-i;u>=t.minimumFill&&(o=u-t.bytesFilled,a=!0);let p=e._queue;for(;o>0;){let h=p.peek(),y=Math.min(o,h.byteLength),_=t.byteOffset+t.bytesFilled;Dr(t.buffer,_,h.buffer,h.byteOffset,y),h.byteLength===y?p.shift():(h.byteOffset+=y,h.byteLength-=y),e._queueTotalSize-=y,Gr(e,y,t),o-=y}return a}function Gr(e,t,r){r.bytesFilled+=t}function xr(e){e._queueTotalSize===0&&e._closeRequested?(Xe(e),Ue(e._controlledReadableByteStream)):be(e)}function Ht(e){e._byobRequest!==null&&(e._byobRequest._associatedReadableByteStreamController=void 0,e._byobRequest._view=null,e._byobRequest=null)}function Gt(e){for(;e._pendingPullIntos.length>0;){if(e._queueTotalSize===0)return;let t=e._pendingPullIntos.peek();Hr(e,t)&&(Te(e),Vt(e._controlledReadableByteStream,t))}}function So(e){let t=e._controlledReadableByteStream._reader;for(;t._readRequests.length>0;){if(e._queueTotalSize===0)return;let r=t._readRequests.shift();Xr(e,r)}}function go(e,t,r,n){let o=e._controlledReadableByteStream,a=t.constructor,i=_o(a),{byteOffset:u,byteLength:p}=t,h=r*i,y;try{y=V(t.buffer)}catch(w){n._errorSteps(w);return}let _={buffer:y,bufferByteLength:y.byteLength,byteOffset:u,byteLength:p,bytesFilled:0,minimumFill:h,elementSize:i,viewConstructor:a,readerType:"byob"};if(e._pendingPullIntos.length>0){e._pendingPullIntos.push(_),tn(o,n);return}if(o._state==="closed"){let w=new a(_.buffer,_.byteOffset,0);n._closeSteps(w);return}if(e._queueTotalSize>0){if(Hr(e,_)){let w=Ur(_);xr(e),n._chunkSteps(w);return}if(e._closeRequested){let w=new TypeError("Insufficient bytes to fill elements in the given buffer");F(e,w),n._errorSteps(w);return}}e._pendingPullIntos.push(_),tn(o,n),be(e)}function Ro(e,t){t.readerType==="none"&&Te(e);let r=e._controlledReadableByteStream;if(Xt(r))for(;rn(r)>0;){let n=Te(e);Vt(r,n)}}function wo(e,t,r){if(Gr(e,t,r),r.readerType==="none"){Vr(e,r),Gt(e);return}if(r.bytesFilled<r.minimumFill)return;Te(e);let n=r.bytesFilled%r.elementSize;if(n>0){let o=r.byteOffset+r.bytesFilled;Yr(e,r.buffer,o-n,n)}r.bytesFilled-=n,Vt(e._controlledReadableByteStream,r),Gt(e)}function Zr(e,t){let r=e._pendingPullIntos.peek();Ht(e),e._controlledReadableByteStream._state==="closed"?Ro(e,r):wo(e,t,r),be(e)}function Te(e){return e._pendingPullIntos.shift()}function Co(e){let t=e._controlledReadableByteStream;return t._state!=="readable"||e._closeRequested||!e._started?!1:!!(Br(t)&&He(t)>0||Xt(t)&&rn(t)>0||Jr(e)>0)}function Xe(e){e._pullAlgorithm=void 0,e._cancelAlgorithm=void 0}function je(e){let t=e._controlledReadableByteStream;if(!(e._closeRequested||t._state!=="readable")){if(e._queueTotalSize>0){e._closeRequested=!0;return}if(e._pendingPullIntos.length>0){let r=e._pendingPullIntos.peek();if(r.bytesFilled%r.elementSize!==0){let n=new TypeError("Insufficient bytes to fill elements in the given buffer");throw F(e,n),n}}Xe(e),Ue(t)}}function Je(e,t){let r=e._controlledReadableByteStream;if(e._closeRequested||r._state!=="readable")return;let{buffer:n,byteOffset:o,byteLength:a}=t;if(te(n))throw new TypeError("chunk's buffer is detached and so cannot be enqueued");let i=V(n);if(e._pendingPullIntos.length>0){let u=e._pendingPullIntos.peek();if(te(u.buffer))throw new TypeError("The BYOB request's buffer has been detached and so cannot be filled with an enqueued chunk");Ht(e),u.buffer=V(u.buffer),u.readerType==="none"&&Vr(e,u)}if(Br(r))if(So(e),He(r)===0)Ze(e,i,o,a);else{e._pendingPullIntos.length>0&&Te(e);let u=new Uint8Array(i,o,a);Dt(r,u,!1)}else Xt(r)?(Ze(e,i,o,a),Gt(e)):Ze(e,i,o,a);be(e)}function F(e,t){let r=e._controlledReadableByteStream;r._state==="readable"&&(Qr(e),re(e),Xe(e),En(r,t))}function Xr(e,t){let r=e._queue.shift();e._queueTotalSize-=r.byteLength,xr(e);let n=new Uint8Array(r.buffer,r.byteOffset,r.byteLength);t._chunkSteps(n)}function xt(e){if(e._byobRequest===null&&e._pendingPullIntos.length>0){let t=e._pendingPullIntos.peek(),r=new Uint8Array(t.buffer,t.byteOffset+t.bytesFilled,t.byteLength-t.bytesFilled),n=Object.create(ce.prototype);Po(n,e,r),e._byobRequest=n}return e._byobRequest}function Jr(e){let t=e._controlledReadableByteStream._state;return t==="errored"?null:t==="closed"?0:e._strategyHWM-e._queueTotalSize}function Ke(e,t){let r=e._pendingPullIntos.peek();if(e._controlledReadableByteStream._state==="closed"){if(t!==0)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream")}else{if(t===0)throw new TypeError("bytesWritten must be greater than 0 when calling respond() on a readable stream");if(r.bytesFilled+t>r.byteLength)throw new RangeError("bytesWritten out of range")}r.buffer=V(r.buffer),Zr(e,t)}function et(e,t){let r=e._pendingPullIntos.peek();if(e._controlledReadableByteStream._state==="closed"){if(t.byteLength!==0)throw new TypeError("The view's length must be 0 when calling respondWithNewView() on a closed stream")}else if(t.byteLength===0)throw new TypeError("The view's length must be greater than 0 when calling respondWithNewView() on a readable stream");if(r.byteOffset+r.bytesFilled!==t.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(r.bufferByteLength!==t.buffer.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");if(r.bytesFilled+t.byteLength>r.byteLength)throw new RangeError("The region specified by view is larger than byobRequest");let o=t.byteLength;r.buffer=V(t.buffer),Zr(e,o)}function Kr(e,t,r,n,o,a,i){t._controlledReadableByteStream=e,t._pullAgain=!1,t._pulling=!1,t._byobRequest=null,t._queue=t._queueTotalSize=void 0,re(t),t._closeRequested=!1,t._started=!1,t._strategyHWM=a,t._pullAlgorithm=n,t._cancelAlgorithm=o,t._autoAllocateChunkSize=i,t._pendingPullIntos=new k,e._readableStreamController=t;let u=r();v(S(u),()=>(t._started=!0,be(t),null),p=>(F(t,p),null))}function To(e,t,r){let n=Object.create(H.prototype),o,a,i;t.start!==void 0?o=()=>t.start(n):o=()=>{},t.pull!==void 0?a=()=>t.pull(n):a=()=>S(void 0),t.cancel!==void 0?i=p=>t.cancel(p):i=()=>S(void 0);let u=t.autoAllocateChunkSize;if(u===0)throw new TypeError("autoAllocateChunkSize must be greater than 0");Kr(e,n,o,a,i,r,u)}function Po(e,t,r){e._associatedReadableByteStreamController=t,e._view=r}function Zt(e){return new TypeError(`ReadableStreamBYOBRequest.prototype.${e} can only be used on a ReadableStreamBYOBRequest`)}function De(e){return new TypeError(`ReadableByteStreamController.prototype.${e} can only be used on a ReadableByteStreamController`)}function vo(e,t){L(e,t);let r=e?.mode;return{mode:r===void 0?void 0:Eo(r,`${t} has member 'mode' that`)}}function Eo(e,t){if(e=`${e}`,e!=="byob")throw new TypeError(`${t} '${e}' is not a valid enumeration value for ReadableStreamReaderMode`);return e}function qo(e,t){var r;L(e,t);let n=(r=e?.min)!==null&&r!==void 0?r:1;return{min:It(n,`${t} has member 'min' that`)}}function en(e){return new ne(e)}function tn(e,t){e._reader._readIntoRequests.push(t)}function Ao(e,t,r){let o=e._reader._readIntoRequests.shift();r?o._closeSteps(t):o._chunkSteps(t)}function rn(e){return e._reader._readIntoRequests.length}function Xt(e){let t=e._reader;return!(t===void 0||!me(t))}class ne{constructor(t){if(Y(t,1,"ReadableStreamBYOBReader"),jt(t,"First parameter"),ie(t))throw new TypeError("This stream has already been locked for exclusive reading by another reader");if(!he(t._readableStreamController))throw new TypeError("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");Tr(this,t),this._readIntoRequests=new k}get closed(){return me(this)?this._closedPromise:c(tt("closed"))}cancel(t=void 0){return me(this)?this._ownerReadableStream===void 0?c(Ve("cancel")):Bt(this,t):c(tt("cancel"))}read(t,r={}){if(!me(this))return c(tt("read"));if(!ArrayBuffer.isView(t))return c(new TypeError("view must be an array buffer view"));if(t.byteLength===0)return c(new TypeError("view must have non-zero byteLength"));if(t.buffer.byteLength===0)return c(new TypeError("view's buffer must have non-zero byteLength"));if(te(t.buffer))return c(new TypeError("view's buffer has been detached"));let n;try{n=qo(r,"options")}catch(h){return c(h)}let o=n.min;if(o===0)return c(new TypeError("options.min must be greater than 0"));if(yo(t)){if(o>t.byteLength)return c(new RangeError("options.min must be less than or equal to view's byteLength"))}else if(o>t.length)return c(new RangeError("options.min must be less than or equal to view's length"));if(this._ownerReadableStream===void 0)return c(Ve("read from"));let a,i,u=P((h,y)=>{a=h,i=y});return nn(this,t,o,{_chunkSteps:h=>a({value:h,done:!1}),_closeSteps:h=>a({value:h,done:!0}),_errorSteps:h=>i(h)}),u}releaseLock(){if(!me(this))throw tt("releaseLock");this._ownerReadableStream!==void 0&&Wo(this)}}Object.defineProperties(ne.prototype,{cancel:{enumerable:!0},read:{enumerable:!0},releaseLock:{enumerable:!0},closed:{enumerable:!0}}),d(ne.prototype.cancel,"cancel"),d(ne.prototype.read,"read"),d(ne.prototype.releaseLock,"releaseLock"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(ne.prototype,Symbol.toStringTag,{value:"ReadableStreamBYOBReader",configurable:!0});function me(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_readIntoRequests")?!1:e instanceof ne}function nn(e,t,r,n){let o=e._ownerReadableStream;o._disturbed=!0,o._state==="errored"?n._errorSteps(o._storedError):go(o._readableStreamController,t,r,n)}function Wo(e){U(e);let t=new TypeError("Reader was released");on(e,t)}function on(e,t){let r=e._readIntoRequests;e._readIntoRequests=new k,r.forEach(n=>{n._errorSteps(t)})}function tt(e){return new TypeError(`ReadableStreamBYOBReader.prototype.${e} can only be used on a ReadableStreamBYOBReader`)}function Me(e,t){let{highWaterMark:r}=e;if(r===void 0)return t;if(jr(r)||r<0)throw new RangeError("Invalid highWaterMark");return r}function rt(e){let{size:t}=e;return t||(()=>1)}function nt(e,t){L(e,t);let r=e?.highWaterMark,n=e?.size;return{highWaterMark:r===void 0?void 0:zt(r),size:n===void 0?void 0:Bo(n,`${t} has member 'size' that`)}}function Bo(e,t){return O(e,t),r=>zt(e(r))}function ko(e,t){L(e,t);let r=e?.abort,n=e?.close,o=e?.start,a=e?.type,i=e?.write;return{abort:r===void 0?void 0:Oo(r,e,`${t} has member 'abort' that`),close:n===void 0?void 0:Fo(n,e,`${t} has member 'close' that`),start:o===void 0?void 0:zo(o,e,`${t} has member 'start' that`),write:i===void 0?void 0:Io(i,e,`${t} has member 'write' that`),type:a}}function Oo(e,t,r){return O(e,r),n=>J(e,t,[n])}function Fo(e,t,r){return O(e,r),()=>J(e,t,[])}function zo(e,t,r){return O(e,r),n=>de(e,t,[n])}function Io(e,t,r){return O(e,r),(n,o)=>J(e,t,[n,o])}function an(e,t){if(!Pe(e))throw new TypeError(`${t} is not a WritableStream.`)}function jo(e){if(typeof e!="object"||e===null)return!1;try{return typeof e.aborted=="boolean"}catch{return!1}}let Do=typeof AbortController=="function";function Mo(){if(Do)return new AbortController}class oe{constructor(t={},r={}){t===void 0?t=null:qr(t,"First parameter");let n=nt(r,"Second parameter"),o=ko(t,"First parameter");if(ln(this),o.type!==void 0)throw new RangeError("Invalid type is specified");let i=rt(n),u=Me(n,1);Ko(this,o,u,i)}get locked(){if(!Pe(this))throw lt("locked");return ve(this)}abort(t=void 0){return Pe(this)?ve(this)?c(new TypeError("Cannot abort a stream that already has a writer")):ot(this,t):c(lt("abort"))}close(){return Pe(this)?ve(this)?c(new TypeError("Cannot close a stream that already has a writer")):$(this)?c(new TypeError("Cannot close an already-closing stream")):un(this):c(lt("close"))}getWriter(){if(!Pe(this))throw lt("getWriter");return sn(this)}}Object.defineProperties(oe.prototype,{abort:{enumerable:!0},close:{enumerable:!0},getWriter:{enumerable:!0},locked:{enumerable:!0}}),d(oe.prototype.abort,"abort"),d(oe.prototype.close,"close"),d(oe.prototype.getWriter,"getWriter"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(oe.prototype,Symbol.toStringTag,{value:"WritableStream",configurable:!0});function sn(e){return new G(e)}function Lo(e,t,r,n,o=1,a=()=>1){let i=Object.create(oe.prototype);ln(i);let u=Object.create(Ee.prototype);return mn(i,u,e,t,r,n,o,a),i}function ln(e){e._state="writable",e._storedError=void 0,e._writer=void 0,e._writableStreamController=void 0,e._writeRequests=new k,e._inFlightWriteRequest=void 0,e._closeRequest=void 0,e._inFlightCloseRequest=void 0,e._pendingAbortRequest=void 0,e._backpressure=!1}function Pe(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_writableStreamController")?!1:e instanceof oe}function ve(e){return e._writer!==void 0}function ot(e,t){var r;if(e._state==="closed"||e._state==="errored")return S(void 0);e._writableStreamController._abortReason=t,(r=e._writableStreamController._abortController)===null||r===void 0||r.abort(t);let n=e._state;if(n==="closed"||n==="errored")return S(void 0);if(e._pendingAbortRequest!==void 0)return e._pendingAbortRequest._promise;let o=!1;n==="erroring"&&(o=!0,t=void 0);let a=P((i,u)=>{e._pendingAbortRequest={_promise:void 0,_resolve:i,_reject:u,_reason:t,_wasAlreadyErroring:o}});return e._pendingAbortRequest._promise=a,o||Kt(e,t),a}function un(e){let t=e._state;if(t==="closed"||t==="errored")return c(new TypeError(`The stream (in ${t} state) is not in the writable state and cannot be closed`));let r=P((o,a)=>{let i={_resolve:o,_reject:a};e._closeRequest=i}),n=e._writer;return n!==void 0&&e._backpressure&&t==="writable"&&sr(n),ea(e._writableStreamController),r}function $o(e){return P((r,n)=>{let o={_resolve:r,_reject:n};e._writeRequests.push(o)})}function Jt(e,t){if(e._state==="writable"){Kt(e,t);return}er(e)}function Kt(e,t){let r=e._writableStreamController;e._state="erroring",e._storedError=t;let n=e._writer;n!==void 0&&dn(n,t),!Vo(e)&&r._started&&er(e)}function er(e){e._state="errored",e._writableStreamController[Cr]();let t=e._storedError;if(e._writeRequests.forEach(o=>{o._reject(t)}),e._writeRequests=new k,e._pendingAbortRequest===void 0){at(e);return}let r=e._pendingAbortRequest;if(e._pendingAbortRequest=void 0,r._wasAlreadyErroring){r._reject(t),at(e);return}let n=e._writableStreamController[wr](r._reason);v(n,()=>(r._resolve(),at(e),null),o=>(r._reject(o),at(e),null))}function No(e){e._inFlightWriteRequest._resolve(void 0),e._inFlightWriteRequest=void 0}function Qo(e,t){e._inFlightWriteRequest._reject(t),e._inFlightWriteRequest=void 0,Jt(e,t)}function Uo(e){e._inFlightCloseRequest._resolve(void 0),e._inFlightCloseRequest=void 0,e._state==="erroring"&&(e._storedError=void 0,e._pendingAbortRequest!==void 0&&(e._pendingAbortRequest._resolve(),e._pendingAbortRequest=void 0)),e._state="closed";let r=e._writer;r!==void 0&&Sn(r)}function Yo(e,t){e._inFlightCloseRequest._reject(t),e._inFlightCloseRequest=void 0,e._pendingAbortRequest!==void 0&&(e._pendingAbortRequest._reject(t),e._pendingAbortRequest=void 0),Jt(e,t)}function $(e){return!(e._closeRequest===void 0&&e._inFlightCloseRequest===void 0)}function Vo(e){return!(e._inFlightWriteRequest===void 0&&e._inFlightCloseRequest===void 0)}function Ho(e){e._inFlightCloseRequest=e._closeRequest,e._closeRequest=void 0}function Go(e){e._inFlightWriteRequest=e._writeRequests.shift()}function at(e){e._closeRequest!==void 0&&(e._closeRequest._reject(e._storedError),e._closeRequest=void 0);let t=e._writer;t!==void 0&&ar(t,e._storedError)}function tr(e,t){let r=e._writer;r!==void 0&&t!==e._backpressure&&(t?sa(r):sr(r)),e._backpressure=t}class G{constructor(t){if(Y(t,1,"WritableStreamDefaultWriter"),an(t,"First parameter"),ve(t))throw new TypeError("This stream has already been locked for exclusive writing by another writer");this._ownerWritableStream=t,t._writer=this;let r=t._state;if(r==="writable")!$(t)&&t._backpressure?ft(this):gn(this),ut(this);else if(r==="erroring")ir(this,t._storedError),ut(this);else if(r==="closed")gn(this),aa(this);else{let n=t._storedError;ir(this,n),_n(this,n)}}get closed(){return pe(this)?this._closedPromise:c(ye("closed"))}get desiredSize(){if(!pe(this))throw ye("desiredSize");if(this._ownerWritableStream===void 0)throw $e("desiredSize");return Jo(this)}get ready(){return pe(this)?this._readyPromise:c(ye("ready"))}abort(t=void 0){return pe(this)?this._ownerWritableStream===void 0?c($e("abort")):xo(this,t):c(ye("abort"))}close(){if(!pe(this))return c(ye("close"));let t=this._ownerWritableStream;return t===void 0?c($e("close")):$(t)?c(new TypeError("Cannot close an already-closing stream")):fn(this)}releaseLock(){if(!pe(this))throw ye("releaseLock");this._ownerWritableStream!==void 0&&cn(this)}write(t=void 0){return pe(this)?this._ownerWritableStream===void 0?c($e("write to")):hn(this,t):c(ye("write"))}}Object.defineProperties(G.prototype,{abort:{enumerable:!0},close:{enumerable:!0},releaseLock:{enumerable:!0},write:{enumerable:!0},closed:{enumerable:!0},desiredSize:{enumerable:!0},ready:{enumerable:!0}}),d(G.prototype.abort,"abort"),d(G.prototype.close,"close"),d(G.prototype.releaseLock,"releaseLock"),d(G.prototype.write,"write"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(G.prototype,Symbol.toStringTag,{value:"WritableStreamDefaultWriter",configurable:!0});function pe(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_ownerWritableStream")?!1:e instanceof G}function xo(e,t){let r=e._ownerWritableStream;return ot(r,t)}function fn(e){let t=e._ownerWritableStream;return un(t)}function Zo(e){let t=e._ownerWritableStream,r=t._state;return $(t)||r==="closed"?S(void 0):r==="errored"?c(t._storedError):fn(e)}function Xo(e,t){e._closedPromiseState==="pending"?ar(e,t):ia(e,t)}function dn(e,t){e._readyPromiseState==="pending"?Rn(e,t):la(e,t)}function Jo(e){let t=e._ownerWritableStream,r=t._state;return r==="errored"||r==="erroring"?null:r==="closed"?0:pn(t._writableStreamController)}function cn(e){let t=e._ownerWritableStream,r=new TypeError("Writer was released and can no longer be used to monitor the stream's closedness");dn(e,r),Xo(e,r),t._writer=void 0,e._ownerWritableStream=void 0}function hn(e,t){let r=e._ownerWritableStream,n=r._writableStreamController,o=ta(n,t);if(r!==e._ownerWritableStream)return c($e("write to"));let a=r._state;if(a==="errored")return c(r._storedError);if($(r)||a==="closed")return c(new TypeError("The stream is closing or closed and cannot be written to"));if(a==="erroring")return c(r._storedError);let i=$o(r);return ra(n,t,o),i}let bn={};class Ee{constructor(){throw new TypeError("Illegal constructor")}get abortReason(){if(!rr(this))throw or("abortReason");return this._abortReason}get signal(){if(!rr(this))throw or("signal");if(this._abortController===void 0)throw new TypeError("WritableStreamDefaultController.prototype.signal is not supported");return this._abortController.signal}error(t=void 0){if(!rr(this))throw or("error");this._controlledWritableStream._state==="writable"&&yn(this,t)}[wr](t){let r=this._abortAlgorithm(t);return it(this),r}[Cr](){re(this)}}Object.defineProperties(Ee.prototype,{abortReason:{enumerable:!0},signal:{enumerable:!0},error:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(Ee.prototype,Symbol.toStringTag,{value:"WritableStreamDefaultController",configurable:!0});function rr(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_controlledWritableStream")?!1:e instanceof Ee}function mn(e,t,r,n,o,a,i,u){t._controlledWritableStream=e,e._writableStreamController=t,t._queue=void 0,t._queueTotalSize=void 0,re(t),t._abortReason=void 0,t._abortController=Mo(),t._started=!1,t._strategySizeAlgorithm=u,t._strategyHWM=i,t._writeAlgorithm=n,t._closeAlgorithm=o,t._abortAlgorithm=a;let p=nr(t);tr(e,p);let h=r(),y=S(h);v(y,()=>(t._started=!0,st(t),null),_=>(t._started=!0,Jt(e,_),null))}function Ko(e,t,r,n){let o=Object.create(Ee.prototype),a,i,u,p;t.start!==void 0?a=()=>t.start(o):a=()=>{},t.write!==void 0?i=h=>t.write(h,o):i=()=>S(void 0),t.close!==void 0?u=()=>t.close():u=()=>S(void 0),t.abort!==void 0?p=h=>t.abort(h):p=()=>S(void 0),mn(e,o,a,i,u,p,r,n)}function it(e){e._writeAlgorithm=void 0,e._closeAlgorithm=void 0,e._abortAlgorithm=void 0,e._strategySizeAlgorithm=void 0}function ea(e){Ut(e,bn,0),st(e)}function ta(e,t){try{return e._strategySizeAlgorithm(t)}catch(r){return Le(e,r),1}}function pn(e){return e._strategyHWM-e._queueTotalSize}function ra(e,t,r){try{Ut(e,t,r)}catch(o){Le(e,o);return}let n=e._controlledWritableStream;if(!$(n)&&n._state==="writable"){let o=nr(e);tr(n,o)}st(e)}function st(e){let t=e._controlledWritableStream;if(!e._started||t._inFlightWriteRequest!==void 0)return;if(t._state==="erroring"){er(t);return}if(e._queue.length===0)return;let n=po(e);n===bn?na(e):oa(e,n)}function Le(e,t){e._controlledWritableStream._state==="writable"&&yn(e,t)}function na(e){let t=e._controlledWritableStream;Ho(t),Qt(e);let r=e._closeAlgorithm();it(e),v(r,()=>(Uo(t),null),n=>(Yo(t,n),null))}function oa(e,t){let r=e._controlledWritableStream;Go(r);let n=e._writeAlgorithm(t);v(n,()=>{No(r);let o=r._state;if(Qt(e),!$(r)&&o==="writable"){let a=nr(e);tr(r,a)}return st(e),null},o=>(r._state==="writable"&&it(e),Qo(r,o),null))}function nr(e){return pn(e)<=0}function yn(e,t){let r=e._controlledWritableStream;it(e),Kt(r,t)}function lt(e){return new TypeError(`WritableStream.prototype.${e} can only be used on a WritableStream`)}function or(e){return new TypeError(`WritableStreamDefaultController.prototype.${e} can only be used on a WritableStreamDefaultController`)}function ye(e){return new TypeError(`WritableStreamDefaultWriter.prototype.${e} can only be used on a WritableStreamDefaultWriter`)}function $e(e){return new TypeError("Cannot "+e+" a stream using a released writer")}function ut(e){e._closedPromise=P((t,r)=>{e._closedPromise_resolve=t,e._closedPromise_reject=r,e._closedPromiseState="pending"})}function _n(e,t){ut(e),ar(e,t)}function aa(e){ut(e),Sn(e)}function ar(e,t){e._closedPromise_reject!==void 0&&(we(e._closedPromise),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._closedPromiseState="rejected")}function ia(e,t){_n(e,t)}function Sn(e){e._closedPromise_resolve!==void 0&&(e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._closedPromiseState="resolved")}function ft(e){e._readyPromise=P((t,r)=>{e._readyPromise_resolve=t,e._readyPromise_reject=r}),e._readyPromiseState="pending"}function ir(e,t){ft(e),Rn(e,t)}function gn(e){ft(e),sr(e)}function Rn(e,t){e._readyPromise_reject!==void 0&&(we(e._readyPromise),e._readyPromise_reject(t),e._readyPromise_resolve=void 0,e._readyPromise_reject=void 0,e._readyPromiseState="rejected")}function sa(e){ft(e)}function la(e,t){ir(e,t)}function sr(e){e._readyPromise_resolve!==void 0&&(e._readyPromise_resolve(void 0),e._readyPromise_resolve=void 0,e._readyPromise_reject=void 0,e._readyPromiseState="fulfilled")}function ua(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof global<"u")return global}let lr=ua();function fa(e){if(!(typeof e=="function"||typeof e=="object")||e.name!=="DOMException")return!1;try{return new e,!0}catch{return!1}}function da(){let e=lr?.DOMException;return fa(e)?e:void 0}function ca(){let e=function(r,n){this.message=r||"",this.name=n||"Error",Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)};return d(e,"DOMException"),e.prototype=Object.create(Error.prototype),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,configurable:!0}),e}let ha=da()||ca();function wn(e,t,r,n,o,a){let i=Ce(e),u=sn(t);e._disturbed=!0;let p=!1,h=S(void 0);return P((y,_)=>{let w;if(a!==void 0){if(w=()=>{let m=a.reason!==void 0?a.reason:new ha("Aborted","AbortError"),g=[];n||g.push(()=>t._state==="writable"?ot(t,m):S(void 0)),o||g.push(()=>e._state==="readable"?j(e,m):S(void 0)),A(()=>Promise.all(g.map(T=>T())),!0,m)},a.aborted){w();return}a.addEventListener("abort",w)}function D(){return P((m,g)=>{function T(B){B?m():W(Be(),T,g)}T(!1)})}function Be(){return p?S(!0):W(u._readyPromise,()=>P((m,g)=>{ze(i,{_chunkSteps:T=>{h=W(hn(u,T),void 0,s),m(!1)},_closeSteps:()=>m(!0),_errorSteps:g})}))}if(Z(e,i._closedPromise,m=>(n?z(!0,m):A(()=>ot(t,m),!0,m),null)),Z(t,u._closedPromise,m=>(o?z(!0,m):A(()=>j(e,m),!0,m),null)),q(e,i._closedPromise,()=>(r?z():A(()=>Zo(u)),null)),$(t)||t._state==="closed"){let m=new TypeError("the destination writable stream closed before all data could be piped to it");o?z(!0,m):A(()=>j(e,m),!0,m)}we(D());function le(){let m=h;return W(h,()=>m!==h?le():void 0)}function Z(m,g,T){m._state==="errored"?T(m._storedError):N(g,T)}function q(m,g,T){m._state==="closed"?T():M(g,T)}function A(m,g,T){if(p)return;p=!0,t._state==="writable"&&!$(t)?M(le(),B):B();function B(){return v(m(),()=>X(g,T),ke=>X(!0,ke)),null}}function z(m,g){p||(p=!0,t._state==="writable"&&!$(t)?M(le(),()=>X(m,g)):X(m,g))}function X(m,g){return cn(u),U(i),a!==void 0&&a.removeEventListener("abort",w),m?_(g):y(void 0),null}})}class x{constructor(){throw new TypeError("Illegal constructor")}get desiredSize(){if(!dt(this))throw ht("desiredSize");return ur(this)}close(){if(!dt(this))throw ht("close");if(!Ae(this))throw new TypeError("The stream is not in a state that permits close");_e(this)}enqueue(t=void 0){if(!dt(this))throw ht("enqueue");if(!Ae(this))throw new TypeError("The stream is not in a state that permits enqueue");return qe(this,t)}error(t=void 0){if(!dt(this))throw ht("error");I(this,t)}[qt](t){re(this);let r=this._cancelAlgorithm(t);return ct(this),r}[At](t){let r=this._controlledReadableStream;if(this._queue.length>0){let n=Qt(this);this._closeRequested&&this._queue.length===0?(ct(this),Ue(r)):Ne(this),t._chunkSteps(n)}else Wr(r,t),Ne(this)}[Wt](){}}Object.defineProperties(x.prototype,{close:{enumerable:!0},enqueue:{enumerable:!0},error:{enumerable:!0},desiredSize:{enumerable:!0}}),d(x.prototype.close,"close"),d(x.prototype.enqueue,"enqueue"),d(x.prototype.error,"error"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(x.prototype,Symbol.toStringTag,{value:"ReadableStreamDefaultController",configurable:!0});function dt(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_controlledReadableStream")?!1:e instanceof x}function Ne(e){if(!Cn(e))return;if(e._pulling){e._pullAgain=!0;return}e._pulling=!0;let r=e._pullAlgorithm();v(r,()=>(e._pulling=!1,e._pullAgain&&(e._pullAgain=!1,Ne(e)),null),n=>(I(e,n),null))}function Cn(e){let t=e._controlledReadableStream;return!Ae(e)||!e._started?!1:!!(ie(t)&&He(t)>0||ur(e)>0)}function ct(e){e._pullAlgorithm=void 0,e._cancelAlgorithm=void 0,e._strategySizeAlgorithm=void 0}function _e(e){if(!Ae(e))return;let t=e._controlledReadableStream;e._closeRequested=!0,e._queue.length===0&&(ct(e),Ue(t))}function qe(e,t){if(!Ae(e))return;let r=e._controlledReadableStream;if(ie(r)&&He(r)>0)Dt(r,t,!1);else{let n;try{n=e._strategySizeAlgorithm(t)}catch(o){throw I(e,o),o}try{Ut(e,t,n)}catch(o){throw I(e,o),o}}Ne(e)}function I(e,t){let r=e._controlledReadableStream;r._state==="readable"&&(re(e),ct(e),En(r,t))}function ur(e){let t=e._controlledReadableStream._state;return t==="errored"?null:t==="closed"?0:e._strategyHWM-e._queueTotalSize}function ba(e){return!Cn(e)}function Ae(e){let t=e._controlledReadableStream._state;return!e._closeRequested&&t==="readable"}function Tn(e,t,r,n,o,a,i){t._controlledReadableStream=e,t._queue=void 0,t._queueTotalSize=void 0,re(t),t._started=!1,t._closeRequested=!1,t._pullAgain=!1,t._pulling=!1,t._strategySizeAlgorithm=i,t._strategyHWM=a,t._pullAlgorithm=n,t._cancelAlgorithm=o,e._readableStreamController=t;let u=r();v(S(u),()=>(t._started=!0,Ne(t),null),p=>(I(t,p),null))}function ma(e,t,r,n){let o=Object.create(x.prototype),a,i,u;t.start!==void 0?a=()=>t.start(o):a=()=>{},t.pull!==void 0?i=()=>t.pull(o):i=()=>S(void 0),t.cancel!==void 0?u=p=>t.cancel(p):u=()=>S(void 0),Tn(e,o,a,i,u,r,n)}function ht(e){return new TypeError(`ReadableStreamDefaultController.prototype.${e} can only be used on a ReadableStreamDefaultController`)}function pa(e,t){return he(e._readableStreamController)?_a(e):ya(e)}function ya(e,t){let r=Ce(e),n=!1,o=!1,a=!1,i=!1,u,p,h,y,_,w=P(q=>{_=q});function D(){return n?(o=!0,S(void 0)):(n=!0,ze(r,{_chunkSteps:A=>{fe(()=>{o=!1;let z=A,X=A;a||qe(h._readableStreamController,z),i||qe(y._readableStreamController,X),n=!1,o&&D()})},_closeSteps:()=>{n=!1,a||_e(h._readableStreamController),i||_e(y._readableStreamController),(!a||!i)&&_(void 0)},_errorSteps:()=>{n=!1}}),S(void 0))}function Be(q){if(a=!0,u=q,i){let A=Ie([u,p]),z=j(e,A);_(z)}return w}function le(q){if(i=!0,p=q,a){let A=Ie([u,p]),z=j(e,A);_(z)}return w}function Z(){}return h=Qe(Z,D,Be),y=Qe(Z,D,le),N(r._closedPromise,q=>(I(h._readableStreamController,q),I(y._readableStreamController,q),(!a||!i)&&_(void 0),null)),[h,y]}function _a(e){let t=Ce(e),r=!1,n=!1,o=!1,a=!1,i=!1,u,p,h,y,_,w=P(m=>{_=m});function D(m){N(m._closedPromise,g=>(m!==t||(F(h._readableStreamController,g),F(y._readableStreamController,g),(!a||!i)&&_(void 0)),null))}function Be(){me(t)&&(U(t),t=Ce(e),D(t)),ze(t,{_chunkSteps:g=>{fe(()=>{n=!1,o=!1;let T=g,B=g;if(!a&&!i)try{B=$r(g)}catch(ke){F(h._readableStreamController,ke),F(y._readableStreamController,ke),_(j(e,ke));return}a||Je(h._readableStreamController,T),i||Je(y._readableStreamController,B),r=!1,n?Z():o&&q()})},_closeSteps:()=>{r=!1,a||je(h._readableStreamController),i||je(y._readableStreamController),h._readableStreamController._pendingPullIntos.length>0&&Ke(h._readableStreamController,0),y._readableStreamController._pendingPullIntos.length>0&&Ke(y._readableStreamController,0),(!a||!i)&&_(void 0)},_errorSteps:()=>{r=!1}})}function le(m,g){ee(t)&&(U(t),t=en(e),D(t));let T=g?y:h,B=g?h:y;nn(t,m,1,{_chunkSteps:Oe=>{fe(()=>{n=!1,o=!1;let Fe=g?i:a;if(g?a:i)Fe||et(T._readableStreamController,Oe);else{let Ln;try{Ln=$r(Oe)}catch(br){F(T._readableStreamController,br),F(B._readableStreamController,br),_(j(e,br));return}Fe||et(T._readableStreamController,Oe),Je(B._readableStreamController,Ln)}r=!1,n?Z():o&&q()})},_closeSteps:Oe=>{r=!1;let Fe=g?i:a,Rt=g?a:i;Fe||je(T._readableStreamController),Rt||je(B._readableStreamController),Oe!==void 0&&(Fe||et(T._readableStreamController,Oe),!Rt&&B._readableStreamController._pendingPullIntos.length>0&&Ke(B._readableStreamController,0)),(!Fe||!Rt)&&_(void 0)},_errorSteps:()=>{r=!1}})}function Z(){if(r)return n=!0,S(void 0);r=!0;let m=xt(h._readableStreamController);return m===null?Be():le(m._view,!1),S(void 0)}function q(){if(r)return o=!0,S(void 0);r=!0;let m=xt(y._readableStreamController);return m===null?Be():le(m._view,!0),S(void 0)}function A(m){if(a=!0,u=m,i){let g=Ie([u,p]),T=j(e,g);_(T)}return w}function z(m){if(i=!0,p=m,a){let g=Ie([u,p]),T=j(e,g);_(T)}return w}function X(){}return h=vn(X,Z,A),y=vn(X,q,z),D(t),[h,y]}function Sa(e){return l(e)&&typeof e.getReader<"u"}function ga(e){return Sa(e)?wa(e.getReader()):Ra(e)}function Ra(e){let t,r=Lr(e,"async"),n=s;function o(){let i;try{i=co(r)}catch(p){return c(p)}let u=S(i);return Q(u,p=>{if(!l(p))throw new TypeError("The promise returned by the iterator.next() method must fulfill with an object");if(ho(p))_e(t._readableStreamController);else{let y=bo(p);qe(t._readableStreamController,y)}})}function a(i){let u=r.iterator,p;try{p=xe(u,"return")}catch(_){return c(_)}if(p===void 0)return S(void 0);let h;try{h=de(p,u,[i])}catch(_){return c(_)}let y=S(h);return Q(y,_=>{if(!l(_))throw new TypeError("The promise returned by the iterator.return() method must fulfill with an object")})}return t=Qe(n,o,a,0),t}function wa(e){let t,r=s;function n(){let a;try{a=e.read()}catch(i){return c(i)}return Q(a,i=>{if(!l(i))throw new TypeError("The promise returned by the reader.read() method must fulfill with an object");if(i.done)_e(t._readableStreamController);else{let u=i.value;qe(t._readableStreamController,u)}})}function o(a){try{return S(e.cancel(a))}catch(i){return c(i)}}return t=Qe(r,n,o,0),t}function Ca(e,t){L(e,t);let r=e,n=r?.autoAllocateChunkSize,o=r?.cancel,a=r?.pull,i=r?.start,u=r?.type;return{autoAllocateChunkSize:n===void 0?void 0:It(n,`${t} has member 'autoAllocateChunkSize' that`),cancel:o===void 0?void 0:Ta(o,r,`${t} has member 'cancel' that`),pull:a===void 0?void 0:Pa(a,r,`${t} has member 'pull' that`),start:i===void 0?void 0:va(i,r,`${t} has member 'start' that`),type:u===void 0?void 0:Ea(u,`${t} has member 'type' that`)}}function Ta(e,t,r){return O(e,r),n=>J(e,t,[n])}function Pa(e,t,r){return O(e,r),n=>J(e,t,[n])}function va(e,t,r){return O(e,r),n=>de(e,t,[n])}function Ea(e,t){if(e=`${e}`,e!=="bytes")throw new TypeError(`${t} '${e}' is not a valid enumeration value for ReadableStreamType`);return e}function qa(e,t){return L(e,t),{preventCancel:!!e?.preventCancel}}function Pn(e,t){L(e,t);let r=e?.preventAbort,n=e?.preventCancel,o=e?.preventClose,a=e?.signal;return a!==void 0&&Aa(a,`${t} has member 'signal' that`),{preventAbort:!!r,preventCancel:!!n,preventClose:!!o,signal:a}}function Aa(e,t){if(!jo(e))throw new TypeError(`${t} is not an AbortSignal.`)}function Wa(e,t){L(e,t);let r=e?.readable;Ft(r,"readable","ReadableWritablePair"),jt(r,`${t} has member 'readable' that`);let n=e?.writable;return Ft(n,"writable","ReadableWritablePair"),an(n,`${t} has member 'writable' that`),{readable:r,writable:n}}class E{constructor(t={},r={}){t===void 0?t=null:qr(t,"First parameter");let n=nt(r,"Second parameter"),o=Ca(t,"First parameter");if(fr(this),o.type==="bytes"){if(n.size!==void 0)throw new RangeError("The strategy for a byte stream cannot have a size function");let a=Me(n,0);To(this,o,a)}else{let a=rt(n),i=Me(n,1);ma(this,o,i,a)}}get locked(){if(!ae(this))throw Se("locked");return ie(this)}cancel(t=void 0){return ae(this)?ie(this)?c(new TypeError("Cannot cancel a stream that already has a reader")):j(this,t):c(Se("cancel"))}getReader(t=void 0){if(!ae(this))throw Se("getReader");return vo(t,"First parameter").mode===void 0?Ce(this):en(this)}pipeThrough(t,r={}){if(!ae(this))throw Se("pipeThrough");Y(t,1,"pipeThrough");let n=Wa(t,"First parameter"),o=Pn(r,"Second parameter");if(ie(this))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");if(ve(n.writable))throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");let a=wn(this,n.writable,o.preventClose,o.preventAbort,o.preventCancel,o.signal);return we(a),n.readable}pipeTo(t,r={}){if(!ae(this))return c(Se("pipeTo"));if(t===void 0)return c("Parameter 1 is required in 'pipeTo'.");if(!Pe(t))return c(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));let n;try{n=Pn(r,"Second parameter")}catch(o){return c(o)}return ie(this)?c(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")):ve(t)?c(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")):wn(this,t,n.preventClose,n.preventAbort,n.preventCancel,n.signal)}tee(){if(!ae(this))throw Se("tee");let t=pa(this);return Ie(t)}values(t=void 0){if(!ae(this))throw Se("values");let r=qa(t,"First parameter");return uo(this,r.preventCancel)}[Nt](t){return this.values(t)}static from(t){return ga(t)}}Object.defineProperties(E,{from:{enumerable:!0}}),Object.defineProperties(E.prototype,{cancel:{enumerable:!0},getReader:{enumerable:!0},pipeThrough:{enumerable:!0},pipeTo:{enumerable:!0},tee:{enumerable:!0},values:{enumerable:!0},locked:{enumerable:!0}}),d(E.from,"from"),d(E.prototype.cancel,"cancel"),d(E.prototype.getReader,"getReader"),d(E.prototype.pipeThrough,"pipeThrough"),d(E.prototype.pipeTo,"pipeTo"),d(E.prototype.tee,"tee"),d(E.prototype.values,"values"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(E.prototype,Symbol.toStringTag,{value:"ReadableStream",configurable:!0}),Object.defineProperty(E.prototype,Nt,{value:E.prototype.values,writable:!0,configurable:!0});function Qe(e,t,r,n=1,o=()=>1){let a=Object.create(E.prototype);fr(a);let i=Object.create(x.prototype);return Tn(a,i,e,t,r,n,o),a}function vn(e,t,r){let n=Object.create(E.prototype);fr(n);let o=Object.create(H.prototype);return Kr(n,o,e,t,r,0,void 0),n}function fr(e){e._state="readable",e._reader=void 0,e._storedError=void 0,e._disturbed=!1}function ae(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_readableStreamController")?!1:e instanceof E}function ie(e){return e._reader!==void 0}function j(e,t){if(e._disturbed=!0,e._state==="closed")return S(void 0);if(e._state==="errored")return c(e._storedError);Ue(e);let r=e._reader;if(r!==void 0&&me(r)){let o=r._readIntoRequests;r._readIntoRequests=new k,o.forEach(a=>{a._closeSteps(void 0)})}let n=e._readableStreamController[qt](t);return Q(n,s)}function Ue(e){e._state="closed";let t=e._reader;if(t!==void 0&&(vr(t),ee(t))){let r=t._readRequests;t._readRequests=new k,r.forEach(n=>{n._closeSteps()})}}function En(e,t){e._state="errored",e._storedError=t;let r=e._reader;r!==void 0&&(Ot(r,t),ee(r)?kr(r,t):on(r,t))}function Se(e){return new TypeError(`ReadableStream.prototype.${e} can only be used on a ReadableStream`)}function qn(e,t){L(e,t);let r=e?.highWaterMark;return Ft(r,"highWaterMark","QueuingStrategyInit"),{highWaterMark:zt(r)}}let An=e=>e.byteLength;d(An,"size");class bt{constructor(t){Y(t,1,"ByteLengthQueuingStrategy"),t=qn(t,"First parameter"),this._byteLengthQueuingStrategyHighWaterMark=t.highWaterMark}get highWaterMark(){if(!Bn(this))throw Wn("highWaterMark");return this._byteLengthQueuingStrategyHighWaterMark}get size(){if(!Bn(this))throw Wn("size");return An}}Object.defineProperties(bt.prototype,{highWaterMark:{enumerable:!0},size:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(bt.prototype,Symbol.toStringTag,{value:"ByteLengthQueuingStrategy",configurable:!0});function Wn(e){return new TypeError(`ByteLengthQueuingStrategy.prototype.${e} can only be used on a ByteLengthQueuingStrategy`)}function Bn(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_byteLengthQueuingStrategyHighWaterMark")?!1:e instanceof bt}let kn=()=>1;d(kn,"size");class mt{constructor(t){Y(t,1,"CountQueuingStrategy"),t=qn(t,"First parameter"),this._countQueuingStrategyHighWaterMark=t.highWaterMark}get highWaterMark(){if(!Fn(this))throw On("highWaterMark");return this._countQueuingStrategyHighWaterMark}get size(){if(!Fn(this))throw On("size");return kn}}Object.defineProperties(mt.prototype,{highWaterMark:{enumerable:!0},size:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(mt.prototype,Symbol.toStringTag,{value:"CountQueuingStrategy",configurable:!0});function On(e){return new TypeError(`CountQueuingStrategy.prototype.${e} can only be used on a CountQueuingStrategy`)}function Fn(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_countQueuingStrategyHighWaterMark")?!1:e instanceof mt}function Ba(e,t){L(e,t);let r=e?.cancel,n=e?.flush,o=e?.readableType,a=e?.start,i=e?.transform,u=e?.writableType;return{cancel:r===void 0?void 0:za(r,e,`${t} has member 'cancel' that`),flush:n===void 0?void 0:ka(n,e,`${t} has member 'flush' that`),readableType:o,start:a===void 0?void 0:Oa(a,e,`${t} has member 'start' that`),transform:i===void 0?void 0:Fa(i,e,`${t} has member 'transform' that`),writableType:u}}function ka(e,t,r){return O(e,r),n=>J(e,t,[n])}function Oa(e,t,r){return O(e,r),n=>de(e,t,[n])}function Fa(e,t,r){return O(e,r),(n,o)=>J(e,t,[n,o])}function za(e,t,r){return O(e,r),n=>J(e,t,[n])}class pt{constructor(t={},r={},n={}){t===void 0&&(t=null);let o=nt(r,"Second parameter"),a=nt(n,"Third parameter"),i=Ba(t,"First parameter");if(i.readableType!==void 0)throw new RangeError("Invalid readableType specified");if(i.writableType!==void 0)throw new RangeError("Invalid writableType specified");let u=Me(a,0),p=rt(a),h=Me(o,1),y=rt(o),_,w=P(D=>{_=D});Ia(this,w,h,y,u,p),Da(this,i),i.start!==void 0?_(i.start(this._transformStreamController)):_(void 0)}get readable(){if(!zn(this))throw Mn("readable");return this._readable}get writable(){if(!zn(this))throw Mn("writable");return this._writable}}Object.defineProperties(pt.prototype,{readable:{enumerable:!0},writable:{enumerable:!0}}),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(pt.prototype,Symbol.toStringTag,{value:"TransformStream",configurable:!0});function Ia(e,t,r,n,o,a){function i(){return t}function u(w){return $a(e,w)}function p(w){return Na(e,w)}function h(){return Qa(e)}e._writable=Lo(i,u,h,p,r,n);function y(){return Ua(e)}function _(w){return Ya(e,w)}e._readable=Qe(i,y,_,o,a),e._backpressure=void 0,e._backpressureChangePromise=void 0,e._backpressureChangePromise_resolve=void 0,yt(e,!0),e._transformStreamController=void 0}function zn(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_transformStreamController")?!1:e instanceof pt}function In(e,t){I(e._readable._readableStreamController,t),dr(e,t)}function dr(e,t){St(e._transformStreamController),Le(e._writable._writableStreamController,t),cr(e)}function cr(e){e._backpressure&&yt(e,!1)}function yt(e,t){e._backpressureChangePromise!==void 0&&e._backpressureChangePromise_resolve(),e._backpressureChangePromise=P(r=>{e._backpressureChangePromise_resolve=r}),e._backpressure=t}class se{constructor(){throw new TypeError("Illegal constructor")}get desiredSize(){if(!_t(this))throw gt("desiredSize");let t=this._controlledTransformStream._readable._readableStreamController;return ur(t)}enqueue(t=void 0){if(!_t(this))throw gt("enqueue");jn(this,t)}error(t=void 0){if(!_t(this))throw gt("error");Ma(this,t)}terminate(){if(!_t(this))throw gt("terminate");La(this)}}Object.defineProperties(se.prototype,{enqueue:{enumerable:!0},error:{enumerable:!0},terminate:{enumerable:!0},desiredSize:{enumerable:!0}}),d(se.prototype.enqueue,"enqueue"),d(se.prototype.error,"error"),d(se.prototype.terminate,"terminate"),typeof Symbol.toStringTag=="symbol"&&Object.defineProperty(se.prototype,Symbol.toStringTag,{value:"TransformStreamDefaultController",configurable:!0});function _t(e){return!l(e)||!Object.prototype.hasOwnProperty.call(e,"_controlledTransformStream")?!1:e instanceof se}function ja(e,t,r,n,o){t._controlledTransformStream=e,e._transformStreamController=t,t._transformAlgorithm=r,t._flushAlgorithm=n,t._cancelAlgorithm=o,t._finishPromise=void 0,t._finishPromise_resolve=void 0,t._finishPromise_reject=void 0}function Da(e,t){let r=Object.create(se.prototype),n,o,a;t.transform!==void 0?n=i=>t.transform(i,r):n=i=>{try{return jn(r,i),S(void 0)}catch(u){return c(u)}},t.flush!==void 0?o=()=>t.flush(r):o=()=>S(void 0),t.cancel!==void 0?a=i=>t.cancel(i):a=()=>S(void 0),ja(e,r,n,o,a)}function St(e){e._transformAlgorithm=void 0,e._flushAlgorithm=void 0,e._cancelAlgorithm=void 0}function jn(e,t){let r=e._controlledTransformStream,n=r._readable._readableStreamController;if(!Ae(n))throw new TypeError("Readable side is not in a state that permits enqueue");try{qe(n,t)}catch(a){throw dr(r,a),r._readable._storedError}ba(n)!==r._backpressure&&yt(r,!0)}function Ma(e,t){In(e._controlledTransformStream,t)}function Dn(e,t){let r=e._transformAlgorithm(t);return Q(r,void 0,n=>{throw In(e._controlledTransformStream,n),n})}function La(e){let t=e._controlledTransformStream,r=t._readable._readableStreamController;_e(r);let n=new TypeError("TransformStream terminated");dr(t,n)}function $a(e,t){let r=e._transformStreamController;if(e._backpressure){let n=e._backpressureChangePromise;return Q(n,()=>{let o=e._writable;if(o._state==="erroring")throw o._storedError;return Dn(r,t)})}return Dn(r,t)}function Na(e,t){let r=e._transformStreamController;if(r._finishPromise!==void 0)return r._finishPromise;let n=e._readable;r._finishPromise=P((a,i)=>{r._finishPromise_resolve=a,r._finishPromise_reject=i});let o=r._cancelAlgorithm(t);return St(r),v(o,()=>(n._state==="errored"?We(r,n._storedError):(I(n._readableStreamController,t),hr(r)),null),a=>(I(n._readableStreamController,a),We(r,a),null)),r._finishPromise}function Qa(e){let t=e._transformStreamController;if(t._finishPromise!==void 0)return t._finishPromise;let r=e._readable;t._finishPromise=P((o,a)=>{t._finishPromise_resolve=o,t._finishPromise_reject=a});let n=t._flushAlgorithm();return St(t),v(n,()=>(r._state==="errored"?We(t,r._storedError):(_e(r._readableStreamController),hr(t)),null),o=>(I(r._readableStreamController,o),We(t,o),null)),t._finishPromise}function Ua(e){return yt(e,!1),e._backpressureChangePromise}function Ya(e,t){let r=e._transformStreamController;if(r._finishPromise!==void 0)return r._finishPromise;let n=e._writable;r._finishPromise=P((a,i)=>{r._finishPromise_resolve=a,r._finishPromise_reject=i});let o=r._cancelAlgorithm(t);return St(r),v(o,()=>(n._state==="errored"?We(r,n._storedError):(Le(n._writableStreamController,t),cr(e),hr(r)),null),a=>(Le(n._writableStreamController,a),cr(e),We(r,a),null)),r._finishPromise}function gt(e){return new TypeError(`TransformStreamDefaultController.prototype.${e} can only be used on a TransformStreamDefaultController`)}function hr(e){e._finishPromise_resolve!==void 0&&(e._finishPromise_resolve(),e._finishPromise_resolve=void 0,e._finishPromise_reject=void 0)}function We(e,t){e._finishPromise_reject!==void 0&&(we(e._finishPromise),e._finishPromise_reject(t),e._finishPromise_resolve=void 0,e._finishPromise_reject=void 0)}function Mn(e){return new TypeError(`TransformStream.prototype.${e} can only be used on a TransformStream`)}f.ByteLengthQueuingStrategy=bt,f.CountQueuingStrategy=mt,f.ReadableByteStreamController=H,f.ReadableStream=E,f.ReadableStreamBYOBReader=ne,f.ReadableStreamBYOBRequest=ce,f.ReadableStreamDefaultController=x,f.ReadableStreamDefaultReader=K,f.TransformStream=pt,f.TransformStreamDefaultController=se,f.WritableStream=oe,f.WritableStreamDefaultController=Ee,f.WritableStreamDefaultWriter=G}))});var Un=mr(()=>{if(!globalThis.ReadableStream)try{let f=wt("node:process"),{emitWarning:s}=f;try{f.emitWarning=()=>{},Object.assign(globalThis,wt("node:stream/web")),f.emitWarning=s}catch(l){throw f.emitWarning=s,l}}catch{Object.assign(globalThis,Qn())}try{let{Blob:f}=wt("buffer");f&&!f.prototype.stream&&(f.prototype.stream=function(l){let b=0,d=this;return new ReadableStream({type:"bytes",async pull(R){let ue=await d.slice(b,Math.min(d.size,b+65536)).arrayBuffer();b+=ue.byteLength,R.enqueue(new Uint8Array(ue)),b===d.size&&R.close()}})})}catch{}});async function*pr(f,s=!0){for(let l of f)if("stream"in l)yield*l.stream();else if(ArrayBuffer.isView(l))if(s){let b=l.byteOffset,d=l.byteOffset+l.byteLength;for(;b!==d;){let R=Math.min(d-b,Yn),C=l.buffer.slice(b,b+R);b+=C.byteLength,yield new Uint8Array(C)}}else yield l;else{let b=0,d=l;for(;b!==d.size;){let C=await d.slice(b,Math.min(d.size,b+Yn)).arrayBuffer();b+=C.byteLength,yield new Uint8Array(C)}}}var ai,Yn,Vn,Va,ge,Pt=Ct(()=>{ai=$n(Un(),1);Yn=65536;Vn=class yr{#e=[];#t="";#r=0;#n="transparent";constructor(s=[],l={}){if(typeof s!="object"||s===null)throw new TypeError("Failed to construct 'Blob': The provided value cannot be converted to a sequence.");if(typeof s[Symbol.iterator]!="function")throw new TypeError("Failed to construct 'Blob': The object must have a callable @@iterator property.");if(typeof l!="object"&&typeof l!="function")throw new TypeError("Failed to construct 'Blob': parameter 2 cannot convert to dictionary.");l===null&&(l={});let b=new TextEncoder;for(let R of s){let C;ArrayBuffer.isView(R)?C=new Uint8Array(R.buffer.slice(R.byteOffset,R.byteOffset+R.byteLength)):R instanceof ArrayBuffer?C=new Uint8Array(R.slice(0)):R instanceof yr?C=R:C=b.encode(`${R}`),this.#r+=ArrayBuffer.isView(C)?C.byteLength:C.size,this.#e.push(C)}this.#n=`${l.endings===void 0?"transparent":l.endings}`;let d=l.type===void 0?"":String(l.type);this.#t=/^[\x20-\x7E]*$/.test(d)?d:""}get size(){return this.#r}get type(){return this.#t}async text(){let s=new TextDecoder,l="";for await(let b of pr(this.#e,!1))l+=s.decode(b,{stream:!0});return l+=s.decode(),l}async arrayBuffer(){let s=new Uint8Array(this.size),l=0;for await(let b of pr(this.#e,!1))s.set(b,l),l+=b.length;return s.buffer}stream(){let s=pr(this.#e,!0);return new globalThis.ReadableStream({type:"bytes",async pull(l){let b=await s.next();b.done?l.close():l.enqueue(b.value)},async cancel(){await s.return()}})}slice(s=0,l=this.size,b=""){let{size:d}=this,R=s<0?Math.max(d+s,0):Math.min(s,d),C=l<0?Math.max(d+l,0):Math.min(l,d),ue=Math.max(C-R,0),P=this.#e,S=[],c=0;for(let v of P){if(c>=ue)break;let M=ArrayBuffer.isView(v)?v.byteLength:v.size;if(R&&M<=R)R-=M,C-=M;else{let N;ArrayBuffer.isView(v)?(N=v.subarray(R,Math.min(M,C)),c+=N.byteLength):(N=v.slice(R,Math.min(M,C)),c+=N.size),C-=M,S.push(N),R=0}}let W=new yr([],{type:String(b).toLowerCase()});return W.#r=ue,W.#e=S,W}get[Symbol.toStringTag](){return"Blob"}static[Symbol.hasInstance](s){return s&&typeof s=="object"&&typeof s.constructor=="function"&&(typeof s.stream=="function"||typeof s.arrayBuffer=="function")&&/^(Blob|File)$/.test(s[Symbol.toStringTag])}};Object.defineProperties(Vn.prototype,{size:{enumerable:!0},type:{enumerable:!0},slice:{enumerable:!0}});Va=Vn,ge=Va});var Ha,Ga,vt,_r=Ct(()=>{Pt();Ha=class extends ge{#e=0;#t="";constructor(s,l,b={}){if(arguments.length<2)throw new TypeError(`Failed to construct 'File': 2 arguments required, but only ${arguments.length} present.`);super(s,b),b===null&&(b={});let d=b.lastModified===void 0?Date.now():Number(b.lastModified);Number.isNaN(d)||(this.#e=d),this.#t=String(l)}get name(){return this.#t}get lastModified(){return this.#e}get[Symbol.toStringTag](){return"File"}static[Symbol.hasInstance](s){return!!s&&s instanceof ge&&/^(File)$/.test(s[Symbol.toStringTag])}},Ga=Ha,vt=Ga});function bi(f,s=ge){var l=`${Hn()}${Hn()}`.replace(/\./g,"").slice(-28).padStart(32,"-"),b=[],d=`--${l}\r
|
|
2
|
-
Content-Disposition: form-data; name="`;return f.forEach((R,C)=>typeof R=="string"?b.push(d+Sr(C)+`"\r
|
|
3
|
-
\r
|
|
4
|
-
${R.replace(/\r(?!\n)|(?<!\r)\n/g,`\r
|
|
5
|
-
`)}\r
|
|
6
|
-
`):b.push(d+Sr(C)+`"; filename="${Sr(R.name,1)}"\r
|
|
7
|
-
Content-Type: ${R.type||"application/octet-stream"}\r
|
|
8
|
-
\r
|
|
9
|
-
`,R,`\r
|
|
10
|
-
`)),b.push(`--${l}--`),new s(b,{type:"multipart/form-data; boundary="+l})}var Ye,xa,Za,Hn,Xa,Gn,Sr,Re,ci,Ja=Ct(()=>{Pt();_r();({toStringTag:Ye,iterator:xa,hasInstance:Za}=Symbol),Hn=Math.random,Xa="append,set,get,getAll,delete,keys,values,entries,forEach,constructor".split(","),Gn=(f,s,l)=>(f+="",/^(Blob|File)$/.test(s&&s[Ye])?[(l=l!==void 0?l+"":s[Ye]=="File"?s.name:"blob",f),s.name!==l||s[Ye]=="blob"?new vt([s],l,s):s]:[f,s+""]),Sr=(f,s)=>(s?f:f.replace(/\r?\n|\r/g,`\r
|
|
11
|
-
`)).replace(/\n/g,"%0A").replace(/\r/g,"%0D").replace(/"/g,"%22"),Re=(f,s,l)=>{if(s.length<l)throw new TypeError(`Failed to execute '${f}' on 'FormData': ${l} arguments required, but only ${s.length} present.`)},ci=class{#e=[];constructor(...s){if(s.length)throw new TypeError("Failed to construct 'FormData': parameter 1 is not of type 'HTMLFormElement'.")}get[Ye](){return"FormData"}[xa](){return this.entries()}static[Za](s){return s&&typeof s=="object"&&s[Ye]==="FormData"&&!Xa.some(l=>typeof s[l]!="function")}append(...s){Re("append",arguments,2),this.#e.push(Gn(...s))}delete(s){Re("delete",arguments,1),s+="",this.#e=this.#e.filter(([l])=>l!==s)}get(s){Re("get",arguments,1),s+="";for(var l=this.#e,b=l.length,d=0;d<b;d++)if(l[d][0]===s)return l[d][1];return null}getAll(s,l){return Re("getAll",arguments,1),l=[],s+="",this.#e.forEach(b=>b[0]===s&&l.push(b[1])),l}has(s){return Re("has",arguments,1),s+="",this.#e.some(l=>l[0]===s)}forEach(s,l){Re("forEach",arguments,1);for(var[b,d]of this)s.call(l,d,b,this)}set(...s){Re("set",arguments,2);var l=[],b=!0;s=Gn(...s),this.#e.forEach(d=>{d[0]===s[0]?b&&(b=!l.push(s)):l.push(d)}),b&&l.push(s),this.#e=l}*entries(){yield*this.#e}*keys(){for(var[s]of this)yield s}*values(){for(var[,s]of this)yield s}}});var Zn=mr((pi,xn)=>{if(!globalThis.DOMException)try{let{MessageChannel:f}=wt("worker_threads"),s=new f().port1,l=new ArrayBuffer;s.postMessage(l,[l,l])}catch(f){f.constructor.name==="DOMException"&&(globalThis.DOMException=f.constructor)}xn.exports=globalThis.DOMException});import{statSync as Xn,createReadStream as Ka,promises as ei}from"node:fs";import{basename as ti}from"node:path";var Jn,gr,Ri,wi,Ci,Ti,Kn,eo,Et,ri=Ct(()=>{Jn=$n(Zn(),1);_r();Pt();({stat:gr}=ei),Ri=(f,s)=>Kn(Xn(f),f,s),wi=(f,s)=>gr(f).then(l=>Kn(l,f,s)),Ci=(f,s)=>gr(f).then(l=>eo(l,f,s)),Ti=(f,s)=>eo(Xn(f),f,s),Kn=(f,s,l="")=>new ge([new Et({path:s,size:f.size,lastModified:f.mtimeMs,start:0})],{type:l}),eo=(f,s,l="")=>new vt([new Et({path:s,size:f.size,lastModified:f.mtimeMs,start:0})],ti(s),{type:l,lastModified:f.mtimeMs}),Et=class f{#e;#t;constructor(s){this.#e=s.path,this.#t=s.start,this.size=s.size,this.lastModified=s.lastModified}slice(s,l){return new f({path:this.#e,lastModified:this.lastModified,size:l-s,start:this.#t+s})}async*stream(){let{mtimeMs:s}=await gr(this.#e);if(s>this.lastModified)throw new Jn.default("The requested file could not be read, typically due to permission problems that have occurred after a reference to a file was acquired.","NotReadableError");yield*Ka(this.#e,{start:this.#t,end:this.#t+this.size-1})}get[Symbol.toStringTag](){return"Blob"}}});export{ge as a,Pt as b,vt as c,ci as d,bi as e,Ja as f,Ri as g,wi as h,Ci as i,Ti as j,ri as k};
|
|
12
|
-
/*! Bundled license information:
|
|
13
|
-
|
|
14
|
-
web-streams-polyfill/dist/ponyfill.es2018.js:
|
|
15
|
-
(**
|
|
16
|
-
* @license
|
|
17
|
-
* web-streams-polyfill v3.3.3
|
|
18
|
-
* Copyright 2024 Mattias Buelens, Diwank Singh Tomer and other contributors.
|
|
19
|
-
* This code is released under the MIT license.
|
|
20
|
-
* SPDX-License-Identifier: MIT
|
|
21
|
-
*)
|
|
22
|
-
|
|
23
|
-
fetch-blob/index.js:
|
|
24
|
-
(*! fetch-blob. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> *)
|
|
25
|
-
|
|
26
|
-
formdata-polyfill/esm.min.js:
|
|
27
|
-
(*! formdata-polyfill. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> *)
|
|
28
|
-
|
|
29
|
-
node-domexception/index.js:
|
|
30
|
-
(*! node-domexception. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> *)
|
|
31
|
-
*/
|
package/chunks/chunk-IFE5SYGK.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{f as e}from"./chunk-Y5E7ZCCX.js";var n={command:"eser",devCommand:"deno task cli",npmPackage:"eser",jsrPackage:"@eserstack/cli"},r="npx eser@latest noskills",t=r,i=s=>{t=s},a=()=>t,m=s=>`${t} ${s}`,c=async()=>await e(n,["noskills","nos"])??r;export{i as a,a as b,m as c,c as d};
|
package/chunks/chunk-IM73MYMS.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{f as r}from"./chunk-HB62UGZI.js";import{i}from"./chunk-Y5E7ZCCX.js";var o=async e=>{try{return await r`which ${e}`.noThrow().code()===0}catch{return!1}},s=async()=>{try{return(await fetch("http://localhost:11434/api/version",{signal:AbortSignal.timeout(1e3)})).ok}catch{return!1}},a=e=>i.env.has(e),c=async()=>{let[e,t,l,n]=await Promise.all([o("claude"),s(),o("opencode"),o("kiro")]);return[{name:"claude-code",alias:"cc",type:"CLI",available:e,detail:e?"claude binary found":"claude not on PATH"},{name:"ollama",alias:"ol",type:"HTTP",available:t,detail:t?"localhost:11434 reachable":"localhost:11434 not reachable"},{name:"opencode",alias:"oc",type:"CLI",available:l,detail:l?"opencode binary found":"opencode not on PATH"},{name:"kiro",alias:"kr",type:"CLI",available:n,detail:n?"kiro binary found":"kiro not on PATH"},{name:"anthropic",alias:"ant",type:"API",available:a("ANTHROPIC_API_KEY")||a("ANTHROPIC_AUTH_TOKEN"),detail:a("ANTHROPIC_API_KEY")?"ANTHROPIC_API_KEY set":a("ANTHROPIC_AUTH_TOKEN")?"ANTHROPIC_AUTH_TOKEN set":"ANTHROPIC_API_KEY not set"},{name:"openai",alias:"oai",type:"API",available:a("OPENAI_API_KEY"),detail:a("OPENAI_API_KEY")?"OPENAI_API_KEY set":"OPENAI_API_KEY not set"},{name:"gemini",alias:"gem",type:"API",available:a("GEMINI_API_KEY")||a("GOOGLE_API_KEY"),detail:a("GEMINI_API_KEY")||a("GOOGLE_API_KEY")?"API key set":"GEMINI_API_KEY not set"},{name:"vertexai",alias:"vtx",type:"API",available:a("GOOGLE_CLOUD_PROJECT"),detail:a("GOOGLE_CLOUD_PROJECT")?"GOOGLE_CLOUD_PROJECT set":"GOOGLE_CLOUD_PROJECT not set"}]},_=async()=>(await c()).filter(t=>t.available).map(t=>t.name);export{c as a,_ as b};
|
package/chunks/chunk-J25XTDQQ.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as t}from"./chunk-CH6A3LES.js";var r=o=>{let e=o;return typeof e.submitBatch=="function"&&typeof e.getBatchJob=="function"&&typeof e.listBatchJobs=="function"&&typeof e.downloadBatchResults=="function"&&typeof e.cancelBatchJob=="function"};var a=new t({description:"AI provider interface \u2014 ask questions, generate content",modules:{ask:{description:"Send a prompt to an AI provider",load:()=>import("./ask-UB26SBWQ.js")},list:{description:"List available AI providers",load:()=>import("./list-WO6RS7JX.js")}}});export{r as a,a as b};
|
package/chunks/chunk-JYVB6UAV.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var t=class extends Error{provider;statusCode;constructor(e,r){super(e,{cause:r?.cause}),this.name="AiError",this.provider=r?.provider??null,this.statusCode=r?.statusCode??null}},i=class extends t{constructor(e,r){super(e,{...r,statusCode:r?.statusCode??429}),this.name="RateLimitedError"}},o=class extends t{constructor(e,r){super(e,{...r,statusCode:r?.statusCode??401}),this.name="AuthFailedError"}},u=class extends t{constructor(e,r){super(e,{...r,statusCode:r?.statusCode??402}),this.name="InsufficientCreditsError"}},a=class extends t{constructor(e,r){super(e,{...r,statusCode:r?.statusCode??400}),this.name="BadRequestError"}},c=class extends t{constructor(e,r){super(e,{...r,statusCode:r?.statusCode??503}),this.name="ServiceUnavailableError"}},p=class extends t{constructor(e){super(`Model "${e}" not found in registry`),this.name="ModelNotFoundError"}},f=class extends t{constructor(e){super(`Model "${e}" already exists in registry`),this.name="ModelAlreadyExistsError"}},x=class extends t{constructor(e){super(`No factory registered for provider "${e}"`),this.name="UnsupportedProviderError"}},E=s=>s===429?i:s===401?o:s===402?u:s===400?a:s===500||s===503||s===529?c:null,m=(s,e,r)=>{let n=E(e);return n!==null?new n(r.message,{provider:s,statusCode:e,cause:r}):new t(r.message,{provider:s,statusCode:e,cause:r})},g={rate_limited:i,auth_failed:o,insufficient_credits:u,bad_request:a,service_unavailable:c},y=(s,e,r,n)=>{let d=n!==void 0&&n>0?n:void 0,l=r===void 0?void 0:g[r];return l===void 0?new t(e,{provider:s,statusCode:d}):new l(e,{provider:s,statusCode:d})};export{t as a,i as b,o as c,u as d,a as e,c as f,p as g,f as h,x as i,E as j,m as k,y as l};
|
package/chunks/chunk-KJLEPI7T.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as o}from"./chunk-Z7OYXH3J.js";var d=(e,n)=>{if(e!==void 0)for(let r of e){if(r==="--agent")return"agent";if(r==="--human")return"human"}let t=n?.agentMode;return t===!0?"agent":t===!1?"human":o()};var u=e=>e===void 0?[]:e.filter(n=>n!=="--agent"&&n!=="--human"&&n!=="--non-interactive");export{d as a,u as b};
|
package/chunks/chunk-KRRPOVQG.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as v}from"./chunk-FE4MKOI4.js";import*as t from"node:fs/promises";import*as w from"node:fs";import*as i from"node:path";import*as F from"node:os";import n from"node:process";import{Readable as b,Writable as g}from"node:stream";var p=e=>({isFile:e.isFile(),isDirectory:e.isDirectory(),isSymlink:e.isSymbolicLink(),size:e.size,mtime:e.mtime,atime:e.atime,birthtime:e.birthtime,mode:e.mode}),l=(e,r)=>{throw e instanceof Error&&"code"in e&&e.code==="ENOENT"?new v(r):e},x=()=>({async readFile(e,r){try{let s=await t.readFile(e,{signal:r?.signal});return new Uint8Array(s)}catch(s){return l(s,e)}},async readTextFile(e,r){try{return await t.readFile(e,{encoding:"utf-8",signal:r?.signal})}catch(s){return l(s,e)}},async writeFile(e,r,s){let a=s?.append?"a":"w";await t.writeFile(e,r,{signal:s?.signal,mode:s?.mode,flag:a})},async writeTextFile(e,r,s){let a=s?.append?"a":"w";await t.writeFile(e,r,{encoding:"utf-8",signal:s?.signal,mode:s?.mode,flag:a})},async exists(e){try{return await t.access(e),!0}catch{return!1}},async stat(e){try{let r=await t.stat(e);return p(r)}catch(r){return l(r,e)}},async lstat(e){try{let r=await t.lstat(e);return p(r)}catch(r){return l(r,e)}},async mkdir(e,r){await t.mkdir(e,{recursive:r?.recursive??!1,mode:r?.mode})},async ensureDir(e){await t.mkdir(e,{recursive:!0})},async remove(e,r){try{await t.rm(e,{recursive:r?.recursive??!1,force:!1})}catch(s){l(s,e)}},async*readDir(e){try{let r=await t.readdir(e,{withFileTypes:!0});for(let s of r)yield{name:s.name,isFile:s.isFile(),isDirectory:s.isDirectory(),isSymlink:s.isSymbolicLink()}}catch(r){l(r,e)}},async copyFile(e,r){await t.copyFile(e,r)},async rename(e,r){await t.rename(e,r)},async makeTempDir(e){let r=e?.dir??F.tmpdir(),s=e?.prefix??"",a=e?.suffix??"",c=await t.mkdtemp(i.join(r,s));if(a){let m=c+a;return await t.rename(c,m),m}return c},async realPath(e){try{return await t.realpath(e)}catch(r){return l(r,e)}},watch(e,r){let s=r?.recursive??!0,a=[],c=[],m=[],u=!1,f=o=>{u||(m.length>0?m.shift()({value:o,done:!1}):c.push(o))};for(let o of e)try{let d=w.watch(o,{recursive:s},(y,P)=>{P!==null&&f({kind:y==="rename"?"create":"modify",paths:[i.join(o,P)]})});a.push(d)}catch{}return{close:()=>{u=!0;for(let o of a)o.close();for(let o of m)o({value:void 0,done:!0});m=[]},[Symbol.asyncIterator]:()=>({next:()=>u?Promise.resolve({value:void 0,done:!0}):c.length>0?Promise.resolve({value:c.shift(),done:!1}):new Promise(o=>{m.push(o)})})}},async chmod(e,r){await t.chmod(e,r)},async*walk(e,r){let s=r?.includeDirs??!0,a=r?.includeFiles??!0,c=r?.exts,m=r?.skip,u=async function*(f){let o=await t.readdir(f,{withFileTypes:!0});for(let d of o){let y=i.join(f,d.name);if(m?.some(h=>h.test(y)))continue;let P=d.isSymbolicLink();if(d.isDirectory())s&&(yield{path:y,name:d.name,isFile:!1,isDirectory:!0,isSymlink:P}),yield*u(y);else if(d.isFile()||P){if(!a||c&&!c.some(h=>d.name.endsWith(h.startsWith(".")?h:`.${h}`)))continue;yield{path:y,name:d.name,isFile:d.isFile(),isDirectory:!1,isSymlink:P}}}};yield*u(e)}}),R=()=>({join:i.join,resolve:i.resolve,dirname:i.dirname,basename:i.basename,extname:i.extname,normalize:i.normalize,isAbsolute:i.isAbsolute,relative:i.relative,parse:i.parse,format:i.format,sep:i.sep,delimiter:i.delimiter}),W=()=>({get(e){return n.env[e]},set(e,r){n.env[e]=r},delete(e){delete n.env[e]},has(e){return e in n.env},toObject(){let e={};for(let[r,s]of Object.entries(n.env))s!==void 0&&(e[r]=s);return e}}),T=()=>({exit(e){n.exit(e)},setExitCode(e){n.exitCode=e},cwd(){return n.cwd()},chdir(e){n.chdir(e)},hostname(){return F.hostname()},execPath(){return n.execPath},argv:n.argv,argv0:n.argv0,args:n.argv.slice(2),pid:n.pid,isAlive(e){try{return n.kill(e,0),!0}catch(r){return r.code==="EPERM"}},stdin:b.toWeb(n.stdin),stdout:g.toWeb(n.stdout),stderr:g.toWeb(n.stderr),isTerminal(e){switch(e){case"stdin":return n.stdin.isTTY===!0;case"stdout":return n.stdout.isTTY===!0;case"stderr":return n.stderr.isTTY===!0}},setStdinRaw(e){n.stdin.setRawMode(e)},writeToStdout(e){n.stdout.write(e)},consoleSize(){return{columns:n.stdout.columns??80,rows:n.stdout.rows??24}}});export{x as a,R as b,W as c,T as d};
|
package/chunks/chunk-LGQEWL5X.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as S,b as p,c as v,d as w,e as g,f as m,g as f}from"./chunk-Y45DQJSS.js";import{a as l}from"./chunk-JYVB6UAV.js";import{a as h,b as k}from"./chunk-OAWYVETM.js";var y=class{capabilities=["text_generation","streaming"];provider="opencode";modelId;binary;config;constructor(e,r){this.binary=e,this.config=r,this.modelId=r.model}async generateText(e,r){let o=T(this.config,e,"json"),i=f(e.messages,e.system),s=p(this.binary,o,{signal:r,stdinData:i}),c=g(s.stderr),t=await w(s.stdout,this.modelId),u=await s.waitForExit(),a=await c,d=m("opencode",u.code,a);return d!==null?k(d):h(t)}async*streamText(e,r){let o=T(this.config,e,"stream-json"),i=f(e.messages,e.system),s=p(this.binary,o,{signal:r,stdinData:i}),c=g(s.stderr);try{for await(let d of v(s.stdout)){let x=E(d);x!==null&&(yield x)}let t=await s.waitForExit(),u=await c,a=m("opencode",t.code,u);a!==null&&(yield{kind:"error",error:a})}catch(t){t instanceof l?yield{kind:"error",error:t}:yield{kind:"error",error:new l(t instanceof Error?t.message:String(t),{provider:"opencode",cause:t instanceof Error?t:void 0})}}}close(){return Promise.resolve()}getRawClient(){return null}},_={provider:"opencode",async createModel(n){let e=await S("opencode",n);return new y(e,n)}},T=(n,e,r)=>{let o=["--output-format",r];o.push("--model",n.model),e.maxTokens!==void 0&&o.push("--max-tokens",String(e.maxTokens));let i=n.properties?.args;return i!==void 0&&o.push(...i),o},E=n=>{if(n===null||typeof n!="object")return null;let e=n;if(e.type==="content_block_delta"||e.type==="assistant"){let r=e.delta?.text??e.message?.content?.[0]?.text;return r!==void 0?{kind:"content_delta",textDelta:r}:null}return e.type==="result"||e.done===!0?{kind:"message_done",stopReason:"end_turn",usage:{inputTokens:e.usage?.input_tokens??0,outputTokens:e.usage?.output_tokens??0,totalTokens:(e.usage?.input_tokens??0)+(e.usage?.output_tokens??0)}}:e.type==="error"?{kind:"error",error:new l(e.error?.message??"Unknown OpenCode error",{provider:"opencode"})}:e.content!==void 0&&typeof e.content=="string"?{kind:"content_delta",textDelta:e.content}:null};export{y as a,_ as b};
|
package/chunks/chunk-LJEWPIEI.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{f as s,u as o,v as i,w as a}from"./chunk-FE4MKOI4.js";var c={fs:!1,fsSync:!1,exec:!1,process:!1,env:!0,stdin:!1,stdout:!1,kv:!0},t=new Map,u=()=>({get(e){return t.get(e)},set(e,n){t.set(e,n)},delete(e){t.delete(e)},has(e){return t.has(e)},toObject(){return Object.fromEntries(t)}}),l=e=>{for(let[n,r]of Object.entries(e))r!=null&&r.constructor===String&&t.set(n,r)},f=()=>{t.clear()},m=()=>({name:"workerd",version:"unknown",capabilities:c,fs:o("workerd"),path:s,exec:i("workerd"),env:u(),process:a("workerd")});export{c as a,l as b,f as c,m as d};
|
package/chunks/chunk-LKZZ4JN5.js
DELETED
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
import{a as b}from"./chunk-IFE5SYGK.js";import{f as y}from"./chunk-WDKWHGJU.js";import{i as n}from"./chunk-Y5E7ZCCX.js";var S="<!-- noskills:start -->",g="<!-- noskills:end -->",Y=(e,t,s="npx eser noskills")=>{let o=[S,"## noskills orchestrator","","State-driven orchestration. Do NOT read `.eser/` files directly \u2014 noskills provides everything via JSON.","","### Protocol","",` ${s} spec <name> next # get instruction`,` ${s} spec <name> next --answer="response" # submit and advance`,` ${s} spec new "description" # create spec (name auto-generated)`,"","Every spec command MUST include `spec <name>`. Use `"+s+" spec list` for available specs.","","### Core rules","","- Call noskills ONCE per interaction. One question, one answer, one submit.","- Call `next` at: conversation start, before file edits, after completing work, at decisions.","- Never batch-submit. Never answer discovery questions yourself.","- Never skip steps or infer decisions. Ask first. Explicit > Clever.","- NEVER suggest bypassing or skipping noskills. Discovery is not overhead.","- NEVER ask permission to run the next noskills command. After spec new \u2192 run next. After approve \u2192 run next. Each step has one next step. Just run it.","- Execute noskills commands IMMEDIATELY \u2014 the output has all context needed.","- Display `roadmap` before content. Display `gate` prominently.","","### Interactive choices","","- Use AskUserQuestion for `interactiveOptions`. Use `commandMap` to resolve selections.","- On recurring patterns or corrections: ask 'Permanent rule?' \u2192 `"+s+' rule add "description"`.'];if((t?.allowGit??!1)||o.push("","### Git","","Read-only: log, diff, status, show, blame. No write commands (commit, push, checkout, etc.)."),o.push("","### Spec Creation","","When the user wants a spec:",'1. Ask "What do you want to build?" \u2014 nothing else.',"2. Take their full answer as the description.",`3. Run: ${s} spec new "their answer"`,"Do NOT suggest names. Do NOT analyze before creating. Just ask, take the answer, create.","","### Concern Management","",'When user says "add concerns" or "manage concerns":',`- Run \`${s} concern list\` immediately. Do NOT analyze which concerns are appropriate.`,"- Present list via AskUserQuestion with multiSelect:true, max 4 options per question.",`- Add all selected concerns in ONE command: ${s} concern add open-source well-engineered long-lived`,"","### Discovery","","Listen first: after spec creation, ask user to share context before mode selection.","Modes: full (default), validate, technical-depth, ship-fast, explore.","Pre-scan codebase before questions. Challenge premises. Propose alternatives.","With --from-plan: extract answers, present for user confirmation.","","### Mode Management","","noskills manages Claude Code plan mode transitions automatically.","Follow the `modeDirective` field in each `noskills next` output.","","| Phase | Mode |","|-------|------|","| IDLE | plan mode optional \u2014 no active spec |","| DISCOVERY, DISCOVERY_REFINEMENT, SPEC_PROPOSAL | **plan mode** \u2014 read-only, no file edits |","| EXECUTING | **normal mode** \u2014 full write access for sub-agents |","| BLOCKED | **plan mode** \u2014 analyze the blocker, do not edit |","| COMPLETED | plan mode optional |","","Non-Claude-Code platforms: `modeDirective` is advisory. Hooks enforce file restrictions mechanically.","","### Execution","","- Re-read files before and after editing. Files >500 LOC: read in chunks.","- Run type-check + lint after every edit. Never mark AC passed if type-check fails.","- If search returns few results, re-run narrower \u2014 assume truncation.","- Clean dead code before structural refactors on files >300 LOC.","- Complete the spec \u2014 no mid-execution pauses or checkpoints.","- `meta` block has resume context for session start or after compaction."),e.length>0){o.push("","### Active Rules","");for(let i of e)o.push(`- ${i}`)}return o.push(g),o.join(`
|
|
2
|
-
`)},x=async(e,t,s,o="npx eser noskills")=>{let i=`${e}/CLAUDE.md`,r=Y(t,s,o),a;try{a=await n.fs.readTextFile(i);let l=a.indexOf(S),c=a.indexOf(g);l!==-1&&c!==-1?a=a.slice(0,l)+r+a.slice(c+g.length):a=a.trimEnd()+`
|
|
3
|
-
|
|
4
|
-
`+r+`
|
|
5
|
-
`}catch{a=r+`
|
|
6
|
-
`}await n.fs.writeTextFile(i,a)};var J=e=>({hooks:{PreToolUse:[{matcher:"Write|Edit|MultiEdit|Bash",hooks:[{type:"command",command:`${e} invoke-hook pre-tool-use`,timeout:5}]}],PostToolUse:[{matcher:"Write|Edit|MultiEdit",hooks:[{type:"command",command:`${e} invoke-hook post-file-write`,timeout:3}]},{matcher:"Bash",hooks:[{type:"command",command:`${e} invoke-hook post-bash`,timeout:3}]},{matcher:"AskUserQuestion",hooks:[{type:"command",command:`${e} invoke-hook post-ask-user-question`,timeout:3}]}],Stop:[{hooks:[{type:"command",command:`${e} invoke-hook stop`,timeout:10}]}],SessionStart:[{hooks:[{type:"command",command:`${e} invoke-hook session-start`,timeout:5}]}]}}),R=async(e,t="npx eser@latest noskills")=>{let s=`${e}/.claude/settings.json`,o={};try{let a=await n.fs.readTextFile(s);o=JSON.parse(a)}catch{}let i=J(t),r={...o,...i};await n.fs.mkdir(`${e}/.claude`,{recursive:!0}),await n.fs.writeTextFile(s,JSON.stringify(r,null,2)+`
|
|
7
|
-
`)};var q=async(e,t)=>{let s=`${e}/.claude/agents`;await n.fs.mkdir(s,{recursive:!0});let o=`---
|
|
8
|
-
name: noskills-executor
|
|
9
|
-
description: "Executes a single noskills task."
|
|
10
|
-
tools: Read, Edit, MultiEdit, Write, Bash, Grep, Glob, LS
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
You are executing a single task from a noskills spec.
|
|
14
|
-
Your ONLY job is to complete the task described in the prompt.
|
|
15
|
-
Follow all behavioral rules provided in the prompt.
|
|
16
|
-
Do NOT start new tasks, explore unrelated code, or make architectural decisions.
|
|
17
|
-
If the task is too vague to execute, say so immediately.
|
|
18
|
-
|
|
19
|
-
## Self-Verification
|
|
20
|
-
After completing the task, you MUST verify your own work before reporting:
|
|
21
|
-
1. Run type check: \`deno check\` on all modified files
|
|
22
|
-
2. Run test suite: \`deno test\` on the relevant test files
|
|
23
|
-
3. If type check or tests fail, fix the issues before reporting
|
|
24
|
-
|
|
25
|
-
## Reporting
|
|
26
|
-
When finished, provide a structured JSON summary:
|
|
27
|
-
\\\`\\\`\\\`json
|
|
28
|
-
{"completed": ["<item IDs done>"], "remaining": ["<item IDs not done>"], "blocked": ["<item IDs needing decisions>"], "filesModified": ["<paths>"], "verification": {"typeCheck": "pass|fail", "tests": "pass|fail (N passed, M failed)"}}
|
|
29
|
-
\\\`\\\`\\\`
|
|
30
|
-
|
|
31
|
-
Do NOT return raw test output \u2014 summarize it in the verification field.
|
|
32
|
-
The orchestrator will submit this to \`${t} next --answer\` on your behalf.
|
|
33
|
-
`;await n.fs.writeTextFile(`${s}/noskills-executor.md`,o)},K=async(e,t)=>{let s=`${e}/.claude/agents`;await n.fs.mkdir(s,{recursive:!0}),await n.fs.writeTextFile(`${s}/noskills-verifier.md`,`---
|
|
34
|
-
name: noskills-verifier
|
|
35
|
-
description: "Independently verifies completed task work. Read-only. Never sees the executor's context."
|
|
36
|
-
tools: Read, Bash, Grep, Glob, LS
|
|
37
|
-
---
|
|
38
|
-
|
|
39
|
-
You are verifying another agent's work. You have NO context about how it was done.
|
|
40
|
-
Read the changed files. Run the test suite. Check each acceptance criterion independently.
|
|
41
|
-
|
|
42
|
-
For each acceptance criterion:
|
|
43
|
-
- PASS: with evidence \u2014 show the grep result, the test output, or the file content that proves it
|
|
44
|
-
- FAIL: with specific reason \u2014 what's missing, what's wrong, what doesn't match
|
|
45
|
-
|
|
46
|
-
Be skeptical. Don't assume anything works \u2014 verify it yourself.
|
|
47
|
-
You CANNOT edit files. Read-only access only.
|
|
48
|
-
|
|
49
|
-
## Verification Steps
|
|
50
|
-
1. Read each modified file and verify the changes are correct
|
|
51
|
-
2. Run type check: \\\`deno check\\\` on modified files
|
|
52
|
-
3. Run tests: \\\`deno test\\\` on relevant test files
|
|
53
|
-
4. Check each acceptance criterion against actual file contents
|
|
54
|
-
|
|
55
|
-
## Report Format
|
|
56
|
-
When finished, provide a structured JSON summary:
|
|
57
|
-
\\\`\\\`\\\`json
|
|
58
|
-
{"results": [{"id": "ac-1", "status": "PASS", "evidence": "..."}, {"id": "ac-2", "status": "FAIL", "reason": "..."}]}
|
|
59
|
-
\\\`\\\`\\\`
|
|
60
|
-
|
|
61
|
-
The orchestrator will use this report for the noskills status report.
|
|
62
|
-
`)},A={id:"claude-code",capabilities:{rules:!0,hooks:!0,agents:!0,specs:!1,mcp:!1,interaction:{hasAskUserTool:!0,optionPresentation:"tool",hasSubAgentDelegation:!0,subAgentMethod:"task"}},async syncRules(e,t){await x(e.root,e.rules,t,e.commandPrefix)},async syncHooks(e,t){await R(e.root,e.commandPrefix)},async syncAgents(e,t){await q(e.root,e.commandPrefix),await K(e.root,e.commandPrefix)}};var T=async(e,t,s="npx eser noskills")=>{let o=["# Generated by noskills \u2014 do not edit manually","","## noskills orchestrator","","This project uses noskills for state-driven orchestration.","Do NOT read `.eser/specs/` or `.eser/rules/` directly. noskills gives you what you need.","",`Run \`${s} next\` to get your current instruction.`,`Submit results with \`${s} next --answer="..."\``,"","## Why noskills calls matter","","noskills is not a form to fill out. It is a live state machine that the user","watches in real-time. Every `"+s+" next --answer` call:","","- Updates the spec file on disk (the user sees it change)","- Updates the terminal dashboard if `noskills watch` is running","- Advances the state machine to the next phase","- Records the decision permanently in the project history","","When you batch-submit answers or backfill discovery responses yourself,","the user sees nothing happening \u2014 then suddenly everything jumps forward.","This defeats the purpose.","","Call noskills ONCE per interaction. Ask the user ONE question. Wait for","their answer. Submit it. Ask the next. The user is watching every step.","Do NOT pre-fill answers. Do NOT batch multiple answers. Do NOT answer","discovery questions yourself \u2014 the user's input is the data.","","## When to call noskills next","","1. At the START of every conversation","2. BEFORE creating or modifying any file","3. AFTER completing a logical unit of work","4. When you encounter a DECISION that affects architecture","5. When you are UNSURE what to do next","","NEVER proceed with implementation without checking noskills first.","NEVER suggest bypassing or skipping noskills. Discovery is not overhead.","NEVER ask permission to run the next noskills command. After spec new \u2192 run next. After approve \u2192 run next. Each step has one next step. Just run it.","","## Interactive choices","","Present choices as numbered lists. Users select by number.","When interactiveOptions are present in noskills output, present each as a","numbered item with its label and description. Ask the user to pick a number.","","## Execution model","","Execute tasks sequentially in this context. Do not attempt to spawn sub-agents.",""];if(t.length>0){o.push("## Rules","");for(let i of t)o.push(`- ${i}`);o.push("")}await n.fs.writeTextFile(`${e}/.cursorrules`,o.join(`
|
|
63
|
-
`))};var C={id:"cursor",capabilities:{rules:!0,hooks:!1,agents:!1,specs:!1,mcp:!1,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!1,subAgentMethod:"none"}},async syncRules(e){await T(e.root,e.rules,e.commandPrefix)}};var X=".kiro/steering",O=".kiro/settings",Z=".kiro/agents",ee=".kiro/specs",te="hooks.json",se="mcp.json",oe="noskills-protocol.md",ne="noskills-coaching.md",k="noskills-rules.md",E="conventions.md",ie="noskills-executor.json",re="noskills-verifier.json",ae=(e,t)=>{let s=["---","inclusion: always","---","","# noskills Protocol","","# Generated by noskills \u2014 do not edit manually","","## What is noskills","","This project uses noskills for state-driven orchestration.","Do NOT read `.eser/rules/`, `.eser/specs/`, or concern files directly.","noskills gives you exactly what you need via JSON output.","","## Protocol","",` ${e} spec <name> next # get current instruction`,` ${e} spec <name> next --answer="your response" # submit result and advance`,"","Every noskills command that operates on a spec MUST include `spec <name>`.",`Never omit it. Use \`${e} spec list\` to see available specs.`,"","## Why noskills calls matter","","noskills is not a form to fill out. It is a live state machine that the user","watches in real-time. Every `"+e+" next --answer` call:","","- Updates the spec file on disk (the user sees it change)","- Updates the terminal dashboard if `noskills watch` is running","- Advances the state machine to the next phase","- Records the decision permanently in the project history","","When you batch-submit answers or backfill discovery responses yourself,","the user sees nothing happening \u2014 then suddenly everything jumps forward.","This defeats the purpose.","","Call noskills ONCE per interaction. Ask the user ONE question. Wait for","their answer. Submit it. Ask the next. The user is watching every step.","Do NOT pre-fill answers. Do NOT batch multiple answers. Do NOT answer","discovery questions yourself \u2014 the user's input is the data.","","## When to call noskills next","",`You MUST call \`${e} next\` in these situations:`,"","1. At the **START** of every conversation (first thing you do)","2. **BEFORE** creating or modifying any file (to verify you have an active task)","3. **AFTER** completing a logical unit of work (to report progress)","4. When you encounter a **DECISION** that affects architecture or scope","5. When you are **UNSURE** what to do next","","NEVER proceed with implementation without checking noskills first.","NEVER make architectural decisions independently \u2014 noskills routes them to the user."];return(t?.allowGit??!1)||s.push("","## Git is read-only","","You MUST NOT run git write commands: commit, add, push, checkout, stash,","reset, merge, rebase, cherry-pick. The user controls git. You control files.","You MAY read from git: log, diff, status, show, blame."),s.push("","## Interactive choices","","Present choices as numbered lists. Users select by number.","When interactiveOptions are present in noskills output, present each as a","numbered item with its label and description. Ask the user to pick a number.","Use the `commandMap` to resolve the user's selection to a CLI command.","","## Decision principle: Explicit > Clever","","You NEVER skip steps, bypass questions, or make assumptions on behalf of the user.","- Discovery questions \u2192 ask the user, don't answer yourself","- Classification \u2192 ask the user, don't infer","- Spec approval \u2192 ask the user, don't auto-approve","- Task refinement \u2192 ask the user, don't self-assign","- Rule promotion \u2192 ask the user, don't decide",`If you think something can be skipped, ASK "would you like to skip this?" \u2014 don't skip it.`,"NEVER suggest bypassing or skipping noskills. Discovery is not overhead.","NEVER ask permission to run the next noskills command. After spec new \u2192 run next. After approve \u2192 run next. Just run it.","","## Command execution","","When told to run a noskills command, execute it IMMEDIATELY. Do not explore,","research, read source code, or plan first. The command output contains all the","context you need. Exploring noskills internals wastes tokens and delays the user.","","## JSON output","","noskills returns JSON with a `phase` field and phase-specific instructions.","The `meta` block contains resume context - use it to orient yourself,","especially after compaction or at the start of a new session.","Follow the `instruction` field. Use `transition` commands to advance state.",""),s.join(`
|
|
64
|
-
`)},ce=e=>["---","inclusion: auto","name: noskills-coaching",'description: "Guidance for noskills spec-driven development workflow, including convention discovery and rule promotion"',"---","","# noskills Coaching","","# Generated by noskills \u2014 do not edit manually","","## Convention discovery","","When you discover a pattern, receive a correction, or identify a recurring",'preference from the user, ask: "Should this be a permanent rule for this',`project, or just for this task?" If permanent, run: \`${e} rule add`,'"<description>"`. If just this task, note it and move on.',"Never write to `.eser/rules/` directly.","","## How to promote rules","","When a convention should be permanent, use the noskills CLI to register it:","",` ${e} rule add "<description of the rule>"`,"","This stores the rule in `.eser/rules/` and ensures it is synced to all","coding tools on the next `noskills sync`. Never edit `.eser/rules/` directly.",""].join(`
|
|
65
|
-
`),le=e=>{let t=["---","inclusion: always","---","","# noskills Rules","","# Generated by noskills \u2014 do not edit manually","","## Active Rules",""];for(let s of e)t.push(`- ${s}`);return t.push(""),t.join(`
|
|
66
|
-
`)},ue=e=>({hooks:[{_noskills:!0,trigger:"Prompt Submit",action:{type:"Run Command",command:`${e} invoke-hook session-start`},timeout:5e3},{_noskills:!0,trigger:"Pre Tool Use",condition:{toolNames:["write","shell"]},action:{type:"Run Command",command:`${e} invoke-hook pre-tool-use`},timeout:5e3},{_noskills:!0,trigger:"Post Tool Use",condition:{toolNames:["write"]},action:{type:"Run Command",command:`${e} invoke-hook post-file-write`},timeout:3e3},{_noskills:!0,trigger:"Post Tool Use",condition:{toolNames:["shell"]},action:{type:"Run Command",command:`${e} invoke-hook post-bash`},timeout:3e3},{_noskills:!0,trigger:"Agent Stop",action:{type:"Run Command",command:`${e} invoke-hook stop`},timeout:1e4}]}),de=e=>{let t=e.split(/\s+/),s=t[0]??"npx",o=[...t.slice(1),"mcp-serve"];return{mcpServers:{noskills:{command:s,args:o,env:{},autoApprove:["noskills_next","noskills_status"],disabled:!1}}}},pe=e=>({name:"noskills-executor",description:"Executes a single noskills task. Follows spec behavioral rules and reports structured results.",tools:["read","write","glob","grep","shell","delegate"],allowedTools:["read","write","glob","grep","shell","delegate"],resources:["file://.kiro/steering/noskills-protocol.md"],prompt:["You are executing a single task from a noskills spec.","Your ONLY job is to complete the task described in the prompt.","Follow all behavioral rules provided in the prompt.","Do NOT start new tasks, explore unrelated code, or make architectural decisions.","If the task is too vague to execute, say so immediately.","","## Self-Verification","After completing the task, you MUST verify your own work before reporting:","1. Run type check: `deno check` on all modified files","2. Run test suite: `deno test` on the relevant test files","3. If type check or tests fail, fix the issues before reporting","","## Reporting","When finished, provide a structured JSON summary:","```json",'{"completed": ["<item IDs done>"], "remaining": ["<item IDs not done>"], "blocked": ["<item IDs needing decisions>"], "filesModified": ["<paths>"], "verification": {"typeCheck": "pass|fail", "tests": "pass|fail (N passed, M failed)"}}',"```","","Do NOT return raw test output \u2014 summarize it in the verification field.",`The orchestrator will submit this to \`${e} next --answer\` on your behalf.`].join(`
|
|
67
|
-
`)}),he=()=>({name:"noskills-verifier",description:"Independently verifies completed task work. Read-only. Never sees the executor's context.",tools:["read","glob","grep","shell","use_subagent"],allowedTools:["read","glob","grep","shell"],resources:["file://.kiro/steering/noskills-protocol.md"],prompt:["You are verifying another agent's work. You have NO context about how it was done.","Read the changed files. Run the test suite. Check each acceptance criterion independently.","","For each acceptance criterion:","- PASS: with evidence \u2014 show the grep result, the test output, or the file content that proves it","- FAIL: with specific reason \u2014 what's missing, what's wrong, what doesn't match","","Be skeptical. Don't assume anything works \u2014 verify it yourself.","You CANNOT edit files. Read-only access only.","","## Verification Steps","1. Read each modified file and verify the changes are correct","2. Run type check: `deno check` on modified files","3. Run tests: `deno test` on relevant test files","4. Check each acceptance criterion against actual file contents","","## Report Format","When finished, provide a structured JSON summary:","```json",'{"results": [{"id": "ac-1", "status": "PASS", "evidence": "..."}, {"id": "ac-2", "status": "FAIL", "reason": "..."}]}',"```","","The orchestrator will use this report for the noskills status report."].join(`
|
|
68
|
-
`)}),N=async e=>{try{return await n.fs.stat(e),!0}catch{return!1}},me=e=>{let s=e.match(/^# Spec:\s*(.+)$/m)?.[1]?.trim()??"Untitled",o=new Map,i=e.split(/^## /m);for(let a of i){let l=a.indexOf(`
|
|
69
|
-
`);if(l===-1)continue;let c=a.slice(0,l).trim().toLowerCase(),u=a.slice(l+1).trim();o.set(c,u)}let r=a=>{for(let[l,c]of o)if(l.startsWith(a.toLowerCase()))return c;return""};return{title:s,concerns:r("concerns"),discoveryAnswers:r("discovery answers"),contributorGuide:r("contributor guide"),publicApi:r("public api"),outOfScope:r("out of scope"),tasks:r("tasks"),verification:r("verification")}},fe=e=>{let t=[`# Feature: ${e.title}`,"","## Overview","",e.discoveryAnswers||"(no discovery answers yet)","","## Requirements",""],s=e.discoveryAnswers.split(`
|
|
70
|
-
`).filter(o=>o.startsWith("### "));if(s.length>0)for(let o of s)t.push(`- ${o.replace(/^###\s*/,"")}`);else e.discoveryAnswers?t.push("- See overview for details"):t.push("- (none yet)");if(t.push("","## Acceptance Criteria",""),e.verification){let o=e.verification.split(`
|
|
71
|
-
`).filter(i=>i.trim());for(let i of o){let r=i.replace(/^[-*]\s*/,"").trim();r&&t.push(`- [ ] ${r}`)}}else t.push("- [ ] (none yet)");return t.push("","## Out of Scope",""),t.push(e.outOfScope||"(nothing listed)"),t.push(""),t.join(`
|
|
72
|
-
`)},ye=e=>{let t=[`# Design: ${e.title}`,"","## Architecture",""];return e.discoveryAnswers?t.push(e.discoveryAnswers):t.push("(no architecture decisions yet)"),t.push("","## Concerns",""),e.concerns?t.push(e.concerns):t.push("(no active concerns)"),t.push("","## Decisions",""),e.contributorGuide||e.publicApi?(e.contributorGuide&&t.push("### Contributor Guide","",e.contributorGuide,""),e.publicApi&&t.push("### Public API Surface","",e.publicApi,"")):t.push("(no decisions yet)"),t.push(""),t.join(`
|
|
73
|
-
`)},ge=e=>{let t=[`# Tasks: ${e.title}`,""];return e.tasks?t.push(e.tasks):t.push("(no tasks yet)"),t.push(""),t.join(`
|
|
74
|
-
`)},$={id:"kiro",capabilities:{rules:!0,hooks:!0,agents:!0,specs:!0,mcp:!0,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!0,subAgentMethod:"delegation"}},async syncRules(e,t){let s=`${e.root}/${X}`;await n.fs.mkdir(s,{recursive:!0}),await n.fs.writeTextFile(`${s}/${oe}`,ae(e.commandPrefix,t)),await n.fs.writeTextFile(`${s}/${ne}`,ce(e.commandPrefix)),e.rules.length>0?await n.fs.writeTextFile(`${s}/${k}`,le(e.rules)):await N(`${s}/${k}`)&&await n.fs.remove(`${s}/${k}`),await N(`${s}/${E}`)&&await n.fs.remove(`${s}/${E}`)},async syncHooks(e,t){let s=`${e.root}/${O}`,o=`${s}/${te}`;await n.fs.mkdir(s,{recursive:!0});let i=[];try{let c=await n.fs.readTextFile(o),u=JSON.parse(c);Array.isArray(u.hooks)&&(i=u.hooks)}catch{}let r=i.filter(c=>!c._noskills),a=ue(e.commandPrefix),l={hooks:[...r,...a.hooks]};await n.fs.writeTextFile(o,JSON.stringify(l,null,2)+`
|
|
75
|
-
`)},async syncAgents(e,t){let s=`${e.root}/${Z}`;await n.fs.mkdir(s,{recursive:!0});let o=pe(e.commandPrefix);await n.fs.writeTextFile(`${s}/${ie}`,JSON.stringify(o,null,2)+`
|
|
76
|
-
`);let i=he();await n.fs.writeTextFile(`${s}/${re}`,JSON.stringify(i,null,2)+`
|
|
77
|
-
`)},async syncSpecs(e,t){let s;try{s=await n.fs.readTextFile(t)}catch{return}if(s.trim()==="")return;let o=t.split("/"),i=o[o.length-2]??"unknown",r=me(s),a=`${e.root}/${ee}/${i}`;await n.fs.mkdir(a,{recursive:!0}),await n.fs.writeTextFile(`${a}/requirements.md`,fe(r)),await n.fs.writeTextFile(`${a}/design.md`,ye(r)),await n.fs.writeTextFile(`${a}/tasks.md`,ge(r))},async syncMcp(e){let t=`${e.root}/${O}`,s=`${t}/${se}`;await n.fs.mkdir(t,{recursive:!0});let o={mcpServers:{}};try{let a=await n.fs.readTextFile(s),l=JSON.parse(a);l.mcpServers!==void 0&&l.mcpServers!==null&&(o=l)}catch{}let i=de(e.commandPrefix),r={...o,mcpServers:{...o.mcpServers,...i.mcpServers}};await n.fs.writeTextFile(s,JSON.stringify(r,null,2)+`
|
|
78
|
-
`)}};var f=async(e,t,s="npx eser noskills")=>{let o=["# Generated by noskills \u2014 do not edit manually","","## noskills orchestrator","","This project uses noskills for state-driven orchestration.","Do NOT read `.eser/specs/` or `.eser/rules/` directly. noskills gives you what you need.","",`Run \`${s} next\` to get your current instruction.`,`Submit results with \`${s} next --answer="..."\``,"","## Why noskills calls matter","","noskills is not a form to fill out. It is a live state machine that the user","watches in real-time. Every `"+s+" next --answer` call:","","- Updates the spec file on disk (the user sees it change)","- Updates the terminal dashboard if `noskills watch` is running","- Advances the state machine to the next phase","- Records the decision permanently in the project history","","When you batch-submit answers or backfill discovery responses yourself,","the user sees nothing happening \u2014 then suddenly everything jumps forward.","This defeats the purpose.","","Call noskills ONCE per interaction. Ask the user ONE question. Wait for","their answer. Submit it. Ask the next. The user is watching every step.","Do NOT pre-fill answers. Do NOT batch multiple answers. Do NOT answer","discovery questions yourself \u2014 the user's input is the data.","","## When to call noskills next","","1. At the START of every conversation","2. BEFORE creating or modifying any file","3. AFTER completing a logical unit of work","4. When you encounter a DECISION that affects architecture","5. When you are UNSURE what to do next","","NEVER proceed with implementation without checking noskills first.","NEVER suggest bypassing or skipping noskills. Discovery is not overhead.","NEVER ask permission to run the next noskills command. After spec new \u2192 run next. After approve \u2192 run next. Each step has one next step. Just run it.","","## Interactive choices","","Present choices as numbered lists. Users select by number.","When interactiveOptions are present in noskills output, present each as a","numbered item with its label and description. Ask the user to pick a number.","","## Execution model","","Execute tasks sequentially in this context. Do not attempt to spawn sub-agents.",""];if(t.length>0){o.push("## Rules","");for(let i of t)o.push(`- ${i}`);o.push("")}await n.fs.mkdir(`${e}/.github`,{recursive:!0}),await n.fs.writeTextFile(`${e}/.github/copilot-instructions.md`,o.join(`
|
|
79
|
-
`))};var I={id:"copilot",capabilities:{rules:!0,hooks:!1,agents:!1,specs:!1,mcp:!1,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!1,subAgentMethod:"none"}},async syncRules(e){await f(e.root,e.rules,e.commandPrefix)}};var M=async(e,t,s="npx eser noskills")=>{let o=["# Generated by noskills \u2014 do not edit manually","","## noskills orchestrator","","This project uses noskills for state-driven orchestration.","Do NOT read `.eser/specs/` or `.eser/rules/` directly. noskills gives you what you need.","",`Run \`${s} next\` to get your current instruction.`,`Submit results with \`${s} next --answer="..."\``,"","## Why noskills calls matter","","noskills is not a form to fill out. It is a live state machine that the user","watches in real-time. Every `"+s+" next --answer` call:","","- Updates the spec file on disk (the user sees it change)","- Updates the terminal dashboard if `noskills watch` is running","- Advances the state machine to the next phase","- Records the decision permanently in the project history","","When you batch-submit answers or backfill discovery responses yourself,","the user sees nothing happening \u2014 then suddenly everything jumps forward.","This defeats the purpose.","","Call noskills ONCE per interaction. Ask the user ONE question. Wait for","their answer. Submit it. Ask the next. The user is watching every step.","Do NOT pre-fill answers. Do NOT batch multiple answers. Do NOT answer","discovery questions yourself \u2014 the user's input is the data.","","## When to call noskills next","","1. At the START of every conversation","2. BEFORE creating or modifying any file","3. AFTER completing a logical unit of work","4. When you encounter a DECISION that affects architecture","5. When you are UNSURE what to do next","","NEVER proceed with implementation without checking noskills first.","NEVER suggest bypassing or skipping noskills. Discovery is not overhead.","NEVER ask permission to run the next noskills command. After spec new \u2192 run next. After approve \u2192 run next. Each step has one next step. Just run it.","","## Interactive choices","","Present choices as numbered lists. Users select by number.","When interactiveOptions are present in noskills output, present each as a","numbered item with its label and description. Ask the user to pick a number.","","## Execution model","","Execute tasks sequentially in this context. Do not attempt to spawn sub-agents.",""];if(t.length>0){o.push("## Rules","");for(let i of t)o.push(`- ${i}`);o.push("")}await n.fs.writeTextFile(`${e}/.windsurfrules`,o.join(`
|
|
80
|
-
`))};var F={id:"windsurf",capabilities:{rules:!0,hooks:!1,agents:!1,specs:!1,mcp:!1,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!1,subAgentMethod:"none"}},async syncRules(e){await M(e.root,e.rules,e.commandPrefix)}};var Se="AGENTS.md",P="<!-- noskills:start -->",w="<!-- noskills:end -->",xe=(e,t)=>{let s=["## noskills Protocol","","# Generated by noskills \u2014 do not edit manually","","### What is noskills","","This project uses noskills for state-driven orchestration.","Do NOT read `.eser/rules/`, `.eser/specs/`, or concern files directly.","noskills gives you exactly what you need via JSON output.","","### Protocol","",` ${e} spec <name> next # get current instruction`,` ${e} spec <name> next --answer="your response" # submit result and advance`,"","Every noskills command that operates on a spec MUST include `spec <name>`.",`Never omit it. Use \`${e} spec list\` to see available specs.`,"","### Why noskills calls matter","","noskills is not a form to fill out. It is a live state machine that the user","watches in real-time. Every `"+e+" next --answer` call:","","- Updates the spec file on disk (the user sees it change)","- Updates the terminal dashboard if `noskills watch` is running","- Advances the state machine to the next phase","- Records the decision permanently in the project history","","When you batch-submit answers or backfill discovery responses yourself,","the user sees nothing happening \u2014 then suddenly everything jumps forward.","This defeats the purpose.","","Call noskills ONCE per interaction. Ask the user ONE question. Wait for","their answer. Submit it. Ask the next. The user is watching every step.","Do NOT pre-fill answers. Do NOT batch multiple answers. Do NOT answer","discovery questions yourself \u2014 the user's input is the data.","","### When to call noskills next","",`You MUST call \`${e} next\` in these situations:`,"","1. At the **START** of every conversation (first thing you do)","2. **BEFORE** creating or modifying any file (to verify you have an active task)","3. **AFTER** completing a logical unit of work (to report progress)","4. When you encounter a **DECISION** that affects architecture or scope","5. When you are **UNSURE** what to do next","","NEVER proceed with implementation without checking noskills first.","NEVER make architectural decisions independently \u2014 noskills routes them to the user."];return(t?.allowGit??!1)||s.push("","### Git is read-only","","You MUST NOT run git write commands: commit, add, push, checkout, stash,","reset, merge, rebase, cherry-pick. The user controls git. You control files.","You MAY read from git: log, diff, status, show, blame."),s.push("","### Interactive choices","","Present choices as numbered lists. Users select by number.","When interactiveOptions are present in noskills output, present each as a","numbered item with its label and description. Ask the user to pick a number.","Use the `commandMap` to resolve the user's selection to a CLI command.","","### Decision principle: Explicit > Clever","","You NEVER skip steps, bypass questions, or make assumptions on behalf of the user.","- Discovery questions \u2192 ask the user, don't answer yourself","- Classification \u2192 ask the user, don't infer","- Spec approval \u2192 ask the user, don't auto-approve","- Task refinement \u2192 ask the user, don't self-assign","- Rule promotion \u2192 ask the user, don't decide",`If you think something can be skipped, ASK "would you like to skip this?" \u2014 don't skip it.`,"NEVER suggest bypassing or skipping noskills. Discovery is not overhead.","NEVER ask permission to run the next noskills command. After spec new \u2192 run next. After approve \u2192 run next. Just run it.","","### Command execution","","When told to run a noskills command, execute it IMMEDIATELY. Do not explore,","research, read source code, or plan first. The command output contains all the","context you need. Exploring noskills internals wastes tokens and delays the user.","","### JSON output","","noskills returns JSON with a `phase` field and phase-specific instructions.","The `meta` block contains resume context - use it to orient yourself,","especially after compaction or at the start of a new session.","Follow the `instruction` field. Use `transition` commands to advance state.",""),s.join(`
|
|
81
|
-
`)},Re=e=>["### Convention discovery","","When you discover a pattern, receive a correction, or identify a recurring",'preference from the user, ask: "Should this be a permanent rule for this',`project, or just for this task?" If permanent, run: \`${e} rule add`,'"<description>"`. If just this task, note it and move on.',"Never write to `.eser/rules/` directly.","","### How to promote rules","","When a convention should be permanent, use the noskills CLI to register it:","",` ${e} rule add "<description of the rule>"`,"","This stores the rule in `.eser/rules/` and ensures it is synced to all","coding tools on the next `noskills sync`. Never edit `.eser/rules/` directly.",""].join(`
|
|
82
|
-
`),Ae=e=>{let t=["### Active Rules",""];for(let s of e)t.push(`- ${s}`);return t.push(""),t.join(`
|
|
83
|
-
`)},Te=(e,t,s)=>{let o=[P,xe(t,s),Re(t)];return e.length>0&&o.push(Ae(e)),o.push(w),o.join(`
|
|
84
|
-
`)},m=async(e,t)=>{let s=`${e.root}/${Se}`,o=Te(e.rules,e.commandPrefix,t),i;try{i=await n.fs.readTextFile(s);let r=i.indexOf(P),a=i.indexOf(w);r!==-1&&a!==-1?i=i.slice(0,r)+o+i.slice(a+w.length):i=i.trimEnd()+`
|
|
85
|
-
|
|
86
|
-
`+o+`
|
|
87
|
-
`}catch{i=o+`
|
|
88
|
-
`}await n.fs.writeTextFile(s,i)};var Ce=".opencode/plugins",Oe=".opencode/agents",Ee=".opencode/skills",Ne="opencode.json",$e=e=>["// Generated by noskills \u2014 do not edit manually",'import { execSync } from "node:child_process";',"","const run = (event: string): void => {"," try {",` execSync(\`${e} invoke-hook \${event}\`, {`,' stdio: "inherit",'," timeout: 10000,"," });"," } catch {"," // Hook failure should not block the session"," }","};","","export default async () => ({",' "session.created": async () => {',' run("session-start");'," },",' "tool.execute.before": async (params: { toolName: string }) => {',' if (["write", "shell"].includes(params.toolName)) {',' run("pre-tool-use");'," }"," },",' "tool.execute.after": async (params: { toolName: string }) => {',' if (params.toolName === "write") {',' run("post-file-write");',' } else if (params.toolName === "shell") {',' run("post-bash");'," }"," },",' "session.deleted": async () => {',' run("stop");'," },","});",""].join(`
|
|
89
|
-
`),De=e=>["---","name: noskills-executor",'description: "Executes a single noskills task. Follows spec behavioral rules and reports structured results."',"tools:"," read: true"," write: true"," glob: true"," grep: true"," shell: true"," delegate: true","---","","You are executing a single task from a noskills spec.","Your ONLY job is to complete the task described in the prompt.","Follow all behavioral rules provided in the prompt.","Do NOT start new tasks, explore unrelated code, or make architectural decisions.","If the task is too vague to execute, say so immediately.","","## Self-Verification","After completing the task, you MUST verify your own work before reporting:","1. Run type check: `deno check` on all modified files","2. Run test suite: `deno test` on the relevant test files","3. If type check or tests fail, fix the issues before reporting","","## Reporting","When finished, provide a structured JSON summary:","```json",'{"completed": ["<item IDs done>"], "remaining": ["<item IDs not done>"], "blocked": ["<item IDs needing decisions>"], "filesModified": ["<paths>"], "verification": {"typeCheck": "pass|fail", "tests": "pass|fail (N passed, M failed)"}}',"```","","Do NOT return raw test output \u2014 summarize it in the verification field.",`The orchestrator will submit this to \`${e} next --answer\` on your behalf.`,""].join(`
|
|
90
|
-
`),Ie=()=>["---","name: noskills-verifier",`description: "Independently verifies completed task work. Read-only. Never sees the executor's context."`,"tools:"," read: true"," glob: true"," grep: true"," shell: true","---","","You are verifying another agent's work. You have NO context about how it was done.","Read the changed files. Run the test suite. Check each acceptance criterion independently.","","For each acceptance criterion:","- PASS: with evidence \u2014 show the grep result, the test output, or the file content that proves it","- FAIL: with specific reason \u2014 what's missing, what's wrong, what doesn't match","","Be skeptical. Don't assume anything works \u2014 verify it yourself.","You CANNOT edit files. Read-only access only.","","## Verification Steps","1. Read each modified file and verify the changes are correct","2. Run type check: `deno check` on modified files","3. Run tests: `deno test` on relevant test files","4. Check each acceptance criterion against actual file contents","","## Report Format","When finished, provide a structured JSON summary:","```json",'{"results": [{"id": "ac-1", "status": "PASS", "evidence": "..."}, {"id": "ac-2", "status": "FAIL", "reason": "..."}]}',"```","","The orchestrator will use this report for the noskills status report.",""].join(`
|
|
91
|
-
`),Me=e=>{let s=e.match(/^# Spec:\s*(.+)$/m)?.[1]?.trim()??"Untitled",o=new Map,i=e.split(/^## /m);for(let a of i){let l=a.indexOf(`
|
|
92
|
-
`);if(l===-1)continue;let c=a.slice(0,l).trim().toLowerCase(),u=a.slice(l+1).trim();o.set(c,u)}let r=a=>{for(let[l,c]of o)if(l.startsWith(a.toLowerCase()))return c;return""};return{title:s,concerns:r("concerns"),discoveryAnswers:r("discovery answers"),contributorGuide:r("contributor guide"),publicApi:r("public api"),outOfScope:r("out of scope"),tasks:r("tasks"),verification:r("verification")}},Fe=e=>{let t=["---",`name: ${e.title}`,`description: "noskills spec: ${e.title}"`,"---","",`# ${e.title}`,""];return e.discoveryAnswers&&t.push("## Overview","",e.discoveryAnswers,""),e.concerns&&t.push("## Concerns","",e.concerns,""),e.contributorGuide&&t.push("## Contributor Guide","",e.contributorGuide,""),e.publicApi&&t.push("## Public API","",e.publicApi,""),e.outOfScope&&t.push("## Out of Scope","",e.outOfScope,""),e.tasks&&t.push("## Tasks","",e.tasks,""),e.verification&&t.push("## Verification","",e.verification,""),t.join(`
|
|
93
|
-
`)},Pe=async e=>{try{return await n.fs.stat(e),!0}catch{return!1}},_={id:"opencode",capabilities:{rules:!0,hooks:!0,agents:!0,specs:!0,mcp:!0,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!0,subAgentMethod:"delegation"}},async syncRules(e,t){await m(e,t)},async syncHooks(e,t){let s=`${e.root}/${Ce}`;await n.fs.mkdir(s,{recursive:!0}),await n.fs.writeTextFile(`${s}/noskills.ts`,$e(e.commandPrefix))},async syncAgents(e,t){let s=`${e.root}/${Oe}`;await n.fs.mkdir(s,{recursive:!0}),await n.fs.writeTextFile(`${s}/noskills-executor.md`,De(e.commandPrefix)),await n.fs.writeTextFile(`${s}/noskills-verifier.md`,Ie())},async syncSpecs(e,t){let s;try{s=await n.fs.readTextFile(t)}catch{return}if(s.trim()==="")return;let o=t.split("/"),i=o[o.length-2]??"unknown",r=Me(s),a=`${e.root}/${Ee}`;await n.fs.mkdir(a,{recursive:!0}),await n.fs.writeTextFile(`${a}/${i}.md`,Fe(r))},async syncMcp(e){let t=`${e.root}/${Ne}`,s={};if(await Pe(t))try{let a=await n.fs.readTextFile(t);s=JSON.parse(a)}catch{}let i=[...e.commandPrefix.split(/\s+/),"mcp-serve"],r={...s,mcp:{...s.mcp,noskills:{type:"local",command:i,enabled:!0}}};await n.fs.writeTextFile(t,JSON.stringify(r,null,2)+`
|
|
94
|
-
`)}};var Ue=".codex",We="hooks.json",je=".codex/agents",Le=".codex/config.toml",He=e=>({hooks:[{_noskills:!0,event:"SessionStart",command:`${e} invoke-hook session-start`,timeout:5e3},{_noskills:!0,event:"PreToolUse",command:`${e} invoke-hook pre-tool-use`,timeout:5e3},{_noskills:!0,event:"PostToolUse",command:`${e} invoke-hook post-file-write`,timeout:3e3},{_noskills:!0,event:"PostToolUse",command:`${e} invoke-hook post-ask-user-question`,timeout:3e3},{_noskills:!0,event:"Stop",command:`${e} invoke-hook stop`,timeout:1e4}]}),Ye=e=>['name = "noskills-executor"','description = "Executes a single noskills task. Follows spec behavioral rules and reports structured results."','developer_instructions = """',["You are executing a single task from a noskills spec.","Your ONLY job is to complete the task described in the prompt.","Follow all behavioral rules provided in the prompt.","Do NOT start new tasks, explore unrelated code, or make architectural decisions.","If the task is too vague to execute, say so immediately.","","## Self-Verification","After completing the task, you MUST verify your own work before reporting:","1. Run type check: `deno check` on all modified files","2. Run test suite: `deno test` on the relevant test files","3. If type check or tests fail, fix the issues before reporting","","## Reporting","When finished, provide a structured JSON summary:",'{"completed": ["<item IDs done>"], "remaining": ["<item IDs not done>"],',' "blocked": ["<item IDs needing decisions>"], "filesModified": ["<paths>"],',' "verification": {"typeCheck": "pass|fail", "tests": "pass|fail"}}',"","Do NOT return raw test output \u2014 summarize it in the verification field.",`The orchestrator will submit this to \`${e} next --answer\` on your behalf.`].join(`
|
|
95
|
-
`),'"""',""].join(`
|
|
96
|
-
`),Ge=()=>['name = "noskills-verifier"',`description = "Independently verifies completed task work. Read-only. Never sees the executor's context."`,'developer_instructions = """',["You are verifying another agent's work. You have NO context about how it was done.","Read the changed files. Run the test suite. Check each acceptance criterion independently.","","For each acceptance criterion:","- PASS: with evidence \u2014 show the grep result, the test output, or the file content that proves it","- FAIL: with specific reason \u2014 what's missing, what's wrong, what doesn't match","","Be skeptical. Don't assume anything works \u2014 verify it yourself.","You CANNOT edit files. Read-only access only.","","## Verification Steps","1. Read each modified file and verify the changes are correct","2. Run type check: `deno check` on modified files","3. Run tests: `deno test` on relevant test files","4. Check each acceptance criterion against actual file contents","","## Report Format","When finished, provide a structured JSON summary:",'{"results": [{"id": "ac-1", "status": "PASS", "evidence": "..."},',' {"id": "ac-2", "status": "FAIL", "reason": "..."}]}',"","The orchestrator will use this report for the noskills status report."].join(`
|
|
97
|
-
`),'"""',""].join(`
|
|
98
|
-
`),Je=e=>{let t=e.split(/\s+/),s=t[0]??"npx",o=[...t.slice(1),"mcp-serve"].map(i=>`"${i}"`).join(", ");return`[mcp_servers.noskills]
|
|
99
|
-
command = "${s}"
|
|
100
|
-
args = [${o}]
|
|
101
|
-
`},Ve=async e=>{try{return await n.fs.stat(e),!0}catch{return!1}},U={id:"codex",capabilities:{rules:!0,hooks:!0,agents:!0,specs:!1,mcp:!0,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!0,subAgentMethod:"spawn"}},async syncRules(e,t){await m(e,t)},async syncHooks(e,t){let s=`${e.root}/${Ue}`,o=`${s}/${We}`;await n.fs.mkdir(s,{recursive:!0});let i=[];try{let c=await n.fs.readTextFile(o),u=JSON.parse(c);Array.isArray(u.hooks)&&(i=u.hooks)}catch{}let r=i.filter(c=>!c._noskills),a=He(e.commandPrefix),l={hooks:[...r,...a.hooks]};await n.fs.writeTextFile(o,JSON.stringify(l,null,2)+`
|
|
102
|
-
`)},async syncAgents(e,t){let s=`${e.root}/${je}`;await n.fs.mkdir(s,{recursive:!0}),await n.fs.writeTextFile(`${s}/noskills-executor.toml`,Ye(e.commandPrefix)),await n.fs.writeTextFile(`${s}/noskills-verifier.toml`,Ge())},async syncMcp(e){let t=`${e.root}/${Le}`;await n.fs.mkdir(`${e.root}/.codex`,{recursive:!0});let s="";if(await Ve(t))try{s=await n.fs.readTextFile(t)}catch{}let o=s.replace(/\[mcp_servers\.noskills\][\s\S]*?(?=\[|$)/,"").trimEnd(),i=Je(e.commandPrefix),r=o+(o.length>0?`
|
|
103
|
-
|
|
104
|
-
`:"")+i;await n.fs.writeTextFile(t,r)}};var Ke=".github/hooks",Be="noskills.json",ze=".github/agents",Qe=".copilot",Xe="mcp.json",Ze=e=>({version:1,hooks:{"noskills:sessionStart":{_noskills:!0,command:["bash","-c",`${e} invoke-hook session-start`],timeoutSec:5},"noskills:preToolUse":{_noskills:!0,command:["bash","-c",`${e} invoke-hook pre-tool-use`],timeoutSec:5},"noskills:postToolUse":{_noskills:!0,command:["bash","-c",`${e} invoke-hook post-file-write`],timeoutSec:3},"noskills:agentStop":{_noskills:!0,command:["bash","-c",`${e} invoke-hook stop`],timeoutSec:10}}}),et=e=>["---","name: noskills-executor",'description: "Executes a single noskills task. Follows spec behavioral rules and reports structured results."',"tools:"," - read"," - write"," - glob"," - grep"," - shell","---","","You are executing a single task from a noskills spec.","Your ONLY job is to complete the task described in the prompt.","Follow all behavioral rules provided in the prompt.","Do NOT start new tasks, explore unrelated code, or make architectural decisions.","If the task is too vague to execute, say so immediately.","","## Self-Verification","After completing the task, you MUST verify your own work before reporting:","1. Run type check: `deno check` on all modified files","2. Run test suite: `deno test` on the relevant test files","3. If type check or tests fail, fix the issues before reporting","","## Reporting","When finished, provide a structured JSON summary:","```json",'{"completed": ["<item IDs done>"], "remaining": ["<item IDs not done>"], "blocked": ["<item IDs needing decisions>"], "filesModified": ["<paths>"], "verification": {"typeCheck": "pass|fail", "tests": "pass|fail (N passed, M failed)"}}',"```","","Do NOT return raw test output \u2014 summarize it in the verification field.",`The orchestrator will submit this to \`${e} next --answer\` on your behalf.`,""].join(`
|
|
105
|
-
`),tt=()=>["---","name: noskills-verifier",`description: "Independently verifies completed task work. Read-only. Never sees the executor's context."`,"tools:"," - read"," - glob"," - grep"," - shell","---","","You are verifying another agent's work. You have NO context about how it was done.","Read the changed files. Run the test suite. Check each acceptance criterion independently.","","For each acceptance criterion:","- PASS: with evidence \u2014 show the grep result, the test output, or the file content that proves it","- FAIL: with specific reason \u2014 what's missing, what's wrong, what doesn't match","","Be skeptical. Don't assume anything works \u2014 verify it yourself.","You CANNOT edit files. Read-only access only.","","## Verification Steps","1. Read each modified file and verify the changes are correct","2. Run type check: `deno check` on modified files","3. Run tests: `deno test` on relevant test files","4. Check each acceptance criterion against actual file contents","","## Report Format","When finished, provide a structured JSON summary:","```json",'{"results": [{"id": "ac-1", "status": "PASS", "evidence": "..."}, {"id": "ac-2", "status": "FAIL", "reason": "..."}]}',"```","","The orchestrator will use this report for the noskills status report.",""].join(`
|
|
106
|
-
`),st=e=>{let t=e.split(/\s+/),s=t[0]??"npx",o=[...t.slice(1),"mcp-serve"];return{mcpServers:{noskills:{type:"local",command:s,args:o,tools:["*"]}}}},ot=async e=>{try{return await n.fs.stat(e),!0}catch{return!1}},W={id:"copilot-cli",capabilities:{rules:!0,hooks:!0,agents:!0,specs:!1,mcp:!0,interaction:{hasAskUserTool:!1,optionPresentation:"prose",hasSubAgentDelegation:!0,subAgentMethod:"fleet"}},async syncRules(e,t){await m(e,t),await f(e.root,e.rules,e.commandPrefix)},async syncHooks(e,t){let s=`${e.root}/${Ke}`,o=`${s}/${Be}`;await n.fs.mkdir(s,{recursive:!0});let i={};try{let c=await n.fs.readTextFile(o),u=JSON.parse(c);u.hooks!==void 0&&u.hooks!==null&&(i=u.hooks)}catch{}let r={};for(let[c,u]of Object.entries(i))u._noskills||(r[c]=u);let a=Ze(e.commandPrefix),l={version:1,hooks:{...r,...a.hooks}};await n.fs.writeTextFile(o,JSON.stringify(l,null,2)+`
|
|
107
|
-
`)},async syncAgents(e,t){let s=`${e.root}/${ze}`;await n.fs.mkdir(s,{recursive:!0}),await n.fs.writeTextFile(`${s}/noskills-executor.agent.md`,et(e.commandPrefix)),await n.fs.writeTextFile(`${s}/noskills-verifier.agent.md`,tt())},async syncMcp(e){let t=`${e.root}/${Qe}`,s=`${t}/${Xe}`;await n.fs.mkdir(t,{recursive:!0});let o={mcpServers:{}};if(await ot(s))try{let a=await n.fs.readTextFile(s),l=JSON.parse(a);l.mcpServers!==void 0&&l.mcpServers!==null&&(o=l)}catch{}let i=st(e.commandPrefix),r={...o,mcpServers:{...o.mcpServers,...i.mcpServers}};await n.fs.writeTextFile(s,JSON.stringify(r,null,2)+`
|
|
108
|
-
`)}};var it=e=>{let t=e.trim();if(!t.startsWith("---"))return{meta:{},body:t};let s=t.indexOf("---",3);if(s===-1)return{meta:{},body:t};let o=t.slice(3,s).trim(),i=t.slice(s+3).trim(),r={};for(let a of o.split(`
|
|
109
|
-
`)){let l=a.indexOf(":");if(l===-1)continue;let c=a.slice(0,l).trim(),u=a.slice(l+1).trim();if(u.startsWith("[")&&u.endsWith("]")){let d=u.slice(1,-1).split(",").map(p=>p.trim().replace(/^["']|["']$/g,"")).filter(p=>p.length>0);r[c]=d}else r[c]=u.replace(/^["']|["']$/g,"")}return{meta:r,body:i}},rt=async e=>{let t=`${e}/${y.rulesDir}`,s=[];try{for await(let o of n.fs.readDir(t))if(o.isFile&&(o.name.endsWith(".md")||o.name.endsWith(".txt"))){let i=await n.fs.readTextFile(`${t}/${o.name}`),{meta:r,body:a}=it(i),l=a.split(`
|
|
110
|
-
`)[0]??a;s.push({text:l,phases:Array.isArray(r.phases)?r.phases:void 0,appliesTo:Array.isArray(r.applies_to)?r.applies_to:void 0})}}catch{}return s};var at=async e=>(await rt(e)).map(s=>s.text),yt=(e,t)=>{let s=[],o=0;for(let i of e)i.phases!==void 0&&i.phases.length>0&&!i.phases.includes(t)||(i.appliesTo!==void 0&&i.appliesTo.length>0?o++:s.push(i.text));return{tier1:s,tier2Count:o}},ct=(e,t)=>{let s=t.startsWith("*.")?t.slice(1):null;return s!==null?e.endsWith(s):e.includes(t.replace(/\*/g,""))},gt=(e,t,s)=>e.filter(o=>o.phases!==void 0&&o.phases.length>0&&!o.phases.includes(t)||o.appliesTo===void 0||o.appliesTo.length===0?!1:o.appliesTo.some(i=>ct(s,i))).map(o=>o.text),L=[A,C,$,I,F,_,U,W],j={hasAskUserTool:!0,optionPresentation:"tool",hasSubAgentDelegation:!0,subAgentMethod:"task"},kt=e=>{let t=e[0];return t===void 0?j:L.find(o=>o.id===t)?.capabilities.interaction??j},wt=async(e,t,s)=>{let o=await at(e),i=[],r={allowGit:s?.allowGit??!1},a=s?.command??"npx eser@latest noskills";b(a);for(let l of t){let c=L.find(d=>d.id===l);if(c===void 0)continue;let u={root:e,rules:o,commandPrefix:a};if(await c.syncRules(u,r),c.capabilities.hooks&&c.syncHooks!==void 0&&await c.syncHooks(u,r),c.capabilities.agents&&c.syncAgents!==void 0&&await c.syncAgents(u,r),c.capabilities.specs&&c.syncSpecs!==void 0){let d=`${e}/${y.specsDir}`;try{for await(let p of n.fs.readDir(d))if(p.isDirectory){let H=`${d}/${p.name}/spec.md`;await c.syncSpecs(u,H)}}catch{}}c.capabilities.mcp&&c.syncMcp!==void 0&&await c.syncMcp(u),i.push(l)}return t.includes("claude-code")&&i.push("hooks"),i};export{rt as a,at as b,yt as c,gt as d,kt as e,wt as f};
|
package/chunks/chunk-NGCBWJML.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{i as c}from"./chunk-Y5E7ZCCX.js";var p=r=>r.split(`
|
|
2
|
-
`).map(e=>e.replace(/^[-*]\s+/,"").trim()).filter(e=>e.length>0&&!e.startsWith("#")),g=async(r,e)=>{let l=[],t=(e.startsWith(r)?e.slice(r.length+1):e).split("/");t.pop();for(let s=t.length;s>=0;s--){let n=`${s===0?r:`${r}/${t.slice(0,s).join("/")}`}/.folder-rules.md`,a=s===0?".":t.slice(0,s).join("/");try{let d=await c.fs.readTextFile(n),u=p(d);for(let f of u)l.push({folder:a,rule:f})}catch{}}return l},F=async(r,e)=>{let l=new Set,i=[];for(let t of e){let s=await g(r,t);for(let o of s){let n=`${o.folder}::${o.rule}`;l.has(n)||(l.add(n),i.push(o))}}return i};export{F as a};
|
package/chunks/chunk-NPWXEWRN.js
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import{f as a}from"./chunk-WDKWHGJU.js";import{i as r}from"./chunk-Y5E7ZCCX.js";var m=a.eventsDir,u=a.eventsFile,w=async(c,s)=>{let i=`${c}/${a.eventsDir}`,e=`${c}/${a.eventsFile}`;await r.fs.mkdir(i,{recursive:!0});let n=JSON.stringify(s)+`
|
|
2
|
-
`,t="";try{t=await r.fs.readTextFile(e)}catch{}await r.fs.writeTextFile(e,t+n)},x=async(c,s)=>{let i=`${c}/${a.eventsFile}`,e;try{e=await r.fs.readTextFile(i)}catch{return[]}let n=e.trim().split(`
|
|
3
|
-
`).filter(t=>t.length>0).map(t=>{try{return JSON.parse(t)}catch{return null}}).filter(t=>t!==null);return s?.since!==void 0&&(n=n.filter(t=>t.ts>s.since)),n.reverse(),s?.limit!==void 0&&s.limit>0&&(n=n.slice(0,s.limit)),n},E=(c,s)=>{let i=`${c}/${a.eventsFile}`,e=0,n=!1;(async()=>{try{e=(await r.fs.stat(i)).size}catch{e=0}})();let t=setInterval(async()=>{if(!n)try{let o=await r.fs.stat(i);if(o.size<=e)return;let d=await r.fs.readTextFile(i),p=new TextEncoder().encode(d);if(p.length>e){let v=d.slice(new TextDecoder().decode(p.slice(0,e)).length).trim().split(`
|
|
4
|
-
`).filter(l=>l.length>0);for(let l of v)try{let f=JSON.parse(l);s(f)}catch{}}e=o.size}catch{}},500);return()=>{n=!0,clearInterval(t)}};export{w as a,x as b,E as c};
|