@yukino.js/yukino 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (87) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +320 -0
  3. package/dist/acp-IVY5HZR4.js +14 -0
  4. package/dist/agent-QANDY7FO.js +4 -0
  5. package/dist/anthropic-6YLT4JZR.js +4 -0
  6. package/dist/bwrap-MLSZLWHD.js +4 -0
  7. package/dist/chunk-2LHY3FND.js +67 -0
  8. package/dist/chunk-3KKA6537.js +4 -0
  9. package/dist/chunk-3QL446GD.js +4 -0
  10. package/dist/chunk-4GE22WHI.js +4 -0
  11. package/dist/chunk-5VOCXSSX.js +5 -0
  12. package/dist/chunk-77W2UPS2.js +4 -0
  13. package/dist/chunk-7MKA3SHV.js +4 -0
  14. package/dist/chunk-AGSYLE4E.js +16 -0
  15. package/dist/chunk-CU3IISCC.js +4 -0
  16. package/dist/chunk-GYBJR2RB.js +65 -0
  17. package/dist/chunk-HLE7243Q.js +4 -0
  18. package/dist/chunk-HMZQYFYG.js +4 -0
  19. package/dist/chunk-JFKC4VCA.js +4 -0
  20. package/dist/chunk-K4BYVVW7.js +5 -0
  21. package/dist/chunk-KCMBAHWU.js +4 -0
  22. package/dist/chunk-L2BWSPCF.js +10 -0
  23. package/dist/chunk-MDPSQ6L7.js +44 -0
  24. package/dist/chunk-OFC2GD5K.js +4 -0
  25. package/dist/chunk-RAS3ORX3.js +164 -0
  26. package/dist/chunk-RCXKUD3Y.js +4 -0
  27. package/dist/chunk-SAJCBGHL.js +4 -0
  28. package/dist/chunk-SOO5OXX2.js +237 -0
  29. package/dist/chunk-T4O4GQVL.js +607 -0
  30. package/dist/chunk-UPNNYP7M.js +60 -0
  31. package/dist/chunk-VCIRD267.js +4 -0
  32. package/dist/chunk-VU3JWAJR.js +4 -0
  33. package/dist/chunk-VWUGGYUP.js +6 -0
  34. package/dist/chunk-XO7ITAWR.js +4 -0
  35. package/dist/devtools-YWVUN4HX.js +7 -0
  36. package/dist/esm-57CJEGGK.js +4 -0
  37. package/dist/esm-6L5BJ5GT.js +4 -0
  38. package/dist/esm-DIYJ5HX6.js +4 -0
  39. package/dist/esm-HW2JMFYC.js +4 -0
  40. package/dist/esm-RPR2GBJ2.js +4 -0
  41. package/dist/esm-YKAO4ES6.js +4 -0
  42. package/dist/esm-ZTIYTMTS.js +229 -0
  43. package/dist/getMachineId-bsd-E27XJQLX.js +4 -0
  44. package/dist/getMachineId-darwin-35UPAIXP.js +5 -0
  45. package/dist/getMachineId-linux-MKXIYT6A.js +4 -0
  46. package/dist/getMachineId-unsupported-ZXVGGFX2.js +4 -0
  47. package/dist/getMachineId-win-RNVIYJG5.js +4 -0
  48. package/dist/lib/agent-6FZX4P2Y.js +16 -0
  49. package/dist/lib/anthropic-IP23YZ3P.js +21 -0
  50. package/dist/lib/bwrap-2OL7VPSO.js +7 -0
  51. package/dist/lib/chunk-2VF3XTGH.js +3382 -0
  52. package/dist/lib/chunk-5DVQ64YL.js +619 -0
  53. package/dist/lib/chunk-5TGXH7BX.js +624 -0
  54. package/dist/lib/chunk-6OMQD7MK.js +591 -0
  55. package/dist/lib/chunk-AZRC67RW.js +512 -0
  56. package/dist/lib/chunk-F2YJG72O.js +150 -0
  57. package/dist/lib/chunk-FFM2LB4C.js +132 -0
  58. package/dist/lib/chunk-FLKB4BK7.js +50 -0
  59. package/dist/lib/chunk-I34MAQRE.js +255 -0
  60. package/dist/lib/chunk-KA6POJKI.js +889 -0
  61. package/dist/lib/chunk-MLKGABMK.js +9 -0
  62. package/dist/lib/chunk-O7ELJUEK.js +262 -0
  63. package/dist/lib/chunk-QYBQT2DM.js +655 -0
  64. package/dist/lib/chunk-YIWNQ7OA.js +47 -0
  65. package/dist/lib/index.d.ts +8581 -0
  66. package/dist/lib/index.js +15905 -0
  67. package/dist/lib/openai-EMJ6U4FW.js +15 -0
  68. package/dist/lib/permissions-KZ5ACZAX.js +19 -0
  69. package/dist/lib/providers-2CGZPBFI.js +9 -0
  70. package/dist/lib/sandbox-runtime-CCQ3X3SM.js +9 -0
  71. package/dist/lib/seatbelt-WO7YWKLR.js +7 -0
  72. package/dist/lib/tool-filter-CKHZUUBQ.js +21 -0
  73. package/dist/main.js +332 -0
  74. package/dist/node-634LOHDX.js +15 -0
  75. package/dist/openai-YXYO5OW6.js +34 -0
  76. package/dist/permissions-VCDMNX3L.js +4 -0
  77. package/dist/providers-HNMBGGW6.js +4 -0
  78. package/dist/sandbox-runtime-ELKAYRIL.js +4 -0
  79. package/dist/seatbelt-JOCANLYS.js +4 -0
  80. package/dist/server-ZHQILOBP.js +4 -0
  81. package/dist/src-43CPCEK2.js +12 -0
  82. package/dist/src-JBRNH4FA.js +4 -0
  83. package/dist/src-R4BSSIJJ.js +4 -0
  84. package/dist/src-X6JWWHHT.js +4 -0
  85. package/dist/tool-filter-BQZDV3TF.js +4 -0
  86. package/dist/turndown.es-NQ3KDXM7.js +83 -0
  87. package/package.json +146 -0
@@ -0,0 +1,60 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire as __yukinoCreateRequire } from "node:module";
3
+ const require = __yukinoCreateRequire(import.meta.url);
4
+ import{a as Q,c as U,e as ss}from"./chunk-7MKA3SHV.js";var rt=U(($a,Hr)=>{"use strict";var Ue=e=>e&&typeof e.message=="string",tt=e=>{if(!e)return;let t=e.cause;if(typeof t=="function"){let r=e.cause();return Ue(r)?r:void 0}else return Ue(t)?t:void 0},$r=(e,t)=>{if(!Ue(e))return"";let r=e.stack||"";if(t.has(e))return r+`
5
+ causes have become circular...`;let o=tt(e);return o?(t.add(e),r+`
6
+ caused by: `+$r(o,t)):r},ps=e=>$r(e,new Set),Wr=(e,t,r)=>{if(!Ue(e))return"";let o=r?"":e.message||"";if(t.has(e))return o+": ...";let s=tt(e);if(s){t.add(e);let l=typeof e.cause=="function";return o+(l?"":": ")+Wr(s,t,l)}else return o},gs=e=>Wr(e,new Set);Hr.exports={isErrorLike:Ue,getErrorCause:tt,stackWithCauses:ps,messageWithCauses:gs}});var it=U((Wa,Kr)=>{"use strict";var ms=Symbol("circular-ref-tag"),ln=Symbol("pino-raw-err-ref"),zr=Object.create({},{type:{enumerable:!0,writable:!0,value:void 0},message:{enumerable:!0,writable:!0,value:void 0},stack:{enumerable:!0,writable:!0,value:void 0},aggregateErrors:{enumerable:!0,writable:!0,value:void 0},raw:{enumerable:!1,get:function(){return this[ln]},set:function(e){this[ln]=e}}});Object.defineProperty(zr,ln,{writable:!0,value:{}});Kr.exports={pinoErrProto:zr,pinoErrorSymbols:{seen:ms,rawSymbol:ln}}});var Vr=U((Ha,Yr)=>{"use strict";Yr.exports=st;var{messageWithCauses:ys,stackWithCauses:bs,isErrorLike:Ur}=rt(),{pinoErrProto:ws,pinoErrorSymbols:Ss}=it(),{seen:ot}=Ss,{toString:As}=Object.prototype;function st(e){if(!Ur(e))return e;e[ot]=void 0;let t=Object.create(ws);t.type=As.call(e.constructor)==="[object Function]"?e.constructor.name:e.name,t.message=ys(e),t.stack=bs(e),Array.isArray(e.errors)&&(t.aggregateErrors=e.errors.map(r=>st(r)));for(let r in e)if(t[r]===void 0){let o=e[r];Ur(o)?r!=="cause"&&!Object.prototype.hasOwnProperty.call(o,ot)&&(t[r]=st(o)):t[r]=o}return delete e[ot],t.raw=e,t}});var Jr=U((za,Gr)=>{"use strict";Gr.exports=cn;var{isErrorLike:lt}=rt(),{pinoErrProto:_s,pinoErrorSymbols:Es}=it(),{seen:un}=Es,{toString:xs}=Object.prototype;function cn(e){if(!lt(e))return e;e[un]=void 0;let t=Object.create(_s);t.type=xs.call(e.constructor)==="[object Function]"?e.constructor.name:e.name,t.message=e.message,t.stack=e.stack,Array.isArray(e.errors)&&(t.aggregateErrors=e.errors.map(r=>cn(r))),lt(e.cause)&&!Object.prototype.hasOwnProperty.call(e.cause,un)&&(t.cause=cn(e.cause));for(let r in e)if(t[r]===void 0){let o=e[r];lt(o)?Object.prototype.hasOwnProperty.call(o,un)||(t[r]=cn(o)):t[r]=o}return delete e[un],t.raw=e,t}});var ei=U((Ka,Zr)=>{"use strict";Zr.exports={mapHttpRequest:Os,reqSerializer:Qr};var ut=Symbol("pino-raw-req-ref"),Xr=Object.create({},{id:{enumerable:!0,writable:!0,value:""},method:{enumerable:!0,writable:!0,value:""},url:{enumerable:!0,writable:!0,value:""},query:{enumerable:!0,writable:!0,value:""},params:{enumerable:!0,writable:!0,value:""},headers:{enumerable:!0,writable:!0,value:{}},remoteAddress:{enumerable:!0,writable:!0,value:""},remotePort:{enumerable:!0,writable:!0,value:""},raw:{enumerable:!1,get:function(){return this[ut]},set:function(e){this[ut]=e}}});Object.defineProperty(Xr,ut,{writable:!0,value:{}});function Qr(e){let t=e.info||e.socket,r=Object.create(Xr);if(r.id=typeof e.id=="function"?e.id():e.id||(e.info?e.info.id:void 0),r.method=e.method,e.originalUrl)r.url=e.originalUrl;else{let o=e.path;r.url=typeof o=="string"?o:e.url?e.url.path||e.url:void 0}return e.query&&(r.query=e.query),e.params&&(r.params=e.params),r.headers=e.headers,r.remoteAddress=t&&t.remoteAddress,r.remotePort=t&&t.remotePort,r.raw=e.raw||e,r}function Os(e){return{req:Qr(e)}}});var ii=U((Ua,ri)=>{"use strict";ri.exports={mapHttpResponse:Cs,resSerializer:ti};var ct=Symbol("pino-raw-res-ref"),ni=Object.create({},{statusCode:{enumerable:!0,writable:!0,value:0},headers:{enumerable:!0,writable:!0,value:""},raw:{enumerable:!1,get:function(){return this[ct]},set:function(e){this[ct]=e}}});Object.defineProperty(ni,ct,{writable:!0,value:{}});function ti(e){let t=Object.create(ni);return t.statusCode=e.headersSent?e.statusCode:null,t.headers=e.getHeaders?e.getHeaders():e._headers,t.raw=e,t}function Cs(e){return{res:ti(e)}}});var at=U((Ya,oi)=>{"use strict";var ft=Vr(),Ts=Jr(),fn=ei(),an=ii();oi.exports={err:ft,errWithCause:Ts,mapHttpRequest:fn.mapHttpRequest,mapHttpResponse:an.mapHttpResponse,req:fn.reqSerializer,res:an.resSerializer,wrapErrorSerializer:function(t){return t===ft?t:function(o){return t(ft(o))}},wrapRequestSerializer:function(t){return t===fn.reqSerializer?t:function(o){return t(fn.reqSerializer(o))}},wrapResponseSerializer:function(t){return t===an.resSerializer?t:function(o){return t(an.resSerializer(o))}}}});var ht=U((Va,si)=>{"use strict";function ks(e,t){return t}si.exports=function(){let t=Error.prepareStackTrace;Error.prepareStackTrace=ks;let r=new Error().stack;if(Error.prepareStackTrace=t,!Array.isArray(r))return;let o=r.slice(2),s=[];for(let l of o)l&&s.push(l.getFileName());return s}});var hi=U((Ga,ai)=>{"use strict";function dt(e){if(e===null||typeof e!="object")return e;if(e instanceof Date)return new Date(e.getTime());if(e instanceof Array){let t=[];for(let r=0;r<e.length;r++)t[r]=dt(e[r]);return t}if(typeof e=="object"){let t=Object.create(Object.getPrototypeOf(e));for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=dt(e[r]));return t}return e}function li(e){let t=[],r="",o=!1,s=!1,l="";for(let f=0;f<e.length;f++){let u=e[f];!o&&u==="."?r&&(t.push(r),r=""):u==="["?(r&&(t.push(r),r=""),o=!0):u==="]"&&o?(t.push(r),r="",o=!1,s=!1):(u==='"'||u==="'")&&o?s?u===l?(s=!1,l=""):r+=u:(s=!0,l=u):r+=u}return r&&t.push(r),t}function ui(e,t,r){let o=e;for(let l=0;l<t.length-1;l++){let f=t[l];if(typeof o!="object"||o===null||!(f in o)||typeof o[f]!="object"||o[f]===null)return!1;o=o[f]}let s=t[t.length-1];if(s==="*"){if(Array.isArray(o))for(let l=0;l<o.length;l++)o[l]=r;else if(typeof o=="object"&&o!==null)for(let l in o)Object.prototype.hasOwnProperty.call(o,l)&&(o[l]=r)}else typeof o=="object"&&o!==null&&s in o&&Object.prototype.hasOwnProperty.call(o,s)&&(o[s]=r);return!0}function ci(e,t){let r=e;for(let s=0;s<t.length-1;s++){let l=t[s];if(typeof r!="object"||r===null||!(l in r)||typeof r[l]!="object"||r[l]===null)return!1;r=r[l]}let o=t[t.length-1];if(o==="*"){if(Array.isArray(r))for(let s=0;s<r.length;s++)r[s]=void 0;else if(typeof r=="object"&&r!==null)for(let s in r)Object.prototype.hasOwnProperty.call(r,s)&&delete r[s]}else typeof r=="object"&&r!==null&&o in r&&Object.prototype.hasOwnProperty.call(r,o)&&delete r[o];return!0}var hn=Symbol("PATH_NOT_FOUND");function Ls(e,t){let r=e;for(let o of t){if(r==null||typeof r!="object"||r===null||!(o in r))return hn;r=r[o]}return r}function vs(e,t){let r=e;for(let o of t){if(r==null||typeof r!="object"||r===null)return;r=r[o]}return r}function Is(e,t,r,o=!1){for(let s of t){let l=li(s);if(l.includes("*"))fi(e,l,r,s,o);else if(o)ci(e,l);else{let f=Ls(e,l);if(f===hn)continue;let u=typeof r=="function"?r(f,l):r;ui(e,l,u)}}}function fi(e,t,r,o,s=!1){let l=t.indexOf("*");if(l===t.length-1){let f=t.slice(0,-1),u=e;for(let a of f){if(u==null||typeof u!="object"||u===null)return;u=u[a]}if(Array.isArray(u))if(s)for(let a=0;a<u.length;a++)u[a]=void 0;else for(let a=0;a<u.length;a++){let c=[...f,a.toString()],h=typeof r=="function"?r(u[a],c):r;u[a]=h}else if(typeof u=="object"&&u!==null)if(s){let a=[];for(let c in u)Object.prototype.hasOwnProperty.call(u,c)&&a.push(c);for(let c of a)delete u[c]}else for(let a in u){let c=[...f,a],h=typeof r=="function"?r(u[a],c):r;u[a]=h}}else Ns(e,t,r,l,o,s)}function Ns(e,t,r,o,s,l=!1){let f=t.slice(0,o),u=t.slice(o+1),a=[];function c(h,d){if(d===f.length){if(Array.isArray(h))for(let A=0;A<h.length;A++)a[d]=A.toString(),c(h[A],d+1);else if(typeof h=="object"&&h!==null)for(let A in h)a[d]=A,c(h[A],d+1)}else if(d<f.length){let A=f[d];h&&typeof h=="object"&&h!==null&&A in h&&(a[d]=A,c(h[A],d+1))}else if(u.includes("*"))fi(h,u,typeof r=="function"?(x,p)=>{let C=[...a.slice(0,d),...p];return r(x,C)}:r,s,l);else if(l)ci(h,u);else{let A=typeof r=="function"?r(vs(h,u),[...a.slice(0,d),...u]):r;ui(h,u,A)}}if(f.length===0)c(e,0);else{let h=e;for(let d=0;d<f.length;d++){let A=f[d];if(h==null||typeof h!="object"||h===null)return;h=h[A],a[d]=A}h!=null&&c(h,f.length)}}function Rs(e){if(e.length===0)return null;let t=new Map;for(let r of e){let o=li(r),s=t;for(let l=0;l<o.length;l++){let f=o[l];s.has(f)||s.set(f,new Map),s=s.get(f)}}return t}function Ps(e,t){if(!t)return e;function r(o,s,l=0){if(!s||s.size===0||o===null||typeof o!="object")return o;if(o instanceof Date)return new Date(o.getTime());if(Array.isArray(o)){let u=[];for(let a=0;a<o.length;a++){let c=a.toString();s.has(c)||s.has("*")?u[a]=r(o[a],s.get(c)||s.get("*")):u[a]=o[a]}return u}let f=Object.create(Object.getPrototypeOf(o));for(let u in o)Object.prototype.hasOwnProperty.call(o,u)&&(s.has(u)||s.has("*")?f[u]=r(o[u],s.get(u)||s.get("*")):f[u]=o[u]);return f}return r(e,t)}function Ms(e){if(typeof e!="string")throw new Error("Paths must be (non-empty) strings");if(e==="")throw new Error("Invalid redaction path ()");if(e.includes(".."))throw new Error(`Invalid redaction path (${e})`);if(e.includes(","))throw new Error(`Invalid redaction path (${e})`);let t=0,r=!1,o="";for(let s=0;s<e.length;s++){let l=e[s];if((l==='"'||l==="'")&&t>0)r?l===o&&(r=!1,o=""):(r=!0,o=l);else if(l==="["&&!r)t++;else if(l==="]"&&!r&&(t--,t<0))throw new Error(`Invalid redaction path (${e})`)}if(t!==0)throw new Error(`Invalid redaction path (${e})`)}function Ds(e){if(!Array.isArray(e))throw new TypeError("paths must be an array");for(let t of e)Ms(t)}function js(e={}){let{paths:t=[],censor:r="[REDACTED]",serialize:o=JSON.stringify,strict:s=!0,remove:l=!1}=e;Ds(t);let f=Rs(t);return function(a){if(s&&(a===null||typeof a!="object")&&(a==null||typeof a!="object"))return o?o(a):a;let c=Ps(a,f),h=a,d=r;return typeof r=="function"&&(d=r),Is(c,t,d,l),o===!1?(c.restore=function(){return dt(h)},c):typeof o=="function"?o(c):JSON.stringify(c)}}ai.exports=js});var Ne=U((Ja,di)=>{"use strict";var Bs=Symbol("pino.setLevel"),Fs=Symbol("pino.getLevel"),qs=Symbol("pino.levelVal"),$s=Symbol("pino.levelComp"),Ws=Symbol("pino.useLevelLabels"),Hs=Symbol("pino.useOnlyCustomLevels"),zs=Symbol("pino.mixin"),Ks=Symbol("pino.lsCache"),Us=Symbol("pino.chindings"),Ys=Symbol("pino.asJson"),Vs=Symbol("pino.write"),Gs=Symbol("pino.redactFmt"),Js=Symbol("pino.time"),Xs=Symbol("pino.timeSliceIndex"),Qs=Symbol("pino.stream"),Zs=Symbol("pino.stringify"),el=Symbol("pino.stringifySafe"),nl=Symbol("pino.stringifiers"),tl=Symbol("pino.end"),rl=Symbol("pino.formatOpts"),il=Symbol("pino.messageKey"),ol=Symbol("pino.errorKey"),sl=Symbol("pino.nestedKey"),ll=Symbol("pino.nestedKeyStr"),ul=Symbol("pino.mixinMergeStrategy"),cl=Symbol("pino.msgPrefix"),fl=Symbol("pino.wildcardFirst"),al=Symbol.for("pino.serializers"),hl=Symbol.for("pino.formatters"),dl=Symbol.for("pino.hooks"),pl=Symbol.for("pino.metadata");di.exports={setLevelSym:Bs,getLevelSym:Fs,levelValSym:qs,levelCompSym:$s,useLevelLabelsSym:Ws,mixinSym:zs,lsCacheSym:Ks,chindingsSym:Us,asJsonSym:Ys,writeSym:Vs,serializersSym:al,redactFmtSym:Gs,timeSym:Js,timeSliceIndexSym:Xs,streamSym:Qs,stringifySym:Zs,stringifySafeSym:el,stringifiersSym:nl,endSym:tl,formatOptsSym:rl,messageKeySym:il,errorKeySym:ol,nestedKeySym:sl,wildcardFirstSym:fl,needsMetadataGsym:pl,useOnlyCustomLevelsSym:Hs,formattersSym:hl,hooksSym:dl,nestedKeyStrSym:ll,mixinMergeStrategySym:ul,msgPrefixSym:cl}});var gt=U((Xa,yi)=>{"use strict";var pi=hi(),{redactFmtSym:gl,wildcardFirstSym:dn}=Ne(),pt=/[^.[\]]+|\[([^[\]]*?)\]/g,gi="[Redacted]",mi=!1;function ml(e,t){let{paths:r,censor:o,remove:s}=yl(e),l=r.reduce((a,c)=>{pt.lastIndex=0;let h=pt.exec(c),d=pt.exec(c),A=h[1]!==void 0?h[1].replace(/^(?:"|'|`)(.*)(?:"|'|`)$/,"$1"):h[0];if(A==="*"&&(A=dn),d===null)return a[A]=null,a;if(a[A]===null)return a;let{index:x}=d,p=`${c.substr(x,c.length-1)}`;return a[A]=a[A]||[],A!==dn&&a[A].length===0&&a[A].push(...a[dn]||[]),A===dn&&Object.keys(a).forEach(function(C){a[C]&&a[C].push(p)}),a[A].push(p),a},{}),f={[gl]:pi({paths:r,censor:o,serialize:t,strict:mi,remove:s})},u=(...a)=>t(typeof o=="function"?o(...a):o);return[...Object.keys(l),...Object.getOwnPropertySymbols(l)].reduce((a,c)=>{if(l[c]===null)a[c]=h=>u(h,[c]);else{let h=typeof o=="function"?(d,A)=>o(d,[c,...A]):o;a[c]=pi({paths:l[c],censor:h,serialize:t,strict:mi,remove:s})}return a},f)}function yl(e){if(Array.isArray(e))return e={paths:e,censor:gi},e;let{paths:t,censor:r=gi,remove:o}=e;if(Array.isArray(t)===!1)throw Error("pino \u2013 redact must contain an array of strings");return o===!0&&(r=void 0),{paths:t,censor:r,remove:o}}yi.exports=ml});var Si=U((Qa,wi)=>{"use strict";var bl=()=>"",wl=()=>`,"time":${Date.now()}`,Sl=()=>`,"time":${Math.round(Date.now()/1e3)}`,Al=()=>`,"time":"${new Date(Date.now()).toISOString()}"`,_l=1000000n,bi=1000000000n,El=BigInt(Date.now())*_l,xl=process.hrtime.bigint(),Ol=()=>{let e=process.hrtime.bigint()-xl,t=El+e,r=t/bi,o=t%bi,s=Number(r*1000n+o/1000000n),l=new Date(s),f=l.getUTCFullYear(),u=(l.getUTCMonth()+1).toString().padStart(2,"0"),a=l.getUTCDate().toString().padStart(2,"0"),c=l.getUTCHours().toString().padStart(2,"0"),h=l.getUTCMinutes().toString().padStart(2,"0"),d=l.getUTCSeconds().toString().padStart(2,"0");return`,"time":"${f}-${u}-${a}T${c}:${h}:${d}.${o.toString().padStart(9,"0")}Z"`};wi.exports={nullTime:bl,epochTime:wl,unixTime:Sl,isoTime:Al,isoTimeNano:Ol}});var _i=U((Za,Ai)=>{"use strict";function Cl(e){try{return JSON.stringify(e)}catch{return'"[Circular]"'}}Ai.exports=Tl;function Tl(e,t,r){var o=r&&r.stringify||Cl,s=1;if(typeof e=="object"&&e!==null){var l=t.length+s;if(l===1)return e;var f=new Array(l);f[0]=o(e);for(var u=1;u<l;u++)f[u]=o(t[u]);return f.join(" ")}if(typeof e!="string")return e;var a=t.length;if(a===0)return e;for(var c="",h=1-s,d=-1,A=e&&e.length||0,x=0;x<A;){if(e.charCodeAt(x)===37&&x+1<A){switch(d=d>-1?d:0,e.charCodeAt(x+1)){case 100:case 102:if(h>=a||t[h]==null)break;d<x&&(c+=e.slice(d,x)),c+=Number(t[h]),d=x+2,x++;break;case 105:if(h>=a||t[h]==null)break;d<x&&(c+=e.slice(d,x)),c+=Math.floor(Number(t[h])),d=x+2,x++;break;case 79:case 111:case 106:if(h>=a||t[h]===void 0)break;d<x&&(c+=e.slice(d,x));var p=typeof t[h];if(p==="string"){c+="'"+t[h]+"'",d=x+2,x++;break}if(p==="function"){c+=t[h].name||"<anonymous>",d=x+2,x++;break}c+=o(t[h]),d=x+2,x++;break;case 115:if(h>=a)break;d<x&&(c+=e.slice(d,x)),c+=String(t[h]),d=x+2,x++;break;case 37:d<x&&(c+=e.slice(d,x)),c+="%",d=x+2,x++,h--;break}++h}++x}return d===-1?e:(d<A&&(c+=e.slice(d)),c)}});var yt=U((eh,mt)=>{"use strict";if(typeof SharedArrayBuffer<"u"&&typeof Atomics<"u"){let t=function(r){if((r>0&&r<1/0)===!1)throw typeof r!="number"&&typeof r!="bigint"?TypeError("sleep: ms must be a number"):RangeError("sleep: ms must be a number that is greater than 0 but less than Infinity");Atomics.wait(e,0,0,Number(r))},e=new Int32Array(new SharedArrayBuffer(4));mt.exports=t}else{let e=function(t){if((t>0&&t<1/0)===!1)throw typeof t!="number"&&typeof t!="bigint"?TypeError("sleep: ms must be a number"):RangeError("sleep: ms must be a number that is greater than 0 but less than Infinity");let o=Date.now()+Number(t);for(;o>Date.now(););};mt.exports=e}});var vi=U((nh,Li)=>{"use strict";var V=Q("fs"),kl=Q("events"),Ll=Q("util").inherits,Ei=Q("path"),wt=yt(),vl=Q("assert"),pn=100,gn=Buffer.allocUnsafe(0),Il=16*1024,xi="buffer",Oi="utf8",[Nl,Rl]=(process.versions.node||"0.0").split(".").map(Number),Pl=Nl>=22&&Rl>=7;function Ci(e,t){t._opening=!0,t._writing=!0,t._asyncDrainScheduled=!1;function r(l,f){if(l){t._reopening=!1,t._writing=!1,t._opening=!1,t.sync?process.nextTick(()=>{t.listenerCount("error")>0&&t.emit("error",l)}):t.emit("error",l);return}let u=t._reopening;t.fd=f,t.file=e,t._reopening=!1,t._opening=!1,t._writing=!1,t.sync?process.nextTick(()=>t.emit("ready")):t.emit("ready"),!t.destroyed&&(!t._writing&&t._len>t.minLength||t._flushPending?t._actualWrite():u&&process.nextTick(()=>t.emit("drain")))}let o=t.append?"a":"w",s=t.mode;if(t.sync)try{t.mkdir&&V.mkdirSync(Ei.dirname(e),{recursive:!0});let l=V.openSync(e,o,s);r(null,l)}catch(l){throw r(l),l}else t.mkdir?V.mkdir(Ei.dirname(e),{recursive:!0},l=>{if(l)return r(l);V.open(e,o,s,r)}):V.open(e,o,s,r)}function ue(e){if(!(this instanceof ue))return new ue(e);let{fd:t,dest:r,minLength:o,maxLength:s,maxWrite:l,periodicFlush:f,sync:u,append:a=!0,mkdir:c,retryEAGAIN:h,fsync:d,contentMode:A,mode:x}=e||{};t=t||r,this._len=0,this.fd=-1,this._bufs=[],this._lens=[],this._writing=!1,this._ending=!1,this._reopening=!1,this._asyncDrainScheduled=!1,this._flushPending=!1,this._hwm=Math.max(o||0,16387),this.file=null,this.destroyed=!1,this.minLength=o||0,this.maxLength=s||0,this.maxWrite=l||Il,this._periodicFlush=f||0,this._periodicFlushTimer=void 0,this.sync=u||!1,this.writable=!0,this._fsync=d||!1,this.append=a||!1,this.mode=x,this.retryEAGAIN=h||(()=>!0),this.mkdir=c||!1;let p,C;if(A===xi)this._writingBuf=gn,this.write=jl,this.flush=Fl,this.flushSync=$l,this._actualWrite=Hl,p=()=>V.writeSync(this.fd,this._writingBuf),C=()=>V.write(this.fd,this._writingBuf,this.release);else if(A===void 0||A===Oi)this._writingBuf="",this.write=Dl,this.flush=Bl,this.flushSync=ql,this._actualWrite=Wl,p=()=>Buffer.isBuffer(this._writingBuf)?V.writeSync(this.fd,this._writingBuf):V.writeSync(this.fd,this._writingBuf,"utf8"),C=()=>Buffer.isBuffer(this._writingBuf)?V.write(this.fd,this._writingBuf,this.release):V.write(this.fd,this._writingBuf,"utf8",this.release);else throw new Error(`SonicBoom supports "${Oi}" and "${xi}", but passed ${A}`);if(typeof t=="number")this.fd=t,process.nextTick(()=>this.emit("ready"));else if(typeof t=="string")Ci(t,this);else throw new Error("SonicBoom supports only file descriptors and files");if(this.minLength>=this.maxWrite)throw new Error(`minLength should be smaller than maxWrite (${this.maxWrite})`);this.release=(v,P)=>{if(v){if((v.code==="EAGAIN"||v.code==="EBUSY")&&this.retryEAGAIN(v,this._writingBuf.length,this._len-this._writingBuf.length))if(this.sync)try{wt(pn),this.release(void 0,0)}catch(M){this.release(M)}else setTimeout(C,pn);else this._writing=!1,this.emit("error",v);return}this.emit("write",P);let N=bt(this._writingBuf,this._len,P);if(this._len=N.len,this._writingBuf=N.writingBuf,this._writingBuf.length){if(!this.sync){C();return}try{do{let M=p(),W=bt(this._writingBuf,this._len,M);this._len=W.len,this._writingBuf=W.writingBuf}while(this._writingBuf.length)}catch(M){this.release(M);return}}this._fsync&&V.fsyncSync(this.fd);let I=this._len;this._reopening?(this._writing=!1,this._reopening=!1,this.reopen()):I>this.minLength?this._actualWrite():this._ending?I>0?this._actualWrite():(this._writing=!1,mn(this)):(this._writing=!1,this.sync?this._asyncDrainScheduled||(this._asyncDrainScheduled=!0,process.nextTick(Ml,this)):this.emit("drain"))},this.on("newListener",function(v){v==="drain"&&(this._asyncDrainScheduled=!1)}),this._periodicFlush!==0&&(this._periodicFlushTimer=setInterval(()=>this.flush(null),this._periodicFlush),this._periodicFlushTimer.unref())}function bt(e,t,r){return typeof e=="string"&&(e=Buffer.from(e)),t=Math.max(t-r,0),e=e.subarray(r),{writingBuf:e,len:t}}function Ml(e){e.listenerCount("drain")>0&&(e._asyncDrainScheduled=!1,e.emit("drain"))}Ll(ue,kl);function Ti(e,t){return e.length===0?gn:e.length===1?e[0]:Buffer.concat(e,t)}function Dl(e){if(this.destroyed)throw new Error("SonicBoom destroyed");e=""+e;let t=Buffer.byteLength(e),r=this._len+t,o=this._bufs;return this.maxLength&&r>this.maxLength?(this.emit("drop",e),this._len<this._hwm):(o.length===0||Buffer.byteLength(o[o.length-1])+t>this.maxWrite?o.push(e):o[o.length-1]+=e,this._len=r,!this._writing&&this._len>=this.minLength&&this._actualWrite(),this._len<this._hwm)}function jl(e){if(this.destroyed)throw new Error("SonicBoom destroyed");let t=this._len+e.length,r=this._bufs,o=this._lens;return this.maxLength&&t>this.maxLength?(this.emit("drop",e),this._len<this._hwm):(r.length===0||o[o.length-1]+e.length>this.maxWrite?(r.push([e]),o.push(e.length)):(r[r.length-1].push(e),o[o.length-1]+=e.length),this._len=t,!this._writing&&this._len>=this.minLength&&this._actualWrite(),this._len<this._hwm)}function ki(e){this._flushPending=!0;let t=()=>{if(this._fsync)this._flushPending=!1,e();else try{V.fsync(this.fd,o=>{this._flushPending=!1,e(o)})}catch(o){e(o)}this.off("error",r)},r=o=>{this._flushPending=!1,e(o),this.off("drain",t)};this.once("drain",t),this.once("error",r)}function Bl(e){if(e!=null&&typeof e!="function")throw new Error("flush cb must be a function");if(this.destroyed){let t=new Error("SonicBoom destroyed");if(e){e(t);return}throw t}if(this.minLength<=0){e?.();return}e&&ki.call(this,e),!this._writing&&(this._bufs.length===0&&this._bufs.push(""),this._actualWrite())}function Fl(e){if(e!=null&&typeof e!="function")throw new Error("flush cb must be a function");if(this.destroyed){let t=new Error("SonicBoom destroyed");if(e){e(t);return}throw t}if(this.minLength<=0){e?.();return}e&&ki.call(this,e),!this._writing&&(this._bufs.length===0&&(this._bufs.push([]),this._lens.push(0)),this._actualWrite())}ue.prototype.reopen=function(e){if(this.destroyed)throw new Error("SonicBoom destroyed");if(this._opening){this.once("ready",()=>{this.reopen(e)});return}if(this._ending)return;if(!this.file)throw new Error("Unable to reopen a file descriptor, you must pass a file to SonicBoom");if(e&&(this.file=e),this._reopening=!0,this._writing)return;let t=this.fd;this.once("ready",()=>{t!==this.fd&&V.close(t,r=>{if(r)return this.emit("error",r)})}),Ci(this.file,this)};ue.prototype.end=function(){if(this.destroyed)throw new Error("SonicBoom destroyed");if(this._opening){this.once("ready",()=>{this.end()});return}this._ending||(this._ending=!0,!this._writing&&(this._len>0&&this.fd>=0?this._actualWrite():mn(this)))};function ql(){if(this.destroyed)throw new Error("SonicBoom destroyed");if(this.fd<0)throw new Error("sonic boom is not ready yet");!this._writing&&this._writingBuf.length>0&&(this._bufs.unshift(this._writingBuf),this._writingBuf="");let e="";for(;this._bufs.length||e.length;){e.length<=0&&(e=this._bufs[0]);try{let t=Buffer.isBuffer(e)?V.writeSync(this.fd,e):V.writeSync(this.fd,e,"utf8"),r=bt(e,this._len,t);e=r.writingBuf,this._len=r.len,e.length<=0&&this._bufs.shift()}catch(t){if((t.code==="EAGAIN"||t.code==="EBUSY")&&!this.retryEAGAIN(t,e.length,this._len-e.length))throw t;wt(pn)}}try{V.fsyncSync(this.fd)}catch{}}function $l(){if(this.destroyed)throw new Error("SonicBoom destroyed");if(this.fd<0)throw new Error("sonic boom is not ready yet");!this._writing&&this._writingBuf.length>0&&(this._bufs.unshift([this._writingBuf]),this._writingBuf=gn);let e=gn;for(;this._bufs.length||e.length;){e.length<=0&&(e=Ti(this._bufs[0],this._lens[0]));try{let t=V.writeSync(this.fd,e);e=e.subarray(t),this._len=Math.max(this._len-t,0),e.length<=0&&(this._bufs.shift(),this._lens.shift())}catch(t){if((t.code==="EAGAIN"||t.code==="EBUSY")&&!this.retryEAGAIN(t,e.length,this._len-e.length))throw t;wt(pn)}}}ue.prototype.destroy=function(){this.destroyed||mn(this)};function Wl(){let e=this.release;if(this._writing=!0,this._writingBuf=this._writingBuf.length?this._writingBuf:this._bufs.shift()||"",this.sync)try{let t=Buffer.isBuffer(this._writingBuf)?V.writeSync(this.fd,this._writingBuf):V.writeSync(this.fd,this._writingBuf,"utf8");e(null,t)}catch(t){e(t)}else V.write(this.fd,this._writingBuf,e)}function Hl(){let e=this.release;if(this._writing=!0,this._writingBuf=this._writingBuf.length?this._writingBuf:Ti(this._bufs.shift(),this._lens.shift()),this.sync)try{let t=V.writeSync(this.fd,this._writingBuf);e(null,t)}catch(t){e(t)}else Pl&&(this._writingBuf=Buffer.from(this._writingBuf)),V.write(this.fd,this._writingBuf,e)}function mn(e){if(e.fd===-1){e.once("ready",mn.bind(null,e));return}e._periodicFlushTimer!==void 0&&clearInterval(e._periodicFlushTimer),e.destroyed=!0,e._bufs=[],e._lens=[],vl(typeof e.fd=="number",`sonic.fd must be a number, got ${typeof e.fd}`);try{V.fsync(e.fd,t)}catch{}function t(){e.fd!==1&&e.fd!==2?V.close(e.fd,r):r()}function r(o){if(o){e.emit("error",o);return}e._ending&&!e._writing&&e.emit("finish"),e.emit("close")}}ue.SonicBoom=ue;ue.default=ue;Li.exports=ue});var St=U((th,Mi)=>{"use strict";var ce={exit:[],beforeExit:[]},Ii={exit:Ul,beforeExit:Yl},Re;function zl(){Re===void 0&&(Re=new FinalizationRegistry(Vl))}function Kl(e){ce[e].length>0||process.on(e,Ii[e])}function Ni(e){ce[e].length>0||(process.removeListener(e,Ii[e]),ce.exit.length===0&&ce.beforeExit.length===0&&(Re=void 0))}function Ul(){Ri("exit")}function Yl(){Ri("beforeExit")}function Ri(e){for(let t of ce[e]){let r=t.deref(),o=t.fn;r!==void 0&&o(r,e)}ce[e]=[]}function Vl(e){for(let t of["exit","beforeExit"]){let r=ce[t].indexOf(e);ce[t].splice(r,r+1),Ni(t)}}function Pi(e,t,r){if(t===void 0)throw new Error("the object can't be undefined");Kl(e);let o=new WeakRef(t);o.fn=r,zl(),Re.register(t,o),ce[e].push(o)}function Gl(e,t){Pi("exit",e,t)}function Jl(e,t){Pi("beforeExit",e,t)}function Xl(e){if(Re!==void 0){Re.unregister(e);for(let t of["exit","beforeExit"])ce[t]=ce[t].filter(r=>{let o=r.deref();return o&&o!==e}),Ni(t)}}Mi.exports={register:Gl,registerBeforeExit:Jl,unregister:Xl}});var Di=U((rh,Ql)=>{Ql.exports={name:"thread-stream",version:"4.2.0",description:"A streaming way to send data to a Node.js Worker Thread",main:"index.js",types:"index.d.ts",engines:{node:">=20"},dependencies:{"real-require":"^1.0.0"},devDependencies:{"@types/node":"^25.0.2","@yao-pkg/pkg":"^6.0.0",borp:"^1.0.0",desm:"^1.3.0",eslint:"^9.39.1",fastbench:"^1.0.1",neostandard:"^0.13.0","pino-elasticsearch":"^9.0.0","sonic-boom":"^5.0.0","ts-node":"^10.8.0",typescript:"~5.7.3"},scripts:{build:"tsc --noEmit",lint:"eslint",test:'npm run lint && npm run build && npm run transpile && borp --pattern "test/*.test.{js,mjs}"',"test:ci":'npm run lint && npm run transpile && borp --pattern "test/*.test.{js,mjs}"',"test:yarn":'npm run transpile && borp --pattern "test/*.test.js"',transpile:"sh ./test/ts/transpile.sh"},repository:{type:"git",url:"git+https://github.com/mcollina/thread-stream.git"},keywords:["worker","thread","threads","stream"],author:"Matteo Collina <hello@matteocollina.com>",license:"MIT",bugs:{url:"https://github.com/mcollina/thread-stream/issues"},homepage:"https://github.com/mcollina/thread-stream#readme"}});var Bi=U((ih,ji)=>{"use strict";function Zl(e,t,r,o,s){let l=o===1/0?1/0:Date.now()+o,f=()=>{let u=Atomics.load(e,t);if(u===r){s(null,"ok");return}if(l!==1/0&&Date.now()>l){s(null,"timed-out");return}let a=l===1/0?1e4:Math.min(1e4,Math.max(1,l-Date.now())),c=Atomics.waitAsync(e,t,u,a);c.async?c.value.then(f):setImmediate(f)};f()}function eu(e,t,r,o,s){let l=o===1/0?1/0:Date.now()+o,f=()=>{if(Atomics.load(e,t)!==r){s(null,"ok");return}if(l!==1/0&&Date.now()>l){s(null,"timed-out");return}let a=l===1/0?1e4:Math.min(1e4,Math.max(1,l-Date.now())),c=Atomics.waitAsync(e,t,r,a);c.async?c.value.then(h=>{if(h==="ok"){s(null,"ok");return}f()}):setImmediate(f)};f()}ji.exports={wait:Zl,waitDiff:eu}});var qi=U((oh,Fi)=>{"use strict";Fi.exports={WRITE_INDEX:4,READ_INDEX:8,SEQ_INDEX:2}});var Qi=U((sh,Xi)=>{"use strict";var{version:nu}=Di(),{EventEmitter:tu}=Q("events"),{Worker:ru}=Q("worker_threads"),{join:iu}=Q("path"),{pathToFileURL:ou}=Q("url"),{wait:su}=Bi(),{WRITE_INDEX:ge,READ_INDEX:Ee,SEQ_INDEX:At}=qi(),lu=Q("buffer"),uu=Q("assert"),w=Symbol("kImpl"),cu=lu.constants.MAX_STRING_LENGTH;function $i(){}function Ot(e,t){Atomics.add(e[w].state,At,1),t(),Atomics.add(e[w].state,At,1),Atomics.notify(e[w].state,At)}function Wi(e){Ot(e,()=>{Atomics.store(e[w].state,Ee,0),Atomics.store(e[w].state,ge,0)})}var Ye=class{constructor(t){this._value=t}deref(){return this._value}},yn=class{register(){}unregister(){}},fu=process.env.NODE_V8_COVERAGE?yn:global.FinalizationRegistry||yn,au=process.env.NODE_V8_COVERAGE?Ye:global.WeakRef||Ye,Hi=new fu(e=>{e.exited||e.terminate()});function hu(e,t){let{filename:r,workerData:o}=t,l=("__bundlerPathsOverrides"in globalThis?globalThis.__bundlerPathsOverrides:{})["thread-stream-worker"]||iu(__dirname,"lib","worker.js"),f=new ru(l,{...t.workerOpts,name:t.workerOpts?.name||"thread-stream",trackUnmanagedFds:!1,workerData:{filename:r.indexOf("file://")===0?r:ou(r).href,dataBuf:e[w].dataBuf,stateBuf:e[w].stateBuf,workerData:{$context:{threadStreamVersion:nu},...o}}});return f.stream=new Ye(e),f.on("message",du),f.on("exit",Ui),Hi.register(e,f),f}function zi(e){uu(!e[w].sync),e[w].needDrain&&(e[w].needDrain=!1,e.emit("drain"))}function Ki(e){for(;;){let t=Atomics.load(e[w].state,ge),r=e[w].data.length-t;if(r>0){if(e[w].bufLen===0){e[w].flushing=!1,e[w].ending?Ct(e):e[w].needDrain&&process.nextTick(zi,e);return}Gi(e,r,$i);continue}if(r===0){if(t===0&&e[w].bufLen===0)return;bn(e,()=>{e.destroyed||(Wi(e),Ki(e))});return}oe(e,new Error("overwritten"));return}}function du(e){let t=this.stream.deref();if(t===void 0){this.exited=!0,this.terminate();return}if(e?.code!=null)switch(e.code){case"READY":this.stream=new au(t),bn(t,()=>{t[w].ready=!0,t.emit("ready")});break;case"ERROR":oe(t,e.err);break;case"EVENT":Array.isArray(e.args)?t.emit(e.name,...e.args):t.emit(e.name,e.args);break;case"FLUSHED":{if(e.context!=="thread-stream"){oe(t,new Error("this should not happen: "+e.code));break}let r=t[w].flushCallbacks.get(e.id);r&&(t[w].flushCallbacks.delete(e.id),process.nextTick(r));break}case"WARNING":process.emitWarning(e.err);break;default:oe(t,new Error("this should not happen: "+e.code))}}function Ui(e){let t=this.stream.deref();t!==void 0&&(Hi.unregister(t),t.worker.exited=!0,t.worker.off("exit",Ui),oe(t,e!==0?new Error("the worker thread exited"):null))}var Et=class extends tu{constructor(t={}){if(super(),t.bufferSize<4)throw new Error("bufferSize must at least fit a 4-byte utf-8 char");this[w]={},this[w].stateBuf=new SharedArrayBuffer(128),this[w].state=new Int32Array(this[w].stateBuf),this[w].dataBuf=new SharedArrayBuffer(t.bufferSize||4*1024*1024),this[w].data=Buffer.from(this[w].dataBuf),this[w].sync=t.sync||!1,this[w].ending=!1,this[w].ended=!1,this[w].needDrain=!1,this[w].destroyed=!1,this[w].flushing=!1,this[w].ready=!1,this[w].finished=!1,this[w].errored=null,this[w].closed=!1,this[w].buf=[],this[w].bufHead=0,this[w].bufLen=0,this[w].flushCallbacks=new Map,this[w].nextFlushId=0,this.worker=hu(this,t),this.on("message",(r,o)=>{this.worker.postMessage(r,o)})}write(t){let r=Buffer.isBuffer(t)?t:Buffer.from(t);if(this[w].destroyed)return xt(this,new Error("the worker has exited")),!1;if(this[w].ending)return xt(this,new Error("the worker is ending")),!1;if(this[w].flushing&&this[w].bufLen+r.length>=cu)try{_t(this),this[w].flushing=!0}catch(o){return oe(this,o),!1}if(this[w].buf.push(r),this[w].bufLen+=r.length,this[w].sync)try{return _t(this),!0}catch(o){return oe(this,o),!1}return this[w].flushing||(this[w].flushing=!0,setImmediate(Ki,this)),this[w].needDrain=this[w].data.length-this[w].bufLen-Atomics.load(this[w].state,ge)<=0,!this[w].needDrain}end(){this[w].destroyed||(this[w].ending=!0,Ct(this))}flush(t){t=typeof t=="function"?t:$i,Yi(this,r=>{if(r){process.nextTick(t,r);return}Vi(this,t)})}flushSync(){this[w].destroyed||(_t(this),Ji(this))}unref(){this.worker.unref()}ref(){this.worker.ref()}get ready(){return this[w].ready}get destroyed(){return this[w].destroyed}get closed(){return this[w].closed}get writable(){return!this[w].destroyed&&!this[w].ending}get writableEnded(){return this[w].ending}get writableFinished(){return this[w].finished}get writableNeedDrain(){return this[w].needDrain}get writableObjectMode(){return!1}get writableErrored(){return this[w].errored}};function Yi(e,t){if(e[w].destroyed){process.nextTick(t,new Error("the worker has exited"));return}if(!e[w].sync&&(e[w].flushing||e[w].bufLen>0)){setImmediate(Yi,e,t);return}bn(e,t)}function bn(e,t){let r=Atomics.load(e[w].state,ge);su(e[w].state,Ee,r,1/0,(o,s)=>{if(o){oe(e,o),t(o);return}if(s!=="ok"){bn(e,t);return}t()})}function Vi(e,t){if(e[w].destroyed){process.nextTick(t,new Error("the worker has exited"));return}if(!e[w].ready){let o=()=>{l(),Vi(e,t)},s=()=>{l(),process.nextTick(t,new Error("the worker has exited"))},l=()=>{e.off("ready",o),e.off("close",s)};e.once("ready",o),e.once("close",s);return}let r=++e[w].nextFlushId;e[w].flushCallbacks.set(r,t);try{e.worker.postMessage({code:"FLUSH",context:"thread-stream",id:r})}catch(o){e[w].flushCallbacks.delete(r),oe(e,o),process.nextTick(t,o)}}function pu(e,t){let r=e[w].flushCallbacks;if(r.size===0)return;let o=t||new Error("the worker has exited");for(let s of r.values())process.nextTick(s,o);r.clear()}function xt(e,t){setImmediate(()=>{e.emit("error",t)})}function oe(e,t){e[w].destroyed||(e[w].destroyed=!0,pu(e,t),t&&(e[w].errored=t,xt(e,t)),e.worker.exited?setImmediate(()=>{e[w].closed=!0,e.emit("close")}):e.worker.terminate().catch(()=>{}).then(()=>{e[w].closed=!0,e.emit("close")}))}function Gi(e,t,r){let s=Atomics.load(e[w].state,ge),l=t;for(;l>0&&e[w].bufLen!==0;){let f=e[w].bufHead,u=e[w].buf[f];if(u.length<=l){u.copy(e[w].data,s),s+=u.length,l-=u.length,e[w].bufLen-=u.length,e[w].bufHead=f+1,e[w].bufHead===e[w].buf.length?(e[w].buf.length=0,e[w].bufHead=0):e[w].bufHead>=1024&&e[w].bufHead*2>=e[w].buf.length&&(e[w].buf.splice(0,e[w].bufHead),e[w].bufHead=0);continue}u.copy(e[w].data,s,0,l),e[w].buf[f]=u.subarray(l),e[w].bufLen-=l,s+=l,l=0}return Ot(e,()=>{Atomics.store(e[w].state,ge,s)}),r(),!0}function Ct(e){if(!(e[w].ended||!e[w].ending||e[w].flushing)){e[w].ended=!0;try{e.flushSync();let t=Atomics.load(e[w].state,Ee);Ot(e,()=>{Atomics.store(e[w].state,ge,-1)});let r=0;for(;t!==-1;){if(Atomics.wait(e[w].state,Ee,t,1e3),t=Atomics.load(e[w].state,Ee),t===-2){oe(e,new Error("end() failed"));return}if(++r===10){oe(e,new Error("end() took too long (10s)"));return}}process.nextTick(()=>{e[w].finished=!0,e.emit("finish")})}catch(t){oe(e,t)}}}function _t(e){let t=()=>{e[w].ending?Ct(e):e[w].needDrain&&process.nextTick(zi,e)};for(e[w].flushing=!1;e[w].bufLen!==0;){let r=Atomics.load(e[w].state,ge),o=e[w].data.length-r;if(o===0){Ji(e),Wi(e);continue}else if(o<0)throw new Error("overwritten");Gi(e,o,t)}}function Ji(e){if(e[w].flushing)throw new Error("unable to flush while flushing");let t=Atomics.load(e[w].state,ge),r=0;for(;;){let o=Atomics.load(e[w].state,Ee);if(o===-2)throw Error("_flushSync failed");if(o!==t)Atomics.wait(e[w].state,Ee,o,1e3);else break;if(++r===10)throw new Error("_flushSync took too long (10s)")}}Xi.exports=Et});var Lt=U((lh,no)=>{"use strict";var{createRequire:gu}=Q("module"),{existsSync:mu}=Q("fs"),yu=ht(),{join:Tt,isAbsolute:eo,sep:bu}=Q("path"),{fileURLToPath:wu}=Q("url"),Su=yt(),kt=St(),Au=Qi();function _u(e){kt.register(e,Tu),kt.registerBeforeExit(e,ku),e.on("close",function(){kt.unregister(e)})}function Eu(){let e=process.execArgv;for(let t=0;t<e.length;t++){let r=e[t];if(r==="--import"||r==="--require"||r==="-r"||r.startsWith("--import=")||r.startsWith("--require=")||r.startsWith("-r="))return!0}return!1}function xu(e){let t=e.match(/(?:[^\s"']+|"[^"]*"|'[^']*')+/g);if(!t)return e;let r=[],o=!1;for(let s=0;s<t.length;s++){let l=t[s];if(l==="--require"||l==="-r"||l==="--import"){let f=t[s+1];if(f&&Zi(f)){o=!0,s++;continue}r.push(l),f&&(r.push(f),s++);continue}if(l.startsWith("--require=")||l.startsWith("-r=")||l.startsWith("--import=")){let f=l.slice(l.indexOf("=")+1);if(Zi(f)){o=!0;continue}}r.push(l)}return o?r.join(" "):e}function Zi(e){let t=Ou(e);if(!t)return!1;let r=t;if(r.startsWith("file://"))try{r=wu(r)}catch{return!1}return eo(r)&&!mu(r)}function Ou(e){let t=e[0],r=e[e.length-1];return t==='"'&&r==='"'||t==="'"&&r==="'"?e.slice(1,-1):e}function Cu(e,t,r,o,s){if(!r.execArgv&&Eu()&&Q.main===void 0&&(r={...r,execArgv:[]}),!r.env&&process.env.NODE_OPTIONS){let a=xu(process.env.NODE_OPTIONS);a!==process.env.NODE_OPTIONS&&(r={...r,env:{...process.env,NODE_OPTIONS:a}})}r={...r,name:s};let l=new Au({filename:e,workerData:t,workerOpts:r,sync:o});l.on("ready",f),l.on("close",function(){process.removeListener("exit",u)}),process.on("exit",u);function f(){process.removeListener("exit",u),l.unref(),r.autoEnd!==!1&&_u(l)}function u(){l.closed||(l.flushSync(),Su(100),l.end())}return l}function Tu(e){e.ref(),e.flushSync(),e.end(),e.once("close",function(){e.unref()})}function ku(e){e.flushSync()}function Lu(e){let{pipeline:t,targets:r,levels:o,dedupe:s,worker:l={},caller:f=yu(),sync:u=!1}=e,a={...e.options},c=typeof f=="string"?[f]:f,h=typeof globalThis=="object"&&Object.prototype.hasOwnProperty.call(globalThis,"__bundlerPathsOverrides")&&globalThis.__bundlerPathsOverrides&&typeof globalThis.__bundlerPathsOverrides=="object"?globalThis.__bundlerPathsOverrides:Object.create(null),d=e.target;if(d&&r)throw new Error("only one of target or targets can be specified");r?(d=h["pino-worker"]||Tt(__dirname,"worker.js"),a.targets=r.filter(p=>p.target).map(p=>({...p,target:x(p.target)})),a.pipelines=r.filter(p=>p.pipeline).map(p=>p.pipeline.map(C=>({...C,level:p.level,target:x(C.target)})))):t&&(d=h["pino-worker"]||Tt(__dirname,"worker.js"),a.pipelines=[t.map(p=>({...p,target:x(p.target)}))]),o&&(a.levels=o),s&&(a.dedupe=s),a.pinoWillSendConfig=!0;let A=r||t?"pino.transport":d;return Cu(x(d),a,l,u,A);function x(p){if(p=h[p]||p,eo(p)||p.indexOf("file://")===0)return p;if(p==="pino/file")return Tt(__dirname,"..","file.js");let C;for(let v of c)try{let P=v==="node:repl"?process.cwd()+bu:v;C=gu(P).resolve(p);break}catch{continue}if(!C)throw new Error(`unable to determine transport target for "${p}"`);return C}}no.exports=Lu});var An=U((ch,go)=>{"use strict";var vu=Q("diagnostics_channel"),to=_i(),{mapHttpRequest:Iu,mapHttpResponse:Nu}=at(),It=vi(),ro=St(),{lsCacheSym:Ru,chindingsSym:uo,writeSym:io,serializersSym:co,formatOptsSym:oo,endSym:Pu,stringifiersSym:fo,stringifySym:ao,stringifySafeSym:Nt,wildcardFirstSym:ho,nestedKeySym:Mu,formattersSym:po,messageKeySym:Du,errorKeySym:ju,nestedKeyStrSym:Bu,msgPrefixSym:wn}=Ne(),{isMainThread:Fu}=Q("worker_threads"),qu=Lt(),[$u]=process.versions.node.split(".").map(e=>Number(e)),so=vu.tracingChannel("pino_asJson"),vt=$u>=25?e=>JSON.stringify(e):Hu;function Pe(){}function Wu(e,t){if(!t)return r;return function(...s){t.call(this,s,r,e)};function r(o,...s){if(typeof o=="object"){let l=o;o!==null&&(o.method&&o.headers&&o.socket?o=Iu(o):typeof o.setHeader=="function"&&(o=Nu(o)));let f;l===null&&s.length===0?f=[null]:(l=s.shift(),f=s),typeof this[wn]=="string"&&l!==void 0&&l!==null&&(l=this[wn]+l),this[io](o,to(l,f,this[oo]),e)}else{let l=o===void 0?s.shift():o;typeof this[wn]=="string"&&l!==void 0&&l!==null&&(l=this[wn]+l),this[io](null,to(l,s,this[oo]),e)}}}function Hu(e){let t="",r=0,o=!1,s=255,l=e.length;if(l>100)return JSON.stringify(e);for(var f=0;f<l&&s>=32;f++)s=e.charCodeAt(f),(s===34||s===92)&&(t+=e.slice(r,f)+"\\",r=f,o=!0);return o?t+=e.slice(r):t=e,s<32?JSON.stringify(e):'"'+t+'"'}function zu(e,t,r,o){if(so.hasSubscribers===!1)return lo.call(this,e,t,r,o);let s={instance:this,arguments};return so.traceSync(lo,s,this,e,t,r,o)}function lo(e,t,r,o){let s=this[ao],l=this[Nt],f=this[fo],u=this[Pu],a=this[uo],c=this[co],h=this[po],d=this[Du],A=this[ju],x=this[Ru][r]+o;x=x+a;let p;h.log&&(e=h.log(e));let C=f[ho],v="";for(let N in e)if(p=e[N],Object.prototype.hasOwnProperty.call(e,N)&&p!==void 0){c[N]?p=c[N](p):N===A&&c.err&&(p=c.err(p));let I=f[N]||C;switch(typeof p){case"undefined":case"function":continue;case"number":Number.isFinite(p)===!1&&(p=null);case"boolean":I&&(p=I(p));break;case"string":p=(I||vt)(p);break;default:p=(I||s)(p,l)}if(p===void 0)continue;let M=vt(N);v+=","+M+":"+p}let P="";if(t!==void 0){p=c[d]?c[d](t):t;let N=f[d]||C;switch(typeof p){case"function":break;case"number":Number.isFinite(p)===!1&&(p=null);case"boolean":N&&(p=N(p)),P=',"'+d+'":'+p;break;case"string":p=(N||vt)(p),P=',"'+d+'":'+p;break;default:p=(N||s)(p,l),P=',"'+d+'":'+p}}return this[Mu]&&v?x+this[Bu]+v.slice(1)+"}"+P+u:x+v+P+u}function Ku(e,t){let r,o=e[uo],s=e[ao],l=e[Nt],f=e[fo],u=f[ho],a=e[co],c=e[po].bindings;t=c(t);for(let h in t)if(r=t[h],((h.length<5||h!=="level"&&h!=="serializers"&&h!=="formatters"&&h!=="customLevels")&&t.hasOwnProperty(h)&&r!==void 0)===!0){if(r=a[h]?a[h](r):r,r=(f[h]||u||s)(r,l),r===void 0)continue;o+=',"'+h+'":'+r}return o}function Uu(e){return e.write!==e.constructor.prototype.write}function Sn(e){let t=new It(e);return t.on("error",r),!e.sync&&Fu&&(ro.register(t,Yu),t.on("close",function(){ro.unregister(t)})),t;function r(o){if(o.code==="EPIPE"){t.write=Pe,t.end=Pe,t.flushSync=Pe,t.destroy=Pe;return}t.removeListener("error",r),t.emit("error",o)}}function Yu(e,t){e.destroyed||(t==="beforeExit"?(e.flush(),e.on("drain",function(){e.end()})):e.flushSync())}function Vu(e){return function(r,o,s={},l){if(typeof s=="string")l=Sn({dest:s}),s={};else if(typeof l=="string"){if(s&&s.transport)throw Error("only one of option.transport or stream can be specified");l=Sn({dest:l})}else if(s instanceof It||s.writable||s._writableState)l=s,s={};else if(s.transport){if(s.transport instanceof It||s.transport.writable||s.transport._writableState)throw Error("option.transport do not allow stream, please pass to option directly. e.g. pino(transport)");if(s.transport.targets&&s.transport.targets.length&&s.formatters&&typeof s.formatters.level=="function")throw Error("option.transport.targets do not allow custom level formatters");let a;s.customLevels&&(a=s.useOnlyCustomLevels?s.customLevels:Object.assign({},s.levels,s.customLevels)),l=qu({caller:o,...s.transport,levels:a})}if(s=Object.assign({},e,s),s.serializers=Object.assign({},e.serializers,s.serializers),s.formatters=Object.assign({},e.formatters,s.formatters),s.prettyPrint)throw new Error("prettyPrint option is no longer supported, see the pino-pretty package (https://github.com/pinojs/pino-pretty)");let{enabled:f,onChild:u}=s;return f===!1&&(s.level="silent"),u||(s.onChild=Pe),l||(Uu(process.stdout)?l=process.stdout:l=Sn({fd:process.stdout.fd||1})),{opts:s,stream:l}}}function Gu(e,t){try{return JSON.stringify(e)}catch{try{return(t||this[Nt])(e)}catch{return'"[unable to serialize, circular reference is too complex to analyze]"'}}}function Ju(e,t,r){return{level:e,bindings:t,log:r}}function Xu(e){let t=Number(e);return typeof e=="string"&&Number.isFinite(t)?t:e===void 0?1:e}go.exports={noop:Pe,buildSafeSonicBoom:Sn,asChindings:Ku,asJson:zu,genLog:Wu,createArgsNormalizer:Vu,stringify:Gu,buildFormatters:Ju,normalizeDestFileDescriptor:Xu}});var _n=U((fh,mo)=>{"use strict";var Qu={trace:10,debug:20,info:30,warn:40,error:50,fatal:60},Zu={ASC:"ASC",DESC:"DESC"};mo.exports={DEFAULT_LEVELS:Qu,SORTING_ORDER:Zu}});var Mt=U((ah,So)=>{"use strict";var{lsCacheSym:ec,levelValSym:Rt,useOnlyCustomLevelsSym:nc,streamSym:tc,formattersSym:rc,hooksSym:ic,levelCompSym:yo}=Ne(),{noop:oc,genLog:xe}=An(),{DEFAULT_LEVELS:ae,SORTING_ORDER:bo}=_n(),wo={fatal:e=>{let t=xe(ae.fatal,e);return function(...r){let o=this[tc];if(t.call(this,...r),typeof o.flushSync=="function")try{o.flushSync()}catch{}}},error:e=>xe(ae.error,e),warn:e=>xe(ae.warn,e),info:e=>xe(ae.info,e),debug:e=>xe(ae.debug,e),trace:e=>xe(ae.trace,e)},Pt=Object.keys(ae).reduce((e,t)=>(e[ae[t]]=t,e),{}),sc=Object.keys(Pt).reduce((e,t)=>(e[t]='{"level":'+Number(t),e),{});function lc(e){let t=e[rc].level,{labels:r}=e.levels,o={};for(let s in r){let l=t(r[s],Number(s));o[s]=JSON.stringify(l).slice(0,-1)}return e[ec]=o,e}function uc(e,t){if(t)return!1;switch(e){case"fatal":case"error":case"warn":case"info":case"debug":case"trace":return!0;default:return!1}}function cc(e){let{labels:t,values:r}=this.levels;if(typeof e=="number"){if(t[e]===void 0)throw Error("unknown level value"+e);e=t[e]}if(r[e]===void 0)throw Error("unknown level "+e);let o=this[Rt],s=this[Rt]=r[e],l=this[nc],f=this[yo],u=this[ic].logMethod;for(let a in r){if(f(r[a],s)===!1){this[a]=oc;continue}this[a]=uc(a,l)?wo[a](u):xe(r[a],u)}this.emit("level-change",e,s,t[o],o,this)}function fc(e){let{levels:t,levelVal:r}=this;return t&&t.labels?t.labels[r]:""}function ac(e){let{values:t}=this.levels,r=t[e];return r!==void 0&&this[yo](r,this[Rt])}function hc(e,t,r){return e===bo.DESC?t<=r:t>=r}function dc(e){return typeof e=="string"?hc.bind(null,e):e}function pc(e=null,t=!1){let r=e?Object.keys(e).reduce((l,f)=>(l[e[f]]=f,l),{}):null,o=Object.assign(Object.create(Object.prototype,{Infinity:{value:"silent"}}),t?null:Pt,r),s=Object.assign(Object.create(Object.prototype,{silent:{value:1/0}}),t?null:ae,e);return{labels:o,values:s}}function gc(e,t,r){if(typeof e=="number"){if(![].concat(Object.keys(t||{}).map(l=>t[l]),r?[]:Object.keys(Pt).map(l=>+l),1/0).includes(e))throw Error(`default level:${e} must be included in custom levels`);return}let o=Object.assign(Object.create(Object.prototype,{silent:{value:1/0}}),r?null:ae,t);if(!(e in o))throw Error(`default level:${e} must be included in custom levels`)}function mc(e,t){let{labels:r,values:o}=e;for(let s in t){if(s in o)throw Error("levels cannot be overridden");if(t[s]in r)throw Error("pre-existing level values cannot be used for new levels")}}function yc(e){if(typeof e!="function"&&!(typeof e=="string"&&Object.values(bo).includes(e)))throw new Error('Levels comparison should be one of "ASC", "DESC" or "function" type')}So.exports={initialLsCache:sc,genLsCache:lc,levelMethods:wo,getLevel:fc,setLevel:cc,isLevelEnabled:ac,mappings:pc,assertNoLevelCollisions:mc,assertDefaultLevelFound:gc,genLevelComparison:dc,assertLevelComparison:yc}});var Dt=U((hh,Ao)=>{"use strict";Ao.exports={version:"10.3.1"}});var Lo=U((ph,ko)=>{"use strict";var{EventEmitter:bc}=Q("events"),{lsCacheSym:wc,levelValSym:Sc,setLevelSym:Bt,getLevelSym:_o,chindingsSym:xn,mixinSym:Ac,asJsonSym:xo,writeSym:_c,mixinMergeStrategySym:Ec,timeSym:xc,timeSliceIndexSym:Oc,streamSym:Oo,serializersSym:Oe,formattersSym:Ve,errorKeySym:Cc,messageKeySym:Tc,useOnlyCustomLevelsSym:kc,needsMetadataGsym:Lc,redactFmtSym:vc,stringifySym:Ic,formatOptsSym:Nc,stringifiersSym:Rc,msgPrefixSym:Ft,hooksSym:Pc}=Ne(),{getLevel:Mc,setLevel:Dc,isLevelEnabled:jc,mappings:Bc,initialLsCache:Fc,genLsCache:qc,assertNoLevelCollisions:$c}=Mt(),{asChindings:qt,asJson:Wc,buildFormatters:jt,stringify:Eo,noop:Co}=An(),{version:Hc}=Dt(),zc=gt(),Kc=class{},To={constructor:Kc,child:Uc,bindings:Yc,setBindings:Vc,flush:Xc,isLevelEnabled:jc,version:Hc,get level(){return this[_o]()},set level(e){this[Bt](e)},get levelVal(){return this[Sc]},set levelVal(e){throw Error("levelVal is read-only")},get msgPrefix(){return this[Ft]},get[Symbol.toStringTag](){return"Pino"},[wc]:Fc,[_c]:Jc,[xo]:Wc,[_o]:Mc,[Bt]:Dc};Object.setPrototypeOf(To,bc.prototype);ko.exports=function(){return Object.create(To)};var En=e=>e;function Uc(e,t){if(!e)throw Error("missing bindings for child Pino");let r=this[Oe],o=this[Ve],s=Object.create(this);if(t==null)return s[Ve].bindings!==En&&(s[Ve]=jt(o.level,En,o.log)),s[xn]=qt(s,e),this.onChild!==Co&&this.onChild(s),s;if(t.hasOwnProperty("serializers")===!0){s[Oe]=Object.create(null);for(let c in r)s[Oe][c]=r[c];let u=Object.getOwnPropertySymbols(r);for(var l=0;l<u.length;l++){let c=u[l];s[Oe][c]=r[c]}for(let c in t.serializers)s[Oe][c]=t.serializers[c];let a=Object.getOwnPropertySymbols(t.serializers);for(var f=0;f<a.length;f++){let c=a[f];s[Oe][c]=t.serializers[c]}}else s[Oe]=r;if(t.hasOwnProperty("formatters")){let{level:u,bindings:a,log:c}=t.formatters;s[Ve]=jt(u||o.level,a||En,c||o.log)}else s[Ve]=jt(o.level,En,o.log);if(t.hasOwnProperty("customLevels")===!0&&($c(this.levels,t.customLevels),s.levels=Bc(t.customLevels,s[kc]),qc(s)),typeof t.redact=="object"&&t.redact!==null||Array.isArray(t.redact)){s.redact=t.redact;let u=zc(s.redact,Eo),a={stringify:u[vc]};s[Ic]=Eo,s[Rc]=u,s[Nc]=a}if(typeof t.msgPrefix=="string"&&(s[Ft]=(this[Ft]||"")+t.msgPrefix),s[xn]=qt(s,e),t.level!==void 0&&t.level!==this.level||t.hasOwnProperty("customLevels")){let u=t.level||this.level;s[Bt](u)}return this.onChild(s),s}function Yc(){let t=`{${this[xn].substr(1)}}`,r=JSON.parse(t);return delete r.pid,delete r.hostname,r}function Vc(e){let t=qt(this,e);this[xn]=t}function Gc(e,t){return Object.assign(t,e)}function Jc(e,t,r){let o=this[xc](),s=this[Ac],l=this[Cc],f=this[Tc],u=this[Ec]||Gc,a,c=this[Pc].streamWrite;e==null?a={}:e instanceof Error?(a={[l]:e},t===void 0&&(t=e.message)):(a=e,t===void 0&&e[f]===void 0&&e[l]&&(t=e[l].message)),s&&(a=u(a,s(a,r,this)));let h=this[xo](a,t,r,o),d=this[Oo];d[Lc]===!0&&(d.lastLevel=r,d.lastObj=a,d.lastMsg=t,d.lastTime=o.slice(this[Oc]),d.lastLogger=this),d.write(c?c(h):h)}function Xc(e){if(e!=null&&typeof e!="function")throw Error("callback must be a function");let t=this[Oo];typeof t.flush=="function"?t.flush(e||Co):e&&e()}});var Ro=U((zt,No)=>{"use strict";var{hasOwnProperty:Ge}=Object.prototype,Te=Ht();Te.configure=Ht;Te.stringify=Te;Te.default=Te;zt.stringify=Te;zt.configure=Ht;No.exports=Te;var Qc=/[\u0000-\u001f\u0022\u005c\ud800-\udfff]/;function Ae(e){return e.length<5e3&&!Qc.test(e)?`"${e}"`:JSON.stringify(e)}function $t(e,t){if(e.length>200||t)return e.sort(t);for(let r=1;r<e.length;r++){let o=e[r],s=r;for(;s!==0&&e[s-1]>o;)e[s]=e[s-1],s--;e[s]=o}return e}var Zc=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(Object.getPrototypeOf(new Int8Array)),Symbol.toStringTag).get;function Wt(e){return Zc.call(e)!==void 0&&e.length!==0}function vo(e,t,r){e.length<r&&(r=e.length);let o=t===","?"":" ",s=`"0":${o}${e[0]}`;for(let l=1;l<r;l++)s+=`${t}"${l}":${o}${e[l]}`;return s}function ef(e){if(Ge.call(e,"circularValue")){let t=e.circularValue;if(typeof t=="string")return`"${t}"`;if(t==null)return t;if(t===Error||t===TypeError)return{toString(){throw new TypeError("Converting circular structure to JSON")}};throw new TypeError('The "circularValue" argument must be of type string or the value null or undefined')}return'"[Circular]"'}function nf(e){let t;if(Ge.call(e,"deterministic")&&(t=e.deterministic,typeof t!="boolean"&&typeof t!="function"))throw new TypeError('The "deterministic" argument must be of type boolean or comparator function');return t===void 0?!0:t}function tf(e,t){let r;if(Ge.call(e,t)&&(r=e[t],typeof r!="boolean"))throw new TypeError(`The "${t}" argument must be of type boolean`);return r===void 0?!0:r}function Io(e,t){let r;if(Ge.call(e,t)){if(r=e[t],typeof r!="number")throw new TypeError(`The "${t}" argument must be of type number`);if(!Number.isInteger(r))throw new TypeError(`The "${t}" argument must be an integer`);if(r<1)throw new RangeError(`The "${t}" argument must be >= 1`)}return r===void 0?1/0:r}function Ce(e){return e===1?"1 item":`${e} items`}function rf(e){let t=new Set;for(let r of e)(typeof r=="string"||typeof r=="number")&&t.add(String(r));return t}function of(e){if(Ge.call(e,"strict")){let t=e.strict;if(typeof t!="boolean")throw new TypeError('The "strict" argument must be of type boolean');if(t)return r=>{let o=`Object can not safely be stringified. Received type ${typeof r}`;throw typeof r!="function"&&(o+=` (${r.toString()})`),new Error(o)}}}function Ht(e){e={...e};let t=of(e);t&&(e.bigint===void 0&&(e.bigint=!1),"circularValue"in e||(e.circularValue=Error));let r=ef(e),o=tf(e,"bigint"),s=nf(e),l=typeof s=="function"?s:void 0,f=Io(e,"maximumDepth"),u=Io(e,"maximumBreadth");function a(x,p,C,v,P,N){let I=p[x];switch(typeof I=="object"&&I!==null&&typeof I.toJSON=="function"&&(I=I.toJSON(x)),I=v.call(p,x,I),typeof I){case"string":return Ae(I);case"object":{if(I===null)return"null";if(C.indexOf(I)!==-1)return r;let M="",W=",",Y=N;if(Array.isArray(I)){if(I.length===0)return"[]";if(f<C.length+1)return'"[Array]"';C.push(I),P!==""&&(N+=P,M+=`
7
+ ${N}`,W=`,
8
+ ${N}`);let G=Math.min(I.length,u),ee=0;for(;ee<G-1;ee++){let ie=a(String(ee),I,C,v,P,N);M+=ie!==void 0?ie:"null",M+=W}let z=a(String(ee),I,C,v,P,N);if(M+=z!==void 0?z:"null",I.length-1>u){let ie=I.length-u-1;M+=`${W}"... ${Ce(ie)} not stringified"`}return P!==""&&(M+=`
9
+ ${Y}`),C.pop(),`[${M}]`}let H=Object.keys(I),K=H.length;if(K===0)return"{}";if(f<C.length+1)return'"[Object]"';let q="",J="";P!==""&&(N+=P,W=`,
10
+ ${N}`,q=" ");let Z=Math.min(K,u);s&&!Wt(I)&&(H=$t(H,l)),C.push(I);for(let G=0;G<Z;G++){let ee=H[G],z=a(ee,I,C,v,P,N);z!==void 0&&(M+=`${J}${Ae(ee)}:${q}${z}`,J=W)}if(K>u){let G=K-u;M+=`${J}"...":${q}"${Ce(G)} not stringified"`,J=W}return P!==""&&J.length>1&&(M=`
11
+ ${N}${M}
12
+ ${Y}`),C.pop(),`{${M}}`}case"number":return isFinite(I)?String(I):t?t(I):"null";case"boolean":return I===!0?"true":"false";case"undefined":return;case"bigint":if(o)return String(I);default:return t?t(I):void 0}}function c(x,p,C,v,P,N){switch(typeof p=="object"&&p!==null&&typeof p.toJSON=="function"&&(p=p.toJSON(x)),typeof p){case"string":return Ae(p);case"object":{if(p===null)return"null";if(C.indexOf(p)!==-1)return r;let I=N,M="",W=",";if(Array.isArray(p)){if(p.length===0)return"[]";if(f<C.length+1)return'"[Array]"';C.push(p),P!==""&&(N+=P,M+=`
13
+ ${N}`,W=`,
14
+ ${N}`);let K=Math.min(p.length,u),q=0;for(;q<K-1;q++){let Z=c(String(q),p[q],C,v,P,N);M+=Z!==void 0?Z:"null",M+=W}let J=c(String(q),p[q],C,v,P,N);if(M+=J!==void 0?J:"null",p.length-1>u){let Z=p.length-u-1;M+=`${W}"... ${Ce(Z)} not stringified"`}return P!==""&&(M+=`
15
+ ${I}`),C.pop(),`[${M}]`}C.push(p);let Y="";P!==""&&(N+=P,W=`,
16
+ ${N}`,Y=" ");let H="";for(let K of v){let q=c(K,p[K],C,v,P,N);q!==void 0&&(M+=`${H}${Ae(K)}:${Y}${q}`,H=W)}return P!==""&&H.length>1&&(M=`
17
+ ${N}${M}
18
+ ${I}`),C.pop(),`{${M}}`}case"number":return isFinite(p)?String(p):t?t(p):"null";case"boolean":return p===!0?"true":"false";case"undefined":return;case"bigint":if(o)return String(p);default:return t?t(p):void 0}}function h(x,p,C,v,P){switch(typeof p){case"string":return Ae(p);case"object":{if(p===null)return"null";if(typeof p.toJSON=="function"){if(p=p.toJSON(x),typeof p!="object")return h(x,p,C,v,P);if(p===null)return"null"}if(C.indexOf(p)!==-1)return r;let N=P;if(Array.isArray(p)){if(p.length===0)return"[]";if(f<C.length+1)return'"[Array]"';C.push(p),P+=v;let q=`
19
+ ${P}`,J=`,
20
+ ${P}`,Z=Math.min(p.length,u),G=0;for(;G<Z-1;G++){let z=h(String(G),p[G],C,v,P);q+=z!==void 0?z:"null",q+=J}let ee=h(String(G),p[G],C,v,P);if(q+=ee!==void 0?ee:"null",p.length-1>u){let z=p.length-u-1;q+=`${J}"... ${Ce(z)} not stringified"`}return q+=`
21
+ ${N}`,C.pop(),`[${q}]`}let I=Object.keys(p),M=I.length;if(M===0)return"{}";if(f<C.length+1)return'"[Object]"';P+=v;let W=`,
22
+ ${P}`,Y="",H="",K=Math.min(M,u);Wt(p)&&(Y+=vo(p,W,u),I=I.slice(p.length),K-=p.length,H=W),s&&(I=$t(I,l)),C.push(p);for(let q=0;q<K;q++){let J=I[q],Z=h(J,p[J],C,v,P);Z!==void 0&&(Y+=`${H}${Ae(J)}: ${Z}`,H=W)}if(M>u){let q=M-u;Y+=`${H}"...": "${Ce(q)} not stringified"`,H=W}return H!==""&&(Y=`
23
+ ${P}${Y}
24
+ ${N}`),C.pop(),`{${Y}}`}case"number":return isFinite(p)?String(p):t?t(p):"null";case"boolean":return p===!0?"true":"false";case"undefined":return;case"bigint":if(o)return String(p);default:return t?t(p):void 0}}function d(x,p,C){switch(typeof p){case"string":return Ae(p);case"object":{if(p===null)return"null";if(typeof p.toJSON=="function"){if(p=p.toJSON(x),typeof p!="object")return d(x,p,C);if(p===null)return"null"}if(C.indexOf(p)!==-1)return r;let v="",P=p.length!==void 0;if(P&&Array.isArray(p)){if(p.length===0)return"[]";if(f<C.length+1)return'"[Array]"';C.push(p);let Y=Math.min(p.length,u),H=0;for(;H<Y-1;H++){let q=d(String(H),p[H],C);v+=q!==void 0?q:"null",v+=","}let K=d(String(H),p[H],C);if(v+=K!==void 0?K:"null",p.length-1>u){let q=p.length-u-1;v+=`,"... ${Ce(q)} not stringified"`}return C.pop(),`[${v}]`}let N=Object.keys(p),I=N.length;if(I===0)return"{}";if(f<C.length+1)return'"[Object]"';let M="",W=Math.min(I,u);P&&Wt(p)&&(v+=vo(p,",",u),N=N.slice(p.length),W-=p.length,M=","),s&&(N=$t(N,l)),C.push(p);for(let Y=0;Y<W;Y++){let H=N[Y],K=d(H,p[H],C);K!==void 0&&(v+=`${M}${Ae(H)}:${K}`,M=",")}if(I>u){let Y=I-u;v+=`${M}"...":"${Ce(Y)} not stringified"`}return C.pop(),`{${v}}`}case"number":return isFinite(p)?String(p):t?t(p):"null";case"boolean":return p===!0?"true":"false";case"undefined":return;case"bigint":if(o)return String(p);default:return t?t(p):void 0}}function A(x,p,C){if(arguments.length>1){let v="";if(typeof C=="number"?v=" ".repeat(Math.min(C,10)):typeof C=="string"&&(v=C.slice(0,10)),p!=null){if(typeof p=="function")return a("",{"":x},[],p,v,"");if(Array.isArray(p))return c("",x,[],rf(p),v,"")}if(v.length!==0)return h("",x,[],v,"")}return d("",x,[])}return A}});var jo=U((gh,Do)=>{"use strict";var Kt=Symbol.for("pino.metadata"),{DEFAULT_LEVELS:Mo}=_n(),sf=Mo.info;function lf(e,t){e=e||[],t=t||{dedupe:!1};let r=Object.create(Mo);r.silent=1/0,t.levels&&typeof t.levels=="object"&&Object.keys(t.levels).forEach(d=>{r[d]=t.levels[d]});let o={write:s,add:u,remove:a,emit:l,flushSync:f,end:c,minLevel:0,lastId:0,streams:[],clone:h,[Kt]:!0,streamLevels:r};return Array.isArray(e)?e.forEach(u,o):u.call(o,e),e=null,o;function s(d){let A,x=this.lastLevel,{streams:p}=this,C=0,v;for(let P=uf(p.length,t.dedupe);ff(P,p.length,t.dedupe);P=cf(P,t.dedupe))if(A=p[P],A.level<=x){if(C!==0&&C!==A.level)break;if(v=A.stream,v[Kt]){let{lastTime:N,lastMsg:I,lastObj:M,lastLogger:W}=this;v.lastLevel=x,v.lastTime=N,v.lastMsg=I,v.lastObj=M,v.lastLogger=W}v.write(d),t.dedupe&&(C=A.level)}else if(!t.dedupe)break}function l(...d){for(let{stream:A}of this.streams)typeof A.emit=="function"&&A.emit(...d)}function f(){for(let{stream:d}of this.streams)typeof d.flushSync=="function"&&d.flushSync()}function u(d){if(!d)return o;let A=typeof d.write=="function"||d.stream,x=d.write?d:d.stream;if(!A)throw Error("stream object needs to implement either StreamEntry or DestinationStream interface");let{streams:p,streamLevels:C}=this,v;typeof d.levelVal=="number"?v=d.levelVal:typeof d.level=="string"?v=C[d.level]:typeof d.level=="number"?v=d.level:v=sf;let P={stream:x,level:v,levelVal:void 0,id:++o.lastId};return p.unshift(P),p.sort(Po),this.minLevel=p[0].level,o}function a(d){let{streams:A}=this,x=A.findIndex(p=>p.id===d);return x>=0&&(A.splice(x,1),A.sort(Po),this.minLevel=A.length>0?A[0].level:-1),o}function c(){for(let{stream:d}of this.streams)typeof d.flushSync=="function"&&d.flushSync(),d.end()}function h(d){let A=new Array(this.streams.length);for(let x=0;x<A.length;x++)A[x]={level:d,stream:this.streams[x].stream};return{write:s,add:u,remove:a,minLevel:d,streams:A,clone:h,emit:l,flushSync:f,[Kt]:!0}}}function Po(e,t){return e.level-t.level}function uf(e,t){return t?e-1:0}function cf(e,t){return t?e-1:e+1}function ff(e,t,r){return r?e>=0:e<t}Do.exports=lf});var Xo=U((mh,se)=>{"use strict";var af=Q("os"),Ko=at(),hf=ht(),df=gt(),Uo=Si(),pf=Lo(),Yo=Ne(),{configure:gf}=Ro(),{assertDefaultLevelFound:mf,mappings:Vo,genLsCache:yf,genLevelComparison:bf,assertLevelComparison:wf}=Mt(),{DEFAULT_LEVELS:Go,SORTING_ORDER:Sf}=_n(),{createArgsNormalizer:Af,asChindings:_f,buildSafeSonicBoom:Bo,buildFormatters:Ef,stringify:Ut,normalizeDestFileDescriptor:Fo,noop:xf}=An(),{version:Of}=Dt(),{chindingsSym:qo,redactFmtSym:Cf,serializersSym:$o,timeSym:Tf,timeSliceIndexSym:kf,streamSym:Lf,stringifySym:Wo,stringifySafeSym:Yt,stringifiersSym:Ho,setLevelSym:vf,endSym:If,formatOptsSym:Nf,messageKeySym:Rf,errorKeySym:Pf,nestedKeySym:Mf,mixinSym:Df,levelCompSym:jf,useOnlyCustomLevelsSym:Bf,formattersSym:zo,hooksSym:Ff,nestedKeyStrSym:qf,mixinMergeStrategySym:$f,msgPrefixSym:Wf}=Yo,{epochTime:Jo,nullTime:Hf}=Uo,{pid:zf}=process,Kf=af.hostname(),Uf=Ko.err,Yf={level:"info",levelComparison:Sf.ASC,levels:Go,messageKey:"msg",errorKey:"err",nestedKey:null,enabled:!0,base:{pid:zf,hostname:Kf},serializers:Object.assign(Object.create(null),{err:Uf}),formatters:Object.assign(Object.create(null),{bindings(e){return e},level(e,t){return{level:t}}}),hooks:{logMethod:void 0,streamWrite:void 0},timestamp:Jo,name:void 0,redact:null,customLevels:null,useOnlyCustomLevels:!1,depthLimit:5,edgeLimit:100},Vf=Af(Yf),Gf=Object.assign(Object.create(null),Ko);function Vt(...e){let t={},{opts:r,stream:o}=Vf(t,hf(),...e);r.level&&typeof r.level=="string"&&Go[r.level.toLowerCase()]!==void 0&&(r.level=r.level.toLowerCase());let{redact:s,crlf:l,serializers:f,timestamp:u,messageKey:a,errorKey:c,nestedKey:h,base:d,name:A,level:x,customLevels:p,levelComparison:C,mixin:v,mixinMergeStrategy:P,useOnlyCustomLevels:N,formatters:I,hooks:M,depthLimit:W,edgeLimit:Y,onChild:H,msgPrefix:K}=r,q=gf({maximumDepth:W,maximumBreadth:Y}),J=Ef(I.level,I.bindings,I.log),Z=Ut.bind({[Yt]:q}),G=s?df(s,Z):{},ee=s?{stringify:G[Cf]}:{stringify:Z},z="}"+(l?`\r
25
+ `:`
26
+ `),ie=_f.bind(null,{[qo]:"",[$o]:f,[Ho]:G,[Wo]:Ut,[Yt]:q,[zo]:J}),R="";d!==null&&(A===void 0?R=ie(d):R=ie(Object.assign({},d,{name:A})));let he=u instanceof Function?u:u?Jo:Hf,le=he().indexOf(":")+1;if(N&&!p)throw Error("customLevels is required if useOnlyCustomLevels is set true");if(v&&typeof v!="function")throw Error(`Unknown mixin type "${typeof v}" - expected "function"`);if(K&&typeof K!="string")throw Error(`Unknown msgPrefix type "${typeof K}" - expected "string"`);mf(x,p,N);let Le=Vo(p,N);typeof o.emit=="function"&&o.emit("message",{code:"PINO_CONFIG",config:{levels:Le,messageKey:a,errorKey:c}}),wf(C);let de=bf(C);return Object.assign(t,{levels:Le,[jf]:de,[Bf]:N,[Lf]:o,[Tf]:he,[kf]:le,[Wo]:Ut,[Yt]:q,[Ho]:G,[If]:z,[Nf]:ee,[Rf]:a,[Pf]:c,[Mf]:h,[qf]:h?`,${JSON.stringify(h)}:{`:"",[$o]:f,[Df]:v,[$f]:P,[qo]:R,[zo]:J,[Ff]:M,silent:xf,onChild:H,[Wf]:K}),Object.setPrototypeOf(t,pf()),yf(t),t[vf](x),t}se.exports=Vt;se.exports.destination=(e=process.stdout.fd)=>typeof e=="object"?(e.dest=Fo(e.dest||process.stdout.fd),Bo(e)):Bo({dest:Fo(e),minLength:0});se.exports.transport=Lt();se.exports.multistream=jo();se.exports.levels=Vo();se.exports.stdSerializers=Gf;se.exports.stdTimeFunctions=Object.assign({},Uo);se.exports.symbols=Yo;se.exports.version=Of;se.exports.default=Vt;se.exports.pino=Vt});function ls(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ne={},sn={},Se={},Zt;function ze(){if(Zt)return Se;Zt=1;function e(f){return typeof f>"u"||f===null}function t(f){return typeof f=="object"&&f!==null}function r(f){return Array.isArray(f)?f:e(f)?[]:[f]}function o(f,u){if(u){let a=Object.keys(u);for(let c=0,h=a.length;c<h;c+=1){let d=a[c];f[d]=u[d]}}return f}function s(f,u){let a="";for(let c=0;c<u;c+=1)a+=f;return a}function l(f){return f===0&&Number.NEGATIVE_INFINITY===1/f}return Se.isNothing=e,Se.isObject=t,Se.toArray=r,Se.repeat=s,Se.isNegativeZero=l,Se.extend=o,Se}var Rn,er;function Ke(){if(er)return Rn;er=1;function e(r,o){let s="",l=r.reason||"(unknown reason)";return r.mark?(r.mark.name&&(s+='in "'+r.mark.name+'" '),s+="("+(r.mark.line+1)+":"+(r.mark.column+1)+")",!o&&r.mark.snippet&&(s+=`
27
+
28
+ `+r.mark.snippet),l+" "+s):l}function t(r,o){Error.call(this),this.name="YAMLException",this.reason=r,this.mark=o,this.message=e(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t.prototype.toString=function(o){return this.name+": "+e(this,o)},Rn=t,Rn}var Pn,nr;function us(){if(nr)return Pn;nr=1;let e=ze();function t(s,l,f,u,a){let c="",h="",d=Math.floor(a/2)-1;return u-l>d&&(c=" ... ",l=u-d+c.length),f-u>d&&(h=" ...",f=u+d-h.length),{str:c+s.slice(l,f).replace(/\t/g,"\u2192")+h,pos:u-l+c.length}}function r(s,l){return e.repeat(" ",l-s.length)+s}function o(s,l){if(l=Object.create(l||null),!s.buffer)return null;l.maxLength||(l.maxLength=79),typeof l.indent!="number"&&(l.indent=1),typeof l.linesBefore!="number"&&(l.linesBefore=3),typeof l.linesAfter!="number"&&(l.linesAfter=2);let f=/\r?\n|\r|\0/g,u=[0],a=[],c,h=-1;for(;c=f.exec(s.buffer);)a.push(c.index),u.push(c.index+c[0].length),s.position<=c.index&&h<0&&(h=u.length-2);h<0&&(h=u.length-1);let d="",A=Math.min(s.line+l.linesAfter,a.length).toString().length,x=l.maxLength-(l.indent+A+3);for(let C=1;C<=l.linesBefore&&!(h-C<0);C++){let v=t(s.buffer,u[h-C],a[h-C],s.position-(u[h]-u[h-C]),x);d=e.repeat(" ",l.indent)+r((s.line-C+1).toString(),A)+" | "+v.str+`
29
+ `+d}let p=t(s.buffer,u[h],a[h],s.position,x);d+=e.repeat(" ",l.indent)+r((s.line+1).toString(),A)+" | "+p.str+`
30
+ `,d+=e.repeat("-",l.indent+A+3+p.pos)+`^
31
+ `;for(let C=1;C<=l.linesAfter&&!(h+C>=a.length);C++){let v=t(s.buffer,u[h+C],a[h+C],s.position-(u[h]-u[h+C]),x);d+=e.repeat(" ",l.indent)+r((s.line+C+1).toString(),A)+" | "+v.str+`
32
+ `}return d.replace(/\n$/,"")}return Pn=o,Pn}var Mn,tr;function te(){if(tr)return Mn;tr=1;let e=Ke(),t=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],r=["scalar","sequence","mapping"];function o(l){let f={};return l!==null&&Object.keys(l).forEach(function(u){l[u].forEach(function(a){f[String(a)]=u})}),f}function s(l,f){if(f=f||{},Object.keys(f).forEach(function(u){if(t.indexOf(u)===-1)throw new e('Unknown option "'+u+'" is met in definition of "'+l+'" YAML type.')}),this.options=f,this.tag=l,this.kind=f.kind||null,this.resolve=f.resolve||function(){return!0},this.construct=f.construct||function(u){return u},this.instanceOf=f.instanceOf||null,this.predicate=f.predicate||null,this.represent=f.represent||null,this.representName=f.representName||null,this.defaultStyle=f.defaultStyle||null,this.multi=f.multi||!1,this.styleAliases=o(f.styleAliases||null),r.indexOf(this.kind)===-1)throw new e('Unknown kind "'+this.kind+'" is specified for "'+l+'" YAML type.')}return Mn=s,Mn}var Dn,rr;function xr(){if(rr)return Dn;rr=1;let e=Ke(),t=te();function r(l,f){let u=[];return l[f].forEach(function(a){let c=u.length;u.forEach(function(h,d){h.tag===a.tag&&h.kind===a.kind&&h.multi===a.multi&&(c=d)}),u[c]=a}),u}function o(){let l={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function f(u){u.multi?(l.multi[u.kind].push(u),l.multi.fallback.push(u)):l[u.kind][u.tag]=l.fallback[u.tag]=u}for(let u=0,a=arguments.length;u<a;u+=1)arguments[u].forEach(f);return l}function s(l){return this.extend(l)}return s.prototype.extend=function(f){let u=[],a=[];if(f instanceof t)a.push(f);else if(Array.isArray(f))a=a.concat(f);else if(f&&(Array.isArray(f.implicit)||Array.isArray(f.explicit)))f.implicit&&(u=u.concat(f.implicit)),f.explicit&&(a=a.concat(f.explicit));else throw new e("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");u.forEach(function(h){if(!(h instanceof t))throw new e("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(h.loadKind&&h.loadKind!=="scalar")throw new e("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(h.multi)throw new e("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),a.forEach(function(h){if(!(h instanceof t))throw new e("Specified list of YAML types (or a single Type object) contains a non-Type object.")});let c=Object.create(s.prototype);return c.implicit=(this.implicit||[]).concat(u),c.explicit=(this.explicit||[]).concat(a),c.compiledImplicit=r(c,"implicit"),c.compiledExplicit=r(c,"explicit"),c.compiledTypeMap=o(c.compiledImplicit,c.compiledExplicit),c},Dn=s,Dn}var jn,ir;function Or(){if(ir)return jn;ir=1;let e=te();return jn=new e("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}}),jn}var Bn,or;function Cr(){if(or)return Bn;or=1;let e=te();return Bn=new e("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}}),Bn}var Fn,sr;function Tr(){if(sr)return Fn;sr=1;let e=te();return Fn=new e("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}}),Fn}var qn,lr;function kr(){if(lr)return qn;lr=1;let e=xr();return qn=new e({explicit:[Or(),Cr(),Tr()]}),qn}var $n,ur;function Lr(){if(ur)return $n;ur=1;let e=te();function t(s){if(s===null)return!0;let l=s.length;return l===1&&s==="~"||l===4&&(s==="null"||s==="Null"||s==="NULL")}function r(){return null}function o(s){return s===null}return $n=new e("tag:yaml.org,2002:null",{kind:"scalar",resolve:t,construct:r,predicate:o,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"}),$n}var Wn,cr;function vr(){if(cr)return Wn;cr=1;let e=te();function t(s){if(s===null)return!1;let l=s.length;return l===4&&(s==="true"||s==="True"||s==="TRUE")||l===5&&(s==="false"||s==="False"||s==="FALSE")}function r(s){return s==="true"||s==="True"||s==="TRUE"}function o(s){return Object.prototype.toString.call(s)==="[object Boolean]"}return Wn=new e("tag:yaml.org,2002:bool",{kind:"scalar",resolve:t,construct:r,predicate:o,represent:{lowercase:function(s){return s?"true":"false"},uppercase:function(s){return s?"TRUE":"FALSE"},camelcase:function(s){return s?"True":"False"}},defaultStyle:"lowercase"}),Wn}var Hn,fr;function Ir(){if(fr)return Hn;fr=1;let e=ze(),t=te();function r(c){return c>=48&&c<=57||c>=65&&c<=70||c>=97&&c<=102}function o(c){return c>=48&&c<=55}function s(c){return c>=48&&c<=57}function l(c){if(c===null)return!1;let h=c.length,d=0,A=!1;if(!h)return!1;let x=c[d];if((x==="-"||x==="+")&&(x=c[++d]),x==="0"){if(d+1===h)return!0;if(x=c[++d],x==="b"){for(d++;d<h;d++){if(x=c[d],x!=="0"&&x!=="1")return!1;A=!0}return A&&isFinite(f(c))}if(x==="x"){for(d++;d<h;d++){if(!r(c.charCodeAt(d)))return!1;A=!0}return A&&isFinite(f(c))}if(x==="o"){for(d++;d<h;d++){if(!o(c.charCodeAt(d)))return!1;A=!0}return A&&isFinite(f(c))}}for(;d<h;d++){if(!s(c.charCodeAt(d)))return!1;A=!0}return A?isFinite(f(c)):!1}function f(c){let h=c,d=1,A=h[0];if((A==="-"||A==="+")&&(A==="-"&&(d=-1),h=h.slice(1),A=h[0]),h==="0")return 0;if(A==="0"){if(h[1]==="b")return d*parseInt(h.slice(2),2);if(h[1]==="x")return d*parseInt(h.slice(2),16);if(h[1]==="o")return d*parseInt(h.slice(2),8)}return d*parseInt(h,10)}function u(c){return f(c)}function a(c){return Object.prototype.toString.call(c)==="[object Number]"&&c%1===0&&!e.isNegativeZero(c)}return Hn=new t("tag:yaml.org,2002:int",{kind:"scalar",resolve:l,construct:u,predicate:a,represent:{binary:function(c){return c>=0?"0b"+c.toString(2):"-0b"+c.toString(2).slice(1)},octal:function(c){return c>=0?"0o"+c.toString(8):"-0o"+c.toString(8).slice(1)},decimal:function(c){return c.toString(10)},hexadecimal:function(c){return c>=0?"0x"+c.toString(16).toUpperCase():"-0x"+c.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Hn}var zn,ar;function Nr(){if(ar)return zn;ar=1;let e=ze(),t=te(),r=new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),o=new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function s(c){return c===null||!r.test(c)?!1:isFinite(parseFloat(c,10))?!0:o.test(c)}function l(c){let h=c.toLowerCase(),d=h[0]==="-"?-1:1;return"+-".indexOf(h[0])>=0&&(h=h.slice(1)),h===".inf"?d===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:h===".nan"?NaN:d*parseFloat(h,10)}let f=/^[-+]?[0-9]+e/;function u(c,h){if(isNaN(c))switch(h){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===c)switch(h){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===c)switch(h){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(e.isNegativeZero(c))return"-0.0";let d=c.toString(10);return f.test(d)?d.replace("e",".e"):d}function a(c){return Object.prototype.toString.call(c)==="[object Number]"&&(c%1!==0||e.isNegativeZero(c))}return zn=new t("tag:yaml.org,2002:float",{kind:"scalar",resolve:s,construct:l,predicate:a,represent:u,defaultStyle:"lowercase"}),zn}var Kn,hr;function Rr(){return hr||(hr=1,Kn=kr().extend({implicit:[Lr(),vr(),Ir(),Nr()]})),Kn}var Un,dr;function Pr(){return dr||(dr=1,Un=Rr()),Un}var Yn,pr;function Mr(){if(pr)return Yn;pr=1;let e=te(),t=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),r=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function o(f){return f===null?!1:t.exec(f)!==null||r.exec(f)!==null}function s(f){let u=0,a=null,c=t.exec(f);if(c===null&&(c=r.exec(f)),c===null)throw new Error("Date resolve error");let h=+c[1],d=+c[2]-1,A=+c[3];if(!c[4])return new Date(Date.UTC(h,d,A));let x=+c[4],p=+c[5],C=+c[6];if(c[7]){for(u=c[7].slice(0,3);u.length<3;)u+="0";u=+u}if(c[9]){let P=+c[10],N=+(c[11]||0);a=(P*60+N)*6e4,c[9]==="-"&&(a=-a)}let v=new Date(Date.UTC(h,d,A,x,p,C,u));return a&&v.setTime(v.getTime()-a),v}function l(f){return f.toISOString()}return Yn=new e("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:o,construct:s,instanceOf:Date,represent:l}),Yn}var Vn,gr;function Dr(){if(gr)return Vn;gr=1;let e=te();function t(r){return r==="<<"||r===null}return Vn=new e("tag:yaml.org,2002:merge",{kind:"scalar",resolve:t}),Vn}var Gn,mr;function jr(){if(mr)return Gn;mr=1;let e=te(),t=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
33
+ \r`;function r(f){if(f===null)return!1;let u=0,a=f.length,c=t;for(let h=0;h<a;h++){let d=c.indexOf(f.charAt(h));if(!(d>64)){if(d<0)return!1;u+=6}}return u%8===0}function o(f){let u=f.replace(/[\r\n=]/g,""),a=u.length,c=t,h=0,d=[];for(let x=0;x<a;x++)x%4===0&&x&&(d.push(h>>16&255),d.push(h>>8&255),d.push(h&255)),h=h<<6|c.indexOf(u.charAt(x));let A=a%4*6;return A===0?(d.push(h>>16&255),d.push(h>>8&255),d.push(h&255)):A===18?(d.push(h>>10&255),d.push(h>>2&255)):A===12&&d.push(h>>4&255),new Uint8Array(d)}function s(f){let u="",a=0,c=f.length,h=t;for(let A=0;A<c;A++)A%3===0&&A&&(u+=h[a>>18&63],u+=h[a>>12&63],u+=h[a>>6&63],u+=h[a&63]),a=(a<<8)+f[A];let d=c%3;return d===0?(u+=h[a>>18&63],u+=h[a>>12&63],u+=h[a>>6&63],u+=h[a&63]):d===2?(u+=h[a>>10&63],u+=h[a>>4&63],u+=h[a<<2&63],u+=h[64]):d===1&&(u+=h[a>>2&63],u+=h[a<<4&63],u+=h[64],u+=h[64]),u}function l(f){return Object.prototype.toString.call(f)==="[object Uint8Array]"}return Gn=new e("tag:yaml.org,2002:binary",{kind:"scalar",resolve:r,construct:o,predicate:l,represent:s}),Gn}var Jn,yr;function Br(){if(yr)return Jn;yr=1;let e=te(),t=Object.prototype.hasOwnProperty,r=Object.prototype.toString;function o(l){if(l===null)return!0;let f={},u=l;for(let a=0,c=u.length;a<c;a+=1){let h=u[a],d=!1;if(r.call(h)!=="[object Object]")return!1;let A;for(A in h)if(t.call(h,A))if(!d)d=!0;else return!1;if(!d||t.call(f,A))return!1;Object.defineProperty(f,A,{value:!0})}return!0}function s(l){return l!==null?l:[]}return Jn=new e("tag:yaml.org,2002:omap",{kind:"sequence",resolve:o,construct:s}),Jn}var Xn,br;function Fr(){if(br)return Xn;br=1;let e=te(),t=Object.prototype.toString;function r(s){if(s===null)return!0;let l=s,f=new Array(l.length);for(let u=0,a=l.length;u<a;u+=1){let c=l[u];if(t.call(c)!=="[object Object]")return!1;let h=Object.keys(c);if(h.length!==1)return!1;f[u]=[h[0],c[h[0]]]}return!0}function o(s){if(s===null)return[];let l=s,f=new Array(l.length);for(let u=0,a=l.length;u<a;u+=1){let c=l[u],h=Object.keys(c);f[u]=[h[0],c[h[0]]]}return f}return Xn=new e("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:r,construct:o}),Xn}var Qn,wr;function qr(){if(wr)return Qn;wr=1;let e=te(),t=Object.prototype.hasOwnProperty;function r(s){if(s===null)return!0;let l=s;for(let f in l)if(t.call(l,f)&&l[f]!==null)return!1;return!0}function o(s){return s!==null?s:{}}return Qn=new e("tag:yaml.org,2002:set",{kind:"mapping",resolve:r,construct:o}),Qn}var Zn,Sr;function nt(){return Sr||(Sr=1,Zn=Pr().extend({implicit:[Mr(),Dr()],explicit:[jr(),Br(),Fr(),qr()]})),Zn}var Ar;function cs(){if(Ar)return sn;Ar=1;let e=ze(),t=Ke(),r=us(),o=nt(),s=Object.prototype.hasOwnProperty,l=1,f=2,u=3,a=4,c=1,h=2,d=3,A=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,x=/[\x85\u2028\u2029]/,p=/[,\[\]{}]/,C=/^(?:!|!!|![0-9A-Za-z-]+!)$/,v=/^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;function P(n){return Object.prototype.toString.call(n)}function N(n){return n===10||n===13}function I(n){return n===9||n===32}function M(n){return n===9||n===32||n===10||n===13}function W(n){return n===44||n===91||n===93||n===123||n===125}function Y(n){if(n>=48&&n<=57)return n-48;let g=n|32;return g>=97&&g<=102?g-97+10:-1}function H(n){return n===120?2:n===117?4:n===85?8:0}function K(n){return n>=48&&n<=57?n-48:-1}function q(n){switch(n){case 48:return"\0";case 97:return"\x07";case 98:return"\b";case 116:return" ";case 9:return" ";case 110:return`
34
+ `;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"\x85";case 95:return"\xA0";case 76:return"\u2028";case 80:return"\u2029";default:return""}}function J(n){return n<=65535?String.fromCharCode(n):String.fromCharCode((n-65536>>10)+55296,(n-65536&1023)+56320)}function Z(n,g,_){g==="__proto__"?Object.defineProperty(n,g,{configurable:!0,enumerable:!0,writable:!0,value:_}):n[g]=_}let G=new Array(256),ee=new Array(256);for(let n=0;n<256;n++)G[n]=q(n)?1:0,ee[n]=q(n);function z(n,g){this.input=n,this.filename=g.filename||null,this.schema=g.schema||o,this.onWarning=g.onWarning||null,this.legacy=g.legacy||!1,this.json=g.json||!1,this.listener=g.listener||null,this.maxDepth=typeof g.maxDepth=="number"?g.maxDepth:100,this.maxTotalMergeKeys=typeof g.maxTotalMergeKeys=="number"?g.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=n.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}function ie(n,g){let _={name:n.filename,buffer:n.input.slice(0,-1),position:n.position,line:n.line,column:n.position-n.lineStart};return _.snippet=r(_),new t(g,_)}function R(n,g){throw ie(n,g)}function he(n,g){n.onWarning&&n.onWarning.call(null,ie(n,g))}function le(n,g,_){let E=n.anchorMapTransactions;if(E.length!==0){let b=E[E.length-1];s.call(b,g)||(b[g]={existed:s.call(n.anchorMap,g),value:n.anchorMap[g]})}n.anchorMap[g]=_}function Le(n){n.anchorMapTransactions.push(Object.create(null))}function de(n){let g=n.anchorMapTransactions.pop(),_=n.anchorMapTransactions;if(_.length===0)return;let E=_[_.length-1],b=Object.keys(g);for(let i=0,m=b.length;i<m;i+=1){let y=b[i];s.call(E,y)||(E[y]=g[y])}}function kn(n){let g=n.anchorMapTransactions.pop(),_=Object.keys(g);for(let E=_.length-1;E>=0;E-=1){let b=g[_[E]];b.existed?n.anchorMap[_[E]]=b.value:delete n.anchorMap[_[E]]}}function je(n){return{position:n.position,line:n.line,lineStart:n.lineStart,lineIndent:n.lineIndent,firstTabInLine:n.firstTabInLine,tag:n.tag,anchor:n.anchor,kind:n.kind,result:n.result}}function ve(n,g){n.position=g.position,n.line=g.line,n.lineStart=g.lineStart,n.lineIndent=g.lineIndent,n.firstTabInLine=g.firstTabInLine,n.tag=g.tag,n.anchor=g.anchor,n.kind=g.kind,n.result=g.result}let Je={YAML:function(g,_,E){g.version!==null&&R(g,"duplication of %YAML directive"),E.length!==1&&R(g,"YAML directive accepts exactly one argument");let b=/^([0-9]+)\.([0-9]+)$/.exec(E[0]);b===null&&R(g,"ill-formed argument of the YAML directive");let i=parseInt(b[1],10),m=parseInt(b[2],10);i!==1&&R(g,"unacceptable YAML version of the document"),g.version=E[0],g.checkLineBreaks=m<2,m!==1&&m!==2&&he(g,"unsupported YAML version of the document")},TAG:function(g,_,E){let b;E.length!==2&&R(g,"TAG directive accepts exactly two arguments");let i=E[0];b=E[1],C.test(i)||R(g,"ill-formed tag handle (first argument) of the TAG directive"),s.call(g.tagMap,i)&&R(g,'there is a previously declared suffix for "'+i+'" tag handle'),v.test(b)||R(g,"ill-formed tag prefix (second argument) of the TAG directive");try{b=decodeURIComponent(b)}catch{R(g,"tag prefix is malformed: "+b)}g.tagMap[i]=b}};function re(n,g,_,E){if(g<_){let b=n.input.slice(g,_);if(E)for(let i=0,m=b.length;i<m;i+=1){let y=b.charCodeAt(i);y===9||y>=32&&y<=1114111||R(n,"expected valid JSON character")}else A.test(b)&&R(n,"the stream contains non-printable characters");n.result+=b}}function me(n){n.totalMergeKeys++,n.maxTotalMergeKeys!==-1&&n.totalMergeKeys>n.maxTotalMergeKeys&&R(n,"merge keys exceeded maxTotalMergeKeys ("+n.maxTotalMergeKeys+")")}function Be(n,g,_,E){e.isObject(_)||R(n,"cannot merge mappings; the provided source object is unacceptable"),me(n);let b=Object.keys(_);for(let i=0,m=b.length;i<m;i+=1){let y=b[i];me(n),s.call(g,y)||(Z(g,y,_[y]),E[y]=!0)}}function pe(n,g,_,E,b,i,m,y,O){if(Array.isArray(b)){b=Array.prototype.slice.call(b);for(let T=0,k=b.length;T<k;T+=1)Array.isArray(b[T])&&R(n,"nested arrays are not supported inside keys"),typeof b=="object"&&P(b[T])==="[object Object]"&&(b[T]="[object Object]")}if(typeof b=="object"&&P(b)==="[object Object]"&&(b="[object Object]"),b=String(b),g===null&&(g={}),E==="tag:yaml.org,2002:merge")if(Array.isArray(i)){i.length>100&&R(n,"abnormal merge sequence size");for(let T=0,k=i.length;T<k;T+=1)Be(n,g,i[T],_)}else Be(n,g,i,_);else!n.json&&!s.call(_,b)&&s.call(g,b)&&(n.line=m||n.line,n.lineStart=y||n.lineStart,n.position=O||n.position,R(n,"duplicated mapping key")),Z(g,b,i),delete _[b];return g}function Fe(n){let g=n.input.charCodeAt(n.position);g===10?n.position++:g===13?(n.position++,n.input.charCodeAt(n.position)===10&&n.position++):R(n,"a line break is expected"),n.line+=1,n.lineStart=n.position,n.firstTabInLine=-1}function X(n,g,_){let E=0,b=n.input.charCodeAt(n.position);for(;b!==0;){for(;I(b);)b===9&&n.firstTabInLine===-1&&(n.firstTabInLine=n.position),b=n.input.charCodeAt(++n.position);if(g&&b===35)do b=n.input.charCodeAt(++n.position);while(b!==10&&b!==13&&b!==0);if(N(b))for(Fe(n),b=n.input.charCodeAt(n.position),E++,n.lineIndent=0;b===32;)n.lineIndent++,b=n.input.charCodeAt(++n.position);else break}return _!==-1&&E!==0&&n.lineIndent<_&&he(n,"deficient indentation"),E}function fe(n){let g=n.position,_=n.input.charCodeAt(g);return!!((_===45||_===46)&&_===n.input.charCodeAt(g+1)&&_===n.input.charCodeAt(g+2)&&(g+=3,_=n.input.charCodeAt(g),_===0||M(_)))}function Ie(n,g){g===1?n.result+=" ":g>1&&(n.result+=e.repeat(`
35
+ `,g-1))}function Xe(n,g,_){let E,b,i,m,y,O,T=n.kind,k=n.result,S=n.input.charCodeAt(n.position);if(M(S)||W(S)||S===35||S===38||S===42||S===33||S===124||S===62||S===39||S===34||S===37||S===64||S===96)return!1;if(S===63||S===45){let L=n.input.charCodeAt(n.position+1);if(M(L)||_&&W(L))return!1}for(n.kind="scalar",n.result="",E=b=n.position,i=!1;S!==0;){if(S===58){let L=n.input.charCodeAt(n.position+1);if(M(L)||_&&W(L))break}else if(S===35){let L=n.input.charCodeAt(n.position-1);if(M(L))break}else{if(n.position===n.lineStart&&fe(n)||_&&W(S))break;if(N(S))if(m=n.line,y=n.lineStart,O=n.lineIndent,X(n,!1,-1),n.lineIndent>=g){i=!0,S=n.input.charCodeAt(n.position);continue}else{n.position=b,n.line=m,n.lineStart=y,n.lineIndent=O;break}}i&&(re(n,E,b,!1),Ie(n,n.line-m),E=b=n.position,i=!1),I(S)||(b=n.position+1),S=n.input.charCodeAt(++n.position)}return re(n,E,b,!1),n.result?!0:(n.kind=T,n.result=k,!1)}function qe(n,g){let _,E,b=n.input.charCodeAt(n.position);if(b!==39)return!1;for(n.kind="scalar",n.result="",n.position++,_=E=n.position;(b=n.input.charCodeAt(n.position))!==0;)if(b===39)if(re(n,_,n.position,!0),b=n.input.charCodeAt(++n.position),b===39)_=n.position,n.position++,E=n.position;else return!0;else N(b)?(re(n,_,E,!0),Ie(n,X(n,!1,g)),_=E=n.position):n.position===n.lineStart&&fe(n)?R(n,"unexpected end of the document within a single quoted scalar"):(n.position++,I(b)||(E=n.position));R(n,"unexpected end of the stream within a single quoted scalar")}function Qe(n,g){let _,E,b,i=n.input.charCodeAt(n.position);if(i!==34)return!1;for(n.kind="scalar",n.result="",n.position++,_=E=n.position;(i=n.input.charCodeAt(n.position))!==0;){if(i===34)return re(n,_,n.position,!0),n.position++,!0;if(i===92){if(re(n,_,n.position,!0),i=n.input.charCodeAt(++n.position),N(i))X(n,!1,g);else if(i<256&&G[i])n.result+=ee[i],n.position++;else if((b=H(i))>0){let m=b,y=0;for(;m>0;m--)i=n.input.charCodeAt(++n.position),(b=Y(i))>=0?y=(y<<4)+b:R(n,"expected hexadecimal character");n.result+=J(y),n.position++}else R(n,"unknown escape sequence");_=E=n.position}else N(i)?(re(n,_,E,!0),Ie(n,X(n,!1,g)),_=E=n.position):n.position===n.lineStart&&fe(n)?R(n,"unexpected end of the document within a double quoted scalar"):(n.position++,I(i)||(E=n.position))}R(n,"unexpected end of the stream within a double quoted scalar")}function Ze(n,g){let _=!0,E,b,i,m=n.tag,y,O=n.anchor,T,k,S,L,D=Object.create(null),j,B,F,$=n.input.charCodeAt(n.position);if($===91)T=93,L=!1,y=[];else if($===123)T=125,L=!0,y={};else return!1;for(n.anchor!==null&&le(n,n.anchor,y),$=n.input.charCodeAt(++n.position);$!==0;){if(X(n,!0,g),$=n.input.charCodeAt(n.position),$===T)return n.position++,n.tag=m,n.anchor=O,n.kind=L?"mapping":"sequence",n.result=y,!0;if(_?$===44&&R(n,"expected the node content, but found ','"):R(n,"missed comma between flow collection entries"),B=j=F=null,k=S=!1,$===63){let we=n.input.charCodeAt(n.position+1);M(we)&&(k=S=!0,n.position++,X(n,!0,g))}E=n.line,b=n.lineStart,i=n.position,be(n,g,l,!1,!0),B=n.tag,j=n.result,X(n,!0,g),$=n.input.charCodeAt(n.position),(S||n.line===E)&&$===58&&(k=!0,$=n.input.charCodeAt(++n.position),X(n,!0,g),be(n,g,l,!1,!0),F=n.result),L?pe(n,y,D,B,j,F,E,b,i):k?y.push(pe(n,null,D,B,j,F,E,b,i)):y.push(j),X(n,!0,g),$=n.input.charCodeAt(n.position),$===44?(_=!0,$=n.input.charCodeAt(++n.position)):_=!1}R(n,"unexpected end of the stream within a flow collection")}function ye(n,g){let _,E=c,b=!1,i=!1,m=g,y=0,O=!1,T,k=n.input.charCodeAt(n.position);if(k===124)_=!1;else if(k===62)_=!0;else return!1;for(n.kind="scalar",n.result="";k!==0;)if(k=n.input.charCodeAt(++n.position),k===43||k===45)c===E?E=k===43?d:h:R(n,"repeat of a chomping mode identifier");else if((T=K(k))>=0)T===0?R(n,"bad explicit indentation width of a block scalar; it cannot be less than one"):i?R(n,"repeat of an indentation width identifier"):(m=g+T-1,i=!0);else break;if(I(k)){do k=n.input.charCodeAt(++n.position);while(I(k));if(k===35)do k=n.input.charCodeAt(++n.position);while(!N(k)&&k!==0)}for(;k!==0;){for(Fe(n),n.lineIndent=0,k=n.input.charCodeAt(n.position);(!i||n.lineIndent<m)&&k===32;)n.lineIndent++,k=n.input.charCodeAt(++n.position);if(!i&&n.lineIndent>m&&(m=n.lineIndent),N(k)){y++;continue}if(!i&&m===0&&R(n,"missing indentation for block scalar"),n.lineIndent<m){E===d?n.result+=e.repeat(`
36
+ `,b?1+y:y):E===c&&b&&(n.result+=`
37
+ `);break}_?I(k)?(O=!0,n.result+=e.repeat(`
38
+ `,b?1+y:y)):O?(O=!1,n.result+=e.repeat(`
39
+ `,y+1)):y===0?b&&(n.result+=" "):n.result+=e.repeat(`
40
+ `,y):n.result+=e.repeat(`
41
+ `,b?1+y:y),b=!0,i=!0,y=0;let S=n.position;for(;!N(k)&&k!==0;)k=n.input.charCodeAt(++n.position);re(n,S,n.position,!1)}return!0}function en(n,g){let _=n.tag,E=n.anchor,b=[],i=!1;if(n.firstTabInLine!==-1)return!1;n.anchor!==null&&le(n,n.anchor,b);let m=n.input.charCodeAt(n.position);for(;m!==0&&(n.firstTabInLine!==-1&&(n.position=n.firstTabInLine,R(n,"tab characters must not be used in indentation")),m===45);){let y=n.input.charCodeAt(n.position+1);if(!M(y))break;if(i=!0,n.position++,X(n,!0,-1)&&n.lineIndent<=g){b.push(null),m=n.input.charCodeAt(n.position);continue}let O=n.line;if(be(n,g,u,!1,!0),b.push(n.result),X(n,!0,-1),m=n.input.charCodeAt(n.position),(n.line===O||n.lineIndent>g)&&m!==0)R(n,"bad indentation of a sequence entry");else if(n.lineIndent<g)break}return i?(n.tag=_,n.anchor=E,n.kind="sequence",n.result=b,!0):!1}function nn(n,g,_){let E,b,i,m,y=n.tag,O=n.anchor,T={},k=Object.create(null),S=null,L=null,D=null,j=!1,B=!1;if(n.firstTabInLine!==-1)return!1;n.anchor!==null&&le(n,n.anchor,T);let F=n.input.charCodeAt(n.position);for(;F!==0;){!j&&n.firstTabInLine!==-1&&(n.position=n.firstTabInLine,R(n,"tab characters must not be used in indentation"));let $=n.input.charCodeAt(n.position+1),we=n.line;if((F===63||F===58)&&M($))F===63?(j&&(pe(n,T,k,S,L,null,b,i,m),S=L=D=null),B=!0,j=!0,E=!0):j?(j=!1,E=!0):R(n,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),n.position+=1,F=$;else{if(b=n.line,i=n.lineStart,m=n.position,!be(n,_,f,!1,!0))break;if(n.line===we){for(F=n.input.charCodeAt(n.position);I(F);)F=n.input.charCodeAt(++n.position);if(F===58)F=n.input.charCodeAt(++n.position),M(F)||R(n,"a whitespace character is expected after the key-value separator within a block mapping"),j&&(pe(n,T,k,S,L,null,b,i,m),S=L=D=null),B=!0,j=!1,E=!1,S=n.tag,L=n.result;else if(B)R(n,"can not read an implicit mapping pair; a colon is missed");else return n.tag=y,n.anchor=O,!0}else if(B)R(n,"can not read a block mapping entry; a multiline key may not be an implicit key");else return n.tag=y,n.anchor=O,!0}if((n.line===we||n.lineIndent>g)&&(j&&(b=n.line,i=n.lineStart,m=n.position),be(n,g,a,!0,E)&&(j?L=n.result:D=n.result),j||(pe(n,T,k,S,L,D,b,i,m),S=L=D=null),X(n,!0,-1),F=n.input.charCodeAt(n.position)),(n.line===we||n.lineIndent>g)&&F!==0)R(n,"bad indentation of a mapping entry");else if(n.lineIndent<g)break}return j&&pe(n,T,k,S,L,null,b,i,m),B&&(n.tag=y,n.anchor=O,n.kind="mapping",n.result=T),B}function tn(n){let g=!1,_=!1,E,b,i=n.input.charCodeAt(n.position);if(i!==33)return!1;n.tag!==null&&R(n,"duplication of a tag property"),i=n.input.charCodeAt(++n.position),i===60?(g=!0,i=n.input.charCodeAt(++n.position)):i===33?(_=!0,E="!!",i=n.input.charCodeAt(++n.position)):E="!";let m=n.position;if(g){do i=n.input.charCodeAt(++n.position);while(i!==0&&i!==62);n.position<n.length?(b=n.input.slice(m,n.position),i=n.input.charCodeAt(++n.position)):R(n,"unexpected end of the stream within a verbatim tag")}else{for(;i!==0&&!M(i);)i===33&&(_?R(n,"tag suffix cannot contain exclamation marks"):(E=n.input.slice(m-1,n.position+1),C.test(E)||R(n,"named tag handle cannot contain such characters"),_=!0,m=n.position+1)),i=n.input.charCodeAt(++n.position);b=n.input.slice(m,n.position),p.test(b)&&R(n,"tag suffix cannot contain flow indicator characters")}b&&!v.test(b)&&R(n,"tag name cannot contain such characters: "+b);try{b=decodeURIComponent(b)}catch{R(n,"tag name is malformed: "+b)}return g?n.tag=b:s.call(n.tagMap,E)?n.tag=n.tagMap[E]+b:E==="!"?n.tag="!"+b:E==="!!"?n.tag="tag:yaml.org,2002:"+b:R(n,'undeclared tag handle "'+E+'"'),!0}function rn(n){let g=n.input.charCodeAt(n.position);if(g!==38)return!1;n.anchor!==null&&R(n,"duplication of an anchor property"),g=n.input.charCodeAt(++n.position);let _=n.position;for(;g!==0&&!M(g)&&!W(g);)g=n.input.charCodeAt(++n.position);return n.position===_&&R(n,"name of an anchor node must contain at least one character"),n.anchor=n.input.slice(_,n.position),!0}function Ln(n){let g=n.input.charCodeAt(n.position);if(g!==42)return!1;g=n.input.charCodeAt(++n.position);let _=n.position;for(;g!==0&&!M(g)&&!W(g);)g=n.input.charCodeAt(++n.position);n.position===_&&R(n,"name of an alias node must contain at least one character");let E=n.input.slice(_,n.position);return s.call(n.anchorMap,E)||R(n,'unidentified alias "'+E+'"'),n.result=n.anchorMap[E],X(n,!0,-1),!0}function on(n,g,_,E){let b=je(n);return Le(n),ve(n,g),n.tag=null,n.anchor=null,n.kind=null,n.result=null,nn(n,_,E)&&n.kind==="mapping"?(de(n),!0):(kn(n),ve(n,b),!1)}function be(n,g,_,E,b){let i,m,y=1,O=!1,T=!1,k=null,S,L,D;n.depth>=n.maxDepth&&R(n,"nesting exceeded maxDepth ("+n.maxDepth+")"),n.depth+=1,n.listener!==null&&n.listener("open",n),n.tag=null,n.anchor=null,n.kind=null,n.result=null;let j=i=m=a===_||u===_;if(E&&X(n,!0,-1)&&(O=!0,n.lineIndent>g?y=1:n.lineIndent===g?y=0:n.lineIndent<g&&(y=-1)),y===1)for(;;){let B=n.input.charCodeAt(n.position),F=je(n);if(O&&(B===33&&n.tag!==null||B===38&&n.anchor!==null)||!tn(n)&&!rn(n))break;k===null&&(k=F),X(n,!0,-1)?(O=!0,m=j,n.lineIndent>g?y=1:n.lineIndent===g?y=0:n.lineIndent<g&&(y=-1)):m=!1}if(m&&(m=O||b),y===1||a===_)if(l===_||f===_?L=g:L=g+1,D=n.position-n.lineStart,y===1)if(m&&(en(n,D)||nn(n,D,L))||Ze(n,L))T=!0;else{let B=n.input.charCodeAt(n.position);k!==null&&j&&!m&&B!==124&&B!==62&&on(n,k,k.position-k.lineStart,L)||i&&ye(n,L)||qe(n,L)||Qe(n,L)?T=!0:Ln(n)?(T=!0,(n.tag!==null||n.anchor!==null)&&R(n,"alias node should not have any properties")):Xe(n,L,l===_)&&(T=!0,n.tag===null&&(n.tag="?")),n.anchor!==null&&le(n,n.anchor,n.result)}else y===0&&(T=m&&en(n,D));if(n.tag===null)n.anchor!==null&&le(n,n.anchor,n.result);else if(n.tag==="?"){n.result!==null&&n.kind!=="scalar"&&R(n,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+n.kind+'"');for(let B=0,F=n.implicitTypes.length;B<F;B+=1)if(S=n.implicitTypes[B],S.resolve(n.result)){n.result=S.construct(n.result),n.tag=S.tag,n.anchor!==null&&le(n,n.anchor,n.result);break}}else if(n.tag!=="!"){if(s.call(n.typeMap[n.kind||"fallback"],n.tag))S=n.typeMap[n.kind||"fallback"][n.tag];else{S=null;let B=n.typeMap.multi[n.kind||"fallback"];for(let F=0,$=B.length;F<$;F+=1)if(n.tag.slice(0,B[F].tag.length)===B[F].tag){S=B[F];break}}S||R(n,"unknown tag !<"+n.tag+">"),n.result!==null&&S.kind!==n.kind&&R(n,"unacceptable node kind for !<"+n.tag+'> tag; it should be "'+S.kind+'", not "'+n.kind+'"'),S.resolve(n.result,n.tag)?(n.result=S.construct(n.result,n.tag),n.anchor!==null&&le(n,n.anchor,n.result)):R(n,"cannot resolve a node with !<"+n.tag+"> explicit tag")}return n.listener!==null&&n.listener("close",n),n.depth-=1,n.tag!==null||n.anchor!==null||T}function vn(n){let g=n.position,_=!1,E;for(n.version=null,n.checkLineBreaks=n.legacy,n.tagMap=Object.create(null),n.anchorMap=Object.create(null);(E=n.input.charCodeAt(n.position))!==0&&(X(n,!0,-1),E=n.input.charCodeAt(n.position),!(n.lineIndent>0||E!==37));){_=!0,E=n.input.charCodeAt(++n.position);let b=n.position;for(;E!==0&&!M(E);)E=n.input.charCodeAt(++n.position);let i=n.input.slice(b,n.position),m=[];for(i.length<1&&R(n,"directive name must not be less than one character in length");E!==0;){for(;I(E);)E=n.input.charCodeAt(++n.position);if(E===35){do E=n.input.charCodeAt(++n.position);while(E!==0&&!N(E));break}if(N(E))break;for(b=n.position;E!==0&&!M(E);)E=n.input.charCodeAt(++n.position);m.push(n.input.slice(b,n.position))}E!==0&&Fe(n),s.call(Je,i)?Je[i](n,i,m):he(n,'unknown document directive "'+i+'"')}if(X(n,!0,-1),n.lineIndent===0&&n.input.charCodeAt(n.position)===45&&n.input.charCodeAt(n.position+1)===45&&n.input.charCodeAt(n.position+2)===45?(n.position+=3,X(n,!0,-1)):_&&R(n,"directives end mark is expected"),be(n,n.lineIndent-1,a,!1,!0),X(n,!0,-1),n.checkLineBreaks&&x.test(n.input.slice(g,n.position))&&he(n,"non-ASCII line breaks are interpreted as content"),n.documents.push(n.result),n.position===n.lineStart&&fe(n)){n.input.charCodeAt(n.position)===46&&(n.position+=3,X(n,!0,-1));return}n.position<n.length-1&&R(n,"end of the stream or a document separator is expected")}function $e(n,g){n=String(n),g=g||{},n.length!==0&&(n.charCodeAt(n.length-1)!==10&&n.charCodeAt(n.length-1)!==13&&(n+=`
42
+ `),n.charCodeAt(0)===65279&&(n=n.slice(1)));let _=new z(n,g),E=n.indexOf("\0");for(E!==-1&&(_.position=E,R(_,"null byte is not allowed in input")),_.input+="\0";_.input.charCodeAt(_.position)===32;)_.lineIndent+=1,_.position+=1;for(;_.position<_.length-1;)vn(_);return _.documents}function In(n,g,_){g!==null&&typeof g=="object"&&typeof _>"u"&&(_=g,g=null);let E=$e(n,_);if(typeof g!="function")return E;for(let b=0,i=E.length;b<i;b+=1)g(E[b])}function Nn(n,g){let _=$e(n,g);if(_.length!==0){if(_.length===1)return _[0];throw new t("expected a single document in the stream, but found more")}}return sn.loadAll=In,sn.load=Nn,sn}var et={},_r;function fs(){if(_r)return et;_r=1;let e=ze(),t=Ke(),r=nt(),o=Object.prototype.toString,s=Object.prototype.hasOwnProperty,l=65279,f=9,u=10,a=13,c=32,h=33,d=34,A=35,x=37,p=38,C=39,v=42,P=44,N=45,I=58,M=61,W=62,Y=63,H=64,K=91,q=93,J=96,Z=123,G=124,ee=125,z={};z[0]="\\0",z[7]="\\a",z[8]="\\b",z[9]="\\t",z[10]="\\n",z[11]="\\v",z[12]="\\f",z[13]="\\r",z[27]="\\e",z[34]='\\"',z[92]="\\\\",z[133]="\\N",z[160]="\\_",z[8232]="\\L",z[8233]="\\P";let ie=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],R=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function he(i,m){if(m===null)return{};let y={},O=Object.keys(m);for(let T=0,k=O.length;T<k;T+=1){let S=O[T],L=String(m[S]);S.slice(0,2)==="!!"&&(S="tag:yaml.org,2002:"+S.slice(2));let D=i.compiledTypeMap.fallback[S];D&&s.call(D.styleAliases,L)&&(L=D.styleAliases[L]),y[S]=L}return y}function le(i){let m,y,O=i.toString(16).toUpperCase();if(i<=255)m="x",y=2;else if(i<=65535)m="u",y=4;else if(i<=4294967295)m="U",y=8;else throw new t("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+m+e.repeat("0",y-O.length)+O}let Le=1,de=2;function kn(i){this.schema=i.schema||r,this.indent=Math.max(1,i.indent||2),this.noArrayIndent=i.noArrayIndent||!1,this.skipInvalid=i.skipInvalid||!1,this.flowLevel=e.isNothing(i.flowLevel)?-1:i.flowLevel,this.styleMap=he(this.schema,i.styles||null),this.sortKeys=i.sortKeys||!1,this.lineWidth=i.lineWidth||80,this.noRefs=i.noRefs||!1,this.noCompatMode=i.noCompatMode||!1,this.condenseFlow=i.condenseFlow||!1,this.quotingType=i.quotingType==='"'?de:Le,this.forceQuotes=i.forceQuotes||!1,this.replacer=typeof i.replacer=="function"?i.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function je(i,m){let y=e.repeat(" ",m),O=0,T="",k=i.length;for(;O<k;){let S,L=i.indexOf(`
43
+ `,O);L===-1?(S=i.slice(O),O=k):(S=i.slice(O,L+1),O=L+1),S.length&&S!==`
44
+ `&&(T+=y),T+=S}return T}function ve(i,m){return`
45
+ `+e.repeat(" ",i.indent*m)}function Je(i,m){for(let y=0,O=i.implicitTypes.length;y<O;y+=1)if(i.implicitTypes[y].resolve(m))return!0;return!1}function re(i){return i===c||i===f}function me(i){return i>=32&&i<=126||i>=161&&i<=55295&&i!==8232&&i!==8233||i>=57344&&i<=65533&&i!==l||i>=65536&&i<=1114111}function Be(i){return me(i)&&i!==l&&i!==a&&i!==u}function pe(i,m,y){let O=Be(i),T=O&&!re(i);return(y?O:O&&i!==P&&i!==K&&i!==q&&i!==Z&&i!==ee)&&i!==A&&!(m===I&&!T)||Be(m)&&!re(m)&&i===A||m===I&&T}function Fe(i){return me(i)&&i!==l&&!re(i)&&i!==N&&i!==Y&&i!==I&&i!==P&&i!==K&&i!==q&&i!==Z&&i!==ee&&i!==A&&i!==p&&i!==v&&i!==h&&i!==G&&i!==M&&i!==W&&i!==C&&i!==d&&i!==x&&i!==H&&i!==J}function X(i){return!re(i)&&i!==I}function fe(i,m){let y=i.charCodeAt(m),O;return y>=55296&&y<=56319&&m+1<i.length&&(O=i.charCodeAt(m+1),O>=56320&&O<=57343)?(y-55296)*1024+O-56320+65536:y}function Ie(i){return/^\n* /.test(i)}let Xe=1,qe=2,Qe=3,Ze=4,ye=5;function en(i,m,y,O,T,k,S,L){let D,j=0,B=null,F=!1,$=!1,we=O!==-1,We=-1,He=Fe(fe(i,0))&&X(fe(i,i.length-1));if(m||S)for(D=0;D<i.length;j>=65536?D+=2:D++){if(j=fe(i,D),!me(j))return ye;He=He&&pe(j,B,L),B=j}else{for(D=0;D<i.length;j>=65536?D+=2:D++){if(j=fe(i,D),j===u)F=!0,we&&($=$||D-We-1>O&&i[We+1]!==" ",We=D);else if(!me(j))return ye;He=He&&pe(j,B,L),B=j}$=$||we&&D-We-1>O&&i[We+1]!==" "}return!F&&!$?He&&!S&&!T(i)?Xe:k===de?ye:qe:y>9&&Ie(i)?ye:S?k===de?ye:qe:$?Ze:Qe}function nn(i,m,y,O,T){i.dump=(function(){if(m.length===0)return i.quotingType===de?'""':"''";if(!i.noCompatMode&&(ie.indexOf(m)!==-1||R.test(m)))return i.quotingType===de?'"'+m+'"':"'"+m+"'";let k=i.indent*Math.max(1,y),S=i.lineWidth===-1?-1:Math.max(Math.min(i.lineWidth,40),i.lineWidth-k),L=O||i.flowLevel>-1&&y>=i.flowLevel;function D(j){return Je(i,j)}switch(en(m,L,i.indent,S,D,i.quotingType,i.forceQuotes&&!O,T)){case Xe:return m;case qe:return"'"+m.replace(/'/g,"''")+"'";case Qe:return"|"+tn(m,i.indent)+rn(je(m,k));case Ze:return">"+tn(m,i.indent)+rn(je(Ln(m,S),k));case ye:return'"'+be(m)+'"';default:throw new t("impossible error: invalid scalar style")}})()}function tn(i,m){let y=Ie(i)?String(m):"",O=i[i.length-1]===`
46
+ `,k=O&&(i[i.length-2]===`
47
+ `||i===`
48
+ `)?"+":O?"":"-";return y+k+`
49
+ `}function rn(i){return i[i.length-1]===`
50
+ `?i.slice(0,-1):i}function Ln(i,m){let y=/(\n+)([^\n]*)/g,O=(function(){let L=i.indexOf(`
51
+ `);return L=L!==-1?L:i.length,y.lastIndex=L,on(i.slice(0,L),m)})(),T=i[0]===`
52
+ `||i[0]===" ",k,S;for(;S=y.exec(i);){let L=S[1],D=S[2];k=D[0]===" ",O+=L+(!T&&!k&&D!==""?`
53
+ `:"")+on(D,m),T=k}return O}function on(i,m){if(i===""||i[0]===" ")return i;let y=/ [^ ]/g,O,T=0,k,S=0,L=0,D="";for(;O=y.exec(i);)L=O.index,L-T>m&&(k=S>T?S:L,D+=`
54
+ `+i.slice(T,k),T=k+1),S=L;return D+=`
55
+ `,i.length-T>m&&S>T?D+=i.slice(T,S)+`
56
+ `+i.slice(S+1):D+=i.slice(T),D.slice(1)}function be(i){let m="",y=0;for(let O=0;O<i.length;y>=65536?O+=2:O++){y=fe(i,O);let T=z[y];!T&&me(y)?(m+=i[O],y>=65536&&(m+=i[O+1])):m+=T||le(y)}return m}function vn(i,m,y){let O="",T=i.tag;for(let k=0,S=y.length;k<S;k+=1){let L=y[k];i.replacer&&(L=i.replacer.call(y,String(k),L)),(g(i,m,L,!1,!1)||typeof L>"u"&&g(i,m,null,!1,!1))&&(O!==""&&(O+=","+(i.condenseFlow?"":" ")),O+=i.dump)}i.tag=T,i.dump="["+O+"]"}function $e(i,m,y,O){let T="",k=i.tag;for(let S=0,L=y.length;S<L;S+=1){let D=y[S];i.replacer&&(D=i.replacer.call(y,String(S),D)),(g(i,m+1,D,!0,!0,!1,!0)||typeof D>"u"&&g(i,m+1,null,!0,!0,!1,!0))&&((!O||T!=="")&&(T+=ve(i,m)),i.dump&&u===i.dump.charCodeAt(0)?T+="-":T+="- ",T+=i.dump)}i.tag=k,i.dump=T||"[]"}function In(i,m,y){let O="",T=i.tag,k=Object.keys(y);for(let S=0,L=k.length;S<L;S+=1){let D="";O!==""&&(D+=", "),i.condenseFlow&&(D+='"');let j=k[S],B=y[j];i.replacer&&(B=i.replacer.call(y,j,B)),g(i,m,j,!1,!1)&&(i.dump.length>1024&&(D+="? "),D+=i.dump+(i.condenseFlow?'"':"")+":"+(i.condenseFlow?"":" "),g(i,m,B,!1,!1)&&(D+=i.dump,O+=D))}i.tag=T,i.dump="{"+O+"}"}function Nn(i,m,y,O){let T="",k=i.tag,S=Object.keys(y);if(i.sortKeys===!0)S.sort();else if(typeof i.sortKeys=="function")S.sort(i.sortKeys);else if(i.sortKeys)throw new t("sortKeys must be a boolean or a function");for(let L=0,D=S.length;L<D;L+=1){let j="";(!O||T!=="")&&(j+=ve(i,m));let B=S[L],F=y[B];if(i.replacer&&(F=i.replacer.call(y,B,F)),!g(i,m+1,B,!0,!0,!0))continue;let $=i.tag!==null&&i.tag!=="?"||i.dump&&i.dump.length>1024;$&&(i.dump&&u===i.dump.charCodeAt(0)?j+="?":j+="? "),j+=i.dump,$&&(j+=ve(i,m)),g(i,m+1,F,!0,$)&&(i.dump&&u===i.dump.charCodeAt(0)?j+=":":j+=": ",j+=i.dump,T+=j)}i.tag=k,i.dump=T||"{}"}function n(i,m,y){let O=y?i.explicitTypes:i.implicitTypes;for(let T=0,k=O.length;T<k;T+=1){let S=O[T];if((S.instanceOf||S.predicate)&&(!S.instanceOf||typeof m=="object"&&m instanceof S.instanceOf)&&(!S.predicate||S.predicate(m))){if(y?S.multi&&S.representName?i.tag=S.representName(m):i.tag=S.tag:i.tag="?",S.represent){let L=i.styleMap[S.tag]||S.defaultStyle,D;if(o.call(S.represent)==="[object Function]")D=S.represent(m,L);else if(s.call(S.represent,L))D=S.represent[L](m,L);else throw new t("!<"+S.tag+'> tag resolver accepts not "'+L+'" style');i.dump=D}return!0}}return!1}function g(i,m,y,O,T,k,S){i.tag=null,i.dump=y,n(i,y,!1)||n(i,y,!0);let L=o.call(i.dump),D=O;O&&(O=i.flowLevel<0||i.flowLevel>m);let j=L==="[object Object]"||L==="[object Array]",B,F;if(j&&(B=i.duplicates.indexOf(y),F=B!==-1),(i.tag!==null&&i.tag!=="?"||F||i.indent!==2&&m>0)&&(T=!1),F&&i.usedDuplicates[B])i.dump="*ref_"+B;else{if(j&&F&&!i.usedDuplicates[B]&&(i.usedDuplicates[B]=!0),L==="[object Object]")O&&Object.keys(i.dump).length!==0?(Nn(i,m,i.dump,T),F&&(i.dump="&ref_"+B+i.dump)):(In(i,m,i.dump),F&&(i.dump="&ref_"+B+" "+i.dump));else if(L==="[object Array]")O&&i.dump.length!==0?(i.noArrayIndent&&!S&&m>0?$e(i,m-1,i.dump,T):$e(i,m,i.dump,T),F&&(i.dump="&ref_"+B+i.dump)):(vn(i,m,i.dump),F&&(i.dump="&ref_"+B+" "+i.dump));else if(L==="[object String]")i.tag!=="?"&&nn(i,i.dump,m,k,D);else{if(L==="[object Undefined]")return!1;if(i.skipInvalid)return!1;throw new t("unacceptable kind of an object to dump "+L)}if(i.tag!==null&&i.tag!=="?"){let $=encodeURI(i.tag[0]==="!"?i.tag.slice(1):i.tag).replace(/!/g,"%21");i.tag[0]==="!"?$="!"+$:$.slice(0,18)==="tag:yaml.org,2002:"?$="!!"+$.slice(18):$="!<"+$+">",i.dump=$+" "+i.dump}}return!0}function _(i,m){let y=[],O=[];E(i,y,O);let T=O.length;for(let k=0;k<T;k+=1)m.duplicates.push(y[O[k]]);m.usedDuplicates=new Array(T)}function E(i,m,y){if(i!==null&&typeof i=="object"){let O=m.indexOf(i);if(O!==-1)y.indexOf(O)===-1&&y.push(O);else if(m.push(i),Array.isArray(i))for(let T=0,k=i.length;T<k;T+=1)E(i[T],m,y);else{let T=Object.keys(i);for(let k=0,S=T.length;k<S;k+=1)E(i[T[k]],m,y)}}}function b(i,m){m=m||{};let y=new kn(m);y.noRefs||_(i,y);let O=i;return y.replacer&&(O=y.replacer.call({"":O},"",O)),g(y,0,O,!0,!0)?y.dump+`
57
+ `:""}return et.dump=b,et}var Er;function as(){if(Er)return ne;Er=1;let e=cs(),t=fs();function r(o,s){return function(){throw new Error("Function yaml."+o+" is removed in js-yaml 4. Use yaml."+s+" instead, which is now safe by default.")}}return ne.Type=te(),ne.Schema=xr(),ne.FAILSAFE_SCHEMA=kr(),ne.JSON_SCHEMA=Rr(),ne.CORE_SCHEMA=Pr(),ne.DEFAULT_SCHEMA=nt(),ne.load=e.load,ne.loadAll=e.loadAll,ne.dump=t.dump,ne.YAMLException=Ke(),ne.types={binary:jr(),float:Nr(),map:Tr(),null:Lr(),pairs:Fr(),set:qr(),timestamp:Mr(),bool:vr(),int:Ir(),merge:Dr(),omap:Br(),seq:Cr(),str:Or()},ne.safeLoad=r("safeLoad","load"),ne.safeLoadAll=r("safeLoadAll","loadAll"),ne.safeDump=r("safeDump","dump"),ne}var hs=as(),ds=ls(hs),{Type:Ca,Schema:Ta,FAILSAFE_SCHEMA:ka,JSON_SCHEMA:La,CORE_SCHEMA:va,DEFAULT_SCHEMA:Ia,load:Na,loadAll:Ra,dump:Pa,YAMLException:Ma,types:Da,safeLoad:ja,safeLoadAll:Ba,safeDump:Fa}=ds;var Me=ss(Xo(),1);import{openSync as Jf,closeSync as Xf,mkdirSync as Qf,writeFileSync as Zf}from"fs";import{readdir as Zo,stat as ea,unlink as na}from"fs/promises";import{homedir as ta}from"os";import{join as ke,dirname as Jt,basename as ra}from"path";var _e=null,De=null,On=null;function ia(e){let t=e.logDir??ke(e.workDir??process.cwd(),".yukino","logs");return ke(t,`${e.sessionId}.jsonl`)}function oa(e){let t=Jt(e);for(;ra(t)!==".yukino";){let r=Jt(t);if(r===t)return;t=r}try{Zf(ke(t,".gitignore"),`*
58
+ `,{flag:"wx"})}catch{}}function Ah(e){return e.replace(/[^a-zA-Z0-9_-]/g,"_")||"unnamed"}function sa(e){if(typeof e!="object"||e===null)return;let t=Reflect.get(e,"flushSync");typeof t=="function"&&t.call(e)}var Gt="warn";function _h(e){_e&&la();let t=ia(e);Qf(Jt(t),{recursive:!0}),oa(t);let r=Jf(t,"a");On=r,De=Me.default.destination(r);let o={level:Gt,base:{sessionId:e.sessionId,mode:e.mode},serializers:{err:aa}};if(e.stdout?_e=(0,Me.default)(o,Me.default.multistream([{stream:De,level:Gt},{stream:process.stdout,level:Gt}])):_e=(0,Me.default)(o,De),!e.skipCleanup){let s=e.workDir??process.cwd();ua(s).catch(()=>{})}return _e}function Xt(){return _e}function la(){if(_e){try{_e.flush()}catch{}_e=null}if(De&&(sa(De),De=null),On!==null){try{Xf(On)}catch{}On=null}}var es=(0,Me.default)({level:"silent"}),Eh=new Proxy(es,{get(e,t,r){let s=Xt()??e,l=Reflect.get(s,t,r);return typeof l=="function"?l.bind(s):l},set(e,t,r){return Reflect.set(Xt()??e,t,r)}});function ns(e){let t=null,r=null,o=()=>{let s=Xt();return s?((t===null||r!==s)&&(t=s.child(e),r=s),t):null};return new Proxy(es,{get(s,l,f){let u=o()??s,a=Reflect.get(u,l,f);return typeof a=="function"?a.bind(u):a},set(s,l,f){return Reflect.set(o()??s,l,f)}})}async function Qo(e){let t;try{t=(await Zo(e)).filter(s=>s.endsWith(".jsonl"))}catch{return 0}let r=Date.now(),o=0;for(let s of t){let l=ke(e,s);try{let f=await ea(l);r-f.mtimeMs>720*60*60*1e3&&(await na(l),o++)}catch{}}return o}async function ua(e){let t=0;t+=await Qo(ke(e,".yukino","logs"));let r=ke(ta(),".yukino","teams"),o;try{o=await Zo(r)}catch{return t}for(let s of o)t+=await Qo(ke(r,s,"logs"));return t}var ca=5,fa=new Set(["name","message","stack","cause"]);function ts(e,t){let r={type:e.name,message:e.message,stack:e.stack},o=Object.getOwnPropertyDescriptor(e,"cause");if(o&&t<ca){let s=o.value;s instanceof Error?r.cause=ts(s,t+1):s!==void 0&&(r.cause={message:rs(s)})}for(let s of Object.keys(e)){if(fa.has(s))continue;let l=Object.getOwnPropertyDescriptor(e,s);if(l){let f=l.value;r[s]=f}}return r}function rs(e){if(typeof e=="string")return e;try{let t=JSON.stringify(e);if(t!==void 0)return t}catch{}try{return String(e)}catch{return Object.prototype.toString.call(e)}}function aa(e){return e instanceof Error?ts(e,0):{message:rs(e),value:e}}import{realpathSync as ha}from"fs";import{homedir as da}from"os";import{basename as pa,dirname as ga,isAbsolute as ma,join as ya,relative as ba,resolve as is,sep as wa}from"path";function kh(e){let t=is(e),r=[];for(;;)try{return ya(ha(t),...r)}catch(o){if(!(o instanceof Error)||!("code"in o)||o.code!=="ENOENT"&&o.code!=="ENOTDIR")throw o;let s=ga(t);if(s===t)return is(e);r.unshift(pa(t)),t=s}}function Lh(e,t){let r=ba(e,t);return r===""||r!==".."&&!r.startsWith(`..${wa}`)&&!ma(r)}function vh(e){let t=da();return e===t?"~":e.startsWith(`${t}/`)?`~/${e.slice(t.length+1)}`:e}var os=["Accomplishing","Architecting","Baking","Barking","Woofing","Howling","Be-bopping'","Befuddling","Boogieing","Boondoggling","Bootstrapping","Brewing","Calculating","Canoodling","Caramelizing","Cascading","Cerebrating","Choreographing","Churning","Coalescing","Cogitating","Combobulating","Composing","Computing","Concocting","Considering","Contemplating","Cooking","Crafting","Creating","Crunching","Crystallizing","Cultivating","Deciphering","Deliberating","Dilly-dallying","Discombobulating","Doodling","Elucidating","Enchanting","Envisioning","Fermenting","Finagling","Flamb\xE9ing","Flummoxing","Forging","Frolicking","Gallivanting","Garnishing","Generating","Germinating","Grooving","Harmonizing","Hatching","Honking","Ideating","Imagining","Improvising","Incubating","Inferring","Infusing","Kneading","Lollygagging","Manifesting","Marinating","Meandering","Metamorphosing","Mewing","Moonwalking","Moseying","Mulling","Musing","Noodling","Orbiting","Orchestrating","Percolating","Philosophizing","Pondering","Pontificating","Pouncing","Purring","Puzzling","Razzle-dazzling","Ruminating","Scampering","Simmering","Sketching","Spelunking","Spinning","Sprouting","Synthesizing","Thinking","Tinkering","Transfiguring","Transmuting","Undulating","Unfurling","Unravelling","Vibing","Wandering","Whisking","Working","Wrangling","Zigzagging"];function Ih(){return os[Math.floor(Math.random()*os.length)]}var _a=ns({module:"utils"});function Ea(e){if(typeof e=="string")return e;let t=[];for(let r of e)if(r.type==="text"&&typeof r.text=="string")t.push(r.text);else if(r.type==="image"&&Qt(r.source)){let o=r.source.type==="base64"&&typeof r.source.media_type=="string"?r.source.media_type:"image";t.push(`[Image: ${o}]`)}else if(r.type==="tool_reference"&&typeof r.tool_name=="string")t.push(`[Tool reference: ${r.tool_name}]`);else if(r.type==="search_result"){let o=typeof r.title=="string"?r.title:"search result",s=typeof r.source=="string"?` (${r.source})`:"",l=Array.isArray(r.content)?Ea(r.content.filter(Qt)):"";t.push(`${o}${s}${l?`
59
+ ${l}`:""}`)}else if(r.type==="document"){let o=typeof r.title=="string"?r.title:"document";t.push(`[Document: ${o}]`)}return t.join(`
60
+ `)}function Qt(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Rh(e){return Qt(e)?e:Array.isArray(e)?Object.fromEntries(e.entries()):{}}function xa(e){return typeof e=="string"?e:String(e)}function Ph(e){return e instanceof Error?e.message:xa(e)}function Mh(e){return typeof e=="object"&&e!==null}function Oa(e,t){return typeof e!="function"?e:function(...r){let o;try{o=t?e.call(t,...r):e.call(this,...r)}catch(s){_a.error({err:s},"utils operation failed");return}return o}}var Dh=Oa(JSON.parse,JSON);function jh(e,t,r){let o=e[t];if(typeof o=="number")return Math.floor(o);if(typeof o=="string"){let s=Number.parseInt(o,10);return Number.isNaN(s)?r:s}return r}function Bh(e){return Array.isArray(e)?e.filter(t=>typeof t=="string"):[]}function Cn(e,t,r){let o=e[t];return typeof o=="string"?o:r??""}function Fh(e,t,r){let o=e[t];return typeof o=="boolean"?o:r??!!o}function qh(e){return e.command?Tn(Cn(e,"command"),80):e.file_path?Tn(Cn(e,"file_path"),80):e.pattern?Tn(Cn(e,"pattern"),80):e.description?Tn(Cn(e,"description"),80):""}function Tn(e,t){return e.length>t?`${e.slice(0,t)}\u2026`:e}export{ds as a,Ah as b,_h as c,la as d,Eh as e,ns as f,kh as g,Lh as h,vh as i,Ih as j,Ea as k,Qt as l,Rh as m,xa as n,Ph as o,Mh as p,jh as q,Bh as r,Cn as s,Fh as t,qh as u};
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire as __yukinoCreateRequire } from "node:module";
3
+ const require = __yukinoCreateRequire(import.meta.url);
4
+ import{b as a,d as $e}from"./chunk-7MKA3SHV.js";var k,Wt=a(()=>{"use strict";(function(t){t[t.UNSET=0]="UNSET",t[t.OK=1]="OK",t[t.ERROR=2]="ERROR"})(k||(k={}))});var h,ut=a(()=>{"use strict";h="1.9.1"});function Fe(t){let e=new Set([t]),r=new Set,n=t.match(Ht);if(!n)return()=>!1;let o={major:+n[1],minor:+n[2],patch:+n[3],prerelease:n[4]};if(o.prerelease!=null)return function(c){return c===t};function s(u){return r.add(u),!1}function i(u){return e.add(u),!0}return function(c){if(e.has(c))return!0;if(r.has(c))return!1;let g=c.match(Ht);if(!g)return s(c);let _={major:+g[1],minor:+g[2],patch:+g[3],prerelease:g[4]};return _.prerelease!=null||o.major!==_.major?s(c):o.major===0?o.minor===_.minor&&o.patch<=_.patch?i(c):s(c):o.minor<=_.minor?i(c):s(c)}}var Ht,Qt,qt=a(()=>{"use strict";ut();Ht=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;Qt=Fe(h)});function m(t,e,r,n=!1){var o;let s=P[w]=(o=P[w])!==null&&o!==void 0?o:{version:h};if(!n&&s[t]){let i=new Error(`@opentelemetry/api: Attempted duplicate registration of API: ${t}`);return r.error(i.stack||i.message),!1}if(s.version!==h){let i=new Error(`@opentelemetry/api: Registration of version v${s.version} for ${t} does not match previously registered API v${h}`);return r.error(i.stack||i.message),!1}return s[t]=e,r.debug(`@opentelemetry/api: Registered a global for ${t} v${h}.`),!0}function f(t){var e,r;let n=(e=P[w])===null||e===void 0?void 0:e.version;if(!(!n||!Qt(n)))return(r=P[w])===null||r===void 0?void 0:r[t]}function d(t,e){e.debug(`@opentelemetry/api: Unregistering a global for ${t} v${h}.`);let r=P[w];r&&delete r[t]}var Xe,w,P,A=a(()=>{"use strict";ut();qt();Xe=h.split(".")[0],w=Symbol.for(`opentelemetry.js.api.${Xe}`),P=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof global=="object"?global:{}});function y(t,e,r){let n=f("diag");if(n)return n[t](e,...r)}var U,Jt=a(()=>{"use strict";A();U=class{constructor(e){this._namespace=e.namespace||"DiagComponentLogger"}debug(...e){return y("debug",this._namespace,e)}error(...e){return y("error",this._namespace,e)}info(...e){return y("info",this._namespace,e)}warn(...e){return y("warn",this._namespace,e)}verbose(...e){return y("verbose",this._namespace,e)}}});var p,j=a(()=>{"use strict";(function(t){t[t.NONE=0]="NONE",t[t.ERROR=30]="ERROR",t[t.WARN=50]="WARN",t[t.INFO=60]="INFO",t[t.DEBUG=70]="DEBUG",t[t.VERBOSE=80]="VERBOSE",t[t.ALL=9999]="ALL"})(p||(p={}))});function Zt(t,e){t<p.NONE?t=p.NONE:t>p.ALL&&(t=p.ALL),e=e||{};function r(n,o){let s=e[n];return typeof s=="function"&&t>=o?s.bind(e):function(){}}return{error:r("error",p.ERROR),warn:r("warn",p.WARN),info:r("info",p.INFO),debug:r("debug",p.DEBUG),verbose:r("verbose",p.VERBOSE)}}var te=a(()=>{"use strict";j()});var Ke,l,R=a(()=>{"use strict";Jt();te();j();A();Ke="diag",l=class t{static instance(){return this._instance||(this._instance=new t),this._instance}constructor(){function e(o){return function(...s){let i=f("diag");if(i)return i[o](...s)}}let r=this,n=(o,s={logLevel:p.INFO})=>{var i,u,c;if(o===r){let v=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");return r.error((i=v.stack)!==null&&i!==void 0?i:v.message),!1}typeof s=="number"&&(s={logLevel:s});let g=f("diag"),_=Zt((u=s.logLevel)!==null&&u!==void 0?u:p.INFO,o);if(g&&!s.suppressOverrideMessage){let v=(c=new Error().stack)!==null&&c!==void 0?c:"<failed to generate stacktrace>";g.warn(`Current logger will be overwritten from ${v}`),_.warn(`Current logger will overwrite one already registered from ${v}`)}return m("diag",_,r,!0)};r.setLogger=n,r.disable=()=>{d(Ke,r)},r.createComponentLogger=o=>new U(o),r.verbose=e("verbose"),r.debug=e("debug"),r.info=e("info"),r.warn=e("warn"),r.error=e("error")}}});var pt,ee=a(()=>{"use strict";R();pt=l.instance()});var $,re=a(()=>{"use strict";$=class t{constructor(e){this._entries=e?new Map(e):new Map}getEntry(e){let r=this._entries.get(e);if(r)return Object.assign({},r)}getAllEntries(){return Array.from(this._entries.entries())}setEntry(e,r){let n=new t(this._entries);return n._entries.set(e,r),n}removeEntry(e){let r=new t(this._entries);return r._entries.delete(e),r}removeEntries(...e){let r=new t(this._entries);for(let n of e)r._entries.delete(n);return r}clear(){return new t}}});var ne,oe=a(()=>{"use strict";ne=Symbol("BaggageEntryMetadata")});function ae(t={}){return new $(new Map(Object.entries(t)))}function se(t){return typeof t!="string"&&(Ye.error(`Cannot create baggage metadata from unknown type: ${typeof t}`),t=""),{__TYPE__:ne,toString(){return t}}}var Ye,ft=a(()=>{"use strict";R();re();oe();Ye=l.instance()});function O(t){return Symbol.for(t)}var gt,F,M=a(()=>{"use strict";gt=class t{constructor(e){let r=this;r._currentContext=e?new Map(e):new Map,r.getValue=n=>r._currentContext.get(n),r.setValue=(n,o)=>{let s=new t(r._currentContext);return s._currentContext.set(n,o),s},r.deleteValue=n=>{let o=new t(r._currentContext);return o._currentContext.delete(n),o}}},F=new gt});var _t,mt,X,ie=a(()=>{"use strict";_t=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}],mt={};if(typeof console<"u"){let t=["error","warn","info","debug","trace","log"];for(let e of t)typeof console[e]=="function"&&(mt[e]=console[e])}X=class{constructor(){function e(r){return function(...n){let o=mt[r];if(typeof o!="function"&&(o=mt.log),typeof o!="function"&&console&&(o=console[r],typeof o!="function"&&(o=console.log)),typeof o=="function")return o.apply(console,n)}}for(let r=0;r<_t.length;r++)this[_t[r].n]=e(_t[r].c)}}});function ce(){return Tt}var dt,T,xt,Et,ht,At,D,Rt,bt,Ot,Tt,ze,We,He,Qe,qe,Je,Ze,It=a(()=>{"use strict";dt=class{constructor(){}createGauge(e,r){return We}createHistogram(e,r){return He}createCounter(e,r){return ze}createUpDownCounter(e,r){return Qe}createObservableGauge(e,r){return Je}createObservableCounter(e,r){return qe}createObservableUpDownCounter(e,r){return Ze}addBatchObservableCallback(e,r){}removeBatchObservableCallback(e){}},T=class{},xt=class extends T{add(e,r){}},Et=class extends T{add(e,r){}},ht=class extends T{record(e,r){}},At=class extends T{record(e,r){}},D=class{addCallback(e){}removeCallback(e){}},Rt=class extends D{},bt=class extends D{},Ot=class extends D{},Tt=new dt,ze=new xt,We=new ht,He=new At,Qe=new Et,qe=new Rt,Je=new bt,Ze=new Ot});var K,le=a(()=>{"use strict";(function(t){t[t.INT=0]="INT",t[t.DOUBLE=1]="DOUBLE"})(K||(K={}))});var Y,z,St=a(()=>{"use strict";Y={get(t,e){if(t!=null)return t[e]},keys(t){return t==null?[]:Object.keys(t)}},z={set(t,e,r){t!=null&&(t[e]=r)}}});var W,ue=a(()=>{"use strict";M();W=class{active(){return F}with(e,r,n,...o){return r.call(n,...o)}bind(e,r){return r}enable(){return this}disable(){return this}}});var Nt,tr,x,V=a(()=>{"use strict";ue();A();R();Nt="context",tr=new W,x=class t{constructor(){}static getInstance(){return this._instance||(this._instance=new t),this._instance}setGlobalContextManager(e){return m(Nt,e,l.instance())}active(){return this._getContextManager().active()}with(e,r,n,...o){return this._getContextManager().with(e,r,n,...o)}bind(e,r){return this._getContextManager().bind(e,r)}_getContextManager(){return f(Nt)||tr}disable(){this._getContextManager().disable(),d(Nt,l.instance())}}});var I,Ct=a(()=>{"use strict";(function(t){t[t.NONE=0]="NONE",t[t.SAMPLED=1]="SAMPLED"})(I||(I={}))});var G,B,H,Q=a(()=>{"use strict";Ct();G="0000000000000000",B="00000000000000000000000000000000",H={traceId:B,spanId:G,traceFlags:I.NONE}});var E,q=a(()=>{"use strict";Q();E=class{constructor(e=H){this._spanContext=e}spanContext(){return this._spanContext}setAttribute(e,r){return this}setAttributes(e){return this}addEvent(e,r){return this}addLink(e){return this}addLinks(e){return this}setStatus(e){return this}updateName(e){return this}end(e){}isRecording(){return!1}recordException(e,r){}}});function J(t){return t.getValue(vt)||void 0}function pe(){return J(x.getInstance().active())}function L(t,e){return t.setValue(vt,e)}function fe(t){return t.deleteValue(vt)}function ge(t,e){return L(t,new E(e))}function Z(t){var e;return(e=J(t))===null||e===void 0?void 0:e.spanContext()}var vt,wt=a(()=>{"use strict";M();q();V();vt=O("OpenTelemetry Context Key SPAN")});function _e(t,e){if(typeof t!="string"||t.length!==e)return!1;let r=0;for(let n=0;n<t.length;n+=4)r+=(tt[t.charCodeAt(n)]|0)+(tt[t.charCodeAt(n+1)]|0)+(tt[t.charCodeAt(n+2)]|0)+(tt[t.charCodeAt(n+3)]|0);return r===e}function Pt(t){return _e(t,32)&&t!==B}function yt(t){return _e(t,16)&&t!==G}function S(t){return Pt(t.traceId)&&yt(t.spanId)}function me(t){return new E(t)}var tt,et=a(()=>{"use strict";Q();q();tt=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1])});function er(t){return t!==null&&typeof t=="object"&&"spanId"in t&&typeof t.spanId=="string"&&"traceId"in t&&typeof t.traceId=="string"&&"traceFlags"in t&&typeof t.traceFlags=="number"}var Mt,N,Dt=a(()=>{"use strict";V();wt();q();et();Mt=x.getInstance(),N=class{startSpan(e,r,n=Mt.active()){if(!!r?.root)return new E;let s=n&&Z(n);return er(s)&&S(s)?new E(s):new E}startActiveSpan(e,r,n,o){let s,i,u;if(arguments.length<2)return;arguments.length===2?u=r:arguments.length===3?(s=r,u=n):(s=r,i=n,u=o);let c=i??Mt.active(),g=this.startSpan(e,s,c),_=L(c,g);return Mt.with(_,u,void 0,g)}}});var rr,C,Vt=a(()=>{"use strict";Dt();rr=new N,C=class{constructor(e,r,n,o){this._provider=e,this.name=r,this.version=n,this.options=o}startSpan(e,r,n){return this._getTracer().startSpan(e,r,n)}startActiveSpan(e,r,n,o){let s=this._getTracer();return Reflect.apply(s.startActiveSpan,s,arguments)}_getTracer(){if(this._delegate)return this._delegate;let e=this._provider.getDelegateTracer(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):rr}}});var rt,de=a(()=>{"use strict";Dt();rt=class{getTracer(e,r,n){return new N}}});var nr,b,Gt=a(()=>{"use strict";Vt();de();nr=new rt,b=class{getTracer(e,r,n){var o;return(o=this.getDelegateTracer(e,r,n))!==null&&o!==void 0?o:new C(this,e,r,n)}getDelegate(){var e;return(e=this._delegate)!==null&&e!==void 0?e:nr}setDelegate(e){this._delegate=e}getDelegateTracer(e,r,n){var o;return(o=this._delegate)===null||o===void 0?void 0:o.getTracer(e,r,n)}}});var nt,xe=a(()=>{"use strict";(function(t){t[t.NOT_RECORD=0]="NOT_RECORD",t[t.RECORD=1]="RECORD",t[t.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"})(nt||(nt={}))});var ot,Ee=a(()=>{"use strict";(function(t){t[t.INTERNAL=0]="INTERNAL",t[t.SERVER=1]="SERVER",t[t.CLIENT=2]="CLIENT",t[t.PRODUCER=3]="PRODUCER",t[t.CONSUMER=4]="CONSUMER"})(ot||(ot={}))});function he(t){return sr.test(t)}function Ae(t){return ir.test(t)&&!cr.test(t)}var Bt,or,ar,sr,ir,cr,Re=a(()=>{"use strict";Bt="[_0-9a-z-*/]",or=`[a-z]${Bt}{0,255}`,ar=`[a-z0-9]${Bt}{0,240}@[a-z]${Bt}{0,13}`,sr=new RegExp(`^(?:${or}|${ar})$`),ir=/^[ -~]{0,255}[!-~]$/,cr=/,|=/});var be,lr,Oe,Te,at,Ie=a(()=>{"use strict";Re();be=32,lr=512,Oe=",",Te="=",at=class t{constructor(e){this._internalState=new Map,e&&this._parse(e)}set(e,r){let n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,r),n}unset(e){let r=this._clone();return r._internalState.delete(e),r}get(e){return this._internalState.get(e)}serialize(){return Array.from(this._internalState.keys()).reduceRight((e,r)=>(e.push(r+Te+this.get(r)),e),[]).join(Oe)}_parse(e){e.length>lr||(this._internalState=e.split(Oe).reduceRight((r,n)=>{let o=n.trim(),s=o.indexOf(Te);if(s!==-1){let i=o.slice(0,s),u=o.slice(s+1,n.length);he(i)&&Ae(u)&&r.set(i,u)}return r},new Map),this._internalState.size>be&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,be))))}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){let e=new t;return e._internalState=new Map(this._internalState),e}}});function Se(t){return new at(t)}var Ne=a(()=>{"use strict";Ie()});var Lt,Ce=a(()=>{"use strict";V();Lt=x.getInstance()});var kt,ve,we=a(()=>{"use strict";It();kt=class{getMeter(e,r,n){return Tt}},ve=new kt});var Ut,st,Pe=a(()=>{"use strict";we();A();R();Ut="metrics",st=class t{constructor(){}static getInstance(){return this._instance||(this._instance=new t),this._instance}setGlobalMeterProvider(e){return m(Ut,e,l.instance())}getMeterProvider(){return f(Ut)||ve}getMeter(e,r,n){return this.getMeterProvider().getMeter(e,r,n)}disable(){d(Ut,l.instance())}}});var jt,ye=a(()=>{"use strict";Pe();jt=st.getInstance()});var it,Me=a(()=>{"use strict";it=class{inject(e,r){}extract(e,r){return e}fields(){return[]}}});function Ft(t){return t.getValue($t)||void 0}function De(){return Ft(x.getInstance().active())}function Ve(t,e){return t.setValue($t,e)}function Ge(t){return t.deleteValue($t)}var $t,Be=a(()=>{"use strict";V();M();$t=O("OpenTelemetry Baggage Key")});var Xt,ur,ct,Le=a(()=>{"use strict";A();Me();St();Be();ft();R();Xt="propagation",ur=new it,ct=class t{constructor(){this.createBaggage=ae,this.getBaggage=Ft,this.getActiveBaggage=De,this.setBaggage=Ve,this.deleteBaggage=Ge}static getInstance(){return this._instance||(this._instance=new t),this._instance}setGlobalPropagator(e){return m(Xt,e,l.instance())}inject(e,r,n=z){return this._getGlobalPropagator().inject(e,r,n)}extract(e,r,n=Y){return this._getGlobalPropagator().extract(e,r,n)}fields(){return this._getGlobalPropagator().fields()}disable(){d(Xt,l.instance())}_getGlobalPropagator(){return f(Xt)||ur}}});var Kt,ke=a(()=>{"use strict";Le();Kt=ct.getInstance()});var Yt,lt,Ue=a(()=>{"use strict";A();Gt();et();wt();R();Yt="trace",lt=class t{constructor(){this._proxyTracerProvider=new b,this.wrapSpanContext=me,this.isSpanContextValid=S,this.deleteSpan=fe,this.getSpan=J,this.getActiveSpan=pe,this.getSpanContext=Z,this.setSpan=L,this.setSpanContext=ge}static getInstance(){return this._instance||(this._instance=new t),this._instance}setGlobalTracerProvider(e){let r=m(Yt,this._proxyTracerProvider,l.instance());return r&&this._proxyTracerProvider.setDelegate(e),r}getTracerProvider(){return f(Yt)||this._proxyTracerProvider}getTracer(e,r){return this.getTracerProvider().getTracer(e,r)}disable(){d(Yt,l.instance()),this._proxyTracerProvider=new b}}});var zt,je=a(()=>{"use strict";Ue();zt=lt.getInstance()});var fr={};$e(fr,{DiagConsoleLogger:()=>X,DiagLogLevel:()=>p,INVALID_SPANID:()=>G,INVALID_SPAN_CONTEXT:()=>H,INVALID_TRACEID:()=>B,ProxyTracer:()=>C,ProxyTracerProvider:()=>b,ROOT_CONTEXT:()=>F,SamplingDecision:()=>nt,SpanKind:()=>ot,SpanStatusCode:()=>k,TraceFlags:()=>I,ValueType:()=>K,baggageEntryMetadataFromString:()=>se,context:()=>Lt,createContextKey:()=>O,createNoopMeter:()=>ce,createTraceState:()=>Se,default:()=>pr,defaultTextMapGetter:()=>Y,defaultTextMapSetter:()=>z,diag:()=>pt,isSpanContextValid:()=>S,isValidSpanId:()=>yt,isValidTraceId:()=>Pt,metrics:()=>jt,propagation:()=>Kt,trace:()=>zt});var pr,gr=a(()=>{"use strict";ft();M();ie();j();It();le();St();Vt();Gt();xe();Ee();Wt();Ct();Ne();et();Q();Ce();ee();ye();ke();je();pr={context:Lt,diag:pt,metrics:jt,propagation:Kt,trace:zt}});export{p as a,se as b,O as c,F as d,ce as e,K as f,I as g,B as h,H as i,Pt as j,S as k,nt as l,ot as m,k as n,Lt as o,pt as p,jt as q,Kt as r,zt as s,fr as t,gr as u};
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire as __yukinoCreateRequire } from "node:module";
3
+ const require = __yukinoCreateRequire(import.meta.url);
4
+ import{b as a,d as O}from"./chunk-7MKA3SHV.js";var M={};O(M,{createSupportsColor:()=>l,default:()=>_});import R from"process";import C from"os";import T from"tty";function e(t,n=globalThis.Deno?globalThis.Deno.args:R.argv){let i=t.startsWith("-")?"":t.length===1?"-":"--",s=n.indexOf(i+t),u=n.indexOf("--");return s!==-1&&(u===-1||s<u)}function E(){if(!("FORCE_COLOR"in r))return;if(r.FORCE_COLOR==="true")return 1;if(r.FORCE_COLOR==="false")return 0;if(r.FORCE_COLOR.length===0)return 1;let t=Math.min(Number.parseInt(r.FORCE_COLOR,10),3);if([0,1,2,3].includes(t))return t}function m(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function p(t,{streamIsTTY:n,sniffFlags:i=!0}={}){let s=E();s!==void 0&&(c=s);let u=i?c:s;if(u===0)return 0;if(i){if(e("color=16m")||e("color=full")||e("color=truecolor"))return 3;if(e("color=256"))return 2}if("TF_BUILD"in r&&"AGENT_NAME"in r)return 1;if(t&&!n&&u===void 0)return 0;let f=u||0;if(r.TERM==="dumb")return f;if(R.platform==="win32"){let o=C.release().split(".");return Number(o[0])>=10&&Number(o[2])>=10586?Number(o[2])>=14931?3:2:1}if("CI"in r)return["GITHUB_ACTIONS","GITEA_ACTIONS","CIRCLECI"].some(o=>o in r)?3:["TRAVIS","APPVEYOR","GITLAB_CI","BUILDKITE","DRONE"].some(o=>o in r)||r.CI_NAME==="codeship"?1:f;if("TEAMCITY_VERSION"in r)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(r.TEAMCITY_VERSION)?1:0;if(r.COLORTERM==="truecolor"||r.TERM==="xterm-kitty"||r.TERM==="xterm-ghostty"||r.TERM==="wezterm")return 3;if("TERM_PROGRAM"in r){let o=Number.parseInt((r.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(r.TERM_PROGRAM){case"iTerm.app":return o>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(r.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(r.TERM)||"COLORTERM"in r?1:f}function l(t,n={}){let i=p(t,{streamIsTTY:t&&t.isTTY,...n});return m(i)}var r,c,I,_,A=a(()=>{"use strict";({env:r}=R);e("no-color")||e("no-colors")||e("color=false")||e("color=never")?c=0:(e("color")||e("colors")||e("color=true")||e("color=always"))&&(c=1);I={stdout:l({isTTY:T.isatty(1)}),stderr:l({isTTY:T.isatty(2)})},_=I});export{l as a,M as b,A as c};