faf-cli 7.3.0 → 7.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,146 +1,146 @@
1
- import{createRequire as C6}from"node:module";var A6=Object.defineProperty;var D=($,Z)=>()=>(Z||$((Z={exports:{}}).exports,Z),Z.exports);var N6=($)=>$;function w6($,Z){this[$]=N6.bind(null,Z)}var b6=($,Z)=>{for(var z in Z)A6($,z,{get:Z[z],enumerable:!0,configurable:!0,set:w6.bind(Z,z)})};var p0=C6(import.meta.url);var b=D((r6)=>{var w1=Symbol.for("yaml.alias"),H3=Symbol.for("yaml.document"),T$=Symbol.for("yaml.map"),G3=Symbol.for("yaml.pair"),b1=Symbol.for("yaml.scalar"),A$=Symbol.for("yaml.seq"),r=Symbol.for("yaml.node.type"),p6=($)=>!!$&&typeof $==="object"&&$[r]===w1,l6=($)=>!!$&&typeof $==="object"&&$[r]===H3,d6=($)=>!!$&&typeof $==="object"&&$[r]===T$,c6=($)=>!!$&&typeof $==="object"&&$[r]===G3,_3=($)=>!!$&&typeof $==="object"&&$[r]===b1,i6=($)=>!!$&&typeof $==="object"&&$[r]===A$;function Y3($){if($&&typeof $==="object")switch($[r]){case T$:case A$:return!0}return!1}function s6($){if($&&typeof $==="object")switch($[r]){case w1:case T$:case b1:case A$:return!0}return!1}var a6=($)=>(_3($)||Y3($))&&!!$.anchor;r6.ALIAS=w1;r6.DOC=H3;r6.MAP=T$;r6.NODE_TYPE=r;r6.PAIR=G3;r6.SCALAR=b1;r6.SEQ=A$;r6.hasAnchor=a6;r6.isAlias=p6;r6.isCollection=Y3;r6.isDocument=l6;r6.isMap=d6;r6.isNode=s6;r6.isPair=c6;r6.isScalar=_3;r6.isSeq=i6});var s0=D((BZ)=>{var f=b(),u=Symbol("break visit"),q3=Symbol("skip children"),i=Symbol("remove node");function N$($,Z){let z=B3(Z);if(f.isDocument($)){if(T0(null,$.contents,z,Object.freeze([$]))===i)$.contents=null}else T0(null,$,z,Object.freeze([]))}N$.BREAK=u;N$.SKIP=q3;N$.REMOVE=i;function T0($,Z,z,X){let U=V3($,Z,z,X);if(f.isNode(U)||f.isPair(U))return O3($,X,U),T0($,U,z,X);if(typeof U!=="symbol"){if(f.isCollection(Z)){X=Object.freeze(X.concat(Z));for(let Q=0;Q<Z.items.length;++Q){let J=T0(Q,Z.items[Q],z,X);if(typeof J==="number")Q=J-1;else if(J===u)return u;else if(J===i)Z.items.splice(Q,1),Q-=1}}else if(f.isPair(Z)){X=Object.freeze(X.concat(Z));let Q=T0("key",Z.key,z,X);if(Q===u)return u;else if(Q===i)Z.key=null;let J=T0("value",Z.value,z,X);if(J===u)return u;else if(J===i)Z.value=null}}return U}async function w$($,Z){let z=B3(Z);if(f.isDocument($)){if(await A0(null,$.contents,z,Object.freeze([$]))===i)$.contents=null}else await A0(null,$,z,Object.freeze([]))}w$.BREAK=u;w$.SKIP=q3;w$.REMOVE=i;async function A0($,Z,z,X){let U=await V3($,Z,z,X);if(f.isNode(U)||f.isPair(U))return O3($,X,U),A0($,U,z,X);if(typeof U!=="symbol"){if(f.isCollection(Z)){X=Object.freeze(X.concat(Z));for(let Q=0;Q<Z.items.length;++Q){let J=await A0(Q,Z.items[Q],z,X);if(typeof J==="number")Q=J-1;else if(J===u)return u;else if(J===i)Z.items.splice(Q,1),Q-=1}}else if(f.isPair(Z)){X=Object.freeze(X.concat(Z));let Q=await A0("key",Z.key,z,X);if(Q===u)return u;else if(Q===i)Z.key=null;let J=await A0("value",Z.value,z,X);if(J===u)return u;else if(J===i)Z.value=null}}return U}function B3($){if(typeof $==="object"&&($.Collection||$.Node||$.Value))return Object.assign({Alias:$.Node,Map:$.Node,Scalar:$.Node,Seq:$.Node},$.Value&&{Map:$.Value,Scalar:$.Value,Seq:$.Value},$.Collection&&{Map:$.Collection,Seq:$.Collection},$);return $}function V3($,Z,z,X){if(typeof z==="function")return z($,Z,X);if(f.isMap(Z))return z.Map?.($,Z,X);if(f.isSeq(Z))return z.Seq?.($,Z,X);if(f.isPair(Z))return z.Pair?.($,Z,X);if(f.isScalar(Z))return z.Scalar?.($,Z,X);if(f.isAlias(Z))return z.Alias?.($,Z,X);return}function O3($,Z,z){let X=Z[Z.length-1];if(f.isCollection(X))X.items[$]=z;else if(f.isPair(X))if($==="key")X.key=z;else X.value=z;else if(f.isDocument(X))X.contents=z;else{let U=f.isAlias(X)?"alias":"scalar";throw Error(`Cannot replace node with ${U} parent`)}}BZ.visit=N$;BZ.visitAsync=w$});var C1=D((DZ)=>{var W3=b(),WZ=s0(),IZ={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},LZ=($)=>$.replace(/[!,[\]{}]/g,(Z)=>IZ[Z]);class k{constructor($,Z){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},k.defaultYaml,$),this.tags=Object.assign({},k.defaultTags,Z)}clone(){let $=new k(this.yaml,this.tags);return $.docStart=this.docStart,$}atDocument(){let $=new k(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:k.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},k.defaultTags);break}return $}add($,Z){if(this.atNextDocument)this.yaml={explicit:k.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},k.defaultTags),this.atNextDocument=!1;let z=$.trim().split(/[ \t]+/),X=z.shift();switch(X){case"%TAG":{if(z.length!==2){if(Z(0,"%TAG directive should contain exactly two parts"),z.length<2)return!1}let[U,Q]=z;return this.tags[U]=Q,!0}case"%YAML":{if(this.yaml.explicit=!0,z.length!==1)return Z(0,"%YAML directive should contain exactly one part"),!1;let[U]=z;if(U==="1.1"||U==="1.2")return this.yaml.version=U,!0;else{let Q=/^\d+\.\d+$/.test(U);return Z(6,`Unsupported YAML version ${U}`,Q),!1}}default:return Z(0,`Unknown directive ${X}`,!0),!1}}tagName($,Z){if($==="!")return"!";if($[0]!=="!")return Z(`Not a valid tag: ${$}`),null;if($[1]==="<"){let Q=$.slice(2,-1);if(Q==="!"||Q==="!!")return Z(`Verbatim tags aren't resolved, so ${$} is invalid.`),null;if($[$.length-1]!==">")Z("Verbatim tags must end with a >");return Q}let[,z,X]=$.match(/^(.*!)([^!]*)$/s);if(!X)Z(`The ${$} tag has no suffix`);let U=this.tags[z];if(U)try{return U+decodeURIComponent(X)}catch(Q){return Z(String(Q)),null}if(z==="!")return $;return Z(`Could not resolve tag: ${$}`),null}tagString($){for(let[Z,z]of Object.entries(this.tags))if($.startsWith(z))return Z+LZ($.substring(z.length));return $[0]==="!"?$:`!<${$}>`}toString($){let Z=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],z=Object.entries(this.tags),X;if($&&z.length>0&&W3.isNode($.contents)){let U={};WZ.visit($.contents,(Q,J)=>{if(W3.isNode(J)&&J.tag)U[J.tag]=!0}),X=Object.keys(U)}else X=[];for(let[U,Q]of z){if(U==="!!"&&Q==="tag:yaml.org,2002:")continue;if(!$||X.some((J)=>J.startsWith(Q)))Z.push(`%TAG ${U} ${Q}`)}return Z.join(`
2
- `)}}k.defaultYaml={explicit:!1,version:"1.2"};k.defaultTags={"!!":"tag:yaml.org,2002:"};DZ.Directives=k});var b$=D((PZ)=>{var I3=b(),FZ=s0();function MZ($){if(/[\x00-\x19\s,[\]{}]/.test($)){let z=`Anchor must not contain whitespace or control characters: ${JSON.stringify($)}`;throw Error(z)}return!0}function L3($){let Z=new Set;return FZ.visit($,{Value(z,X){if(X.anchor)Z.add(X.anchor)}}),Z}function D3($,Z){for(let z=1;;++z){let X=`${$}${z}`;if(!Z.has(X))return X}}function KZ($,Z){let z=[],X=new Map,U=null;return{onAnchor:(Q)=>{z.push(Q),U??(U=L3($));let J=D3(Z,U);return U.add(J),J},setAnchors:()=>{for(let Q of z){let J=X.get(Q);if(typeof J==="object"&&J.anchor&&(I3.isScalar(J.node)||I3.isCollection(J.node)))J.node.anchor=J.anchor;else{let H=Error("Failed to resolve repeated object (this should not happen)");throw H.source=Q,H}}},sourceObjects:X}}PZ.anchorIsValid=MZ;PZ.anchorNames=L3;PZ.createNodeAnchors=KZ;PZ.findNewAnchor=D3});var j1=D((bZ)=>{function a0($,Z,z,X){if(X&&typeof X==="object")if(Array.isArray(X))for(let U=0,Q=X.length;U<Q;++U){let J=X[U],H=a0($,X,String(U),J);if(H===void 0)delete X[U];else if(H!==J)X[U]=H}else if(X instanceof Map)for(let U of Array.from(X.keys())){let Q=X.get(U),J=a0($,X,U,Q);if(J===void 0)X.delete(U);else if(J!==Q)X.set(U,J)}else if(X instanceof Set)for(let U of Array.from(X)){let Q=a0($,X,U,U);if(Q===void 0)X.delete(U);else if(Q!==U)X.delete(U),X.add(Q)}else for(let[U,Q]of Object.entries(X)){let J=a0($,X,U,Q);if(J===void 0)delete X[U];else if(J!==Q)X[U]=J}return $.call(Z,z,X)}bZ.applyReviver=a0});var $0=D((SZ)=>{var jZ=b();function R3($,Z,z){if(Array.isArray($))return $.map((X,U)=>R3(X,String(U),z));if($&&typeof $.toJSON==="function"){if(!z||!jZ.hasAnchor($))return $.toJSON(Z,z);let X={aliasCount:0,count:1,res:void 0};z.anchors.set($,X),z.onCreate=(Q)=>{X.res=Q,delete z.onCreate};let U=$.toJSON(Z,z);if(z.onCreate)z.onCreate(U);return U}if(typeof $==="bigint"&&!z?.keep)return Number($);return $}SZ.toJS=R3});var C$=D((yZ)=>{var gZ=j1(),F3=b(),fZ=$0();class M3{constructor($){Object.defineProperty(this,F3.NODE_TYPE,{value:$})}clone(){let $=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(this.range)$.range=this.range.slice();return $}toJS($,{mapAsMap:Z,maxAliasCount:z,onAnchor:X,reviver:U}={}){if(!F3.isDocument($))throw TypeError("A document argument is required");let Q={anchors:new Map,doc:$,keep:!0,mapAsMap:Z===!0,mapKeyWarned:!1,maxAliasCount:typeof z==="number"?z:100},J=fZ.toJS(this,"",Q);if(typeof X==="function")for(let{count:H,res:G}of Q.anchors.values())X(G,H);return typeof U==="function"?gZ.applyReviver(U,{"":J},"",J):J}}yZ.NodeBase=M3});var r0=D((mZ)=>{var xZ=b$(),uZ=s0(),N0=b(),kZ=C$(),vZ=$0();class K3 extends kZ.NodeBase{constructor($){super(N0.ALIAS);this.source=$,Object.defineProperty(this,"tag",{set(){throw Error("Alias nodes cannot have tags")}})}resolve($,Z){let z;if(Z?.aliasResolveCache)z=Z.aliasResolveCache;else if(z=[],uZ.visit($,{Node:(U,Q)=>{if(N0.isAlias(Q)||N0.hasAnchor(Q))z.push(Q)}}),Z)Z.aliasResolveCache=z;let X=void 0;for(let U of z){if(U===this)break;if(U.anchor===this.source)X=U}return X}toJSON($,Z){if(!Z)return{source:this.source};let{anchors:z,doc:X,maxAliasCount:U}=Z,Q=this.resolve(X,Z);if(!Q){let H=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(H)}let J=z.get(Q);if(!J)vZ.toJS(Q,null,Z),J=z.get(Q);if(J?.res===void 0)throw ReferenceError("This should not happen: Alias anchor was not resolved?");if(U>=0){if(J.count+=1,J.aliasCount===0)J.aliasCount=j$(X,Q,z);if(J.count*J.aliasCount>U)throw ReferenceError("Excessive alias count indicates a resource exhaustion attack")}return J.res}toString($,Z,z){let X=`*${this.source}`;if($){if(xZ.anchorIsValid(this.source),$.options.verifyAliasOrder&&!$.anchors.has(this.source)){let U=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(U)}if($.implicitKey)return`${X} `}return X}}function j$($,Z,z){if(N0.isAlias(Z)){let X=Z.resolve($),U=z&&X&&z.get(X);return U?U.count*U.aliasCount:0}else if(N0.isCollection(Z)){let X=0;for(let U of Z.items){let Q=j$($,U,z);if(Q>X)X=Q}return X}else if(N0.isPair(Z)){let X=j$($,Z.key,z),U=j$($,Z.value,z);return Math.max(X,U)}return 1}mZ.Alias=K3});var g=D((sZ)=>{var lZ=b(),dZ=C$(),cZ=$0(),iZ=($)=>!$||typeof $!=="function"&&typeof $!=="object";class q0 extends dZ.NodeBase{constructor($){super(lZ.SCALAR);this.value=$}toJSON($,Z){return Z?.keep?this.value:cZ.toJS(this.value,$,Z)}toString(){return String(this.value)}}q0.BLOCK_FOLDED="BLOCK_FOLDED";q0.BLOCK_LITERAL="BLOCK_LITERAL";q0.PLAIN="PLAIN";q0.QUOTE_DOUBLE="QUOTE_DOUBLE";q0.QUOTE_SINGLE="QUOTE_SINGLE";sZ.Scalar=q0;sZ.isScalarValue=iZ});var n0=D(($4)=>{var nZ=r0(),B0=b(),P3=g(),oZ="tag:yaml.org,2002:";function tZ($,Z,z){if(Z){let X=z.filter((Q)=>Q.tag===Z),U=X.find((Q)=>!Q.format)??X[0];if(!U)throw Error(`Tag ${Z} not found`);return U}return z.find((X)=>X.identify?.($)&&!X.format)}function eZ($,Z,z){if(B0.isDocument($))$=$.contents;if(B0.isNode($))return $;if(B0.isPair($)){let Y=z.schema[B0.MAP].createNode?.(z.schema,null,z);return Y.items.push($),Y}if($ instanceof String||$ instanceof Number||$ instanceof Boolean||typeof BigInt<"u"&&$ instanceof BigInt)$=$.valueOf();let{aliasDuplicateObjects:X,onAnchor:U,onTagObj:Q,schema:J,sourceObjects:H}=z,G=void 0;if(X&&$&&typeof $==="object")if(G=H.get($),G)return G.anchor??(G.anchor=U($)),new nZ.Alias(G.anchor);else G={anchor:null,node:null},H.set($,G);if(Z?.startsWith("!!"))Z=oZ+Z.slice(2);let _=tZ($,Z,J.tags);if(!_){if($&&typeof $.toJSON==="function")$=$.toJSON();if(!$||typeof $!=="object"){let Y=new P3.Scalar($);if(G)G.node=Y;return Y}_=$ instanceof Map?J[B0.MAP]:(Symbol.iterator in Object($))?J[B0.SEQ]:J[B0.MAP]}if(Q)Q(_),delete z.onTagObj;let B=_?.createNode?_.createNode(z.schema,$,z):typeof _?.nodeClass?.from==="function"?_.nodeClass.from(z.schema,$,z):new P3.Scalar($);if(Z)B.tag=Z;else if(!_.default)B.tag=_.tag;if(G)G.node=B;return B}$4.createNode=eZ});var S$=D((U4)=>{var z4=n0(),s=b(),X4=C$();function S1($,Z,z){let X=z;for(let U=Z.length-1;U>=0;--U){let Q=Z[U];if(typeof Q==="number"&&Number.isInteger(Q)&&Q>=0){let J=[];J[Q]=X,X=J}else X=new Map([[Q,X]])}return z4.createNode(X,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error("This should not happen, please report a bug.")},schema:$,sourceObjects:new Map})}var T3=($)=>$==null||typeof $==="object"&&!!$[Symbol.iterator]().next().done;class A3 extends X4.NodeBase{constructor($,Z){super($);Object.defineProperty(this,"schema",{value:Z,configurable:!0,enumerable:!1,writable:!0})}clone($){let Z=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if($)Z.schema=$;if(Z.items=Z.items.map((z)=>s.isNode(z)||s.isPair(z)?z.clone($):z),this.range)Z.range=this.range.slice();return Z}addIn($,Z){if(T3($))this.add(Z);else{let[z,...X]=$,U=this.get(z,!0);if(s.isCollection(U))U.addIn(X,Z);else if(U===void 0&&this.schema)this.set(z,S1(this.schema,X,Z));else throw Error(`Expected YAML collection at ${z}. Remaining path: ${X}`)}}deleteIn($){let[Z,...z]=$;if(z.length===0)return this.delete(Z);let X=this.get(Z,!0);if(s.isCollection(X))return X.deleteIn(z);else throw Error(`Expected YAML collection at ${Z}. Remaining path: ${z}`)}getIn($,Z){let[z,...X]=$,U=this.get(z,!0);if(X.length===0)return!Z&&s.isScalar(U)?U.value:U;else return s.isCollection(U)?U.getIn(X,Z):void 0}hasAllNullValues($){return this.items.every((Z)=>{if(!s.isPair(Z))return!1;let z=Z.value;return z==null||$&&s.isScalar(z)&&z.value==null&&!z.commentBefore&&!z.comment&&!z.tag})}hasIn($){let[Z,...z]=$;if(z.length===0)return this.has(Z);let X=this.get(Z,!0);return s.isCollection(X)?X.hasIn(z):!1}setIn($,Z){let[z,...X]=$;if(X.length===0)this.set(z,Z);else{let U=this.get(z,!0);if(s.isCollection(U))U.setIn(X,Z);else if(U===void 0&&this.schema)this.set(z,S1(this.schema,X,Z));else throw Error(`Expected YAML collection at ${z}. Remaining path: ${X}`)}}}U4.Collection=A3;U4.collectionFromPath=S1;U4.isEmptyPath=T3});var o0=D((Y4)=>{var G4=($)=>$.replace(/^(?!$)(?: $)?/gm,"#");function E1($,Z){if(/^\n+$/.test($))return $.substring(1);return Z?$.replace(/^(?! *$)/gm,Z):$}var _4=($,Z,z)=>$.endsWith(`
3
- `)?E1(z,Z):z.includes(`
1
+ import{createRequire as s9}from"node:module";var d9=Object.defineProperty;var R=($,Z)=>()=>(Z||$((Z={exports:{}}).exports,Z),Z.exports);var c9=($)=>$;function i9($,Z){this[$]=c9.bind(null,Z)}var r9=($,Z)=>{for(var U in Z)d9($,U,{get:Z[U],enumerable:!0,configurable:!0,set:i9.bind(Z,U)})};var r0=s9(import.meta.url);var C=R((OZ)=>{var u$=Symbol.for("yaml.alias"),M3=Symbol.for("yaml.document"),g1=Symbol.for("yaml.map"),K3=Symbol.for("yaml.pair"),k$=Symbol.for("yaml.scalar"),x1=Symbol.for("yaml.seq"),o=Symbol.for("yaml.node.type"),HZ=($)=>!!$&&typeof $==="object"&&$[o]===u$,qZ=($)=>!!$&&typeof $==="object"&&$[o]===M3,YZ=($)=>!!$&&typeof $==="object"&&$[o]===g1,GZ=($)=>!!$&&typeof $==="object"&&$[o]===K3,F3=($)=>!!$&&typeof $==="object"&&$[o]===k$,_Z=($)=>!!$&&typeof $==="object"&&$[o]===x1;function P3($){if($&&typeof $==="object")switch($[o]){case g1:case x1:return!0}return!1}function BZ($){if($&&typeof $==="object")switch($[o]){case u$:case g1:case k$:case x1:return!0}return!1}var VZ=($)=>(F3($)||P3($))&&!!$.anchor;OZ.ALIAS=u$;OZ.DOC=M3;OZ.MAP=g1;OZ.NODE_TYPE=o;OZ.PAIR=K3;OZ.SCALAR=k$;OZ.SEQ=x1;OZ.hasAnchor=VZ;OZ.isAlias=HZ;OZ.isCollection=P3;OZ.isDocument=qZ;OZ.isMap=YZ;OZ.isNode=BZ;OZ.isPair=GZ;OZ.isScalar=F3;OZ.isSeq=_Z});var t0=R((EZ)=>{var h=C(),k=Symbol("break visit"),A3=Symbol("skip children"),s=Symbol("remove node");function h1($,Z){let U=T3(Z);if(h.isDocument($)){if(b0(null,$.contents,U,Object.freeze([$]))===s)$.contents=null}else b0(null,$,U,Object.freeze([]))}h1.BREAK=k;h1.SKIP=A3;h1.REMOVE=s;function b0($,Z,U,X){let Q=N3($,Z,U,X);if(h.isNode(Q)||h.isPair(Q))return w3($,X,Q),b0($,Q,U,X);if(typeof Q!=="symbol"){if(h.isCollection(Z)){X=Object.freeze(X.concat(Z));for(let z=0;z<Z.items.length;++z){let J=b0(z,Z.items[z],U,X);if(typeof J==="number")z=J-1;else if(J===k)return k;else if(J===s)Z.items.splice(z,1),z-=1}}else if(h.isPair(Z)){X=Object.freeze(X.concat(Z));let z=b0("key",Z.key,U,X);if(z===k)return k;else if(z===s)Z.key=null;let J=b0("value",Z.value,U,X);if(J===k)return k;else if(J===s)Z.value=null}}return Q}async function y1($,Z){let U=T3(Z);if(h.isDocument($)){if(await S0(null,$.contents,U,Object.freeze([$]))===s)$.contents=null}else await S0(null,$,U,Object.freeze([]))}y1.BREAK=k;y1.SKIP=A3;y1.REMOVE=s;async function S0($,Z,U,X){let Q=await N3($,Z,U,X);if(h.isNode(Q)||h.isPair(Q))return w3($,X,Q),S0($,Q,U,X);if(typeof Q!=="symbol"){if(h.isCollection(Z)){X=Object.freeze(X.concat(Z));for(let z=0;z<Z.items.length;++z){let J=await S0(z,Z.items[z],U,X);if(typeof J==="number")z=J-1;else if(J===k)return k;else if(J===s)Z.items.splice(z,1),z-=1}}else if(h.isPair(Z)){X=Object.freeze(X.concat(Z));let z=await S0("key",Z.key,U,X);if(z===k)return k;else if(z===s)Z.key=null;let J=await S0("value",Z.value,U,X);if(J===k)return k;else if(J===s)Z.value=null}}return Q}function T3($){if(typeof $==="object"&&($.Collection||$.Node||$.Value))return Object.assign({Alias:$.Node,Map:$.Node,Scalar:$.Node,Seq:$.Node},$.Value&&{Map:$.Value,Scalar:$.Value,Seq:$.Value},$.Collection&&{Map:$.Collection,Seq:$.Collection},$);return $}function N3($,Z,U,X){if(typeof U==="function")return U($,Z,X);if(h.isMap(Z))return U.Map?.($,Z,X);if(h.isSeq(Z))return U.Seq?.($,Z,X);if(h.isPair(Z))return U.Pair?.($,Z,X);if(h.isScalar(Z))return U.Scalar?.($,Z,X);if(h.isAlias(Z))return U.Alias?.($,Z,X);return}function w3($,Z,U){let X=Z[Z.length-1];if(h.isCollection(X))X.items[$]=U;else if(h.isPair(X))if($==="key")X.key=U;else X.value=U;else if(h.isDocument(X))X.contents=U;else{let Q=h.isAlias(X)?"alias":"scalar";throw Error(`Cannot replace node with ${Q} parent`)}}EZ.visit=h1;EZ.visitAsync=y1});var v$=R((fZ)=>{var C3=C(),xZ=t0(),hZ={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},yZ=($)=>$.replace(/[!,[\]{}]/g,(Z)=>hZ[Z]);class m{constructor($,Z){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},m.defaultYaml,$),this.tags=Object.assign({},m.defaultTags,Z)}clone(){let $=new m(this.yaml,this.tags);return $.docStart=this.docStart,$}atDocument(){let $=new m(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:m.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},m.defaultTags);break}return $}add($,Z){if(this.atNextDocument)this.yaml={explicit:m.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},m.defaultTags),this.atNextDocument=!1;let U=$.trim().split(/[ \t]+/),X=U.shift();switch(X){case"%TAG":{if(U.length!==2){if(Z(0,"%TAG directive should contain exactly two parts"),U.length<2)return!1}let[Q,z]=U;return this.tags[Q]=z,!0}case"%YAML":{if(this.yaml.explicit=!0,U.length!==1)return Z(0,"%YAML directive should contain exactly one part"),!1;let[Q]=U;if(Q==="1.1"||Q==="1.2")return this.yaml.version=Q,!0;else{let z=/^\d+\.\d+$/.test(Q);return Z(6,`Unsupported YAML version ${Q}`,z),!1}}default:return Z(0,`Unknown directive ${X}`,!0),!1}}tagName($,Z){if($==="!")return"!";if($[0]!=="!")return Z(`Not a valid tag: ${$}`),null;if($[1]==="<"){let z=$.slice(2,-1);if(z==="!"||z==="!!")return Z(`Verbatim tags aren't resolved, so ${$} is invalid.`),null;if($[$.length-1]!==">")Z("Verbatim tags must end with a >");return z}let[,U,X]=$.match(/^(.*!)([^!]*)$/s);if(!X)Z(`The ${$} tag has no suffix`);let Q=this.tags[U];if(Q)try{return Q+decodeURIComponent(X)}catch(z){return Z(String(z)),null}if(U==="!")return $;return Z(`Could not resolve tag: ${$}`),null}tagString($){for(let[Z,U]of Object.entries(this.tags))if($.startsWith(U))return Z+yZ($.substring(U.length));return $[0]==="!"?$:`!<${$}>`}toString($){let Z=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],U=Object.entries(this.tags),X;if($&&U.length>0&&C3.isNode($.contents)){let Q={};xZ.visit($.contents,(z,J)=>{if(C3.isNode(J)&&J.tag)Q[J.tag]=!0}),X=Object.keys(Q)}else X=[];for(let[Q,z]of U){if(Q==="!!"&&z==="tag:yaml.org,2002:")continue;if(!$||X.some((J)=>J.startsWith(z)))Z.push(`%TAG ${Q} ${z}`)}return Z.join(`
2
+ `)}}m.defaultYaml={explicit:!1,version:"1.2"};m.defaultTags={"!!":"tag:yaml.org,2002:"};fZ.Directives=m});var f1=R((pZ)=>{var b3=C(),kZ=t0();function vZ($){if(/[\x00-\x19\s,[\]{}]/.test($)){let U=`Anchor must not contain whitespace or control characters: ${JSON.stringify($)}`;throw Error(U)}return!0}function S3($){let Z=new Set;return kZ.visit($,{Value(U,X){if(X.anchor)Z.add(X.anchor)}}),Z}function E3($,Z){for(let U=1;;++U){let X=`${$}${U}`;if(!Z.has(X))return X}}function mZ($,Z){let U=[],X=new Map,Q=null;return{onAnchor:(z)=>{U.push(z),Q??(Q=S3($));let J=E3(Z,Q);return Q.add(J),J},setAnchors:()=>{for(let z of U){let J=X.get(z);if(typeof J==="object"&&J.anchor&&(b3.isScalar(J.node)||b3.isCollection(J.node)))J.node.anchor=J.anchor;else{let H=Error("Failed to resolve repeated object (this should not happen)");throw H.source=z,H}}},sourceObjects:X}}pZ.anchorIsValid=vZ;pZ.anchorNames=S3;pZ.createNodeAnchors=mZ;pZ.findNewAnchor=E3});var m$=R((rZ)=>{function e0($,Z,U,X){if(X&&typeof X==="object")if(Array.isArray(X))for(let Q=0,z=X.length;Q<z;++Q){let J=X[Q],H=e0($,X,String(Q),J);if(H===void 0)delete X[Q];else if(H!==J)X[Q]=H}else if(X instanceof Map)for(let Q of Array.from(X.keys())){let z=X.get(Q),J=e0($,X,Q,z);if(J===void 0)X.delete(Q);else if(J!==z)X.set(Q,J)}else if(X instanceof Set)for(let Q of Array.from(X)){let z=e0($,X,Q,Q);if(z===void 0)X.delete(Q);else if(z!==Q)X.delete(Q),X.add(z)}else for(let[Q,z]of Object.entries(X)){let J=e0($,X,Q,z);if(J===void 0)delete X[Q];else if(J!==z)X[Q]=J}return $.call(Z,U,X)}rZ.applyReviver=e0});var X0=R((nZ)=>{var aZ=C();function j3($,Z,U){if(Array.isArray($))return $.map((X,Q)=>j3(X,String(Q),U));if($&&typeof $.toJSON==="function"){if(!U||!aZ.hasAnchor($))return $.toJSON(Z,U);let X={aliasCount:0,count:1,res:void 0};U.anchors.set($,X),U.onCreate=(z)=>{X.res=z,delete U.onCreate};let Q=$.toJSON(Z,U);if(U.onCreate)U.onCreate(Q);return Q}if(typeof $==="bigint"&&!U?.keep)return Number($);return $}nZ.toJS=j3});var u1=R(($4)=>{var tZ=m$(),g3=C(),eZ=X0();class x3{constructor($){Object.defineProperty(this,g3.NODE_TYPE,{value:$})}clone(){let $=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if(this.range)$.range=this.range.slice();return $}toJS($,{mapAsMap:Z,maxAliasCount:U,onAnchor:X,reviver:Q}={}){if(!g3.isDocument($))throw TypeError("A document argument is required");let z={anchors:new Map,doc:$,keep:!0,mapAsMap:Z===!0,mapKeyWarned:!1,maxAliasCount:typeof U==="number"?U:100},J=eZ.toJS(this,"",z);if(typeof X==="function")for(let{count:H,res:q}of z.anchors.values())X(q,H);return typeof Q==="function"?tZ.applyReviver(Q,{"":J},"",J):J}}$4.NodeBase=x3});var $1=R((J4)=>{var U4=f1(),X4=t0(),E0=C(),Q4=u1(),z4=X0();class h3 extends Q4.NodeBase{constructor($){super(E0.ALIAS);this.source=$,Object.defineProperty(this,"tag",{set(){throw Error("Alias nodes cannot have tags")}})}resolve($,Z){let U;if(Z?.aliasResolveCache)U=Z.aliasResolveCache;else if(U=[],X4.visit($,{Node:(Q,z)=>{if(E0.isAlias(z)||E0.hasAnchor(z))U.push(z)}}),Z)Z.aliasResolveCache=U;let X=void 0;for(let Q of U){if(Q===this)break;if(Q.anchor===this.source)X=Q}return X}toJSON($,Z){if(!Z)return{source:this.source};let{anchors:U,doc:X,maxAliasCount:Q}=Z,z=this.resolve(X,Z);if(!z){let H=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(H)}let J=U.get(z);if(!J)z4.toJS(z,null,Z),J=U.get(z);if(J?.res===void 0)throw ReferenceError("This should not happen: Alias anchor was not resolved?");if(Q>=0){if(J.count+=1,J.aliasCount===0)J.aliasCount=k1(X,z,U);if(J.count*J.aliasCount>Q)throw ReferenceError("Excessive alias count indicates a resource exhaustion attack")}return J.res}toString($,Z,U){let X=`*${this.source}`;if($){if(U4.anchorIsValid(this.source),$.options.verifyAliasOrder&&!$.anchors.has(this.source)){let Q=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(Q)}if($.implicitKey)return`${X} `}return X}}function k1($,Z,U){if(E0.isAlias(Z)){let X=Z.resolve($),Q=U&&X&&U.get(X);return Q?Q.count*Q.aliasCount:0}else if(E0.isCollection(Z)){let X=0;for(let Q of Z.items){let z=k1($,Q,U);if(z>X)X=z}return X}else if(E0.isPair(Z)){let X=k1($,Z.key,U),Q=k1($,Z.value,U);return Math.max(X,Q)}return 1}J4.Alias=h3});var x=R((B4)=>{var q4=C(),Y4=u1(),G4=X0(),_4=($)=>!$||typeof $!=="function"&&typeof $!=="object";class O0 extends Y4.NodeBase{constructor($){super(q4.SCALAR);this.value=$}toJSON($,Z){return Z?.keep?this.value:G4.toJS(this.value,$,Z)}toString(){return String(this.value)}}O0.BLOCK_FOLDED="BLOCK_FOLDED";O0.BLOCK_LITERAL="BLOCK_LITERAL";O0.PLAIN="PLAIN";O0.QUOTE_DOUBLE="QUOTE_DOUBLE";O0.QUOTE_SINGLE="QUOTE_SINGLE";B4.Scalar=O0;B4.isScalarValue=_4});var Z1=R((R4)=>{var W4=$1(),W0=C(),y3=x(),D4="tag:yaml.org,2002:";function I4($,Z,U){if(Z){let X=U.filter((z)=>z.tag===Z),Q=X.find((z)=>!z.format)??X[0];if(!Q)throw Error(`Tag ${Z} not found`);return Q}return U.find((X)=>X.identify?.($)&&!X.format)}function L4($,Z,U){if(W0.isDocument($))$=$.contents;if(W0.isNode($))return $;if(W0.isPair($)){let _=U.schema[W0.MAP].createNode?.(U.schema,null,U);return _.items.push($),_}if($ instanceof String||$ instanceof Number||$ instanceof Boolean||typeof BigInt<"u"&&$ instanceof BigInt)$=$.valueOf();let{aliasDuplicateObjects:X,onAnchor:Q,onTagObj:z,schema:J,sourceObjects:H}=U,q=void 0;if(X&&$&&typeof $==="object")if(q=H.get($),q)return q.anchor??(q.anchor=Q($)),new W4.Alias(q.anchor);else q={anchor:null,node:null},H.set($,q);if(Z?.startsWith("!!"))Z=D4+Z.slice(2);let Y=I4($,Z,J.tags);if(!Y){if($&&typeof $.toJSON==="function")$=$.toJSON();if(!$||typeof $!=="object"){let _=new y3.Scalar($);if(q)q.node=_;return _}Y=$ instanceof Map?J[W0.MAP]:(Symbol.iterator in Object($))?J[W0.SEQ]:J[W0.MAP]}if(z)z(Y),delete U.onTagObj;let G=Y?.createNode?Y.createNode(U.schema,$,U):typeof Y?.nodeClass?.from==="function"?Y.nodeClass.from(U.schema,$,U):new y3.Scalar($);if(Z)G.tag=Z;else if(!Y.default)G.tag=Y.tag;if(q)q.node=G;return G}R4.createNode=L4});var v1=R((P4)=>{var K4=Z1(),a=C(),F4=u1();function p$($,Z,U){let X=U;for(let Q=Z.length-1;Q>=0;--Q){let z=Z[Q];if(typeof z==="number"&&Number.isInteger(z)&&z>=0){let J=[];J[z]=X,X=J}else X=new Map([[z,X]])}return K4.createNode(X,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error("This should not happen, please report a bug.")},schema:$,sourceObjects:new Map})}var f3=($)=>$==null||typeof $==="object"&&!!$[Symbol.iterator]().next().done;class u3 extends F4.NodeBase{constructor($,Z){super($);Object.defineProperty(this,"schema",{value:Z,configurable:!0,enumerable:!1,writable:!0})}clone($){let Z=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));if($)Z.schema=$;if(Z.items=Z.items.map((U)=>a.isNode(U)||a.isPair(U)?U.clone($):U),this.range)Z.range=this.range.slice();return Z}addIn($,Z){if(f3($))this.add(Z);else{let[U,...X]=$,Q=this.get(U,!0);if(a.isCollection(Q))Q.addIn(X,Z);else if(Q===void 0&&this.schema)this.set(U,p$(this.schema,X,Z));else throw Error(`Expected YAML collection at ${U}. Remaining path: ${X}`)}}deleteIn($){let[Z,...U]=$;if(U.length===0)return this.delete(Z);let X=this.get(Z,!0);if(a.isCollection(X))return X.deleteIn(U);else throw Error(`Expected YAML collection at ${Z}. Remaining path: ${U}`)}getIn($,Z){let[U,...X]=$,Q=this.get(U,!0);if(X.length===0)return!Z&&a.isScalar(Q)?Q.value:Q;else return a.isCollection(Q)?Q.getIn(X,Z):void 0}hasAllNullValues($){return this.items.every((Z)=>{if(!a.isPair(Z))return!1;let U=Z.value;return U==null||$&&a.isScalar(U)&&U.value==null&&!U.commentBefore&&!U.comment&&!U.tag})}hasIn($){let[Z,...U]=$;if(U.length===0)return this.has(Z);let X=this.get(Z,!0);return a.isCollection(X)?X.hasIn(U):!1}setIn($,Z){let[U,...X]=$;if(X.length===0)this.set(U,Z);else{let Q=this.get(U,!0);if(a.isCollection(Q))Q.setIn(X,Z);else if(Q===void 0&&this.schema)this.set(U,p$(this.schema,X,Z));else throw Error(`Expected YAML collection at ${U}. Remaining path: ${X}`)}}}P4.Collection=u3;P4.collectionFromPath=p$;P4.isEmptyPath=f3});var U1=R((b4)=>{var w4=($)=>$.replace(/^(?!$)(?: $)?/gm,"#");function l$($,Z){if(/^\n+$/.test($))return $.substring(1);return Z?$.replace(/^(?! *$)/gm,Z):$}var C4=($,Z,U)=>$.endsWith(`
3
+ `)?l$(U,Z):U.includes(`
4
4
  `)?`
5
- `+E1(z,Z):($.endsWith(" ")?"":" ")+z;Y4.indentComment=E1;Y4.lineComment=_4;Y4.stringifyComment=G4});var w3=D((W4)=>{function O4($,Z,z="flow",{indentAtStart:X,lineWidth:U=80,minContentWidth:Q=20,onFold:J,onOverflow:H}={}){if(!U||U<0)return $;if(U<Q)Q=0;let G=Math.max(1+Q,1+U-Z.length);if($.length<=G)return $;let _=[],B={},Y=U-Z.length;if(typeof X==="number")if(X>U-Math.max(2,Q))_.push(0);else Y=U-X;let q=void 0,W=void 0,I=!1,V=-1,O=-1,L=-1;if(z==="block"){if(V=N3($,V,Z.length),V!==-1)Y=V+G}for(let K;K=$[V+=1];){if(z==="quoted"&&K==="\\"){switch(O=V,$[V+1]){case"x":V+=3;break;case"u":V+=5;break;case"U":V+=9;break;default:V+=1}L=V}if(K===`
6
- `){if(z==="block")V=N3($,V,Z.length);Y=V+Z.length+G,q=void 0}else{if(K===" "&&W&&W!==" "&&W!==`
7
- `&&W!=="\t"){let N=$[V+1];if(N&&N!==" "&&N!==`
8
- `&&N!=="\t")q=V}if(V>=Y)if(q)_.push(q),Y=q+G,q=void 0;else if(z==="quoted"){while(W===" "||W==="\t")W=K,K=$[V+=1],I=!0;let N=V>L+1?V-2:O-1;if(B[N])return $;_.push(N),B[N]=!0,Y=N+G,q=void 0}else I=!0}W=K}if(I&&H)H();if(_.length===0)return $;if(J)J();let R=$.slice(0,_[0]);for(let K=0;K<_.length;++K){let N=_[K],A=_[K+1]||$.length;if(N===0)R=`
9
- ${Z}${$.slice(0,A)}`;else{if(z==="quoted"&&B[N])R+=`${$[N]}\\`;R+=`
10
- ${Z}${$.slice(N+1,A)}`}}return R}function N3($,Z,z){let X=Z,U=Z+1,Q=$[U];while(Q===" "||Q==="\t")if(Z<U+z)Q=$[++Z];else{do Q=$[++Z];while(Q&&Q!==`
11
- `);X=Z,U=Z+1,Q=$[U]}return X}W4.FOLD_BLOCK="block";W4.FOLD_FLOW="flow";W4.FOLD_QUOTED="quoted";W4.foldFlowLines=O4});var e0=D((P4)=>{var m=g(),Z0=w3(),g$=($,Z)=>({indentAtStart:Z?$.indent.length:$.indentAtStart,lineWidth:$.options.lineWidth,minContentWidth:$.options.minContentWidth}),f$=($)=>/^(%|---|\.\.\.)/m.test($);function F4($,Z,z){if(!Z||Z<0)return!1;let X=Z-z,U=$.length;if(U<=X)return!1;for(let Q=0,J=0;Q<U;++Q)if($[Q]===`
12
- `){if(Q-J>X)return!0;if(J=Q+1,U-J<=X)return!1}return!0}function t0($,Z){let z=JSON.stringify($);if(Z.options.doubleQuotedAsJSON)return z;let{implicitKey:X}=Z,U=Z.options.doubleQuotedMinMultiLineLength,Q=Z.indent||(f$($)?" ":""),J="",H=0;for(let G=0,_=z[G];_;_=z[++G]){if(_===" "&&z[G+1]==="\\"&&z[G+2]==="n")J+=z.slice(H,G)+"\\ ",G+=1,H=G,_="\\";if(_==="\\")switch(z[G+1]){case"u":{J+=z.slice(H,G);let B=z.substr(G+2,4);switch(B){case"0000":J+="\\0";break;case"0007":J+="\\a";break;case"000b":J+="\\v";break;case"001b":J+="\\e";break;case"0085":J+="\\N";break;case"00a0":J+="\\_";break;case"2028":J+="\\L";break;case"2029":J+="\\P";break;default:if(B.substr(0,2)==="00")J+="\\x"+B.substr(2);else J+=z.substr(G,6)}G+=5,H=G+1}break;case"n":if(X||z[G+2]==='"'||z.length<U)G+=1;else{J+=z.slice(H,G)+`
5
+ `+l$(U,Z):($.endsWith(" ")?"":" ")+U;b4.indentComment=l$;b4.lineComment=C4;b4.stringifyComment=w4});var v3=R((x4)=>{function g4($,Z,U="flow",{indentAtStart:X,lineWidth:Q=80,minContentWidth:z=20,onFold:J,onOverflow:H}={}){if(!Q||Q<0)return $;if(Q<z)z=0;let q=Math.max(1+z,1+Q-Z.length);if($.length<=q)return $;let Y=[],G={},_=Q-Z.length;if(typeof X==="number")if(X>Q-Math.max(2,z))Y.push(0);else _=Q-X;let B=void 0,O=void 0,D=!1,V=-1,W=-1,I=-1;if(U==="block"){if(V=k3($,V,Z.length),V!==-1)_=V+q}for(let F;F=$[V+=1];){if(U==="quoted"&&F==="\\"){switch(W=V,$[V+1]){case"x":V+=3;break;case"u":V+=5;break;case"U":V+=9;break;default:V+=1}I=V}if(F===`
6
+ `){if(U==="block")V=k3($,V,Z.length);_=V+Z.length+q,B=void 0}else{if(F===" "&&O&&O!==" "&&O!==`
7
+ `&&O!=="\t"){let A=$[V+1];if(A&&A!==" "&&A!==`
8
+ `&&A!=="\t")B=V}if(V>=_)if(B)Y.push(B),_=B+q,B=void 0;else if(U==="quoted"){while(O===" "||O==="\t")O=F,F=$[V+=1],D=!0;let A=V>I+1?V-2:W-1;if(G[A])return $;Y.push(A),G[A]=!0,_=A+q,B=void 0}else D=!0}O=F}if(D&&H)H();if(Y.length===0)return $;if(J)J();let L=$.slice(0,Y[0]);for(let F=0;F<Y.length;++F){let A=Y[F],T=Y[F+1]||$.length;if(A===0)L=`
9
+ ${Z}${$.slice(0,T)}`;else{if(U==="quoted"&&G[A])L+=`${$[A]}\\`;L+=`
10
+ ${Z}${$.slice(A+1,T)}`}}return L}function k3($,Z,U){let X=Z,Q=Z+1,z=$[Q];while(z===" "||z==="\t")if(Z<Q+U)z=$[++Z];else{do z=$[++Z];while(z&&z!==`
11
+ `);X=Z,Q=Z+1,z=$[Q]}return X}x4.FOLD_BLOCK="block";x4.FOLD_FLOW="flow";x4.FOLD_QUOTED="quoted";x4.foldFlowLines=g4});var Q1=R((p4)=>{var d=x(),Q0=v3(),p1=($,Z)=>({indentAtStart:Z?$.indent.length:$.indentAtStart,lineWidth:$.options.lineWidth,minContentWidth:$.options.minContentWidth}),l1=($)=>/^(%|---|\.\.\.)/m.test($);function k4($,Z,U){if(!Z||Z<0)return!1;let X=Z-U,Q=$.length;if(Q<=X)return!1;for(let z=0,J=0;z<Q;++z)if($[z]===`
12
+ `){if(z-J>X)return!0;if(J=z+1,Q-J<=X)return!1}return!0}function X1($,Z){let U=JSON.stringify($);if(Z.options.doubleQuotedAsJSON)return U;let{implicitKey:X}=Z,Q=Z.options.doubleQuotedMinMultiLineLength,z=Z.indent||(l1($)?" ":""),J="",H=0;for(let q=0,Y=U[q];Y;Y=U[++q]){if(Y===" "&&U[q+1]==="\\"&&U[q+2]==="n")J+=U.slice(H,q)+"\\ ",q+=1,H=q,Y="\\";if(Y==="\\")switch(U[q+1]){case"u":{J+=U.slice(H,q);let G=U.substr(q+2,4);switch(G){case"0000":J+="\\0";break;case"0007":J+="\\a";break;case"000b":J+="\\v";break;case"001b":J+="\\e";break;case"0085":J+="\\N";break;case"00a0":J+="\\_";break;case"2028":J+="\\L";break;case"2029":J+="\\P";break;default:if(G.substr(0,2)==="00")J+="\\x"+G.substr(2);else J+=U.substr(q,6)}q+=5,H=q+1}break;case"n":if(X||U[q+2]==='"'||U.length<Q)q+=1;else{J+=U.slice(H,q)+`
13
13
 
14
- `;while(z[G+2]==="\\"&&z[G+3]==="n"&&z[G+4]!=='"')J+=`
15
- `,G+=2;if(J+=Q,z[G+2]===" ")J+="\\";G+=1,H=G+1}break;default:G+=1}}return J=H?J+z.slice(H):z,X?J:Z0.foldFlowLines(J,Q,Z0.FOLD_QUOTED,g$(Z,!1))}function g1($,Z){if(Z.options.singleQuote===!1||Z.implicitKey&&$.includes(`
16
- `)||/[ \t]\n|\n[ \t]/.test($))return t0($,Z);let z=Z.indent||(f$($)?" ":""),X="'"+$.replace(/'/g,"''").replace(/\n+/g,`$&
17
- ${z}`)+"'";return Z.implicitKey?X:Z0.foldFlowLines(X,z,Z0.FOLD_FLOW,g$(Z,!1))}function w0($,Z){let{singleQuote:z}=Z.options,X;if(z===!1)X=t0;else{let U=$.includes('"'),Q=$.includes("'");if(U&&!Q)X=g1;else if(Q&&!U)X=t0;else X=z?g1:t0}return X($,Z)}var f1;try{f1=new RegExp(`(^|(?<!
14
+ `;while(U[q+2]==="\\"&&U[q+3]==="n"&&U[q+4]!=='"')J+=`
15
+ `,q+=2;if(J+=z,U[q+2]===" ")J+="\\";q+=1,H=q+1}break;default:q+=1}}return J=H?J+U.slice(H):U,X?J:Q0.foldFlowLines(J,z,Q0.FOLD_QUOTED,p1(Z,!1))}function d$($,Z){if(Z.options.singleQuote===!1||Z.implicitKey&&$.includes(`
16
+ `)||/[ \t]\n|\n[ \t]/.test($))return X1($,Z);let U=Z.indent||(l1($)?" ":""),X="'"+$.replace(/'/g,"''").replace(/\n+/g,`$&
17
+ ${U}`)+"'";return Z.implicitKey?X:Q0.foldFlowLines(X,U,Q0.FOLD_FLOW,p1(Z,!1))}function j0($,Z){let{singleQuote:U}=Z.options,X;if(U===!1)X=X1;else{let Q=$.includes('"'),z=$.includes("'");if(Q&&!z)X=d$;else if(z&&!Q)X=X1;else X=U?d$:X1}return X($,Z)}var c$;try{c$=new RegExp(`(^|(?<!
18
18
  ))
19
19
  +(?!
20
- |$)`,"g")}catch{f1=/\n+(?!\n|$)/g}function E$({comment:$,type:Z,value:z},X,U,Q){let{blockQuote:J,commentString:H,lineWidth:G}=X.options;if(!J||/\n[\t ]+$/.test(z))return w0(z,X);let _=X.indent||(X.forceBlockIndent||f$(z)?" ":""),B=J==="literal"?!0:J==="folded"||Z===m.Scalar.BLOCK_FOLDED?!1:Z===m.Scalar.BLOCK_LITERAL?!0:!F4(z,G,_.length);if(!z)return B?`|
20
+ |$)`,"g")}catch{c$=/\n+(?!\n|$)/g}function m1({comment:$,type:Z,value:U},X,Q,z){let{blockQuote:J,commentString:H,lineWidth:q}=X.options;if(!J||/\n[\t ]+$/.test(U))return j0(U,X);let Y=X.indent||(X.forceBlockIndent||l1(U)?" ":""),G=J==="literal"?!0:J==="folded"||Z===d.Scalar.BLOCK_FOLDED?!1:Z===d.Scalar.BLOCK_LITERAL?!0:!k4(U,q,Y.length);if(!U)return G?`|
21
21
  `:`>
22
- `;let Y,q;for(q=z.length;q>0;--q){let A=z[q-1];if(A!==`
23
- `&&A!=="\t"&&A!==" ")break}let W=z.substring(q),I=W.indexOf(`
24
- `);if(I===-1)Y="-";else if(z===W||I!==W.length-1){if(Y="+",Q)Q()}else Y="";if(W){if(z=z.slice(0,-W.length),W[W.length-1]===`
25
- `)W=W.slice(0,-1);W=W.replace(f1,`$&${_}`)}let V=!1,O,L=-1;for(O=0;O<z.length;++O){let A=z[O];if(A===" ")V=!0;else if(A===`
26
- `)L=O;else break}let R=z.substring(0,L<O?L+1:O);if(R)z=z.substring(R.length),R=R.replace(/\n+/g,`$&${_}`);let N=(V?_?"2":"1":"")+Y;if($){if(N+=" "+H($.replace(/ ?[\r\n]+/g," ")),U)U()}if(!B){let A=z.replace(/\n+/g,`
27
- $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${_}`),w=!1,C=g$(X,!0);if(J!=="folded"&&Z!==m.Scalar.BLOCK_FOLDED)C.onOverflow=()=>{w=!0};let P=Z0.foldFlowLines(`${R}${A}${W}`,_,Z0.FOLD_BLOCK,C);if(!w)return`>${N}
28
- ${_}${P}`}return z=z.replace(/\n+/g,`$&${_}`),`|${N}
29
- ${_}${R}${z}${W}`}function M4($,Z,z,X){let{type:U,value:Q}=$,{actualString:J,implicitKey:H,indent:G,indentStep:_,inFlow:B}=Z;if(H&&Q.includes(`
30
- `)||B&&/[[\]{},]/.test(Q))return w0(Q,Z);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(Q))return H||B||!Q.includes(`
31
- `)?w0(Q,Z):E$($,Z,z,X);if(!H&&!B&&U!==m.Scalar.PLAIN&&Q.includes(`
32
- `))return E$($,Z,z,X);if(f$(Q)){if(G==="")return Z.forceBlockIndent=!0,E$($,Z,z,X);else if(H&&G===_)return w0(Q,Z)}let Y=Q.replace(/\n+/g,`$&
33
- ${G}`);if(J){let q=(V)=>V.default&&V.tag!=="tag:yaml.org,2002:str"&&V.test?.test(Y),{compat:W,tags:I}=Z.doc.schema;if(I.some(q)||W?.some(q))return w0(Q,Z)}return H?Y:Z0.foldFlowLines(Y,G,Z0.FOLD_FLOW,g$(Z,!1))}function K4($,Z,z,X){let{implicitKey:U,inFlow:Q}=Z,J=typeof $.value==="string"?$:Object.assign({},$,{value:String($.value)}),{type:H}=$;if(H!==m.Scalar.QUOTE_DOUBLE){if(/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(J.value))H=m.Scalar.QUOTE_DOUBLE}let G=(B)=>{switch(B){case m.Scalar.BLOCK_FOLDED:case m.Scalar.BLOCK_LITERAL:return U||Q?w0(J.value,Z):E$(J,Z,z,X);case m.Scalar.QUOTE_DOUBLE:return t0(J.value,Z);case m.Scalar.QUOTE_SINGLE:return g1(J.value,Z);case m.Scalar.PLAIN:return M4(J,Z,z,X);default:return null}},_=G(H);if(_===null){let{defaultKeyType:B,defaultStringType:Y}=Z.options,q=U&&B||Y;if(_=G(q),_===null)throw Error(`Unsupported default string type ${q}`)}return _}P4.stringifyString=K4});var $$=D((E4)=>{var A4=b$(),z0=b(),N4=o0(),w4=e0();function b4($,Z){let z=Object.assign({blockQuote:!0,commentString:N4.stringifyComment,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:"true",verifyAliasOrder:!0},$.schema.toStringOptions,Z),X;switch(z.collectionStyle){case"block":X=!1;break;case"flow":X=!0;break;default:X=null}return{anchors:new Set,doc:$,flowCollectionPadding:z.flowCollectionPadding?" ":"",indent:"",indentStep:typeof z.indent==="number"?" ".repeat(z.indent):" ",inFlow:X,options:z}}function C4($,Z){if(Z.tag){let U=$.filter((Q)=>Q.tag===Z.tag);if(U.length>0)return U.find((Q)=>Q.format===Z.format)??U[0]}let z=void 0,X;if(z0.isScalar(Z)){X=Z.value;let U=$.filter((Q)=>Q.identify?.(X));if(U.length>1){let Q=U.filter((J)=>J.test);if(Q.length>0)U=Q}z=U.find((Q)=>Q.format===Z.format)??U.find((Q)=>!Q.format)}else X=Z,z=$.find((U)=>U.nodeClass&&X instanceof U.nodeClass);if(!z){let U=X?.constructor?.name??(X===null?"null":typeof X);throw Error(`Tag not resolved for ${U} value`)}return z}function j4($,Z,{anchors:z,doc:X}){if(!X.directives)return"";let U=[],Q=(z0.isScalar($)||z0.isCollection($))&&$.anchor;if(Q&&A4.anchorIsValid(Q))z.add(Q),U.push(`&${Q}`);let J=$.tag??(Z.default?null:Z.tag);if(J)U.push(X.directives.tagString(J));return U.join(" ")}function S4($,Z,z,X){if(z0.isPair($))return $.toString(Z,z,X);if(z0.isAlias($)){if(Z.doc.directives)return $.toString(Z);if(Z.resolvedAliases?.has($))throw TypeError("Cannot stringify circular structure without alias nodes");else{if(Z.resolvedAliases)Z.resolvedAliases.add($);else Z.resolvedAliases=new Set([$]);$=$.resolve(Z.doc)}}let U=void 0,Q=z0.isNode($)?$:Z.doc.createNode($,{onTagObj:(G)=>U=G});U??(U=C4(Z.doc.schema.tags,Q));let J=j4(Q,U,Z);if(J.length>0)Z.indentAtStart=(Z.indentAtStart??0)+J.length+1;let H=typeof U.stringify==="function"?U.stringify(Q,Z,z,X):z0.isScalar(Q)?w4.stringifyString(Q,Z,z,X):Q.toString(Z,z,X);if(!J)return H;return z0.isScalar(Q)||H[0]==="{"||H[0]==="["?`${J} ${H}`:`${J}
34
- ${Z.indent}${H}`}E4.createStringifyContext=b4;E4.stringify=S4});var j3=D((h4)=>{var n=b(),b3=g(),C3=$$(),Z$=o0();function y4({key:$,value:Z},z,X,U){let{allNullValues:Q,doc:J,indent:H,indentStep:G,options:{commentString:_,indentSeq:B,simpleKeys:Y}}=z,q=n.isNode($)&&$.comment||null;if(Y){if(q)throw Error("With simple keys, key nodes cannot have comments");if(n.isCollection($)||!n.isNode($)&&typeof $==="object")throw Error("With simple keys, collection cannot be used as a key value")}let W=!Y&&(!$||q&&Z==null&&!z.inFlow||n.isCollection($)||(n.isScalar($)?$.type===b3.Scalar.BLOCK_FOLDED||$.type===b3.Scalar.BLOCK_LITERAL:typeof $==="object"));z=Object.assign({},z,{allNullValues:!1,implicitKey:!W&&(Y||!Q),indent:H+G});let I=!1,V=!1,O=C3.stringify($,z,()=>I=!0,()=>V=!0);if(!W&&!z.inFlow&&O.length>1024){if(Y)throw Error("With simple keys, single line scalar must not span more than 1024 characters");W=!0}if(z.inFlow){if(Q||Z==null){if(I&&X)X();return O===""?"?":W?`? ${O}`:O}}else if(Q&&!Y||Z==null&&W){if(O=`? ${O}`,q&&!I)O+=Z$.lineComment(O,z.indent,_(q));else if(V&&U)U();return O}if(I)q=null;if(W){if(q)O+=Z$.lineComment(O,z.indent,_(q));O=`? ${O}
35
- ${H}:`}else if(O=`${O}:`,q)O+=Z$.lineComment(O,z.indent,_(q));let L,R,K;if(n.isNode(Z))L=!!Z.spaceBefore,R=Z.commentBefore,K=Z.comment;else if(L=!1,R=null,K=null,Z&&typeof Z==="object")Z=J.createNode(Z);if(z.implicitKey=!1,!W&&!q&&n.isScalar(Z))z.indentAtStart=O.length+1;if(V=!1,!B&&G.length>=2&&!z.inFlow&&!W&&n.isSeq(Z)&&!Z.flow&&!Z.tag&&!Z.anchor)z.indent=z.indent.substring(2);let N=!1,A=C3.stringify(Z,z,()=>N=!0,()=>V=!0),w=" ";if(q||L||R){if(w=L?`
36
- `:"",R){let C=_(R);w+=`
37
- ${Z$.indentComment(C,z.indent)}`}if(A===""&&!z.inFlow){if(w===`
38
- `&&K)w=`
22
+ `;let _,B;for(B=U.length;B>0;--B){let T=U[B-1];if(T!==`
23
+ `&&T!=="\t"&&T!==" ")break}let O=U.substring(B),D=O.indexOf(`
24
+ `);if(D===-1)_="-";else if(U===O||D!==O.length-1){if(_="+",z)z()}else _="";if(O){if(U=U.slice(0,-O.length),O[O.length-1]===`
25
+ `)O=O.slice(0,-1);O=O.replace(c$,`$&${Y}`)}let V=!1,W,I=-1;for(W=0;W<U.length;++W){let T=U[W];if(T===" ")V=!0;else if(T===`
26
+ `)I=W;else break}let L=U.substring(0,I<W?I+1:W);if(L)U=U.substring(L.length),L=L.replace(/\n+/g,`$&${Y}`);let A=(V?Y?"2":"1":"")+_;if($){if(A+=" "+H($.replace(/ ?[\r\n]+/g," ")),Q)Q()}if(!G){let T=U.replace(/\n+/g,`
27
+ $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${Y}`),N=!1,b=p1(X,!0);if(J!=="folded"&&Z!==d.Scalar.BLOCK_FOLDED)b.onOverflow=()=>{N=!0};let P=Q0.foldFlowLines(`${L}${T}${O}`,Y,Q0.FOLD_BLOCK,b);if(!N)return`>${A}
28
+ ${Y}${P}`}return U=U.replace(/\n+/g,`$&${Y}`),`|${A}
29
+ ${Y}${L}${U}${O}`}function v4($,Z,U,X){let{type:Q,value:z}=$,{actualString:J,implicitKey:H,indent:q,indentStep:Y,inFlow:G}=Z;if(H&&z.includes(`
30
+ `)||G&&/[[\]{},]/.test(z))return j0(z,Z);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(z))return H||G||!z.includes(`
31
+ `)?j0(z,Z):m1($,Z,U,X);if(!H&&!G&&Q!==d.Scalar.PLAIN&&z.includes(`
32
+ `))return m1($,Z,U,X);if(l1(z)){if(q==="")return Z.forceBlockIndent=!0,m1($,Z,U,X);else if(H&&q===Y)return j0(z,Z)}let _=z.replace(/\n+/g,`$&
33
+ ${q}`);if(J){let B=(V)=>V.default&&V.tag!=="tag:yaml.org,2002:str"&&V.test?.test(_),{compat:O,tags:D}=Z.doc.schema;if(D.some(B)||O?.some(B))return j0(z,Z)}return H?_:Q0.foldFlowLines(_,q,Q0.FOLD_FLOW,p1(Z,!1))}function m4($,Z,U,X){let{implicitKey:Q,inFlow:z}=Z,J=typeof $.value==="string"?$:Object.assign({},$,{value:String($.value)}),{type:H}=$;if(H!==d.Scalar.QUOTE_DOUBLE){if(/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(J.value))H=d.Scalar.QUOTE_DOUBLE}let q=(G)=>{switch(G){case d.Scalar.BLOCK_FOLDED:case d.Scalar.BLOCK_LITERAL:return Q||z?j0(J.value,Z):m1(J,Z,U,X);case d.Scalar.QUOTE_DOUBLE:return X1(J.value,Z);case d.Scalar.QUOTE_SINGLE:return d$(J.value,Z);case d.Scalar.PLAIN:return v4(J,Z,U,X);default:return null}},Y=q(H);if(Y===null){let{defaultKeyType:G,defaultStringType:_}=Z.options,B=Q&&G||_;if(Y=q(B),Y===null)throw Error(`Unsupported default string type ${B}`)}return Y}p4.stringifyString=m4});var z1=R((o4)=>{var d4=f1(),z0=C(),c4=U1(),i4=Q1();function r4($,Z){let U=Object.assign({blockQuote:!0,commentString:c4.stringifyComment,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:"true",verifyAliasOrder:!0},$.schema.toStringOptions,Z),X;switch(U.collectionStyle){case"block":X=!1;break;case"flow":X=!0;break;default:X=null}return{anchors:new Set,doc:$,flowCollectionPadding:U.flowCollectionPadding?" ":"",indent:"",indentStep:typeof U.indent==="number"?" ".repeat(U.indent):" ",inFlow:X,options:U}}function s4($,Z){if(Z.tag){let Q=$.filter((z)=>z.tag===Z.tag);if(Q.length>0)return Q.find((z)=>z.format===Z.format)??Q[0]}let U=void 0,X;if(z0.isScalar(Z)){X=Z.value;let Q=$.filter((z)=>z.identify?.(X));if(Q.length>1){let z=Q.filter((J)=>J.test);if(z.length>0)Q=z}U=Q.find((z)=>z.format===Z.format)??Q.find((z)=>!z.format)}else X=Z,U=$.find((Q)=>Q.nodeClass&&X instanceof Q.nodeClass);if(!U){let Q=X?.constructor?.name??(X===null?"null":typeof X);throw Error(`Tag not resolved for ${Q} value`)}return U}function a4($,Z,{anchors:U,doc:X}){if(!X.directives)return"";let Q=[],z=(z0.isScalar($)||z0.isCollection($))&&$.anchor;if(z&&d4.anchorIsValid(z))U.add(z),Q.push(`&${z}`);let J=$.tag??(Z.default?null:Z.tag);if(J)Q.push(X.directives.tagString(J));return Q.join(" ")}function n4($,Z,U,X){if(z0.isPair($))return $.toString(Z,U,X);if(z0.isAlias($)){if(Z.doc.directives)return $.toString(Z);if(Z.resolvedAliases?.has($))throw TypeError("Cannot stringify circular structure without alias nodes");else{if(Z.resolvedAliases)Z.resolvedAliases.add($);else Z.resolvedAliases=new Set([$]);$=$.resolve(Z.doc)}}let Q=void 0,z=z0.isNode($)?$:Z.doc.createNode($,{onTagObj:(q)=>Q=q});Q??(Q=s4(Z.doc.schema.tags,z));let J=a4(z,Q,Z);if(J.length>0)Z.indentAtStart=(Z.indentAtStart??0)+J.length+1;let H=typeof Q.stringify==="function"?Q.stringify(z,Z,U,X):z0.isScalar(z)?i4.stringifyString(z,Z,U,X):z.toString(Z,U,X);if(!J)return H;return z0.isScalar(z)||H[0]==="{"||H[0]==="["?`${J} ${H}`:`${J}
34
+ ${Z.indent}${H}`}o4.createStringifyContext=r4;o4.stringify=n4});var l3=R((Z5)=>{var t=C(),m3=x(),p3=z1(),J1=U1();function $5({key:$,value:Z},U,X,Q){let{allNullValues:z,doc:J,indent:H,indentStep:q,options:{commentString:Y,indentSeq:G,simpleKeys:_}}=U,B=t.isNode($)&&$.comment||null;if(_){if(B)throw Error("With simple keys, key nodes cannot have comments");if(t.isCollection($)||!t.isNode($)&&typeof $==="object")throw Error("With simple keys, collection cannot be used as a key value")}let O=!_&&(!$||B&&Z==null&&!U.inFlow||t.isCollection($)||(t.isScalar($)?$.type===m3.Scalar.BLOCK_FOLDED||$.type===m3.Scalar.BLOCK_LITERAL:typeof $==="object"));U=Object.assign({},U,{allNullValues:!1,implicitKey:!O&&(_||!z),indent:H+q});let D=!1,V=!1,W=p3.stringify($,U,()=>D=!0,()=>V=!0);if(!O&&!U.inFlow&&W.length>1024){if(_)throw Error("With simple keys, single line scalar must not span more than 1024 characters");O=!0}if(U.inFlow){if(z||Z==null){if(D&&X)X();return W===""?"?":O?`? ${W}`:W}}else if(z&&!_||Z==null&&O){if(W=`? ${W}`,B&&!D)W+=J1.lineComment(W,U.indent,Y(B));else if(V&&Q)Q();return W}if(D)B=null;if(O){if(B)W+=J1.lineComment(W,U.indent,Y(B));W=`? ${W}
35
+ ${H}:`}else if(W=`${W}:`,B)W+=J1.lineComment(W,U.indent,Y(B));let I,L,F;if(t.isNode(Z))I=!!Z.spaceBefore,L=Z.commentBefore,F=Z.comment;else if(I=!1,L=null,F=null,Z&&typeof Z==="object")Z=J.createNode(Z);if(U.implicitKey=!1,!O&&!B&&t.isScalar(Z))U.indentAtStart=W.length+1;if(V=!1,!G&&q.length>=2&&!U.inFlow&&!O&&t.isSeq(Z)&&!Z.flow&&!Z.tag&&!Z.anchor)U.indent=U.indent.substring(2);let A=!1,T=p3.stringify(Z,U,()=>A=!0,()=>V=!0),N=" ";if(B||I||L){if(N=I?`
36
+ `:"",L){let b=Y(L);N+=`
37
+ ${J1.indentComment(b,U.indent)}`}if(T===""&&!U.inFlow){if(N===`
38
+ `&&F)N=`
39
39
 
40
- `}else w+=`
41
- ${z.indent}`}else if(!W&&n.isCollection(Z)){let C=A[0],P=A.indexOf(`
42
- `),T=P!==-1,d=z.inFlow??Z.flow??Z.items.length===0;if(T||!d){let c=!1;if(T&&(C==="&"||C==="!")){let E=A.indexOf(" ");if(C==="&"&&E!==-1&&E<P&&A[E+1]==="!")E=A.indexOf(" ",E+1);if(E===-1||P<E)c=!0}if(!c)w=`
43
- ${z.indent}`}}else if(A===""||A[0]===`
44
- `)w="";if(O+=w+A,z.inFlow){if(N&&X)X()}else if(K&&!N)O+=Z$.lineComment(O,z.indent,_(K));else if(V&&U)U();return O}h4.stringifyPair=y4});var y1=D((v4)=>{var S3=p0("process");function u4($,...Z){if($==="debug")console.log(...Z)}function k4($,Z){if($==="debug"||$==="warn")if(typeof S3.emitWarning==="function")S3.emitWarning(Z);else console.warn(Z)}v4.debug=u4;v4.warn=k4});var x$=D((d4)=>{var z$=b(),E3=g(),y$="<<",h$={identify:($)=>$===y$||typeof $==="symbol"&&$.description===y$,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new E3.Scalar(Symbol(y$)),{addToJSMap:g3}),stringify:()=>y$},l4=($,Z)=>(h$.identify(Z)||z$.isScalar(Z)&&(!Z.type||Z.type===E3.Scalar.PLAIN)&&h$.identify(Z.value))&&$?.doc.schema.tags.some((z)=>z.tag===h$.tag&&z.default);function g3($,Z,z){if(z=$&&z$.isAlias(z)?z.resolve($.doc):z,z$.isSeq(z))for(let X of z.items)h1($,Z,X);else if(Array.isArray(z))for(let X of z)h1($,Z,X);else h1($,Z,z)}function h1($,Z,z){let X=$&&z$.isAlias(z)?z.resolve($.doc):z;if(!z$.isMap(X))throw Error("Merge sources must be maps or map aliases");let U=X.toJSON(null,$,Map);for(let[Q,J]of U)if(Z instanceof Map){if(!Z.has(Q))Z.set(Q,J)}else if(Z instanceof Set)Z.add(Q);else if(!Object.prototype.hasOwnProperty.call(Z,Q))Object.defineProperty(Z,Q,{value:J,writable:!0,enumerable:!0,configurable:!0});return Z}d4.addMergeToJSMap=g3;d4.isMergeKey=l4;d4.merge=h$});var u1=D((t4)=>{var a4=y1(),f3=x$(),r4=$$(),y3=b(),x1=$0();function n4($,Z,{key:z,value:X}){if(y3.isNode(z)&&z.addToJSMap)z.addToJSMap($,Z,X);else if(f3.isMergeKey($,z))f3.addMergeToJSMap($,Z,X);else{let U=x1.toJS(z,"",$);if(Z instanceof Map)Z.set(U,x1.toJS(X,U,$));else if(Z instanceof Set)Z.add(U);else{let Q=o4(z,U,$),J=x1.toJS(X,Q,$);if(Q in Z)Object.defineProperty(Z,Q,{value:J,writable:!0,enumerable:!0,configurable:!0});else Z[Q]=J}}return Z}function o4($,Z,z){if(Z===null)return"";if(typeof Z!=="object")return String(Z);if(y3.isNode($)&&z?.doc){let X=r4.createStringifyContext(z.doc,{});X.anchors=new Set;for(let Q of z.anchors.keys())X.anchors.add(Q.anchor);X.inFlow=!0,X.inStringifyKey=!0;let U=$.toString(X);if(!z.mapKeyWarned){let Q=JSON.stringify(U);if(Q.length>40)Q=Q.substring(0,36)+'..."';a4.warn(z.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${Q}. Set mapAsMap: true to use object keys.`),z.mapKeyWarned=!0}return U}return JSON.stringify(Z)}t4.addPairToJSMap=n4});var X0=D((X5)=>{var h3=n0(),$5=j3(),Z5=u1(),u$=b();function z5($,Z,z){let X=h3.createNode($,void 0,z),U=h3.createNode(Z,void 0,z);return new k$(X,U)}class k${constructor($,Z=null){Object.defineProperty(this,u$.NODE_TYPE,{value:u$.PAIR}),this.key=$,this.value=Z}clone($){let{key:Z,value:z}=this;if(u$.isNode(Z))Z=Z.clone($);if(u$.isNode(z))z=z.clone($);return new k$(Z,z)}toJSON($,Z){let z=Z?.mapAsMap?new Map:{};return Z5.addPairToJSMap(Z,z,this)}toString($,Z,z){return $?.doc?$5.stringifyPair(this,$,Z,z):JSON.stringify(this)}}X5.Pair=k$;X5.createPair=z5});var k1=D((_5)=>{var V0=b(),x3=$$(),v$=o0();function J5($,Z,z){return(Z.inFlow??$.flow?G5:H5)($,Z,z)}function H5({comment:$,items:Z},z,{blockItemPrefix:X,flowChars:U,itemIndent:Q,onChompKeep:J,onComment:H}){let{indent:G,options:{commentString:_}}=z,B=Object.assign({},z,{indent:Q,type:null}),Y=!1,q=[];for(let I=0;I<Z.length;++I){let V=Z[I],O=null;if(V0.isNode(V)){if(!Y&&V.spaceBefore)q.push("");if(m$(z,q,V.commentBefore,Y),V.comment)O=V.comment}else if(V0.isPair(V)){let R=V0.isNode(V.key)?V.key:null;if(R){if(!Y&&R.spaceBefore)q.push("");m$(z,q,R.commentBefore,Y)}}Y=!1;let L=x3.stringify(V,B,()=>O=null,()=>Y=!0);if(O)L+=v$.lineComment(L,Q,_(O));if(Y&&O)Y=!1;q.push(X+L)}let W;if(q.length===0)W=U.start+U.end;else{W=q[0];for(let I=1;I<q.length;++I){let V=q[I];W+=V?`
45
- ${G}${V}`:`
46
- `}}if($){if(W+=`
47
- `+v$.indentComment(_($),G),H)H()}else if(Y&&J)J();return W}function G5({items:$},Z,{flowChars:z,itemIndent:X}){let{indent:U,indentStep:Q,flowCollectionPadding:J,options:{commentString:H}}=Z;X+=Q;let G=Object.assign({},Z,{indent:X,inFlow:!0,type:null}),_=!1,B=0,Y=[];for(let I=0;I<$.length;++I){let V=$[I],O=null;if(V0.isNode(V)){if(V.spaceBefore)Y.push("");if(m$(Z,Y,V.commentBefore,!1),V.comment)O=V.comment}else if(V0.isPair(V)){let R=V0.isNode(V.key)?V.key:null;if(R){if(R.spaceBefore)Y.push("");if(m$(Z,Y,R.commentBefore,!1),R.comment)_=!0}let K=V0.isNode(V.value)?V.value:null;if(K){if(K.comment)O=K.comment;if(K.commentBefore)_=!0}else if(V.value==null&&R?.comment)O=R.comment}if(O)_=!0;let L=x3.stringify(V,G,()=>O=null);if(_||(_=Y.length>B||L.includes(`
48
- `)),I<$.length-1)L+=",";else if(Z.options.trailingComma){if(Z.options.lineWidth>0)_||(_=Y.reduce((R,K)=>R+K.length+2,2)+(L.length+2)>Z.options.lineWidth);if(_)L+=","}if(O)L+=v$.lineComment(L,X,H(O));Y.push(L),B=Y.length}let{start:q,end:W}=z;if(Y.length===0)return q+W;else{if(!_){let I=Y.reduce((V,O)=>V+O.length+2,2);_=Z.options.lineWidth>0&&I>Z.options.lineWidth}if(_){let I=q;for(let V of Y)I+=V?`
49
- ${Q}${U}${V}`:`
50
- `;return`${I}
51
- ${U}${W}`}else return`${q}${J}${Y.join(" ")}${J}${W}`}}function m$({indent:$,options:{commentString:Z}},z,X,U){if(X&&U)X=X.replace(/^\n+/,"");if(X){let Q=v$.indentComment(Z(X),$);z.push(Q.trimStart())}}_5.stringifyCollection=J5});var Q0=D((W5)=>{var q5=k1(),B5=u1(),V5=S$(),U0=b(),p$=X0(),O5=g();function X$($,Z){let z=U0.isScalar(Z)?Z.value:Z;for(let X of $)if(U0.isPair(X)){if(X.key===Z||X.key===z)return X;if(U0.isScalar(X.key)&&X.key.value===z)return X}return}class u3 extends V5.Collection{static get tagName(){return"tag:yaml.org,2002:map"}constructor($){super(U0.MAP,$);this.items=[]}static from($,Z,z){let{keepUndefined:X,replacer:U}=z,Q=new this($),J=(H,G)=>{if(typeof U==="function")G=U.call(Z,H,G);else if(Array.isArray(U)&&!U.includes(H))return;if(G!==void 0||X)Q.items.push(p$.createPair(H,G,z))};if(Z instanceof Map)for(let[H,G]of Z)J(H,G);else if(Z&&typeof Z==="object")for(let H of Object.keys(Z))J(H,Z[H]);if(typeof $.sortMapEntries==="function")Q.items.sort($.sortMapEntries);return Q}add($,Z){let z;if(U0.isPair($))z=$;else if(!$||typeof $!=="object"||!("key"in $))z=new p$.Pair($,$?.value);else z=new p$.Pair($.key,$.value);let X=X$(this.items,z.key),U=this.schema?.sortMapEntries;if(X){if(!Z)throw Error(`Key ${z.key} already set`);if(U0.isScalar(X.value)&&O5.isScalarValue(z.value))X.value.value=z.value;else X.value=z.value}else if(U){let Q=this.items.findIndex((J)=>U(z,J)<0);if(Q===-1)this.items.push(z);else this.items.splice(Q,0,z)}else this.items.push(z)}delete($){let Z=X$(this.items,$);if(!Z)return!1;return this.items.splice(this.items.indexOf(Z),1).length>0}get($,Z){let X=X$(this.items,$)?.value;return(!Z&&U0.isScalar(X)?X.value:X)??void 0}has($){return!!X$(this.items,$)}set($,Z){this.add(new p$.Pair($,Z),!0)}toJSON($,Z,z){let X=z?new z:Z?.mapAsMap?new Map:{};if(Z?.onCreate)Z.onCreate(X);for(let U of this.items)B5.addPairToJSMap(Z,X,U);return X}toString($,Z,z){if(!$)return JSON.stringify(this);for(let X of this.items)if(!U0.isPair(X))throw Error(`Map items must all be pairs; found ${JSON.stringify(X)} instead`);if(!$.allNullValues&&this.hasAllNullValues(!1))$=Object.assign({},$,{allNullValues:!0});return q5.stringifyCollection(this,$,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:$.indent||"",onChompKeep:z,onComment:Z})}}W5.YAMLMap=u3;W5.findPair=X$});var b0=D((F5)=>{var D5=b(),k3=Q0(),R5={collection:"map",default:!0,nodeClass:k3.YAMLMap,tag:"tag:yaml.org,2002:map",resolve($,Z){if(!D5.isMap($))Z("Expected a mapping for this tag");return $},createNode:($,Z,z)=>k3.YAMLMap.from($,Z,z)};F5.map=R5});var J0=D((w5)=>{var K5=n0(),P5=k1(),T5=S$(),d$=b(),A5=g(),N5=$0();class v3 extends T5.Collection{static get tagName(){return"tag:yaml.org,2002:seq"}constructor($){super(d$.SEQ,$);this.items=[]}add($){this.items.push($)}delete($){let Z=l$($);if(typeof Z!=="number")return!1;return this.items.splice(Z,1).length>0}get($,Z){let z=l$($);if(typeof z!=="number")return;let X=this.items[z];return!Z&&d$.isScalar(X)?X.value:X}has($){let Z=l$($);return typeof Z==="number"&&Z<this.items.length}set($,Z){let z=l$($);if(typeof z!=="number")throw Error(`Expected a valid index, not ${$}.`);let X=this.items[z];if(d$.isScalar(X)&&A5.isScalarValue(Z))X.value=Z;else this.items[z]=Z}toJSON($,Z){let z=[];if(Z?.onCreate)Z.onCreate(z);let X=0;for(let U of this.items)z.push(N5.toJS(U,String(X++),Z));return z}toString($,Z,z){if(!$)return JSON.stringify(this);return P5.stringifyCollection(this,$,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:($.indent||"")+" ",onChompKeep:z,onComment:Z})}static from($,Z,z){let{replacer:X}=z,U=new this($);if(Z&&Symbol.iterator in Object(Z)){let Q=0;for(let J of Z){if(typeof X==="function"){let H=Z instanceof Set?J:String(Q++);J=X.call(Z,H,J)}U.items.push(K5.createNode(J,void 0,z))}}return U}}function l$($){let Z=d$.isScalar($)?$.value:$;if(Z&&typeof Z==="string")Z=Number(Z);return typeof Z==="number"&&Number.isInteger(Z)&&Z>=0?Z:null}w5.YAMLSeq=v3});var C0=D((S5)=>{var C5=b(),m3=J0(),j5={collection:"seq",default:!0,nodeClass:m3.YAMLSeq,tag:"tag:yaml.org,2002:seq",resolve($,Z){if(!C5.isSeq($))Z("Expected a sequence for this tag");return $},createNode:($,Z,z)=>m3.YAMLSeq.from($,Z,z)};S5.seq=j5});var U$=D((y5)=>{var g5=e0(),f5={identify:($)=>typeof $==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:($)=>$,stringify($,Z,z,X){return Z=Object.assign({actualString:!0},Z),g5.stringifyString($,Z,z,X)}};y5.string=f5});var c$=D((x5)=>{var p3=g(),l3={identify:($)=>$==null,createNode:()=>new p3.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new p3.Scalar(null),stringify:({source:$},Z)=>typeof $==="string"&&l3.test.test($)?$:Z.options.nullStr};x5.nullTag=l3});var v1=D((v5)=>{var k5=g(),d3={identify:($)=>typeof $==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:($)=>new k5.Scalar($[0]==="t"||$[0]==="T"),stringify({source:$,value:Z},z){if($&&d3.test.test($)){let X=$[0]==="t"||$[0]==="T";if(Z===X)return $}return Z?z.options.trueStr:z.options.falseStr}};v5.boolTag=d3});var j0=D((l5)=>{function p5({format:$,minFractionDigits:Z,tag:z,value:X}){if(typeof X==="bigint")return String(X);let U=typeof X==="number"?X:Number(X);if(!isFinite(U))return isNaN(U)?".nan":U<0?"-.inf":".inf";let Q=Object.is(X,-0)?"-0":JSON.stringify(X);if(!$&&Z&&(!z||z==="tag:yaml.org,2002:float")&&/^\d/.test(Q)){let J=Q.indexOf(".");if(J<0)J=Q.length,Q+=".";let H=Z-(Q.length-J-1);while(H-- >0)Q+="0"}return Q}l5.stringifyNumber=p5});var p1=D((r5)=>{var c5=g(),m1=j0(),i5={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:($)=>$.slice(-3).toLowerCase()==="nan"?NaN:$[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:m1.stringifyNumber},s5={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:($)=>parseFloat($),stringify($){let Z=Number($.value);return isFinite(Z)?Z.toExponential():m1.stringifyNumber($)}},a5={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve($){let Z=new c5.Scalar(parseFloat($)),z=$.indexOf(".");if(z!==-1&&$[$.length-1]==="0")Z.minFractionDigits=$.length-z-1;return Z},stringify:m1.stringifyNumber};r5.float=a5;r5.floatExp=s5;r5.floatNaN=i5});var d1=D((zz)=>{var c3=j0(),i$=($)=>typeof $==="bigint"||Number.isInteger($),l1=($,Z,z,{intAsBigInt:X})=>X?BigInt($):parseInt($.substring(Z),z);function i3($,Z,z){let{value:X}=$;if(i$(X)&&X>=0)return z+X.toString(Z);return c3.stringifyNumber($)}var e5={identify:($)=>i$($)&&$>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:($,Z,z)=>l1($,2,8,z),stringify:($)=>i3($,8,"0o")},$z={identify:i$,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:($,Z,z)=>l1($,0,10,z),stringify:c3.stringifyNumber},Zz={identify:($)=>i$($)&&$>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:($,Z,z)=>l1($,2,16,z),stringify:($)=>i3($,16,"0x")};zz.int=$z;zz.intHex=Zz;zz.intOct=e5});var s3=D((Bz)=>{var Jz=b0(),Hz=c$(),Gz=C0(),_z=U$(),Yz=v1(),c1=p1(),i1=d1(),qz=[Jz.map,Gz.seq,_z.string,Hz.nullTag,Yz.boolTag,i1.intOct,i1.int,i1.intHex,c1.floatNaN,c1.floatExp,c1.float];Bz.schema=qz});var r3=D((Fz)=>{var Oz=g(),Wz=b0(),Iz=C0();function a3($){return typeof $==="bigint"||Number.isInteger($)}var s$=({value:$})=>JSON.stringify($),Lz=[{identify:($)=>typeof $==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:($)=>$,stringify:s$},{identify:($)=>$==null,createNode:()=>new Oz.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:s$},{identify:($)=>typeof $==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:($)=>$==="true",stringify:s$},{identify:a3,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:($,Z,{intAsBigInt:z})=>z?BigInt($):parseInt($,10),stringify:({value:$})=>a3($)?$.toString():JSON.stringify($)},{identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:($)=>parseFloat($),stringify:s$}],Dz={default:!0,tag:"",test:/^/,resolve($,Z){return Z(`Unresolved plain scalar ${JSON.stringify($)}`),$}},Rz=[Wz.map,Iz.seq].concat(Lz,Dz);Fz.schema=Rz});var a1=D((Tz)=>{var Q$=p0("buffer"),s1=g(),Kz=e0(),Pz={identify:($)=>$ instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve($,Z){if(typeof Q$.Buffer==="function")return Q$.Buffer.from($,"base64");else if(typeof atob==="function"){let z=atob($.replace(/[\n\r]/g,"")),X=new Uint8Array(z.length);for(let U=0;U<z.length;++U)X[U]=z.charCodeAt(U);return X}else return Z("This environment does not support reading binary tags; either Buffer or atob is required"),$},stringify({comment:$,type:Z,value:z},X,U,Q){if(!z)return"";let J=z,H;if(typeof Q$.Buffer==="function")H=J instanceof Q$.Buffer?J.toString("base64"):Q$.Buffer.from(J.buffer).toString("base64");else if(typeof btoa==="function"){let G="";for(let _=0;_<J.length;++_)G+=String.fromCharCode(J[_]);H=btoa(G)}else throw Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(Z??(Z=s1.Scalar.BLOCK_LITERAL),Z!==s1.Scalar.QUOTE_DOUBLE){let G=Math.max(X.options.lineWidth-X.indent.length,X.options.minContentWidth),_=Math.ceil(H.length/G),B=Array(_);for(let Y=0,q=0;Y<_;++Y,q+=G)B[Y]=H.substr(q,G);H=B.join(Z===s1.Scalar.BLOCK_LITERAL?`
52
- `:" ")}return Kz.stringifyString({comment:$,type:Z,value:H},X,U,Q)}};Tz.binary=Pz});var r$=D((Cz)=>{var a$=b(),r1=X0(),Nz=g(),wz=J0();function n3($,Z){if(a$.isSeq($))for(let z=0;z<$.items.length;++z){let X=$.items[z];if(a$.isPair(X))continue;else if(a$.isMap(X)){if(X.items.length>1)Z("Each pair must have its own sequence indicator");let U=X.items[0]||new r1.Pair(new Nz.Scalar(null));if(X.commentBefore)U.key.commentBefore=U.key.commentBefore?`${X.commentBefore}
53
- ${U.key.commentBefore}`:X.commentBefore;if(X.comment){let Q=U.value??U.key;Q.comment=Q.comment?`${X.comment}
54
- ${Q.comment}`:X.comment}X=U}$.items[z]=a$.isPair(X)?X:new r1.Pair(X)}else Z("Expected a sequence for this tag");return $}function o3($,Z,z){let{replacer:X}=z,U=new wz.YAMLSeq($);U.tag="tag:yaml.org,2002:pairs";let Q=0;if(Z&&Symbol.iterator in Object(Z))for(let J of Z){if(typeof X==="function")J=X.call(Z,String(Q++),J);let H,G;if(Array.isArray(J))if(J.length===2)H=J[0],G=J[1];else throw TypeError(`Expected [key, value] tuple: ${J}`);else if(J&&J instanceof Object){let _=Object.keys(J);if(_.length===1)H=_[0],G=J[H];else throw TypeError(`Expected tuple with one key, not ${_.length} keys`)}else H=J;U.items.push(r1.createPair(H,G,z))}return U}var bz={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:n3,createNode:o3};Cz.createPairs=o3;Cz.pairs=bz;Cz.resolvePairs=n3});var o1=D((yz)=>{var t3=b(),n1=$0(),J$=Q0(),gz=J0(),e3=r$();class O0 extends gz.YAMLSeq{constructor(){super();this.add=J$.YAMLMap.prototype.add.bind(this),this.delete=J$.YAMLMap.prototype.delete.bind(this),this.get=J$.YAMLMap.prototype.get.bind(this),this.has=J$.YAMLMap.prototype.has.bind(this),this.set=J$.YAMLMap.prototype.set.bind(this),this.tag=O0.tag}toJSON($,Z){if(!Z)return super.toJSON($);let z=new Map;if(Z?.onCreate)Z.onCreate(z);for(let X of this.items){let U,Q;if(t3.isPair(X))U=n1.toJS(X.key,"",Z),Q=n1.toJS(X.value,U,Z);else U=n1.toJS(X,"",Z);if(z.has(U))throw Error("Ordered maps must not include duplicate keys");z.set(U,Q)}return z}static from($,Z,z){let X=e3.createPairs($,Z,z),U=new this;return U.items=X.items,U}}O0.tag="tag:yaml.org,2002:omap";var fz={collection:"seq",identify:($)=>$ instanceof Map,nodeClass:O0,default:!1,tag:"tag:yaml.org,2002:omap",resolve($,Z){let z=e3.resolvePairs($,Z),X=[];for(let{key:U}of z.items)if(t3.isScalar(U))if(X.includes(U.value))Z(`Ordered maps must not include duplicate keys: ${U.value}`);else X.push(U.value);return Object.assign(new O0,z)},createNode:($,Z,z)=>O0.from($,Z,z)};yz.YAMLOMap=O0;yz.omap=fz});var U8=D((uz)=>{var $8=g();function Z8({value:$,source:Z},z){if(Z&&($?z8:X8).test.test(Z))return Z;return $?z.options.trueStr:z.options.falseStr}var z8={identify:($)=>$===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new $8.Scalar(!0),stringify:Z8},X8={identify:($)=>$===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new $8.Scalar(!1),stringify:Z8};uz.falseTag=X8;uz.trueTag=z8});var Q8=D((cz)=>{var mz=g(),t1=j0(),pz={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:($)=>$.slice(-3).toLowerCase()==="nan"?NaN:$[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:t1.stringifyNumber},lz={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:($)=>parseFloat($.replace(/_/g,"")),stringify($){let Z=Number($.value);return isFinite(Z)?Z.toExponential():t1.stringifyNumber($)}},dz={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve($){let Z=new mz.Scalar(parseFloat($.replace(/_/g,""))),z=$.indexOf(".");if(z!==-1){let X=$.substring(z+1).replace(/_/g,"");if(X[X.length-1]==="0")Z.minFractionDigits=X.length}return Z},stringify:t1.stringifyNumber};cz.float=dz;cz.floatExp=lz;cz.floatNaN=pz});var H8=D((ez)=>{var J8=j0(),H$=($)=>typeof $==="bigint"||Number.isInteger($);function n$($,Z,z,{intAsBigInt:X}){let U=$[0];if(U==="-"||U==="+")Z+=1;if($=$.substring(Z).replace(/_/g,""),X){switch(z){case 2:$=`0b${$}`;break;case 8:$=`0o${$}`;break;case 16:$=`0x${$}`;break}let J=BigInt($);return U==="-"?BigInt(-1)*J:J}let Q=parseInt($,z);return U==="-"?-1*Q:Q}function e1($,Z,z){let{value:X}=$;if(H$(X)){let U=X.toString(Z);return X<0?"-"+z+U.substr(1):z+U}return J8.stringifyNumber($)}var rz={identify:H$,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:($,Z,z)=>n$($,2,2,z),stringify:($)=>e1($,2,"0b")},nz={identify:H$,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:($,Z,z)=>n$($,1,8,z),stringify:($)=>e1($,8,"0")},oz={identify:H$,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:($,Z,z)=>n$($,0,10,z),stringify:J8.stringifyNumber},tz={identify:H$,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:($,Z,z)=>n$($,2,16,z),stringify:($)=>e1($,16,"0x")};ez.int=oz;ez.intBin=rz;ez.intHex=tz;ez.intOct=nz});var $2=D((Q7)=>{var e$=b(),o$=X0(),t$=Q0();class W0 extends t$.YAMLMap{constructor($){super($);this.tag=W0.tag}add($){let Z;if(e$.isPair($))Z=$;else if($&&typeof $==="object"&&"key"in $&&"value"in $&&$.value===null)Z=new o$.Pair($.key,null);else Z=new o$.Pair($,null);if(!t$.findPair(this.items,Z.key))this.items.push(Z)}get($,Z){let z=t$.findPair(this.items,$);return!Z&&e$.isPair(z)?e$.isScalar(z.key)?z.key.value:z.key:z}set($,Z){if(typeof Z!=="boolean")throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof Z}`);let z=t$.findPair(this.items,$);if(z&&!Z)this.items.splice(this.items.indexOf(z),1);else if(!z&&Z)this.items.push(new o$.Pair($))}toJSON($,Z){return super.toJSON($,Z,Set)}toString($,Z,z){if(!$)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},$,{allNullValues:!0}),Z,z);else throw Error("Set items must all have null values")}static from($,Z,z){let{replacer:X}=z,U=new this($);if(Z&&Symbol.iterator in Object(Z))for(let Q of Z){if(typeof X==="function")Q=X.call(Z,Q,Q);U.items.push(o$.createPair(Q,null,z))}return U}}W0.tag="tag:yaml.org,2002:set";var U7={collection:"map",identify:($)=>$ instanceof Set,nodeClass:W0,default:!1,tag:"tag:yaml.org,2002:set",createNode:($,Z,z)=>W0.from($,Z,z),resolve($,Z){if(e$.isMap($))if($.hasAllNullValues(!0))return Object.assign(new W0,$);else Z("Set items must all have null values");else Z("Expected a mapping for this tag");return $}};Q7.YAMLSet=W0;Q7.set=U7});var z2=D((q7)=>{var G7=j0();function Z2($,Z){let z=$[0],X=z==="-"||z==="+"?$.substring(1):$,U=(J)=>Z?BigInt(J):Number(J),Q=X.replace(/_/g,"").split(":").reduce((J,H)=>J*U(60)+U(H),U(0));return z==="-"?U(-1)*Q:Q}function G8($){let{value:Z}=$,z=(J)=>J;if(typeof Z==="bigint")z=(J)=>BigInt(J);else if(isNaN(Z)||!isFinite(Z))return G7.stringifyNumber($);let X="";if(Z<0)X="-",Z*=z(-1);let U=z(60),Q=[Z%U];if(Z<60)Q.unshift(0);else if(Z=(Z-Q[0])/U,Q.unshift(Z%U),Z>=60)Z=(Z-Q[0])/U,Q.unshift(Z);return X+Q.map((J)=>String(J).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}var _7={identify:($)=>typeof $==="bigint"||Number.isInteger($),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:($,Z,{intAsBigInt:z})=>Z2($,z),stringify:G8},Y7={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:($)=>Z2($,!1),stringify:G8},_8={identify:($)=>$ instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve($){let Z=$.match(_8.test);if(!Z)throw Error("!!timestamp expects a date, starting with yyyy-mm-dd");let[,z,X,U,Q,J,H]=Z.map(Number),G=Z[7]?Number((Z[7]+"00").substr(1,3)):0,_=Date.UTC(z,X-1,U,Q||0,J||0,H||0,G),B=Z[8];if(B&&B!=="Z"){let Y=Z2(B,!1);if(Math.abs(Y)<30)Y*=60;_-=60000*Y}return new Date(_)},stringify:({value:$})=>$?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""};q7.floatTime=Y7;q7.intTime=_7;q7.timestamp=_8});var q8=D((A7)=>{var W7=b0(),I7=c$(),L7=C0(),D7=U$(),R7=a1(),Y8=U8(),X2=Q8(),$1=H8(),F7=x$(),M7=o1(),K7=r$(),P7=$2(),U2=z2(),T7=[W7.map,L7.seq,D7.string,I7.nullTag,Y8.trueTag,Y8.falseTag,$1.intBin,$1.intOct,$1.int,$1.intHex,X2.floatNaN,X2.floatExp,X2.float,R7.binary,F7.merge,M7.omap,K7.pairs,P7.set,U2.intTime,U2.floatTime,U2.timestamp];A7.schema=T7});var M8=D((f7)=>{var W8=b0(),w7=c$(),I8=C0(),b7=U$(),C7=v1(),Q2=p1(),J2=d1(),j7=s3(),S7=r3(),L8=a1(),G$=x$(),D8=o1(),R8=r$(),B8=q8(),F8=$2(),Z1=z2(),V8=new Map([["core",j7.schema],["failsafe",[W8.map,I8.seq,b7.string]],["json",S7.schema],["yaml11",B8.schema],["yaml-1.1",B8.schema]]),O8={binary:L8.binary,bool:C7.boolTag,float:Q2.float,floatExp:Q2.floatExp,floatNaN:Q2.floatNaN,floatTime:Z1.floatTime,int:J2.int,intHex:J2.intHex,intOct:J2.intOct,intTime:Z1.intTime,map:W8.map,merge:G$.merge,null:w7.nullTag,omap:D8.omap,pairs:R8.pairs,seq:I8.seq,set:F8.set,timestamp:Z1.timestamp},E7={"tag:yaml.org,2002:binary":L8.binary,"tag:yaml.org,2002:merge":G$.merge,"tag:yaml.org,2002:omap":D8.omap,"tag:yaml.org,2002:pairs":R8.pairs,"tag:yaml.org,2002:set":F8.set,"tag:yaml.org,2002:timestamp":Z1.timestamp};function g7($,Z,z){let X=V8.get(Z);if(X&&!$)return z&&!X.includes(G$.merge)?X.concat(G$.merge):X.slice();let U=X;if(!U)if(Array.isArray($))U=[];else{let Q=Array.from(V8.keys()).filter((J)=>J!=="yaml11").map((J)=>JSON.stringify(J)).join(", ");throw Error(`Unknown schema "${Z}"; use one of ${Q} or define customTags array`)}if(Array.isArray($))for(let Q of $)U=U.concat(Q);else if(typeof $==="function")U=$(U.slice());if(z)U=U.concat(G$.merge);return U.reduce((Q,J)=>{let H=typeof J==="string"?O8[J]:J;if(!H){let G=JSON.stringify(J),_=Object.keys(O8).map((B)=>JSON.stringify(B)).join(", ");throw Error(`Unknown custom tag ${G}; use one of ${_}`)}if(!Q.includes(H))Q.push(H);return Q},[])}f7.coreKnownTags=E7;f7.getTags=g7});var _2=D((m7)=>{var H2=b(),x7=b0(),u7=C0(),k7=U$(),z1=M8(),v7=($,Z)=>$.key<Z.key?-1:$.key>Z.key?1:0;class G2{constructor({compat:$,customTags:Z,merge:z,resolveKnownTags:X,schema:U,sortMapEntries:Q,toStringDefaults:J}){this.compat=Array.isArray($)?z1.getTags($,"compat"):$?z1.getTags(null,$):null,this.name=typeof U==="string"&&U||"core",this.knownTags=X?z1.coreKnownTags:{},this.tags=z1.getTags(Z,this.name,z),this.toStringOptions=J??null,Object.defineProperty(this,H2.MAP,{value:x7.map}),Object.defineProperty(this,H2.SCALAR,{value:k7.string}),Object.defineProperty(this,H2.SEQ,{value:u7.seq}),this.sortMapEntries=typeof Q==="function"?Q:Q===!0?v7:null}clone(){let $=Object.create(G2.prototype,Object.getOwnPropertyDescriptors(this));return $.tags=this.tags.slice(),$}}m7.Schema=G2});var K8=D((c7)=>{var l7=b(),Y2=$$(),_$=o0();function d7($,Z){let z=[],X=Z.directives===!0;if(Z.directives!==!1&&$.directives){let G=$.directives.toString($);if(G)z.push(G),X=!0;else if($.directives.docStart)X=!0}if(X)z.push("---");let U=Y2.createStringifyContext($,Z),{commentString:Q}=U.options;if($.commentBefore){if(z.length!==1)z.unshift("");let G=Q($.commentBefore);z.unshift(_$.indentComment(G,""))}let J=!1,H=null;if($.contents){if(l7.isNode($.contents)){if($.contents.spaceBefore&&X)z.push("");if($.contents.commentBefore){let B=Q($.contents.commentBefore);z.push(_$.indentComment(B,""))}U.forceBlockIndent=!!$.comment,H=$.contents.comment}let G=H?void 0:()=>J=!0,_=Y2.stringify($.contents,U,()=>H=null,G);if(H)_+=_$.lineComment(_,"",Q(H));if((_[0]==="|"||_[0]===">")&&z[z.length-1]==="---")z[z.length-1]=`--- ${_}`;else z.push(_)}else z.push(Y2.stringify($.contents,U));if($.directives?.docEnd)if($.comment){let G=Q($.comment);if(G.includes(`
55
- `))z.push("..."),z.push(_$.indentComment(G,""));else z.push(`... ${G}`)}else z.push("...");else{let G=$.comment;if(G&&J)G=G.replace(/^\n+/,"");if(G){if((!J||H)&&z[z.length-1]!=="")z.push("");z.push(_$.indentComment(Q(G),""))}}return z.join(`
40
+ `}else N+=`
41
+ ${U.indent}`}else if(!O&&t.isCollection(Z)){let b=T[0],P=T.indexOf(`
42
+ `),w=P!==-1,v=U.inFlow??Z.flow??Z.items.length===0;if(w||!v){let S=!1;if(w&&(b==="&"||b==="!")){let g=T.indexOf(" ");if(b==="&"&&g!==-1&&g<P&&T[g+1]==="!")g=T.indexOf(" ",g+1);if(g===-1||P<g)S=!0}if(!S)N=`
43
+ ${U.indent}`}}else if(T===""||T[0]===`
44
+ `)N="";if(W+=N+T,U.inFlow){if(A&&X)X()}else if(F&&!A)W+=J1.lineComment(W,U.indent,Y(F));else if(V&&Q)Q();return W}Z5.stringifyPair=$5});var i$=R((z5)=>{var d3=r0("process");function X5($,...Z){if($==="debug")console.log(...Z)}function Q5($,Z){if($==="debug"||$==="warn")if(typeof d3.emitWarning==="function")d3.emitWarning(Z);else console.warn(Z)}z5.debug=X5;z5.warn=Q5});var i1=R((Y5)=>{var H1=C(),c3=x(),d1="<<",c1={identify:($)=>$===d1||typeof $==="symbol"&&$.description===d1,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new c3.Scalar(Symbol(d1)),{addToJSMap:i3}),stringify:()=>d1},q5=($,Z)=>(c1.identify(Z)||H1.isScalar(Z)&&(!Z.type||Z.type===c3.Scalar.PLAIN)&&c1.identify(Z.value))&&$?.doc.schema.tags.some((U)=>U.tag===c1.tag&&U.default);function i3($,Z,U){if(U=$&&H1.isAlias(U)?U.resolve($.doc):U,H1.isSeq(U))for(let X of U.items)r$($,Z,X);else if(Array.isArray(U))for(let X of U)r$($,Z,X);else r$($,Z,U)}function r$($,Z,U){let X=$&&H1.isAlias(U)?U.resolve($.doc):U;if(!H1.isMap(X))throw Error("Merge sources must be maps or map aliases");let Q=X.toJSON(null,$,Map);for(let[z,J]of Q)if(Z instanceof Map){if(!Z.has(z))Z.set(z,J)}else if(Z instanceof Set)Z.add(z);else if(!Object.prototype.hasOwnProperty.call(Z,z))Object.defineProperty(Z,z,{value:J,writable:!0,enumerable:!0,configurable:!0});return Z}Y5.addMergeToJSMap=i3;Y5.isMergeKey=q5;Y5.merge=c1});var a$=R((I5)=>{var V5=i$(),r3=i1(),O5=z1(),s3=C(),s$=X0();function W5($,Z,{key:U,value:X}){if(s3.isNode(U)&&U.addToJSMap)U.addToJSMap($,Z,X);else if(r3.isMergeKey($,U))r3.addMergeToJSMap($,Z,X);else{let Q=s$.toJS(U,"",$);if(Z instanceof Map)Z.set(Q,s$.toJS(X,Q,$));else if(Z instanceof Set)Z.add(Q);else{let z=D5(U,Q,$),J=s$.toJS(X,z,$);if(z in Z)Object.defineProperty(Z,z,{value:J,writable:!0,enumerable:!0,configurable:!0});else Z[z]=J}}return Z}function D5($,Z,U){if(Z===null)return"";if(typeof Z!=="object")return String(Z);if(s3.isNode($)&&U?.doc){let X=O5.createStringifyContext(U.doc,{});X.anchors=new Set;for(let z of U.anchors.keys())X.anchors.add(z.anchor);X.inFlow=!0,X.inStringifyKey=!0;let Q=$.toString(X);if(!U.mapKeyWarned){let z=JSON.stringify(Q);if(z.length>40)z=z.substring(0,36)+'..."';V5.warn(U.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${z}. Set mapAsMap: true to use object keys.`),U.mapKeyWarned=!0}return Q}return JSON.stringify(Z)}I5.addPairToJSMap=W5});var J0=R((F5)=>{var a3=Z1(),R5=l3(),M5=a$(),r1=C();function K5($,Z,U){let X=a3.createNode($,void 0,U),Q=a3.createNode(Z,void 0,U);return new s1(X,Q)}class s1{constructor($,Z=null){Object.defineProperty(this,r1.NODE_TYPE,{value:r1.PAIR}),this.key=$,this.value=Z}clone($){let{key:Z,value:U}=this;if(r1.isNode(Z))Z=Z.clone($);if(r1.isNode(U))U=U.clone($);return new s1(Z,U)}toJSON($,Z){let U=Z?.mapAsMap?new Map:{};return M5.addPairToJSMap(Z,U,this)}toString($,Z,U){return $?.doc?R5.stringifyPair(this,$,Z,U):JSON.stringify(this)}}F5.Pair=s1;F5.createPair=K5});var n$=R((C5)=>{var D0=C(),n3=z1(),a1=U1();function T5($,Z,U){return(Z.inFlow??$.flow?w5:N5)($,Z,U)}function N5({comment:$,items:Z},U,{blockItemPrefix:X,flowChars:Q,itemIndent:z,onChompKeep:J,onComment:H}){let{indent:q,options:{commentString:Y}}=U,G=Object.assign({},U,{indent:z,type:null}),_=!1,B=[];for(let D=0;D<Z.length;++D){let V=Z[D],W=null;if(D0.isNode(V)){if(!_&&V.spaceBefore)B.push("");if(n1(U,B,V.commentBefore,_),V.comment)W=V.comment}else if(D0.isPair(V)){let L=D0.isNode(V.key)?V.key:null;if(L){if(!_&&L.spaceBefore)B.push("");n1(U,B,L.commentBefore,_)}}_=!1;let I=n3.stringify(V,G,()=>W=null,()=>_=!0);if(W)I+=a1.lineComment(I,z,Y(W));if(_&&W)_=!1;B.push(X+I)}let O;if(B.length===0)O=Q.start+Q.end;else{O=B[0];for(let D=1;D<B.length;++D){let V=B[D];O+=V?`
45
+ ${q}${V}`:`
46
+ `}}if($){if(O+=`
47
+ `+a1.indentComment(Y($),q),H)H()}else if(_&&J)J();return O}function w5({items:$},Z,{flowChars:U,itemIndent:X}){let{indent:Q,indentStep:z,flowCollectionPadding:J,options:{commentString:H}}=Z;X+=z;let q=Object.assign({},Z,{indent:X,inFlow:!0,type:null}),Y=!1,G=0,_=[];for(let D=0;D<$.length;++D){let V=$[D],W=null;if(D0.isNode(V)){if(V.spaceBefore)_.push("");if(n1(Z,_,V.commentBefore,!1),V.comment)W=V.comment}else if(D0.isPair(V)){let L=D0.isNode(V.key)?V.key:null;if(L){if(L.spaceBefore)_.push("");if(n1(Z,_,L.commentBefore,!1),L.comment)Y=!0}let F=D0.isNode(V.value)?V.value:null;if(F){if(F.comment)W=F.comment;if(F.commentBefore)Y=!0}else if(V.value==null&&L?.comment)W=L.comment}if(W)Y=!0;let I=n3.stringify(V,q,()=>W=null);if(Y||(Y=_.length>G||I.includes(`
48
+ `)),D<$.length-1)I+=",";else if(Z.options.trailingComma){if(Z.options.lineWidth>0)Y||(Y=_.reduce((L,F)=>L+F.length+2,2)+(I.length+2)>Z.options.lineWidth);if(Y)I+=","}if(W)I+=a1.lineComment(I,X,H(W));_.push(I),G=_.length}let{start:B,end:O}=U;if(_.length===0)return B+O;else{if(!Y){let D=_.reduce((V,W)=>V+W.length+2,2);Y=Z.options.lineWidth>0&&D>Z.options.lineWidth}if(Y){let D=B;for(let V of _)D+=V?`
49
+ ${z}${Q}${V}`:`
50
+ `;return`${D}
51
+ ${Q}${O}`}else return`${B}${J}${_.join(" ")}${J}${O}`}}function n1({indent:$,options:{commentString:Z}},U,X,Q){if(X&&Q)X=X.replace(/^\n+/,"");if(X){let z=a1.indentComment(Z(X),$);U.push(z.trimStart())}}C5.stringifyCollection=T5});var q0=R((x5)=>{var S5=n$(),E5=a$(),j5=v1(),H0=C(),o1=J0(),g5=x();function q1($,Z){let U=H0.isScalar(Z)?Z.value:Z;for(let X of $)if(H0.isPair(X)){if(X.key===Z||X.key===U)return X;if(H0.isScalar(X.key)&&X.key.value===U)return X}return}class o3 extends j5.Collection{static get tagName(){return"tag:yaml.org,2002:map"}constructor($){super(H0.MAP,$);this.items=[]}static from($,Z,U){let{keepUndefined:X,replacer:Q}=U,z=new this($),J=(H,q)=>{if(typeof Q==="function")q=Q.call(Z,H,q);else if(Array.isArray(Q)&&!Q.includes(H))return;if(q!==void 0||X)z.items.push(o1.createPair(H,q,U))};if(Z instanceof Map)for(let[H,q]of Z)J(H,q);else if(Z&&typeof Z==="object")for(let H of Object.keys(Z))J(H,Z[H]);if(typeof $.sortMapEntries==="function")z.items.sort($.sortMapEntries);return z}add($,Z){let U;if(H0.isPair($))U=$;else if(!$||typeof $!=="object"||!("key"in $))U=new o1.Pair($,$?.value);else U=new o1.Pair($.key,$.value);let X=q1(this.items,U.key),Q=this.schema?.sortMapEntries;if(X){if(!Z)throw Error(`Key ${U.key} already set`);if(H0.isScalar(X.value)&&g5.isScalarValue(U.value))X.value.value=U.value;else X.value=U.value}else if(Q){let z=this.items.findIndex((J)=>Q(U,J)<0);if(z===-1)this.items.push(U);else this.items.splice(z,0,U)}else this.items.push(U)}delete($){let Z=q1(this.items,$);if(!Z)return!1;return this.items.splice(this.items.indexOf(Z),1).length>0}get($,Z){let X=q1(this.items,$)?.value;return(!Z&&H0.isScalar(X)?X.value:X)??void 0}has($){return!!q1(this.items,$)}set($,Z){this.add(new o1.Pair($,Z),!0)}toJSON($,Z,U){let X=U?new U:Z?.mapAsMap?new Map:{};if(Z?.onCreate)Z.onCreate(X);for(let Q of this.items)E5.addPairToJSMap(Z,X,Q);return X}toString($,Z,U){if(!$)return JSON.stringify(this);for(let X of this.items)if(!H0.isPair(X))throw Error(`Map items must all be pairs; found ${JSON.stringify(X)} instead`);if(!$.allNullValues&&this.hasAllNullValues(!1))$=Object.assign({},$,{allNullValues:!0});return S5.stringifyCollection(this,$,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:$.indent||"",onChompKeep:U,onComment:Z})}}x5.YAMLMap=o3;x5.findPair=q1});var g0=R((k5)=>{var f5=C(),t3=q0(),u5={collection:"map",default:!0,nodeClass:t3.YAMLMap,tag:"tag:yaml.org,2002:map",resolve($,Z){if(!f5.isMap($))Z("Expected a mapping for this tag");return $},createNode:($,Z,U)=>t3.YAMLMap.from($,Z,U)};k5.map=u5});var Y0=R((i5)=>{var m5=Z1(),p5=n$(),l5=v1(),e1=C(),d5=x(),c5=X0();class e3 extends l5.Collection{static get tagName(){return"tag:yaml.org,2002:seq"}constructor($){super(e1.SEQ,$);this.items=[]}add($){this.items.push($)}delete($){let Z=t1($);if(typeof Z!=="number")return!1;return this.items.splice(Z,1).length>0}get($,Z){let U=t1($);if(typeof U!=="number")return;let X=this.items[U];return!Z&&e1.isScalar(X)?X.value:X}has($){let Z=t1($);return typeof Z==="number"&&Z<this.items.length}set($,Z){let U=t1($);if(typeof U!=="number")throw Error(`Expected a valid index, not ${$}.`);let X=this.items[U];if(e1.isScalar(X)&&d5.isScalarValue(Z))X.value=Z;else this.items[U]=Z}toJSON($,Z){let U=[];if(Z?.onCreate)Z.onCreate(U);let X=0;for(let Q of this.items)U.push(c5.toJS(Q,String(X++),Z));return U}toString($,Z,U){if(!$)return JSON.stringify(this);return p5.stringifyCollection(this,$,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:($.indent||"")+" ",onChompKeep:U,onComment:Z})}static from($,Z,U){let{replacer:X}=U,Q=new this($);if(Z&&Symbol.iterator in Object(Z)){let z=0;for(let J of Z){if(typeof X==="function"){let H=Z instanceof Set?J:String(z++);J=X.call(Z,H,J)}Q.items.push(m5.createNode(J,void 0,U))}}return Q}}function t1($){let Z=e1.isScalar($)?$.value:$;if(Z&&typeof Z==="string")Z=Number(Z);return typeof Z==="number"&&Number.isInteger(Z)&&Z>=0?Z:null}i5.YAMLSeq=e3});var x0=R((n5)=>{var s5=C(),$8=Y0(),a5={collection:"seq",default:!0,nodeClass:$8.YAMLSeq,tag:"tag:yaml.org,2002:seq",resolve($,Z){if(!s5.isSeq($))Z("Expected a sequence for this tag");return $},createNode:($,Z,U)=>$8.YAMLSeq.from($,Z,U)};n5.seq=a5});var Y1=R(($7)=>{var t5=Q1(),e5={identify:($)=>typeof $==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:($)=>$,stringify($,Z,U,X){return Z=Object.assign({actualString:!0},Z),t5.stringifyString($,Z,U,X)}};$7.string=e5});var $$=R((U7)=>{var Z8=x(),U8={identify:($)=>$==null,createNode:()=>new Z8.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new Z8.Scalar(null),stringify:({source:$},Z)=>typeof $==="string"&&U8.test.test($)?$:Z.options.nullStr};U7.nullTag=U8});var o$=R((z7)=>{var Q7=x(),X8={identify:($)=>typeof $==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:($)=>new Q7.Scalar($[0]==="t"||$[0]==="T"),stringify({source:$,value:Z},U){if($&&X8.test.test($)){let X=$[0]==="t"||$[0]==="T";if(Z===X)return $}return Z?U.options.trueStr:U.options.falseStr}};z7.boolTag=X8});var h0=R((q7)=>{function H7({format:$,minFractionDigits:Z,tag:U,value:X}){if(typeof X==="bigint")return String(X);let Q=typeof X==="number"?X:Number(X);if(!isFinite(Q))return isNaN(Q)?".nan":Q<0?"-.inf":".inf";let z=Object.is(X,-0)?"-0":JSON.stringify(X);if(!$&&Z&&(!U||U==="tag:yaml.org,2002:float")&&/^\d/.test(z)){let J=z.indexOf(".");if(J<0)J=z.length,z+=".";let H=Z-(z.length-J-1);while(H-- >0)z+="0"}return z}q7.stringifyNumber=H7});var e$=R((O7)=>{var G7=x(),t$=h0(),_7={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:($)=>$.slice(-3).toLowerCase()==="nan"?NaN:$[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:t$.stringifyNumber},B7={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:($)=>parseFloat($),stringify($){let Z=Number($.value);return isFinite(Z)?Z.toExponential():t$.stringifyNumber($)}},V7={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve($){let Z=new G7.Scalar(parseFloat($)),U=$.indexOf(".");if(U!==-1&&$[$.length-1]==="0")Z.minFractionDigits=$.length-U-1;return Z},stringify:t$.stringifyNumber};O7.float=V7;O7.floatExp=B7;O7.floatNaN=_7});var Z2=R((K7)=>{var Q8=h0(),Z$=($)=>typeof $==="bigint"||Number.isInteger($),$2=($,Z,U,{intAsBigInt:X})=>X?BigInt($):parseInt($.substring(Z),U);function z8($,Z,U){let{value:X}=$;if(Z$(X)&&X>=0)return U+X.toString(Z);return Q8.stringifyNumber($)}var L7={identify:($)=>Z$($)&&$>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:($,Z,U)=>$2($,2,8,U),stringify:($)=>z8($,8,"0o")},R7={identify:Z$,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:($,Z,U)=>$2($,0,10,U),stringify:Q8.stringifyNumber},M7={identify:($)=>Z$($)&&$>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:($,Z,U)=>$2($,2,16,U),stringify:($)=>z8($,16,"0x")};K7.int=R7;K7.intHex=M7;K7.intOct=L7});var J8=R((E7)=>{var T7=g0(),N7=$$(),w7=x0(),C7=Y1(),b7=o$(),U2=e$(),X2=Z2(),S7=[T7.map,w7.seq,C7.string,N7.nullTag,b7.boolTag,X2.intOct,X2.int,X2.intHex,U2.floatNaN,U2.floatExp,U2.float];E7.schema=S7});var q8=R((k7)=>{var g7=x(),x7=g0(),h7=x0();function H8($){return typeof $==="bigint"||Number.isInteger($)}var U$=({value:$})=>JSON.stringify($),y7=[{identify:($)=>typeof $==="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:($)=>$,stringify:U$},{identify:($)=>$==null,createNode:()=>new g7.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:U$},{identify:($)=>typeof $==="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:($)=>$==="true",stringify:U$},{identify:H8,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:($,Z,{intAsBigInt:U})=>U?BigInt($):parseInt($,10),stringify:({value:$})=>H8($)?$.toString():JSON.stringify($)},{identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:($)=>parseFloat($),stringify:U$}],f7={default:!0,tag:"",test:/^/,resolve($,Z){return Z(`Unresolved plain scalar ${JSON.stringify($)}`),$}},u7=[x7.map,h7.seq].concat(y7,f7);k7.schema=u7});var z2=R((l7)=>{var G1=r0("buffer"),Q2=x(),m7=Q1(),p7={identify:($)=>$ instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve($,Z){if(typeof G1.Buffer==="function")return G1.Buffer.from($,"base64");else if(typeof atob==="function"){let U=atob($.replace(/[\n\r]/g,"")),X=new Uint8Array(U.length);for(let Q=0;Q<U.length;++Q)X[Q]=U.charCodeAt(Q);return X}else return Z("This environment does not support reading binary tags; either Buffer or atob is required"),$},stringify({comment:$,type:Z,value:U},X,Q,z){if(!U)return"";let J=U,H;if(typeof G1.Buffer==="function")H=J instanceof G1.Buffer?J.toString("base64"):G1.Buffer.from(J.buffer).toString("base64");else if(typeof btoa==="function"){let q="";for(let Y=0;Y<J.length;++Y)q+=String.fromCharCode(J[Y]);H=btoa(q)}else throw Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(Z??(Z=Q2.Scalar.BLOCK_LITERAL),Z!==Q2.Scalar.QUOTE_DOUBLE){let q=Math.max(X.options.lineWidth-X.indent.length,X.options.minContentWidth),Y=Math.ceil(H.length/q),G=Array(Y);for(let _=0,B=0;_<Y;++_,B+=q)G[_]=H.substr(B,q);H=G.join(Z===Q2.Scalar.BLOCK_LITERAL?`
52
+ `:" ")}return m7.stringifyString({comment:$,type:Z,value:H},X,Q,z)}};l7.binary=p7});var Q$=R((s7)=>{var X$=C(),J2=J0(),c7=x(),i7=Y0();function Y8($,Z){if(X$.isSeq($))for(let U=0;U<$.items.length;++U){let X=$.items[U];if(X$.isPair(X))continue;else if(X$.isMap(X)){if(X.items.length>1)Z("Each pair must have its own sequence indicator");let Q=X.items[0]||new J2.Pair(new c7.Scalar(null));if(X.commentBefore)Q.key.commentBefore=Q.key.commentBefore?`${X.commentBefore}
53
+ ${Q.key.commentBefore}`:X.commentBefore;if(X.comment){let z=Q.value??Q.key;z.comment=z.comment?`${X.comment}
54
+ ${z.comment}`:X.comment}X=Q}$.items[U]=X$.isPair(X)?X:new J2.Pair(X)}else Z("Expected a sequence for this tag");return $}function G8($,Z,U){let{replacer:X}=U,Q=new i7.YAMLSeq($);Q.tag="tag:yaml.org,2002:pairs";let z=0;if(Z&&Symbol.iterator in Object(Z))for(let J of Z){if(typeof X==="function")J=X.call(Z,String(z++),J);let H,q;if(Array.isArray(J))if(J.length===2)H=J[0],q=J[1];else throw TypeError(`Expected [key, value] tuple: ${J}`);else if(J&&J instanceof Object){let Y=Object.keys(J);if(Y.length===1)H=Y[0],q=J[H];else throw TypeError(`Expected tuple with one key, not ${Y.length} keys`)}else H=J;Q.items.push(J2.createPair(H,q,U))}return Q}var r7={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:Y8,createNode:G8};s7.createPairs=G8;s7.pairs=r7;s7.resolvePairs=Y8});var q2=R(($U)=>{var _8=C(),H2=X0(),_1=q0(),t7=Y0(),B8=Q$();class I0 extends t7.YAMLSeq{constructor(){super();this.add=_1.YAMLMap.prototype.add.bind(this),this.delete=_1.YAMLMap.prototype.delete.bind(this),this.get=_1.YAMLMap.prototype.get.bind(this),this.has=_1.YAMLMap.prototype.has.bind(this),this.set=_1.YAMLMap.prototype.set.bind(this),this.tag=I0.tag}toJSON($,Z){if(!Z)return super.toJSON($);let U=new Map;if(Z?.onCreate)Z.onCreate(U);for(let X of this.items){let Q,z;if(_8.isPair(X))Q=H2.toJS(X.key,"",Z),z=H2.toJS(X.value,Q,Z);else Q=H2.toJS(X,"",Z);if(U.has(Q))throw Error("Ordered maps must not include duplicate keys");U.set(Q,z)}return U}static from($,Z,U){let X=B8.createPairs($,Z,U),Q=new this;return Q.items=X.items,Q}}I0.tag="tag:yaml.org,2002:omap";var e7={collection:"seq",identify:($)=>$ instanceof Map,nodeClass:I0,default:!1,tag:"tag:yaml.org,2002:omap",resolve($,Z){let U=B8.resolvePairs($,Z),X=[];for(let{key:Q}of U.items)if(_8.isScalar(Q))if(X.includes(Q.value))Z(`Ordered maps must not include duplicate keys: ${Q.value}`);else X.push(Q.value);return Object.assign(new I0,U)},createNode:($,Z,U)=>I0.from($,Z,U)};$U.YAMLOMap=I0;$U.omap=e7});var I8=R((XU)=>{var V8=x();function O8({value:$,source:Z},U){if(Z&&($?W8:D8).test.test(Z))return Z;return $?U.options.trueStr:U.options.falseStr}var W8={identify:($)=>$===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new V8.Scalar(!0),stringify:O8},D8={identify:($)=>$===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new V8.Scalar(!1),stringify:O8};XU.falseTag=D8;XU.trueTag=W8});var L8=R((GU)=>{var JU=x(),Y2=h0(),HU={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:($)=>$.slice(-3).toLowerCase()==="nan"?NaN:$[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Y2.stringifyNumber},qU={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:($)=>parseFloat($.replace(/_/g,"")),stringify($){let Z=Number($.value);return isFinite(Z)?Z.toExponential():Y2.stringifyNumber($)}},YU={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve($){let Z=new JU.Scalar(parseFloat($.replace(/_/g,""))),U=$.indexOf(".");if(U!==-1){let X=$.substring(U+1).replace(/_/g,"");if(X[X.length-1]==="0")Z.minFractionDigits=X.length}return Z},stringify:Y2.stringifyNumber};GU.float=YU;GU.floatExp=qU;GU.floatNaN=HU});var M8=R((LU)=>{var R8=h0(),B1=($)=>typeof $==="bigint"||Number.isInteger($);function z$($,Z,U,{intAsBigInt:X}){let Q=$[0];if(Q==="-"||Q==="+")Z+=1;if($=$.substring(Z).replace(/_/g,""),X){switch(U){case 2:$=`0b${$}`;break;case 8:$=`0o${$}`;break;case 16:$=`0x${$}`;break}let J=BigInt($);return Q==="-"?BigInt(-1)*J:J}let z=parseInt($,U);return Q==="-"?-1*z:z}function G2($,Z,U){let{value:X}=$;if(B1(X)){let Q=X.toString(Z);return X<0?"-"+U+Q.substr(1):U+Q}return R8.stringifyNumber($)}var OU={identify:B1,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:($,Z,U)=>z$($,2,2,U),stringify:($)=>G2($,2,"0b")},WU={identify:B1,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:($,Z,U)=>z$($,1,8,U),stringify:($)=>G2($,8,"0")},DU={identify:B1,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:($,Z,U)=>z$($,0,10,U),stringify:R8.stringifyNumber},IU={identify:B1,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:($,Z,U)=>z$($,2,16,U),stringify:($)=>G2($,16,"0x")};LU.int=DU;LU.intBin=OU;LU.intHex=IU;LU.intOct=WU});var _2=R((AU)=>{var q$=C(),J$=J0(),H$=q0();class L0 extends H$.YAMLMap{constructor($){super($);this.tag=L0.tag}add($){let Z;if(q$.isPair($))Z=$;else if($&&typeof $==="object"&&"key"in $&&"value"in $&&$.value===null)Z=new J$.Pair($.key,null);else Z=new J$.Pair($,null);if(!H$.findPair(this.items,Z.key))this.items.push(Z)}get($,Z){let U=H$.findPair(this.items,$);return!Z&&q$.isPair(U)?q$.isScalar(U.key)?U.key.value:U.key:U}set($,Z){if(typeof Z!=="boolean")throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof Z}`);let U=H$.findPair(this.items,$);if(U&&!Z)this.items.splice(this.items.indexOf(U),1);else if(!U&&Z)this.items.push(new J$.Pair($))}toJSON($,Z){return super.toJSON($,Z,Set)}toString($,Z,U){if(!$)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},$,{allNullValues:!0}),Z,U);else throw Error("Set items must all have null values")}static from($,Z,U){let{replacer:X}=U,Q=new this($);if(Z&&Symbol.iterator in Object(Z))for(let z of Z){if(typeof X==="function")z=X.call(Z,z,z);Q.items.push(J$.createPair(z,null,U))}return Q}}L0.tag="tag:yaml.org,2002:set";var PU={collection:"map",identify:($)=>$ instanceof Set,nodeClass:L0,default:!1,tag:"tag:yaml.org,2002:set",createNode:($,Z,U)=>L0.from($,Z,U),resolve($,Z){if(q$.isMap($))if($.hasAllNullValues(!0))return Object.assign(new L0,$);else Z("Set items must all have null values");else Z("Expected a mapping for this tag");return $}};AU.YAMLSet=L0;AU.set=PU});var V2=R((SU)=>{var wU=h0();function B2($,Z){let U=$[0],X=U==="-"||U==="+"?$.substring(1):$,Q=(J)=>Z?BigInt(J):Number(J),z=X.replace(/_/g,"").split(":").reduce((J,H)=>J*Q(60)+Q(H),Q(0));return U==="-"?Q(-1)*z:z}function K8($){let{value:Z}=$,U=(J)=>J;if(typeof Z==="bigint")U=(J)=>BigInt(J);else if(isNaN(Z)||!isFinite(Z))return wU.stringifyNumber($);let X="";if(Z<0)X="-",Z*=U(-1);let Q=U(60),z=[Z%Q];if(Z<60)z.unshift(0);else if(Z=(Z-z[0])/Q,z.unshift(Z%Q),Z>=60)Z=(Z-z[0])/Q,z.unshift(Z);return X+z.map((J)=>String(J).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}var CU={identify:($)=>typeof $==="bigint"||Number.isInteger($),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:($,Z,{intAsBigInt:U})=>B2($,U),stringify:K8},bU={identify:($)=>typeof $==="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:($)=>B2($,!1),stringify:K8},F8={identify:($)=>$ instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve($){let Z=$.match(F8.test);if(!Z)throw Error("!!timestamp expects a date, starting with yyyy-mm-dd");let[,U,X,Q,z,J,H]=Z.map(Number),q=Z[7]?Number((Z[7]+"00").substr(1,3)):0,Y=Date.UTC(U,X-1,Q,z||0,J||0,H||0,q),G=Z[8];if(G&&G!=="Z"){let _=B2(G,!1);if(Math.abs(_)<30)_*=60;Y-=60000*_}return new Date(Y)},stringify:({value:$})=>$?.toISOString().replace(/(T00:00:00)?\.000Z$/,"")??""};SU.floatTime=bU;SU.intTime=CU;SU.timestamp=F8});var A8=R((dU)=>{var xU=g0(),hU=$$(),yU=x0(),fU=Y1(),uU=z2(),P8=I8(),O2=L8(),Y$=M8(),kU=i1(),vU=q2(),mU=Q$(),pU=_2(),W2=V2(),lU=[xU.map,yU.seq,fU.string,hU.nullTag,P8.trueTag,P8.falseTag,Y$.intBin,Y$.intOct,Y$.int,Y$.intHex,O2.floatNaN,O2.floatExp,O2.float,uU.binary,kU.merge,vU.omap,mU.pairs,pU.set,W2.intTime,W2.floatTime,W2.timestamp];dU.schema=lU});var x8=R((eU)=>{var C8=g0(),iU=$$(),b8=x0(),rU=Y1(),sU=o$(),D2=e$(),I2=Z2(),aU=J8(),nU=q8(),S8=z2(),V1=i1(),E8=q2(),j8=Q$(),T8=A8(),g8=_2(),G$=V2(),N8=new Map([["core",aU.schema],["failsafe",[C8.map,b8.seq,rU.string]],["json",nU.schema],["yaml11",T8.schema],["yaml-1.1",T8.schema]]),w8={binary:S8.binary,bool:sU.boolTag,float:D2.float,floatExp:D2.floatExp,floatNaN:D2.floatNaN,floatTime:G$.floatTime,int:I2.int,intHex:I2.intHex,intOct:I2.intOct,intTime:G$.intTime,map:C8.map,merge:V1.merge,null:iU.nullTag,omap:E8.omap,pairs:j8.pairs,seq:b8.seq,set:g8.set,timestamp:G$.timestamp},oU={"tag:yaml.org,2002:binary":S8.binary,"tag:yaml.org,2002:merge":V1.merge,"tag:yaml.org,2002:omap":E8.omap,"tag:yaml.org,2002:pairs":j8.pairs,"tag:yaml.org,2002:set":g8.set,"tag:yaml.org,2002:timestamp":G$.timestamp};function tU($,Z,U){let X=N8.get(Z);if(X&&!$)return U&&!X.includes(V1.merge)?X.concat(V1.merge):X.slice();let Q=X;if(!Q)if(Array.isArray($))Q=[];else{let z=Array.from(N8.keys()).filter((J)=>J!=="yaml11").map((J)=>JSON.stringify(J)).join(", ");throw Error(`Unknown schema "${Z}"; use one of ${z} or define customTags array`)}if(Array.isArray($))for(let z of $)Q=Q.concat(z);else if(typeof $==="function")Q=$(Q.slice());if(U)Q=Q.concat(V1.merge);return Q.reduce((z,J)=>{let H=typeof J==="string"?w8[J]:J;if(!H){let q=JSON.stringify(J),Y=Object.keys(w8).map((G)=>JSON.stringify(G)).join(", ");throw Error(`Unknown custom tag ${q}; use one of ${Y}`)}if(!z.includes(H))z.push(H);return z},[])}eU.coreKnownTags=oU;eU.getTags=tU});var M2=R((JX)=>{var L2=C(),UX=g0(),XX=x0(),QX=Y1(),_$=x8(),zX=($,Z)=>$.key<Z.key?-1:$.key>Z.key?1:0;class R2{constructor({compat:$,customTags:Z,merge:U,resolveKnownTags:X,schema:Q,sortMapEntries:z,toStringDefaults:J}){this.compat=Array.isArray($)?_$.getTags($,"compat"):$?_$.getTags(null,$):null,this.name=typeof Q==="string"&&Q||"core",this.knownTags=X?_$.coreKnownTags:{},this.tags=_$.getTags(Z,this.name,U),this.toStringOptions=J??null,Object.defineProperty(this,L2.MAP,{value:UX.map}),Object.defineProperty(this,L2.SCALAR,{value:QX.string}),Object.defineProperty(this,L2.SEQ,{value:XX.seq}),this.sortMapEntries=typeof z==="function"?z:z===!0?zX:null}clone(){let $=Object.create(R2.prototype,Object.getOwnPropertyDescriptors(this));return $.tags=this.tags.slice(),$}}JX.Schema=R2});var h8=R((GX)=>{var qX=C(),K2=z1(),O1=U1();function YX($,Z){let U=[],X=Z.directives===!0;if(Z.directives!==!1&&$.directives){let q=$.directives.toString($);if(q)U.push(q),X=!0;else if($.directives.docStart)X=!0}if(X)U.push("---");let Q=K2.createStringifyContext($,Z),{commentString:z}=Q.options;if($.commentBefore){if(U.length!==1)U.unshift("");let q=z($.commentBefore);U.unshift(O1.indentComment(q,""))}let J=!1,H=null;if($.contents){if(qX.isNode($.contents)){if($.contents.spaceBefore&&X)U.push("");if($.contents.commentBefore){let G=z($.contents.commentBefore);U.push(O1.indentComment(G,""))}Q.forceBlockIndent=!!$.comment,H=$.contents.comment}let q=H?void 0:()=>J=!0,Y=K2.stringify($.contents,Q,()=>H=null,q);if(H)Y+=O1.lineComment(Y,"",z(H));if((Y[0]==="|"||Y[0]===">")&&U[U.length-1]==="---")U[U.length-1]=`--- ${Y}`;else U.push(Y)}else U.push(K2.stringify($.contents,Q));if($.directives?.docEnd)if($.comment){let q=z($.comment);if(q.includes(`
55
+ `))U.push("..."),U.push(O1.indentComment(q,""));else U.push(`... ${q}`)}else U.push("...");else{let q=$.comment;if(q&&J)q=q.replace(/^\n+/,"");if(q){if((!J||H)&&U[U.length-1]!=="")U.push("");U.push(O1.indentComment(z(q),""))}}return U.join(`
56
56
  `)+`
57
- `}c7.stringifyDocument=d7});var Y$=D(($X)=>{var s7=r0(),S0=S$(),v=b(),a7=X0(),r7=$0(),n7=_2(),o7=K8(),q2=b$(),t7=j1(),e7=n0(),B2=C1();class V2{constructor($,Z,z){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,v.NODE_TYPE,{value:v.DOC});let X=null;if(typeof Z==="function"||Array.isArray(Z))X=Z;else if(z===void 0&&Z)z=Z,Z=void 0;let U=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},z);this.options=U;let{version:Q}=U;if(z?._directives){if(this.directives=z._directives.atDocument(),this.directives.yaml.explicit)Q=this.directives.yaml.version}else this.directives=new B2.Directives({version:Q});this.setSchema(Q,z),this.contents=$===void 0?null:this.createNode($,X,z)}clone(){let $=Object.create(V2.prototype,{[v.NODE_TYPE]:{value:v.DOC}});if($.commentBefore=this.commentBefore,$.comment=this.comment,$.errors=this.errors.slice(),$.warnings=this.warnings.slice(),$.options=Object.assign({},this.options),this.directives)$.directives=this.directives.clone();if($.schema=this.schema.clone(),$.contents=v.isNode(this.contents)?this.contents.clone($.schema):this.contents,this.range)$.range=this.range.slice();return $}add($){if(E0(this.contents))this.contents.add($)}addIn($,Z){if(E0(this.contents))this.contents.addIn($,Z)}createAlias($,Z){if(!$.anchor){let z=q2.anchorNames(this);$.anchor=!Z||z.has(Z)?q2.findNewAnchor(Z||"a",z):Z}return new s7.Alias($.anchor)}createNode($,Z,z){let X=void 0;if(typeof Z==="function")$=Z.call({"":$},"",$),X=Z;else if(Array.isArray(Z)){let V=(L)=>typeof L==="number"||L instanceof String||L instanceof Number,O=Z.filter(V).map(String);if(O.length>0)Z=Z.concat(O);X=Z}else if(z===void 0&&Z)z=Z,Z=void 0;let{aliasDuplicateObjects:U,anchorPrefix:Q,flow:J,keepUndefined:H,onTagObj:G,tag:_}=z??{},{onAnchor:B,setAnchors:Y,sourceObjects:q}=q2.createNodeAnchors(this,Q||"a"),W={aliasDuplicateObjects:U??!0,keepUndefined:H??!1,onAnchor:B,onTagObj:G,replacer:X,schema:this.schema,sourceObjects:q},I=e7.createNode($,_,W);if(J&&v.isCollection(I))I.flow=!0;return Y(),I}createPair($,Z,z={}){let X=this.createNode($,null,z),U=this.createNode(Z,null,z);return new a7.Pair(X,U)}delete($){return E0(this.contents)?this.contents.delete($):!1}deleteIn($){if(S0.isEmptyPath($)){if(this.contents==null)return!1;return this.contents=null,!0}return E0(this.contents)?this.contents.deleteIn($):!1}get($,Z){return v.isCollection(this.contents)?this.contents.get($,Z):void 0}getIn($,Z){if(S0.isEmptyPath($))return!Z&&v.isScalar(this.contents)?this.contents.value:this.contents;return v.isCollection(this.contents)?this.contents.getIn($,Z):void 0}has($){return v.isCollection(this.contents)?this.contents.has($):!1}hasIn($){if(S0.isEmptyPath($))return this.contents!==void 0;return v.isCollection(this.contents)?this.contents.hasIn($):!1}set($,Z){if(this.contents==null)this.contents=S0.collectionFromPath(this.schema,[$],Z);else if(E0(this.contents))this.contents.set($,Z)}setIn($,Z){if(S0.isEmptyPath($))this.contents=Z;else if(this.contents==null)this.contents=S0.collectionFromPath(this.schema,Array.from($),Z);else if(E0(this.contents))this.contents.setIn($,Z)}setSchema($,Z={}){if(typeof $==="number")$=String($);let z;switch($){case"1.1":if(this.directives)this.directives.yaml.version="1.1";else this.directives=new B2.Directives({version:"1.1"});z={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":if(this.directives)this.directives.yaml.version=$;else this.directives=new B2.Directives({version:$});z={resolveKnownTags:!0,schema:"core"};break;case null:if(this.directives)delete this.directives;z=null;break;default:{let X=JSON.stringify($);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${X}`)}}if(Z.schema instanceof Object)this.schema=Z.schema;else if(z)this.schema=new n7.Schema(Object.assign(z,Z));else throw Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:$,jsonArg:Z,mapAsMap:z,maxAliasCount:X,onAnchor:U,reviver:Q}={}){let J={anchors:new Map,doc:this,keep:!$,mapAsMap:z===!0,mapKeyWarned:!1,maxAliasCount:typeof X==="number"?X:100},H=r7.toJS(this.contents,Z??"",J);if(typeof U==="function")for(let{count:G,res:_}of J.anchors.values())U(_,G);return typeof Q==="function"?t7.applyReviver(Q,{"":H},"",H):H}toJSON($,Z){return this.toJS({json:!0,jsonArg:$,mapAsMap:!1,onAnchor:Z})}toString($={}){if(this.errors.length>0)throw Error("Document with errors cannot be stringified");if("indent"in $&&(!Number.isInteger($.indent)||Number($.indent)<=0)){let Z=JSON.stringify($.indent);throw Error(`"indent" option must be a positive integer, not ${Z}`)}return o7.stringifyDocument(this,$)}}function E0($){if(v.isCollection($))return!0;throw Error("Expected a YAML collection as document contents")}$X.Document=V2});var q$=D((XX)=>{class X1 extends Error{constructor($,Z,z,X){super();this.name=$,this.code=z,this.message=X,this.pos=Z}}class P8 extends X1{constructor($,Z,z){super("YAMLParseError",$,Z,z)}}class T8 extends X1{constructor($,Z,z){super("YAMLWarning",$,Z,z)}}var zX=($,Z)=>(z)=>{if(z.pos[0]===-1)return;z.linePos=z.pos.map((H)=>Z.linePos(H));let{line:X,col:U}=z.linePos[0];z.message+=` at line ${X}, column ${U}`;let Q=U-1,J=$.substring(Z.lineStarts[X-1],Z.lineStarts[X]).replace(/[\n\r]+$/,"");if(Q>=60&&J.length>80){let H=Math.min(Q-39,J.length-79);J="…"+J.substring(H),Q-=H-1}if(J.length>80)J=J.substring(0,79)+"…";if(X>1&&/^ *$/.test(J.substring(0,Q))){let H=$.substring(Z.lineStarts[X-2],Z.lineStarts[X-1]);if(H.length>80)H=H.substring(0,79)+`…
58
- `;J=H+J}if(/[^ ]/.test(J)){let H=1,G=z.linePos[1];if(G?.line===X&&G.col>U)H=Math.max(1,Math.min(G.col-U,80-Q));let _=" ".repeat(Q)+"^".repeat(H);z.message+=`:
57
+ `}GX.stringifyDocument=YX});var W1=R((RX)=>{var BX=$1(),y0=v1(),p=C(),VX=J0(),OX=X0(),WX=M2(),DX=h8(),F2=f1(),IX=m$(),LX=Z1(),P2=v$();class A2{constructor($,Z,U){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,p.NODE_TYPE,{value:p.DOC});let X=null;if(typeof Z==="function"||Array.isArray(Z))X=Z;else if(U===void 0&&Z)U=Z,Z=void 0;let Q=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},U);this.options=Q;let{version:z}=Q;if(U?._directives){if(this.directives=U._directives.atDocument(),this.directives.yaml.explicit)z=this.directives.yaml.version}else this.directives=new P2.Directives({version:z});this.setSchema(z,U),this.contents=$===void 0?null:this.createNode($,X,U)}clone(){let $=Object.create(A2.prototype,{[p.NODE_TYPE]:{value:p.DOC}});if($.commentBefore=this.commentBefore,$.comment=this.comment,$.errors=this.errors.slice(),$.warnings=this.warnings.slice(),$.options=Object.assign({},this.options),this.directives)$.directives=this.directives.clone();if($.schema=this.schema.clone(),$.contents=p.isNode(this.contents)?this.contents.clone($.schema):this.contents,this.range)$.range=this.range.slice();return $}add($){if(f0(this.contents))this.contents.add($)}addIn($,Z){if(f0(this.contents))this.contents.addIn($,Z)}createAlias($,Z){if(!$.anchor){let U=F2.anchorNames(this);$.anchor=!Z||U.has(Z)?F2.findNewAnchor(Z||"a",U):Z}return new BX.Alias($.anchor)}createNode($,Z,U){let X=void 0;if(typeof Z==="function")$=Z.call({"":$},"",$),X=Z;else if(Array.isArray(Z)){let V=(I)=>typeof I==="number"||I instanceof String||I instanceof Number,W=Z.filter(V).map(String);if(W.length>0)Z=Z.concat(W);X=Z}else if(U===void 0&&Z)U=Z,Z=void 0;let{aliasDuplicateObjects:Q,anchorPrefix:z,flow:J,keepUndefined:H,onTagObj:q,tag:Y}=U??{},{onAnchor:G,setAnchors:_,sourceObjects:B}=F2.createNodeAnchors(this,z||"a"),O={aliasDuplicateObjects:Q??!0,keepUndefined:H??!1,onAnchor:G,onTagObj:q,replacer:X,schema:this.schema,sourceObjects:B},D=LX.createNode($,Y,O);if(J&&p.isCollection(D))D.flow=!0;return _(),D}createPair($,Z,U={}){let X=this.createNode($,null,U),Q=this.createNode(Z,null,U);return new VX.Pair(X,Q)}delete($){return f0(this.contents)?this.contents.delete($):!1}deleteIn($){if(y0.isEmptyPath($)){if(this.contents==null)return!1;return this.contents=null,!0}return f0(this.contents)?this.contents.deleteIn($):!1}get($,Z){return p.isCollection(this.contents)?this.contents.get($,Z):void 0}getIn($,Z){if(y0.isEmptyPath($))return!Z&&p.isScalar(this.contents)?this.contents.value:this.contents;return p.isCollection(this.contents)?this.contents.getIn($,Z):void 0}has($){return p.isCollection(this.contents)?this.contents.has($):!1}hasIn($){if(y0.isEmptyPath($))return this.contents!==void 0;return p.isCollection(this.contents)?this.contents.hasIn($):!1}set($,Z){if(this.contents==null)this.contents=y0.collectionFromPath(this.schema,[$],Z);else if(f0(this.contents))this.contents.set($,Z)}setIn($,Z){if(y0.isEmptyPath($))this.contents=Z;else if(this.contents==null)this.contents=y0.collectionFromPath(this.schema,Array.from($),Z);else if(f0(this.contents))this.contents.setIn($,Z)}setSchema($,Z={}){if(typeof $==="number")$=String($);let U;switch($){case"1.1":if(this.directives)this.directives.yaml.version="1.1";else this.directives=new P2.Directives({version:"1.1"});U={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":if(this.directives)this.directives.yaml.version=$;else this.directives=new P2.Directives({version:$});U={resolveKnownTags:!0,schema:"core"};break;case null:if(this.directives)delete this.directives;U=null;break;default:{let X=JSON.stringify($);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${X}`)}}if(Z.schema instanceof Object)this.schema=Z.schema;else if(U)this.schema=new WX.Schema(Object.assign(U,Z));else throw Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:$,jsonArg:Z,mapAsMap:U,maxAliasCount:X,onAnchor:Q,reviver:z}={}){let J={anchors:new Map,doc:this,keep:!$,mapAsMap:U===!0,mapKeyWarned:!1,maxAliasCount:typeof X==="number"?X:100},H=OX.toJS(this.contents,Z??"",J);if(typeof Q==="function")for(let{count:q,res:Y}of J.anchors.values())Q(Y,q);return typeof z==="function"?IX.applyReviver(z,{"":H},"",H):H}toJSON($,Z){return this.toJS({json:!0,jsonArg:$,mapAsMap:!1,onAnchor:Z})}toString($={}){if(this.errors.length>0)throw Error("Document with errors cannot be stringified");if("indent"in $&&(!Number.isInteger($.indent)||Number($.indent)<=0)){let Z=JSON.stringify($.indent);throw Error(`"indent" option must be a positive integer, not ${Z}`)}return DX.stringifyDocument(this,$)}}function f0($){if(p.isCollection($))return!0;throw Error("Expected a YAML collection as document contents")}RX.Document=A2});var D1=R((FX)=>{class B$ extends Error{constructor($,Z,U,X){super();this.name=$,this.code=U,this.message=X,this.pos=Z}}class y8 extends B${constructor($,Z,U){super("YAMLParseError",$,Z,U)}}class f8 extends B${constructor($,Z,U){super("YAMLWarning",$,Z,U)}}var KX=($,Z)=>(U)=>{if(U.pos[0]===-1)return;U.linePos=U.pos.map((H)=>Z.linePos(H));let{line:X,col:Q}=U.linePos[0];U.message+=` at line ${X}, column ${Q}`;let z=Q-1,J=$.substring(Z.lineStarts[X-1],Z.lineStarts[X]).replace(/[\n\r]+$/,"");if(z>=60&&J.length>80){let H=Math.min(z-39,J.length-79);J="…"+J.substring(H),z-=H-1}if(J.length>80)J=J.substring(0,79)+"…";if(X>1&&/^ *$/.test(J.substring(0,z))){let H=$.substring(Z.lineStarts[X-2],Z.lineStarts[X-1]);if(H.length>80)H=H.substring(0,79)+`…
58
+ `;J=H+J}if(/[^ ]/.test(J)){let H=1,q=U.linePos[1];if(q?.line===X&&q.col>Q)H=Math.max(1,Math.min(q.col-Q,80-z));let Y=" ".repeat(z)+"^".repeat(H);U.message+=`:
59
59
 
60
60
  ${J}
61
- ${_}
62
- `}};XX.YAMLError=X1;XX.YAMLParseError=P8;XX.YAMLWarning=T8;XX.prettifyError=zX});var B$=D((_X)=>{function GX($,{flow:Z,indicator:z,next:X,offset:U,onError:Q,parentIndent:J,startOnNewline:H}){let G=!1,_=H,B=H,Y="",q="",W=!1,I=!1,V=null,O=null,L=null,R=null,K=null,N=null,A=null;for(let P of $){if(I){if(P.type!=="space"&&P.type!=="newline"&&P.type!=="comma")Q(P.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");I=!1}if(V){if(_&&P.type!=="comment"&&P.type!=="newline")Q(V,"TAB_AS_INDENT","Tabs are not allowed as indentation");V=null}switch(P.type){case"space":if(!Z&&(z!=="doc-start"||X?.type!=="flow-collection")&&P.source.includes("\t"))V=P;B=!0;break;case"comment":{if(!B)Q(P,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let T=P.source.substring(1)||" ";if(!Y)Y=T;else Y+=q+T;q="",_=!1;break}case"newline":if(_){if(Y)Y+=P.source;else if(!N||z!=="seq-item-ind")G=!0}else q+=P.source;if(_=!0,W=!0,O||L)R=P;B=!0;break;case"anchor":if(O)Q(P,"MULTIPLE_ANCHORS","A node can have at most one anchor");if(P.source.endsWith(":"))Q(P.offset+P.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0);O=P,A??(A=P.offset),_=!1,B=!1,I=!0;break;case"tag":{if(L)Q(P,"MULTIPLE_TAGS","A node can have at most one tag");L=P,A??(A=P.offset),_=!1,B=!1,I=!0;break}case z:if(O||L)Q(P,"BAD_PROP_ORDER",`Anchors and tags must be after the ${P.source} indicator`);if(N)Q(P,"UNEXPECTED_TOKEN",`Unexpected ${P.source} in ${Z??"collection"}`);N=P,_=z==="seq-item-ind"||z==="explicit-key-ind",B=!1;break;case"comma":if(Z){if(K)Q(P,"UNEXPECTED_TOKEN",`Unexpected , in ${Z}`);K=P,_=!1,B=!1;break}default:Q(P,"UNEXPECTED_TOKEN",`Unexpected ${P.type} token`),_=!1,B=!1}}let w=$[$.length-1],C=w?w.offset+w.source.length:U;if(I&&X&&X.type!=="space"&&X.type!=="newline"&&X.type!=="comma"&&(X.type!=="scalar"||X.source!==""))Q(X.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");if(V&&(_&&V.indent<=J||X?.type==="block-map"||X?.type==="block-seq"))Q(V,"TAB_AS_INDENT","Tabs are not allowed as indentation");return{comma:K,found:N,spaceBefore:G,comment:Y,hasNewline:W,anchor:O,tag:L,newlineAfterProp:R,end:C,start:A??C}}_X.resolveProps=GX});var U1=D((qX)=>{function O2($){if(!$)return null;switch($.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if($.source.includes(`
63
- `))return!0;if($.end){for(let Z of $.end)if(Z.type==="newline")return!0}return!1;case"flow-collection":for(let Z of $.items){for(let z of Z.start)if(z.type==="newline")return!0;if(Z.sep){for(let z of Z.sep)if(z.type==="newline")return!0}if(O2(Z.key)||O2(Z.value))return!0}return!1;default:return!0}}qX.containsNewline=O2});var W2=D((WX)=>{var VX=U1();function OX($,Z,z){if(Z?.type==="flow-collection"){let X=Z.end[0];if(X.indent===$&&(X.source==="]"||X.source==="}")&&VX.containsNewline(Z))z(X,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}WX.flowIndentCheck=OX});var I2=D((DX)=>{var A8=b();function LX($,Z,z){let{uniqueKeys:X}=$.options;if(X===!1)return!1;let U=typeof X==="function"?X:(Q,J)=>Q===J||A8.isScalar(Q)&&A8.isScalar(J)&&Q.value===J.value;return Z.some((Q)=>U(Q.key,z))}DX.mapIncludes=LX});var j8=D((TX)=>{var N8=X0(),FX=Q0(),w8=B$(),MX=U1(),b8=W2(),KX=I2(),C8="All mapping items must start at the same column";function PX({composeNode:$,composeEmptyNode:Z},z,X,U,Q){let H=new(Q?.nodeClass??FX.YAMLMap)(z.schema);if(z.atRoot)z.atRoot=!1;let G=X.offset,_=null;for(let B of X.items){let{start:Y,key:q,sep:W,value:I}=B,V=w8.resolveProps(Y,{indicator:"explicit-key-ind",next:q??W?.[0],offset:G,onError:U,parentIndent:X.indent,startOnNewline:!0}),O=!V.found;if(O){if(q){if(q.type==="block-seq")U(G,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key");else if("indent"in q&&q.indent!==X.indent)U(G,"BAD_INDENT",C8)}if(!V.anchor&&!V.tag&&!W){if(_=V.end,V.comment)if(H.comment)H.comment+=`
64
- `+V.comment;else H.comment=V.comment;continue}if(V.newlineAfterProp||MX.containsNewline(q))U(q??Y[Y.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else if(V.found?.indent!==X.indent)U(G,"BAD_INDENT",C8);z.atKey=!0;let L=V.end,R=q?$(z,q,V,U):Z(z,L,Y,null,V,U);if(z.schema.compat)b8.flowIndentCheck(X.indent,q,U);if(z.atKey=!1,KX.mapIncludes(z,H.items,R))U(L,"DUPLICATE_KEY","Map keys must be unique");let K=w8.resolveProps(W??[],{indicator:"map-value-ind",next:I,offset:R.range[2],onError:U,parentIndent:X.indent,startOnNewline:!q||q.type==="block-scalar"});if(G=K.end,K.found){if(O){if(I?.type==="block-map"&&!K.hasNewline)U(G,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings");if(z.options.strict&&V.start<K.found.offset-1024)U(R.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key")}let N=I?$(z,I,K,U):Z(z,G,W,null,K,U);if(z.schema.compat)b8.flowIndentCheck(X.indent,I,U);G=N.range[2];let A=new N8.Pair(R,N);if(z.options.keepSourceTokens)A.srcToken=B;H.items.push(A)}else{if(O)U(R.range,"MISSING_CHAR","Implicit map keys need to be followed by map values");if(K.comment)if(R.comment)R.comment+=`
65
- `+K.comment;else R.comment=K.comment;let N=new N8.Pair(R);if(z.options.keepSourceTokens)N.srcToken=B;H.items.push(N)}}if(_&&_<G)U(_,"IMPOSSIBLE","Map comment with trailing content");return H.range=[X.offset,G,_??G],H}TX.resolveBlockMap=PX});var S8=D((jX)=>{var NX=J0(),wX=B$(),bX=W2();function CX({composeNode:$,composeEmptyNode:Z},z,X,U,Q){let H=new(Q?.nodeClass??NX.YAMLSeq)(z.schema);if(z.atRoot)z.atRoot=!1;if(z.atKey)z.atKey=!1;let G=X.offset,_=null;for(let{start:B,value:Y}of X.items){let q=wX.resolveProps(B,{indicator:"seq-item-ind",next:Y,offset:G,onError:U,parentIndent:X.indent,startOnNewline:!0});if(!q.found)if(q.anchor||q.tag||Y)if(Y?.type==="block-seq")U(q.end,"BAD_INDENT","All sequence items must start at the same column");else U(G,"MISSING_CHAR","Sequence item without - indicator");else{if(_=q.end,q.comment)H.comment=q.comment;continue}let W=Y?$(z,Y,q,U):Z(z,q.end,B,null,q,U);if(z.schema.compat)bX.flowIndentCheck(X.indent,Y,U);G=W.range[2],H.items.push(W)}return H.range=[X.offset,G,_??G],H}jX.resolveBlockSeq=CX});var g0=D((gX)=>{function EX($,Z,z,X){let U="";if($){let Q=!1,J="";for(let H of $){let{source:G,type:_}=H;switch(_){case"space":Q=!0;break;case"comment":{if(z&&!Q)X(H,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let B=G.substring(1)||" ";if(!U)U=B;else U+=J+B;J="";break}case"newline":if(U)J+=G;Q=!0;break;default:X(H,"UNEXPECTED_TOKEN",`Unexpected ${_} at node end`)}Z+=G.length}}return{comment:U,offset:Z}}gX.resolveEnd=EX});var f8=D((pX)=>{var yX=b(),hX=X0(),E8=Q0(),xX=J0(),uX=g0(),g8=B$(),kX=U1(),vX=I2(),L2="Block collections are not allowed within flow collections",D2=($)=>$&&($.type==="block-map"||$.type==="block-seq");function mX({composeNode:$,composeEmptyNode:Z},z,X,U,Q){let J=X.start.source==="{",H=J?"flow map":"flow sequence",_=new(Q?.nodeClass??(J?E8.YAMLMap:xX.YAMLSeq))(z.schema);_.flow=!0;let B=z.atRoot;if(B)z.atRoot=!1;if(z.atKey)z.atKey=!1;let Y=X.offset+X.start.source.length;for(let O=0;O<X.items.length;++O){let L=X.items[O],{start:R,key:K,sep:N,value:A}=L,w=g8.resolveProps(R,{flow:H,indicator:"explicit-key-ind",next:K??N?.[0],offset:Y,onError:U,parentIndent:X.indent,startOnNewline:!1});if(!w.found){if(!w.anchor&&!w.tag&&!N&&!A){if(O===0&&w.comma)U(w.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${H}`);else if(O<X.items.length-1)U(w.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${H}`);if(w.comment)if(_.comment)_.comment+=`
66
- `+w.comment;else _.comment=w.comment;Y=w.end;continue}if(!J&&z.options.strict&&kX.containsNewline(K))U(K,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(O===0){if(w.comma)U(w.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${H}`)}else{if(!w.comma)U(w.start,"MISSING_CHAR",`Missing , between ${H} items`);if(w.comment){let C="";$:for(let P of R)switch(P.type){case"comma":case"space":break;case"comment":C=P.source.substring(1);break $;default:break $}if(C){let P=_.items[_.items.length-1];if(yX.isPair(P))P=P.value??P.key;if(P.comment)P.comment+=`
67
- `+C;else P.comment=C;w.comment=w.comment.substring(C.length+1)}}}if(!J&&!N&&!w.found){let C=A?$(z,A,w,U):Z(z,w.end,N,null,w,U);if(_.items.push(C),Y=C.range[2],D2(A))U(C.range,"BLOCK_IN_FLOW",L2)}else{z.atKey=!0;let C=w.end,P=K?$(z,K,w,U):Z(z,C,R,null,w,U);if(D2(K))U(P.range,"BLOCK_IN_FLOW",L2);z.atKey=!1;let T=g8.resolveProps(N??[],{flow:H,indicator:"map-value-ind",next:A,offset:P.range[2],onError:U,parentIndent:X.indent,startOnNewline:!1});if(T.found){if(!J&&!w.found&&z.options.strict){if(N)for(let E of N){if(E===T.found)break;if(E.type==="newline"){U(E,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}if(w.start<T.found.offset-1024)U(T.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else if(A)if("source"in A&&A.source?.[0]===":")U(A,"MISSING_CHAR",`Missing space after : in ${H}`);else U(T.start,"MISSING_CHAR",`Missing , or : between ${H} items`);let d=A?$(z,A,T,U):T.found?Z(z,T.end,N,null,T,U):null;if(d){if(D2(A))U(d.range,"BLOCK_IN_FLOW",L2)}else if(T.comment)if(P.comment)P.comment+=`
68
- `+T.comment;else P.comment=T.comment;let c=new hX.Pair(P,d);if(z.options.keepSourceTokens)c.srcToken=L;if(J){let E=_;if(vX.mapIncludes(z,E.items,P))U(C,"DUPLICATE_KEY","Map keys must be unique");E.items.push(c)}else{let E=new E8.YAMLMap(z.schema);E.flow=!0,E.items.push(c);let m0=(d??P).range;E.range=[P.range[0],m0[1],m0[2]],_.items.push(E)}Y=d?d.range[2]:T.end}}let q=J?"}":"]",[W,...I]=X.end,V=Y;if(W?.source===q)V=W.offset+W.source.length;else{let O=H[0].toUpperCase()+H.substring(1),L=B?`${O} must end with a ${q}`:`${O} in block collection must be sufficiently indented and end with a ${q}`;if(U(Y,B?"MISSING_CHAR":"BAD_INDENT",L),W&&W.source.length!==1)I.unshift(W)}if(I.length>0){let O=uX.resolveEnd(I,V,z.options.strict,U);if(O.comment)if(_.comment)_.comment+=`
69
- `+O.comment;else _.comment=O.comment;_.range=[X.offset,V,O.offset]}else _.range=[X.offset,V,V];return _}pX.resolveFlowCollection=mX});var y8=D((tX)=>{var dX=b(),cX=g(),iX=Q0(),sX=J0(),aX=j8(),rX=S8(),nX=f8();function R2($,Z,z,X,U,Q){let J=z.type==="block-map"?aX.resolveBlockMap($,Z,z,X,Q):z.type==="block-seq"?rX.resolveBlockSeq($,Z,z,X,Q):nX.resolveFlowCollection($,Z,z,X,Q),H=J.constructor;if(U==="!"||U===H.tagName)return J.tag=H.tagName,J;if(U)J.tag=U;return J}function oX($,Z,z,X,U){let Q=X.tag,J=!Q?null:Z.directives.tagName(Q.source,(q)=>U(Q,"TAG_RESOLVE_FAILED",q));if(z.type==="block-seq"){let{anchor:q,newlineAfterProp:W}=X,I=q&&Q?q.offset>Q.offset?q:Q:q??Q;if(I&&(!W||W.offset<I.offset))U(I,"MISSING_CHAR","Missing newline after block sequence props")}let H=z.type==="block-map"?"map":z.type==="block-seq"?"seq":z.start.source==="{"?"map":"seq";if(!Q||!J||J==="!"||J===iX.YAMLMap.tagName&&H==="map"||J===sX.YAMLSeq.tagName&&H==="seq")return R2($,Z,z,U,J);let G=Z.schema.tags.find((q)=>q.tag===J&&q.collection===H);if(!G){let q=Z.schema.knownTags[J];if(q?.collection===H)Z.schema.tags.push(Object.assign({},q,{default:!1})),G=q;else{if(q)U(Q,"BAD_COLLECTION_TYPE",`${q.tag} used for ${H} collection, but expects ${q.collection??"scalar"}`,!0);else U(Q,"TAG_RESOLVE_FAILED",`Unresolved tag: ${J}`,!0);return R2($,Z,z,U,J)}}let _=R2($,Z,z,U,J,G),B=G.resolve?.(_,(q)=>U(Q,"TAG_RESOLVE_FAILED",q),Z.options)??_,Y=dX.isNode(B)?B:new cX.Scalar(B);if(Y.range=_.range,Y.tag=J,G?.format)Y.format=G.format;return Y}tX.composeCollection=oX});var M2=D((XU)=>{var F2=g();function $U($,Z,z){let X=Z.offset,U=ZU(Z,$.options.strict,z);if(!U)return{value:"",type:null,comment:"",range:[X,X,X]};let Q=U.mode===">"?F2.Scalar.BLOCK_FOLDED:F2.Scalar.BLOCK_LITERAL,J=Z.source?zU(Z.source):[],H=J.length;for(let V=J.length-1;V>=0;--V){let O=J[V][1];if(O===""||O==="\r")H=V;else break}if(H===0){let V=U.chomp==="+"&&J.length>0?`
70
- `.repeat(Math.max(1,J.length-1)):"",O=X+U.length;if(Z.source)O+=Z.source.length;return{value:V,type:Q,comment:U.comment,range:[X,O,O]}}let G=Z.indent+U.indent,_=Z.offset+U.length,B=0;for(let V=0;V<H;++V){let[O,L]=J[V];if(L===""||L==="\r"){if(U.indent===0&&O.length>G)G=O.length}else{if(O.length<G)z(_+O.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator");if(U.indent===0)G=O.length;if(B=V,G===0&&!$.atRoot)z(_,"BAD_INDENT","Block scalar values in collections must be indented");break}_+=O.length+L.length+1}for(let V=J.length-1;V>=H;--V)if(J[V][0].length>G)H=V+1;let Y="",q="",W=!1;for(let V=0;V<B;++V)Y+=J[V][0].slice(G)+`
71
- `;for(let V=B;V<H;++V){let[O,L]=J[V];_+=O.length+L.length+1;let R=L[L.length-1]==="\r";if(R)L=L.slice(0,-1);if(L&&O.length<G){let N=`Block scalar lines must not be less indented than their ${U.indent?"explicit indentation indicator":"first line"}`;z(_-L.length-(R?2:1),"BAD_INDENT",N),O=""}if(Q===F2.Scalar.BLOCK_LITERAL)Y+=q+O.slice(G)+L,q=`
72
- `;else if(O.length>G||L[0]==="\t"){if(q===" ")q=`
73
- `;else if(!W&&q===`
74
- `)q=`
61
+ ${Y}
62
+ `}};FX.YAMLError=B$;FX.YAMLParseError=y8;FX.YAMLWarning=f8;FX.prettifyError=KX});var I1=R((CX)=>{function wX($,{flow:Z,indicator:U,next:X,offset:Q,onError:z,parentIndent:J,startOnNewline:H}){let q=!1,Y=H,G=H,_="",B="",O=!1,D=!1,V=null,W=null,I=null,L=null,F=null,A=null,T=null;for(let P of $){if(D){if(P.type!=="space"&&P.type!=="newline"&&P.type!=="comma")z(P.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");D=!1}if(V){if(Y&&P.type!=="comment"&&P.type!=="newline")z(V,"TAB_AS_INDENT","Tabs are not allowed as indentation");V=null}switch(P.type){case"space":if(!Z&&(U!=="doc-start"||X?.type!=="flow-collection")&&P.source.includes("\t"))V=P;G=!0;break;case"comment":{if(!G)z(P,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let w=P.source.substring(1)||" ";if(!_)_=w;else _+=B+w;B="",Y=!1;break}case"newline":if(Y){if(_)_+=P.source;else if(!A||U!=="seq-item-ind")q=!0}else B+=P.source;if(Y=!0,O=!0,W||I)L=P;G=!0;break;case"anchor":if(W)z(P,"MULTIPLE_ANCHORS","A node can have at most one anchor");if(P.source.endsWith(":"))z(P.offset+P.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0);W=P,T??(T=P.offset),Y=!1,G=!1,D=!0;break;case"tag":{if(I)z(P,"MULTIPLE_TAGS","A node can have at most one tag");I=P,T??(T=P.offset),Y=!1,G=!1,D=!0;break}case U:if(W||I)z(P,"BAD_PROP_ORDER",`Anchors and tags must be after the ${P.source} indicator`);if(A)z(P,"UNEXPECTED_TOKEN",`Unexpected ${P.source} in ${Z??"collection"}`);A=P,Y=U==="seq-item-ind"||U==="explicit-key-ind",G=!1;break;case"comma":if(Z){if(F)z(P,"UNEXPECTED_TOKEN",`Unexpected , in ${Z}`);F=P,Y=!1,G=!1;break}default:z(P,"UNEXPECTED_TOKEN",`Unexpected ${P.type} token`),Y=!1,G=!1}}let N=$[$.length-1],b=N?N.offset+N.source.length:Q;if(D&&X&&X.type!=="space"&&X.type!=="newline"&&X.type!=="comma"&&(X.type!=="scalar"||X.source!==""))z(X.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space");if(V&&(Y&&V.indent<=J||X?.type==="block-map"||X?.type==="block-seq"))z(V,"TAB_AS_INDENT","Tabs are not allowed as indentation");return{comma:F,found:A,spaceBefore:q,comment:_,hasNewline:O,anchor:W,tag:I,newlineAfterProp:L,end:b,start:T??b}}CX.resolveProps=wX});var V$=R((SX)=>{function T2($){if(!$)return null;switch($.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if($.source.includes(`
63
+ `))return!0;if($.end){for(let Z of $.end)if(Z.type==="newline")return!0}return!1;case"flow-collection":for(let Z of $.items){for(let U of Z.start)if(U.type==="newline")return!0;if(Z.sep){for(let U of Z.sep)if(U.type==="newline")return!0}if(T2(Z.key)||T2(Z.value))return!0}return!1;default:return!0}}SX.containsNewline=T2});var N2=R((xX)=>{var jX=V$();function gX($,Z,U){if(Z?.type==="flow-collection"){let X=Z.end[0];if(X.indent===$&&(X.source==="]"||X.source==="}")&&jX.containsNewline(Z))U(X,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}xX.flowIndentCheck=gX});var w2=R((fX)=>{var u8=C();function yX($,Z,U){let{uniqueKeys:X}=$.options;if(X===!1)return!1;let Q=typeof X==="function"?X:(z,J)=>z===J||u8.isScalar(z)&&u8.isScalar(J)&&z.value===J.value;return Z.some((z)=>Q(z.key,U))}fX.mapIncludes=yX});var l8=R((lX)=>{var k8=J0(),kX=q0(),v8=I1(),vX=V$(),m8=N2(),mX=w2(),p8="All mapping items must start at the same column";function pX({composeNode:$,composeEmptyNode:Z},U,X,Q,z){let H=new(z?.nodeClass??kX.YAMLMap)(U.schema);if(U.atRoot)U.atRoot=!1;let q=X.offset,Y=null;for(let G of X.items){let{start:_,key:B,sep:O,value:D}=G,V=v8.resolveProps(_,{indicator:"explicit-key-ind",next:B??O?.[0],offset:q,onError:Q,parentIndent:X.indent,startOnNewline:!0}),W=!V.found;if(W){if(B){if(B.type==="block-seq")Q(q,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key");else if("indent"in B&&B.indent!==X.indent)Q(q,"BAD_INDENT",p8)}if(!V.anchor&&!V.tag&&!O){if(Y=V.end,V.comment)if(H.comment)H.comment+=`
64
+ `+V.comment;else H.comment=V.comment;continue}if(V.newlineAfterProp||vX.containsNewline(B))Q(B??_[_.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else if(V.found?.indent!==X.indent)Q(q,"BAD_INDENT",p8);U.atKey=!0;let I=V.end,L=B?$(U,B,V,Q):Z(U,I,_,null,V,Q);if(U.schema.compat)m8.flowIndentCheck(X.indent,B,Q);if(U.atKey=!1,mX.mapIncludes(U,H.items,L))Q(I,"DUPLICATE_KEY","Map keys must be unique");let F=v8.resolveProps(O??[],{indicator:"map-value-ind",next:D,offset:L.range[2],onError:Q,parentIndent:X.indent,startOnNewline:!B||B.type==="block-scalar"});if(q=F.end,F.found){if(W){if(D?.type==="block-map"&&!F.hasNewline)Q(q,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings");if(U.options.strict&&V.start<F.found.offset-1024)Q(L.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key")}let A=D?$(U,D,F,Q):Z(U,q,O,null,F,Q);if(U.schema.compat)m8.flowIndentCheck(X.indent,D,Q);q=A.range[2];let T=new k8.Pair(L,A);if(U.options.keepSourceTokens)T.srcToken=G;H.items.push(T)}else{if(W)Q(L.range,"MISSING_CHAR","Implicit map keys need to be followed by map values");if(F.comment)if(L.comment)L.comment+=`
65
+ `+F.comment;else L.comment=F.comment;let A=new k8.Pair(L);if(U.options.keepSourceTokens)A.srcToken=G;H.items.push(A)}}if(Y&&Y<q)Q(Y,"IMPOSSIBLE","Map comment with trailing content");return H.range=[X.offset,q,Y??q],H}lX.resolveBlockMap=pX});var d8=R((aX)=>{var cX=Y0(),iX=I1(),rX=N2();function sX({composeNode:$,composeEmptyNode:Z},U,X,Q,z){let H=new(z?.nodeClass??cX.YAMLSeq)(U.schema);if(U.atRoot)U.atRoot=!1;if(U.atKey)U.atKey=!1;let q=X.offset,Y=null;for(let{start:G,value:_}of X.items){let B=iX.resolveProps(G,{indicator:"seq-item-ind",next:_,offset:q,onError:Q,parentIndent:X.indent,startOnNewline:!0});if(!B.found)if(B.anchor||B.tag||_)if(_?.type==="block-seq")Q(B.end,"BAD_INDENT","All sequence items must start at the same column");else Q(q,"MISSING_CHAR","Sequence item without - indicator");else{if(Y=B.end,B.comment)H.comment=B.comment;continue}let O=_?$(U,_,B,Q):Z(U,B.end,G,null,B,Q);if(U.schema.compat)rX.flowIndentCheck(X.indent,_,Q);q=O.range[2],H.items.push(O)}return H.range=[X.offset,q,Y??q],H}aX.resolveBlockSeq=sX});var u0=R((tX)=>{function oX($,Z,U,X){let Q="";if($){let z=!1,J="";for(let H of $){let{source:q,type:Y}=H;switch(Y){case"space":z=!0;break;case"comment":{if(U&&!z)X(H,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let G=q.substring(1)||" ";if(!Q)Q=G;else Q+=J+G;J="";break}case"newline":if(Q)J+=q;z=!0;break;default:X(H,"UNEXPECTED_TOKEN",`Unexpected ${Y} at node end`)}Z+=q.length}}return{comment:Q,offset:Z}}tX.resolveEnd=oX});var r8=R((HQ)=>{var $Q=C(),ZQ=J0(),c8=q0(),UQ=Y0(),XQ=u0(),i8=I1(),QQ=V$(),zQ=w2(),C2="Block collections are not allowed within flow collections",b2=($)=>$&&($.type==="block-map"||$.type==="block-seq");function JQ({composeNode:$,composeEmptyNode:Z},U,X,Q,z){let J=X.start.source==="{",H=J?"flow map":"flow sequence",Y=new(z?.nodeClass??(J?c8.YAMLMap:UQ.YAMLSeq))(U.schema);Y.flow=!0;let G=U.atRoot;if(G)U.atRoot=!1;if(U.atKey)U.atKey=!1;let _=X.offset+X.start.source.length;for(let W=0;W<X.items.length;++W){let I=X.items[W],{start:L,key:F,sep:A,value:T}=I,N=i8.resolveProps(L,{flow:H,indicator:"explicit-key-ind",next:F??A?.[0],offset:_,onError:Q,parentIndent:X.indent,startOnNewline:!1});if(!N.found){if(!N.anchor&&!N.tag&&!A&&!T){if(W===0&&N.comma)Q(N.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${H}`);else if(W<X.items.length-1)Q(N.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${H}`);if(N.comment)if(Y.comment)Y.comment+=`
66
+ `+N.comment;else Y.comment=N.comment;_=N.end;continue}if(!J&&U.options.strict&&QQ.containsNewline(F))Q(F,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(W===0){if(N.comma)Q(N.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${H}`)}else{if(!N.comma)Q(N.start,"MISSING_CHAR",`Missing , between ${H} items`);if(N.comment){let b="";$:for(let P of L)switch(P.type){case"comma":case"space":break;case"comment":b=P.source.substring(1);break $;default:break $}if(b){let P=Y.items[Y.items.length-1];if($Q.isPair(P))P=P.value??P.key;if(P.comment)P.comment+=`
67
+ `+b;else P.comment=b;N.comment=N.comment.substring(b.length+1)}}}if(!J&&!A&&!N.found){let b=T?$(U,T,N,Q):Z(U,N.end,A,null,N,Q);if(Y.items.push(b),_=b.range[2],b2(T))Q(b.range,"BLOCK_IN_FLOW",C2)}else{U.atKey=!0;let b=N.end,P=F?$(U,F,N,Q):Z(U,b,L,null,N,Q);if(b2(F))Q(P.range,"BLOCK_IN_FLOW",C2);U.atKey=!1;let w=i8.resolveProps(A??[],{flow:H,indicator:"map-value-ind",next:T,offset:P.range[2],onError:Q,parentIndent:X.indent,startOnNewline:!1});if(w.found){if(!J&&!N.found&&U.options.strict){if(A)for(let g of A){if(g===w.found)break;if(g.type==="newline"){Q(g,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}if(N.start<w.found.offset-1024)Q(w.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else if(T)if("source"in T&&T.source?.[0]===":")Q(T,"MISSING_CHAR",`Missing space after : in ${H}`);else Q(w.start,"MISSING_CHAR",`Missing , or : between ${H} items`);let v=T?$(U,T,w,Q):w.found?Z(U,w.end,A,null,w,Q):null;if(v){if(b2(T))Q(v.range,"BLOCK_IN_FLOW",C2)}else if(w.comment)if(P.comment)P.comment+=`
68
+ `+w.comment;else P.comment=w.comment;let S=new ZQ.Pair(P,v);if(U.options.keepSourceTokens)S.srcToken=I;if(J){let g=Y;if(zQ.mapIncludes(U,g.items,P))Q(b,"DUPLICATE_KEY","Map keys must be unique");g.items.push(S)}else{let g=new c8.YAMLMap(U.schema);g.flow=!0,g.items.push(S);let i0=(v??P).range;g.range=[P.range[0],i0[1],i0[2]],Y.items.push(g)}_=v?v.range[2]:w.end}}let B=J?"}":"]",[O,...D]=X.end,V=_;if(O?.source===B)V=O.offset+O.source.length;else{let W=H[0].toUpperCase()+H.substring(1),I=G?`${W} must end with a ${B}`:`${W} in block collection must be sufficiently indented and end with a ${B}`;if(Q(_,G?"MISSING_CHAR":"BAD_INDENT",I),O&&O.source.length!==1)D.unshift(O)}if(D.length>0){let W=XQ.resolveEnd(D,V,U.options.strict,Q);if(W.comment)if(Y.comment)Y.comment+=`
69
+ `+W.comment;else Y.comment=W.comment;Y.range=[X.offset,V,W.offset]}else Y.range=[X.offset,V,V];return Y}HQ.resolveFlowCollection=JQ});var s8=R((IQ)=>{var YQ=C(),GQ=x(),_Q=q0(),BQ=Y0(),VQ=l8(),OQ=d8(),WQ=r8();function S2($,Z,U,X,Q,z){let J=U.type==="block-map"?VQ.resolveBlockMap($,Z,U,X,z):U.type==="block-seq"?OQ.resolveBlockSeq($,Z,U,X,z):WQ.resolveFlowCollection($,Z,U,X,z),H=J.constructor;if(Q==="!"||Q===H.tagName)return J.tag=H.tagName,J;if(Q)J.tag=Q;return J}function DQ($,Z,U,X,Q){let z=X.tag,J=!z?null:Z.directives.tagName(z.source,(B)=>Q(z,"TAG_RESOLVE_FAILED",B));if(U.type==="block-seq"){let{anchor:B,newlineAfterProp:O}=X,D=B&&z?B.offset>z.offset?B:z:B??z;if(D&&(!O||O.offset<D.offset))Q(D,"MISSING_CHAR","Missing newline after block sequence props")}let H=U.type==="block-map"?"map":U.type==="block-seq"?"seq":U.start.source==="{"?"map":"seq";if(!z||!J||J==="!"||J===_Q.YAMLMap.tagName&&H==="map"||J===BQ.YAMLSeq.tagName&&H==="seq")return S2($,Z,U,Q,J);let q=Z.schema.tags.find((B)=>B.tag===J&&B.collection===H);if(!q){let B=Z.schema.knownTags[J];if(B?.collection===H)Z.schema.tags.push(Object.assign({},B,{default:!1})),q=B;else{if(B)Q(z,"BAD_COLLECTION_TYPE",`${B.tag} used for ${H} collection, but expects ${B.collection??"scalar"}`,!0);else Q(z,"TAG_RESOLVE_FAILED",`Unresolved tag: ${J}`,!0);return S2($,Z,U,Q,J)}}let Y=S2($,Z,U,Q,J,q),G=q.resolve?.(Y,(B)=>Q(z,"TAG_RESOLVE_FAILED",B),Z.options)??Y,_=YQ.isNode(G)?G:new GQ.Scalar(G);if(_.range=Y.range,_.tag=J,q?.format)_.format=q.format;return _}IQ.composeCollection=DQ});var j2=R((FQ)=>{var E2=x();function RQ($,Z,U){let X=Z.offset,Q=MQ(Z,$.options.strict,U);if(!Q)return{value:"",type:null,comment:"",range:[X,X,X]};let z=Q.mode===">"?E2.Scalar.BLOCK_FOLDED:E2.Scalar.BLOCK_LITERAL,J=Z.source?KQ(Z.source):[],H=J.length;for(let V=J.length-1;V>=0;--V){let W=J[V][1];if(W===""||W==="\r")H=V;else break}if(H===0){let V=Q.chomp==="+"&&J.length>0?`
70
+ `.repeat(Math.max(1,J.length-1)):"",W=X+Q.length;if(Z.source)W+=Z.source.length;return{value:V,type:z,comment:Q.comment,range:[X,W,W]}}let q=Z.indent+Q.indent,Y=Z.offset+Q.length,G=0;for(let V=0;V<H;++V){let[W,I]=J[V];if(I===""||I==="\r"){if(Q.indent===0&&W.length>q)q=W.length}else{if(W.length<q)U(Y+W.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator");if(Q.indent===0)q=W.length;if(G=V,q===0&&!$.atRoot)U(Y,"BAD_INDENT","Block scalar values in collections must be indented");break}Y+=W.length+I.length+1}for(let V=J.length-1;V>=H;--V)if(J[V][0].length>q)H=V+1;let _="",B="",O=!1;for(let V=0;V<G;++V)_+=J[V][0].slice(q)+`
71
+ `;for(let V=G;V<H;++V){let[W,I]=J[V];Y+=W.length+I.length+1;let L=I[I.length-1]==="\r";if(L)I=I.slice(0,-1);if(I&&W.length<q){let A=`Block scalar lines must not be less indented than their ${Q.indent?"explicit indentation indicator":"first line"}`;U(Y-I.length-(L?2:1),"BAD_INDENT",A),W=""}if(z===E2.Scalar.BLOCK_LITERAL)_+=B+W.slice(q)+I,B=`
72
+ `;else if(W.length>q||I[0]==="\t"){if(B===" ")B=`
73
+ `;else if(!O&&B===`
74
+ `)B=`
75
75
 
76
- `;Y+=q+O.slice(G)+L,q=`
77
- `,W=!0}else if(L==="")if(q===`
78
- `)Y+=`
79
- `;else q=`
80
- `;else Y+=q+L,q=" ",W=!1}switch(U.chomp){case"-":break;case"+":for(let V=H;V<J.length;++V)Y+=`
81
- `+J[V][0].slice(G);if(Y[Y.length-1]!==`
82
- `)Y+=`
83
- `;break;default:Y+=`
84
- `}let I=X+U.length+Z.source.length;return{value:Y,type:Q,comment:U.comment,range:[X,I,I]}}function ZU({offset:$,props:Z},z,X){if(Z[0].type!=="block-scalar-header")return X(Z[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:U}=Z[0],Q=U[0],J=0,H="",G=-1;for(let q=1;q<U.length;++q){let W=U[q];if(!H&&(W==="-"||W==="+"))H=W;else{let I=Number(W);if(!J&&I)J=I;else if(G===-1)G=$+q}}if(G!==-1)X(G,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${U}`);let _=!1,B="",Y=U.length;for(let q=1;q<Z.length;++q){let W=Z[q];switch(W.type){case"space":_=!0;case"newline":Y+=W.source.length;break;case"comment":if(z&&!_)X(W,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");Y+=W.source.length,B=W.source.substring(1);break;case"error":X(W,"UNEXPECTED_TOKEN",W.message),Y+=W.source.length;break;default:{let I=`Unexpected token in block scalar header: ${W.type}`;X(W,"UNEXPECTED_TOKEN",I);let V=W.source;if(V&&typeof V==="string")Y+=V.length}}}return{mode:Q,indent:J,chomp:H,comment:B,length:Y}}function zU($){let Z=$.split(/\n( *)/),z=Z[0],X=z.match(/^( *)/),Q=[X?.[1]?[X[1],z.slice(X[1].length)]:["",z]];for(let J=1;J<Z.length;J+=2)Q.push([Z[J],Z[J+1]]);return Q}XU.resolveBlockScalar=$U});var P2=D((VU)=>{var K2=g(),QU=g0();function JU($,Z,z){let{offset:X,type:U,source:Q,end:J}=$,H,G,_=(q,W,I)=>z(X+q,W,I);switch(U){case"scalar":H=K2.Scalar.PLAIN,G=HU(Q,_);break;case"single-quoted-scalar":H=K2.Scalar.QUOTE_SINGLE,G=GU(Q,_);break;case"double-quoted-scalar":H=K2.Scalar.QUOTE_DOUBLE,G=_U(Q,_);break;default:return z($,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${U}`),{value:"",type:null,comment:"",range:[X,X+Q.length,X+Q.length]}}let B=X+Q.length,Y=QU.resolveEnd(J,B,Z,z);return{value:G,type:H,comment:Y.comment,range:[X,B,Y.offset]}}function HU($,Z){let z="";switch($[0]){case"\t":z="a tab character";break;case",":z="flow indicator character ,";break;case"%":z="directive indicator character %";break;case"|":case">":{z=`block scalar indicator ${$[0]}`;break}case"@":case"`":{z=`reserved character ${$[0]}`;break}}if(z)Z(0,"BAD_SCALAR_START",`Plain value cannot start with ${z}`);return h8($)}function GU($,Z){if($[$.length-1]!=="'"||$.length===1)Z($.length,"MISSING_CHAR","Missing closing 'quote");return h8($.slice(1,-1)).replace(/''/g,"'")}function h8($){let Z,z;try{Z=new RegExp(`(.*?)(?<![ ])[ ]*\r?
85
- `,"sy"),z=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?
86
- `,"sy")}catch{Z=/(.*?)[ \t]*\r?\n/sy,z=/[ \t]*(.*?)[ \t]*\r?\n/sy}let X=Z.exec($);if(!X)return $;let U=X[1],Q=" ",J=Z.lastIndex;z.lastIndex=J;while(X=z.exec($)){if(X[1]==="")if(Q===`
87
- `)U+=Q;else Q=`
88
- `;else U+=Q+X[1],Q=" ";J=z.lastIndex}let H=/[ \t]*(.*)/sy;return H.lastIndex=J,X=H.exec($),U+Q+(X?.[1]??"")}function _U($,Z){let z="";for(let X=1;X<$.length-1;++X){let U=$[X];if(U==="\r"&&$[X+1]===`
89
- `)continue;if(U===`
90
- `){let{fold:Q,offset:J}=YU($,X);z+=Q,X=J}else if(U==="\\"){let Q=$[++X],J=qU[Q];if(J)z+=J;else if(Q===`
91
- `){Q=$[X+1];while(Q===" "||Q==="\t")Q=$[++X+1]}else if(Q==="\r"&&$[X+1]===`
92
- `){Q=$[++X+1];while(Q===" "||Q==="\t")Q=$[++X+1]}else if(Q==="x"||Q==="u"||Q==="U"){let H={x:2,u:4,U:8}[Q];z+=BU($,X+1,H,Z),X+=H}else{let H=$.substr(X-1,2);Z(X-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${H}`),z+=H}}else if(U===" "||U==="\t"){let Q=X,J=$[X+1];while(J===" "||J==="\t")J=$[++X+1];if(J!==`
76
+ `;_+=B+W.slice(q)+I,B=`
77
+ `,O=!0}else if(I==="")if(B===`
78
+ `)_+=`
79
+ `;else B=`
80
+ `;else _+=B+I,B=" ",O=!1}switch(Q.chomp){case"-":break;case"+":for(let V=H;V<J.length;++V)_+=`
81
+ `+J[V][0].slice(q);if(_[_.length-1]!==`
82
+ `)_+=`
83
+ `;break;default:_+=`
84
+ `}let D=X+Q.length+Z.source.length;return{value:_,type:z,comment:Q.comment,range:[X,D,D]}}function MQ({offset:$,props:Z},U,X){if(Z[0].type!=="block-scalar-header")return X(Z[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:Q}=Z[0],z=Q[0],J=0,H="",q=-1;for(let B=1;B<Q.length;++B){let O=Q[B];if(!H&&(O==="-"||O==="+"))H=O;else{let D=Number(O);if(!J&&D)J=D;else if(q===-1)q=$+B}}if(q!==-1)X(q,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${Q}`);let Y=!1,G="",_=Q.length;for(let B=1;B<Z.length;++B){let O=Z[B];switch(O.type){case"space":Y=!0;case"newline":_+=O.source.length;break;case"comment":if(U&&!Y)X(O,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");_+=O.source.length,G=O.source.substring(1);break;case"error":X(O,"UNEXPECTED_TOKEN",O.message),_+=O.source.length;break;default:{let D=`Unexpected token in block scalar header: ${O.type}`;X(O,"UNEXPECTED_TOKEN",D);let V=O.source;if(V&&typeof V==="string")_+=V.length}}}return{mode:z,indent:J,chomp:H,comment:G,length:_}}function KQ($){let Z=$.split(/\n( *)/),U=Z[0],X=U.match(/^( *)/),z=[X?.[1]?[X[1],U.slice(X[1].length)]:["",U]];for(let J=1;J<Z.length;J+=2)z.push([Z[J],Z[J+1]]);return z}FQ.resolveBlockScalar=RQ});var x2=R((jQ)=>{var g2=x(),AQ=u0();function TQ($,Z,U){let{offset:X,type:Q,source:z,end:J}=$,H,q,Y=(B,O,D)=>U(X+B,O,D);switch(Q){case"scalar":H=g2.Scalar.PLAIN,q=NQ(z,Y);break;case"single-quoted-scalar":H=g2.Scalar.QUOTE_SINGLE,q=wQ(z,Y);break;case"double-quoted-scalar":H=g2.Scalar.QUOTE_DOUBLE,q=CQ(z,Y);break;default:return U($,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${Q}`),{value:"",type:null,comment:"",range:[X,X+z.length,X+z.length]}}let G=X+z.length,_=AQ.resolveEnd(J,G,Z,U);return{value:q,type:H,comment:_.comment,range:[X,G,_.offset]}}function NQ($,Z){let U="";switch($[0]){case"\t":U="a tab character";break;case",":U="flow indicator character ,";break;case"%":U="directive indicator character %";break;case"|":case">":{U=`block scalar indicator ${$[0]}`;break}case"@":case"`":{U=`reserved character ${$[0]}`;break}}if(U)Z(0,"BAD_SCALAR_START",`Plain value cannot start with ${U}`);return a8($)}function wQ($,Z){if($[$.length-1]!=="'"||$.length===1)Z($.length,"MISSING_CHAR","Missing closing 'quote");return a8($.slice(1,-1)).replace(/''/g,"'")}function a8($){let Z,U;try{Z=new RegExp(`(.*?)(?<![ ])[ ]*\r?
85
+ `,"sy"),U=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?
86
+ `,"sy")}catch{Z=/(.*?)[ \t]*\r?\n/sy,U=/[ \t]*(.*?)[ \t]*\r?\n/sy}let X=Z.exec($);if(!X)return $;let Q=X[1],z=" ",J=Z.lastIndex;U.lastIndex=J;while(X=U.exec($)){if(X[1]==="")if(z===`
87
+ `)Q+=z;else z=`
88
+ `;else Q+=z+X[1],z=" ";J=U.lastIndex}let H=/[ \t]*(.*)/sy;return H.lastIndex=J,X=H.exec($),Q+z+(X?.[1]??"")}function CQ($,Z){let U="";for(let X=1;X<$.length-1;++X){let Q=$[X];if(Q==="\r"&&$[X+1]===`
89
+ `)continue;if(Q===`
90
+ `){let{fold:z,offset:J}=bQ($,X);U+=z,X=J}else if(Q==="\\"){let z=$[++X],J=SQ[z];if(J)U+=J;else if(z===`
91
+ `){z=$[X+1];while(z===" "||z==="\t")z=$[++X+1]}else if(z==="\r"&&$[X+1]===`
92
+ `){z=$[++X+1];while(z===" "||z==="\t")z=$[++X+1]}else if(z==="x"||z==="u"||z==="U"){let H={x:2,u:4,U:8}[z];U+=EQ($,X+1,H,Z),X+=H}else{let H=$.substr(X-1,2);Z(X-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${H}`),U+=H}}else if(Q===" "||Q==="\t"){let z=X,J=$[X+1];while(J===" "||J==="\t")J=$[++X+1];if(J!==`
93
93
  `&&!(J==="\r"&&$[X+2]===`
94
- `))z+=X>Q?$.slice(Q,X+1):U}else z+=U}if($[$.length-1]!=='"'||$.length===1)Z($.length,"MISSING_CHAR",'Missing closing "quote');return z}function YU($,Z){let z="",X=$[Z+1];while(X===" "||X==="\t"||X===`
94
+ `))U+=X>z?$.slice(z,X+1):Q}else U+=Q}if($[$.length-1]!=='"'||$.length===1)Z($.length,"MISSING_CHAR",'Missing closing "quote');return U}function bQ($,Z){let U="",X=$[Z+1];while(X===" "||X==="\t"||X===`
95
95
  `||X==="\r"){if(X==="\r"&&$[Z+2]!==`
96
96
  `)break;if(X===`
97
- `)z+=`
98
- `;Z+=1,X=$[Z+1]}if(!z)z=" ";return{fold:z,offset:Z}}var qU={"0":"\x00",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
99
- `,r:"\r",t:"\t",v:"\v",N:"…",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"};function BU($,Z,z,X){let U=$.substr(Z,z),J=U.length===z&&/^[0-9a-fA-F]+$/.test(U)?parseInt(U,16):NaN;if(isNaN(J)){let H=$.substr(Z-2,z+2);return X(Z-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${H}`),H}return String.fromCodePoint(J)}VU.resolveFlowScalar=JU});var u8=D((FU)=>{var I0=b(),x8=g(),WU=M2(),IU=P2();function LU($,Z,z,X){let{value:U,type:Q,comment:J,range:H}=Z.type==="block-scalar"?WU.resolveBlockScalar($,Z,X):IU.resolveFlowScalar(Z,$.options.strict,X),G=z?$.directives.tagName(z.source,(Y)=>X(z,"TAG_RESOLVE_FAILED",Y)):null,_;if($.options.stringKeys&&$.atKey)_=$.schema[I0.SCALAR];else if(G)_=DU($.schema,U,G,z,X);else if(Z.type==="scalar")_=RU($,U,Z,X);else _=$.schema[I0.SCALAR];let B;try{let Y=_.resolve(U,(q)=>X(z??Z,"TAG_RESOLVE_FAILED",q),$.options);B=I0.isScalar(Y)?Y:new x8.Scalar(Y)}catch(Y){let q=Y instanceof Error?Y.message:String(Y);X(z??Z,"TAG_RESOLVE_FAILED",q),B=new x8.Scalar(U)}if(B.range=H,B.source=U,Q)B.type=Q;if(G)B.tag=G;if(_.format)B.format=_.format;if(J)B.comment=J;return B}function DU($,Z,z,X,U){if(z==="!")return $[I0.SCALAR];let Q=[];for(let H of $.tags)if(!H.collection&&H.tag===z)if(H.default&&H.test)Q.push(H);else return H;for(let H of Q)if(H.test?.test(Z))return H;let J=$.knownTags[z];if(J&&!J.collection)return $.tags.push(Object.assign({},J,{default:!1,test:void 0})),J;return U(X,"TAG_RESOLVE_FAILED",`Unresolved tag: ${z}`,z!=="tag:yaml.org,2002:str"),$[I0.SCALAR]}function RU({atKey:$,directives:Z,schema:z},X,U,Q){let J=z.tags.find((H)=>(H.default===!0||$&&H.default==="key")&&H.test?.test(X))||z[I0.SCALAR];if(z.compat){let H=z.compat.find((G)=>G.default&&G.test?.test(X))??z[I0.SCALAR];if(J.tag!==H.tag){let G=Z.tagString(J.tag),_=Z.tagString(H.tag),B=`Value may be parsed as either ${G} or ${_}`;Q(U,"TAG_RESOLVE_FAILED",B,!0)}}return J}FU.composeScalar=LU});var k8=D((PU)=>{function KU($,Z,z){if(Z){z??(z=Z.length);for(let X=z-1;X>=0;--X){let U=Z[X];switch(U.type){case"space":case"comment":case"newline":$-=U.source.length;continue}U=Z[++X];while(U?.type==="space")$+=U.source.length,U=Z[++X];break}}return $}PU.emptyScalarPosition=KU});var p8=D((EU)=>{var AU=r0(),NU=b(),wU=y8(),v8=u8(),bU=g0(),CU=k8(),jU={composeNode:m8,composeEmptyNode:T2};function m8($,Z,z,X){let U=$.atKey,{spaceBefore:Q,comment:J,anchor:H,tag:G}=z,_,B=!0;switch(Z.type){case"alias":if(_=SU($,Z,X),H||G)X(Z,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":if(_=v8.composeScalar($,Z,G,X),H)_.anchor=H.source.substring(1);break;case"block-map":case"block-seq":case"flow-collection":try{if(_=wU.composeCollection(jU,$,Z,z,X),H)_.anchor=H.source.substring(1)}catch(Y){let q=Y instanceof Error?Y.message:String(Y);X(Z,"RESOURCE_EXHAUSTION",q)}break;default:{let Y=Z.type==="error"?Z.message:`Unsupported token (type: ${Z.type})`;X(Z,"UNEXPECTED_TOKEN",Y),B=!1}}if(_??(_=T2($,Z.offset,void 0,null,z,X)),H&&_.anchor==="")X(H,"BAD_ALIAS","Anchor cannot be an empty string");if(U&&$.options.stringKeys&&(!NU.isScalar(_)||typeof _.value!=="string"||_.tag&&_.tag!=="tag:yaml.org,2002:str"))X(G??Z,"NON_STRING_KEY","With stringKeys, all keys must be strings");if(Q)_.spaceBefore=!0;if(J)if(Z.type==="scalar"&&Z.source==="")_.comment=J;else _.commentBefore=J;if($.options.keepSourceTokens&&B)_.srcToken=Z;return _}function T2($,Z,z,X,{spaceBefore:U,comment:Q,anchor:J,tag:H,end:G},_){let B={type:"scalar",offset:CU.emptyScalarPosition(Z,z,X),indent:-1,source:""},Y=v8.composeScalar($,B,H,_);if(J){if(Y.anchor=J.source.substring(1),Y.anchor==="")_(J,"BAD_ALIAS","Anchor cannot be an empty string")}if(U)Y.spaceBefore=!0;if(Q)Y.comment=Q,Y.range[2]=G;return Y}function SU({options:$},{offset:Z,source:z,end:X},U){let Q=new AU.Alias(z.substring(1));if(Q.source==="")U(Z,"BAD_ALIAS","Alias cannot be an empty string");if(Q.source.endsWith(":"))U(Z+z.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let J=Z+z.length,H=bU.resolveEnd(X,J,$.strict,U);if(Q.range=[Z,J,H.offset],H.comment)Q.comment=H.comment;return Q}EU.composeEmptyNode=T2;EU.composeNode=m8});var d8=D((kU)=>{var yU=Y$(),l8=p8(),hU=g0(),xU=B$();function uU($,Z,{offset:z,start:X,value:U,end:Q},J){let H=Object.assign({_directives:Z},$),G=new yU.Document(void 0,H),_={atKey:!1,atRoot:!0,directives:G.directives,options:G.options,schema:G.schema},B=xU.resolveProps(X,{indicator:"doc-start",next:U??Q?.[0],offset:z,onError:J,parentIndent:0,startOnNewline:!0});if(B.found){if(G.directives.docStart=!0,U&&(U.type==="block-map"||U.type==="block-seq")&&!B.hasNewline)J(B.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")}G.contents=U?l8.composeNode(_,U,B,J):l8.composeEmptyNode(_,B.end,X,null,B,J);let Y=G.contents.range[2],q=hU.resolveEnd(Q,Y,!1,J);if(q.comment)G.comment=q.comment;return G.range=[z,Y,q.offset],G}kU.composeDoc=uU});var A2=D((iU)=>{var mU=p0("process"),pU=C1(),lU=Y$(),V$=q$(),c8=b(),dU=d8(),cU=g0();function O$($){if(typeof $==="number")return[$,$+1];if(Array.isArray($))return $.length===2?$:[$[0],$[1]];let{offset:Z,source:z}=$;return[Z,Z+(typeof z==="string"?z.length:1)]}function i8($){let Z="",z=!1,X=!1;for(let U=0;U<$.length;++U){let Q=$[U];switch(Q[0]){case"#":Z+=(Z===""?"":X?`
97
+ `)U+=`
98
+ `;Z+=1,X=$[Z+1]}if(!U)U=" ";return{fold:U,offset:Z}}var SQ={"0":"\x00",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
99
+ `,r:"\r",t:"\t",v:"\v",N:"…",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","\t":"\t"};function EQ($,Z,U,X){let Q=$.substr(Z,U),J=Q.length===U&&/^[0-9a-fA-F]+$/.test(Q)?parseInt(Q,16):NaN;if(isNaN(J)){let H=$.substr(Z-2,U+2);return X(Z-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${H}`),H}return String.fromCodePoint(J)}jQ.resolveFlowScalar=TQ});var o8=R((kQ)=>{var R0=C(),n8=x(),xQ=j2(),hQ=x2();function yQ($,Z,U,X){let{value:Q,type:z,comment:J,range:H}=Z.type==="block-scalar"?xQ.resolveBlockScalar($,Z,X):hQ.resolveFlowScalar(Z,$.options.strict,X),q=U?$.directives.tagName(U.source,(_)=>X(U,"TAG_RESOLVE_FAILED",_)):null,Y;if($.options.stringKeys&&$.atKey)Y=$.schema[R0.SCALAR];else if(q)Y=fQ($.schema,Q,q,U,X);else if(Z.type==="scalar")Y=uQ($,Q,Z,X);else Y=$.schema[R0.SCALAR];let G;try{let _=Y.resolve(Q,(B)=>X(U??Z,"TAG_RESOLVE_FAILED",B),$.options);G=R0.isScalar(_)?_:new n8.Scalar(_)}catch(_){let B=_ instanceof Error?_.message:String(_);X(U??Z,"TAG_RESOLVE_FAILED",B),G=new n8.Scalar(Q)}if(G.range=H,G.source=Q,z)G.type=z;if(q)G.tag=q;if(Y.format)G.format=Y.format;if(J)G.comment=J;return G}function fQ($,Z,U,X,Q){if(U==="!")return $[R0.SCALAR];let z=[];for(let H of $.tags)if(!H.collection&&H.tag===U)if(H.default&&H.test)z.push(H);else return H;for(let H of z)if(H.test?.test(Z))return H;let J=$.knownTags[U];if(J&&!J.collection)return $.tags.push(Object.assign({},J,{default:!1,test:void 0})),J;return Q(X,"TAG_RESOLVE_FAILED",`Unresolved tag: ${U}`,U!=="tag:yaml.org,2002:str"),$[R0.SCALAR]}function uQ({atKey:$,directives:Z,schema:U},X,Q,z){let J=U.tags.find((H)=>(H.default===!0||$&&H.default==="key")&&H.test?.test(X))||U[R0.SCALAR];if(U.compat){let H=U.compat.find((q)=>q.default&&q.test?.test(X))??U[R0.SCALAR];if(J.tag!==H.tag){let q=Z.tagString(J.tag),Y=Z.tagString(H.tag),G=`Value may be parsed as either ${q} or ${Y}`;z(Q,"TAG_RESOLVE_FAILED",G,!0)}}return J}kQ.composeScalar=yQ});var t8=R((pQ)=>{function mQ($,Z,U){if(Z){U??(U=Z.length);for(let X=U-1;X>=0;--X){let Q=Z[X];switch(Q.type){case"space":case"comment":case"newline":$-=Q.source.length;continue}Q=Z[++X];while(Q?.type==="space")$+=Q.source.length,Q=Z[++X];break}}return $}pQ.emptyScalarPosition=mQ});var Z6=R((oQ)=>{var dQ=$1(),cQ=C(),iQ=s8(),e8=o8(),rQ=u0(),sQ=t8(),aQ={composeNode:$6,composeEmptyNode:h2};function $6($,Z,U,X){let Q=$.atKey,{spaceBefore:z,comment:J,anchor:H,tag:q}=U,Y,G=!0;switch(Z.type){case"alias":if(Y=nQ($,Z,X),H||q)X(Z,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":if(Y=e8.composeScalar($,Z,q,X),H)Y.anchor=H.source.substring(1);break;case"block-map":case"block-seq":case"flow-collection":try{if(Y=iQ.composeCollection(aQ,$,Z,U,X),H)Y.anchor=H.source.substring(1)}catch(_){let B=_ instanceof Error?_.message:String(_);X(Z,"RESOURCE_EXHAUSTION",B)}break;default:{let _=Z.type==="error"?Z.message:`Unsupported token (type: ${Z.type})`;X(Z,"UNEXPECTED_TOKEN",_),G=!1}}if(Y??(Y=h2($,Z.offset,void 0,null,U,X)),H&&Y.anchor==="")X(H,"BAD_ALIAS","Anchor cannot be an empty string");if(Q&&$.options.stringKeys&&(!cQ.isScalar(Y)||typeof Y.value!=="string"||Y.tag&&Y.tag!=="tag:yaml.org,2002:str"))X(q??Z,"NON_STRING_KEY","With stringKeys, all keys must be strings");if(z)Y.spaceBefore=!0;if(J)if(Z.type==="scalar"&&Z.source==="")Y.comment=J;else Y.commentBefore=J;if($.options.keepSourceTokens&&G)Y.srcToken=Z;return Y}function h2($,Z,U,X,{spaceBefore:Q,comment:z,anchor:J,tag:H,end:q},Y){let G={type:"scalar",offset:sQ.emptyScalarPosition(Z,U,X),indent:-1,source:""},_=e8.composeScalar($,G,H,Y);if(J){if(_.anchor=J.source.substring(1),_.anchor==="")Y(J,"BAD_ALIAS","Anchor cannot be an empty string")}if(Q)_.spaceBefore=!0;if(z)_.comment=z,_.range[2]=q;return _}function nQ({options:$},{offset:Z,source:U,end:X},Q){let z=new dQ.Alias(U.substring(1));if(z.source==="")Q(Z,"BAD_ALIAS","Alias cannot be an empty string");if(z.source.endsWith(":"))Q(Z+U.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let J=Z+U.length,H=rQ.resolveEnd(X,J,$.strict,Q);if(z.range=[Z,J,H.offset],H.comment)z.comment=H.comment;return z}oQ.composeEmptyNode=h2;oQ.composeNode=$6});var X6=R((Qz)=>{var $z=W1(),U6=Z6(),Zz=u0(),Uz=I1();function Xz($,Z,{offset:U,start:X,value:Q,end:z},J){let H=Object.assign({_directives:Z},$),q=new $z.Document(void 0,H),Y={atKey:!1,atRoot:!0,directives:q.directives,options:q.options,schema:q.schema},G=Uz.resolveProps(X,{indicator:"doc-start",next:Q??z?.[0],offset:U,onError:J,parentIndent:0,startOnNewline:!0});if(G.found){if(q.directives.docStart=!0,Q&&(Q.type==="block-map"||Q.type==="block-seq")&&!G.hasNewline)J(G.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")}q.contents=Q?U6.composeNode(Y,Q,G,J):U6.composeEmptyNode(Y,G.end,X,null,G,J);let _=q.contents.range[2],B=Zz.resolveEnd(z,_,!1,J);if(B.comment)q.comment=B.comment;return q.range=[U,_,B.offset],q}Qz.composeDoc=Xz});var y2=R((_z)=>{var Jz=r0("process"),Hz=v$(),qz=W1(),L1=D1(),Q6=C(),Yz=X6(),Gz=u0();function R1($){if(typeof $==="number")return[$,$+1];if(Array.isArray($))return $.length===2?$:[$[0],$[1]];let{offset:Z,source:U}=$;return[Z,Z+(typeof U==="string"?U.length:1)]}function z6($){let Z="",U=!1,X=!1;for(let Q=0;Q<$.length;++Q){let z=$[Q];switch(z[0]){case"#":Z+=(Z===""?"":X?`
100
100
 
101
101
  `:`
102
- `)+(Q.substring(1)||" "),z=!0,X=!1;break;case"%":if($[U+1]?.[0]!=="#")U+=1;z=!1;break;default:if(!z)X=!0;z=!1}}return{comment:Z,afterEmptyLine:X}}class s8{constructor($={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(Z,z,X,U)=>{let Q=O$(Z);if(U)this.warnings.push(new V$.YAMLWarning(Q,z,X));else this.errors.push(new V$.YAMLParseError(Q,z,X))},this.directives=new pU.Directives({version:$.version||"1.2"}),this.options=$}decorate($,Z){let{comment:z,afterEmptyLine:X}=i8(this.prelude);if(z){let U=$.contents;if(Z)$.comment=$.comment?`${$.comment}
103
- ${z}`:z;else if(X||$.directives.docStart||!U)$.commentBefore=z;else if(c8.isCollection(U)&&!U.flow&&U.items.length>0){let Q=U.items[0];if(c8.isPair(Q))Q=Q.key;let J=Q.commentBefore;Q.commentBefore=J?`${z}
104
- ${J}`:z}else{let Q=U.commentBefore;U.commentBefore=Q?`${z}
105
- ${Q}`:z}}if(Z)Array.prototype.push.apply($.errors,this.errors),Array.prototype.push.apply($.warnings,this.warnings);else $.errors=this.errors,$.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:i8(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose($,Z=!1,z=-1){for(let X of $)yield*this.next(X);yield*this.end(Z,z)}*next($){if(mU.env.LOG_STREAM)console.dir($,{depth:null});switch($.type){case"directive":this.directives.add($.source,(Z,z,X)=>{let U=O$($);U[0]+=Z,this.onError(U,"BAD_DIRECTIVE",z,X)}),this.prelude.push($.source),this.atDirectives=!0;break;case"document":{let Z=dU.composeDoc(this.options,this.directives,$,this.onError);if(this.atDirectives&&!Z.directives.docStart)this.onError($,"MISSING_CHAR","Missing directives-end/doc-start indicator line");if(this.decorate(Z,!1),this.doc)yield this.doc;this.doc=Z,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push($.source);break;case"error":{let Z=$.source?`${$.message}: ${JSON.stringify($.source)}`:$.message,z=new V$.YAMLParseError(O$($),"UNEXPECTED_TOKEN",Z);if(this.atDirectives||!this.doc)this.errors.push(z);else this.doc.errors.push(z);break}case"doc-end":{if(!this.doc){this.errors.push(new V$.YAMLParseError(O$($),"UNEXPECTED_TOKEN","Unexpected doc-end without preceding document"));break}this.doc.directives.docEnd=!0;let Z=cU.resolveEnd($.end,$.offset+$.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),Z.comment){let z=this.doc.comment;this.doc.comment=z?`${z}
106
- ${Z.comment}`:Z.comment}this.doc.range[2]=Z.offset;break}default:this.errors.push(new V$.YAMLParseError(O$($),"UNEXPECTED_TOKEN",`Unsupported token ${$.type}`))}}*end($=!1,Z=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if($){let z=Object.assign({_directives:this.directives},this.options),X=new lU.Document(void 0,z);if(this.atDirectives)this.onError(Z,"MISSING_CHAR","Missing directives-end indicator line");X.range=[0,Z,Z],this.decorate(X,!1),yield X}}}iU.Composer=s8});var n8=D((ZQ)=>{var aU=M2(),rU=P2(),nU=q$(),a8=e0();function oU($,Z=!0,z){if($){let X=(U,Q,J)=>{let H=typeof U==="number"?U:Array.isArray(U)?U[0]:U.offset;if(z)z(H,Q,J);else throw new nU.YAMLParseError([H,H+1],Q,J)};switch($.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return rU.resolveFlowScalar($,Z,X);case"block-scalar":return aU.resolveBlockScalar({options:{strict:Z}},$,X)}}return null}function tU($,Z){let{implicitKey:z=!1,indent:X,inFlow:U=!1,offset:Q=-1,type:J="PLAIN"}=Z,H=a8.stringifyString({type:J,value:$},{implicitKey:z,indent:X>0?" ".repeat(X):"",inFlow:U,options:{blockQuote:!0,lineWidth:-1}}),G=Z.end??[{type:"newline",offset:-1,indent:X,source:`
107
- `}];switch(H[0]){case"|":case">":{let _=H.indexOf(`
108
- `),B=H.substring(0,_),Y=H.substring(_+1)+`
109
- `,q=[{type:"block-scalar-header",offset:Q,indent:X,source:B}];if(!r8(q,G))q.push({type:"newline",offset:-1,indent:X,source:`
110
- `});return{type:"block-scalar",offset:Q,indent:X,props:q,source:Y}}case'"':return{type:"double-quoted-scalar",offset:Q,indent:X,source:H,end:G};case"'":return{type:"single-quoted-scalar",offset:Q,indent:X,source:H,end:G};default:return{type:"scalar",offset:Q,indent:X,source:H,end:G}}}function eU($,Z,z={}){let{afterKey:X=!1,implicitKey:U=!1,inFlow:Q=!1,type:J}=z,H="indent"in $?$.indent:null;if(X&&typeof H==="number")H+=2;if(!J)switch($.type){case"single-quoted-scalar":J="QUOTE_SINGLE";break;case"double-quoted-scalar":J="QUOTE_DOUBLE";break;case"block-scalar":{let _=$.props[0];if(_.type!=="block-scalar-header")throw Error("Invalid block scalar header");J=_.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:J="PLAIN"}let G=a8.stringifyString({type:J,value:Z},{implicitKey:U||H===null,indent:H!==null&&H>0?" ".repeat(H):"",inFlow:Q,options:{blockQuote:!0,lineWidth:-1}});switch(G[0]){case"|":case">":$Q($,G);break;case'"':N2($,G,"double-quoted-scalar");break;case"'":N2($,G,"single-quoted-scalar");break;default:N2($,G,"scalar")}}function $Q($,Z){let z=Z.indexOf(`
111
- `),X=Z.substring(0,z),U=Z.substring(z+1)+`
112
- `;if($.type==="block-scalar"){let Q=$.props[0];if(Q.type!=="block-scalar-header")throw Error("Invalid block scalar header");Q.source=X,$.source=U}else{let{offset:Q}=$,J="indent"in $?$.indent:-1,H=[{type:"block-scalar-header",offset:Q,indent:J,source:X}];if(!r8(H,"end"in $?$.end:void 0))H.push({type:"newline",offset:-1,indent:J,source:`
113
- `});for(let G of Object.keys($))if(G!=="type"&&G!=="offset")delete $[G];Object.assign($,{type:"block-scalar",indent:J,props:H,source:U})}}function r8($,Z){if(Z)for(let z of Z)switch(z.type){case"space":case"comment":$.push(z);break;case"newline":return $.push(z),!0}return!1}function N2($,Z,z){switch($.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":$.type=z,$.source=Z;break;case"block-scalar":{let X=$.props.slice(1),U=Z.length;if($.props[0].type==="block-scalar-header")U-=$.props[0].source.length;for(let Q of X)Q.offset+=U;delete $.props,Object.assign($,{type:z,source:Z,end:X});break}case"block-map":case"block-seq":{let U={type:"newline",offset:$.offset+Z.length,indent:$.indent,source:`
114
- `};delete $.items,Object.assign($,{type:z,source:Z,end:[U]});break}default:{let X="indent"in $?$.indent:-1,U="end"in $&&Array.isArray($.end)?$.end.filter((Q)=>Q.type==="space"||Q.type==="comment"||Q.type==="newline"):[];for(let Q of Object.keys($))if(Q!=="type"&&Q!=="offset")delete $[Q];Object.assign($,{type:z,indent:X,source:Z,end:U})}}}ZQ.createScalarToken=tU;ZQ.resolveAsScalar=oU;ZQ.setScalarValue=eU});var o8=D((JQ)=>{var QQ=($)=>("type"in $)?J1($):Q1($);function J1($){switch($.type){case"block-scalar":{let Z="";for(let z of $.props)Z+=J1(z);return Z+$.source}case"block-map":case"block-seq":{let Z="";for(let z of $.items)Z+=Q1(z);return Z}case"flow-collection":{let Z=$.start.source;for(let z of $.items)Z+=Q1(z);for(let z of $.end)Z+=z.source;return Z}case"document":{let Z=Q1($);if($.end)for(let z of $.end)Z+=z.source;return Z}default:{let Z=$.source;if("end"in $&&$.end)for(let z of $.end)Z+=z.source;return Z}}}function Q1({start:$,key:Z,sep:z,value:X}){let U="";for(let Q of $)U+=Q.source;if(Z)U+=J1(Z);if(z)for(let Q of z)U+=Q.source;if(X)U+=J1(X);return U}JQ.stringify=QQ});var $9=D((_Q)=>{var w2=Symbol("break visit"),GQ=Symbol("skip children"),t8=Symbol("remove item");function L0($,Z){if("type"in $&&$.type==="document")$={start:$.start,value:$.value};e8(Object.freeze([]),$,Z)}L0.BREAK=w2;L0.SKIP=GQ;L0.REMOVE=t8;L0.itemAtPath=($,Z)=>{let z=$;for(let[X,U]of Z){let Q=z?.[X];if(Q&&"items"in Q)z=Q.items[U];else return}return z};L0.parentCollection=($,Z)=>{let z=L0.itemAtPath($,Z.slice(0,-1)),X=Z[Z.length-1][0],U=z?.[X];if(U&&"items"in U)return U;throw Error("Parent collection not found")};function e8($,Z,z){let X=z(Z,$);if(typeof X==="symbol")return X;for(let U of["key","value"]){let Q=Z[U];if(Q&&"items"in Q){for(let J=0;J<Q.items.length;++J){let H=e8(Object.freeze($.concat([[U,J]])),Q.items[J],z);if(typeof H==="number")J=H-1;else if(H===w2)return w2;else if(H===t8)Q.items.splice(J,1),J-=1}if(typeof X==="function"&&U==="key")X=X(Z,$)}}return typeof X==="function"?X(Z,$):X}_Q.visit=L0});var H1=D((LQ)=>{var b2=n8(),qQ=o8(),BQ=$9(),C2="\uFEFF",j2="\x02",S2="\x18",E2="\x1F",VQ=($)=>!!$&&("items"in $),OQ=($)=>!!$&&($.type==="scalar"||$.type==="single-quoted-scalar"||$.type==="double-quoted-scalar"||$.type==="block-scalar");function WQ($){switch($){case C2:return"<BOM>";case j2:return"<DOC>";case S2:return"<FLOW_END>";case E2:return"<SCALAR>";default:return JSON.stringify($)}}function IQ($){switch($){case C2:return"byte-order-mark";case j2:return"doc-mode";case S2:return"flow-error-end";case E2:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
102
+ `)+(z.substring(1)||" "),U=!0,X=!1;break;case"%":if($[Q+1]?.[0]!=="#")Q+=1;U=!1;break;default:if(!U)X=!0;U=!1}}return{comment:Z,afterEmptyLine:X}}class J6{constructor($={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(Z,U,X,Q)=>{let z=R1(Z);if(Q)this.warnings.push(new L1.YAMLWarning(z,U,X));else this.errors.push(new L1.YAMLParseError(z,U,X))},this.directives=new Hz.Directives({version:$.version||"1.2"}),this.options=$}decorate($,Z){let{comment:U,afterEmptyLine:X}=z6(this.prelude);if(U){let Q=$.contents;if(Z)$.comment=$.comment?`${$.comment}
103
+ ${U}`:U;else if(X||$.directives.docStart||!Q)$.commentBefore=U;else if(Q6.isCollection(Q)&&!Q.flow&&Q.items.length>0){let z=Q.items[0];if(Q6.isPair(z))z=z.key;let J=z.commentBefore;z.commentBefore=J?`${U}
104
+ ${J}`:U}else{let z=Q.commentBefore;Q.commentBefore=z?`${U}
105
+ ${z}`:U}}if(Z)Array.prototype.push.apply($.errors,this.errors),Array.prototype.push.apply($.warnings,this.warnings);else $.errors=this.errors,$.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:z6(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose($,Z=!1,U=-1){for(let X of $)yield*this.next(X);yield*this.end(Z,U)}*next($){if(Jz.env.LOG_STREAM)console.dir($,{depth:null});switch($.type){case"directive":this.directives.add($.source,(Z,U,X)=>{let Q=R1($);Q[0]+=Z,this.onError(Q,"BAD_DIRECTIVE",U,X)}),this.prelude.push($.source),this.atDirectives=!0;break;case"document":{let Z=Yz.composeDoc(this.options,this.directives,$,this.onError);if(this.atDirectives&&!Z.directives.docStart)this.onError($,"MISSING_CHAR","Missing directives-end/doc-start indicator line");if(this.decorate(Z,!1),this.doc)yield this.doc;this.doc=Z,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push($.source);break;case"error":{let Z=$.source?`${$.message}: ${JSON.stringify($.source)}`:$.message,U=new L1.YAMLParseError(R1($),"UNEXPECTED_TOKEN",Z);if(this.atDirectives||!this.doc)this.errors.push(U);else this.doc.errors.push(U);break}case"doc-end":{if(!this.doc){this.errors.push(new L1.YAMLParseError(R1($),"UNEXPECTED_TOKEN","Unexpected doc-end without preceding document"));break}this.doc.directives.docEnd=!0;let Z=Gz.resolveEnd($.end,$.offset+$.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),Z.comment){let U=this.doc.comment;this.doc.comment=U?`${U}
106
+ ${Z.comment}`:Z.comment}this.doc.range[2]=Z.offset;break}default:this.errors.push(new L1.YAMLParseError(R1($),"UNEXPECTED_TOKEN",`Unsupported token ${$.type}`))}}*end($=!1,Z=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if($){let U=Object.assign({_directives:this.directives},this.options),X=new qz.Document(void 0,U);if(this.atDirectives)this.onError(Z,"MISSING_CHAR","Missing directives-end indicator line");X.range=[0,Z,Z],this.decorate(X,!1),yield X}}}_z.Composer=J6});var Y6=R((Mz)=>{var Vz=j2(),Oz=x2(),Wz=D1(),H6=Q1();function Dz($,Z=!0,U){if($){let X=(Q,z,J)=>{let H=typeof Q==="number"?Q:Array.isArray(Q)?Q[0]:Q.offset;if(U)U(H,z,J);else throw new Wz.YAMLParseError([H,H+1],z,J)};switch($.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return Oz.resolveFlowScalar($,Z,X);case"block-scalar":return Vz.resolveBlockScalar({options:{strict:Z}},$,X)}}return null}function Iz($,Z){let{implicitKey:U=!1,indent:X,inFlow:Q=!1,offset:z=-1,type:J="PLAIN"}=Z,H=H6.stringifyString({type:J,value:$},{implicitKey:U,indent:X>0?" ".repeat(X):"",inFlow:Q,options:{blockQuote:!0,lineWidth:-1}}),q=Z.end??[{type:"newline",offset:-1,indent:X,source:`
107
+ `}];switch(H[0]){case"|":case">":{let Y=H.indexOf(`
108
+ `),G=H.substring(0,Y),_=H.substring(Y+1)+`
109
+ `,B=[{type:"block-scalar-header",offset:z,indent:X,source:G}];if(!q6(B,q))B.push({type:"newline",offset:-1,indent:X,source:`
110
+ `});return{type:"block-scalar",offset:z,indent:X,props:B,source:_}}case'"':return{type:"double-quoted-scalar",offset:z,indent:X,source:H,end:q};case"'":return{type:"single-quoted-scalar",offset:z,indent:X,source:H,end:q};default:return{type:"scalar",offset:z,indent:X,source:H,end:q}}}function Lz($,Z,U={}){let{afterKey:X=!1,implicitKey:Q=!1,inFlow:z=!1,type:J}=U,H="indent"in $?$.indent:null;if(X&&typeof H==="number")H+=2;if(!J)switch($.type){case"single-quoted-scalar":J="QUOTE_SINGLE";break;case"double-quoted-scalar":J="QUOTE_DOUBLE";break;case"block-scalar":{let Y=$.props[0];if(Y.type!=="block-scalar-header")throw Error("Invalid block scalar header");J=Y.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:J="PLAIN"}let q=H6.stringifyString({type:J,value:Z},{implicitKey:Q||H===null,indent:H!==null&&H>0?" ".repeat(H):"",inFlow:z,options:{blockQuote:!0,lineWidth:-1}});switch(q[0]){case"|":case">":Rz($,q);break;case'"':f2($,q,"double-quoted-scalar");break;case"'":f2($,q,"single-quoted-scalar");break;default:f2($,q,"scalar")}}function Rz($,Z){let U=Z.indexOf(`
111
+ `),X=Z.substring(0,U),Q=Z.substring(U+1)+`
112
+ `;if($.type==="block-scalar"){let z=$.props[0];if(z.type!=="block-scalar-header")throw Error("Invalid block scalar header");z.source=X,$.source=Q}else{let{offset:z}=$,J="indent"in $?$.indent:-1,H=[{type:"block-scalar-header",offset:z,indent:J,source:X}];if(!q6(H,"end"in $?$.end:void 0))H.push({type:"newline",offset:-1,indent:J,source:`
113
+ `});for(let q of Object.keys($))if(q!=="type"&&q!=="offset")delete $[q];Object.assign($,{type:"block-scalar",indent:J,props:H,source:Q})}}function q6($,Z){if(Z)for(let U of Z)switch(U.type){case"space":case"comment":$.push(U);break;case"newline":return $.push(U),!0}return!1}function f2($,Z,U){switch($.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":$.type=U,$.source=Z;break;case"block-scalar":{let X=$.props.slice(1),Q=Z.length;if($.props[0].type==="block-scalar-header")Q-=$.props[0].source.length;for(let z of X)z.offset+=Q;delete $.props,Object.assign($,{type:U,source:Z,end:X});break}case"block-map":case"block-seq":{let Q={type:"newline",offset:$.offset+Z.length,indent:$.indent,source:`
114
+ `};delete $.items,Object.assign($,{type:U,source:Z,end:[Q]});break}default:{let X="indent"in $?$.indent:-1,Q="end"in $&&Array.isArray($.end)?$.end.filter((z)=>z.type==="space"||z.type==="comment"||z.type==="newline"):[];for(let z of Object.keys($))if(z!=="type"&&z!=="offset")delete $[z];Object.assign($,{type:U,indent:X,source:Z,end:Q})}}}Mz.createScalarToken=Iz;Mz.resolveAsScalar=Dz;Mz.setScalarValue=Lz});var G6=R((Tz)=>{var Az=($)=>("type"in $)?W$($):O$($);function W$($){switch($.type){case"block-scalar":{let Z="";for(let U of $.props)Z+=W$(U);return Z+$.source}case"block-map":case"block-seq":{let Z="";for(let U of $.items)Z+=O$(U);return Z}case"flow-collection":{let Z=$.start.source;for(let U of $.items)Z+=O$(U);for(let U of $.end)Z+=U.source;return Z}case"document":{let Z=O$($);if($.end)for(let U of $.end)Z+=U.source;return Z}default:{let Z=$.source;if("end"in $&&$.end)for(let U of $.end)Z+=U.source;return Z}}}function O$({start:$,key:Z,sep:U,value:X}){let Q="";for(let z of $)Q+=z.source;if(Z)Q+=W$(Z);if(U)for(let z of U)Q+=z.source;if(X)Q+=W$(X);return Q}Tz.stringify=Az});var V6=R((Cz)=>{var u2=Symbol("break visit"),wz=Symbol("skip children"),_6=Symbol("remove item");function M0($,Z){if("type"in $&&$.type==="document")$={start:$.start,value:$.value};B6(Object.freeze([]),$,Z)}M0.BREAK=u2;M0.SKIP=wz;M0.REMOVE=_6;M0.itemAtPath=($,Z)=>{let U=$;for(let[X,Q]of Z){let z=U?.[X];if(z&&"items"in z)U=z.items[Q];else return}return U};M0.parentCollection=($,Z)=>{let U=M0.itemAtPath($,Z.slice(0,-1)),X=Z[Z.length-1][0],Q=U?.[X];if(Q&&"items"in Q)return Q;throw Error("Parent collection not found")};function B6($,Z,U){let X=U(Z,$);if(typeof X==="symbol")return X;for(let Q of["key","value"]){let z=Z[Q];if(z&&"items"in z){for(let J=0;J<z.items.length;++J){let H=B6(Object.freeze($.concat([[Q,J]])),z.items[J],U);if(typeof H==="number")J=H-1;else if(H===u2)return u2;else if(H===_6)z.items.splice(J,1),J-=1}if(typeof X==="function"&&Q==="key")X=X(Z,$)}}return typeof X==="function"?X(Z,$):X}Cz.visit=M0});var D$=R((yz)=>{var k2=Y6(),Sz=G6(),Ez=V6(),v2="\uFEFF",m2="\x02",p2="\x18",l2="\x1F",jz=($)=>!!$&&("items"in $),gz=($)=>!!$&&($.type==="scalar"||$.type==="single-quoted-scalar"||$.type==="double-quoted-scalar"||$.type==="block-scalar");function xz($){switch($){case v2:return"<BOM>";case m2:return"<DOC>";case p2:return"<FLOW_END>";case l2:return"<SCALAR>";default:return JSON.stringify($)}}function hz($){switch($){case v2:return"byte-order-mark";case m2:return"doc-mode";case p2:return"flow-error-end";case l2:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
115
115
  `:case`\r
116
- `:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch($[0]){case" ":case"\t":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}LQ.createScalarToken=b2.createScalarToken;LQ.resolveAsScalar=b2.resolveAsScalar;LQ.setScalarValue=b2.setScalarValue;LQ.stringify=qQ.stringify;LQ.visit=BQ.visit;LQ.BOM=C2;LQ.DOCUMENT=j2;LQ.FLOW_END=S2;LQ.SCALAR=E2;LQ.isCollection=VQ;LQ.isScalar=OQ;LQ.prettyToken=WQ;LQ.tokenType=IQ});var f2=D((gQ)=>{var W$=H1();function p($){switch($){case void 0:case" ":case`
117
- `:case"\r":case"\t":return!0;default:return!1}}var Z9=new Set("0123456789ABCDEFabcdef"),SQ=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),G1=new Set(",[]{}"),EQ=new Set(` ,[]{}
118
- \r `),g2=($)=>!$||EQ.has($);class z9{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex($,Z=!1){if($){if(typeof $!=="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+$:$,this.lineEndPos=null}this.atEnd=!Z;let z=this.next??"stream";while(z&&(Z||this.hasChars(1)))z=yield*this.parseNext(z)}atLineEnd(){let $=this.pos,Z=this.buffer[$];while(Z===" "||Z==="\t")Z=this.buffer[++$];if(!Z||Z==="#"||Z===`
116
+ `:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch($[0]){case" ":case"\t":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}yz.createScalarToken=k2.createScalarToken;yz.resolveAsScalar=k2.resolveAsScalar;yz.setScalarValue=k2.setScalarValue;yz.stringify=Sz.stringify;yz.visit=Ez.visit;yz.BOM=v2;yz.DOCUMENT=m2;yz.FLOW_END=p2;yz.SCALAR=l2;yz.isCollection=jz;yz.isScalar=gz;yz.prettyToken=xz;yz.tokenType=hz});var c2=R((tz)=>{var M1=D$();function c($){switch($){case void 0:case" ":case`
117
+ `:case"\r":case"\t":return!0;default:return!1}}var O6=new Set("0123456789ABCDEFabcdef"),nz=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),I$=new Set(",[]{}"),oz=new Set(` ,[]{}
118
+ \r `),d2=($)=>!$||oz.has($);class W6{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex($,Z=!1){if($){if(typeof $!=="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+$:$,this.lineEndPos=null}this.atEnd=!Z;let U=this.next??"stream";while(U&&(Z||this.hasChars(1)))U=yield*this.parseNext(U)}atLineEnd(){let $=this.pos,Z=this.buffer[$];while(Z===" "||Z==="\t")Z=this.buffer[++$];if(!Z||Z==="#"||Z===`
119
119
  `)return!0;if(Z==="\r")return this.buffer[$+1]===`
120
- `;return!1}charAt($){return this.buffer[this.pos+$]}continueScalar($){let Z=this.buffer[$];if(this.indentNext>0){let z=0;while(Z===" ")Z=this.buffer[++z+$];if(Z==="\r"){let X=this.buffer[z+$+1];if(X===`
121
- `||!X&&!this.atEnd)return $+z+1}return Z===`
122
- `||z>=this.indentNext||!Z&&!this.atEnd?$+z:-1}if(Z==="-"||Z==="."){let z=this.buffer.substr($,3);if((z==="---"||z==="...")&&p(this.buffer[$+3]))return-1}return $}getLine(){let $=this.lineEndPos;if(typeof $!=="number"||$!==-1&&$<this.pos)$=this.buffer.indexOf(`
123
- `,this.pos),this.lineEndPos=$;if($===-1)return this.atEnd?this.buffer.substring(this.pos):null;if(this.buffer[$-1]==="\r")$-=1;return this.buffer.substring(this.pos,$)}hasChars($){return this.pos+$<=this.buffer.length}setNext($){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=$,null}peek($){return this.buffer.substr(this.pos,$)}*parseNext($){switch($){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let $=this.getLine();if($===null)return this.setNext("stream");if($[0]===W$.BOM)yield*this.pushCount(1),$=$.substring(1);if($[0]==="%"){let Z=$.length,z=$.indexOf("#");while(z!==-1){let U=$[z-1];if(U===" "||U==="\t"){Z=z-1;break}else z=$.indexOf("#",z+1)}while(!0){let U=$[Z-1];if(U===" "||U==="\t")Z-=1;else break}let X=(yield*this.pushCount(Z))+(yield*this.pushSpaces(!0));return yield*this.pushCount($.length-X),this.pushNewline(),"stream"}if(this.atLineEnd()){let Z=yield*this.pushSpaces(!0);return yield*this.pushCount($.length-Z),yield*this.pushNewline(),"stream"}return yield W$.DOCUMENT,yield*this.parseLineStart()}*parseLineStart(){let $=this.charAt(0);if(!$&&!this.atEnd)return this.setNext("line-start");if($==="-"||$==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");let Z=this.peek(3);if((Z==="---"||Z==="...")&&p(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,Z==="---"?"doc":"stream"}if(this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!p(this.charAt(1)))this.indentNext=this.indentValue;return yield*this.parseBlockStart()}*parseBlockStart(){let[$,Z]=this.peek(2);if(!Z&&!this.atEnd)return this.setNext("block-start");if(($==="-"||$==="?"||$===":")&&p(Z)){let z=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=z,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);let $=this.getLine();if($===null)return this.setNext("doc");let Z=yield*this.pushIndicators();switch($[Z]){case"#":yield*this.pushCount($.length-Z);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(g2),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return Z+=yield*this.parseBlockScalarHeader(),Z+=yield*this.pushSpaces(!0),yield*this.pushCount($.length-Z),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let $,Z,z=-1;do{if($=yield*this.pushNewline(),$>0)Z=yield*this.pushSpaces(!1),this.indentValue=z=Z;else Z=0;Z+=yield*this.pushSpaces(!0)}while($+Z>0);let X=this.getLine();if(X===null)return this.setNext("flow");if(z!==-1&&z<this.indentNext&&X[0]!=="#"||z===0&&(X.startsWith("---")||X.startsWith("..."))&&p(X[3])){if(!(z===this.indentNext-1&&this.flowLevel===1&&(X[0]==="]"||X[0]==="}")))return this.flowLevel=0,yield W$.FLOW_END,yield*this.parseLineStart()}let U=0;while(X[U]===",")U+=yield*this.pushCount(1),U+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(U+=yield*this.pushIndicators(),X[U]){case void 0:return"flow";case"#":return yield*this.pushCount(X.length-U),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(g2),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{let Q=this.charAt(1);if(this.flowKey||p(Q)||Q===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let $=this.charAt(0),Z=this.buffer.indexOf($,this.pos+1);if($==="'")while(Z!==-1&&this.buffer[Z+1]==="'")Z=this.buffer.indexOf("'",Z+2);else while(Z!==-1){let U=0;while(this.buffer[Z-1-U]==="\\")U+=1;if(U%2===0)break;Z=this.buffer.indexOf('"',Z+1)}let z=this.buffer.substring(0,Z),X=z.indexOf(`
124
- `,this.pos);if(X!==-1){while(X!==-1){let U=this.continueScalar(X+1);if(U===-1)break;X=z.indexOf(`
125
- `,U)}if(X!==-1)Z=X-(z[X-1]==="\r"?2:1)}if(Z===-1){if(!this.atEnd)return this.setNext("quoted-scalar");Z=this.buffer.length}return yield*this.pushToIndex(Z+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let $=this.pos;while(!0){let Z=this.buffer[++$];if(Z==="+")this.blockScalarKeep=!0;else if(Z>"0"&&Z<="9")this.blockScalarIndent=Number(Z)-1;else if(Z!=="-")break}return yield*this.pushUntil((Z)=>p(Z)||Z==="#")}*parseBlockScalar(){let $=this.pos-1,Z=0,z;$:for(let U=this.pos;z=this.buffer[U];++U)switch(z){case" ":Z+=1;break;case`
126
- `:$=U,Z=0;break;case"\r":{let Q=this.buffer[U+1];if(!Q&&!this.atEnd)return this.setNext("block-scalar");if(Q===`
127
- `)break}default:break $}if(!z&&!this.atEnd)return this.setNext("block-scalar");if(Z>=this.indentNext){if(this.blockScalarIndent===-1)this.indentNext=Z;else this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let U=this.continueScalar($+1);if(U===-1)break;$=this.buffer.indexOf(`
128
- `,U)}while($!==-1);if($===-1){if(!this.atEnd)return this.setNext("block-scalar");$=this.buffer.length}}let X=$+1;z=this.buffer[X];while(z===" ")z=this.buffer[++X];if(z==="\t"){while(z==="\t"||z===" "||z==="\r"||z===`
129
- `)z=this.buffer[++X];$=X-1}else if(!this.blockScalarKeep)do{let U=$-1,Q=this.buffer[U];if(Q==="\r")Q=this.buffer[--U];let J=U;while(Q===" ")Q=this.buffer[--U];if(Q===`
130
- `&&U>=this.pos&&U+1+Z>J)$=U;else break}while(!0);return yield W$.SCALAR,yield*this.pushToIndex($+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let $=this.flowLevel>0,Z=this.pos-1,z=this.pos-1,X;while(X=this.buffer[++z])if(X===":"){let U=this.buffer[z+1];if(p(U)||$&&G1.has(U))break;Z=z}else if(p(X)){let U=this.buffer[z+1];if(X==="\r")if(U===`
131
- `)z+=1,X=`
132
- `,U=this.buffer[z+1];else Z=z;if(U==="#"||$&&G1.has(U))break;if(X===`
133
- `){let Q=this.continueScalar(z+1);if(Q===-1)break;z=Math.max(z,Q-2)}}else{if($&&G1.has(X))break;Z=z}if(!X&&!this.atEnd)return this.setNext("plain-scalar");return yield W$.SCALAR,yield*this.pushToIndex(Z+1,!0),$?"flow":"doc"}*pushCount($){if($>0)return yield this.buffer.substr(this.pos,$),this.pos+=$,$;return 0}*pushToIndex($,Z){let z=this.buffer.slice(this.pos,$);if(z)return yield z,this.pos+=z.length,z.length;else if(Z)yield"";return 0}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(g2))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{let $=this.flowLevel>0,Z=this.charAt(1);if(p(Z)||$&&G1.has(Z)){if(!$)this.indentNext=this.indentValue+1;else if(this.flowKey)this.flowKey=!1;return(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}}return 0}*pushTag(){if(this.charAt(1)==="<"){let $=this.pos+2,Z=this.buffer[$];while(!p(Z)&&Z!==">")Z=this.buffer[++$];return yield*this.pushToIndex(Z===">"?$+1:$,!1)}else{let $=this.pos+1,Z=this.buffer[$];while(Z)if(SQ.has(Z))Z=this.buffer[++$];else if(Z==="%"&&Z9.has(this.buffer[$+1])&&Z9.has(this.buffer[$+2]))Z=this.buffer[$+=3];else break;return yield*this.pushToIndex($,!1)}}*pushNewline(){let $=this.buffer[this.pos];if($===`
120
+ `;return!1}charAt($){return this.buffer[this.pos+$]}continueScalar($){let Z=this.buffer[$];if(this.indentNext>0){let U=0;while(Z===" ")Z=this.buffer[++U+$];if(Z==="\r"){let X=this.buffer[U+$+1];if(X===`
121
+ `||!X&&!this.atEnd)return $+U+1}return Z===`
122
+ `||U>=this.indentNext||!Z&&!this.atEnd?$+U:-1}if(Z==="-"||Z==="."){let U=this.buffer.substr($,3);if((U==="---"||U==="...")&&c(this.buffer[$+3]))return-1}return $}getLine(){let $=this.lineEndPos;if(typeof $!=="number"||$!==-1&&$<this.pos)$=this.buffer.indexOf(`
123
+ `,this.pos),this.lineEndPos=$;if($===-1)return this.atEnd?this.buffer.substring(this.pos):null;if(this.buffer[$-1]==="\r")$-=1;return this.buffer.substring(this.pos,$)}hasChars($){return this.pos+$<=this.buffer.length}setNext($){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=$,null}peek($){return this.buffer.substr(this.pos,$)}*parseNext($){switch($){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let $=this.getLine();if($===null)return this.setNext("stream");if($[0]===M1.BOM)yield*this.pushCount(1),$=$.substring(1);if($[0]==="%"){let Z=$.length,U=$.indexOf("#");while(U!==-1){let Q=$[U-1];if(Q===" "||Q==="\t"){Z=U-1;break}else U=$.indexOf("#",U+1)}while(!0){let Q=$[Z-1];if(Q===" "||Q==="\t")Z-=1;else break}let X=(yield*this.pushCount(Z))+(yield*this.pushSpaces(!0));return yield*this.pushCount($.length-X),this.pushNewline(),"stream"}if(this.atLineEnd()){let Z=yield*this.pushSpaces(!0);return yield*this.pushCount($.length-Z),yield*this.pushNewline(),"stream"}return yield M1.DOCUMENT,yield*this.parseLineStart()}*parseLineStart(){let $=this.charAt(0);if(!$&&!this.atEnd)return this.setNext("line-start");if($==="-"||$==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");let Z=this.peek(3);if((Z==="---"||Z==="...")&&c(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,Z==="---"?"doc":"stream"}if(this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!c(this.charAt(1)))this.indentNext=this.indentValue;return yield*this.parseBlockStart()}*parseBlockStart(){let[$,Z]=this.peek(2);if(!Z&&!this.atEnd)return this.setNext("block-start");if(($==="-"||$==="?"||$===":")&&c(Z)){let U=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=U,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);let $=this.getLine();if($===null)return this.setNext("doc");let Z=yield*this.pushIndicators();switch($[Z]){case"#":yield*this.pushCount($.length-Z);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(d2),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return Z+=yield*this.parseBlockScalarHeader(),Z+=yield*this.pushSpaces(!0),yield*this.pushCount($.length-Z),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let $,Z,U=-1;do{if($=yield*this.pushNewline(),$>0)Z=yield*this.pushSpaces(!1),this.indentValue=U=Z;else Z=0;Z+=yield*this.pushSpaces(!0)}while($+Z>0);let X=this.getLine();if(X===null)return this.setNext("flow");if(U!==-1&&U<this.indentNext&&X[0]!=="#"||U===0&&(X.startsWith("---")||X.startsWith("..."))&&c(X[3])){if(!(U===this.indentNext-1&&this.flowLevel===1&&(X[0]==="]"||X[0]==="}")))return this.flowLevel=0,yield M1.FLOW_END,yield*this.parseLineStart()}let Q=0;while(X[Q]===",")Q+=yield*this.pushCount(1),Q+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(Q+=yield*this.pushIndicators(),X[Q]){case void 0:return"flow";case"#":return yield*this.pushCount(X.length-Q),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(d2),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{let z=this.charAt(1);if(this.flowKey||c(z)||z===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let $=this.charAt(0),Z=this.buffer.indexOf($,this.pos+1);if($==="'")while(Z!==-1&&this.buffer[Z+1]==="'")Z=this.buffer.indexOf("'",Z+2);else while(Z!==-1){let Q=0;while(this.buffer[Z-1-Q]==="\\")Q+=1;if(Q%2===0)break;Z=this.buffer.indexOf('"',Z+1)}let U=this.buffer.substring(0,Z),X=U.indexOf(`
124
+ `,this.pos);if(X!==-1){while(X!==-1){let Q=this.continueScalar(X+1);if(Q===-1)break;X=U.indexOf(`
125
+ `,Q)}if(X!==-1)Z=X-(U[X-1]==="\r"?2:1)}if(Z===-1){if(!this.atEnd)return this.setNext("quoted-scalar");Z=this.buffer.length}return yield*this.pushToIndex(Z+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let $=this.pos;while(!0){let Z=this.buffer[++$];if(Z==="+")this.blockScalarKeep=!0;else if(Z>"0"&&Z<="9")this.blockScalarIndent=Number(Z)-1;else if(Z!=="-")break}return yield*this.pushUntil((Z)=>c(Z)||Z==="#")}*parseBlockScalar(){let $=this.pos-1,Z=0,U;$:for(let Q=this.pos;U=this.buffer[Q];++Q)switch(U){case" ":Z+=1;break;case`
126
+ `:$=Q,Z=0;break;case"\r":{let z=this.buffer[Q+1];if(!z&&!this.atEnd)return this.setNext("block-scalar");if(z===`
127
+ `)break}default:break $}if(!U&&!this.atEnd)return this.setNext("block-scalar");if(Z>=this.indentNext){if(this.blockScalarIndent===-1)this.indentNext=Z;else this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let Q=this.continueScalar($+1);if(Q===-1)break;$=this.buffer.indexOf(`
128
+ `,Q)}while($!==-1);if($===-1){if(!this.atEnd)return this.setNext("block-scalar");$=this.buffer.length}}let X=$+1;U=this.buffer[X];while(U===" ")U=this.buffer[++X];if(U==="\t"){while(U==="\t"||U===" "||U==="\r"||U===`
129
+ `)U=this.buffer[++X];$=X-1}else if(!this.blockScalarKeep)do{let Q=$-1,z=this.buffer[Q];if(z==="\r")z=this.buffer[--Q];let J=Q;while(z===" ")z=this.buffer[--Q];if(z===`
130
+ `&&Q>=this.pos&&Q+1+Z>J)$=Q;else break}while(!0);return yield M1.SCALAR,yield*this.pushToIndex($+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let $=this.flowLevel>0,Z=this.pos-1,U=this.pos-1,X;while(X=this.buffer[++U])if(X===":"){let Q=this.buffer[U+1];if(c(Q)||$&&I$.has(Q))break;Z=U}else if(c(X)){let Q=this.buffer[U+1];if(X==="\r")if(Q===`
131
+ `)U+=1,X=`
132
+ `,Q=this.buffer[U+1];else Z=U;if(Q==="#"||$&&I$.has(Q))break;if(X===`
133
+ `){let z=this.continueScalar(U+1);if(z===-1)break;U=Math.max(U,z-2)}}else{if($&&I$.has(X))break;Z=U}if(!X&&!this.atEnd)return this.setNext("plain-scalar");return yield M1.SCALAR,yield*this.pushToIndex(Z+1,!0),$?"flow":"doc"}*pushCount($){if($>0)return yield this.buffer.substr(this.pos,$),this.pos+=$,$;return 0}*pushToIndex($,Z){let U=this.buffer.slice(this.pos,$);if(U)return yield U,this.pos+=U.length,U.length;else if(Z)yield"";return 0}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(d2))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{let $=this.flowLevel>0,Z=this.charAt(1);if(c(Z)||$&&I$.has(Z)){if(!$)this.indentNext=this.indentValue+1;else if(this.flowKey)this.flowKey=!1;return(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}}return 0}*pushTag(){if(this.charAt(1)==="<"){let $=this.pos+2,Z=this.buffer[$];while(!c(Z)&&Z!==">")Z=this.buffer[++$];return yield*this.pushToIndex(Z===">"?$+1:$,!1)}else{let $=this.pos+1,Z=this.buffer[$];while(Z)if(nz.has(Z))Z=this.buffer[++$];else if(Z==="%"&&O6.has(this.buffer[$+1])&&O6.has(this.buffer[$+2]))Z=this.buffer[$+=3];else break;return yield*this.pushToIndex($,!1)}}*pushNewline(){let $=this.buffer[this.pos];if($===`
134
134
  `)return yield*this.pushCount(1);else if($==="\r"&&this.charAt(1)===`
135
- `)return yield*this.pushCount(2);else return 0}*pushSpaces($){let Z=this.pos-1,z;do z=this.buffer[++Z];while(z===" "||$&&z==="\t");let X=Z-this.pos;if(X>0)yield this.buffer.substr(this.pos,X),this.pos=Z;return X}*pushUntil($){let Z=this.pos,z=this.buffer[Z];while(!$(z))z=this.buffer[++Z];return yield*this.pushToIndex(Z,!1)}}gQ.Lexer=z9});var y2=D((yQ)=>{class X9{constructor(){this.lineStarts=[],this.addNewLine=($)=>this.lineStarts.push($),this.linePos=($)=>{let Z=0,z=this.lineStarts.length;while(Z<z){let U=Z+z>>1;if(this.lineStarts[U]<$)Z=U+1;else z=U}if(this.lineStarts[Z]===$)return{line:Z+1,col:1};if(Z===0)return{line:0,col:$};let X=this.lineStarts[Z-1];return{line:Z,col:$-X+1}}}}yQ.LineCounter=X9});var h2=D((kQ)=>{var xQ=p0("process"),U9=H1(),uQ=f2();function H0($,Z){for(let z=0;z<$.length;++z)if($[z].type===Z)return!0;return!1}function Q9($){for(let Z=0;Z<$.length;++Z)switch($[Z].type){case"space":case"comment":case"newline":break;default:return Z}return-1}function H9($){switch($?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function _1($){switch($.type){case"document":return $.start;case"block-map":{let Z=$.items[$.items.length-1];return Z.sep??Z.start}case"block-seq":return $.items[$.items.length-1].start;default:return[]}}function f0($){if($.length===0)return[];let Z=$.length;$:while(--Z>=0)switch($[Z].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break $}while($[++Z]?.type==="space");return $.splice(Z,$.length)}function J9($){if($.start.type==="flow-seq-start"){for(let Z of $.items)if(Z.sep&&!Z.value&&!H0(Z.start,"explicit-key-ind")&&!H0(Z.sep,"map-value-ind")){if(Z.key)Z.value=Z.key;if(delete Z.key,H9(Z.value))if(Z.value.end)Array.prototype.push.apply(Z.value.end,Z.sep);else Z.value.end=Z.sep;else Array.prototype.push.apply(Z.start,Z.sep);delete Z.sep}}}class G9{constructor($){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new uQ.Lexer,this.onNewLine=$}*parse($,Z=!1){if(this.onNewLine&&this.offset===0)this.onNewLine(0);for(let z of this.lexer.lex($,Z))yield*this.next(z);if(!Z)yield*this.end()}*next($){if(this.source=$,xQ.env.LOG_TOKENS)console.log("|",U9.prettyToken($));if(this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=$.length;return}let Z=U9.tokenType($);if(!Z){let z=`Not a YAML token: ${$}`;yield*this.pop({type:"error",offset:this.offset,message:z,source:$}),this.offset+=$.length}else if(Z==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=Z,yield*this.step(),Z){case"newline":if(this.atNewLine=!0,this.indent=0,this.onNewLine)this.onNewLine(this.offset+$.length);break;case"space":if(this.atNewLine&&$[0]===" ")this.indent+=$.length;break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":if(this.atNewLine)this.indent+=$.length;break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=$.length}}*end(){while(this.stack.length>0)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let $=this.peek(1);if(this.type==="doc-end"&&$?.type!=="doc-end"){while(this.stack.length>0)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!$)return yield*this.stream();switch($.type){case"document":return yield*this.document($);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar($);case"block-scalar":return yield*this.blockScalar($);case"block-map":return yield*this.blockMap($);case"block-seq":return yield*this.blockSequence($);case"flow-collection":return yield*this.flowCollection($);case"doc-end":return yield*this.documentEnd($)}yield*this.pop()}peek($){return this.stack[this.stack.length-$]}*pop($){let Z=$??this.stack.pop();if(!Z)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield Z;else{let z=this.peek(1);if(Z.type==="block-scalar")Z.indent="indent"in z?z.indent:0;else if(Z.type==="flow-collection"&&z.type==="document")Z.indent=0;if(Z.type==="flow-collection")J9(Z);switch(z.type){case"document":z.value=Z;break;case"block-scalar":z.props.push(Z);break;case"block-map":{let X=z.items[z.items.length-1];if(X.value){z.items.push({start:[],key:Z,sep:[]}),this.onKeyLine=!0;return}else if(X.sep)X.value=Z;else{Object.assign(X,{key:Z,sep:[]}),this.onKeyLine=!X.explicitKey;return}break}case"block-seq":{let X=z.items[z.items.length-1];if(X.value)z.items.push({start:[],value:Z});else X.value=Z;break}case"flow-collection":{let X=z.items[z.items.length-1];if(!X||X.value)z.items.push({start:[],key:Z,sep:[]});else if(X.sep)X.value=Z;else Object.assign(X,{key:Z,sep:[]});return}default:yield*this.pop(),yield*this.pop(Z)}if((z.type==="document"||z.type==="block-map"||z.type==="block-seq")&&(Z.type==="block-map"||Z.type==="block-seq")){let X=Z.items[Z.items.length-1];if(X&&!X.sep&&!X.value&&X.start.length>0&&Q9(X.start)===-1&&(Z.indent===0||X.start.every((U)=>U.type!=="comment"||U.indent<Z.indent))){if(z.type==="document")z.end=X.start;else z.items.push({start:X.start});Z.items.splice(-1,1)}}}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{let $={type:"document",offset:this.offset,start:[]};if(this.type==="doc-start")$.start.push(this.sourceToken);this.stack.push($);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document($){if($.value)return yield*this.lineEnd($);switch(this.type){case"doc-start":{if(Q9($.start)!==-1)yield*this.pop(),yield*this.step();else $.start.push(this.sourceToken);return}case"anchor":case"tag":case"space":case"comment":case"newline":$.start.push(this.sourceToken);return}let Z=this.startBlockValue($);if(Z)this.stack.push(Z);else yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar($){if(this.type==="map-value-ind"){let Z=_1(this.peek(2)),z=f0(Z),X;if($.end)X=$.end,X.push(this.sourceToken),delete $.end;else X=[this.sourceToken];let U={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:z,key:$,sep:X}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=U}else yield*this.lineEnd($)}*blockScalar($){switch(this.type){case"space":case"comment":case"newline":$.props.push(this.sourceToken);return;case"scalar":if($.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let Z=this.source.indexOf(`
135
+ `)return yield*this.pushCount(2);else return 0}*pushSpaces($){let Z=this.pos-1,U;do U=this.buffer[++Z];while(U===" "||$&&U==="\t");let X=Z-this.pos;if(X>0)yield this.buffer.substr(this.pos,X),this.pos=Z;return X}*pushUntil($){let Z=this.pos,U=this.buffer[Z];while(!$(U))U=this.buffer[++Z];return yield*this.pushToIndex(Z,!1)}}tz.Lexer=W6});var i2=R(($J)=>{class D6{constructor(){this.lineStarts=[],this.addNewLine=($)=>this.lineStarts.push($),this.linePos=($)=>{let Z=0,U=this.lineStarts.length;while(Z<U){let Q=Z+U>>1;if(this.lineStarts[Q]<$)Z=Q+1;else U=Q}if(this.lineStarts[Z]===$)return{line:Z+1,col:1};if(Z===0)return{line:0,col:$};let X=this.lineStarts[Z-1];return{line:Z,col:$-X+1}}}}$J.LineCounter=D6});var r2=R((QJ)=>{var UJ=r0("process"),I6=D$(),XJ=c2();function G0($,Z){for(let U=0;U<$.length;++U)if($[U].type===Z)return!0;return!1}function L6($){for(let Z=0;Z<$.length;++Z)switch($[Z].type){case"space":case"comment":case"newline":break;default:return Z}return-1}function M6($){switch($?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function L$($){switch($.type){case"document":return $.start;case"block-map":{let Z=$.items[$.items.length-1];return Z.sep??Z.start}case"block-seq":return $.items[$.items.length-1].start;default:return[]}}function k0($){if($.length===0)return[];let Z=$.length;$:while(--Z>=0)switch($[Z].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break $}while($[++Z]?.type==="space");return $.splice(Z,$.length)}function R6($){if($.start.type==="flow-seq-start"){for(let Z of $.items)if(Z.sep&&!Z.value&&!G0(Z.start,"explicit-key-ind")&&!G0(Z.sep,"map-value-ind")){if(Z.key)Z.value=Z.key;if(delete Z.key,M6(Z.value))if(Z.value.end)Array.prototype.push.apply(Z.value.end,Z.sep);else Z.value.end=Z.sep;else Array.prototype.push.apply(Z.start,Z.sep);delete Z.sep}}}class K6{constructor($){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new XJ.Lexer,this.onNewLine=$}*parse($,Z=!1){if(this.onNewLine&&this.offset===0)this.onNewLine(0);for(let U of this.lexer.lex($,Z))yield*this.next(U);if(!Z)yield*this.end()}*next($){if(this.source=$,UJ.env.LOG_TOKENS)console.log("|",I6.prettyToken($));if(this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=$.length;return}let Z=I6.tokenType($);if(!Z){let U=`Not a YAML token: ${$}`;yield*this.pop({type:"error",offset:this.offset,message:U,source:$}),this.offset+=$.length}else if(Z==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=Z,yield*this.step(),Z){case"newline":if(this.atNewLine=!0,this.indent=0,this.onNewLine)this.onNewLine(this.offset+$.length);break;case"space":if(this.atNewLine&&$[0]===" ")this.indent+=$.length;break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":if(this.atNewLine)this.indent+=$.length;break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=$.length}}*end(){while(this.stack.length>0)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let $=this.peek(1);if(this.type==="doc-end"&&$?.type!=="doc-end"){while(this.stack.length>0)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!$)return yield*this.stream();switch($.type){case"document":return yield*this.document($);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar($);case"block-scalar":return yield*this.blockScalar($);case"block-map":return yield*this.blockMap($);case"block-seq":return yield*this.blockSequence($);case"flow-collection":return yield*this.flowCollection($);case"doc-end":return yield*this.documentEnd($)}yield*this.pop()}peek($){return this.stack[this.stack.length-$]}*pop($){let Z=$??this.stack.pop();if(!Z)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield Z;else{let U=this.peek(1);if(Z.type==="block-scalar")Z.indent="indent"in U?U.indent:0;else if(Z.type==="flow-collection"&&U.type==="document")Z.indent=0;if(Z.type==="flow-collection")R6(Z);switch(U.type){case"document":U.value=Z;break;case"block-scalar":U.props.push(Z);break;case"block-map":{let X=U.items[U.items.length-1];if(X.value){U.items.push({start:[],key:Z,sep:[]}),this.onKeyLine=!0;return}else if(X.sep)X.value=Z;else{Object.assign(X,{key:Z,sep:[]}),this.onKeyLine=!X.explicitKey;return}break}case"block-seq":{let X=U.items[U.items.length-1];if(X.value)U.items.push({start:[],value:Z});else X.value=Z;break}case"flow-collection":{let X=U.items[U.items.length-1];if(!X||X.value)U.items.push({start:[],key:Z,sep:[]});else if(X.sep)X.value=Z;else Object.assign(X,{key:Z,sep:[]});return}default:yield*this.pop(),yield*this.pop(Z)}if((U.type==="document"||U.type==="block-map"||U.type==="block-seq")&&(Z.type==="block-map"||Z.type==="block-seq")){let X=Z.items[Z.items.length-1];if(X&&!X.sep&&!X.value&&X.start.length>0&&L6(X.start)===-1&&(Z.indent===0||X.start.every((Q)=>Q.type!=="comment"||Q.indent<Z.indent))){if(U.type==="document")U.end=X.start;else U.items.push({start:X.start});Z.items.splice(-1,1)}}}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{let $={type:"document",offset:this.offset,start:[]};if(this.type==="doc-start")$.start.push(this.sourceToken);this.stack.push($);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document($){if($.value)return yield*this.lineEnd($);switch(this.type){case"doc-start":{if(L6($.start)!==-1)yield*this.pop(),yield*this.step();else $.start.push(this.sourceToken);return}case"anchor":case"tag":case"space":case"comment":case"newline":$.start.push(this.sourceToken);return}let Z=this.startBlockValue($);if(Z)this.stack.push(Z);else yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar($){if(this.type==="map-value-ind"){let Z=L$(this.peek(2)),U=k0(Z),X;if($.end)X=$.end,X.push(this.sourceToken),delete $.end;else X=[this.sourceToken];let Q={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:U,key:$,sep:X}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=Q}else yield*this.lineEnd($)}*blockScalar($){switch(this.type){case"space":case"comment":case"newline":$.props.push(this.sourceToken);return;case"scalar":if($.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let Z=this.source.indexOf(`
136
136
  `)+1;while(Z!==0)this.onNewLine(this.offset+Z),Z=this.source.indexOf(`
137
- `,Z)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap($){let Z=$.items[$.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,Z.value){let z="end"in Z.value?Z.value.end:void 0;if((Array.isArray(z)?z[z.length-1]:void 0)?.type==="comment")z?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else if(Z.sep)Z.sep.push(this.sourceToken);else Z.start.push(this.sourceToken);return;case"space":case"comment":if(Z.value)$.items.push({start:[this.sourceToken]});else if(Z.sep)Z.sep.push(this.sourceToken);else{if(this.atIndentedComment(Z.start,$.indent)){let X=$.items[$.items.length-2]?.value?.end;if(Array.isArray(X)){Array.prototype.push.apply(X,Z.start),X.push(this.sourceToken),$.items.pop();return}}Z.start.push(this.sourceToken)}return}if(this.indent>=$.indent){let z=!this.onKeyLine&&this.indent===$.indent,X=z&&(Z.sep||Z.explicitKey)&&this.type!=="seq-item-ind",U=[];if(X&&Z.sep&&!Z.value){let Q=[];for(let J=0;J<Z.sep.length;++J){let H=Z.sep[J];switch(H.type){case"newline":Q.push(J);break;case"space":break;case"comment":if(H.indent>$.indent)Q.length=0;break;default:Q.length=0}}if(Q.length>=2)U=Z.sep.splice(Q[1])}switch(this.type){case"anchor":case"tag":if(X||Z.value)U.push(this.sourceToken),$.items.push({start:U}),this.onKeyLine=!0;else if(Z.sep)Z.sep.push(this.sourceToken);else Z.start.push(this.sourceToken);return;case"explicit-key-ind":if(!Z.sep&&!Z.explicitKey)Z.start.push(this.sourceToken),Z.explicitKey=!0;else if(X||Z.value)U.push(this.sourceToken),$.items.push({start:U,explicitKey:!0});else this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]});this.onKeyLine=!0;return;case"map-value-ind":if(Z.explicitKey)if(!Z.sep)if(H0(Z.start,"newline"))Object.assign(Z,{key:null,sep:[this.sourceToken]});else{let Q=f0(Z.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:Q,key:null,sep:[this.sourceToken]}]})}else if(Z.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(H0(Z.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:U,key:null,sep:[this.sourceToken]}]});else if(H9(Z.key)&&!H0(Z.sep,"newline")){let Q=f0(Z.start),J=Z.key,H=Z.sep;H.push(this.sourceToken),delete Z.key,delete Z.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:Q,key:J,sep:H}]})}else if(U.length>0)Z.sep=Z.sep.concat(U,this.sourceToken);else Z.sep.push(this.sourceToken);else if(!Z.sep)Object.assign(Z,{key:null,sep:[this.sourceToken]});else if(Z.value||X)$.items.push({start:U,key:null,sep:[this.sourceToken]});else if(H0(Z.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else Z.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let Q=this.flowScalar(this.type);if(X||Z.value)$.items.push({start:U,key:Q,sep:[]}),this.onKeyLine=!0;else if(Z.sep)this.stack.push(Q);else Object.assign(Z,{key:Q,sep:[]}),this.onKeyLine=!0;return}default:{let Q=this.startBlockValue($);if(Q){if(Q.type==="block-seq"){if(!Z.explicitKey&&Z.sep&&!H0(Z.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else if(z)$.items.push({start:U});this.stack.push(Q);return}}}}yield*this.pop(),yield*this.step()}*blockSequence($){let Z=$.items[$.items.length-1];switch(this.type){case"newline":if(Z.value){let z="end"in Z.value?Z.value.end:void 0;if((Array.isArray(z)?z[z.length-1]:void 0)?.type==="comment")z?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else Z.start.push(this.sourceToken);return;case"space":case"comment":if(Z.value)$.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(Z.start,$.indent)){let X=$.items[$.items.length-2]?.value?.end;if(Array.isArray(X)){Array.prototype.push.apply(X,Z.start),X.push(this.sourceToken),$.items.pop();return}}Z.start.push(this.sourceToken)}return;case"anchor":case"tag":if(Z.value||this.indent<=$.indent)break;Z.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==$.indent)break;if(Z.value||H0(Z.start,"seq-item-ind"))$.items.push({start:[this.sourceToken]});else Z.start.push(this.sourceToken);return}if(this.indent>$.indent){let z=this.startBlockValue($);if(z){this.stack.push(z);return}}yield*this.pop(),yield*this.step()}*flowCollection($){let Z=$.items[$.items.length-1];if(this.type==="flow-error-end"){let z;do yield*this.pop(),z=this.peek(1);while(z?.type==="flow-collection")}else if($.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!Z||Z.sep)$.items.push({start:[this.sourceToken]});else Z.start.push(this.sourceToken);return;case"map-value-ind":if(!Z||Z.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Z.sep)Z.sep.push(this.sourceToken);else Object.assign(Z,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!Z||Z.value)$.items.push({start:[this.sourceToken]});else if(Z.sep)Z.sep.push(this.sourceToken);else Z.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let X=this.flowScalar(this.type);if(!Z||Z.value)$.items.push({start:[],key:X,sep:[]});else if(Z.sep)this.stack.push(X);else Object.assign(Z,{key:X,sep:[]});return}case"flow-map-end":case"flow-seq-end":$.end.push(this.sourceToken);return}let z=this.startBlockValue($);if(z)this.stack.push(z);else yield*this.pop(),yield*this.step()}else{let z=this.peek(2);if(z.type==="block-map"&&(this.type==="map-value-ind"&&z.indent===$.indent||this.type==="newline"&&!z.items[z.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&z.type!=="flow-collection"){let X=_1(z),U=f0(X);J9($);let Q=$.end.splice(1,$.end.length);Q.push(this.sourceToken);let J={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:U,key:$,sep:Q}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=J}else yield*this.lineEnd($)}}flowScalar($){if(this.onNewLine){let Z=this.source.indexOf(`
137
+ `,Z)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap($){let Z=$.items[$.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,Z.value){let U="end"in Z.value?Z.value.end:void 0;if((Array.isArray(U)?U[U.length-1]:void 0)?.type==="comment")U?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else if(Z.sep)Z.sep.push(this.sourceToken);else Z.start.push(this.sourceToken);return;case"space":case"comment":if(Z.value)$.items.push({start:[this.sourceToken]});else if(Z.sep)Z.sep.push(this.sourceToken);else{if(this.atIndentedComment(Z.start,$.indent)){let X=$.items[$.items.length-2]?.value?.end;if(Array.isArray(X)){Array.prototype.push.apply(X,Z.start),X.push(this.sourceToken),$.items.pop();return}}Z.start.push(this.sourceToken)}return}if(this.indent>=$.indent){let U=!this.onKeyLine&&this.indent===$.indent,X=U&&(Z.sep||Z.explicitKey)&&this.type!=="seq-item-ind",Q=[];if(X&&Z.sep&&!Z.value){let z=[];for(let J=0;J<Z.sep.length;++J){let H=Z.sep[J];switch(H.type){case"newline":z.push(J);break;case"space":break;case"comment":if(H.indent>$.indent)z.length=0;break;default:z.length=0}}if(z.length>=2)Q=Z.sep.splice(z[1])}switch(this.type){case"anchor":case"tag":if(X||Z.value)Q.push(this.sourceToken),$.items.push({start:Q}),this.onKeyLine=!0;else if(Z.sep)Z.sep.push(this.sourceToken);else Z.start.push(this.sourceToken);return;case"explicit-key-ind":if(!Z.sep&&!Z.explicitKey)Z.start.push(this.sourceToken),Z.explicitKey=!0;else if(X||Z.value)Q.push(this.sourceToken),$.items.push({start:Q,explicitKey:!0});else this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]});this.onKeyLine=!0;return;case"map-value-ind":if(Z.explicitKey)if(!Z.sep)if(G0(Z.start,"newline"))Object.assign(Z,{key:null,sep:[this.sourceToken]});else{let z=k0(Z.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:z,key:null,sep:[this.sourceToken]}]})}else if(Z.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(G0(Z.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:Q,key:null,sep:[this.sourceToken]}]});else if(M6(Z.key)&&!G0(Z.sep,"newline")){let z=k0(Z.start),J=Z.key,H=Z.sep;H.push(this.sourceToken),delete Z.key,delete Z.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:z,key:J,sep:H}]})}else if(Q.length>0)Z.sep=Z.sep.concat(Q,this.sourceToken);else Z.sep.push(this.sourceToken);else if(!Z.sep)Object.assign(Z,{key:null,sep:[this.sourceToken]});else if(Z.value||X)$.items.push({start:Q,key:null,sep:[this.sourceToken]});else if(G0(Z.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]});else Z.sep.push(this.sourceToken);this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let z=this.flowScalar(this.type);if(X||Z.value)$.items.push({start:Q,key:z,sep:[]}),this.onKeyLine=!0;else if(Z.sep)this.stack.push(z);else Object.assign(Z,{key:z,sep:[]}),this.onKeyLine=!0;return}default:{let z=this.startBlockValue($);if(z){if(z.type==="block-seq"){if(!Z.explicitKey&&Z.sep&&!G0(Z.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else if(U)$.items.push({start:Q});this.stack.push(z);return}}}}yield*this.pop(),yield*this.step()}*blockSequence($){let Z=$.items[$.items.length-1];switch(this.type){case"newline":if(Z.value){let U="end"in Z.value?Z.value.end:void 0;if((Array.isArray(U)?U[U.length-1]:void 0)?.type==="comment")U?.push(this.sourceToken);else $.items.push({start:[this.sourceToken]})}else Z.start.push(this.sourceToken);return;case"space":case"comment":if(Z.value)$.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(Z.start,$.indent)){let X=$.items[$.items.length-2]?.value?.end;if(Array.isArray(X)){Array.prototype.push.apply(X,Z.start),X.push(this.sourceToken),$.items.pop();return}}Z.start.push(this.sourceToken)}return;case"anchor":case"tag":if(Z.value||this.indent<=$.indent)break;Z.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==$.indent)break;if(Z.value||G0(Z.start,"seq-item-ind"))$.items.push({start:[this.sourceToken]});else Z.start.push(this.sourceToken);return}if(this.indent>$.indent){let U=this.startBlockValue($);if(U){this.stack.push(U);return}}yield*this.pop(),yield*this.step()}*flowCollection($){let Z=$.items[$.items.length-1];if(this.type==="flow-error-end"){let U;do yield*this.pop(),U=this.peek(1);while(U?.type==="flow-collection")}else if($.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":if(!Z||Z.sep)$.items.push({start:[this.sourceToken]});else Z.start.push(this.sourceToken);return;case"map-value-ind":if(!Z||Z.value)$.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Z.sep)Z.sep.push(this.sourceToken);else Object.assign(Z,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":if(!Z||Z.value)$.items.push({start:[this.sourceToken]});else if(Z.sep)Z.sep.push(this.sourceToken);else Z.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let X=this.flowScalar(this.type);if(!Z||Z.value)$.items.push({start:[],key:X,sep:[]});else if(Z.sep)this.stack.push(X);else Object.assign(Z,{key:X,sep:[]});return}case"flow-map-end":case"flow-seq-end":$.end.push(this.sourceToken);return}let U=this.startBlockValue($);if(U)this.stack.push(U);else yield*this.pop(),yield*this.step()}else{let U=this.peek(2);if(U.type==="block-map"&&(this.type==="map-value-ind"&&U.indent===$.indent||this.type==="newline"&&!U.items[U.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&U.type!=="flow-collection"){let X=L$(U),Q=k0(X);R6($);let z=$.end.splice(1,$.end.length);z.push(this.sourceToken);let J={type:"block-map",offset:$.offset,indent:$.indent,items:[{start:Q,key:$,sep:z}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=J}else yield*this.lineEnd($)}}flowScalar($){if(this.onNewLine){let Z=this.source.indexOf(`
138
138
  `)+1;while(Z!==0)this.onNewLine(this.offset+Z),Z=this.source.indexOf(`
139
- `,Z)+1}return{type:$,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue($){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let Z=_1($),z=f0(Z);return z.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:z,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let Z=_1($),z=f0(Z);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:z,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment($,Z){if(this.type!=="comment")return!1;if(this.indent<=Z)return!1;return $.every((z)=>z.type==="newline"||z.type==="space")}*documentEnd($){if(this.type!=="doc-mode"){if($.end)$.end.push(this.sourceToken);else $.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd($){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if($.end)$.end.push(this.sourceToken);else $.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}kQ.Parser=G9});var V9=D((aQ)=>{var _9=A2(),mQ=Y$(),I$=q$(),pQ=y1(),lQ=b(),dQ=y2(),Y9=h2();function q9($){let Z=$.prettyErrors!==!1;return{lineCounter:$.lineCounter||Z&&new dQ.LineCounter||null,prettyErrors:Z}}function cQ($,Z={}){let{lineCounter:z,prettyErrors:X}=q9(Z),U=new Y9.Parser(z?.addNewLine),Q=new _9.Composer(Z),J=Array.from(Q.compose(U.parse($)));if(X&&z)for(let H of J)H.errors.forEach(I$.prettifyError($,z)),H.warnings.forEach(I$.prettifyError($,z));if(J.length>0)return J;return Object.assign([],{empty:!0},Q.streamInfo())}function B9($,Z={}){let{lineCounter:z,prettyErrors:X}=q9(Z),U=new Y9.Parser(z?.addNewLine),Q=new _9.Composer(Z),J=null;for(let H of Q.compose(U.parse($),!0,$.length))if(!J)J=H;else if(J.options.logLevel!=="silent"){J.errors.push(new I$.YAMLParseError(H.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(X&&z)J.errors.forEach(I$.prettifyError($,z)),J.warnings.forEach(I$.prettifyError($,z));return J}function iQ($,Z,z){let X=void 0;if(typeof Z==="function")X=Z;else if(z===void 0&&Z&&typeof Z==="object")z=Z;let U=B9($,z);if(!U)return null;if(U.warnings.forEach((Q)=>pQ.warn(U.options.logLevel,Q)),U.errors.length>0)if(U.options.logLevel!=="silent")throw U.errors[0];else U.errors=[];return U.toJS(Object.assign({reviver:X},z))}function sQ($,Z,z){let X=null;if(typeof Z==="function"||Array.isArray(Z))X=Z;else if(z===void 0&&Z)z=Z;if(typeof z==="string")z=z.length;if(typeof z==="number"){let U=Math.round(z);z=U<1?void 0:U>8?{indent:8}:{indent:U}}if($===void 0){let{keepUndefined:U}=z??Z??{};if(!U)return}if(lQ.isDocument($)&&!X)return $.toString(z);return new mQ.Document($,X,z).toString(z)}aQ.parse=iQ;aQ.parseAllDocuments=cQ;aQ.parseDocument=B9;aQ.stringify=sQ});var y=[{index:1,path:"project.name",label:"Name",description:"Project name",category:"project"},{index:2,path:"project.goal",label:"Goal",description:"Goal (use case)",category:"project"},{index:3,path:"project.main_language",label:"Language",description:"Primary language",category:"project"},{index:4,path:"human_context.who",label:"Who",description:"Who is this for?",category:"human"},{index:5,path:"human_context.what",label:"What",description:"What are they building",category:"human"},{index:6,path:"human_context.why",label:"Why",description:"Why does it exist",category:"human"},{index:7,path:"human_context.where",label:"Where",description:"Where does it run",category:"human"},{index:8,path:"human_context.when",label:"When",description:"When was it started / timeline",category:"human"},{index:9,path:"human_context.how",label:"How",description:"How is it built",category:"human"},{index:10,path:"stack.frontend",canonical:"stack.framework",label:"Framework",description:"Framework (React, Svelte, etc.)",category:"frontend"},{index:11,path:"stack.css_framework",canonical:"stack.css",label:"CSS",description:"CSS framework",category:"frontend"},{index:12,path:"stack.ui_library",label:"UI Library",description:"UI component library",category:"frontend"},{index:13,path:"stack.state_management",canonical:"stack.state",label:"State",description:"State management",category:"frontend"},{index:14,path:"stack.backend",label:"Backend",description:"Backend framework",category:"backend"},{index:15,path:"stack.api_type",canonical:"stack.api",label:"API",description:"API style (REST, GraphQL, etc.)",category:"backend"},{index:16,path:"stack.runtime",label:"Runtime",description:"Runtime (Node, Bun, Python, etc.)",category:"backend"},{index:17,path:"stack.database",canonical:"stack.db",label:"Database",description:"Database",category:"backend"},{index:18,path:"stack.connection",label:"Connection",description:"Connection method (Prisma, etc.)",category:"backend"},{index:19,path:"stack.hosting",label:"Hosting",description:"Hosting platform",category:"universal"},{index:20,path:"stack.build",label:"Build",description:"Build tool",category:"universal"},{index:21,path:"stack.cicd",label:"CI/CD",description:"CI/CD",category:"universal"},{index:22,path:"stack.monorepo_tool",label:"Monorepo",description:"Monorepo tool",category:"enterprise_infra"},{index:23,path:"stack.package_manager",canonical:"stack.pkg_manager",label:"Package Manager",description:"Package manager",category:"enterprise_infra"},{index:24,path:"stack.workspaces",label:"Workspaces",description:"Workspace configuration",category:"enterprise_infra"},{index:25,path:"monorepo.packages_count",label:"Packages",description:"Number of packages",category:"enterprise_infra"},{index:26,path:"monorepo.build_orchestrator",label:"Build Orchestrator",description:"Build orchestration tool",category:"enterprise_infra"},{index:27,path:"stack.admin",label:"Admin",description:"Admin panel",category:"enterprise_app"},{index:28,path:"stack.cache",label:"Cache",description:"Caching layer",category:"enterprise_app"},{index:29,path:"stack.search",label:"Search",description:"Search engine",category:"enterprise_app"},{index:30,path:"stack.storage",label:"Storage",description:"Object storage",category:"enterprise_app"},{index:31,path:"monorepo.versioning_strategy",label:"Versioning",description:"Version strategy",category:"enterprise_ops"},{index:32,path:"monorepo.shared_configs",label:"Shared Configs",description:"Shared configs",category:"enterprise_ops"},{index:33,path:"monorepo.remote_cache",label:"Remote Cache",description:"Remote build cache",category:"enterprise_ops"}],l0=new Map(y.flatMap(($)=>$.canonical?[[$.path,$],[$.canonical,$]]:[[$.path,$]])),eG=new Map(y.filter(($)=>$.canonical).map(($)=>[$.canonical,$.path])),$_=new Map(y.filter(($)=>$.canonical).map(($)=>[$.path,$.canonical]));function Q3($,Z){let z=(U)=>{let Q=U.split("."),J=$;for(let H of Q)if(J&&typeof J==="object"&&H in J)J=J[H];else return;return J},X=z(Z.path);if(X!==void 0)return X;if(Z.canonical)return z(Z.canonical);return}function j6($){return y.filter((Z)=>Z.category===$)}var S6=y.filter(($)=>$.index<=21),E6=y,M$=new Set(["describe your project goal","development teams","cloud platform","null","none","unknown","n/a","not applicable"]);function Y0($){if($===null||$===void 0||$==="")return!0;if(typeof $==="string")return M$.has($.toLowerCase().trim());if(Array.isArray($)&&$.length===0)return!0;if(typeof $==="object"&&Object.keys($).length===0)return!0;return!1}var K0={about:[],documentation:["project","human"],intent:["project","human"],encyclopedia:["project","human"],cli:["project","human","universal"],library:["project","human","universal"],sdk:["project","human","universal"],wasm:["project","human","universal"],html:["project","human","universal"],"server-card":["project","human","universal"],frontend:["project","frontend","human","universal"],website:["project","frontend","human","universal"],mobile:["project","frontend","human","universal"],extension:["project","frontend","human","universal"],mcp:["project","backend","human","universal"],backend:["project","backend","universal","human"],"data-science":["project","backend","human","universal"],fullstack:["project","frontend","backend","universal","human"],svelte:["project","frontend","backend","universal","human"],framework:["project","frontend","backend","universal","human"],"monorepo-root":["project","human","enterprise_infra","enterprise_app","enterprise_ops"],mcpaas:["project","backend","universal","human","enterprise_app","enterprise_ops"],saas:["project","frontend","backend","universal","human","enterprise_app"],enterprise:["project","frontend","backend","universal","human","enterprise_infra","enterprise_app","enterprise_ops"]};var M1=($)=>(Z)=>`\x1B[${$}m${Z}\x1B[0m`,K$=M1("1"),d0=M1("2"),z_=M1("3"),c0={cyan:"#00D4D4",cyanDeep:"#0E8C8C",orange:"#FF6B35"},P$=($)=>`\x1B[38;2;0;212;212m${$}\x1B[0m`,K1=($)=>`\x1B[38;2;14;140;140m${$}\x1B[0m`,P0=($)=>`\x1B[38;5;208m${$}\x1B[0m`;var a=[{name:"TROPHY",indicator:`${P0("✪")} ${P0("TROPHY")}`,threshold:100},{name:"GOLD",indicator:`${P0(K$("★"))} ${P0("GOLD")}`,threshold:99},{name:"SILVER",indicator:`${P$("◆")} ${P$("SILVER")}`,threshold:95},{name:"BRONZE",indicator:`${K1("◇")} ${K1("BRONZE")}`,threshold:85},{name:"GREEN",indicator:`${K$("●")} GREEN`,threshold:70},{name:"YELLOW",indicator:`${d0("●")} YELLOW`,threshold:55},{name:"RED",indicator:`${d0("○")} RED`,threshold:1},{name:"WHITE",indicator:`${d0("♡")}`,threshold:0}];function i0($){for(let Z of a)if($>=Z.threshold)return Z;return a[a.length-1]}function g6($){let Z=i0($),z=a.indexOf(Z);return z>0?a[z-1]:null}var A1={};b6(A1,{validate:()=>y6,sdkVersion:()=>v6,scoreFafb:()=>k6,scoreEnterprise:()=>f6,score:()=>T1,fafbInfo:()=>u6,decompile:()=>x6,compile:()=>h6});var P1=null;function e(){if(P1)return P1;try{let $=p0("faf-scoring-kernel");return P1=$,$}catch{throw Error(`faf-scoring-kernel not installed.
139
+ `,Z)+1}return{type:$,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue($){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let Z=L$($),U=k0(Z);return U.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:U,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let Z=L$($),U=k0(Z);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:U,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment($,Z){if(this.type!=="comment")return!1;if(this.indent<=Z)return!1;return $.every((U)=>U.type==="newline"||U.type==="space")}*documentEnd($){if(this.type!=="doc-mode"){if($.end)$.end.push(this.sourceToken);else $.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}*lineEnd($){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:if($.end)$.end.push(this.sourceToken);else $.end=[this.sourceToken];if(this.type==="newline")yield*this.pop()}}}QJ.Parser=K6});var N6=R((VJ)=>{var F6=y2(),JJ=W1(),K1=D1(),HJ=i$(),qJ=C(),YJ=i2(),P6=r2();function A6($){let Z=$.prettyErrors!==!1;return{lineCounter:$.lineCounter||Z&&new YJ.LineCounter||null,prettyErrors:Z}}function GJ($,Z={}){let{lineCounter:U,prettyErrors:X}=A6(Z),Q=new P6.Parser(U?.addNewLine),z=new F6.Composer(Z),J=Array.from(z.compose(Q.parse($)));if(X&&U)for(let H of J)H.errors.forEach(K1.prettifyError($,U)),H.warnings.forEach(K1.prettifyError($,U));if(J.length>0)return J;return Object.assign([],{empty:!0},z.streamInfo())}function T6($,Z={}){let{lineCounter:U,prettyErrors:X}=A6(Z),Q=new P6.Parser(U?.addNewLine),z=new F6.Composer(Z),J=null;for(let H of z.compose(Q.parse($),!0,$.length))if(!J)J=H;else if(J.options.logLevel!=="silent"){J.errors.push(new K1.YAMLParseError(H.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}if(X&&U)J.errors.forEach(K1.prettifyError($,U)),J.warnings.forEach(K1.prettifyError($,U));return J}function _J($,Z,U){let X=void 0;if(typeof Z==="function")X=Z;else if(U===void 0&&Z&&typeof Z==="object")U=Z;let Q=T6($,U);if(!Q)return null;if(Q.warnings.forEach((z)=>HJ.warn(Q.options.logLevel,z)),Q.errors.length>0)if(Q.options.logLevel!=="silent")throw Q.errors[0];else Q.errors=[];return Q.toJS(Object.assign({reviver:X},U))}function BJ($,Z,U){let X=null;if(typeof Z==="function"||Array.isArray(Z))X=Z;else if(U===void 0&&Z)U=Z;if(typeof U==="string")U=U.length;if(typeof U==="number"){let Q=Math.round(U);U=Q<1?void 0:Q>8?{indent:8}:{indent:Q}}if($===void 0){let{keepUndefined:Q}=U??Z??{};if(!Q)return}if(qJ.isDocument($)&&!X)return $.toString(U);return new JJ.Document($,X,U).toString(U)}VJ.parse=_J;VJ.parseAllDocuments=GJ;VJ.parseDocument=T6;VJ.stringify=BJ});var y=[{index:1,path:"project.name",label:"Name",description:"Project name",category:"project"},{index:2,path:"project.goal",label:"Goal",description:"Goal (use case)",category:"project"},{index:3,path:"project.main_language",label:"Language",description:"Primary language",category:"project"},{index:4,path:"human_context.who",label:"Who",description:"Who is this for?",category:"human"},{index:5,path:"human_context.what",label:"What",description:"What are they building",category:"human"},{index:6,path:"human_context.why",label:"Why",description:"Why does it exist",category:"human"},{index:7,path:"human_context.where",label:"Where",description:"Where does it run",category:"human"},{index:8,path:"human_context.when",label:"When",description:"When was it started / timeline",category:"human"},{index:9,path:"human_context.how",label:"How",description:"How is it built",category:"human"},{index:10,path:"stack.frontend",canonical:"stack.framework",label:"Framework",description:"Framework (React, Svelte, etc.)",category:"frontend"},{index:11,path:"stack.css_framework",canonical:"stack.css",label:"CSS",description:"CSS framework",category:"frontend"},{index:12,path:"stack.ui_library",label:"UI Library",description:"UI component library",category:"frontend"},{index:13,path:"stack.state_management",canonical:"stack.state",label:"State",description:"State management",category:"frontend"},{index:14,path:"stack.backend",label:"Backend",description:"Backend framework",category:"backend"},{index:15,path:"stack.api_type",canonical:"stack.api",label:"API",description:"API style (REST, GraphQL, etc.)",category:"backend"},{index:16,path:"stack.runtime",label:"Runtime",description:"Runtime (Node, Bun, Python, etc.)",category:"backend"},{index:17,path:"stack.database",canonical:"stack.db",label:"Database",description:"Database",category:"backend"},{index:18,path:"stack.connection",label:"Connection",description:"Connection method (Prisma, etc.)",category:"backend"},{index:19,path:"stack.hosting",label:"Hosting",description:"Hosting platform",category:"universal"},{index:20,path:"stack.build",label:"Build",description:"Build tool",category:"universal"},{index:21,path:"stack.cicd",label:"CI/CD",description:"CI/CD",category:"universal"},{index:22,path:"stack.monorepo_tool",label:"Monorepo",description:"Monorepo tool",category:"enterprise_infra"},{index:23,path:"stack.package_manager",canonical:"stack.pkg_manager",label:"Package Manager",description:"Package manager",category:"enterprise_infra"},{index:24,path:"stack.workspaces",label:"Workspaces",description:"Workspace configuration",category:"enterprise_infra"},{index:25,path:"monorepo.packages_count",label:"Packages",description:"Number of packages",category:"enterprise_infra"},{index:26,path:"monorepo.build_orchestrator",label:"Build Orchestrator",description:"Build orchestration tool",category:"enterprise_infra"},{index:27,path:"stack.admin",label:"Admin",description:"Admin panel",category:"enterprise_app"},{index:28,path:"stack.cache",label:"Cache",description:"Caching layer",category:"enterprise_app"},{index:29,path:"stack.search",label:"Search",description:"Search engine",category:"enterprise_app"},{index:30,path:"stack.storage",label:"Storage",description:"Object storage",category:"enterprise_app"},{index:31,path:"monorepo.versioning_strategy",label:"Versioning",description:"Version strategy",category:"enterprise_ops"},{index:32,path:"monorepo.shared_configs",label:"Shared Configs",description:"Shared configs",category:"enterprise_ops"},{index:33,path:"monorepo.remote_cache",label:"Remote Cache",description:"Remote build cache",category:"enterprise_ops"}],s0=new Map(y.flatMap(($)=>$.canonical?[[$.path,$],[$.canonical,$]]:[[$.path,$]])),ZG=new Map(y.filter(($)=>$.canonical).map(($)=>[$.canonical,$.path])),UG=new Map(y.filter(($)=>$.canonical).map(($)=>[$.path,$.canonical]));function L3($,Z){let U=(Q)=>{let z=Q.split("."),J=$;for(let H of z)if(J&&typeof J==="object"&&H in J)J=J[H];else return;return J},X=U(Z.path);if(X!==void 0)return X;if(Z.canonical)return U(Z.canonical);return}function a9($){return y.filter((Z)=>Z.category===$)}var n9=y.filter(($)=>$.index<=21),o9=y,S1=new Set(["describe your project goal","development teams","cloud platform","null","none","unknown","n/a","not applicable"]);function V0($){if($===null||$===void 0||$==="")return!0;if(typeof $==="string")return S1.has($.toLowerCase().trim());if(Array.isArray($)&&$.length===0)return!0;if(typeof $==="object"&&Object.keys($).length===0)return!0;return!1}var w0={about:[],documentation:["project","human"],intent:["project","human"],encyclopedia:["project","human"],cli:["project","human","universal"],library:["project","human","universal"],sdk:["project","human","universal"],wasm:["project","human","universal"],html:["project","human","universal"],"server-card":["project","human","universal"],frontend:["project","frontend","human","universal"],website:["project","frontend","human","universal"],mobile:["project","frontend","human","universal"],extension:["project","frontend","human","universal"],mcp:["project","backend","human","universal"],backend:["project","backend","universal","human"],"data-science":["project","backend","human","universal"],fullstack:["project","frontend","backend","universal","human"],svelte:["project","frontend","backend","universal","human"],framework:["project","frontend","backend","universal","human"],"monorepo-root":["project","human","enterprise_infra","enterprise_app","enterprise_ops"],mcpaas:["project","backend","universal","human","enterprise_app","enterprise_ops"],saas:["project","frontend","backend","universal","human","enterprise_app"],enterprise:["project","frontend","backend","universal","human","enterprise_infra","enterprise_app","enterprise_ops"]};var j$=($)=>(Z)=>`\x1B[${$}m${Z}\x1B[0m`,E1=j$("1"),a0=j$("2"),QG=j$("3"),n0={cyan:"#00D4D4",cyanDeep:"#0E8C8C",orange:"#FF6B35"},j1=($)=>`\x1B[38;2;0;212;212m${$}\x1B[0m`,g$=($)=>`\x1B[38;2;14;140;140m${$}\x1B[0m`,C0=($)=>`\x1B[38;5;208m${$}\x1B[0m`;var n=[{name:"TROPHY",indicator:`${C0("✪")} ${C0("TROPHY")}`,threshold:100},{name:"GOLD",indicator:`${C0(E1("★"))} ${C0("GOLD")}`,threshold:99},{name:"SILVER",indicator:`${j1("◆")} ${j1("SILVER")}`,threshold:95},{name:"BRONZE",indicator:`${g$("◇")} ${g$("BRONZE")}`,threshold:85},{name:"GREEN",indicator:`${E1("●")} GREEN`,threshold:70},{name:"YELLOW",indicator:`${a0("●")} YELLOW`,threshold:55},{name:"RED",indicator:`${a0("○")} RED`,threshold:1},{name:"WHITE",indicator:`${a0("♡")}`,threshold:0}];function o0($){for(let Z of n)if($>=Z.threshold)return Z;return n[n.length-1]}function t9($){let Z=o0($),U=n.indexOf(Z);return U>0?n[U-1]:null}var y$={};r9(y$,{validate:()=>$Z,sdkVersion:()=>zZ,scoreFafb:()=>QZ,scoreEnterprise:()=>e9,score:()=>h$,fafbInfo:()=>XZ,decompile:()=>UZ,compile:()=>ZZ});var x$=null;function U0(){if(x$)return x$;try{let $=r0("faf-scoring-kernel");return x$=$,$}catch{throw Error(`faf-scoring-kernel not installed.
140
140
 
141
141
  Run: npm install faf-scoring-kernel
142
- `)}}function T1($){return JSON.parse(e().score_faf($))}function f6($){return JSON.parse(e().score_faf_enterprise($))}function y6($){return e().validate_faf($)}function h6($){return e().compile_fafb($)}function x6($){return JSON.parse(e().decompile_fafb($))}function u6($){return JSON.parse(e().fafb_info($))}function k6($){return JSON.parse(e().score_fafb($))}function v6(){return e().sdk_version()}function J3($){return{score:$.score,tier:i0($.score),populated:$.populated,empty:$.empty,ignored:$.ignored,active:$.active,total:$.total,slots:$.slots}}function N1($){if(/^\s*app_type:\s*about\s*$/m.test($)){let z=$.match(/^\s+source_score:\s*(\d+)\s*$/m),X=z?parseInt(z[1],10):-1,U=X>=0&&X<=100?X:-1,Q=$.match(/^\s+represents:\s*(\S+)\s*$/m),J=Q?Q[1]:void 0;return{score:U,tier:U>=0?i0(U):a[a.length-1],populated:0,empty:0,ignored:0,active:0,total:0,slots:{},inherited:!0,represents:J}}return J3(T1($))}function m6($){let Z=[];if(!$||typeof $!=="object")return Z.push("File is not a valid YAML mapping"),{valid:!1,errors:Z};let z=$;if(!z.faf_version)Z.push("Missing required field: faf_version");if(!z.project?.name)Z.push("Missing required field: project.name");if(z.app_type==="about"){if(!z.about?.represents)Z.push("app_type 'about' requires about.represents (owner/repo of the source codebase)");else if(!/^[A-Za-z0-9_.-]+\/[A-Za-z0-9_.-]+$/.test(z.about.represents))Z.push(`about.represents must be "owner/repo" format (got: ${z.about.represents})`);if(z.about?.source_score!==void 0){let X=z.about.source_score;if(typeof X!=="number"||X<0||X>100)Z.push(`about.source_score must be a number 0-100 (got: ${X})`)}}return{valid:Z.length===0,errors:Z}}import{readFileSync as L9,writeFileSync as CY,existsSync as W9}from"fs";import{join as I9,dirname as hJ,basename as SY}from"path";var eQ=A2(),$J=Y$(),ZJ=_2(),x2=q$(),zJ=r0(),G0=b(),XJ=X0(),UJ=g(),QJ=Q0(),JJ=J0(),NY=H1(),HJ=f2(),GJ=y2(),_J=h2(),Y1=V9(),O9=s0();var YJ=eQ.Composer,qJ=$J.Document,BJ=ZJ.Schema,VJ=x2.YAMLError,OJ=x2.YAMLParseError,WJ=x2.YAMLWarning,IJ=zJ.Alias,LJ=G0.isAlias,DJ=G0.isCollection,RJ=G0.isDocument,FJ=G0.isMap,MJ=G0.isNode,KJ=G0.isPair,PJ=G0.isScalar,TJ=G0.isSeq,AJ=XJ.Pair,NJ=UJ.Scalar,wJ=QJ.YAMLMap,bJ=JJ.YAMLSeq;var CJ=HJ.Lexer,jJ=GJ.LineCounter,SJ=_J.Parser,o=Y1.parse,EJ=Y1.parseAllDocuments,gJ=Y1.parseDocument,q1=Y1.stringify,fJ=O9.visit,yJ=O9.visitAsync;function xJ($){let Z=L9($,"utf-8");return o(Z)}function D9($){return L9($,"utf-8")}function R9($=process.cwd()){let Z=["project.faf",".faf"];for(let X of Z){let U=I9($,X);if(W9(U))return U}let z=hJ($);if(z!==$)for(let X of Z){let U=I9(z,X);if(W9(U))return U}return null}import{writeFileSync as uJ}from"fs";import{join as kJ}from"path";var F9=c0.orange,vJ=c0.cyan,mJ=c0.cyanDeep,pJ="#FF9500",lJ="#FF3B30",dJ="#E6EDF3",cJ="#6E7681",M9={TROPHY:{glyph:"✪",color:F9},GOLD:{glyph:"★",color:F9},SILVER:{glyph:"◆",color:vJ},BRONZE:{glyph:"◇",color:mJ},GREEN:{glyph:"●",color:dJ},YELLOW:{glyph:"●",color:pJ},RED:{glyph:"○",color:lJ},WHITE:{glyph:"♡",color:cJ}};function y0($){return String($??"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}var K9=["who","what","why","where","when","how"];function B1($){return $.filter(([,Z])=>Z!==void 0&&Z!==null&&String(Z).trim()!=="").map(([Z,z])=>`<div class="row"><div class="k">${y0(Z)}</div><div class="v">${y0(z)}</div></div>`).join(`
143
- `)}function P9($,Z,z="project.faf"){let X=y0($.project?.name??"Project"),U=Z.tier?.name??"WHITE",Q=M9[U]??M9.WHITE,J=Z.inherited?Z.represents?`inherited from ${y0(Z.represents)}`:"inherited":`${Z.score}%`,H=U==="TROPHY"&&!Z.inherited,G=$.human_context??{},_=K9.map((V)=>[V,G[V]]),B=Object.entries(G).filter(([V])=>!K9.includes(V)),Y=[["goal",$.project?.goal],["main_language",$.project?.main_language],["type",$.project?.type],["framework",$.project?.framework],["faf_version",$.faf_version]],q=Object.entries($.stack??{}),W=q.filter(([,V])=>V&&V!=="slotignored"&&String(V).trim()!==""),I=q.filter(([,V])=>V==="slotignored").length;return`<!DOCTYPE html>
142
+ `)}}function h$($){return JSON.parse(U0().score_faf($))}function e9($){return JSON.parse(U0().score_faf_enterprise($))}function $Z($){return U0().validate_faf($)}function ZZ($){return U0().compile_fafb($)}function UZ($){return JSON.parse(U0().decompile_fafb($))}function XZ($){return JSON.parse(U0().fafb_info($))}function QZ($){return JSON.parse(U0().score_fafb($))}function zZ(){return U0().sdk_version()}function R3($){return{score:$.score,tier:o0($.score),populated:$.populated,empty:$.empty,ignored:$.ignored,active:$.active,total:$.total,slots:$.slots}}function f$($){if(/^\s*app_type:\s*about\s*$/m.test($)){let U=$.match(/^\s+source_score:\s*(\d+)\s*$/m),X=U?parseInt(U[1],10):-1,Q=X>=0&&X<=100?X:-1,z=$.match(/^\s+represents:\s*(\S+)\s*$/m),J=z?z[1]:void 0;return{score:Q,tier:Q>=0?o0(Q):n[n.length-1],populated:0,empty:0,ignored:0,active:0,total:0,slots:{},inherited:!0,represents:J}}return R3(h$($))}function JZ($){let Z=[];if(!$||typeof $!=="object")return Z.push("File is not a valid YAML mapping"),{valid:!1,errors:Z};let U=$;if(!U.faf_version)Z.push("Missing required field: faf_version");if(!U.project?.name)Z.push("Missing required field: project.name");if(U.app_type==="about"){if(!U.about?.represents)Z.push("app_type 'about' requires about.represents (owner/repo of the source codebase)");else if(!/^[A-Za-z0-9_.-]+\/[A-Za-z0-9_.-]+$/.test(U.about.represents))Z.push(`about.represents must be "owner/repo" format (got: ${U.about.represents})`);if(U.about?.source_score!==void 0){let X=U.about.source_score;if(typeof X!=="number"||X<0||X>100)Z.push(`about.source_score must be a number 0-100 (got: ${X})`)}}return{valid:Z.length===0,errors:Z}}import{readFileSync as S6,writeFileSync as E_,existsSync as C6}from"fs";import{join as b6,dirname as ZH,basename as g_}from"path";var LJ=y2(),RJ=W1(),MJ=M2(),s2=D1(),KJ=$1(),_0=C(),FJ=J0(),PJ=x(),AJ=q0(),TJ=Y0(),C_=D$(),NJ=c2(),wJ=i2(),CJ=r2(),R$=N6(),w6=t0();var bJ=LJ.Composer,SJ=RJ.Document,EJ=MJ.Schema,jJ=s2.YAMLError,gJ=s2.YAMLParseError,xJ=s2.YAMLWarning,hJ=KJ.Alias,yJ=_0.isAlias,fJ=_0.isCollection,uJ=_0.isDocument,kJ=_0.isMap,vJ=_0.isNode,mJ=_0.isPair,pJ=_0.isScalar,lJ=_0.isSeq,dJ=FJ.Pair,cJ=PJ.Scalar,iJ=AJ.YAMLMap,rJ=TJ.YAMLSeq;var sJ=NJ.Lexer,aJ=wJ.LineCounter,nJ=CJ.Parser,e=R$.parse,oJ=R$.parseAllDocuments,tJ=R$.parseDocument,M$=R$.stringify,eJ=w6.visit,$H=w6.visitAsync;function UH($){let Z=S6($,"utf-8");return e(Z)}function E6($){return S6($,"utf-8")}function j6($=process.cwd()){let Z=["project.faf",".faf"];for(let X of Z){let Q=b6($,X);if(C6(Q))return Q}let U=ZH($);if(U!==$)for(let X of Z){let Q=b6(U,X);if(C6(Q))return Q}return null}import{writeFileSync as XH}from"fs";import{join as QH}from"path";var g6=n0.orange,zH=n0.cyan,JH=n0.cyanDeep,HH="#FF9500",qH="#FF3B30",YH="#E6EDF3",GH="#6E7681",x6={TROPHY:{glyph:"✪",color:g6},GOLD:{glyph:"★",color:g6},SILVER:{glyph:"◆",color:zH},BRONZE:{glyph:"◇",color:JH},GREEN:{glyph:"●",color:YH},YELLOW:{glyph:"●",color:HH},RED:{glyph:"○",color:qH},WHITE:{glyph:"♡",color:GH}};function v0($){return String($??"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}var h6=["who","what","why","where","when","how"];function K$($){return $.filter(([,Z])=>Z!==void 0&&Z!==null&&String(Z).trim()!=="").map(([Z,U])=>`<div class="row"><div class="k">${v0(Z)}</div><div class="v">${v0(U)}</div></div>`).join(`
143
+ `)}function y6($,Z,U="project.faf"){let X=v0($.project?.name??"Project"),Q=Z.tier?.name??"WHITE",z=x6[Q]??x6.WHITE,J=Z.inherited?Z.represents?`inherited from ${v0(Z.represents)}`:"inherited":`${Z.score}%`,H=Q==="TROPHY"&&!Z.inherited,q=$.human_context??{},Y=h6.map((V)=>[V,q[V]]),G=Object.entries(q).filter(([V])=>!h6.includes(V)),_=[["goal",$.project?.goal],["main_language",$.project?.main_language],["type",$.project?.type],["framework",$.project?.framework],["faf_version",$.faf_version]],B=Object.entries($.stack??{}),O=B.filter(([,V])=>V&&V!=="slotignored"&&String(V).trim()!==""),D=B.filter(([,V])=>V==="slotignored").length;return`<!DOCTYPE html>
144
144
  <html lang="en">
145
145
  <head>
146
146
  <meta charset="UTF-8">
@@ -152,19 +152,19 @@ ${Z.comment}`:Z.comment}this.doc.range[2]=Z.offset;break}default:this.errors.pus
152
152
  *{margin:0;padding:0;box-sizing:border-box}
153
153
  body{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,Helvetica,Arial,sans-serif;background:#0a0a0a;color:#e6edf3;line-height:1.55;padding:48px 20px}
154
154
  .wrap{max-width:880px;margin:0 auto}
155
- .bar{height:3px;border-radius:2px;background:linear-gradient(90deg,transparent,${Q.color},transparent);margin-bottom:40px}
155
+ .bar{height:3px;border-radius:2px;background:linear-gradient(90deg,transparent,${z.color},transparent);margin-bottom:40px}
156
156
  header{display:flex;align-items:baseline;gap:16px;flex-wrap:wrap;margin-bottom:8px}
157
157
  h1{font-size:2.2rem;font-weight:800;letter-spacing:-1px}
158
- .badge{font-size:1.05rem;font-weight:800;color:${Q.color};white-space:nowrap}
158
+ .badge{font-size:1.05rem;font-weight:800;color:${z.color};white-space:nowrap}
159
159
  .score{font-size:1.05rem;font-weight:700;color:#8b949e}
160
160
  .eyebrow{font-size:11px;font-weight:700;letter-spacing:2px;text-transform:uppercase;color:#6e7681;margin-bottom:36px}
161
161
  section{margin-bottom:34px}
162
- h2{font-size:12px;font-weight:700;letter-spacing:2px;text-transform:uppercase;color:${Q.color};margin-bottom:14px;padding-bottom:6px;border-bottom:1px solid rgba(255,255,255,.07)}
162
+ h2{font-size:12px;font-weight:700;letter-spacing:2px;text-transform:uppercase;color:${z.color};margin-bottom:14px;padding-bottom:6px;border-bottom:1px solid rgba(255,255,255,.07)}
163
163
  .row{display:flex;gap:18px;padding:8px 0;border-bottom:1px solid rgba(255,255,255,.04)}
164
164
  .k{flex:0 0 150px;color:#8b949e;font-size:.9rem;text-transform:capitalize}
165
165
  .v{flex:1;color:#e6edf3;font-size:.95rem;word-break:break-word}
166
166
  .meter{height:8px;border-radius:4px;background:rgba(255,255,255,.06);overflow:hidden;margin:6px 0 10px}
167
- .meter span{display:block;height:100%;background:${Q.color};width:${Math.max(0,Math.min(100,Z.score))}%}
167
+ .meter span{display:block;height:100%;background:${z.color};width:${Math.max(0,Math.min(100,Z.score))}%}
168
168
  .award{font-size:.95rem}
169
169
  .statline{margin-bottom:32px}
170
170
  .awd-pre{color:#6E7681}
@@ -181,47 +181,48 @@ footer strong{color:#e6edf3}
181
181
  <div class="eyebrow">project.faf · visual render</div>
182
182
  <header>
183
183
  <h1>${X}</h1>
184
- <span class="badge">${Q.glyph} ${y0(U)}</span>
184
+ <span class="badge">${z.glyph} ${v0(Q)}</span>
185
185
  <span class="score">${J}</span>
186
186
  </header>
187
187
  <div class="meter"><span></span></div>
188
- ${H?'<p class="award statline"><span class="awd-pre">✅ All Required slots filled.</span> <span class="awd-win">100% Trophy ✪ Awarded</span></p>':`<p class="muted statline">${Z.populated}/${Z.active} slots populated · ${Z.total} total${I?` · ${I} N/A`:""}</p>`}
188
+ ${H?'<p class="award statline"><span class="awd-pre">✅ All Required slots filled.</span> <span class="awd-win">100% Trophy ✪ Awarded</span></p>':`<p class="muted statline">${Z.populated}/${Z.active} slots populated · ${Z.total} total${D?` · ${D} N/A`:""}</p>`}
189
189
 
190
190
  <section>
191
191
  <h2>The 6 W's</h2>
192
- ${B1(_)||'<p class="muted">No human_context yet.</p>'}
193
- ${B.length?B1(B):""}
192
+ ${K$(Y)||'<p class="muted">No human_context yet.</p>'}
193
+ ${G.length?K$(G):""}
194
194
  </section>
195
195
 
196
196
  <section>
197
197
  <h2>Project</h2>
198
- ${B1(Y)||'<p class="muted">—</p>'}
198
+ ${K$(_)||'<p class="muted">—</p>'}
199
199
  </section>
200
200
 
201
201
  <section>
202
202
  <h2>Stack</h2>
203
- ${W.length?B1(W):'<p class="muted">No active stack slots.</p>'}
203
+ ${O.length?K$(O):'<p class="muted">No active stack slots.</p>'}
204
204
  </section>
205
205
 
206
206
  <footer>
207
- Rendered on-demand from your current <strong>${y0(z)}</strong><br>
207
+ Rendered on-demand from your current <strong>${v0(U)}</strong><br>
208
208
  <strong>Humans like visuals. <span style="color:#00D4D4">We gave them one.</span></strong>
209
209
  </footer>
210
210
  </div>
211
211
  </body>
212
212
  </html>
213
- `}function iJ($,Z,z,X="project.faf"){uJ(kJ($,"project.html"),P9(Z,z,X),"utf-8")}import{writeFileSync as sJ}from"fs";import{join as aJ}from"path";var T9="application/vnd.faf+yaml",rJ="https://static.modelcontextprotocol.io/schemas/v1/server-card.schema.json",nJ=/^[a-zA-Z0-9.-]+\/[a-zA-Z0-9._-]+$/;function N9($){let Z=String($.project?.name??"project").trim();if(Z.includes("/")&&nJ.test(Z))return Z;let z=$.project?.homepage??$.project?.website??$.project?.url,X="local";if(z)try{X=new URL(z).hostname.replace(/^www\./,"").split(".").reverse().join(".")}catch{}let U=Z.replace(/[^a-zA-Z0-9._-]/g,"-").replace(/^-+|-+$/g,"")||"project";return`${X}/${U}`}function oJ($){let Z=String($.project?.goal??$.context??$.project?.name??"MCP server").replace(/\s+/g," ").trim();if(!Z)return"MCP server";return Z.length<=100?Z:`${Z.slice(0,97).trimEnd()}...`}function u2($,Z={}){return{faf:Z.fafPointer??"./project.faf",mediaType:T9,iana:`https://www.iana.org/assignments/media-types/${T9}`,deterministic:!0,...Z.scoreEndpoint?{scoreEndpoint:Z.scoreEndpoint}:{},generated:$.generated??Z.now??new Date().toISOString()}}function w9($,Z={}){let z={$schema:rJ,name:N9($),version:String($.project?.version??"0.1.0"),description:oJ($)},X=$H($)??$.project?.name;if(X&&X.length<=100)z.title=X;let U=$.project?.homepage??$.project?.website??$.project?.url;if(U)z.websiteUrl=U;if(Z.remoteUrl)z.remotes=[{type:"streamable-http",url:Z.remoteUrl}];return z._meta={"one.faf/context":u2($,Z)},z}var b9="io.modelcontextprotocol.registry/publisher-provided",A9=4096;function tJ($,Z={}){let z={"one.faf/context":u2($,Z)},X=new TextEncoder().encode(JSON.stringify(z)).length;if(X>A9)throw Error(`publisher-provided _meta is ${X}B — exceeds the registry ${A9}B cap`);return{[b9]:z}}function eJ($){return N9($)}function $H($){let Z=$.project?.title;if(typeof Z==="string"){let z=Z.trim();if(z&&z.length<=100)return z}return}function ZH($,Z,z={}){let X=w9(Z,z),U=aJ($,"server-card");return sJ(U,`${JSON.stringify(X,null,2)}
214
- `,"utf-8"),U}var k2=["ephemeral","standard","high","critical"],_0=Object.fromEntries(k2.map(($,Z)=>[$,Z])),V1=new Set(["user","feedback","project","reference"]),v2=new Set(["version","profile","namepoint","created","last_etched","retention","index","memory"]),m2=new Set(["facts","sessions","preferences","custom"]),p2={low:"ephemeral",medium:"standard"};import{readFileSync as zH,writeFileSync as XH,existsSync as UH}from"fs";function h0(){return new Date().toISOString().replace(/\.\d{3}Z$/,"Z")}function x($){return $===null||$===void 0}function L$($){if(x($))return"standard";if(p2[$])return p2[$];if($ in _0)return $;return"standard"}var QH=new Set(["text","id","type","priority","tags","links","timestamp","source"]);function C9($){if(typeof $==="string")return{text:$,id:null,type:null,priority:"standard",tags:[],links:[],timestamp:null,source:null,extra:{}};if(!$||typeof $!=="object"||!("text"in $))throw Error(`fact must be a string or a mapping with 'text': ${JSON.stringify($)}`);let Z=$,z={};for(let[X,U]of Object.entries(Z))if(!QH.has(X))z[X]=U;return{text:String(Z.text),id:Z.id??null,type:Z.type??null,priority:L$(Z.priority),tags:Array.isArray(Z.tags)?Z.tags.slice():[],links:Array.isArray(Z.links)?Z.links.slice():[],timestamp:Z.timestamp??null,source:Z.source??null,extra:z}}function j9($){if(x($.id)&&x($.type)&&$.tags.length===0&&$.links.length===0&&x($.timestamp)&&x($.source)&&Object.keys($.extra).length===0&&$.priority==="standard")return $.text;let z={text:$.text};if(!x($.id))z.id=$.id;if(!x($.type))z.type=$.type;if(z.priority=$.priority,$.tags.length)z.tags=$.tags;if($.links.length)z.links=$.links;if(!x($.timestamp))z.timestamp=$.timestamp;if(!x($.source))z.source=$.source;return Object.assign(z,$.extra),z}class D0{namepoint;profile;retention;created;last_etched;_facts;_byId;_index;_sessions;_preferences;_custom;_extra;_memoryExtra;constructor($,Z={}){this.namepoint=$,this.profile=Z.profile??"knowledge",this.retention=Z.retention??"forever",this.created=Z.created??h0(),this.last_etched=this.created,this._facts=Z.facts?Z.facts.slice():[],this._byId=new Map,this._facts.forEach((z,X)=>{if(!x(z.id))this._byId.set(z.id,X)}),this._index=Z.index?Z.index.slice():[],this._sessions=Z.sessions?structuredClone(Z.sessions):[],this._preferences=Z.preferences?{...Z.preferences}:{},this._custom=Z.custom?{...Z.custom}:{},this._extra=Z.extra?{...Z.extra}:{},this._memoryExtra=Z.memoryExtra?{...Z.memoryExtra}:{}}get facts(){return this._facts}get index(){return this._index}get sessions(){return this._sessions}get preferences(){return this._preferences}get custom(){return this._custom}get extra(){return this._extra}get memoryExtra(){return this._memoryExtra}static load($){if(!UH($))throw Error(`soul file not found: ${$}`);let Z=zH($,"utf-8"),z=o(Z);if(!z||typeof z!=="object")throw Error("soul is not a YAML mapping");let X=z.memory&&typeof z.memory==="object"?z.memory:{},U=Array.isArray(X.facts)?X.facts:[],Q={};for(let[G,_]of Object.entries(z))if(!v2.has(G))Q[G]=structuredClone(_);let J={};for(let[G,_]of Object.entries(X))if(!m2.has(G))J[G]=structuredClone(_);let H=new D0(String(z.namepoint??$.replace(/.*\//,"").replace(/\.fafm$/,"")),{profile:String(z.profile??"voice"),facts:U.map(C9),retention:String(z.retention??"forever"),created:z.created??null,index:Array.isArray(z.index)?z.index.slice():[],sessions:Array.isArray(X.sessions)?structuredClone(X.sessions):[],preferences:X.preferences&&typeof X.preferences==="object"?structuredClone(X.preferences):{},custom:X.custom&&typeof X.custom==="object"?structuredClone(X.custom):{},extra:Q,memoryExtra:J});return H.last_etched=String(z.last_etched??H.created),H}static fromFile($){return D0.load($)}toDoc(){let $={facts:this._facts.map(j9),sessions:structuredClone(this._sessions),preferences:structuredClone(this._preferences),custom:structuredClone(this._custom)};for(let[z,X]of Object.entries(this._memoryExtra))if(!m2.has(z))$[z]=structuredClone(X);let Z={version:"1.1",profile:this.profile,namepoint:this.namepoint,created:this.created,last_etched:this.last_etched,retention:this.retention,index:this._index.slice(),memory:$};for(let[z,X]of Object.entries(this._extra))if(!v2.has(z))Z[z]=structuredClone(X);return Z}toYaml(){return q1(this.toDoc(),{lineWidth:100})}rebuildIndex($=80){return this._index=this._facts.map((Z)=>`${Z.id??"?"} — ${Z.text.slice(0,$)}`),this._index}save($,Z={}){if(Z.reindex!==!1)this.rebuildIndex();return XH($,this.toYaml(),"utf-8"),$}toFile($,Z={}){return this.save($,Z)}add($){if(!x($.id)&&this._byId.has($.id)){let Z=this._byId.get($.id);if(Z!==void 0)this._facts[Z]=$}else if(this._facts.push($),!x($.id))this._byId.set($.id,this._facts.length-1);if($.timestamp&&$.timestamp>(this.last_etched||""))this.last_etched=$.timestamp;return $}etch($,Z={}){return this.add({text:$,id:Z.id??null,type:Z.type??null,priority:L$(Z.priority),tags:Z.tags?Z.tags.slice():[],links:Z.links?Z.links.slice():[],timestamp:h0(),source:Z.source??null,extra:{}})}recall($,Z={}){let z=_0[L$(Z.minPriority??"ephemeral")]??0,X=($??"").toLowerCase(),U=new Set(Z.tags??[]),Q=[];this._facts.forEach((H,G)=>{if(X&&!H.text.toLowerCase().includes(X))return;if(U.size>0&&![...U].some((_)=>H.tags.includes(_)))return;if(!x(Z.type)&&H.type!==Z.type)return;if((_0[H.priority]??1)<z)return;Q.push([G,H])}),Q.sort((H,G)=>{let _=_0[H[1].priority]??1,B=_0[G[1].priority]??1;if(B!==_)return B-_;let Y=H[1].timestamp??"",q=G[1].timestamp??"";if(q!==Y)return q<Y?-1:q>Y?1:0;return G[0]-H[0]});let J=Q.map(([,H])=>H);if(!x(Z.limit))return J.slice(0,Z.limit);return J}getFact($){let Z=this._byId.get($);return Z===void 0?null:this._facts[Z]}deleteFact($){let Z=this._byId.get($);if(Z===void 0)return!1;return this._facts.splice(Z,1),this._byId.clear(),this._facts.forEach((z,X)=>{if(!x(z.id))this._byId.set(z.id,X)}),!0}}import{readdirSync as JH,readFileSync as HH,statSync as S9,existsSync as GH}from"fs";import{join as _H,basename as E9,resolve as YH}from"path";var g9=new Set(["MEMORY.md","MEMORY-FULL.md","README.md"]),qH=/\[\[([^\]]+)\]\]/g;function BH($){let Z=S9($).mtimeMs;return new Date(Z).toISOString().replace(/\.\d{3}Z$/,"Z")}function VH($){if(!$.startsWith("---"))return{fm:null,body:$};let Z=$.split("---");if(Z.length<3)return{fm:null,body:$};try{let z=o(Z[1]);if(!z||typeof z!=="object")return{fm:null,body:Z.slice(2).join("---").trim()};return{fm:z,body:Z.slice(2).join("---").trim()}}catch{return{fm:null,body:$}}}function OH($,Z,z){if(!z.name)return null;let X=z.metadata&&typeof z.metadata==="object"?z.metadata:{},U=X.type;if(typeof U!=="string"||!V1.has(U))return null;let Q=String(z.name).trim(),H=(z.description!==void 0&&z.description!==null&&String(z.description).trim()?String(z.description).trim():"")||Q,G={};if(X.originSessionId)G.provenance=[`session:${X.originSessionId}`];let _=[...new Set([...Z.matchAll(qH)].map((B)=>B[1]))].sort();return{text:H,id:Q,type:U,priority:"standard",tags:[],links:_,timestamp:BH($),source:`claude-code memory: ${E9($)}`,extra:G}}function f9($,Z={}){let z=YH($);if(!GH(z))throw Error(`Claude memory directory not found: ${z}`);if(!S9(z).isDirectory())throw Error(`Claude memory path is not a directory: ${z}`);let X=Z.skip??g9,U=Z.namepoint??`@claude-code:${E9(z)}`,Q=[],J=JH(z).filter((Y)=>Y.endsWith(".md")).sort();for(let Y of J){if(X.has(Y))continue;let q=_H(z,Y),W;try{W=HH(q,"utf-8")}catch{continue}let{fm:I,body:V}=VH(W);if(!I)continue;let O=OH(q,V,I);if(O)Q.push(O)}let H=Q.map((Y)=>Y.timestamp).filter(Boolean),G=H.length?H.reduce((Y,q)=>Y<q?Y:q):h0(),_=H.length?H.reduce((Y,q)=>Y>q?Y:q):G,B=new D0(U,{profile:"knowledge",facts:Q,created:G});return B.last_etched=_,B.rebuildIndex(),B}var k9="faf-interview/1",x0="(terse — 3-4 words)",l2=[{path:"project.name",question:"What is the name of this project?",header:"Name",type:"text",required:!0},{path:"project.goal",question:"What does this project do? (one sentence)",header:"Goal",type:"text",required:!0},{path:"human_context.who",question:`Who is this for? ${x0}`,header:"Who",type:"text",required:!0},{path:"human_context.what",question:`What are they building? ${x0}`,header:"What",type:"text",required:!0},{path:"human_context.why",question:`Why does it exist? ${x0}`,header:"Why",type:"text",required:!0},{path:"human_context.where",question:`Where does it run or ship? ${x0}`,header:"Where",type:"text",required:!0},{path:"human_context.when",question:`When — timeline or stage? ${x0}`,header:"When",type:"text",required:!0},{path:"human_context.how",question:`How is it built or used? ${x0}`,header:"How",type:"text",required:!0}],v9=[{path:"project.main_language",question:"What is the primary programming language?",header:"Language",type:"select",required:!0,options:[{label:"TypeScript",value:"TypeScript",description:"JavaScript with types"},{label:"JavaScript",value:"JavaScript",description:"Vanilla JS or Node.js"},{label:"Python",value:"Python",description:"Python 3.x"},{label:"Rust",value:"Rust",description:"Systems programming"},{label:"Go",value:"Go",description:"Golang"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.frontend",question:"What frontend framework does it use?",header:"Frontend",type:"select",required:!1,options:[{label:"React",value:"React",description:"React.js"},{label:"Vue",value:"Vue",description:"Vue.js"},{label:"Svelte",value:"Svelte",description:"Svelte/SvelteKit"},{label:"Next.js",value:"Next.js",description:"React framework"},{label:"None",value:"None",description:"No frontend"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.backend",question:"What backend framework does it use?",header:"Backend",type:"select",required:!1,options:[{label:"Express",value:"Express",description:"Node.js Express"},{label:"Fastify",value:"Fastify",description:"Node.js Fastify"},{label:"Django",value:"Django",description:"Python Django"},{label:"FastAPI",value:"FastAPI",description:"Python FastAPI"},{label:"None",value:"None",description:"No backend"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.database",question:"What database does it use?",header:"Database",type:"select",required:!1,options:[{label:"PostgreSQL",value:"PostgreSQL",description:"Postgres"},{label:"MySQL",value:"MySQL",description:"MySQL/MariaDB"},{label:"SQLite",value:"SQLite",description:"Embedded SQL"},{label:"MongoDB",value:"MongoDB",description:"Document store"},{label:"None",value:"None",description:"No database"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.runtime",question:"What runtime does it run on?",header:"Runtime",type:"text",required:!1},{path:"stack.hosting",question:"Where is it hosted or distributed?",header:"Hosting",type:"text",required:!1},{path:"stack.build",question:"What is the build tool?",header:"Build",type:"text",required:!1},{path:"stack.cicd",question:"What CI/CD does it use?",header:"CI/CD",type:"text",required:!1}],u0=[...l2,...v9],m9=new Map(u0.map(($)=>[$.path,$])),WH=Object.fromEntries(u0.map(($)=>[$.path,$]));function d2($){let Z=m9.get($);if(Z)return Z.question;let z=l0.get($)??y.find((X)=>X.canonical===$);return z?`${z.description}?`.replace(/\?\?$/,"?"):`${$}?`}function IH($,Z){return u0.filter((z)=>{let X=z.path.split("."),U=$;for(let Q of X)if(U&&typeof U==="object"&&Q in U)U=U[Q];else{U=void 0;break}if(U==="slotignored")return!1;return Z(U)})}var LH=new Set(["developers","development teams","development team","teams","development","cloud platform","web platform","platform","best practices","improve development efficiency","development efficiency","modern development practices","modern development","test-driven development","production/stable","production","stable","app","project","tool"]),DH=[["npm",/\bnpm\b/i],["PyPI",/\bpypi\b/i],["crates.io",/\bcrates\.io\b/i],["Homebrew",/\bhomebrew\b/i],["Docker",/\bdocker\b/i],["Cloudflare",/\bcloudflare\b/i],["Vercel",/\bvercel\b/i],["Netlify",/\bnetlify\b/i],["AWS",/\baws\b/i],["Cloud Run",/\bcloud run\b/i],["edge",/\bedge\b/i],["browser",/\bbrowser\b/i],["WASM",/\bwasm\b/i],["GitHub",/\bgithub\b/i],["MCP Registry",/\bmcp registry\b/i],["Chrome Web Store",/\bchrome web store\b/i],["Smithery",/\bsmithery\b/i]],y9=($)=>LH.has($.toLowerCase().trim()),RH=/^(?:with|and|or|using|for|to|that|who|whom|whose|the|a|an|in|on|of|via|by|&)$/i;function h9($,Z=5){let z=$.trim().split(/\s+/).filter(Boolean).slice(0,Z);while(z.length&&RH.test(z[z.length-1].replace(/[.,;:]+$/,"")))z.pop();return z.join(" ")}function p9($){let Z={};if(!$||typeof $!=="string")return Z;let z=$.trim(),X=z.replace(/^[^A-Za-z0-9]+/,"").split(/\s+(?:for|that|which|to)\s+|\s+[—–]\s+|\s-\s|:\s|\.\s|,\s/)[0].trim(),U=h9(X);if(U.split(/\s+/).filter(Boolean).length>=2&&!y9(U))Z.what=U;let Q=DH.filter(([,G])=>G.test(z)).map(([G])=>G);if(Q.length)Z.where=Q.slice(0,4).join(", ");let J=z.match(/\bfor ((?:[A-Za-z][\w./+-]* )?(?:any |all )?(?:developers?|teams?|engineers?|builders?|users?|integrators?)\b[^.,;:—]*)/i),H=h9((J?.[1]||"").trim().replace(/\s+/g," "));if(H&&!y9(H))Z.who=H;return Z}function x9($,Z){let z=$;for(let X of Z.split("."))if(z&&typeof z==="object"&&X in z)z=z[X];else return;return z}function u9($){if(typeof $!=="string")return!1;let Z=$.trim();if(!Z||Z==="slotignored")return!1;return!Y0(Z)}function FH($,Z={}){let z=$&&typeof $==="object"?$:{},X=x9(z,"project.goal"),U=(u9(X)?String(X).trim():"")||(Z.goal??"").trim(),Q=p9(U),J=Z.detailed??{},H={"project.goal":U||void 0,"human_context.what":Q.what,"human_context.where":Q.where,"human_context.who":Q.who},G=(W)=>{let I=H[W];if(I)return{value:I,source:"project goal",confidence:0.9};let V=W.startsWith("human_context.")?W.slice(14):"",O=V?J[V]:void 0;return O?{value:O.value,source:O.source,confidence:O.confidence}:void 0},_=l2.map((W,I)=>{let V={n:I+1,path:W.path,header:W.header,question:W.question},O=x9(z,W.path);if(u9(O))return{...V,value:String(O).trim(),status:"filled",seeded:!1};let L=G(W.path);if(L)return{...V,value:L.value,status:"seeded",seeded:!0,source:L.source,confidence:L.confidence};return{...V,value:"",status:"empty",seeded:!1}}),B=_.filter((W)=>W.status==="filled").length,Y=_.filter((W)=>W.status==="seeded").length,q=_.filter((W)=>W.status==="empty").length;return{version:k9,rows:_,filledCount:B,seededCount:Y,emptyCount:q,complete:q===0}}function O1($){if($===null||$===void 0)return!0;if(typeof $==="string"){let Z=$.trim();return Z===""||Y0(Z)}return!1}function MH($,Z){let z=$;for(let X of Z.split("."))if(z&&typeof z==="object"&&X in z)z=z[X];else return;return z}function l9($){if($==="project.goal")return!0;return l0.get($)?.category==="human"}function d9($,Z=O1){let z=[],X=[];for(let U of u0){let Q=MH($,U.path);if(Q==="slotignored")continue;if(!Z(Q))continue;(l9(U.path)?z:X).push(U.path)}return{human:z,sourceable:X}}function c9($,Z,z=O1){let X=d9(Z,z),U;if($>=100||X.human.length===0&&X.sourceable.length===0)U="done";else if(X.sourceable.length>0)U="can-source";else U="needs-human";let Q=U==="needs-human"?c2(X):[];return{status:U,score:$,gaps:X,ask:Q}}function c2($){return $.human.map((Z)=>({path:Z,question:d2(Z)}))}function KH($,Z={}){let z=Math.max(1,Z.maxRounds??5),X=Z.isEmpty??O1,U=[],Q=0;for(let H=0;H<=z;H++){let G=$.read();if(!G)return{status:"no-faf",score:0,rounds:Q,history:U,ask:[]};let _=$.score(G.yaml);U.push(_);let B=c9(_,G.data,X);if(B.status==="done")return{status:"done",score:_,rounds:Q,history:U,ask:[]};if(B.status==="needs-human")return{status:"needs-human",score:_,rounds:Q,history:U,ask:B.ask};if(U.length>=2&&_<=U[U.length-2])return B.gaps.human.length?{status:"needs-human",score:_,rounds:Q,history:U,ask:c2(B.gaps)}:{status:"stuck",score:_,rounds:Q,history:U,ask:[]};if(Q>=z)return{status:"capped",score:_,rounds:Q,history:U,ask:c2(B.gaps)};$.runAuto(),Q++}return{status:"capped",score:U[U.length-1]??0,rounds:Q,history:U,ask:[]}}import{createHash as s9}from"crypto";var i2="faf-bench/1",PH={"project.name":"What is the project's name?","project.goal":"What is the project's goal — what is it for?","project.main_language":"What is the primary programming language?","human_context.who":"Who is this project for?","human_context.what":"What are they building?","human_context.why":"Why does this project exist?","human_context.where":"Where does it run or get distributed?","human_context.when":"When — what is the project's timeline or stage?","human_context.how":"How is it built or used?"};function TH($,Z){return PH[$]??`What is the project's ${Z.replace(/\s*\(.*\)$/,"").toLowerCase()}?`}var a9=[["typescript","ts"],["javascript","js"],["python","py","python3"],["node","nodejs","node js","node.js"],["github actions","gh actions","actions"],["postgresql","postgres","pg"],["kubernetes","k8s"],["npm","npm registry"],["cloudflare workers","cf workers","workers"],["google cloud run","cloud run","gcp cloud run"]],D$=new Map;a9.forEach(($,Z)=>$.forEach((z)=>D$.set(z,Z)));var AH=new Set(["a","an","the","and","or","of","for","to","in","on","with","is","it","its","their","your","via","by","using","use","used"]);function W1($){return $.toLowerCase().replace(/[^a-z0-9\s.+#-]/g," ").replace(/\.(?=\s|$)/g," ").replace(/\s+/g," ").trim()}function i9($){return W1($).split(" ").filter((Z)=>Z&&!AH.has(Z))}function r9($,Z){let z=W1($),X=W1(Z);if(!z||!X)return!1;if(z===X)return!0;let U=D$.get(z);if(U!==void 0&&D$.get(X)===U)return!0;let Q=i9($);if(Q.length===0)return!1;let J=new Set(i9(Z));return Q.every((H)=>{if(J.has(H))return!0;let G=D$.get(H);return G!==void 0&&[...J].some((_)=>D$.get(_)===G)})}function NH($){let Z=N1($),z=o($),X=[],U={},Q=0;for(let G of y){if(Z.slots[G.path]!=="populated")continue;let _=Q3(z,G);if(typeof _!=="string")continue;let B=_.trim();if(!B||M$.has(B.toLowerCase()))continue;Q+=1,X.push({n:Q,path:G.path,question:TH(G.path,G.description)}),U[Q]=B}let J=JSON.stringify({v:i2,q:X.map((G)=>[G.path,G.question])}),H=s9("sha256").update(J).digest("hex").slice(0,12);return{version:i2,qsetHash:H,questions:X,answers:U}}function wH($){return{version:$.version,qsetHash:$.qsetHash,questions:$.questions}}function bH($,Z){let z=$.questions.map((U)=>{let Q=Z[String(U.n)]??Z[U.path]??"";return{n:U.n,path:U.path,ok:typeof Q==="string"&&Q.trim()!==""&&r9($.answers[U.n],Q)}}),X=$.questions.filter((U)=>!z[U.n-1].ok);return{correct:z.filter((U)=>U.ok).length,total:$.questions.length,misses:X,perQuestion:z}}function CH($,Z){let z=JSON.stringify({v:$.version,repo:Z??null,qset:$.qsetHash,protocol:$.protocol,cold:$.cold??null,faf:$.faf??null});return{projection:z,hash:s9("sha256").update(z).digest("hex")}}import{existsSync as rH,readdirSync as Z6,readFileSync as nH}from"fs";import{join as n2,dirname as oH,extname as tH,resolve as eH}from"path";var s2={"package.json":{frameworks:["Node.js","JavaScript","TypeScript"],slots:{packageManager:"npm/yarn/pnpm",mainLanguage:"JavaScript/TypeScript"},priority:35,intelligence:"ultra-high"},"README.md":{frameworks:[],slots:{targetUser:"developers",coreProblem:"understanding project",missionPurpose:"project documentation"},priority:25,intelligence:"high"},"requirements.txt":{frameworks:["Python"],slots:{packageManager:"pip",mainLanguage:"Python"},priority:35,intelligence:"ultra-high"},Pipfile:{frameworks:["Python"],slots:{packageManager:"pipenv",mainLanguage:"Python"},priority:35,intelligence:"ultra-high"},"pyproject.toml":{frameworks:["Python"],slots:{mainLanguage:"Python",runtime:"Python",backend:"Python"},priority:36,intelligence:"ultra-high"},Gemfile:{frameworks:["Ruby","Rails"],slots:{packageManager:"bundler",mainLanguage:"Ruby"},priority:35,intelligence:"ultra-high"},"composer.json":{frameworks:["PHP","Laravel","Symfony"],slots:{packageManager:"composer",mainLanguage:"PHP"},priority:35,intelligence:"ultra-high"},"Cargo.toml":{frameworks:["Rust"],slots:{packageManager:"cargo",mainLanguage:"Rust",buildTool:"cargo"},priority:36,intelligence:"ultra-high"},"go.mod":{frameworks:["Go"],slots:{packageManager:"go modules",mainLanguage:"Go",buildTool:"go build"},priority:36,intelligence:"ultra-high"},"pubspec.yaml":{frameworks:["Dart"],slots:{packageManager:"pub",mainLanguage:"Dart"},priority:35,intelligence:"ultra-high"},"pom.xml":{frameworks:["Java","Spring","Maven"],slots:{packageManager:"maven",mainLanguage:"Java",buildTool:"maven"},priority:35,intelligence:"ultra-high"},"build.gradle":{frameworks:["Java","Kotlin","Spring","Gradle"],slots:{packageManager:"gradle",mainLanguage:"Java/Kotlin",buildTool:"gradle"},priority:35,intelligence:"ultra-high"},"next.config.js":{frameworks:["Next.js"],slots:{framework:"Next.js",runtime:"Node.js",buildTool:"Next.js",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"next.config.mjs":{frameworks:["Next.js"],slots:{framework:"Next.js",runtime:"Node.js",buildTool:"Next.js",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"next.config.ts":{frameworks:["Next.js 13+"],slots:{framework:"Next.js 13+",runtime:"Node.js",buildTool:"Next.js",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"nuxt.config.js":{frameworks:["Nuxt 2"],slots:{framework:"Nuxt 2",runtime:"Node.js",buildTool:"Nuxt",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"nuxt.config.ts":{frameworks:["Nuxt 3"],slots:{framework:"Nuxt 3",runtime:"Node.js",buildTool:"Nuxt",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"svelte.config.js":{frameworks:["SvelteKit"],slots:{framework:"SvelteKit",buildTool:"Vite",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"angular.json":{frameworks:["Angular"],slots:{framework:"Angular",buildTool:"Angular CLI",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"manifest.json":{frameworks:["Chrome Extension","Browser Extension"],slots:{framework:"Chrome Extension",runtime:"Chrome/Browser",mainLanguage:"JavaScript",hosting:"Chrome Web Store",apiType:"Chrome APIs"},priority:35,intelligence:"ultra-high",confirmWith:["popup.html","background.js","content.js"]},"vue.config.js":{frameworks:["Vue"],slots:{framework:"Vue",buildTool:"Vue CLI",mainLanguage:"JavaScript"},priority:30,intelligence:"high"},"remix.config.js":{frameworks:["Remix"],slots:{framework:"Remix",runtime:"Node.js",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"gatsby-config.js":{frameworks:["Gatsby"],slots:{framework:"Gatsby",buildTool:"Gatsby",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"gatsby-config.ts":{frameworks:["Gatsby"],slots:{framework:"Gatsby",buildTool:"Gatsby",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"astro.config.mjs":{frameworks:["Astro"],slots:{framework:"Astro",buildTool:"Vite",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"redwood.toml":{frameworks:["RedwoodJS"],slots:{framework:"RedwoodJS",buildTool:"Webpack",mainLanguage:"JavaScript/TypeScript",server:"Node.js",database:"Prisma"},priority:30,intelligence:"high"},"blitz.config.ts":{frameworks:["Blitz.js"],slots:{framework:"Blitz.js",buildTool:"Next.js",mainLanguage:"TypeScript",server:"Node.js",database:"Prisma"},priority:30,intelligence:"high"},"qwik.config.ts":{frameworks:["Qwik"],slots:{framework:"Qwik",buildTool:"Vite",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"manage.py":{frameworks:["Django"],slots:{framework:"Django",backend:"Django",mainLanguage:"Python",server:"Django",apiType:"Django Views"},priority:30,intelligence:"high"},artisan:{frameworks:["Laravel"],slots:{framework:"Laravel",backend:"Laravel",mainLanguage:"PHP",server:"PHP",apiType:"Laravel Routes"},priority:30,intelligence:"high"},"mix.exs":{frameworks:["Phoenix","Elixir"],slots:{framework:"Phoenix",backend:"Phoenix",mainLanguage:"Elixir",server:"BEAM"},priority:30,intelligence:"high"},"nest-cli.json":{frameworks:["NestJS"],slots:{framework:"NestJS",backend:"NestJS",mainLanguage:"TypeScript",server:"Node.js",apiType:"REST API"},priority:30,intelligence:"high"},"strapi.config.js":{frameworks:["Strapi"],slots:{backend:"Strapi",apiType:"REST API",database:"Required",server:"Node.js"},priority:30,intelligence:"high"},Dockerfile:{frameworks:["Docker"],slots:{hosting:"Docker",connection:"Containerized"},priority:30,intelligence:"high"},"docker-compose.yml":{frameworks:["Docker Compose"],slots:{hosting:"Docker",connection:"Multi-container"},priority:30,intelligence:"high"},"docker-compose.yaml":{frameworks:["Docker Compose"],slots:{hosting:"Docker",connection:"Multi-container"},priority:30,intelligence:"high"},"kubernetes.yml":{frameworks:["Kubernetes"],slots:{hosting:"Kubernetes",connection:"Orchestrated"},priority:30,intelligence:"high"},"k8s.yaml":{frameworks:["Kubernetes"],slots:{hosting:"Kubernetes",connection:"Orchestrated"},priority:30,intelligence:"high"},"vercel.json":{frameworks:["Vercel"],slots:{hosting:"Vercel",cicd:"Vercel"},priority:30,intelligence:"high"},"netlify.toml":{frameworks:["Netlify"],slots:{hosting:"Netlify",cicd:"Netlify"},priority:30,intelligence:"high"},"render.yaml":{frameworks:["Render"],slots:{hosting:"Render",cicd:"Render"},priority:30,intelligence:"high"},"fly.toml":{frameworks:["Fly.io"],slots:{hosting:"Fly.io",cicd:"Fly.io"},priority:30,intelligence:"high"},"railway.json":{frameworks:["Railway"],slots:{hosting:"Railway",cicd:"Railway"},priority:30,intelligence:"high"},"railway.toml":{frameworks:["Railway"],slots:{hosting:"Railway",cicd:"Railway"},priority:30,intelligence:"high"},"app.yaml":{frameworks:["Google App Engine"],slots:{hosting:"Google Cloud",cicd:"Google Cloud"},priority:30,intelligence:"high"},Procfile:{frameworks:["Heroku"],slots:{hosting:"Heroku",cicd:"Heroku"},priority:30,intelligence:"high"},"vite.config.js":{frameworks:["Vite"],slots:{buildTool:"Vite"},priority:25,intelligence:"medium"},"vite.config.ts":{frameworks:["Vite"],slots:{buildTool:"Vite",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"webpack.config.js":{frameworks:["Webpack"],slots:{buildTool:"Webpack"},priority:25,intelligence:"medium"},"rollup.config.js":{frameworks:["Rollup"],slots:{buildTool:"Rollup"},priority:25,intelligence:"medium"},"esbuild.config.js":{frameworks:["esbuild"],slots:{buildTool:"esbuild"},priority:25,intelligence:"medium"},"parcel.config.js":{frameworks:["Parcel"],slots:{buildTool:"Parcel"},priority:25,intelligence:"medium"},"snowpack.config.js":{frameworks:["Snowpack"],slots:{buildTool:"Snowpack"},priority:25,intelligence:"medium"},"tsconfig.json":{frameworks:["TypeScript"],slots:{mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"jsconfig.json":{frameworks:["JavaScript"],slots:{mainLanguage:"JavaScript"},priority:20,intelligence:"medium"},"babel.config.js":{frameworks:["Babel"],slots:{buildTool:"Babel"},priority:20,intelligence:"medium"},".babelrc":{frameworks:["Babel"],slots:{buildTool:"Babel"},priority:20,intelligence:"medium"},"jest.config.js":{frameworks:["Jest"],slots:{cicd:"Jest"},priority:25,intelligence:"medium"},"jest.config.ts":{frameworks:["Jest"],slots:{cicd:"Jest",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"vitest.config.ts":{frameworks:["Vitest"],slots:{cicd:"Vitest",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"cypress.config.js":{frameworks:["Cypress"],slots:{cicd:"Cypress"},priority:25,intelligence:"medium"},"playwright.config.ts":{frameworks:["Playwright"],slots:{cicd:"Playwright",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"karma.conf.js":{frameworks:["Karma"],slots:{cicd:"Karma"},priority:20,intelligence:"medium"},"mocha.opts":{frameworks:["Mocha"],slots:{cicd:"Mocha"},priority:20,intelligence:"medium"},".rspec":{frameworks:["RSpec"],slots:{cicd:"RSpec",mainLanguage:"Ruby"},priority:25,intelligence:"medium"},"pytest.ini":{frameworks:["Pytest"],slots:{cicd:"Pytest",mainLanguage:"Python"},priority:25,intelligence:"medium"},"phpunit.xml":{frameworks:["PHPUnit"],slots:{cicd:"PHPUnit",mainLanguage:"PHP"},priority:25,intelligence:"medium"},"schema.prisma":{frameworks:["Prisma"],slots:{database:"Prisma ORM",connection:"Prisma"},priority:25,intelligence:"medium"},"drizzle.config.ts":{frameworks:["Drizzle"],slots:{database:"Drizzle ORM",connection:"Drizzle",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"ormconfig.js":{frameworks:["TypeORM"],slots:{database:"TypeORM",connection:"TypeORM"},priority:25,intelligence:"medium"},"knexfile.js":{frameworks:["Knex.js"],slots:{database:"Knex.js",connection:"Knex.js"},priority:25,intelligence:"medium"},"sequelize.config.js":{frameworks:["Sequelize"],slots:{database:"Sequelize",connection:"Sequelize"},priority:25,intelligence:"medium"},"alembic.ini":{frameworks:["Alembic"],slots:{database:"Alembic",mainLanguage:"Python"},priority:25,intelligence:"medium"},".github/workflows":{frameworks:["GitHub Actions"],slots:{cicd:"GitHub Actions"},priority:25,intelligence:"medium"},".gitlab-ci.yml":{frameworks:["GitLab CI"],slots:{cicd:"GitLab CI"},priority:25,intelligence:"medium"},Jenkinsfile:{frameworks:["Jenkins"],slots:{cicd:"Jenkins"},priority:25,intelligence:"medium"},".circleci/config.yml":{frameworks:["CircleCI"],slots:{cicd:"CircleCI"},priority:25,intelligence:"medium"},".travis.yml":{frameworks:["Travis CI"],slots:{cicd:"Travis CI"},priority:25,intelligence:"medium"},"azure-pipelines.yml":{frameworks:["Azure DevOps"],slots:{cicd:"Azure DevOps"},priority:25,intelligence:"medium"},"bitbucket-pipelines.yml":{frameworks:["Bitbucket Pipelines"],slots:{cicd:"Bitbucket Pipelines"},priority:25,intelligence:"medium"},"tailwind.config.js":{frameworks:["Tailwind CSS"],slots:{cssFramework:"Tailwind CSS"},priority:20,intelligence:"medium"},"tailwind.config.ts":{frameworks:["Tailwind CSS"],slots:{cssFramework:"Tailwind CSS",mainLanguage:"TypeScript"},priority:20,intelligence:"medium"},"postcss.config.js":{frameworks:["PostCSS"],slots:{cssFramework:"PostCSS"},priority:20,intelligence:"medium"},"uno.config.ts":{frameworks:["UnoCSS"],slots:{cssFramework:"UnoCSS",mainLanguage:"TypeScript"},priority:20,intelligence:"medium"},"styled-components.config.js":{frameworks:["styled-components"],slots:{cssFramework:"styled-components",uiLibrary:"styled-components"},priority:20,intelligence:"medium"},"emotion.config.js":{frameworks:["Emotion"],slots:{cssFramework:"Emotion",uiLibrary:"Emotion"},priority:20,intelligence:"medium"},"metro.config.js":{frameworks:["React Native"],slots:{framework:"React Native",mainLanguage:"JavaScript"},priority:25,intelligence:"medium"},"expo.config.js":{frameworks:["Expo"],slots:{framework:"React Native",buildTool:"Expo"},priority:25,intelligence:"medium"},"app.json":{frameworks:["React Native","Expo"],slots:{framework:"React Native"},priority:20,intelligence:"medium",confirmWith:["expo"]},"capacitor.config.ts":{frameworks:["Capacitor"],slots:{framework:"Capacitor",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"ionic.config.json":{frameworks:["Ionic"],slots:{framework:"Ionic",uiLibrary:"Ionic"},priority:25,intelligence:"medium"},"nx.json":{frameworks:["Nx"],slots:{buildTool:"Nx"},priority:25,intelligence:"medium"},"turbo.json":{frameworks:["Turborepo"],slots:{buildTool:"Turborepo"},priority:25,intelligence:"medium"},"lerna.json":{frameworks:["Lerna"],slots:{buildTool:"Lerna"},priority:25,intelligence:"medium"},"rush.json":{frameworks:["Rush"],slots:{buildTool:"Rush"},priority:25,intelligence:"medium"},"pnpm-workspace.yaml":{frameworks:["pnpm workspaces"],slots:{packageManager:"pnpm",buildTool:"pnpm workspaces"},priority:25,intelligence:"medium"},"*.svelte":{frameworks:["Svelte","SvelteKit"],slots:{framework:"Svelte"},priority:15,intelligence:"low"},"*.vue":{frameworks:["Vue"],slots:{framework:"Vue"},priority:15,intelligence:"low"},"*.jsx":{frameworks:["React"],slots:{framework:"React",mainLanguage:"JavaScript"},priority:15,intelligence:"low"},"*.ts":{frameworks:["TypeScript"],slots:{mainLanguage:"TypeScript"},priority:15,intelligence:"low"},"*.tsx":{frameworks:["React","TypeScript"],slots:{framework:"React",mainLanguage:"TypeScript"},priority:15,intelligence:"low"},"*.py":{frameworks:["Python"],slots:{mainLanguage:"Python"},priority:15,intelligence:"low"},"*.rb":{frameworks:["Ruby"],slots:{mainLanguage:"Ruby"},priority:15,intelligence:"low"},"*.php":{frameworks:["PHP"],slots:{mainLanguage:"PHP"},priority:15,intelligence:"low"},"*.java":{frameworks:["Java"],slots:{mainLanguage:"Java"},priority:15,intelligence:"low"},"*.kt":{frameworks:["Kotlin"],slots:{mainLanguage:"Kotlin"},priority:15,intelligence:"low"},"*.swift":{frameworks:["Swift"],slots:{mainLanguage:"Swift"},priority:15,intelligence:"low"},"*.go":{frameworks:["Go"],slots:{mainLanguage:"Go"},priority:15,intelligence:"low"},"*.rs":{frameworks:["Rust"],slots:{mainLanguage:"Rust"},priority:15,intelligence:"low"},"*.dart":{frameworks:["Flutter","Dart"],slots:{mainLanguage:"Dart"},priority:15,intelligence:"low"},"*.ex":{frameworks:["Elixir"],slots:{mainLanguage:"Elixir"},priority:15,intelligence:"low"},"*.exs":{frameworks:["Elixir"],slots:{mainLanguage:"Elixir"},priority:15,intelligence:"low"},"*.scala":{frameworks:["Scala"],slots:{mainLanguage:"Scala"},priority:15,intelligence:"low"},"*.clj":{frameworks:["Clojure"],slots:{mainLanguage:"Clojure"},priority:15,intelligence:"low"},"*.lua":{frameworks:["Lua"],slots:{mainLanguage:"Lua"},priority:15,intelligence:"low"},"*.r":{frameworks:["R"],slots:{mainLanguage:"R"},priority:15,intelligence:"low"},"*.R":{frameworks:["R"],slots:{mainLanguage:"R"},priority:15,intelligence:"low"},"*.jl":{frameworks:["Julia"],slots:{mainLanguage:"Julia"},priority:15,intelligence:"low"},"*.nim":{frameworks:["Nim"],slots:{mainLanguage:"Nim"},priority:15,intelligence:"low"},"*.zig":{frameworks:["Zig"],slots:{mainLanguage:"Zig"},priority:15,intelligence:"low"},"build.zig":{frameworks:["Zig"],slots:{packageManager:"Zig Package Manager",mainLanguage:"Zig",buildTool:"zig build",framework:"Zig",build:"zig build"},priority:35,intelligence:"ultra-high"},"openapi.json":{frameworks:["OpenAPI"],slots:{apiType:"REST API",backend:"API Server"},priority:30,intelligence:"high"},"openapi.yaml":{frameworks:["OpenAPI"],slots:{apiType:"REST API",backend:"API Server"},priority:30,intelligence:"high"},"swagger.json":{frameworks:["Swagger"],slots:{apiType:"REST API",backend:"API Server"},priority:30,intelligence:"high"},"graphql.schema":{frameworks:["GraphQL"],slots:{apiType:"GraphQL",backend:"GraphQL Server"},priority:30,intelligence:"high"},"schema.graphql":{frameworks:["GraphQL"],slots:{apiType:"GraphQL",backend:"GraphQL Server"},priority:30,intelligence:"high"},".graphqlconfig":{frameworks:["GraphQL"],slots:{apiType:"GraphQL"},priority:25,intelligence:"medium"},"redux.config.js":{frameworks:["Redux"],slots:{stateManagement:"Redux"},priority:20,intelligence:"medium"},"mobx.config.js":{frameworks:["MobX"],slots:{stateManagement:"MobX"},priority:20,intelligence:"medium"},"vuex.config.js":{frameworks:["Vuex"],slots:{stateManagement:"Vuex",framework:"Vue"},priority:20,intelligence:"medium"},"pinia.config.js":{frameworks:["Pinia"],slots:{stateManagement:"Pinia",framework:"Vue"},priority:20,intelligence:"medium"},"zustand.config.js":{frameworks:["Zustand"],slots:{stateManagement:"Zustand"},priority:20,intelligence:"medium"},".eslintrc.js":{frameworks:["ESLint"],slots:{},priority:15,intelligence:"low"},".eslintrc.json":{frameworks:["ESLint"],slots:{},priority:15,intelligence:"low"},".prettierrc":{frameworks:["Prettier"],slots:{},priority:15,intelligence:"low"},".prettierrc.json":{frameworks:["Prettier"],slots:{},priority:15,intelligence:"low"},"biome.json":{frameworks:["Biome"],slots:{},priority:15,intelligence:"low"},".editorconfig":{frameworks:["EditorConfig"],slots:{},priority:10,intelligence:"low"},"serverless.yml":{frameworks:["Serverless Framework"],slots:{hosting:"AWS Lambda/Azure/GCP",backend:"Serverless",apiType:"API Gateway"},priority:30,intelligence:"high"},"serverless.yaml":{frameworks:["Serverless Framework"],slots:{hosting:"AWS Lambda/Azure/GCP",backend:"Serverless",apiType:"API Gateway"},priority:30,intelligence:"high"},"sam.yaml":{frameworks:["AWS SAM"],slots:{hosting:"AWS Lambda",backend:"AWS SAM",cicd:"AWS SAM CLI"},priority:30,intelligence:"high"},"template.yaml":{frameworks:["AWS SAM","CloudFormation"],slots:{hosting:"AWS",backend:"AWS SAM/CloudFormation",cicd:"AWS"},priority:25,intelligence:"medium",confirmWith:["samconfig.toml"]},"amplify.yml":{frameworks:["AWS Amplify"],slots:{hosting:"AWS Amplify",backend:"AWS Amplify",cicd:"AWS Amplify"},priority:30,intelligence:"high"},Podfile:{frameworks:["CocoaPods","iOS"],slots:{packageManager:"CocoaPods",mainLanguage:"Swift/Objective-C",framework:"iOS Native"},priority:30,intelligence:"high"},"build.gradle.kts":{frameworks:["Gradle Kotlin DSL","Android","Kotlin"],slots:{packageManager:"Gradle",mainLanguage:"Kotlin",buildTool:"Gradle Kotlin DSL",framework:"Android"},priority:30,intelligence:"high"},"*.ipynb":{frameworks:["Jupyter","Python"],slots:{mainLanguage:"Python",framework:"Jupyter Notebook"},priority:30,intelligence:"high"},MLproject:{frameworks:["MLflow"],slots:{mainLanguage:"Python",framework:"MLflow",backend:"MLflow",cicd:"MLflow"},priority:30,intelligence:"high"},"dvc.yaml":{frameworks:["DVC","Data Version Control"],slots:{mainLanguage:"Python",framework:"DVC",cicd:"DVC Pipelines"},priority:30,intelligence:"high"},"dvc.lock":{frameworks:["DVC"],slots:{framework:"DVC"},priority:20,intelligence:"medium"},"wrangler.toml":{frameworks:["Cloudflare Workers","Cloudflare"],slots:{hosting:"Cloudflare Workers",backend:"Cloudflare Workers",runtime:"V8 Isolates"},priority:30,intelligence:"high"},"deno.json":{frameworks:["Deno"],slots:{runtime:"Deno",mainLanguage:"TypeScript",packageManager:"Deno"},priority:30,intelligence:"high"},"bun.lockb":{frameworks:["Bun"],slots:{runtime:"Bun",packageManager:"Bun",mainLanguage:"TypeScript/JavaScript"},priority:30,intelligence:"high"},"codecov.yml":{frameworks:["Codecov"],slots:{cicd:"Codecov"},priority:25,intelligence:"high"},"dependabot.yml":{frameworks:["Dependabot","GitHub"],slots:{cicd:"Dependabot"},priority:25,intelligence:"high"},"renovate.json":{frameworks:["Renovate"],slots:{cicd:"Renovate"},priority:25,intelligence:"high"},Makefile:{frameworks:["Make","GNU Make"],slots:{buildTool:"Make"},priority:30,intelligence:"high"},"CMakeLists.txt":{frameworks:["CMake","C","C++"],slots:{buildTool:"CMake",mainLanguage:"C/C++"},priority:30,intelligence:"high"},"meson.build":{frameworks:["Meson","C","C++"],slots:{buildTool:"Meson",mainLanguage:"C/C++"},priority:30,intelligence:"high"},"*.c":{frameworks:["C"],slots:{mainLanguage:"C"},priority:30,intelligence:"high"},"*.cpp":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:30,intelligence:"high"},"*.cc":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:30,intelligence:"high"},"*.cxx":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:25,intelligence:"high"},"*.h":{frameworks:["C","C++"],slots:{mainLanguage:"C/C++"},priority:25,intelligence:"high"},"*.hpp":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:25,intelligence:"high"},"*.hxx":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:20,intelligence:"medium"},".env":{frameworks:[],slots:{},priority:20,intelligence:"medium"},".env.example":{frameworks:[],slots:{},priority:25,intelligence:"high"},".env.local":{frameworks:[],slots:{},priority:20,intelligence:"medium"},".env.development":{frameworks:[],slots:{},priority:20,intelligence:"medium"},".env.production":{frameworks:[],slots:{},priority:20,intelligence:"medium"},"skaffold.yaml":{frameworks:["Skaffold","Kubernetes"],slots:{hosting:"Kubernetes",cicd:"Skaffold"},priority:30,intelligence:"high"},"Chart.yaml":{frameworks:["Helm","Kubernetes"],slots:{hosting:"Kubernetes",backend:"Helm"},priority:30,intelligence:"high"},"values.yaml":{frameworks:["Helm","Kubernetes"],slots:{hosting:"Kubernetes"},priority:25,intelligence:"high",confirmWith:["Chart.yaml"]},"pulumi.yaml":{frameworks:["Pulumi"],slots:{hosting:"Cloud",cicd:"Pulumi"},priority:30,intelligence:"high"},"Pulumi.yaml":{frameworks:["Pulumi"],slots:{hosting:"Cloud",cicd:"Pulumi"},priority:30,intelligence:"high"},"terragrunt.hcl":{frameworks:["Terragrunt","Terraform"],slots:{hosting:"Cloud",cicd:"Terragrunt"},priority:30,intelligence:"high"},"ansible.yml":{frameworks:["Ansible"],slots:{cicd:"Ansible"},priority:30,intelligence:"high"},"playbook.yml":{frameworks:["Ansible"],slots:{cicd:"Ansible"},priority:25,intelligence:"high"},"*.cs":{frameworks:["C#",".NET","Unity"],slots:{mainLanguage:"C#"},priority:30,intelligence:"high"},"*.m":{frameworks:["Objective-C","iOS"],slots:{mainLanguage:"Objective-C"},priority:25,intelligence:"high"},".nvmrc":{frameworks:["Node.js","nvm"],slots:{runtime:"Node.js"},priority:25,intelligence:"high"},".tool-versions":{frameworks:["asdf"],slots:{},priority:25,intelligence:"high"},".ruby-version":{frameworks:["Ruby","rbenv"],slots:{mainLanguage:"Ruby",runtime:"Ruby"},priority:25,intelligence:"high"},".python-version":{frameworks:["Python","pyenv"],slots:{mainLanguage:"Python",runtime:"Python"},priority:25,intelligence:"high"},".dockerignore":{frameworks:["Docker"],slots:{},priority:20,intelligence:"medium"},".gitattributes":{frameworks:["Git"],slots:{},priority:15,intelligence:"low"},".npmrc":{frameworks:["npm","Node.js"],slots:{packageManager:"npm"},priority:20,intelligence:"medium"},"sonar-project.properties":{frameworks:["SonarQube","SonarCloud"],slots:{cicd:"SonarQube"},priority:25,intelligence:"high"},"*.fs":{frameworks:["F#",".NET"],slots:{mainLanguage:"F#"},priority:25,intelligence:"high"},"*.mm":{frameworks:["Objective-C++","iOS","macOS"],slots:{mainLanguage:"Objective-C++"},priority:25,intelligence:"high"},"build.zig.zon":{frameworks:["Zig"],slots:{mainLanguage:"Zig",packageManager:"Zig Package Manager",buildTool:"zig build"},priority:35,intelligence:"ultra-high"},"gleam.toml":{frameworks:["Gleam","BEAM","Erlang"],slots:{mainLanguage:"Gleam",runtime:"BEAM",packageManager:"Gleam"},priority:30,intelligence:"high"},"bunfig.toml":{frameworks:["Bun"],slots:{runtime:"Bun",packageManager:"Bun",buildTool:"Bun"},priority:30,intelligence:"high"},"mise.toml":{frameworks:["mise"],slots:{},priority:25,intelligence:"high"},".mise.toml":{frameworks:["mise"],slots:{},priority:25,intelligence:"high"},"manifest.toml":{frameworks:["Flox","Nix"],slots:{},priority:25,intelligence:"high",confirmWith:[".flox"]},justfile:{frameworks:["Just"],slots:{buildTool:"Just"},priority:25,intelligence:"high"},".pre-commit-config.yaml":{frameworks:["pre-commit"],slots:{cicd:"pre-commit"},priority:25,intelligence:"high"},"CLAUDE.md":{frameworks:["Claude Code"],slots:{},priority:30,intelligence:"high",confirmWith:[".claude"]}};import{existsSync as n9,readFileSync as SH,readdirSync as EH}from"fs";import{join as a2}from"path";var k0={version:2,_doc:"SINGLE SOURCE of Dart/Flutter detection KNOWLEDGE (A+B hybrid, the Truth-is-faf-cli spec). faf-cli imports this directly; faf-python-sdk vendors a synced copy (phase 2); MCPs compose it. Bolster Dart/Flutter by editing THIS file. Logic stays in dart.ts. Refreshed 2026-08-01 (knowledge v2) — community receipt on top of 6.13.0 Dart Edition.",flutterDeps:["flutter"],mcpDeps:["dart_mcp","mcp_server","mcp_dart","dart_mcp_server","mcp","dart_mcpserver"],serverFrameworks:[["serverpod","Serverpod"],["dart_frog","Dart Frog"],["conduit","Conduit"],["angel3_framework","Angel3"],["alfred","Alfred"],["shelf","Shelf"],["jaspr","Jaspr"],["relic","Relic"]],stateManagement:[["flutter_riverpod","Riverpod"],["hooks_riverpod","Riverpod"],["riverpod_annotation","Riverpod"],["riverpod","Riverpod"],["flutter_bloc","Bloc"],["bloc","Bloc"],["provider","Provider"],["get","GetX"],["flutter_mobx","MobX"],["mobx","MobX"],["signals","Signals"],["flutter_hooks","Hooks"]],routing:[["go_router","go_router"],["auto_route","auto_route"],["beamer","Beamer"],["routemaster","Routemaster"]]};var gH=k0.flutterDeps,fH=k0.mcpDeps,yH=k0.serverFrameworks,hH=k0.stateManagement,xH=k0.routing;function uH($){let Z=new Set,z=!1;for(let X of $.split(`
215
- `)){if(/^(dependencies|dev_dependencies|dependency_overrides):\s*$/.test(X)){z=!0;continue}if(/^\S/.test(X))z=!1;if(z){let U=X.match(/^\s{2}([a-zA-Z0-9_]+):/);if(U)Z.add(U[1].toLowerCase())}}return Z}function I1($){let Z=a2($,"pubspec.yaml");if(!n9(Z))return null;let z;try{z=SH(Z,"utf-8")}catch{return null}let X=uH(z),U=(K)=>X.has(K.toLowerCase()),Q=gH.some(U)||/^flutter:\s*$/m.test(z)||/\bsdk:\s*flutter\b/.test(z),J=fH.find(U),H=yH.find(([K])=>U(K)),G=hH.find(([K])=>U(K)),_=G?G[1]:"",B=xH.find(([K])=>U(K)),Y=B?B[1]:"",q=U("flutter_test")?"flutter_test":U("test")?"test":"",W=/^executables:\s*$/m.test(z),I=!1;try{I=EH(a2($,"bin")).some((K)=>K.endsWith(".dart"))}catch{}let V=W||I,O,L="",R;if(Q)if(L="Flutter",n9(a2($,"lib","main.dart"))||/^publish_to:\s*['"]?none\b/m.test(z))O="mobile",R="pubspec.yaml (Flutter app)";else O="library",R="pubspec.yaml (Flutter package)";else if(J)O="mcp",R=`pubspec.yaml + ${J} (Dart MCP server)`;else if(H)O="backend",L=H[1],R=`pubspec.yaml + ${H[0]} (Dart backend)`;else if(V)O="cli",R=W?"pubspec.yaml executables: (Dart CLI)":"pubspec.yaml + bin/*.dart (Dart CLI)";else O="library",R="pubspec.yaml (Dart package)";return{appType:O,isFlutter:Q,framework:L,stateManagement:_,routing:Y,testing:q,found:R}}import{existsSync as r2,readFileSync as e9,readdirSync as o9,statSync as vH}from"fs";import{join as D1}from"path";var L1={version:1,_doc:"SINGLE SOURCE of Go detection KNOWLEDGE (A+B hybrid, Truth-is-faf-cli). faf-cli imports this directly; SDKs/MCPs compose it. Bolster Go by editing THIS file. Logic stays in go.ts. Content-aware: go.mod ≠ one bucket — backend · CLI · MCP · library. 2026-08-01 initial (Dart composition pattern).",mcpModules:["github.com/mark3labs/mcp-go","github.com/modelcontextprotocol/go-sdk","github.com/metoro-io/mcp-golang","github.com/ThinkInAIXYZ/go-mcp"],serverFrameworks:[["github.com/gin-gonic/gin","Gin"],["github.com/labstack/echo","Echo"],["github.com/labstack/echo/v4","Echo"],["github.com/gofiber/fiber","Fiber"],["github.com/gofiber/fiber/v2","Fiber"],["github.com/go-chi/chi","Chi"],["github.com/go-chi/chi/v5","Chi"],["github.com/gorilla/mux","Gorilla Mux"],["github.com/gofiber/fiber/v3","Fiber"],["google.golang.org/grpc","gRPC"],["connectrpc.com/connect","Connect"],["github.com/go-kratos/kratos","Kratos"],["github.com/go-kratos/kratos/v2","Kratos"],["github.com/zeromicro/go-zero","go-zero"],["github.com/cloudwego/hertz","Hertz"]],cliFrameworks:[["github.com/spf13/cobra","Cobra"],["github.com/urfave/cli","urfave/cli"],["github.com/urfave/cli/v2","urfave/cli"],["github.com/alecthomas/kingpin","Kingpin"],["github.com/alecthomas/kong","Kong"]]};var mH=L1.mcpModules,pH=L1.serverFrameworks,lH=L1.cliFrameworks;function dH($){let Z=new Set,z=!1;for(let X of $.split(`
216
- `)){let U=X.replace(/\/\/.*$/,"").trim();if(!U)continue;if(/^require\s*\(\s*$/.test(U)){z=!0;continue}if(z){if(U===")"){z=!1;continue}let J=U.match(/^(\S+)/);if(J)Z.add(J[1].toLowerCase());continue}let Q=U.match(/^require\s+(\S+)/);if(Q&&Q[1]!=="(")Z.add(Q[1].toLowerCase())}return Z}function $6($,Z){let z=Z.toLowerCase();for(let X of $)if(X===z||X.startsWith(`${z}/`))return!0;return!1}function t9($,Z){let z;for(let X of Z){if(!$6($,X[0]))continue;if(!z||X[0].length>z[0].length)z=X}return z}function cH($,Z){let z;for(let X of Z){if(!$6($,X))continue;if(!z||X.length>z.length)z=X}return z}function iH($){let Z=$.match(/^module\s+(\S+)/m);return Z?Z[1]:""}function sH($){let Z=D1($,"cmd");if(!r2(Z))return!1;try{for(let z of o9(Z)){let X=D1(Z,z);try{if(vH(X).isDirectory()){if(o9(X).some((Q)=>Q.endsWith(".go")))return!0}else if(z.endsWith(".go"))return!0}catch{}}}catch{}return!1}function aH($){let Z=D1($,"main.go");if(!r2(Z))return!1;try{let z=e9(Z,"utf-8");return/^package\s+main\b/m.test(z)}catch{return!1}}function R1($){let Z=D1($,"go.mod");if(!r2(Z))return null;let z;try{z=e9(Z,"utf-8")}catch{return null}let X=iH(z),U=dH(z),Q=cH(U,mH),J=t9(U,pH),H=t9(U,lH),G=sH($),_=aH($),B,Y="",q;if(Q)B="mcp",q=`go.mod + ${Q} (Go MCP server)`;else if(J)B="backend",Y=J[1],q=`go.mod + ${J[0]} (Go backend)`;else if(H)B="cli",Y=H[1],q=`go.mod + ${H[0]} (Go CLI)`;else if(G)B="cli",q="go.mod + cmd/ (Go CLI layout)";else if(_&&!J)B="cli",q="go.mod + main.go package main (Go CLI)";else B="library",q="go.mod (Go module)";return{appType:B,modulePath:X,framework:Y,found:q}}var $G=new Set(["node_modules",".git","dist","build","venv",".venv","__pycache__","target","coverage",".next",".svelte-kit","vendor"]),ZG=new Set([".py",".ts",".tsx",".js",".jsx",".svelte",".vue",".rb",".go",".rs",".php",".java",".kt",".swift"]),zG={mainLanguage:["project","main_language"],main_language:["project","main_language"],framework:["stack","frontend"],cssFramework:["stack","css_framework"],css:["stack","css_framework"],uiLibrary:["stack","ui_library"],ui_library:["stack","ui_library"],stateManagement:["stack","state_management"],state:["stack","state_management"],backend:["stack","backend"],apiType:["stack","api_type"],api:["stack","api_type"],runtime:["stack","runtime"],database:["stack","database"],db:["stack","database"],connection:["stack","connection"],hosting:["stack","hosting"],buildTool:["stack","build"],build_tool:["stack","build"],build:["stack","build"],packageManager:["stack","package_manager"],pkg_manager:["stack","package_manager"],cicd:["stack","cicd"]},XG=[["packageManager","package-manager"],["pkg_manager","package-manager"],["mainLanguage","language"],["main_language","language"],["framework","framework"],["backend","backend"],["database","database"],["db","database"],["cicd","ci-cd"],["hosting","hosting"],["buildTool","build"],["build_tool","build"],["build","build"],["runtime","runtime"],["cssFramework","css"],["css","css"],["uiLibrary","ui-library"],["stateManagement","state-management"],["apiType","api"],["api","api"]];function UG($,Z){for(let[z,X]of XG)if(z in $)return X;return Z.length>0?"framework":"config"}function QG($){try{let Z=JSON.parse(nH($,"utf-8")),z=["background","content_scripts","action","browser_action","permissions"].some((X)=>(X in Z));if(typeof Z.manifest_version==="number"&&z)return"chrome";return"other"}catch{return"other"}}function JG($){let Z=[],z=eH($),X=rH(n2($,".git"));for(let U=0;U<10;U++){let Q;try{Q=Z6(z)}catch{break}for(let H of Q){let G=s2[H];if(!G)continue;if(H==="manifest.json"&&QG(n2(z,H))!=="chrome")continue;if(H==="pubspec.yaml"){let _=I1(z);if(_){let B={mainLanguage:"Dart",packageManager:"pub"};if(_.isFlutter){if(B.framework="Flutter",_.stateManagement)B.stateManagement=_.stateManagement}else if(_.appType==="backend"&&_.framework)B.backend=_.framework;else if(_.appType==="mcp")B.apiType="MCP";Z.push({slots:B,priority:G.priority,frameworks:_.isFlutter?["Flutter","Dart"]:["Dart"],fileName:H});continue}}if(H==="go.mod"){let _=R1(z);if(_){let B={mainLanguage:"Go",packageManager:"go modules",buildTool:"go build"};if(_.appType==="backend"&&_.framework)B.backend=_.framework;else if(_.appType==="cli"&&_.framework)B.framework=_.framework;else if(_.appType==="mcp")B.apiType="MCP";let Y=_.framework?[_.framework,"Go"]:["Go"];Z.push({slots:B,priority:G.priority,frameworks:Y,fileName:H});continue}}Z.push({slots:G.slots||{},priority:G.priority,frameworks:G.frameworks,fileName:H})}if(X&&U===0)break;let J=oH(z);if(J===z)break;z=J}return Z}function HG($){let Z=[];for(let z of X6($,2,{count:0})){let X=s2[`*${z}`],U=X?.slots?.mainLanguage;if(U)Z.push({slots:{mainLanguage:U},priority:X.priority,frameworks:X.frameworks})}return Z}function z6($){let Z=[...JG($),...HG($)],z={},X={},U=new Set;for(let _ of Z){_.frameworks.forEach((B)=>U.add(B));for(let[B,Y]of Object.entries(_.slots))if(Y&&!Y.includes("/")&&(!(B in z)||_.priority>X[B]))z[B]=Y,X[B]=_.priority}let Q=new Map;for(let _ of Z){if(!_.fileName)continue;if(!Q.has(_.fileName))Q.set(_.fileName,{fileName:_.fileName,category:UG(_.slots,_.frameworks),priority:_.priority})}let J=[...Q.values()].sort((_,B)=>B.priority-_.priority||_.fileName.localeCompare(B.fileName)),H=[];if(z.mainLanguage)H.push(z.mainLanguage.toLowerCase());if(z.framework)H.push(z.framework.toLowerCase());let G=H.length>0?H.join("-"):"unknown-stack";return{slotFills:z,frameworks:[...U],confirmedCount:Z.length,discoveredFormats:J,stackSignature:G}}function o2($){let{slotFills:Z}=z6($),z={};for(let[X,U]of Object.entries(Z)){let Q=zG[X];if(!Q||!U)continue;let[J,H]=Q;if(J==="project")(z.project??={})[H]=U;else(z.stack??={})[H]=U}return z}function X6($,Z,z){let X=new Set;if(Z<0||z.count>400)return X;let U;try{U=Z6($,{withFileTypes:!0})}catch{return X}for(let Q of U){if(z.count++>400)break;if(!Q.isDirectory()){let J=tH(Q.name);if(ZG.has(J))X.add(J);continue}if($G.has(Q.name)||Q.name.startsWith("."))continue;for(let J of X6(n2($,Q.name),Z-1,z))X.add(J)}return X}import{existsSync as U6,readFileSync as Q6}from"fs";import{join as J6}from"path";var h=($,Z,z)=>({value:$,source:Z,confidence:z});function H6($){let Z=GG($),z=_G($),X={},U=(Q,J)=>{if(J)X[Q]=J};return U("what",YG(Z,z)),U("who",qG(z)),U("why",BG(z)),U("where",VG(Z,z)),U("when",OG(z)),U("how",WG(Z,z)),X}function t2($){let Z=H6($),z={};return Object.keys(Z).forEach((X)=>{let U=Z[X];if(U)z[X]=U.value}),z}function GG($){let Z=J6($,"package.json");if(!U6(Z))return null;try{return JSON.parse(Q6(Z,"utf-8"))}catch{return null}}function _G($){let Z=J6($,"README.md");if(!U6(Z))return"";let z;try{z=Q6(Z,"utf-8")}catch{return""}return z.split(`
213
+ `}function _H($,Z,U,X="project.faf"){XH(QH($,"project.html"),y6(Z,U,X),"utf-8")}import{writeFileSync as BH}from"fs";import{join as VH}from"path";var f6="application/vnd.faf+yaml",OH="https://static.modelcontextprotocol.io/schemas/v1/server-card.schema.json",WH=/^[a-zA-Z0-9.-]+\/[a-zA-Z0-9._-]+$/;function k6($){let Z=String($.project?.name??"project").trim();if(Z.includes("/")&&WH.test(Z))return Z;let U=$.project?.homepage??$.project?.website??$.project?.url,X="local";if(U)try{X=new URL(U).hostname.replace(/^www\./,"").split(".").reverse().join(".")}catch{}let Q=Z.replace(/[^a-zA-Z0-9._-]/g,"-").replace(/^-+|-+$/g,"")||"project";return`${X}/${Q}`}function DH($){let Z=String($.project?.goal??$.context??$.project?.name??"MCP server").replace(/\s+/g," ").trim();if(!Z)return"MCP server";return Z.length<=100?Z:`${Z.slice(0,97).trimEnd()}...`}function a2($,Z={}){return{faf:Z.fafPointer??"./project.faf",mediaType:f6,iana:`https://www.iana.org/assignments/media-types/${f6}`,deterministic:!0,...Z.scoreEndpoint?{scoreEndpoint:Z.scoreEndpoint}:{},generated:$.generated??Z.now??new Date().toISOString()}}function v6($,Z={}){let U={$schema:OH,name:k6($),version:String($.project?.version??"0.1.0"),description:DH($)},X=RH($)??$.project?.name;if(X&&X.length<=100)U.title=X;let Q=$.project?.homepage??$.project?.website??$.project?.url;if(Q)U.websiteUrl=Q;if(Z.remoteUrl)U.remotes=[{type:"streamable-http",url:Z.remoteUrl}];return U._meta={"one.faf/context":a2($,Z)},U}var m6="io.modelcontextprotocol.registry/publisher-provided",u6=4096;function IH($,Z={}){let U={"one.faf/context":a2($,Z)},X=new TextEncoder().encode(JSON.stringify(U)).length;if(X>u6)throw Error(`publisher-provided _meta is ${X}B — exceeds the registry ${u6}B cap`);return{[m6]:U}}function LH($){return k6($)}function RH($){let Z=$.project?.title;if(typeof Z==="string"){let U=Z.trim();if(U&&U.length<=100)return U}return}function MH($,Z,U={}){let X=v6(Z,U),Q=VH($,"server-card");return BH(Q,`${JSON.stringify(X,null,2)}
214
+ `,"utf-8"),Q}var n2=["ephemeral","standard","high","critical"],B0=Object.fromEntries(n2.map(($,Z)=>[$,Z])),F$=new Set(["user","feedback","project","reference"]),o2=new Set(["version","profile","namepoint","created","last_etched","retention","index","memory"]),t2=new Set(["facts","sessions","preferences","custom"]),e2={low:"ephemeral",medium:"standard"};import{readFileSync as KH,writeFileSync as FH,existsSync as PH}from"fs";function m0(){return new Date().toISOString().replace(/\.\d{3}Z$/,"Z")}function u($){return $===null||$===void 0}function F1($){if(u($))return"standard";if(e2[$])return e2[$];if($ in B0)return $;return"standard"}var AH=new Set(["text","id","type","priority","tags","links","timestamp","source"]);function p6($){if(typeof $==="string")return{text:$,id:null,type:null,priority:"standard",tags:[],links:[],timestamp:null,source:null,extra:{}};if(!$||typeof $!=="object"||!("text"in $))throw Error(`fact must be a string or a mapping with 'text': ${JSON.stringify($)}`);let Z=$,U={};for(let[X,Q]of Object.entries(Z))if(!AH.has(X))U[X]=Q;return{text:String(Z.text),id:Z.id??null,type:Z.type??null,priority:F1(Z.priority),tags:Array.isArray(Z.tags)?Z.tags.slice():[],links:Array.isArray(Z.links)?Z.links.slice():[],timestamp:Z.timestamp??null,source:Z.source??null,extra:U}}function l6($){if(u($.id)&&u($.type)&&$.tags.length===0&&$.links.length===0&&u($.timestamp)&&u($.source)&&Object.keys($.extra).length===0&&$.priority==="standard")return $.text;let U={text:$.text};if(!u($.id))U.id=$.id;if(!u($.type))U.type=$.type;if(U.priority=$.priority,$.tags.length)U.tags=$.tags;if($.links.length)U.links=$.links;if(!u($.timestamp))U.timestamp=$.timestamp;if(!u($.source))U.source=$.source;return Object.assign(U,$.extra),U}class K0{namepoint;profile;retention;created;last_etched;_facts;_byId;_index;_sessions;_preferences;_custom;_extra;_memoryExtra;constructor($,Z={}){this.namepoint=$,this.profile=Z.profile??"knowledge",this.retention=Z.retention??"forever",this.created=Z.created??m0(),this.last_etched=this.created,this._facts=Z.facts?Z.facts.slice():[],this._byId=new Map,this._facts.forEach((U,X)=>{if(!u(U.id))this._byId.set(U.id,X)}),this._index=Z.index?Z.index.slice():[],this._sessions=Z.sessions?structuredClone(Z.sessions):[],this._preferences=Z.preferences?{...Z.preferences}:{},this._custom=Z.custom?{...Z.custom}:{},this._extra=Z.extra?{...Z.extra}:{},this._memoryExtra=Z.memoryExtra?{...Z.memoryExtra}:{}}get facts(){return this._facts}get index(){return this._index}get sessions(){return this._sessions}get preferences(){return this._preferences}get custom(){return this._custom}get extra(){return this._extra}get memoryExtra(){return this._memoryExtra}static load($){if(!PH($))throw Error(`soul file not found: ${$}`);let Z=KH($,"utf-8"),U=e(Z);if(!U||typeof U!=="object")throw Error("soul is not a YAML mapping");let X=U.memory&&typeof U.memory==="object"?U.memory:{},Q=Array.isArray(X.facts)?X.facts:[],z={};for(let[q,Y]of Object.entries(U))if(!o2.has(q))z[q]=structuredClone(Y);let J={};for(let[q,Y]of Object.entries(X))if(!t2.has(q))J[q]=structuredClone(Y);let H=new K0(String(U.namepoint??$.replace(/.*\//,"").replace(/\.fafm$/,"")),{profile:String(U.profile??"voice"),facts:Q.map(p6),retention:String(U.retention??"forever"),created:U.created??null,index:Array.isArray(U.index)?U.index.slice():[],sessions:Array.isArray(X.sessions)?structuredClone(X.sessions):[],preferences:X.preferences&&typeof X.preferences==="object"?structuredClone(X.preferences):{},custom:X.custom&&typeof X.custom==="object"?structuredClone(X.custom):{},extra:z,memoryExtra:J});return H.last_etched=String(U.last_etched??H.created),H}static fromFile($){return K0.load($)}toDoc(){let $={facts:this._facts.map(l6),sessions:structuredClone(this._sessions),preferences:structuredClone(this._preferences),custom:structuredClone(this._custom)};for(let[U,X]of Object.entries(this._memoryExtra))if(!t2.has(U))$[U]=structuredClone(X);let Z={version:"1.1",profile:this.profile,namepoint:this.namepoint,created:this.created,last_etched:this.last_etched,retention:this.retention,index:this._index.slice(),memory:$};for(let[U,X]of Object.entries(this._extra))if(!o2.has(U))Z[U]=structuredClone(X);return Z}toYaml(){return M$(this.toDoc(),{lineWidth:100})}rebuildIndex($=80){return this._index=this._facts.map((Z)=>`${Z.id??"?"} — ${Z.text.slice(0,$)}`),this._index}save($,Z={}){if(Z.reindex!==!1)this.rebuildIndex();return FH($,this.toYaml(),"utf-8"),$}toFile($,Z={}){return this.save($,Z)}add($){if(!u($.id)&&this._byId.has($.id)){let Z=this._byId.get($.id);if(Z!==void 0)this._facts[Z]=$}else if(this._facts.push($),!u($.id))this._byId.set($.id,this._facts.length-1);if($.timestamp&&$.timestamp>(this.last_etched||""))this.last_etched=$.timestamp;return $}etch($,Z={}){return this.add({text:$,id:Z.id??null,type:Z.type??null,priority:F1(Z.priority),tags:Z.tags?Z.tags.slice():[],links:Z.links?Z.links.slice():[],timestamp:m0(),source:Z.source??null,extra:{}})}recall($,Z={}){let U=B0[F1(Z.minPriority??"ephemeral")]??0,X=($??"").toLowerCase(),Q=new Set(Z.tags??[]),z=[];this._facts.forEach((H,q)=>{if(X&&!H.text.toLowerCase().includes(X))return;if(Q.size>0&&![...Q].some((Y)=>H.tags.includes(Y)))return;if(!u(Z.type)&&H.type!==Z.type)return;if((B0[H.priority]??1)<U)return;z.push([q,H])}),z.sort((H,q)=>{let Y=B0[H[1].priority]??1,G=B0[q[1].priority]??1;if(G!==Y)return G-Y;let _=H[1].timestamp??"",B=q[1].timestamp??"";if(B!==_)return B<_?-1:B>_?1:0;return q[0]-H[0]});let J=z.map(([,H])=>H);if(!u(Z.limit))return J.slice(0,Z.limit);return J}getFact($){let Z=this._byId.get($);return Z===void 0?null:this._facts[Z]}deleteFact($){let Z=this._byId.get($);if(Z===void 0)return!1;return this._facts.splice(Z,1),this._byId.clear(),this._facts.forEach((U,X)=>{if(!u(U.id))this._byId.set(U.id,X)}),!0}}import{readdirSync as TH,readFileSync as NH,statSync as d6,existsSync as wH}from"fs";import{join as CH,basename as c6,resolve as bH}from"path";var i6=new Set(["MEMORY.md","MEMORY-FULL.md","README.md"]),SH=/\[\[([^\]]+)\]\]/g;function EH($){let Z=d6($).mtimeMs;return new Date(Z).toISOString().replace(/\.\d{3}Z$/,"Z")}function jH($){if(!$.startsWith("---"))return{fm:null,body:$};let Z=$.split("---");if(Z.length<3)return{fm:null,body:$};try{let U=e(Z[1]);if(!U||typeof U!=="object")return{fm:null,body:Z.slice(2).join("---").trim()};return{fm:U,body:Z.slice(2).join("---").trim()}}catch{return{fm:null,body:$}}}function gH($,Z,U){if(!U.name)return null;let X=U.metadata&&typeof U.metadata==="object"?U.metadata:{},Q=X.type;if(typeof Q!=="string"||!F$.has(Q))return null;let z=String(U.name).trim(),H=(U.description!==void 0&&U.description!==null&&String(U.description).trim()?String(U.description).trim():"")||z,q={};if(X.originSessionId)q.provenance=[`session:${X.originSessionId}`];let Y=[...new Set([...Z.matchAll(SH)].map((G)=>G[1]))].sort();return{text:H,id:z,type:Q,priority:"standard",tags:[],links:Y,timestamp:EH($),source:`claude-code memory: ${c6($)}`,extra:q}}function r6($,Z={}){let U=bH($);if(!wH(U))throw Error(`Claude memory directory not found: ${U}`);if(!d6(U).isDirectory())throw Error(`Claude memory path is not a directory: ${U}`);let X=Z.skip??i6,Q=Z.namepoint??`@claude-code:${c6(U)}`,z=[],J=TH(U).filter((_)=>_.endsWith(".md")).sort();for(let _ of J){if(X.has(_))continue;let B=CH(U,_),O;try{O=NH(B,"utf-8")}catch{continue}let{fm:D,body:V}=jH(O);if(!D)continue;let W=gH(B,V,D);if(W)z.push(W)}let H=z.map((_)=>_.timestamp).filter(Boolean),q=H.length?H.reduce((_,B)=>_<B?_:B):m0(),Y=H.length?H.reduce((_,B)=>_>B?_:B):q,G=new K0(Q,{profile:"knowledge",facts:z,created:q});return G.last_etched=Y,G.rebuildIndex(),G}var t6="faf-interview/1",p0="(terse — 3-4 words)",$3=[{path:"project.name",question:"What is the name of this project?",header:"Name",type:"text",required:!0},{path:"project.goal",question:"What does this project do? (one sentence)",header:"Goal",type:"text",required:!0},{path:"human_context.who",question:`Who is this for? ${p0}`,header:"Who",type:"text",required:!0},{path:"human_context.what",question:`What are they building? ${p0}`,header:"What",type:"text",required:!0},{path:"human_context.why",question:`Why does it exist? ${p0}`,header:"Why",type:"text",required:!0},{path:"human_context.where",question:`Where does it run or ship? ${p0}`,header:"Where",type:"text",required:!0},{path:"human_context.when",question:`When — timeline or stage? ${p0}`,header:"When",type:"text",required:!0},{path:"human_context.how",question:`How is it built or used? ${p0}`,header:"How",type:"text",required:!0}],e6=[{path:"project.main_language",question:"What is the primary programming language?",header:"Language",type:"select",required:!0,options:[{label:"TypeScript",value:"TypeScript",description:"JavaScript with types"},{label:"JavaScript",value:"JavaScript",description:"Vanilla JS or Node.js"},{label:"Python",value:"Python",description:"Python 3.x"},{label:"Rust",value:"Rust",description:"Systems programming"},{label:"Go",value:"Go",description:"Golang"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.frontend",question:"What frontend framework does it use?",header:"Frontend",type:"select",required:!1,options:[{label:"React",value:"React",description:"React.js"},{label:"Vue",value:"Vue",description:"Vue.js"},{label:"Svelte",value:"Svelte",description:"Svelte/SvelteKit"},{label:"Next.js",value:"Next.js",description:"React framework"},{label:"None",value:"None",description:"No frontend"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.backend",question:"What backend framework does it use?",header:"Backend",type:"select",required:!1,options:[{label:"Express",value:"Express",description:"Node.js Express"},{label:"Fastify",value:"Fastify",description:"Node.js Fastify"},{label:"Django",value:"Django",description:"Python Django"},{label:"FastAPI",value:"FastAPI",description:"Python FastAPI"},{label:"None",value:"None",description:"No backend"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.database",question:"What database does it use?",header:"Database",type:"select",required:!1,options:[{label:"PostgreSQL",value:"PostgreSQL",description:"Postgres"},{label:"MySQL",value:"MySQL",description:"MySQL/MariaDB"},{label:"SQLite",value:"SQLite",description:"Embedded SQL"},{label:"MongoDB",value:"MongoDB",description:"Document store"},{label:"None",value:"None",description:"No database"},{label:"Other",value:"Other",description:"Specify manually"}]},{path:"stack.runtime",question:"What runtime does it run on?",header:"Runtime",type:"text",required:!1},{path:"stack.hosting",question:"Where is it hosted or distributed?",header:"Hosting",type:"text",required:!1},{path:"stack.build",question:"What is the build tool?",header:"Build",type:"text",required:!1},{path:"stack.cicd",question:"What CI/CD does it use?",header:"CI/CD",type:"text",required:!1}],l0=[...$3,...e6],$9=new Map(l0.map(($)=>[$.path,$])),xH=Object.fromEntries(l0.map(($)=>[$.path,$]));function Z3($){let Z=$9.get($);if(Z)return Z.question;let U=s0.get($)??y.find((X)=>X.canonical===$);return U?`${U.description}?`.replace(/\?\?$/,"?"):`${$}?`}function hH($,Z){return l0.filter((U)=>{let X=U.path.split("."),Q=$;for(let z of X)if(Q&&typeof Q==="object"&&z in Q)Q=Q[z];else{Q=void 0;break}if(Q==="slotignored")return!1;return Z(Q)})}var yH=new Set(["developers","development teams","development team","teams","development","cloud platform","web platform","platform","best practices","improve development efficiency","development efficiency","modern development practices","modern development","test-driven development","production/stable","production","stable","app","project","tool"]),fH=[["npm",/\bnpm\b/i],["PyPI",/\bpypi\b/i],["crates.io",/\bcrates\.io\b/i],["Homebrew",/\bhomebrew\b/i],["Docker",/\bdocker\b/i],["Cloudflare",/\bcloudflare\b/i],["Vercel",/\bvercel\b/i],["Netlify",/\bnetlify\b/i],["AWS",/\baws\b/i],["Cloud Run",/\bcloud run\b/i],["edge",/\bedge\b/i],["browser",/\bbrowser\b/i],["WASM",/\bwasm\b/i],["GitHub",/\bgithub\b/i],["MCP Registry",/\bmcp registry\b/i],["Chrome Web Store",/\bchrome web store\b/i],["Smithery",/\bsmithery\b/i]],s6=($)=>yH.has($.toLowerCase().trim()),uH=/^(?:with|and|or|using|for|to|that|who|whom|whose|the|a|an|in|on|of|via|by|&)$/i;function a6($,Z=5){let U=$.trim().split(/\s+/).filter(Boolean).slice(0,Z);while(U.length&&uH.test(U[U.length-1].replace(/[.,;:]+$/,"")))U.pop();return U.join(" ")}function Z9($){let Z={};if(!$||typeof $!=="string")return Z;let U=$.trim(),X=U.replace(/^[^A-Za-z0-9]+/,"").split(/\s+(?:for|that|which|to)\s+|\s+[—–]\s+|\s-\s|:\s|\.\s|,\s/)[0].trim(),Q=a6(X);if(Q.split(/\s+/).filter(Boolean).length>=2&&!s6(Q))Z.what=Q;let z=fH.filter(([,q])=>q.test(U)).map(([q])=>q);if(z.length)Z.where=z.slice(0,4).join(", ");let J=U.match(/\bfor ((?:[A-Za-z][\w./+-]* )?(?:any |all )?(?:developers?|teams?|engineers?|builders?|users?|integrators?)\b[^.,;:—]*)/i),H=a6((J?.[1]||"").trim().replace(/\s+/g," "));if(H&&!s6(H))Z.who=H;return Z}function n6($,Z){let U=$;for(let X of Z.split("."))if(U&&typeof U==="object"&&X in U)U=U[X];else return;return U}function o6($){if(typeof $!=="string")return!1;let Z=$.trim();if(!Z||Z==="slotignored")return!1;return!V0(Z)}function kH($,Z={}){let U=$&&typeof $==="object"?$:{},X=n6(U,"project.goal"),Q=(o6(X)?String(X).trim():"")||(Z.goal??"").trim(),z=Z9(Q),J=Z.detailed??{},H={"project.goal":Q||void 0,"human_context.what":z.what,"human_context.where":z.where,"human_context.who":z.who},q=(O)=>{let D=H[O];if(D)return{value:D,source:"project goal",confidence:0.9};let V=O.startsWith("human_context.")?O.slice(14):"",W=V?J[V]:void 0;return W?{value:W.value,source:W.source,confidence:W.confidence}:void 0},Y=$3.map((O,D)=>{let V={n:D+1,path:O.path,header:O.header,question:O.question},W=n6(U,O.path);if(o6(W))return{...V,value:String(W).trim(),status:"filled",seeded:!1};let I=q(O.path);if(I)return{...V,value:I.value,status:"seeded",seeded:!0,source:I.source,confidence:I.confidence};return{...V,value:"",status:"empty",seeded:!1}}),G=Y.filter((O)=>O.status==="filled").length,_=Y.filter((O)=>O.status==="seeded").length,B=Y.filter((O)=>O.status==="empty").length;return{version:t6,rows:Y,filledCount:G,seededCount:_,emptyCount:B,complete:B===0}}function P$($){if($===null||$===void 0)return!0;if(typeof $==="string"){let Z=$.trim();return Z===""||V0(Z)}return!1}function vH($,Z){let U=$;for(let X of Z.split("."))if(U&&typeof U==="object"&&X in U)U=U[X];else return;return U}function U9($){if($==="project.goal")return!0;return s0.get($)?.category==="human"}function X9($,Z=P$){let U=[],X=[];for(let Q of l0){let z=vH($,Q.path);if(z==="slotignored")continue;if(!Z(z))continue;(U9(Q.path)?U:X).push(Q.path)}return{human:U,sourceable:X}}function Q9($,Z,U=P$){let X=X9(Z,U),Q;if($>=100||X.human.length===0&&X.sourceable.length===0)Q="done";else if(X.sourceable.length>0)Q="can-source";else Q="needs-human";let z=Q==="needs-human"?U3(X):[];return{status:Q,score:$,gaps:X,ask:z}}function U3($){return $.human.map((Z)=>({path:Z,question:Z3(Z)}))}function mH($,Z={}){let U=Math.max(1,Z.maxRounds??5),X=Z.isEmpty??P$,Q=[],z=0;for(let H=0;H<=U;H++){let q=$.read();if(!q)return{status:"no-faf",score:0,rounds:z,history:Q,ask:[]};let Y=$.score(q.yaml);Q.push(Y);let G=Q9(Y,q.data,X);if(G.status==="done")return{status:"done",score:Y,rounds:z,history:Q,ask:[]};if(G.status==="needs-human")return{status:"needs-human",score:Y,rounds:z,history:Q,ask:G.ask};if(Q.length>=2&&Y<=Q[Q.length-2])return G.gaps.human.length?{status:"needs-human",score:Y,rounds:z,history:Q,ask:U3(G.gaps)}:{status:"stuck",score:Y,rounds:z,history:Q,ask:[]};if(z>=U)return{status:"capped",score:Y,rounds:z,history:Q,ask:U3(G.gaps)};$.runAuto(),z++}return{status:"capped",score:Q[Q.length-1]??0,rounds:z,history:Q,ask:[]}}import{createHash as J9}from"crypto";var X3="faf-bench/1",pH={"project.name":"What is the project's name?","project.goal":"What is the project's goal — what is it for?","project.main_language":"What is the primary programming language?","human_context.who":"Who is this project for?","human_context.what":"What are they building?","human_context.why":"Why does this project exist?","human_context.where":"Where does it run or get distributed?","human_context.when":"When — what is the project's timeline or stage?","human_context.how":"How is it built or used?"};function lH($,Z){return pH[$]??`What is the project's ${Z.replace(/\s*\(.*\)$/,"").toLowerCase()}?`}var H9=[["typescript","ts"],["javascript","js"],["python","py","python3"],["node","nodejs","node js","node.js"],["github actions","gh actions","actions"],["postgresql","postgres","pg"],["kubernetes","k8s"],["npm","npm registry"],["cloudflare workers","cf workers","workers"],["google cloud run","cloud run","gcp cloud run"]],P1=new Map;H9.forEach(($,Z)=>$.forEach((U)=>P1.set(U,Z)));var dH=new Set(["a","an","the","and","or","of","for","to","in","on","with","is","it","its","their","your","via","by","using","use","used"]);function A$($){return $.toLowerCase().replace(/[^a-z0-9\s.+#-]/g," ").replace(/\.(?=\s|$)/g," ").replace(/\s+/g," ").trim()}function z9($){return A$($).split(" ").filter((Z)=>Z&&!dH.has(Z))}function q9($,Z){let U=A$($),X=A$(Z);if(!U||!X)return!1;if(U===X)return!0;let Q=P1.get(U);if(Q!==void 0&&P1.get(X)===Q)return!0;let z=z9($);if(z.length===0)return!1;let J=new Set(z9(Z));return z.every((H)=>{if(J.has(H))return!0;let q=P1.get(H);return q!==void 0&&[...J].some((Y)=>P1.get(Y)===q)})}function cH($){let Z=f$($),U=e($),X=[],Q={},z=0;for(let q of y){if(Z.slots[q.path]!=="populated")continue;let Y=L3(U,q);if(typeof Y!=="string")continue;let G=Y.trim();if(!G||S1.has(G.toLowerCase()))continue;z+=1,X.push({n:z,path:q.path,question:lH(q.path,q.description)}),Q[z]=G}let J=JSON.stringify({v:X3,q:X.map((q)=>[q.path,q.question])}),H=J9("sha256").update(J).digest("hex").slice(0,12);return{version:X3,qsetHash:H,questions:X,answers:Q}}function iH($){return{version:$.version,qsetHash:$.qsetHash,questions:$.questions}}function rH($,Z){let U=$.questions.map((Q)=>{let z=Z[String(Q.n)]??Z[Q.path]??"";return{n:Q.n,path:Q.path,ok:typeof z==="string"&&z.trim()!==""&&q9($.answers[Q.n],z)}}),X=$.questions.filter((Q)=>!U[Q.n-1].ok);return{correct:U.filter((Q)=>Q.ok).length,total:$.questions.length,misses:X,perQuestion:U}}function sH($,Z){let U=JSON.stringify({v:$.version,repo:Z??null,qset:$.qsetHash,protocol:$.protocol,cold:$.cold??null,faf:$.faf??null});return{projection:U,hash:J9("sha256").update(U).digest("hex")}}import{existsSync as oq,readdirSync as M9,readFileSync as tq}from"fs";import{join as Y3,dirname as eq,extname as $Y,resolve as ZY}from"path";var Q3={"package.json":{frameworks:["Node.js","JavaScript","TypeScript"],slots:{packageManager:"npm/yarn/pnpm",mainLanguage:"JavaScript/TypeScript"},priority:35,intelligence:"ultra-high"},"README.md":{frameworks:[],slots:{targetUser:"developers",coreProblem:"understanding project",missionPurpose:"project documentation"},priority:25,intelligence:"high"},"requirements.txt":{frameworks:["Python"],slots:{packageManager:"pip",mainLanguage:"Python"},priority:35,intelligence:"ultra-high"},Pipfile:{frameworks:["Python"],slots:{packageManager:"pipenv",mainLanguage:"Python"},priority:35,intelligence:"ultra-high"},"pyproject.toml":{frameworks:["Python"],slots:{mainLanguage:"Python",runtime:"Python",backend:"Python"},priority:36,intelligence:"ultra-high"},Gemfile:{frameworks:["Ruby","Rails"],slots:{packageManager:"bundler",mainLanguage:"Ruby"},priority:35,intelligence:"ultra-high"},"composer.json":{frameworks:["PHP","Laravel","Symfony"],slots:{packageManager:"composer",mainLanguage:"PHP"},priority:35,intelligence:"ultra-high"},"Cargo.toml":{frameworks:["Rust"],slots:{packageManager:"cargo",mainLanguage:"Rust",buildTool:"cargo"},priority:36,intelligence:"ultra-high"},"go.mod":{frameworks:["Go"],slots:{packageManager:"go modules",mainLanguage:"Go",buildTool:"go build"},priority:36,intelligence:"ultra-high"},"*.csproj":{frameworks:["C#",".NET"],slots:{packageManager:"NuGet",mainLanguage:"C#",buildTool:"dotnet"},priority:36,intelligence:"ultra-high"},"pubspec.yaml":{frameworks:["Dart"],slots:{packageManager:"pub",mainLanguage:"Dart"},priority:35,intelligence:"ultra-high"},"pom.xml":{frameworks:["Java"],slots:{packageManager:"maven",mainLanguage:"Java",buildTool:"maven"},priority:35,intelligence:"ultra-high"},"build.gradle":{frameworks:["Java","Gradle"],slots:{packageManager:"gradle",mainLanguage:"Java",buildTool:"gradle"},priority:35,intelligence:"ultra-high"},"settings.gradle":{frameworks:["Java","Gradle"],slots:{packageManager:"gradle",mainLanguage:"Java",buildTool:"gradle"},priority:34,intelligence:"high"},"settings.gradle.kts":{frameworks:["Kotlin","Gradle"],slots:{packageManager:"gradle",mainLanguage:"Kotlin",buildTool:"gradle"},priority:34,intelligence:"high"},"next.config.js":{frameworks:["Next.js"],slots:{framework:"Next.js",runtime:"Node.js",buildTool:"Next.js",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"next.config.mjs":{frameworks:["Next.js"],slots:{framework:"Next.js",runtime:"Node.js",buildTool:"Next.js",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"next.config.ts":{frameworks:["Next.js 13+"],slots:{framework:"Next.js 13+",runtime:"Node.js",buildTool:"Next.js",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"nuxt.config.js":{frameworks:["Nuxt 2"],slots:{framework:"Nuxt 2",runtime:"Node.js",buildTool:"Nuxt",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"nuxt.config.ts":{frameworks:["Nuxt 3"],slots:{framework:"Nuxt 3",runtime:"Node.js",buildTool:"Nuxt",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"svelte.config.js":{frameworks:["SvelteKit"],slots:{framework:"SvelteKit",buildTool:"Vite",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"angular.json":{frameworks:["Angular"],slots:{framework:"Angular",buildTool:"Angular CLI",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"manifest.json":{frameworks:["Chrome Extension","Browser Extension"],slots:{framework:"Chrome Extension",runtime:"Chrome/Browser",mainLanguage:"JavaScript",hosting:"Chrome Web Store",apiType:"Chrome APIs"},priority:35,intelligence:"ultra-high",confirmWith:["popup.html","background.js","content.js"]},"vue.config.js":{frameworks:["Vue"],slots:{framework:"Vue",buildTool:"Vue CLI",mainLanguage:"JavaScript"},priority:30,intelligence:"high"},"remix.config.js":{frameworks:["Remix"],slots:{framework:"Remix",runtime:"Node.js",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"gatsby-config.js":{frameworks:["Gatsby"],slots:{framework:"Gatsby",buildTool:"Gatsby",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"gatsby-config.ts":{frameworks:["Gatsby"],slots:{framework:"Gatsby",buildTool:"Gatsby",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"astro.config.mjs":{frameworks:["Astro"],slots:{framework:"Astro",buildTool:"Vite",mainLanguage:"JavaScript",server:"Node.js"},priority:30,intelligence:"high"},"redwood.toml":{frameworks:["RedwoodJS"],slots:{framework:"RedwoodJS",buildTool:"Webpack",mainLanguage:"JavaScript/TypeScript",server:"Node.js",database:"Prisma"},priority:30,intelligence:"high"},"blitz.config.ts":{frameworks:["Blitz.js"],slots:{framework:"Blitz.js",buildTool:"Next.js",mainLanguage:"TypeScript",server:"Node.js",database:"Prisma"},priority:30,intelligence:"high"},"qwik.config.ts":{frameworks:["Qwik"],slots:{framework:"Qwik",buildTool:"Vite",mainLanguage:"TypeScript",server:"Node.js"},priority:30,intelligence:"high"},"manage.py":{frameworks:["Django"],slots:{framework:"Django",backend:"Django",mainLanguage:"Python",server:"Django",apiType:"Django Views"},priority:30,intelligence:"high"},artisan:{frameworks:["Laravel"],slots:{framework:"Laravel",backend:"Laravel",mainLanguage:"PHP",server:"PHP",apiType:"Laravel Routes"},priority:30,intelligence:"high"},"mix.exs":{frameworks:["Phoenix","Elixir"],slots:{framework:"Phoenix",backend:"Phoenix",mainLanguage:"Elixir",server:"BEAM"},priority:30,intelligence:"high"},"nest-cli.json":{frameworks:["NestJS"],slots:{framework:"NestJS",backend:"NestJS",mainLanguage:"TypeScript",server:"Node.js",apiType:"REST API"},priority:30,intelligence:"high"},"strapi.config.js":{frameworks:["Strapi"],slots:{backend:"Strapi",apiType:"REST API",database:"Required",server:"Node.js"},priority:30,intelligence:"high"},Dockerfile:{frameworks:["Docker"],slots:{hosting:"Docker",connection:"Containerized"},priority:30,intelligence:"high"},"docker-compose.yml":{frameworks:["Docker Compose"],slots:{hosting:"Docker",connection:"Multi-container"},priority:30,intelligence:"high"},"docker-compose.yaml":{frameworks:["Docker Compose"],slots:{hosting:"Docker",connection:"Multi-container"},priority:30,intelligence:"high"},"kubernetes.yml":{frameworks:["Kubernetes"],slots:{hosting:"Kubernetes",connection:"Orchestrated"},priority:30,intelligence:"high"},"k8s.yaml":{frameworks:["Kubernetes"],slots:{hosting:"Kubernetes",connection:"Orchestrated"},priority:30,intelligence:"high"},"vercel.json":{frameworks:["Vercel"],slots:{hosting:"Vercel",cicd:"Vercel"},priority:30,intelligence:"high"},"netlify.toml":{frameworks:["Netlify"],slots:{hosting:"Netlify",cicd:"Netlify"},priority:30,intelligence:"high"},"render.yaml":{frameworks:["Render"],slots:{hosting:"Render",cicd:"Render"},priority:30,intelligence:"high"},"fly.toml":{frameworks:["Fly.io"],slots:{hosting:"Fly.io",cicd:"Fly.io"},priority:30,intelligence:"high"},"railway.json":{frameworks:["Railway"],slots:{hosting:"Railway",cicd:"Railway"},priority:30,intelligence:"high"},"railway.toml":{frameworks:["Railway"],slots:{hosting:"Railway",cicd:"Railway"},priority:30,intelligence:"high"},"app.yaml":{frameworks:["Google App Engine"],slots:{hosting:"Google Cloud",cicd:"Google Cloud"},priority:30,intelligence:"high"},Procfile:{frameworks:["Heroku"],slots:{hosting:"Heroku",cicd:"Heroku"},priority:30,intelligence:"high"},"vite.config.js":{frameworks:["Vite"],slots:{buildTool:"Vite"},priority:25,intelligence:"medium"},"vite.config.ts":{frameworks:["Vite"],slots:{buildTool:"Vite",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"webpack.config.js":{frameworks:["Webpack"],slots:{buildTool:"Webpack"},priority:25,intelligence:"medium"},"rollup.config.js":{frameworks:["Rollup"],slots:{buildTool:"Rollup"},priority:25,intelligence:"medium"},"esbuild.config.js":{frameworks:["esbuild"],slots:{buildTool:"esbuild"},priority:25,intelligence:"medium"},"parcel.config.js":{frameworks:["Parcel"],slots:{buildTool:"Parcel"},priority:25,intelligence:"medium"},"snowpack.config.js":{frameworks:["Snowpack"],slots:{buildTool:"Snowpack"},priority:25,intelligence:"medium"},"tsconfig.json":{frameworks:["TypeScript"],slots:{mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"jsconfig.json":{frameworks:["JavaScript"],slots:{mainLanguage:"JavaScript"},priority:20,intelligence:"medium"},"babel.config.js":{frameworks:["Babel"],slots:{buildTool:"Babel"},priority:20,intelligence:"medium"},".babelrc":{frameworks:["Babel"],slots:{buildTool:"Babel"},priority:20,intelligence:"medium"},"jest.config.js":{frameworks:["Jest"],slots:{cicd:"Jest"},priority:25,intelligence:"medium"},"jest.config.ts":{frameworks:["Jest"],slots:{cicd:"Jest",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"vitest.config.ts":{frameworks:["Vitest"],slots:{cicd:"Vitest",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"cypress.config.js":{frameworks:["Cypress"],slots:{cicd:"Cypress"},priority:25,intelligence:"medium"},"playwright.config.ts":{frameworks:["Playwright"],slots:{cicd:"Playwright",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"karma.conf.js":{frameworks:["Karma"],slots:{cicd:"Karma"},priority:20,intelligence:"medium"},"mocha.opts":{frameworks:["Mocha"],slots:{cicd:"Mocha"},priority:20,intelligence:"medium"},".rspec":{frameworks:["RSpec"],slots:{cicd:"RSpec",mainLanguage:"Ruby"},priority:25,intelligence:"medium"},"pytest.ini":{frameworks:["Pytest"],slots:{cicd:"Pytest",mainLanguage:"Python"},priority:25,intelligence:"medium"},"phpunit.xml":{frameworks:["PHPUnit"],slots:{cicd:"PHPUnit",mainLanguage:"PHP"},priority:25,intelligence:"medium"},"schema.prisma":{frameworks:["Prisma"],slots:{database:"Prisma ORM",connection:"Prisma"},priority:25,intelligence:"medium"},"drizzle.config.ts":{frameworks:["Drizzle"],slots:{database:"Drizzle ORM",connection:"Drizzle",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"ormconfig.js":{frameworks:["TypeORM"],slots:{database:"TypeORM",connection:"TypeORM"},priority:25,intelligence:"medium"},"knexfile.js":{frameworks:["Knex.js"],slots:{database:"Knex.js",connection:"Knex.js"},priority:25,intelligence:"medium"},"sequelize.config.js":{frameworks:["Sequelize"],slots:{database:"Sequelize",connection:"Sequelize"},priority:25,intelligence:"medium"},"alembic.ini":{frameworks:["Alembic"],slots:{database:"Alembic",mainLanguage:"Python"},priority:25,intelligence:"medium"},".github/workflows":{frameworks:["GitHub Actions"],slots:{cicd:"GitHub Actions"},priority:25,intelligence:"medium"},".gitlab-ci.yml":{frameworks:["GitLab CI"],slots:{cicd:"GitLab CI"},priority:25,intelligence:"medium"},Jenkinsfile:{frameworks:["Jenkins"],slots:{cicd:"Jenkins"},priority:25,intelligence:"medium"},".circleci/config.yml":{frameworks:["CircleCI"],slots:{cicd:"CircleCI"},priority:25,intelligence:"medium"},".travis.yml":{frameworks:["Travis CI"],slots:{cicd:"Travis CI"},priority:25,intelligence:"medium"},"azure-pipelines.yml":{frameworks:["Azure DevOps"],slots:{cicd:"Azure DevOps"},priority:25,intelligence:"medium"},"bitbucket-pipelines.yml":{frameworks:["Bitbucket Pipelines"],slots:{cicd:"Bitbucket Pipelines"},priority:25,intelligence:"medium"},"tailwind.config.js":{frameworks:["Tailwind CSS"],slots:{cssFramework:"Tailwind CSS"},priority:20,intelligence:"medium"},"tailwind.config.ts":{frameworks:["Tailwind CSS"],slots:{cssFramework:"Tailwind CSS",mainLanguage:"TypeScript"},priority:20,intelligence:"medium"},"postcss.config.js":{frameworks:["PostCSS"],slots:{cssFramework:"PostCSS"},priority:20,intelligence:"medium"},"uno.config.ts":{frameworks:["UnoCSS"],slots:{cssFramework:"UnoCSS",mainLanguage:"TypeScript"},priority:20,intelligence:"medium"},"styled-components.config.js":{frameworks:["styled-components"],slots:{cssFramework:"styled-components",uiLibrary:"styled-components"},priority:20,intelligence:"medium"},"emotion.config.js":{frameworks:["Emotion"],slots:{cssFramework:"Emotion",uiLibrary:"Emotion"},priority:20,intelligence:"medium"},"metro.config.js":{frameworks:["React Native"],slots:{framework:"React Native",mainLanguage:"JavaScript"},priority:25,intelligence:"medium"},"expo.config.js":{frameworks:["Expo"],slots:{framework:"React Native",buildTool:"Expo"},priority:25,intelligence:"medium"},"app.json":{frameworks:["React Native","Expo"],slots:{framework:"React Native"},priority:20,intelligence:"medium",confirmWith:["expo"]},"capacitor.config.ts":{frameworks:["Capacitor"],slots:{framework:"Capacitor",mainLanguage:"TypeScript"},priority:25,intelligence:"medium"},"ionic.config.json":{frameworks:["Ionic"],slots:{framework:"Ionic",uiLibrary:"Ionic"},priority:25,intelligence:"medium"},"nx.json":{frameworks:["Nx"],slots:{buildTool:"Nx"},priority:25,intelligence:"medium"},"turbo.json":{frameworks:["Turborepo"],slots:{buildTool:"Turborepo"},priority:25,intelligence:"medium"},"lerna.json":{frameworks:["Lerna"],slots:{buildTool:"Lerna"},priority:25,intelligence:"medium"},"rush.json":{frameworks:["Rush"],slots:{buildTool:"Rush"},priority:25,intelligence:"medium"},"pnpm-workspace.yaml":{frameworks:["pnpm workspaces"],slots:{packageManager:"pnpm",buildTool:"pnpm workspaces"},priority:25,intelligence:"medium"},"*.svelte":{frameworks:["Svelte","SvelteKit"],slots:{framework:"Svelte"},priority:15,intelligence:"low"},"*.vue":{frameworks:["Vue"],slots:{framework:"Vue"},priority:15,intelligence:"low"},"*.jsx":{frameworks:["React"],slots:{framework:"React",mainLanguage:"JavaScript"},priority:15,intelligence:"low"},"*.ts":{frameworks:["TypeScript"],slots:{mainLanguage:"TypeScript"},priority:15,intelligence:"low"},"*.tsx":{frameworks:["React","TypeScript"],slots:{framework:"React",mainLanguage:"TypeScript"},priority:15,intelligence:"low"},"*.py":{frameworks:["Python"],slots:{mainLanguage:"Python"},priority:15,intelligence:"low"},"*.rb":{frameworks:["Ruby"],slots:{mainLanguage:"Ruby"},priority:15,intelligence:"low"},"*.php":{frameworks:["PHP"],slots:{mainLanguage:"PHP"},priority:15,intelligence:"low"},"*.java":{frameworks:["Java"],slots:{mainLanguage:"Java"},priority:15,intelligence:"low"},"*.kt":{frameworks:["Kotlin"],slots:{mainLanguage:"Kotlin"},priority:15,intelligence:"low"},"*.swift":{frameworks:["Swift"],slots:{mainLanguage:"Swift"},priority:15,intelligence:"low"},"*.go":{frameworks:["Go"],slots:{mainLanguage:"Go"},priority:15,intelligence:"low"},"*.rs":{frameworks:["Rust"],slots:{mainLanguage:"Rust"},priority:15,intelligence:"low"},"*.dart":{frameworks:["Flutter","Dart"],slots:{mainLanguage:"Dart"},priority:15,intelligence:"low"},"*.ex":{frameworks:["Elixir"],slots:{mainLanguage:"Elixir"},priority:15,intelligence:"low"},"*.exs":{frameworks:["Elixir"],slots:{mainLanguage:"Elixir"},priority:15,intelligence:"low"},"*.scala":{frameworks:["Scala"],slots:{mainLanguage:"Scala"},priority:15,intelligence:"low"},"*.clj":{frameworks:["Clojure"],slots:{mainLanguage:"Clojure"},priority:15,intelligence:"low"},"*.lua":{frameworks:["Lua"],slots:{mainLanguage:"Lua"},priority:15,intelligence:"low"},"*.r":{frameworks:["R"],slots:{mainLanguage:"R"},priority:15,intelligence:"low"},"*.R":{frameworks:["R"],slots:{mainLanguage:"R"},priority:15,intelligence:"low"},"*.jl":{frameworks:["Julia"],slots:{mainLanguage:"Julia"},priority:15,intelligence:"low"},"*.nim":{frameworks:["Nim"],slots:{mainLanguage:"Nim"},priority:15,intelligence:"low"},"*.zig":{frameworks:["Zig"],slots:{mainLanguage:"Zig"},priority:15,intelligence:"low"},"build.zig":{frameworks:["Zig"],slots:{packageManager:"Zig Package Manager",mainLanguage:"Zig",buildTool:"zig build",framework:"Zig",build:"zig build"},priority:35,intelligence:"ultra-high"},"openapi.json":{frameworks:["OpenAPI"],slots:{apiType:"REST API",backend:"API Server"},priority:30,intelligence:"high"},"openapi.yaml":{frameworks:["OpenAPI"],slots:{apiType:"REST API",backend:"API Server"},priority:30,intelligence:"high"},"swagger.json":{frameworks:["Swagger"],slots:{apiType:"REST API",backend:"API Server"},priority:30,intelligence:"high"},"graphql.schema":{frameworks:["GraphQL"],slots:{apiType:"GraphQL",backend:"GraphQL Server"},priority:30,intelligence:"high"},"schema.graphql":{frameworks:["GraphQL"],slots:{apiType:"GraphQL",backend:"GraphQL Server"},priority:30,intelligence:"high"},".graphqlconfig":{frameworks:["GraphQL"],slots:{apiType:"GraphQL"},priority:25,intelligence:"medium"},"redux.config.js":{frameworks:["Redux"],slots:{stateManagement:"Redux"},priority:20,intelligence:"medium"},"mobx.config.js":{frameworks:["MobX"],slots:{stateManagement:"MobX"},priority:20,intelligence:"medium"},"vuex.config.js":{frameworks:["Vuex"],slots:{stateManagement:"Vuex",framework:"Vue"},priority:20,intelligence:"medium"},"pinia.config.js":{frameworks:["Pinia"],slots:{stateManagement:"Pinia",framework:"Vue"},priority:20,intelligence:"medium"},"zustand.config.js":{frameworks:["Zustand"],slots:{stateManagement:"Zustand"},priority:20,intelligence:"medium"},".eslintrc.js":{frameworks:["ESLint"],slots:{},priority:15,intelligence:"low"},".eslintrc.json":{frameworks:["ESLint"],slots:{},priority:15,intelligence:"low"},".prettierrc":{frameworks:["Prettier"],slots:{},priority:15,intelligence:"low"},".prettierrc.json":{frameworks:["Prettier"],slots:{},priority:15,intelligence:"low"},"biome.json":{frameworks:["Biome"],slots:{},priority:15,intelligence:"low"},".editorconfig":{frameworks:["EditorConfig"],slots:{},priority:10,intelligence:"low"},"serverless.yml":{frameworks:["Serverless Framework"],slots:{hosting:"AWS Lambda/Azure/GCP",backend:"Serverless",apiType:"API Gateway"},priority:30,intelligence:"high"},"serverless.yaml":{frameworks:["Serverless Framework"],slots:{hosting:"AWS Lambda/Azure/GCP",backend:"Serverless",apiType:"API Gateway"},priority:30,intelligence:"high"},"sam.yaml":{frameworks:["AWS SAM"],slots:{hosting:"AWS Lambda",backend:"AWS SAM",cicd:"AWS SAM CLI"},priority:30,intelligence:"high"},"template.yaml":{frameworks:["AWS SAM","CloudFormation"],slots:{hosting:"AWS",backend:"AWS SAM/CloudFormation",cicd:"AWS"},priority:25,intelligence:"medium",confirmWith:["samconfig.toml"]},"amplify.yml":{frameworks:["AWS Amplify"],slots:{hosting:"AWS Amplify",backend:"AWS Amplify",cicd:"AWS Amplify"},priority:30,intelligence:"high"},Podfile:{frameworks:["CocoaPods","iOS"],slots:{packageManager:"CocoaPods",mainLanguage:"Swift/Objective-C",framework:"iOS Native"},priority:30,intelligence:"high"},"build.gradle.kts":{frameworks:["Kotlin","Gradle"],slots:{packageManager:"gradle",mainLanguage:"Kotlin",buildTool:"gradle"},priority:35,intelligence:"ultra-high"},"*.ipynb":{frameworks:["Jupyter","Python"],slots:{mainLanguage:"Python",framework:"Jupyter Notebook"},priority:30,intelligence:"high"},MLproject:{frameworks:["MLflow"],slots:{mainLanguage:"Python",framework:"MLflow",backend:"MLflow",cicd:"MLflow"},priority:30,intelligence:"high"},"dvc.yaml":{frameworks:["DVC","Data Version Control"],slots:{mainLanguage:"Python",framework:"DVC",cicd:"DVC Pipelines"},priority:30,intelligence:"high"},"dvc.lock":{frameworks:["DVC"],slots:{framework:"DVC"},priority:20,intelligence:"medium"},"wrangler.toml":{frameworks:["Cloudflare Workers","Cloudflare"],slots:{hosting:"Cloudflare Workers",backend:"Cloudflare Workers",runtime:"V8 Isolates"},priority:30,intelligence:"high"},"deno.json":{frameworks:["Deno"],slots:{runtime:"Deno",mainLanguage:"TypeScript",packageManager:"Deno"},priority:30,intelligence:"high"},"bun.lockb":{frameworks:["Bun"],slots:{runtime:"Bun",packageManager:"Bun",mainLanguage:"TypeScript/JavaScript"},priority:30,intelligence:"high"},"codecov.yml":{frameworks:["Codecov"],slots:{cicd:"Codecov"},priority:25,intelligence:"high"},"dependabot.yml":{frameworks:["Dependabot","GitHub"],slots:{cicd:"Dependabot"},priority:25,intelligence:"high"},"renovate.json":{frameworks:["Renovate"],slots:{cicd:"Renovate"},priority:25,intelligence:"high"},Makefile:{frameworks:["Make","GNU Make"],slots:{buildTool:"Make"},priority:30,intelligence:"high"},"CMakeLists.txt":{frameworks:["CMake","C","C++"],slots:{buildTool:"CMake",mainLanguage:"C/C++"},priority:30,intelligence:"high"},"meson.build":{frameworks:["Meson","C","C++"],slots:{buildTool:"Meson",mainLanguage:"C/C++"},priority:30,intelligence:"high"},"*.c":{frameworks:["C"],slots:{mainLanguage:"C"},priority:30,intelligence:"high"},"*.cpp":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:30,intelligence:"high"},"*.cc":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:30,intelligence:"high"},"*.cxx":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:25,intelligence:"high"},"*.h":{frameworks:["C","C++"],slots:{mainLanguage:"C/C++"},priority:25,intelligence:"high"},"*.hpp":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:25,intelligence:"high"},"*.hxx":{frameworks:["C++"],slots:{mainLanguage:"C++"},priority:20,intelligence:"medium"},".env":{frameworks:[],slots:{},priority:20,intelligence:"medium"},".env.example":{frameworks:[],slots:{},priority:25,intelligence:"high"},".env.local":{frameworks:[],slots:{},priority:20,intelligence:"medium"},".env.development":{frameworks:[],slots:{},priority:20,intelligence:"medium"},".env.production":{frameworks:[],slots:{},priority:20,intelligence:"medium"},"skaffold.yaml":{frameworks:["Skaffold","Kubernetes"],slots:{hosting:"Kubernetes",cicd:"Skaffold"},priority:30,intelligence:"high"},"Chart.yaml":{frameworks:["Helm","Kubernetes"],slots:{hosting:"Kubernetes",backend:"Helm"},priority:30,intelligence:"high"},"values.yaml":{frameworks:["Helm","Kubernetes"],slots:{hosting:"Kubernetes"},priority:25,intelligence:"high",confirmWith:["Chart.yaml"]},"pulumi.yaml":{frameworks:["Pulumi"],slots:{hosting:"Cloud",cicd:"Pulumi"},priority:30,intelligence:"high"},"Pulumi.yaml":{frameworks:["Pulumi"],slots:{hosting:"Cloud",cicd:"Pulumi"},priority:30,intelligence:"high"},"terragrunt.hcl":{frameworks:["Terragrunt","Terraform"],slots:{hosting:"Cloud",cicd:"Terragrunt"},priority:30,intelligence:"high"},"ansible.yml":{frameworks:["Ansible"],slots:{cicd:"Ansible"},priority:30,intelligence:"high"},"playbook.yml":{frameworks:["Ansible"],slots:{cicd:"Ansible"},priority:25,intelligence:"high"},"*.cs":{frameworks:["C#",".NET","Unity"],slots:{mainLanguage:"C#"},priority:30,intelligence:"high"},"*.m":{frameworks:["Objective-C","iOS"],slots:{mainLanguage:"Objective-C"},priority:25,intelligence:"high"},".nvmrc":{frameworks:["Node.js","nvm"],slots:{runtime:"Node.js"},priority:25,intelligence:"high"},".tool-versions":{frameworks:["asdf"],slots:{},priority:25,intelligence:"high"},".ruby-version":{frameworks:["Ruby","rbenv"],slots:{mainLanguage:"Ruby",runtime:"Ruby"},priority:25,intelligence:"high"},".python-version":{frameworks:["Python","pyenv"],slots:{mainLanguage:"Python",runtime:"Python"},priority:25,intelligence:"high"},".dockerignore":{frameworks:["Docker"],slots:{},priority:20,intelligence:"medium"},".gitattributes":{frameworks:["Git"],slots:{},priority:15,intelligence:"low"},".npmrc":{frameworks:["npm","Node.js"],slots:{packageManager:"npm"},priority:20,intelligence:"medium"},"sonar-project.properties":{frameworks:["SonarQube","SonarCloud"],slots:{cicd:"SonarQube"},priority:25,intelligence:"high"},"*.fs":{frameworks:["F#",".NET"],slots:{mainLanguage:"F#"},priority:25,intelligence:"high"},"*.mm":{frameworks:["Objective-C++","iOS","macOS"],slots:{mainLanguage:"Objective-C++"},priority:25,intelligence:"high"},"build.zig.zon":{frameworks:["Zig"],slots:{mainLanguage:"Zig",packageManager:"Zig Package Manager",buildTool:"zig build"},priority:35,intelligence:"ultra-high"},"gleam.toml":{frameworks:["Gleam","BEAM","Erlang"],slots:{mainLanguage:"Gleam",runtime:"BEAM",packageManager:"Gleam"},priority:30,intelligence:"high"},"bunfig.toml":{frameworks:["Bun"],slots:{runtime:"Bun",packageManager:"Bun",buildTool:"Bun"},priority:30,intelligence:"high"},"mise.toml":{frameworks:["mise"],slots:{},priority:25,intelligence:"high"},".mise.toml":{frameworks:["mise"],slots:{},priority:25,intelligence:"high"},"manifest.toml":{frameworks:["Flox","Nix"],slots:{},priority:25,intelligence:"high",confirmWith:[".flox"]},justfile:{frameworks:["Just"],slots:{buildTool:"Just"},priority:25,intelligence:"high"},".pre-commit-config.yaml":{frameworks:["pre-commit"],slots:{cicd:"pre-commit"},priority:25,intelligence:"high"},"CLAUDE.md":{frameworks:["Claude Code"],slots:{},priority:30,intelligence:"high",confirmWith:[".claude"]}};import{existsSync as Y9,readFileSync as nH,readdirSync as oH}from"fs";import{join as z3}from"path";var d0={version:2,_doc:"SINGLE SOURCE of Dart/Flutter detection KNOWLEDGE (A+B hybrid, the Truth-is-faf-cli spec). faf-cli imports this directly; faf-python-sdk vendors a synced copy (phase 2); MCPs compose it. Bolster Dart/Flutter by editing THIS file. Logic stays in dart.ts. Refreshed 2026-08-01 (knowledge v2) — community receipt on top of 6.13.0 Dart Edition.",flutterDeps:["flutter"],mcpDeps:["dart_mcp","mcp_server","mcp_dart","dart_mcp_server","mcp","dart_mcpserver"],serverFrameworks:[["serverpod","Serverpod"],["dart_frog","Dart Frog"],["conduit","Conduit"],["angel3_framework","Angel3"],["alfred","Alfred"],["shelf","Shelf"],["jaspr","Jaspr"],["relic","Relic"]],stateManagement:[["flutter_riverpod","Riverpod"],["hooks_riverpod","Riverpod"],["riverpod_annotation","Riverpod"],["riverpod","Riverpod"],["flutter_bloc","Bloc"],["bloc","Bloc"],["provider","Provider"],["get","GetX"],["flutter_mobx","MobX"],["mobx","MobX"],["signals","Signals"],["flutter_hooks","Hooks"]],routing:[["go_router","go_router"],["auto_route","auto_route"],["beamer","Beamer"],["routemaster","Routemaster"]]};var tH=d0.flutterDeps,eH=d0.mcpDeps,$q=d0.serverFrameworks,Zq=d0.stateManagement,Uq=d0.routing;function Xq($){let Z=new Set,U=!1;for(let X of $.split(`
215
+ `)){if(/^(dependencies|dev_dependencies|dependency_overrides):\s*$/.test(X)){U=!0;continue}if(/^\S/.test(X))U=!1;if(U){let Q=X.match(/^\s{2}([a-zA-Z0-9_]+):/);if(Q)Z.add(Q[1].toLowerCase())}}return Z}function T$($){let Z=z3($,"pubspec.yaml");if(!Y9(Z))return null;let U;try{U=nH(Z,"utf-8")}catch{return null}let X=Xq(U),Q=(F)=>X.has(F.toLowerCase()),z=tH.some(Q)||/^flutter:\s*$/m.test(U)||/\bsdk:\s*flutter\b/.test(U),J=eH.find(Q),H=$q.find(([F])=>Q(F)),q=Zq.find(([F])=>Q(F)),Y=q?q[1]:"",G=Uq.find(([F])=>Q(F)),_=G?G[1]:"",B=Q("flutter_test")?"flutter_test":Q("test")?"test":"",O=/^executables:\s*$/m.test(U),D=!1;try{D=oH(z3($,"bin")).some((F)=>F.endsWith(".dart"))}catch{}let V=O||D,W,I="",L;if(z)if(I="Flutter",Y9(z3($,"lib","main.dart"))||/^publish_to:\s*['"]?none\b/m.test(U))W="mobile",L="pubspec.yaml (Flutter app)";else W="library",L="pubspec.yaml (Flutter package)";else if(J)W="mcp",L=`pubspec.yaml + ${J} (Dart MCP server)`;else if(H)W="backend",I=H[1],L=`pubspec.yaml + ${H[0]} (Dart backend)`;else if(V)W="cli",L=O?"pubspec.yaml executables: (Dart CLI)":"pubspec.yaml + bin/*.dart (Dart CLI)";else W="library",L="pubspec.yaml (Dart package)";return{appType:W,isFlutter:z,framework:I,stateManagement:Y,routing:_,testing:B,found:L}}import{existsSync as J3,readFileSync as B9,readdirSync as G9,statSync as zq}from"fs";import{join as w$}from"path";var N$={version:1,_doc:"SINGLE SOURCE of Go detection KNOWLEDGE (A+B hybrid, Truth-is-faf-cli). faf-cli imports this directly; SDKs/MCPs compose it. Bolster Go by editing THIS file. Logic stays in go.ts. Content-aware: go.mod ≠ one bucket — backend · CLI · MCP · library. 2026-08-01 initial (Dart composition pattern).",mcpModules:["github.com/mark3labs/mcp-go","github.com/modelcontextprotocol/go-sdk","github.com/metoro-io/mcp-golang","github.com/ThinkInAIXYZ/go-mcp"],serverFrameworks:[["github.com/gin-gonic/gin","Gin"],["github.com/labstack/echo","Echo"],["github.com/labstack/echo/v4","Echo"],["github.com/gofiber/fiber","Fiber"],["github.com/gofiber/fiber/v2","Fiber"],["github.com/go-chi/chi","Chi"],["github.com/go-chi/chi/v5","Chi"],["github.com/gorilla/mux","Gorilla Mux"],["github.com/gofiber/fiber/v3","Fiber"],["google.golang.org/grpc","gRPC"],["connectrpc.com/connect","Connect"],["github.com/go-kratos/kratos","Kratos"],["github.com/go-kratos/kratos/v2","Kratos"],["github.com/zeromicro/go-zero","go-zero"],["github.com/cloudwego/hertz","Hertz"]],cliFrameworks:[["github.com/spf13/cobra","Cobra"],["github.com/urfave/cli","urfave/cli"],["github.com/urfave/cli/v2","urfave/cli"],["github.com/alecthomas/kingpin","Kingpin"],["github.com/alecthomas/kong","Kong"]]};var Jq=N$.mcpModules,Hq=N$.serverFrameworks,qq=N$.cliFrameworks;function Yq($){let Z=new Set,U=!1;for(let X of $.split(`
216
+ `)){let Q=X.replace(/\/\/.*$/,"").trim();if(!Q)continue;if(/^require\s*\(\s*$/.test(Q)){U=!0;continue}if(U){if(Q===")"){U=!1;continue}let J=Q.match(/^(\S+)/);if(J)Z.add(J[1].toLowerCase());continue}let z=Q.match(/^require\s+(\S+)/);if(z&&z[1]!=="(")Z.add(z[1].toLowerCase())}return Z}function V9($,Z){let U=Z.toLowerCase();for(let X of $)if(X===U||X.startsWith(`${U}/`))return!0;return!1}function _9($,Z){let U;for(let X of Z){if(!V9($,X[0]))continue;if(!U||X[0].length>U[0].length)U=X}return U}function Gq($,Z){let U;for(let X of Z){if(!V9($,X))continue;if(!U||X.length>U.length)U=X}return U}function _q($){let Z=$.match(/^module\s+(\S+)/m);return Z?Z[1]:""}function Bq($){let Z=w$($,"cmd");if(!J3(Z))return!1;try{for(let U of G9(Z)){let X=w$(Z,U);try{if(zq(X).isDirectory()){if(G9(X).some((z)=>z.endsWith(".go")))return!0}else if(U.endsWith(".go"))return!0}catch{}}}catch{}return!1}function Vq($){let Z=w$($,"main.go");if(!J3(Z))return!1;try{let U=B9(Z,"utf-8");return/^package\s+main\b/m.test(U)}catch{return!1}}function C$($){let Z=w$($,"go.mod");if(!J3(Z))return null;let U;try{U=B9(Z,"utf-8")}catch{return null}let X=_q(U),Q=Yq(U),z=Gq(Q,Jq),J=_9(Q,Hq),H=_9(Q,qq),q=Bq($),Y=Vq($),G,_="",B;if(z)G="mcp",B=`go.mod + ${z} (Go MCP server)`;else if(J)G="backend",_=J[1],B=`go.mod + ${J[0]} (Go backend)`;else if(H)G="cli",_=H[1],B=`go.mod + ${H[0]} (Go CLI)`;else if(q)G="cli",B="go.mod + cmd/ (Go CLI layout)";else if(Y&&!J)G="cli",B="go.mod + main.go package main (Go CLI)";else G="library",B="go.mod (Go module)";return{appType:G,modulePath:X,framework:_,found:B}}import{existsSync as Wq,readFileSync as Dq,readdirSync as Iq}from"fs";import{join as Lq}from"path";var F0={version:1,_doc:"SINGLE SOURCE of C# /.NET detection KNOWLEDGE (Truth-is-faf-cli). faf-cli imports this; SDKs/MCPs compose it. Bolster C# by editing THIS file. Logic stays in csharp.ts. Content-aware: .csproj alone ≠ type — Sdk first, then props/packages. Kill line: .csproj alone ≠ type. 2026-08-01 initial.",mcpPackages:["ModelContextProtocol","ModelContextProtocol.AspNetCore","ModelContextProtocol.Core","ModelContextProtocol.Extensions.Tasks","ModelContextProtocol.Extensions.Apps"],cliPackages:[["System.CommandLine","System.CommandLine"],["Spectre.Console.Cli","Spectre.Console"],["Spectre.Console","Spectre.Console"],["McMaster.Extensions.CommandLineUtils","McMaster"]],testPackages:[["Microsoft.NET.Test.Sdk","VSTest"],["xunit.v3","xUnit"],["xunit","xUnit"],["NUnit","NUnit"],["MSTest.TestFramework","MSTest"],["MSTest","MSTest"]],grpcServerPackages:["Grpc.AspNetCore"],specializedSdks:[["Microsoft.NET.Sdk.Web","web","ASP.NET Core"],["Microsoft.NET.Sdk.Worker","worker","Worker"],["Microsoft.NET.Sdk.BlazorWebAssembly","blazor-wasm","Blazor WebAssembly"],["Microsoft.NET.Sdk.Razor","razor-lib","Razor Class Library"],["MSTest.Sdk","test","MSTest"],["Aspire.AppHost.Sdk","aspire","Aspire AppHost"]],baseSdk:"Microsoft.NET.Sdk"};var Rq=F0.mcpPackages.map(($)=>$.toLowerCase()),Mq=F0.cliPackages.map(([$,Z])=>[$.toLowerCase(),Z]),Kq=F0.testPackages.map(([$,Z])=>[$.toLowerCase(),Z]),Fq=F0.grpcServerPackages.map(($)=>$.toLowerCase()),Pq=F0.specializedSdks,O9=F0.baseSdk.toLowerCase();function Aq($){let Z=$.match(/<Project\b[^>]*\bSdk\s*=\s*"([^"/]+)(?:\/[^"]*)?"/i),U=$.match(/<Sdk\b[^>]*\bName\s*=\s*"([^"]+)"/i),X=(Z?.[1]||U?.[1]||"").trim(),Q=($.match(/<OutputType>\s*([^<]+?)\s*<\/OutputType>/i)?.[1]||"").trim(),z=$.match(/<TargetFramework>\s*([^<]+?)\s*<\/TargetFramework>/i)?.[1],H=($.match(/<TargetFrameworks>\s*([^<]+?)\s*<\/TargetFrameworks>/i)?.[1]||z||"").trim(),q=/<IsTestProject>\s*true\s*<\/IsTestProject>/i.test($),Y=/<UseMaui>\s*true\s*<\/UseMaui>/i.test($),G=/<UseWPF>\s*true\s*<\/UseWPF>/i.test($),_=/<UseWindowsForms>\s*true\s*<\/UseWindowsForms>/i.test($),B=new Set;for(let D of $.matchAll(/<PackageReference\b[^>]*\bInclude\s*=\s*"([^"]+)"/gi))B.add(D[1].toLowerCase());for(let D of $.matchAll(/<PackageReference\s+Include\s*=\s*"([^"]+)"/gi))B.add(D[1].toLowerCase());let O=new Set;for(let D of $.matchAll(/<FrameworkReference\b[^>]*\bInclude\s*=\s*"([^"]+)"/gi))O.add(D[1].toLowerCase());return{sdk:X,outputType:Q,targetFramework:H,isTestProject:q,useMaui:Y,useWpf:G,useWindowsForms:_,packages:B,frameworkRefs:O}}function H3($,Z){let U=Z.toLowerCase();if($.has(U))return!0;for(let X of $)if(X===U||X.startsWith(`${U}.`))return!0;return!1}function W9($,Z){let U;for(let[X,Q]of Z){if(!H3($,X))continue;if(!U||X.length>U[0].length)U=[X,Q]}return U}function Tq($){let Z;for(let U of Rq){if(!H3($,U))continue;if(!Z||U.length>Z.length)Z=U}for(let U of $)if(U==="modelcontextprotocol"||U.startsWith("modelcontextprotocol.")){if(!Z||U.length>Z.length)Z=U}return Z}function Nq($){let Z=$.toLowerCase();if(!Z)return;let U;for(let X of Pq){let Q=X[0].toLowerCase();if(Z===Q||Z.startsWith(`${Q}/`)){if(!U||Q.length>U[0].length)U=X}}return U}function b$($){let Z=$.toLowerCase();return Z==="exe"||Z==="winexe"}function wq($,Z){if($==="mcp")return 0;if($==="mobile")return 1;if($==="backend")return 2;if($==="cli")return 3;if(Z&&Z!=="")return 4;return 5}function Cq($,Z){let U=Z.replace(/\.csproj$/i,""),{sdk:X,packages:Q,frameworkRefs:z,outputType:J}=$,H,q="",Y,G=Tq(Q),_=Nq(X),B=W9(Q,Kq),O=W9(Q,Mq),D=Fq.some((W)=>H3(Q,W)),V=z.has("microsoft.aspnetcore.app");if(G)H="mcp",q="MCP",Y=`${Z} + ${G} (C# MCP server)`;else if($.isTestProject||_?.[1]==="test"||B)H="library",q=B?.[1]||(_?.[1]==="test"?_[2]:"Test"),Y=`${Z} + test (${q})`;else if($.useMaui)H="mobile",q="MAUI",Y=`${Z} + UseMaui (MAUI)`;else if($.useWpf||$.useWindowsForms)H="backend",q=$.useWpf&&$.useWindowsForms?"WPF+WinForms":$.useWpf?"WPF":"Windows Forms",Y=`${Z} + ${q}`;else if(_?.[1]==="web")H="backend",q=D?"gRPC":_[2],Y=`${Z} + Sdk=${_[0]}${D?" + Grpc.AspNetCore":""} (ASP.NET Core)`;else if(_?.[1]==="worker")H="backend",q=_[2],Y=`${Z} + Sdk=${_[0]} (Worker)`;else if(_?.[1]==="blazor-wasm")H="backend",q=_[2],Y=`${Z} + Sdk=${_[0]} (Blazor WASM)`;else if(_?.[1]==="aspire")H="backend",q=_[2],Y=`${Z} + Sdk=${_[0]} (Aspire)`;else if(_?.[1]==="razor-lib")H="library",q=_[2],Y=`${Z} + Sdk=${_[0]} (Razor class library)`;else if(V&&b$(J))H="backend",q="ASP.NET Core",Y=`${Z} + FrameworkReference Microsoft.AspNetCore.App (host)`;else if(V&&!b$(J))H="library",q="ASP.NET Core",Y=`${Z} + FrameworkReference Microsoft.AspNetCore.App (web library)`;else if(O&&(b$(J)||!J))H="cli",q=O[1],Y=`${Z} + ${O[0]} (C# CLI)`;else if(b$(J))H="cli",Y=`${Z} + OutputType=Exe (C# console)`;else{H="library";let W=X?` Sdk=${X}`:"";if(Y=`${Z}${W} (C# class library)`.replace(" Sdk=Microsoft.NET.Sdk",""),!X||X.toLowerCase()===O9||X.toLowerCase().startsWith(`${O9}/`))Y=`${Z} (C# class library)`}return{appType:H,projectName:U,targetFramework:$.targetFramework,sdk:X||"Microsoft.NET.Sdk",framework:q,found:Y}}function A1($){if(!Wq($))return[];try{return Iq($).filter((Z)=>Z.toLowerCase().endsWith(".csproj")).sort()}catch{return[]}}function S$($){let Z=A1($);if(Z.length===0)return null;let U=null,X=999;for(let Q of Z){let z=Lq($,Q),J;try{J=Dq(z,"utf-8")}catch{continue}let H=Aq(J),q=Cq(H,Q),Y=wq(q.appType,q.framework);if(!U||Y<X)U=q,X=Y}return U}import{existsSync as P0,readFileSync as Sq,readdirSync as Eq,statSync as jq}from"fs";import{join as l}from"path";var i={version:1,_doc:"SINGLE SOURCE of JVM (Java/Kotlin) detection KNOWLEDGE (Truth-is-faf-cli). faf-cli imports this; SDKs/MCPs compose it. Bolster JVM by editing THIS file. Logic stays in jvm.ts. Kill line: pom / gradle alone ≠ type. Content-aware: plugins · parents · packaging · deps · version catalogs. One brand JVM — Android/KMP are facets, not a second Kotlin Edition. 2026-08-03 initial (post-intel).",mcpArtifacts:["io.modelcontextprotocol.sdk:mcp","io.modelcontextprotocol.sdk:mcp-core","io.modelcontextprotocol.sdk:mcp-spring-webflux","io.modelcontextprotocol.sdk:mcp-spring-webmvc","org.springframework.ai:spring-ai-starter-mcp-server","org.springframework.ai:spring-ai-starter-mcp-server-webmvc","org.springframework.ai:spring-ai-starter-mcp-server-webflux","org.springframework.ai:spring-ai-starter-mcp-client","org.springframework.ai:spring-ai-mcp-server-spring-boot-starter","org.springframework.ai:spring-ai-mcp-client-spring-boot-starter","io.modelcontextprotocol:kotlin-sdk","io.modelcontextprotocol.kotlin:mcp"],webPlugins:[["org.springframework.boot","Spring Boot"],["io.quarkus","Quarkus"],["io.quarkus.gradle.plugin","Quarkus"],["io.micronaut.application","Micronaut"],["io.micronaut.library","Micronaut"]],webParents:[["org.springframework.boot:spring-boot-starter-parent","Spring Boot"],["io.quarkus.platform:quarkus-bom","Quarkus"],["io.micronaut.platform:micronaut-parent","Micronaut"]],webArtifacts:[["org.springframework.boot:spring-boot-starter-web","Spring Boot"],["org.springframework.boot:spring-boot-starter-webflux","Spring Boot"],["org.springframework.boot:spring-boot-starter","Spring Boot"],["io.quarkus:quarkus-core","Quarkus"],["io.micronaut:micronaut-http-server-netty","Micronaut"],["io.ktor:ktor-server-core","Ktor"],["io.ktor:ktor-server-netty","Ktor"],["io.ktor:ktor-server-cio","Ktor"]],androidPlugins:["com.android.application","com.android.library","com.android.kotlin.multiplatform.library"],kmpPlugins:["org.jetbrains.kotlin.multiplatform","kotlin-multiplatform"],jvmKotlinPlugins:["org.jetbrains.kotlin.jvm","kotlin-jvm","org.jetbrains.kotlin.android","kotlin-android"],cliPlugins:[["org.gradle.application","application"],["application","application"]],cliArtifacts:[["info.picocli:picocli","Picocli"],["com.github.ajalt.clikt:clikt","Clikt"],["com.github.ajalt.clikt:clikt-jvm","Clikt"]],libraryPlugins:["java-library","org.gradle.java-library"]};var gq=i.mcpArtifacts.map(($)=>$.toLowerCase()),xq=i.webPlugins.map(([$,Z])=>[$.toLowerCase(),Z]),hq=i.webParents.map(([$,Z])=>[$.toLowerCase(),Z]),yq=i.webArtifacts.map(([$,Z])=>[$.toLowerCase(),Z]),yB=i.androidPlugins.map(($)=>$.toLowerCase()),fq=i.kmpPlugins.map(($)=>$.toLowerCase()),uq=i.jvmKotlinPlugins.map(($)=>$.toLowerCase()),kq=i.cliPlugins.map(([$,Z])=>[$.toLowerCase(),Z]),vq=i.cliArtifacts.map(([$,Z])=>[$.toLowerCase(),Z]),mq=i.libraryPlugins.map(($)=>$.toLowerCase()),pq=["pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts"];function q3($){return pq.some((Z)=>P0(l($,Z)))}function N1($){try{return Sq($,"utf-8")}catch{return null}}function lq($){let Z=new Map,U=new Map,X="";for(let Q of $.split(`
217
+ `)){let z=Q.replace(/#.*$/,"").trim();if(!z)continue;let J=z.match(/^\[([^\]]+)\]$/);if(J){X=J[1].trim().toLowerCase();continue}let H=z.match(/^([A-Za-z0-9_.-]+)\s*=\s*\{[^}]*\bid\s*=\s*"([^"]+)"/);if(H&&(X==="plugins"||X.endsWith(".plugins"))){Z.set(H[1].replace(/-/g,".").toLowerCase(),H[2].toLowerCase()),Z.set(H[1].toLowerCase(),H[2].toLowerCase());continue}let q=z.match(/^([A-Za-z0-9_.-]+)\s*=\s*\{[^}]*\bmodule\s*=\s*"([^"]+)"/);if(q&&(X==="libraries"||X.endsWith(".libraries"))){let _=q[1].toLowerCase();U.set(_,q[2].toLowerCase()),U.set(_.replace(/-/g,"."),q[2].toLowerCase());continue}let Y=z.match(/^([A-Za-z0-9_.-]+)\s*=\s*\{[^}]*\bgroup\s*=\s*"([^"]+)"[^}]*\bname\s*=\s*"([^"]+)"/);if(Y&&(X==="libraries"||X.endsWith(".libraries"))){let _=`${Y[2]}:${Y[3]}`.toLowerCase(),B=Y[1].toLowerCase();U.set(B,_),U.set(B.replace(/-/g,"."),_);continue}let G=z.match(/^([A-Za-z0-9_.-]+)\s*=\s*"([^"]+)"/);if(G){let _=G[1].toLowerCase(),B=G[2];if(X==="plugins"||X.endsWith(".plugins")){let O=B.split(":")[0].toLowerCase();Z.set(_,O),Z.set(_.replace(/-/g,"."),O)}else if(X==="libraries"||X.endsWith(".libraries")){let O=B.split(":");if(O.length>=2){let D=`${O[0]}:${O[1]}`.toLowerCase();U.set(_,D),U.set(_.replace(/-/g,"."),D)}}}}return{plugins:Z,libraries:U}}function dq($){let Z=l($,"gradle","libs.versions.toml");if(!P0(Z))return{plugins:new Map,libraries:new Map};let U=N1(Z);if(!U)return{plugins:new Map,libraries:new Map};return lq(U)}function cq($){let Z=[];for(let U of $.matchAll(/include\s*\(\s*([^)]+)\)/g))for(let X of U[1].split(",")){let Q=X.replace(/['":\s]/g,"").replace(/^:/,"");if(Q)Z.push(Q.replace(/:/g,"/"))}for(let U of $.matchAll(/include\s+((?:['"][^'"]+['"]\s*,?\s*)+)/g))for(let X of U[1].split(",")){let Q=X.replace(/['":\s]/g,"").replace(/^:/,"");if(Q)Z.push(Q.replace(/:/g,"/"))}for(let U of $.matchAll(/project\s*\(\s*["']:([^"']+)["']\s*\)\s*\.projectDir\s*=\s*file\s*\(\s*["']([^"']+)["']\s*\)/g))Z.push(U[2].replace(/^\.\//,""));return[...new Set(Z)]}function iq($,Z){let U=new Set;for(let X of $.matchAll(/\bid\s*\(\s*["']([^"']+)["']\s*\)/g))U.add(X[1].toLowerCase());for(let X of $.matchAll(/\bid\s+['"]([^'"]+)['"]/g))U.add(X[1].toLowerCase());for(let X of $.matchAll(/plugins\s*\{([\s\S]*?)\}/g))for(let Q of X[1].split(/[\n;]/)){let z=Q.replace(/\/\/.*$/,"").trim();if(!z||z.startsWith("id")||z.startsWith("kotlin")||z.startsWith("alias"))continue;let J=z.match(/^`([a-zA-Z0-9.-]+)`$/)||z.match(/^([a-zA-Z][a-zA-Z0-9.-]*)$/);if(J)U.add(J[1].toLowerCase())}for(let X of $.matchAll(/\bkotlin\s*\(\s*["']([^"']+)["']\s*\)/g)){let Q=X[1].toLowerCase();if(Q==="jvm")U.add("org.jetbrains.kotlin.jvm");else if(Q==="multiplatform")U.add("org.jetbrains.kotlin.multiplatform");else if(Q==="android")U.add("org.jetbrains.kotlin.android");else U.add(`org.jetbrains.kotlin.${Q}`)}for(let X of $.matchAll(/libs\.plugins\.([A-Za-z0-9_.]+)/g)){let Q=X[1].toLowerCase(),z=Z.plugins.get(Q)||Z.plugins.get(Q.replace(/\./g,"-"))||Z.plugins.get(Q.replace(/-/g,"."));if(z)U.add(z);else if(Q.includes("spring")&&Q.includes("boot"))U.add("org.springframework.boot")}for(let X of $.matchAll(/apply\s+plugin\s*:\s*['"]([^'"]+)['"]/g))U.add(X[1].toLowerCase());return U}function rq($,Z){let U=new Set;for(let X of $.matchAll(/["']([A-Za-z0-9_.-]+:[A-Za-z0-9_.-]+)(?::[^"']+)?["']/g))U.add(X[1].toLowerCase());for(let X of $.matchAll(/libs\.([A-Za-z0-9_.]+)/g)){let Q=X[1].toLowerCase();if(Q.startsWith("plugins."))continue;let z=[Q,Q.replace(/\./g,"-"),Q.replace(/-/g,".")];for(let J of z){let H=Z.libraries.get(J);if(H){U.add(H.includes(":")?H.split(":").slice(0,2).join(":"):H);break}}}return U}function L9($){let Z=($.match(/<packaging>\s*([^<]+?)\s*<\/packaging>/i)?.[1]||"jar").trim().toLowerCase(),U=new Set,X=$.match(/<parent>([\s\S]*?)<\/parent>/i);if(X){let J=X[1].match(/<groupId>\s*([^<]+?)\s*<\/groupId>/i)?.[1]?.trim(),H=X[1].match(/<artifactId>\s*([^<]+?)\s*<\/artifactId>/i)?.[1]?.trim();if(J&&H)U.add(`${J}:${H}`.toLowerCase())}let Q=new Set;for(let J of $.matchAll(/<dependency>([\s\S]*?)<\/dependency>/gi)){let H=J[1].match(/<groupId>\s*([^<]+?)\s*<\/groupId>/i)?.[1]?.trim(),q=J[1].match(/<artifactId>\s*([^<]+?)\s*<\/artifactId>/i)?.[1]?.trim();if(H&&q)Q.add(`${H}:${q}`.toLowerCase())}let z=[];for(let J of $.matchAll(/<module>\s*([^<]+?)\s*<\/module>/gi))z.push(J[1].trim());return{packaging:Z,parents:U,artifacts:Q,modules:z}}function $0($,Z){let U=Z.toLowerCase();if($.has(U))return!0;for(let X of $)if(X===U||X.endsWith(`.${U}`)||X===U.replace(/^org\.gradle\./,""))return!0;return!1}function T1($,Z,U){let X;for(let[Q,z]of Z){let J=!1;if(U==="plugin")J=$0($,Q);else if(J=$.has(Q)||[...$].some((H)=>H===Q||H.startsWith(`${Q}:`)||H.startsWith(`${Q}.`)),!J&&U==="artifact")J=[...$].some((H)=>H===Q||H.startsWith(`${Q}`));if(!J)continue;if(!X||Q.length>X[0].length)X=[Q,z]}return X}function sq($){let Z;for(let U of gq)for(let X of $){if(X===U||X.startsWith(`${U}:`)||X.startsWith(U.replace(/:mcp$/,":"))){if(!Z||U.length>Z.length)Z=U}if(X.startsWith("io.modelcontextprotocol")||X.includes("spring-ai-starter-mcp")||X.includes("spring-ai-mcp")){if(!Z||X.length>Z.length)Z=X}}return Z}function R9($){let Z=new Set,U=!1,X=!1,Q=[l($,"src"),l($,"src","main")],z=(J,H)=>{if(H>4||!P0(J))return;let q;try{q=Eq(J)}catch{return}for(let Y of q){if(Y==="androidMain"||Y==="commonMain"||Y==="jvmMain"||Y==="iosMain")Z.add(Y);let G=l(J,Y);try{if(jq(G).isDirectory())z(G,H+1);else if(Y.endsWith(".kt")||Y.endsWith(".kts"))U=!0;else if(Y.endsWith(".java"))X=!0}catch{}}};for(let J of Q)z(J,0);return{kotlin:U,java:X,hints:Z}}function aq($){let Z=[],U=$.plugins,X=$.artifacts,Q=fq.some((A)=>$0(U,A))||$.sourceHints.has("commonMain"),z=$0(U,"com.android.application"),J=$0(U,"com.android.library")||$0(U,"com.android.kotlin.multiplatform.library");if(z||J)Z.push("android");if(Q)Z.push("multiplatform");let H=sq(X),q=T1(U,xq,"plugin"),Y=T1($.parents,hq,"parent"),G=T1(X,yq,"artifact"),_=T1(U,kq,"plugin"),B=T1(X,vq,"artifact"),O=mq.some((A)=>$0(U,A)),D=$.packaging==="pom",V,W="",I;if(z)V="mobile",W=Q?"Android+KMP":"Android",I=`${$.path||"root"} + com.android.application (${W})`;else if(H)V="mcp",W="MCP",Z.push("mcp"),I=`${$.path||"root"} + ${H} (JVM MCP server)`;else if(q||Y||G){V="backend",W=q?.[1]||Y?.[1]||G?.[1]||"JVM";let A=q?.[0]||Y?.[0]||G?.[0]||"web";I=`${$.path||"root"} + ${A} (JVM backend)`}else if(Q&&!J)V="library",W="Kotlin Multiplatform",I=`${$.path||"root"} + kotlin multiplatform (KMP library)`;else if(J)V="library",W=Q?"Android+KMP":"Android",I=`${$.path||"root"} + android library (${W})`;else if(B||$.hasApplicationPlugin&&($.hasMainClass||_)||_&&$.hasMainClass)V="cli",W=B?.[1]||"application",I=B?`${$.path||"root"} + ${B[0]} (JVM CLI)`:`${$.path||"root"} + application plugin (JVM CLI)`;else if($.hasApplicationPlugin&&!O)V="cli",W="application",I=`${$.path||"root"} + application plugin (JVM CLI)`;else if(D)V="library",I=`${$.path||"root"} + packaging=pom (Maven aggregator/BOM)`;else{V="library";let A=$.kotlinSources&&!$.javaSources?"Kotlin":"JVM";if(I=`${$.path||"root"} (${A} library)`,O)I=`${$.path||"root"} + java-library (JVM library)`}let L="Java";if($.kotlinSources&&$.javaSources)L="Java/Kotlin";else if($.kotlinSources||uq.some((A)=>$0(U,A))||Q)L="Kotlin";let F=[...new Set(Z)];return{appType:V,framework:W,facets:F,found:I,buildTool:$.buildTool,mainLanguage:L}}function nq($,Z){if($==="mcp")return 0;if($==="mobile")return 1;if(Z.includes("multiplatform")&&$==="backend")return 2;if($==="backend")return 3;if($==="cli")return 4;if(Z.includes("multiplatform"))return 5;if(Z.includes("android"))return 6;return 7}function D9($,Z,U){let X=Z?l($,Z):$,Q=l(X,"build.gradle.kts"),z=l(X,"build.gradle"),J=P0(Q)?Q:P0(z)?z:null;if(!J)return null;let H=N1(J);if(!H)return null;let q=iq(H,U),Y=rq(H,U),G=R9(X),_=/mainClass\s*[.=]/.test(H)||/mainClassName\s*=/.test(H)||/Main-Class/.test(H),B=$0(q,"application")||$0(q,"org.gradle.application");return{path:Z||"build.gradle",plugins:q,artifacts:Y,packaging:"jar",parents:new Set,hasMainClass:_,hasApplicationPlugin:B,sourceHints:G.hints,kotlinSources:G.kotlin||J.endsWith(".kts"),javaSources:G.java,buildTool:"gradle"}}function I9($,Z){let U=Z?l($,Z):$,X=l(U,"pom.xml");if(!P0(X))return null;let Q=N1(X);if(!Q)return null;let{packaging:z,parents:J,artifacts:H}=L9(Q),q=R9(U);return{path:Z?`${Z}/pom.xml`:"pom.xml",plugins:new Set,artifacts:H,packaging:z,parents:J,hasMainClass:/<mainClass>/.test(Q),hasApplicationPlugin:!1,sourceHints:q.hints,kotlinSources:q.kotlin,javaSources:q.java,buildTool:"maven"}}function w1($){if(!q3($))return null;let Z=dq($),U=[],X=null;for(let Y of["settings.gradle.kts","settings.gradle"]){let G=l($,Y);if(P0(G)){X=N1(G);break}}let Q=X?cq(X):[],z=D9($,"",Z);if(z)U.push(z);for(let Y of Q){let G=D9($,Y,Z);if(G)U.push(G)}let J=I9($,"");if(J){U.push(J);let Y=N1(l($,"pom.xml"));if(Y){let{modules:G}=L9(Y);for(let _ of G){let B=I9($,_);if(B)U.push(B)}}}if(U.length===0&&X)return{appType:"library",framework:"",buildTool:"gradle",mainLanguage:"Java/Kotlin",facets:[],found:"settings.gradle (Gradle multi-project root)"};if(U.length===0)return null;let H=null,q=999;for(let Y of U){let G=aq(Y),_=nq(G.appType,G.facets);if(!H||_<q)H={appType:G.appType,framework:G.framework,buildTool:G.buildTool,mainLanguage:G.mainLanguage,facets:G.facets,found:G.found},q=_}if(H&&Q.length>0&&!H.found.includes("multi-project"));return H}var UY=new Set(["node_modules",".git","dist","build","venv",".venv","__pycache__","target","coverage",".next",".svelte-kit","vendor"]),XY=new Set([".py",".ts",".tsx",".js",".jsx",".svelte",".vue",".rb",".go",".rs",".php",".java",".kt",".swift"]),QY={mainLanguage:["project","main_language"],main_language:["project","main_language"],framework:["stack","frontend"],cssFramework:["stack","css_framework"],css:["stack","css_framework"],uiLibrary:["stack","ui_library"],ui_library:["stack","ui_library"],stateManagement:["stack","state_management"],state:["stack","state_management"],backend:["stack","backend"],apiType:["stack","api_type"],api:["stack","api_type"],runtime:["stack","runtime"],database:["stack","database"],db:["stack","database"],connection:["stack","connection"],hosting:["stack","hosting"],buildTool:["stack","build"],build_tool:["stack","build"],build:["stack","build"],packageManager:["stack","package_manager"],pkg_manager:["stack","package_manager"],cicd:["stack","cicd"]},zY=[["packageManager","package-manager"],["pkg_manager","package-manager"],["mainLanguage","language"],["main_language","language"],["framework","framework"],["backend","backend"],["database","database"],["db","database"],["cicd","ci-cd"],["hosting","hosting"],["buildTool","build"],["build_tool","build"],["build","build"],["runtime","runtime"],["cssFramework","css"],["css","css"],["uiLibrary","ui-library"],["stateManagement","state-management"],["apiType","api"],["api","api"]];function JY($,Z){for(let[U,X]of zY)if(U in $)return X;return Z.length>0?"framework":"config"}function HY($){try{let Z=JSON.parse(tq($,"utf-8")),U=["background","content_scripts","action","browser_action","permissions"].some((X)=>(X in Z));if(typeof Z.manifest_version==="number"&&U)return"chrome";return"other"}catch{return"other"}}function qY($){let Z=[],U=ZY($),X=oq(Y3($,".git")),Q=new Set;for(let z=0;z<10;z++){let J;try{J=M9(U)}catch{break}for(let q of J){if(q.toLowerCase().endsWith(".csproj")){let G=S$(U);if(G){let _={mainLanguage:"C#",packageManager:"NuGet",buildTool:"dotnet"};if(G.appType==="backend"&&G.framework)_.backend=G.framework;else if(G.appType==="cli"&&G.framework)_.framework=G.framework;else if(G.appType==="mcp")_.apiType="MCP";else if(G.appType==="mobile"&&G.framework)_.framework=G.framework;if(G.targetFramework)_.runtime=G.targetFramework;let B=G.framework?[G.framework,"C#",".NET"]:["C#",".NET"];Z.push({slots:_,priority:36,frameworks:B,fileName:q})}continue}let Y=Q3[q];if(!Y)continue;if(q==="manifest.json"&&HY(Y3(U,q))!=="chrome")continue;if(q==="pubspec.yaml"){let G=T$(U);if(G){let _={mainLanguage:"Dart",packageManager:"pub"};if(G.isFlutter){if(_.framework="Flutter",G.stateManagement)_.stateManagement=G.stateManagement}else if(G.appType==="backend"&&G.framework)_.backend=G.framework;else if(G.appType==="mcp")_.apiType="MCP";Z.push({slots:_,priority:Y.priority,frameworks:G.isFlutter?["Flutter","Dart"]:["Dart"],fileName:q});continue}}if(q==="go.mod"){let G=C$(U);if(G){let _={mainLanguage:"Go",packageManager:"go modules",buildTool:"go build"};if(G.appType==="backend"&&G.framework)_.backend=G.framework;else if(G.appType==="cli"&&G.framework)_.framework=G.framework;else if(G.appType==="mcp")_.apiType="MCP";let B=G.framework?[G.framework,"Go"]:["Go"];Z.push({slots:_,priority:Y.priority,frameworks:B,fileName:q});continue}}if(q==="pom.xml"||q==="build.gradle"||q==="build.gradle.kts"||q==="settings.gradle"||q==="settings.gradle.kts"){if(Q.has(U))continue;Q.add(U);let G=w1(U);if(G){let _={mainLanguage:G.mainLanguage==="Java/Kotlin"?"Kotlin":G.mainLanguage,packageManager:G.buildTool==="maven"?"maven":"gradle",buildTool:G.buildTool};if(G.appType==="backend"&&G.framework)_.backend=G.framework;else if(G.appType==="cli"&&G.framework)_.framework=G.framework;else if(G.appType==="mcp")_.apiType="MCP";else if(G.appType==="mobile")_.framework=G.framework||"Android";if(G.facets.includes("multiplatform"))_.framework=G.framework||"Kotlin Multiplatform";let B=G.framework?[G.framework,"JVM",G.mainLanguage==="Kotlin"?"Kotlin":"Java"]:["JVM",G.mainLanguage==="Kotlin"?"Kotlin":"Java"];Z.push({slots:_,priority:Y.priority??35,frameworks:B,fileName:q});continue}}Z.push({slots:Y.slots||{},priority:Y.priority,frameworks:Y.frameworks,fileName:q})}if(X&&z===0)break;let H=eq(U);if(H===U)break;U=H}return Z}function YY($){let Z=[];for(let U of F9($,2,{count:0})){let X=Q3[`*${U}`],Q=X?.slots?.mainLanguage;if(Q)Z.push({slots:{mainLanguage:Q},priority:X.priority,frameworks:X.frameworks})}return Z}function K9($){let Z=[...qY($),...YY($)],U={},X={},Q=new Set;for(let Y of Z){Y.frameworks.forEach((G)=>Q.add(G));for(let[G,_]of Object.entries(Y.slots))if(_&&!_.includes("/")&&(!(G in U)||Y.priority>X[G]))U[G]=_,X[G]=Y.priority}let z=new Map;for(let Y of Z){if(!Y.fileName)continue;if(!z.has(Y.fileName))z.set(Y.fileName,{fileName:Y.fileName,category:JY(Y.slots,Y.frameworks),priority:Y.priority})}let J=[...z.values()].sort((Y,G)=>G.priority-Y.priority||Y.fileName.localeCompare(G.fileName)),H=[];if(U.mainLanguage)H.push(U.mainLanguage.toLowerCase());if(U.framework)H.push(U.framework.toLowerCase());let q=H.length>0?H.join("-"):"unknown-stack";return{slotFills:U,frameworks:[...Q],confirmedCount:Z.length,discoveredFormats:J,stackSignature:q}}function G3($){let{slotFills:Z}=K9($),U={};for(let[X,Q]of Object.entries(Z)){let z=QY[X];if(!z||!Q)continue;let[J,H]=z;if(J==="project")(U.project??={})[H]=Q;else(U.stack??={})[H]=Q}return U}function F9($,Z,U){let X=new Set;if(Z<0||U.count>400)return X;let Q;try{Q=M9($,{withFileTypes:!0})}catch{return X}for(let z of Q){if(U.count++>400)break;if(!z.isDirectory()){let J=$Y(z.name);if(XY.has(J))X.add(J);continue}if(UY.has(z.name)||z.name.startsWith("."))continue;for(let J of F9(Y3($,z.name),Z-1,U))X.add(J)}return X}import{existsSync as P9,readFileSync as A9}from"fs";import{join as T9}from"path";var f=($,Z,U)=>({value:$,source:Z,confidence:U});function N9($){let Z=GY($),U=_Y($),X={},Q=(z,J)=>{if(J)X[z]=J};return Q("what",BY(Z,U)),Q("who",VY(U)),Q("why",OY(U)),Q("where",WY(Z,U)),Q("when",DY(U)),Q("how",IY(Z,U)),X}function _3($){let Z=N9($),U={};return Object.keys(Z).forEach((X)=>{let Q=Z[X];if(Q)U[X]=Q.value}),U}function GY($){let Z=T9($,"package.json");if(!P9(Z))return null;try{return JSON.parse(A9(Z,"utf-8"))}catch{return null}}function _Y($){let Z=T9($,"README.md");if(!P9(Z))return"";let U;try{U=A9(Z,"utf-8")}catch{return""}return U.split(`
217
218
  `).filter((X)=>!/^\s*\[!\[/.test(X)&&!/^\s*!\[/.test(X)).join(`
218
- `).replace(/<[^>]+>/g,"").replace(/!\[[^\]]*\]\([^)]*\)/g,"").trim()}function R0($){return $.replace(/\s+/g," ").replace(/[#*`>]/g,"").trim().slice(0,280)}function v0($,Z){let z=new RegExp(`##?\\s+(${Z})\\s*\\n+([\\s\\S]+?)(?:\\n\\n|\\n##?|$)`,"i"),X=$.match(z);return X&&X[2]&&X[2].trim().length>20?{body:R0(X[2]),heading:X[1].trim()}:null}function R$($,Z,z=30){for(let X of Z){let U=$.match(X);if(U&&U[1]&&U[1].trim().length>=z)return R0(U[1])}return null}function YG($,Z){if($?.description&&$.description.length>20)return h(R0($.description),"package.json:description",0.95);let z=v0(Z,"Purpose|What|About|Overview|Description");if(z)return h(z.body,`README:## ${z.heading}`,0.8);let X=Z.split(/\n\s*\n/).map((Q)=>Q.trim()).find((Q)=>Q.length>30&&!Q.startsWith("#"));if(X)return h(R0(X),"README:first-paragraph",0.5);let U=R$(Z,[/(?:core|main|primary)\s+(?:problem|challenge)(?:\s+is)?\s*:?\s*([^.\n]{30,})/i,/solves?\s+(?:the\s+)?(?:problem\s+of\s+)?([^.\n]{30,})/i]);return U?h(U,"README:problem-heuristic",0.6):null}function qG($){let Z=v0($,"Audience|Who|Who is this for|Who it.s for");if(Z)return h(Z.body,`README:## ${Z.heading}`,0.8);let z=R$($,[/\b(?:designed|built|made)\s+for\s+((?:[a-z][a-z-]*\s+)?(?:developers?|teams?|engineers?|builders?|founders?)[^.\n]{0,80})/i,/\bfor\s+((?:[a-z][a-z-]*\s+)?(?:developers?|teams?|engineers?|builders?|founders?)[^.\n]{0,80})/i],8);return z?h(z,"README:audience-heuristic",0.6):null}function BG($){let Z=v0($,"Why|Mission|Motivation|Rationale|Vision");if(Z)return h(Z.body,`README:## ${Z.heading}`,0.8);let z=R$($,[/(?:our\s+|the\s+)?(?:mission|purpose|goal)\s+is\s+([^.\n]{30,})/i,/\b(?:mission|purpose|goal)\s*:\s*([^.\n]{30,})/i,/(?:built|created|designed)\s+(?:because|to)\s+([^.\n]{30,})/i]);return z?h(z,"README:mission-heuristic",0.6):null}function VG($,Z){let z=typeof $?.repository==="string"?$.repository:$?.repository?.url;if(z)return h(R0(z.replace(/^git\+/,"").replace(/\.git$/,"")),"package.json:repository",0.95);if($?.homepage)return h(R0($.homepage),"package.json:homepage",0.9);let X=R$(Z,[/\b(?:deployed|hosted|available|published)\s+(?:on|at|via)\s+([^.\n]{3,80})/i],3);return X?h(X,"README:deploy-heuristic",0.6):null}function OG($){let Z=v0($,"Timeline|Status|Release|Roadmap");if(Z)return h(Z.body,`README:## ${Z.heading}`,0.8);let z=R$($,[/\b(production\s+since\s+[^.\n]{4,60})/i,/\b((?:in\s+)?(?:production|beta|alpha|development)\s+since\s+[^.\n]{4,60})/i,/\bsince\s+((?:[A-Z][a-z]+\s+)?\d{4}[^.\n]{0,40})/],4);return z?h(z,"README:since-heuristic",0.6):null}function WG($,Z){let z=$?.scripts?Object.keys($.scripts):[],X=["start","dev","build"].filter((J)=>z.includes(J));if(X.length)return h(R0(X.map((J)=>`npm run ${J}`).join(", ")),"package.json:scripts",0.9);let U=v0(Z,"Usage|Getting Started|Install|Installation|Quick Start");if(U)return h(U.body,`README:## ${U.heading}`,0.8);let Q=v0(Z,"Architecture|Approach|How it works|Methodology|How");return Q?h(Q.body,`README:## ${Q.heading}`,0.7):null}var G6="3.0";import{existsSync as M,readFileSync as t,readdirSync as Y6}from"fs";import{join as F}from"path";var _6=[{name:"Next.js",slug:"nextjs",category:"frontend",signals:[{type:"dependency",key:"next"},{type:"file",pattern:"next.config.*"}]},{name:"React",slug:"react",category:"frontend",signals:[{type:"dependency",key:"react"}]},{name:"SvelteKit",slug:"sveltekit",category:"frontend",signals:[{type:"dependency",key:"@sveltejs/kit"},{type:"file",pattern:"svelte.config.*"}]},{name:"Svelte",slug:"svelte",category:"frontend",signals:[{type:"dependency",key:"svelte"},{type:"devDependency",key:"svelte"}]},{name:"Vue.js",slug:"vue",category:"frontend",signals:[{type:"dependency",key:"vue"}]},{name:"Nuxt",slug:"nuxt",category:"frontend",signals:[{type:"dependency",key:"nuxt"},{type:"file",pattern:"nuxt.config.*"}]},{name:"Angular",slug:"angular",category:"frontend",signals:[{type:"dependency",key:"@angular/core"},{type:"file",pattern:"angular.json"}]},{name:"Astro",slug:"astro",category:"frontend",signals:[{type:"dependency",key:"astro"},{type:"file",pattern:"astro.config.*"}]},{name:"Solid",slug:"solid",category:"frontend",signals:[{type:"dependency",key:"solid-js"}]},{name:"Remix",slug:"remix",category:"frontend",signals:[{type:"dependency",key:"@remix-run/react"}]},{name:"Gatsby",slug:"gatsby",category:"frontend",signals:[{type:"dependency",key:"gatsby"},{type:"file",pattern:"gatsby-config.*"}]},{name:"Qwik",slug:"qwik",category:"frontend",signals:[{type:"dependency",key:"@builder.io/qwik"}]},{name:"Vercel (SvelteKit)",slug:"adapter-vercel",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-vercel"},{type:"devDependency",key:"@sveltejs/adapter-vercel"}]},{name:"Node (SvelteKit)",slug:"adapter-node",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-node"},{type:"devDependency",key:"@sveltejs/adapter-node"}]},{name:"Static (SvelteKit)",slug:"adapter-static",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-static"},{type:"devDependency",key:"@sveltejs/adapter-static"}]},{name:"Cloudflare (SvelteKit)",slug:"adapter-cloudflare",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-cloudflare"},{type:"devDependency",key:"@sveltejs/adapter-cloudflare"}]},{name:"Netlify (SvelteKit)",slug:"adapter-netlify",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-netlify"},{type:"devDependency",key:"@sveltejs/adapter-netlify"}]},{name:"Tailwind CSS",slug:"tailwind",category:"css",signals:[{type:"dependency",key:"tailwindcss"},{type:"devDependency",key:"tailwindcss"},{type:"file",pattern:"tailwind.config.*"}]},{name:"Bootstrap",slug:"bootstrap",category:"css",signals:[{type:"dependency",key:"bootstrap"}]},{name:"Styled Components",slug:"styled-components",category:"css",signals:[{type:"dependency",key:"styled-components"}]},{name:"shadcn/ui",slug:"shadcn",category:"ui",signals:[{type:"file",pattern:"components.json"},{type:"dependency",key:"@radix-ui/react-dialog"}]},{name:"Material UI",slug:"mui",category:"ui",signals:[{type:"dependency",key:"@mui/material"}]},{name:"Chakra UI",slug:"chakra",category:"ui",signals:[{type:"dependency",key:"@chakra-ui/react"}]},{name:"Ant Design",slug:"antd",category:"ui",signals:[{type:"dependency",key:"antd"}]},{name:"Redux",slug:"redux",category:"state",signals:[{type:"dependency",key:"@reduxjs/toolkit"}]},{name:"Zustand",slug:"zustand",category:"state",signals:[{type:"dependency",key:"zustand"}]},{name:"Jotai",slug:"jotai",category:"state",signals:[{type:"dependency",key:"jotai"}]},{name:"Pinia",slug:"pinia",category:"state",signals:[{type:"dependency",key:"pinia"}]},{name:"Express",slug:"express",category:"backend",signals:[{type:"dependency",key:"express"}]},{name:"Fastify",slug:"fastify",category:"backend",signals:[{type:"dependency",key:"fastify"}]},{name:"Hono",slug:"hono",category:"backend",signals:[{type:"dependency",key:"hono"}]},{name:"Elysia",slug:"elysia",category:"backend",signals:[{type:"dependency",key:"elysia"}]},{name:"NestJS",slug:"nestjs",category:"backend",signals:[{type:"dependency",key:"@nestjs/core"}]},{name:"Koa",slug:"koa",category:"backend",signals:[{type:"dependency",key:"koa"}]},{name:"Django",slug:"django",category:"backend",signals:[{type:"file",pattern:"manage.py"},{type:"file",pattern:"settings.py"}]},{name:"Flask",slug:"flask",category:"backend",signals:[{type:"file",pattern:"app.py"}]},{name:"FastAPI",slug:"fastapi",category:"backend",signals:[{type:"file",pattern:"main.py"}]},{name:"Rails",slug:"rails",category:"backend",signals:[{type:"file",pattern:"Gemfile"},{type:"file",pattern:"config/routes.rb"}]},{name:"Spring Boot",slug:"spring",category:"backend",signals:[{type:"file",pattern:"pom.xml"},{type:"file",pattern:"build.gradle"}]},{name:"Prisma",slug:"prisma",category:"database",signals:[{type:"dependency",key:"prisma"},{type:"devDependency",key:"prisma"},{type:"file",pattern:"prisma/schema.prisma"}]},{name:"Drizzle",slug:"drizzle",category:"database",signals:[{type:"dependency",key:"drizzle-orm"},{type:"file",pattern:"drizzle.config.*"}]},{name:"TypeORM",slug:"typeorm",category:"database",signals:[{type:"dependency",key:"typeorm"}]},{name:"Mongoose",slug:"mongoose",category:"database",signals:[{type:"dependency",key:"mongoose"}]},{name:"Vite",slug:"vite",category:"build",signals:[{type:"dependency",key:"vite"},{type:"devDependency",key:"vite"},{type:"file",pattern:"vite.config.*"}]},{name:"webpack",slug:"webpack",category:"build",signals:[{type:"dependency",key:"webpack"},{type:"devDependency",key:"webpack"},{type:"file",pattern:"webpack.config.*"}]},{name:"esbuild",slug:"esbuild",category:"build",signals:[{type:"dependency",key:"esbuild"},{type:"devDependency",key:"esbuild"}]},{name:"Turbopack",slug:"turbopack",category:"build",signals:[{type:"file",pattern:"turbo.json"}]},{name:"Jest",slug:"jest",category:"testing",signals:[{type:"devDependency",key:"jest"},{type:"file",pattern:"jest.config.*"}]},{name:"Vitest",slug:"vitest",category:"testing",signals:[{type:"devDependency",key:"vitest"}]},{name:"Playwright",slug:"playwright",category:"testing",signals:[{type:"devDependency",key:"@playwright/test"},{type:"file",pattern:"playwright.config.*"}]},{name:"Cypress",slug:"cypress",category:"testing",signals:[{type:"devDependency",key:"cypress"},{type:"file",pattern:"cypress.config.*"}]},{name:"Turborepo",slug:"turborepo",category:"monorepo",signals:[{type:"devDependency",key:"turbo"},{type:"file",pattern:"turbo.json"}]},{name:"Nx",slug:"nx",category:"monorepo",signals:[{type:"devDependency",key:"nx"},{type:"file",pattern:"nx.json"}]},{name:"Lerna",slug:"lerna",category:"monorepo",signals:[{type:"devDependency",key:"lerna"},{type:"file",pattern:"lerna.json"}]},{name:"MCP SDK",slug:"mcp",category:"ai",signals:[{type:"dependency",key:"@modelcontextprotocol/sdk"}]},{name:"Anthropic SDK",slug:"anthropic",category:"ai",signals:[{type:"dependency",key:"@anthropic-ai/sdk"}]},{name:"OpenAI SDK",slug:"openai",category:"ai",signals:[{type:"dependency",key:"openai"}]},{name:"LangChain",slug:"langchain",category:"ai",signals:[{type:"dependency",key:"langchain"}]},{name:"Vercel",slug:"vercel",category:"hosting",signals:[{type:"file",pattern:"vercel.json"}]},{name:"Netlify",slug:"netlify",category:"hosting",signals:[{type:"file",pattern:"netlify.toml"}]},{name:"Docker",slug:"docker",category:"hosting",signals:[{type:"file",pattern:"Dockerfile"},{type:"file",pattern:"docker-compose.yml"}]},{name:"Cloudflare Workers",slug:"cloudflare",category:"hosting",signals:[{type:"file",pattern:"wrangler.toml"},{type:"dependency",key:"wrangler"}]},{name:"GitHub Actions",slug:"github-actions",category:"cicd",signals:[{type:"file",pattern:".github/workflows/*.yml"}]},{name:"Commander.js",slug:"commander",category:"cli",signals:[{type:"dependency",key:"commander"}]}];function IG($){let Z=F($,"Cargo.toml");if(!M(Z))return null;try{let X=t(Z,"utf-8").match(/^\s*\[package\][\s\S]*?^\s*name\s*=\s*"([^"]+)"/m);return X?X[1]:null}catch{return null}}function LG($){let Z=F($,"Cargo.toml");if(!M(Z))return!1;try{let z=t(Z,"utf-8");return/^\s*\[\[bin\]\]/m.test(z)}catch{return!1}}function DG($,Z){if(Z?.keywords?.some((X)=>/^sdk(?:\s|-|$)|-sdk$/i.test(X)))return'package.json keywords contains "sdk"';if(Z?.name&&/(?:^|[-_/])sdk(?:[-_/]|$)/i.test(Z.name))return`package.json name "${Z.name}" → sdk`;let z=IG($);if(z&&/(?:^|[-_])sdk(?:[-_]|$)/i.test(z))return`Cargo.toml name "${z}" → sdk`;return null}function RG($){let Z=["manifest.json","public/manifest.json","src/manifest.json","app/manifest.json","extension/manifest.json","dist/manifest.json"];for(let z of Z){let X=F($,z);if(!M(X))continue;try{let U=JSON.parse(t(X,"utf-8"));if(typeof U.manifest_version==="number")return`${z} manifest_version ${U.manifest_version} (browser extension)`}catch{}}return null}function FG($){let Z=/(numpy|pandas|jupyter|scikit-learn|sklearn|pytorch|tensorflow|matplotlib|scipy)/i,z=F($,"pyproject.toml");if(M(z))try{let Q=t(z,"utf-8").match(Z);if(Q)return`pyproject.toml depends on ${Q[1]}`}catch{}let X=F($,"requirements.txt");if(M(X))try{let Q=t(X,"utf-8").match(Z);if(Q)return`requirements.txt contains ${Q[1]}`}catch{}return null}function MG($,Z){let z=["react-native","expo","@capacitor/core","@ionic/core"];if(Z){for(let X of z)if(Z.dependencies?.[X]||Z.devDependencies?.[X])return`${X} dependency`}if(M(F($,"ios"))&&M(F($,"android")))return"ios/ + android/ dirs";return null}function KG($,Z){let z=F($,"Cargo.toml");if(M(z))try{let U=t(z,"utf-8");if(/crate-type\s*=\s*\[[^\]]*"cdylib"/.test(U))return'Cargo.toml crate-type = ["cdylib"]';if(/wasm-bindgen|wasm-pack/i.test(U))return"Cargo.toml wasm-bindgen/wasm-pack"}catch{}let X=F($,"build.zig");if(M(X))try{let U=t(X,"utf-8");if(/\.wasm\b|wasm32|setOutputFormat\(\.wasm/i.test(U))return"build.zig wasm target"}catch{}if(Z?.keywords?.some((U)=>/^wasm(?:-|$)|webassembly/i.test(U)))return'package.json keywords contains "wasm"';return null}function PG($,Z){if(!M(F($,"index.html")))return null;if(Z?.dependencies||Z?.devDependencies){let z={...Z.dependencies??{},...Z.devDependencies??{}};if(["react","vue","svelte","@sveltejs/kit","next","nuxt","astro","gatsby","solid-js","qwik"].some((U)=>z[U]))return null}return"index.html (vanilla, no frontend framework)"}function TG($,Z){if(Z?.name&&/specification|^@.*\/spec/i.test(Z.name))return`package name "${Z.name}" → documentation`;if(Z?.keywords?.some((z)=>/^(specification|format-spec|standard)$/i.test(z)))return'package keywords contains "specification"';if(Z?.bin)return null;if(Z?.files&&Z.files.length>0){let z=/^(dist|src|lib|build|bin)(\/|$)|\/(dist|src|lib|build|bin)(\/|$)|(\.|\/)(js|ts|tsx|jsx|mjs|cjs|py|rs|go)$/,X=Z.files.some((Q)=>z.test(Q)),U=Z.files.some((Q)=>/\.(md|MD)$|examples?\//.test(Q)||Q==="README.md"||Q==="docs"||Q==="docs/");if(!X&&U)return"package.json files = docs/examples only (no source)"}return null}function AG($,Z,z){let X=z.find((U)=>U.slug==="astro"||U.slug==="gatsby");if(X)return`${X.name} (static-site framework)`;if(Z?.keywords?.some((U)=>/^(website|marketing|landing|brochure|portfolio)$/i.test(U)))return'package keywords contains "website"/"marketing"/"landing"';return null}function NG($,Z){if(!Z)return null;let z={...Z.dependencies??{},...Z.devDependencies??{}},X=["@clerk/nextjs","@clerk/clerk-react","next-auth","@auth/core","auth0","@auth0/nextjs-auth0"],U=["stripe","@stripe/stripe-js","lemonsqueezy"],Q=X.some((H)=>z[H]),J=U.some((H)=>z[H]);if(Q&&J)return"auth + payment dependencies";return null}function wG($,Z,z){if(Z?.keywords?.some((Q)=>/mcpaas/i.test(Q)))return'package keywords contains "mcpaas"';if(Z?.name&&/mcpaas/i.test(Z.name))return`package name "${Z.name}" → mcpaas`;let X=z.some((Q)=>Q.slug==="mcp"),U=z.some((Q)=>Q.category==="database");if(X&&U&&Z?.dependencies&&Object.keys(Z.dependencies).length>10)return"MCP + database + complex deps (platform shape)";return null}function bG($,Z){if(!Z?.private)return null;if(!(!!Z.workspaces||M(F($,"pnpm-workspace.yaml"))))return null;return"private workspace + multi-package"}function F0($){let Z=F($,"package.json");if(!M(Z))return null;try{return JSON.parse(t(Z,"utf-8"))}catch{return null}}function CG($,Z){if(!Z.includes("*"))return M(F($,Z));let z=Z.split("/");if(z.length===1){let H=Z.split("*")[0];try{return Y6($).some((G)=>G.startsWith(H))}catch{return!1}}let X=F($,...z.slice(0,-1)),U=z[z.length-1],Q=U.split("*")[0],J=U.split("*")[1]||"";try{return Y6(X).some((H)=>H.startsWith(Q)&&H.endsWith(J))}catch{return!1}}function jG($,Z,z){switch($.type){case"dependency":return!!Z?.dependencies?.[$.key];case"devDependency":return!!Z?.devDependencies?.[$.key];case"file":return CG(z,$.pattern);default:return!1}}function e2($){let Z=F0($);return _6.map((z)=>{let U=z.signals.filter((Q)=>jG(Q,Z,$)).length/z.signals.length;return{name:z.name,slug:z.slug,category:z.category,confidence:U}}).filter((z)=>z.confidence>0).sort((z,X)=>X.confidence-z.confidence)}function q6($){let Z=F0($);if(Z?.devDependencies?.typescript||Z?.dependencies?.typescript)return"TypeScript";if(M(F($,"tsconfig.json")))return"TypeScript";if(M(F($,"Cargo.toml")))return"Rust";if(M(F($,"go.mod")))return"Go";if(M(F($,"pyproject.toml"))||M(F($,"setup.py")))return"Python";if(M(F($,"Gemfile")))return"Ruby";if(M(F($,"pom.xml"))||M(F($,"build.gradle")))return"Java";if(M(F($,"Package.swift")))return"Swift";if(M(F($,"build.zig")))return"Zig";if(M(F($,"pubspec.yaml")))return"Dart";if(Z)return"JavaScript";return"Unknown"}function B6($){let Z=F0($),z=e2($),X=[],U=TG($,Z);if(U)return X.push(U),{type:"documentation",found:X};let Q=DG($,Z);if(Q)return X.push(Q),{type:"sdk",found:X};let J=RG($);if(J)return X.push(J),{type:"extension",found:X};let H=wG($,Z,z);if(H)return X.push(H),{type:"mcpaas",found:X};let G=NG($,Z);if(G)return X.push(G),{type:"saas",found:X};let _=KG($,Z);if(_)return X.push(_),{type:"wasm",found:X};let B=I1($);if(B)return X.push(B.found),{type:B.appType,found:X};let Y=R1($);if(Y)return X.push(Y.found),{type:Y.appType,found:X};let q=MG($,Z);if(q)return X.push(q),{type:"mobile",found:X};if(z.some((T)=>T.slug==="mcp"))return X.push("MCP SDK signal"),{type:"mcp",found:X};if(Z?.bin)return X.push("package.json bin"),{type:"cli",found:X};if(LG($))return X.push("Cargo.toml [[bin]]"),{type:"cli",found:X};if(M(F($,"build.zig"))){if(X.push("build.zig"),M(F($,"src/main.zig")))return X.push("src/main.zig"),{type:"cli",found:X};if(M(F($,"src/root.zig")))return X.push("src/root.zig"),{type:"library",found:X}}let I=z.some((T)=>T.slug==="svelte"||T.slug==="sveltekit");if(Z?.private===!0&&(M(F($,"pnpm-workspace.yaml"))||Z?.workspaces!==void 0)&&I)return X.push("private workspace","Svelte"),{type:"framework",found:X};if(I)return X.push("Svelte/SvelteKit"),{type:"svelte",found:X};let O=z.some((T)=>T.category==="frontend"),L=z.some((T)=>T.category==="backend");if(Z?.private&&(Z.workspaces||M(F($,"pnpm-workspace.yaml")))&&O&&L)return X.push("private workspace + frontend + backend frameworks"),{type:"enterprise",found:X};let R=bG($,Z);if(R)return X.push(R),{type:"monorepo-root",found:X};let K=AG($,Z,z);if(K)return X.push(K),{type:"website",found:X};if(z.some((T)=>T.slug==="nextjs"||T.slug==="nuxt"))return X.push(z.find((T)=>T.slug==="nextjs")?"Next.js":"Nuxt"),{type:"fullstack",found:X};let A=z.some((T)=>T.category==="frontend"),w=z.some((T)=>T.category==="backend");if(A&&w)return X.push("frontend framework","backend framework"),{type:"fullstack",found:X};if(A)return X.push("frontend framework"),{type:"frontend",found:X};if(w)return X.push("backend framework"),{type:"backend",found:X};let C=FG($);if(C)return X.push(C),{type:"data-science",found:X};let P=PG($,Z);if(P)return X.push(P),{type:"html",found:X};if(Z?.main&&!Z?.bin)return X.push("package.json main (no bin)"),{type:"library",found:X};return X.push("no classifying signals — fallback"),{type:"library",found:X}}function V6($){if(M(F($,"bunfig.toml")))return"Bun";if(M(F($,"deno.json"))||M(F($,"deno.jsonc")))return"Deno";if(F0($))return"Node.js";if(M(F($,"Cargo.toml")))return"Rust";if(M(F($,"go.mod")))return"Go";if(M(F($,"pubspec.yaml")))return"Dart";return"Unknown"}function O6($){if(M(F($,"pubspec.yaml")))return"pub";if(M(F($,"go.mod")))return"go modules";if(M(F($,"bun.lockb"))||M(F($,"bun.lock")))return"bun";if(M(F($,"pnpm-lock.yaml")))return"pnpm";if(M(F($,"yarn.lock")))return"yarn";if(M(F($,"package-lock.json")))return"npm";return"npm"}function W6($){if(M(F($,".github/workflows")))return"GitHub Actions";if(M(F($,".gitlab-ci.yml")))return"GitLab CI";if(M(F($,".circleci")))return"CircleCI";if(M(F($,"Jenkinsfile")))return"Jenkins";return null}function I6($){if(M(F($,"vercel.json")))return"Vercel";if(M(F($,"netlify.toml")))return"Netlify";if(M(F($,"wrangler.toml")))return"Cloudflare";if(M(F($,"Dockerfile")))return"Docker";if(M(F($,"fly.toml")))return"Fly.io";if(M(F($,"render.yaml")))return"Render";return null}function L6($){let Z=F($,"svelte.config.js");if(!M(Z))return null;try{let X=t(Z,"utf-8").match(/@sveltejs\/adapter-(\w+)/);if(X){let U=X[1];switch(U){case"vercel":return"Vercel";case"node":return"Node";case"static":return"Static";case"cloudflare":return"Cloudflare";case"netlify":return"Netlify";case"auto":return"Auto";default:return U}}return null}catch{return null}}function D6($){let Z=F0($);if(Z?.devDependencies?.vite||Z?.dependencies?.vite)return"Vite";if(Z?.devDependencies?.webpack||Z?.dependencies?.webpack)return"webpack";if(Z?.devDependencies?.esbuild||Z?.dependencies?.esbuild)return"esbuild";if(M(F($,"tsconfig.json"))&&Z?.devDependencies?.typescript)return"TypeScript (tsc)";return null}function R6($){return["package.json","Cargo.toml","pyproject.toml","go.mod","build.zig","build.zig.zon","src/index.ts","src/index.js","src/main.ts","src/cli.ts","src/main.rs","src/lib.rs","src/main.zig","src/root.zig","src/__init__.py","main.py","__main__.py","main.go","cmd/main.go","README.md","SPECIFICATION.md","BINARY-FORMAT.md","tsconfig.json","wrangler.toml","vercel.json"].filter((z)=>M(F($,z)))}function F6($,Z){let z={};if(Z?.scripts){for(let X of["build","test","lint","dev","start"])if(Z.scripts[X]){let U=M(F($,"bun.lock"))||M(F($,"bun.lockb"))?"bun run":"npm run";z[X]=`${U} ${X}`}}if(M(F($,"Cargo.toml"))){if(!z.build)z.build="cargo build --release";if(!z.test)z.test="cargo test";if(!z.lint)z.lint="cargo clippy"}if(M(F($,"build.zig"))){if(!z.build)z.build="zig build";if(!z.test)z.test="zig build test"}if(M(F($,"go.mod"))){if(!z.build)z.build="go build ./...";if(!z.test)z.test="go test ./..."}if(M(F($,"pyproject.toml"))||M(F($,"pytest.ini"))){if(!z.test)z.test="pytest"}return z}function M6($,Z,z,X){let U=[];if(X&&X!=="Unknown")U.push(X);let Q=new Set(["frontend","backend","database","build","css","state","monorepo"]);for(let J of z)if(Q.has(J.category))U.push(J.name);if(M(F($,"bunfig.toml")))U.push("Bun");else if(M(F($,"deno.json"))||M(F($,"deno.jsonc")))U.push("Deno");if(U.length<3&&Z?.dependencies){let J=Object.keys(Z.dependencies).slice(0,5);for(let H of J)if(!U.some((G)=>G.toLowerCase().includes(H.toLowerCase())))U.push(H)}return U}function K6($){let Z=F0($),z=e2($),X=q6($),U=B6($),Q=U.type,J=V6($),H=O6($),G=W6($),_=I6($),B=D6($),Y=z.find((j)=>j.category==="frontend"),q=z.find((j)=>j.category==="css"),W=z.find((j)=>j.category==="ui"),I=z.find((j)=>j.category==="state"),V=z.find((j)=>j.category==="backend"),O=z.find((j)=>j.category==="database"),L=K0[Q]||K0.library,R=Q==="framework",K=z.some((j)=>j.slug==="svelte"||j.slug==="sveltekit"),N=R&&K?"svelte":R?null:null,A=Q==="svelte"||N==="svelte",w=A?L6($):null,C=A&&z.some((j)=>j.slug==="sveltekit"),P=new Set(["css_framework","ui_library","database","connection","hosting"]),T={},d=y.filter((j)=>j.path.startsWith("stack."));for(let j of d){let S=j.path.replace("stack.","");if(!L.includes(j.category)){T[S]="slotignored";continue}if(R&&P.has(S)){T[S]="slotignored";continue}switch(S){case"frontend":T[S]=Y?.name??(Q==="cli"?"CLI":"");break;case"css_framework":T[S]=q?.name??"";break;case"ui_library":T[S]=W?.name??"";break;case"state_management":T[S]=A?I?.name??"Runes":I?.name??"";break;case"backend":T[S]=A?C?"SvelteKit":V?.name??"":V?.name??"";break;case"api_type":T[S]=C?"Server Routes":"";break;case"runtime":T[S]=J!=="Unknown"?J:"";break;case"database":T[S]=O?.name??"";break;case"connection":T[S]=O?.name??"";break;case"hosting":if(A&&w)T[S]=w;else T[S]=_??"";break;case"build":T[S]=A?"Vite":B??"";break;case"cicd":T[S]=G??"";break;case"package_manager":T[S]=H;break;default:T[S]="";break}}let c={},E=y.filter((j)=>j.path.startsWith("monorepo."));for(let j of E){let S=j.path.replace("monorepo.","");if(!L.includes(j.category))c[S]="slotignored";else c[S]=""}let m0={name:Z?.name??$.split("/").pop()??"project",goal:Z?.description??"",main_language:X,type:Q};if(R&&N)m0.framework=N;let z3=M6($,Z,z,X),X3=R6($),U3=F6($,Z),F$={faf_version:G6,project:m0,stack:T,human_context:{who:"",what:Z?.description??"",why:"",where:"",when:"",how:""},monorepo:c,_meta:{found:U.found}};if(z3.length>0)F$.tech_stack=z3;if(X3.length>0)F$.key_files=X3;if(Object.keys(U3).length>0)F$.commands=U3;return F$}import{existsSync as EG,readFileSync as gG}from"fs";import{join as fG}from"path";var P6={MIN_LENGTH:8,MAX_LENGTH:280},SG=[/^(see|see\s+the?)\s+readme/i,/^(tbd|todo|fixme|coming\s+soon)\b/i,/^(software|application|app|project|tool|library|framework)\.?$/i,/^(for\s+users|for\s+developers)\.?$/i,/^(description|goal|name|title)\.?$/i,/^lorem\s+ipsum/i,/^example(\s+\w+)?\.?$/i];function l($){let Z=$.trim();if(Z.length<P6.MIN_LENGTH)return!1;if(Z.length>P6.MAX_LENGTH)return!1;if(SG.some((z)=>z.test(Z)))return!1;if(/^[\s|\-*+]/.test(Z))return!1;if(Z.split(`
219
- `).length>4)return!1;return!0}function yG($){let Z=$.split(`
220
- `),z=0;while(z<Z.length&&/^(#\s|$)/.test(Z[z].trim()))z++;while(z<Z.length){let X=Z[z].trim();if(/^\[!\[/.test(X)){z++;continue}if(/^!\[/.test(X)){z++;continue}if(/^<img\s/i.test(X)){z++;continue}if(X===""){z++;continue}break}return Z.slice(z).join(`
221
- `)}function hG($){let z=yG($).split(`
222
- `),X=[];for(let U of z){let Q=U.trim();if(Q===""){if(X.length>0)break;continue}if(/^(#|>|```|---|\||\s*[-*+]\s|\d+\.\s)/.test(Q))break;if(/^\*\*[^*]+\*\*\s*$/.test(Q)&&X.length===0)continue;X.push(Q)}if(X.length===0)return null;return X.join(" ").trim()}function M0($,Z){let z=$.split(`
223
- `),X=0;while(X<z.length){let Q=z[X].trim().match(/^(#{1,6})\s+(.+)$/);if(Q&&Z.test(Q[2])){let J=Q[1].length,H=[];X++;while(X<z.length){let G=z[X].trim(),_=G.match(/^(#{1,6})\s+/);if(_&&_[1].length<=J)break;if(G===""){if(H.length>0)break;X++;continue}if(/^(>|```|---|\||\s*[-*+]\s|\d+\.\s)/.test(G))break;H.push(G),X++}if(H.length===0)return null;return H.join(" ").trim()}X++}return null}function xG($){let Z=M0($,/^(use\s+cases?|goal)\b/i);if(Z&&l(Z))return Z;let z=hG($);if(z&&l(z))return z;return}function uG($){let Z=M0($,/^(about|description|overview|what(\s+is\s+this)?)\b/i);if(Z&&l(Z))return Z;return}function kG($){let Z=M0($,/^(audience|users?|for\s+whom|who(\s+is\s+this\s+for)?)\b/i);if(Z&&l(Z))return Z;return}function vG($){let Z=M0($,/^(why|motivation|problem|rationale)\b/i);if(Z&&l(Z))return Z;return}function mG($){let Z=M0($,/^(deployment|where(\s+it\s+runs)?|hosting)\b/i);if(Z&&l(Z))return Z;return}function pG($){let Z=M0($,/^(status|history|timeline|since|launched)\b/i);if(Z&&l(Z))return Z;return}function lG($){let Z=M0($,/^(architecture|how(\s+it\s+works)?|approach|design)\b/i);if(Z&&l(Z))return Z;return}function $3($){let Z=["README.md","README.MD","Readme.md","readme.md"],z=null;for(let W of Z){let I=fG($,W);if(EG(I)){z=I;break}}if(!z)return{};let X;try{X=gG(z,"utf-8")}catch{return{}}let U={},Q=xG(X);if(Q)U.project={goal:Q};let J={},H=uG(X);if(H)J.what=H;let G=kG(X);if(G)J.who=G;let _=vG(X);if(_)J.why=_;let B=mG(X);if(B)J.where=B;let Y=pG(X);if(Y)J.when=Y;let q=lG(X);if(q)J.how=q;if(Object.keys(J).length>0)U.human_context=J;return U}import{existsSync as dG,readFileSync as cG}from"fs";import{join as iG}from"path";function sG($,Z){let z=$.split(`
224
- `),X=!1;for(let U of z){let Q=U.trim();if(/^\[/.test(Q)){X=Q==="[package]";continue}if(!X)continue;let J=Q.match(new RegExp(`^${Z}\\s*=\\s*(.+)$`));if(J){let H=J[1].trim();H=H.replace(/\s*#.*$/,"").trim();let G=H.match(/^"((?:[^"\\]|\\.)*)"$/)||H.match(/^'((?:[^'\\]|\\.)*)'$/);if(G)return G[1];return H}}return null}function Z3($){let Z=iG($,"Cargo.toml");if(!dG(Z))return{};let z;try{z=cG(Z,"utf-8")}catch{return{}}let X=sG(z,"description");if(X&&l(X))return{project:{goal:X}};return{}}function aG($,Z){let z={project:{...Z.project??{},...$.project??{}},human_context:{...Z.human_context??{},...$.human_context??{}}};if(z.project&&Object.keys(z.project).length===0)delete z.project;if(z.human_context&&Object.keys(z.human_context).length===0)delete z.human_context;return z}function T6($){return aG($3($),Z3($))}function rG($){let Z=K6($),z=T6($),X=F1(Z,z);nG(X);let U=F1(X,o2($));return F1(U,{human_context:t2($)})}function nG($){let Z=$.project?.type??"library",z=K0[Z]||K0.library;for(let X of y){if(z.includes(X.category))continue;let[U,Q]=X.path.split(".");if(U==="stack"&&$.stack)$.stack[Q]="slotignored";if(U==="monorepo"&&$.monorepo)$.monorepo[Q]="slotignored"}}function F1($,Z){let z={...$};for(let[X,U]of Object.entries(Z)){let Q=z[X];if(Y0(Q))z[X]=U;else if(typeof U==="object"&&U!==null&&!Array.isArray(U)&&typeof Q==="object"&&Q!==null&&!Array.isArray(Q))z[X]=F1(Q,U)}return z}export{ZH as writeServerCard,iJ as writeProjectHtml,m6 as validateFaf,h0 as utcNow,o2 as turboCatSlots,z6 as turboCatScan,j6 as slotsByCategory,p9 as seedSixWsFromGoal,N1 as scoreFafYaml,KH as runLoop,H6 as relentlessContextDetailed,t2 as relentlessContext,eJ as registryName,tJ as registryMeta,D9 as readFafRaw,xJ as readFaf,d2 as questionForSlot,wH as publicQuestions,W1 as normalizeAnswer,c9 as loopVerdict,A1 as kernel,Y0 as isPlaceholder,l9 as isHumanSlot,O1 as isEmptyValue,IH as interviewForMissing,bH as gradeAnswers,i0 as getTier,g6 as getNextTier,w9 as generateServerCard,P9 as generateProjectHtml,f9 as fromClaudeDir,R9 as findFafFile,u2 as fafContextBlock,J3 as enrichScore,NH as deriveQuestionSet,d9 as classifyGaps,L$ as canonicalPriority,FH as buildTableOf8,CH as buildReceipt,rG as assembleFreshFaf,r9 as answersMatch,a as TIERS,v9 as STACK_INTERVIEW,l0 as SLOT_BY_PATH,y as SLOTS,l2 as SIX_WS_INTERVIEW,b9 as REGISTRY_PUBLISHER_KEY,_0 as PRIORITY_RANK,k2 as PRIORITY_ORDER,M$ as PLACEHOLDERS,V1 as KNOWLEDGE_TYPES,k9 as INTERVIEW_VERSION,WH as INTERVIEW_PATHS,m9 as INTERVIEW_BY_PATH,u0 as INTERVIEW,D0 as FafmSoul,c0 as FAF_HEX,E6 as ENTERPRISE_SLOTS,i2 as BENCH_VERSION,S6 as BASE_SLOTS,a9 as ALIAS_GROUPS};
219
+ `).replace(/<[^>]+>/g,"").replace(/!\[[^\]]*\]\([^)]*\)/g,"").trim()}function A0($){return $.replace(/\s+/g," ").replace(/[#*`>]/g,"").trim().slice(0,280)}function c0($,Z){let U=new RegExp(`##?\\s+(${Z})\\s*\\n+([\\s\\S]+?)(?:\\n\\n|\\n##?|$)`,"i"),X=$.match(U);return X&&X[2]&&X[2].trim().length>20?{body:A0(X[2]),heading:X[1].trim()}:null}function C1($,Z,U=30){for(let X of Z){let Q=$.match(X);if(Q&&Q[1]&&Q[1].trim().length>=U)return A0(Q[1])}return null}function BY($,Z){if($?.description&&$.description.length>20)return f(A0($.description),"package.json:description",0.95);let U=c0(Z,"Purpose|What|About|Overview|Description");if(U)return f(U.body,`README:## ${U.heading}`,0.8);let X=Z.split(/\n\s*\n/).map((z)=>z.trim()).find((z)=>z.length>30&&!z.startsWith("#"));if(X)return f(A0(X),"README:first-paragraph",0.5);let Q=C1(Z,[/(?:core|main|primary)\s+(?:problem|challenge)(?:\s+is)?\s*:?\s*([^.\n]{30,})/i,/solves?\s+(?:the\s+)?(?:problem\s+of\s+)?([^.\n]{30,})/i]);return Q?f(Q,"README:problem-heuristic",0.6):null}function VY($){let Z=c0($,"Audience|Who|Who is this for|Who it.s for");if(Z)return f(Z.body,`README:## ${Z.heading}`,0.8);let U=C1($,[/\b(?:designed|built|made)\s+for\s+((?:[a-z][a-z-]*\s+)?(?:developers?|teams?|engineers?|builders?|founders?)[^.\n]{0,80})/i,/\bfor\s+((?:[a-z][a-z-]*\s+)?(?:developers?|teams?|engineers?|builders?|founders?)[^.\n]{0,80})/i],8);return U?f(U,"README:audience-heuristic",0.6):null}function OY($){let Z=c0($,"Why|Mission|Motivation|Rationale|Vision");if(Z)return f(Z.body,`README:## ${Z.heading}`,0.8);let U=C1($,[/(?:our\s+|the\s+)?(?:mission|purpose|goal)\s+is\s+([^.\n]{30,})/i,/\b(?:mission|purpose|goal)\s*:\s*([^.\n]{30,})/i,/(?:built|created|designed)\s+(?:because|to)\s+([^.\n]{30,})/i]);return U?f(U,"README:mission-heuristic",0.6):null}function WY($,Z){let U=typeof $?.repository==="string"?$.repository:$?.repository?.url;if(U)return f(A0(U.replace(/^git\+/,"").replace(/\.git$/,"")),"package.json:repository",0.95);if($?.homepage)return f(A0($.homepage),"package.json:homepage",0.9);let X=C1(Z,[/\b(?:deployed|hosted|available|published)\s+(?:on|at|via)\s+([^.\n]{3,80})/i],3);return X?f(X,"README:deploy-heuristic",0.6):null}function DY($){let Z=c0($,"Timeline|Status|Release|Roadmap");if(Z)return f(Z.body,`README:## ${Z.heading}`,0.8);let U=C1($,[/\b(production\s+since\s+[^.\n]{4,60})/i,/\b((?:in\s+)?(?:production|beta|alpha|development)\s+since\s+[^.\n]{4,60})/i,/\bsince\s+((?:[A-Z][a-z]+\s+)?\d{4}[^.\n]{0,40})/],4);return U?f(U,"README:since-heuristic",0.6):null}function IY($,Z){let U=$?.scripts?Object.keys($.scripts):[],X=["start","dev","build"].filter((J)=>U.includes(J));if(X.length)return f(A0(X.map((J)=>`npm run ${J}`).join(", ")),"package.json:scripts",0.9);let Q=c0(Z,"Usage|Getting Started|Install|Installation|Quick Start");if(Q)return f(Q.body,`README:## ${Q.heading}`,0.8);let z=c0(Z,"Architecture|Approach|How it works|Methodology|How");return z?f(z.body,`README:## ${z.heading}`,0.7):null}var w9="3.0";import{existsSync as K,readFileSync as Z0,readdirSync as b9}from"fs";import{join as M}from"path";var C9=[{name:"Next.js",slug:"nextjs",category:"frontend",signals:[{type:"dependency",key:"next"},{type:"file",pattern:"next.config.*"}]},{name:"React",slug:"react",category:"frontend",signals:[{type:"dependency",key:"react"}]},{name:"SvelteKit",slug:"sveltekit",category:"frontend",signals:[{type:"dependency",key:"@sveltejs/kit"},{type:"file",pattern:"svelte.config.*"}]},{name:"Svelte",slug:"svelte",category:"frontend",signals:[{type:"dependency",key:"svelte"},{type:"devDependency",key:"svelte"}]},{name:"Vue.js",slug:"vue",category:"frontend",signals:[{type:"dependency",key:"vue"}]},{name:"Nuxt",slug:"nuxt",category:"frontend",signals:[{type:"dependency",key:"nuxt"},{type:"file",pattern:"nuxt.config.*"}]},{name:"Angular",slug:"angular",category:"frontend",signals:[{type:"dependency",key:"@angular/core"},{type:"file",pattern:"angular.json"}]},{name:"Astro",slug:"astro",category:"frontend",signals:[{type:"dependency",key:"astro"},{type:"file",pattern:"astro.config.*"}]},{name:"Solid",slug:"solid",category:"frontend",signals:[{type:"dependency",key:"solid-js"}]},{name:"Remix",slug:"remix",category:"frontend",signals:[{type:"dependency",key:"@remix-run/react"}]},{name:"Gatsby",slug:"gatsby",category:"frontend",signals:[{type:"dependency",key:"gatsby"},{type:"file",pattern:"gatsby-config.*"}]},{name:"Qwik",slug:"qwik",category:"frontend",signals:[{type:"dependency",key:"@builder.io/qwik"}]},{name:"Vercel (SvelteKit)",slug:"adapter-vercel",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-vercel"},{type:"devDependency",key:"@sveltejs/adapter-vercel"}]},{name:"Node (SvelteKit)",slug:"adapter-node",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-node"},{type:"devDependency",key:"@sveltejs/adapter-node"}]},{name:"Static (SvelteKit)",slug:"adapter-static",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-static"},{type:"devDependency",key:"@sveltejs/adapter-static"}]},{name:"Cloudflare (SvelteKit)",slug:"adapter-cloudflare",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-cloudflare"},{type:"devDependency",key:"@sveltejs/adapter-cloudflare"}]},{name:"Netlify (SvelteKit)",slug:"adapter-netlify",category:"hosting",signals:[{type:"dependency",key:"@sveltejs/adapter-netlify"},{type:"devDependency",key:"@sveltejs/adapter-netlify"}]},{name:"Tailwind CSS",slug:"tailwind",category:"css",signals:[{type:"dependency",key:"tailwindcss"},{type:"devDependency",key:"tailwindcss"},{type:"file",pattern:"tailwind.config.*"}]},{name:"Bootstrap",slug:"bootstrap",category:"css",signals:[{type:"dependency",key:"bootstrap"}]},{name:"Styled Components",slug:"styled-components",category:"css",signals:[{type:"dependency",key:"styled-components"}]},{name:"shadcn/ui",slug:"shadcn",category:"ui",signals:[{type:"file",pattern:"components.json"},{type:"dependency",key:"@radix-ui/react-dialog"}]},{name:"Material UI",slug:"mui",category:"ui",signals:[{type:"dependency",key:"@mui/material"}]},{name:"Chakra UI",slug:"chakra",category:"ui",signals:[{type:"dependency",key:"@chakra-ui/react"}]},{name:"Ant Design",slug:"antd",category:"ui",signals:[{type:"dependency",key:"antd"}]},{name:"Redux",slug:"redux",category:"state",signals:[{type:"dependency",key:"@reduxjs/toolkit"}]},{name:"Zustand",slug:"zustand",category:"state",signals:[{type:"dependency",key:"zustand"}]},{name:"Jotai",slug:"jotai",category:"state",signals:[{type:"dependency",key:"jotai"}]},{name:"Pinia",slug:"pinia",category:"state",signals:[{type:"dependency",key:"pinia"}]},{name:"Express",slug:"express",category:"backend",signals:[{type:"dependency",key:"express"}]},{name:"Fastify",slug:"fastify",category:"backend",signals:[{type:"dependency",key:"fastify"}]},{name:"Hono",slug:"hono",category:"backend",signals:[{type:"dependency",key:"hono"}]},{name:"Elysia",slug:"elysia",category:"backend",signals:[{type:"dependency",key:"elysia"}]},{name:"NestJS",slug:"nestjs",category:"backend",signals:[{type:"dependency",key:"@nestjs/core"}]},{name:"Koa",slug:"koa",category:"backend",signals:[{type:"dependency",key:"koa"}]},{name:"Django",slug:"django",category:"backend",signals:[{type:"file",pattern:"manage.py"},{type:"file",pattern:"settings.py"}]},{name:"Flask",slug:"flask",category:"backend",signals:[{type:"file",pattern:"app.py"}]},{name:"FastAPI",slug:"fastapi",category:"backend",signals:[{type:"file",pattern:"main.py"}]},{name:"Rails",slug:"rails",category:"backend",signals:[{type:"file",pattern:"Gemfile"},{type:"file",pattern:"config/routes.rb"}]},{name:"Spring Boot",slug:"spring",category:"backend",signals:[{type:"file",pattern:"pom.xml"},{type:"file",pattern:"build.gradle"}]},{name:"Prisma",slug:"prisma",category:"database",signals:[{type:"dependency",key:"prisma"},{type:"devDependency",key:"prisma"},{type:"file",pattern:"prisma/schema.prisma"}]},{name:"Drizzle",slug:"drizzle",category:"database",signals:[{type:"dependency",key:"drizzle-orm"},{type:"file",pattern:"drizzle.config.*"}]},{name:"TypeORM",slug:"typeorm",category:"database",signals:[{type:"dependency",key:"typeorm"}]},{name:"Mongoose",slug:"mongoose",category:"database",signals:[{type:"dependency",key:"mongoose"}]},{name:"Vite",slug:"vite",category:"build",signals:[{type:"dependency",key:"vite"},{type:"devDependency",key:"vite"},{type:"file",pattern:"vite.config.*"}]},{name:"webpack",slug:"webpack",category:"build",signals:[{type:"dependency",key:"webpack"},{type:"devDependency",key:"webpack"},{type:"file",pattern:"webpack.config.*"}]},{name:"esbuild",slug:"esbuild",category:"build",signals:[{type:"dependency",key:"esbuild"},{type:"devDependency",key:"esbuild"}]},{name:"Turbopack",slug:"turbopack",category:"build",signals:[{type:"file",pattern:"turbo.json"}]},{name:"Jest",slug:"jest",category:"testing",signals:[{type:"devDependency",key:"jest"},{type:"file",pattern:"jest.config.*"}]},{name:"Vitest",slug:"vitest",category:"testing",signals:[{type:"devDependency",key:"vitest"}]},{name:"Playwright",slug:"playwright",category:"testing",signals:[{type:"devDependency",key:"@playwright/test"},{type:"file",pattern:"playwright.config.*"}]},{name:"Cypress",slug:"cypress",category:"testing",signals:[{type:"devDependency",key:"cypress"},{type:"file",pattern:"cypress.config.*"}]},{name:"Turborepo",slug:"turborepo",category:"monorepo",signals:[{type:"devDependency",key:"turbo"},{type:"file",pattern:"turbo.json"}]},{name:"Nx",slug:"nx",category:"monorepo",signals:[{type:"devDependency",key:"nx"},{type:"file",pattern:"nx.json"}]},{name:"Lerna",slug:"lerna",category:"monorepo",signals:[{type:"devDependency",key:"lerna"},{type:"file",pattern:"lerna.json"}]},{name:"MCP SDK",slug:"mcp",category:"ai",signals:[{type:"dependency",key:"@modelcontextprotocol/sdk"}]},{name:"Anthropic SDK",slug:"anthropic",category:"ai",signals:[{type:"dependency",key:"@anthropic-ai/sdk"}]},{name:"OpenAI SDK",slug:"openai",category:"ai",signals:[{type:"dependency",key:"openai"}]},{name:"LangChain",slug:"langchain",category:"ai",signals:[{type:"dependency",key:"langchain"}]},{name:"Vercel",slug:"vercel",category:"hosting",signals:[{type:"file",pattern:"vercel.json"}]},{name:"Netlify",slug:"netlify",category:"hosting",signals:[{type:"file",pattern:"netlify.toml"}]},{name:"Docker",slug:"docker",category:"hosting",signals:[{type:"file",pattern:"Dockerfile"},{type:"file",pattern:"docker-compose.yml"}]},{name:"Cloudflare Workers",slug:"cloudflare",category:"hosting",signals:[{type:"file",pattern:"wrangler.toml"},{type:"dependency",key:"wrangler"}]},{name:"GitHub Actions",slug:"github-actions",category:"cicd",signals:[{type:"file",pattern:".github/workflows/*.yml"}]},{name:"Commander.js",slug:"commander",category:"cli",signals:[{type:"dependency",key:"commander"}]}];function LY($){let Z=M($,"Cargo.toml");if(!K(Z))return null;try{let X=Z0(Z,"utf-8").match(/^\s*\[package\][\s\S]*?^\s*name\s*=\s*"([^"]+)"/m);return X?X[1]:null}catch{return null}}function RY($){let Z=M($,"Cargo.toml");if(!K(Z))return!1;try{let U=Z0(Z,"utf-8");return/^\s*\[\[bin\]\]/m.test(U)}catch{return!1}}function MY($,Z){if(Z?.keywords?.some((X)=>/^sdk(?:\s|-|$)|-sdk$/i.test(X)))return'package.json keywords contains "sdk"';if(Z?.name&&/(?:^|[-_/])sdk(?:[-_/]|$)/i.test(Z.name))return`package.json name "${Z.name}" → sdk`;let U=LY($);if(U&&/(?:^|[-_])sdk(?:[-_]|$)/i.test(U))return`Cargo.toml name "${U}" → sdk`;return null}function KY($){let Z=["manifest.json","public/manifest.json","src/manifest.json","app/manifest.json","extension/manifest.json","dist/manifest.json"];for(let U of Z){let X=M($,U);if(!K(X))continue;try{let Q=JSON.parse(Z0(X,"utf-8"));if(typeof Q.manifest_version==="number")return`${U} manifest_version ${Q.manifest_version} (browser extension)`}catch{}}return null}function FY($){let Z=/(numpy|pandas|jupyter|scikit-learn|sklearn|pytorch|tensorflow|matplotlib|scipy)/i,U=M($,"pyproject.toml");if(K(U))try{let z=Z0(U,"utf-8").match(Z);if(z)return`pyproject.toml depends on ${z[1]}`}catch{}let X=M($,"requirements.txt");if(K(X))try{let z=Z0(X,"utf-8").match(Z);if(z)return`requirements.txt contains ${z[1]}`}catch{}return null}function PY($,Z){let U=["react-native","expo","@capacitor/core","@ionic/core"];if(Z){for(let X of U)if(Z.dependencies?.[X]||Z.devDependencies?.[X])return`${X} dependency`}if(K(M($,"ios"))&&K(M($,"android")))return"ios/ + android/ dirs";return null}function AY($,Z){let U=M($,"Cargo.toml");if(K(U))try{let Q=Z0(U,"utf-8");if(/crate-type\s*=\s*\[[^\]]*"cdylib"/.test(Q))return'Cargo.toml crate-type = ["cdylib"]';if(/wasm-bindgen|wasm-pack/i.test(Q))return"Cargo.toml wasm-bindgen/wasm-pack"}catch{}let X=M($,"build.zig");if(K(X))try{let Q=Z0(X,"utf-8");if(/\.wasm\b|wasm32|setOutputFormat\(\.wasm/i.test(Q))return"build.zig wasm target"}catch{}if(Z?.keywords?.some((Q)=>/^wasm(?:-|$)|webassembly/i.test(Q)))return'package.json keywords contains "wasm"';return null}function TY($,Z){if(!K(M($,"index.html")))return null;if(Z?.dependencies||Z?.devDependencies){let U={...Z.dependencies??{},...Z.devDependencies??{}};if(["react","vue","svelte","@sveltejs/kit","next","nuxt","astro","gatsby","solid-js","qwik"].some((Q)=>U[Q]))return null}return"index.html (vanilla, no frontend framework)"}function NY($,Z){if(Z?.name&&/specification|^@.*\/spec/i.test(Z.name))return`package name "${Z.name}" → documentation`;if(Z?.keywords?.some((U)=>/^(specification|format-spec|standard)$/i.test(U)))return'package keywords contains "specification"';if(Z?.bin)return null;if(Z?.files&&Z.files.length>0){let U=/^(dist|src|lib|build|bin)(\/|$)|\/(dist|src|lib|build|bin)(\/|$)|(\.|\/)(js|ts|tsx|jsx|mjs|cjs|py|rs|go)$/,X=Z.files.some((z)=>U.test(z)),Q=Z.files.some((z)=>/\.(md|MD)$|examples?\//.test(z)||z==="README.md"||z==="docs"||z==="docs/");if(!X&&Q)return"package.json files = docs/examples only (no source)"}return null}function wY($,Z,U){let X=U.find((Q)=>Q.slug==="astro"||Q.slug==="gatsby");if(X)return`${X.name} (static-site framework)`;if(Z?.keywords?.some((Q)=>/^(website|marketing|landing|brochure|portfolio)$/i.test(Q)))return'package keywords contains "website"/"marketing"/"landing"';return null}function CY($,Z){if(!Z)return null;let U={...Z.dependencies??{},...Z.devDependencies??{}},X=["@clerk/nextjs","@clerk/clerk-react","next-auth","@auth/core","auth0","@auth0/nextjs-auth0"],Q=["stripe","@stripe/stripe-js","lemonsqueezy"],z=X.some((H)=>U[H]),J=Q.some((H)=>U[H]);if(z&&J)return"auth + payment dependencies";return null}function bY($,Z,U){if(Z?.keywords?.some((z)=>/mcpaas/i.test(z)))return'package keywords contains "mcpaas"';if(Z?.name&&/mcpaas/i.test(Z.name))return`package name "${Z.name}" → mcpaas`;let X=U.some((z)=>z.slug==="mcp"),Q=U.some((z)=>z.category==="database");if(X&&Q&&Z?.dependencies&&Object.keys(Z.dependencies).length>10)return"MCP + database + complex deps (platform shape)";return null}function SY($,Z){if(!Z?.private)return null;if(!(!!Z.workspaces||K(M($,"pnpm-workspace.yaml"))))return null;return"private workspace + multi-package"}function T0($){let Z=M($,"package.json");if(!K(Z))return null;try{return JSON.parse(Z0(Z,"utf-8"))}catch{return null}}function EY($,Z){if(!Z.includes("*"))return K(M($,Z));let U=Z.split("/");if(U.length===1){let H=Z.split("*")[0];try{return b9($).some((q)=>q.startsWith(H))}catch{return!1}}let X=M($,...U.slice(0,-1)),Q=U[U.length-1],z=Q.split("*")[0],J=Q.split("*")[1]||"";try{return b9(X).some((H)=>H.startsWith(z)&&H.endsWith(J))}catch{return!1}}function jY($,Z,U){switch($.type){case"dependency":return!!Z?.dependencies?.[$.key];case"devDependency":return!!Z?.devDependencies?.[$.key];case"file":return EY(U,$.pattern);default:return!1}}function B3($){let Z=T0($);return C9.map((U)=>{let Q=U.signals.filter((z)=>jY(z,Z,$)).length/U.signals.length;return{name:U.name,slug:U.slug,category:U.category,confidence:Q}}).filter((U)=>U.confidence>0).sort((U,X)=>X.confidence-U.confidence)}function S9($){let Z=T0($);if(Z?.devDependencies?.typescript||Z?.dependencies?.typescript)return"TypeScript";if(K(M($,"tsconfig.json")))return"TypeScript";if(K(M($,"Cargo.toml")))return"Rust";if(K(M($,"go.mod")))return"Go";if(A1($).length>0)return"C#";if(K(M($,"pyproject.toml"))||K(M($,"setup.py")))return"Python";if(K(M($,"Gemfile")))return"Ruby";if(q3($)){let U=w1($);if(U)return U.mainLanguage==="Java/Kotlin"?"Kotlin":U.mainLanguage;return"Java"}if(K(M($,"Package.swift")))return"Swift";if(K(M($,"build.zig")))return"Zig";if(K(M($,"pubspec.yaml")))return"Dart";if(Z)return"JavaScript";return"Unknown"}function E9($){let Z=T0($),U=B3($),X=[],Q=NY($,Z);if(Q)return X.push(Q),{type:"documentation",found:X};let z=MY($,Z);if(z)return X.push(z),{type:"sdk",found:X};let J=KY($);if(J)return X.push(J),{type:"extension",found:X};let H=bY($,Z,U);if(H)return X.push(H),{type:"mcpaas",found:X};let q=CY($,Z);if(q)return X.push(q),{type:"saas",found:X};let Y=AY($,Z);if(Y)return X.push(Y),{type:"wasm",found:X};let G=T$($);if(G)return X.push(G.found),{type:G.appType,found:X};let _=C$($);if(_)return X.push(_.found),{type:_.appType,found:X};let B=S$($);if(B)return X.push(B.found),{type:B.appType,found:X};let O=w1($);if(O)return X.push(O.found),{type:O.appType,found:X};let D=PY($,Z);if(D)return X.push(D),{type:"mobile",found:X};if(U.some((S)=>S.slug==="mcp"))return X.push("MCP SDK signal"),{type:"mcp",found:X};if(Z?.bin)return X.push("package.json bin"),{type:"cli",found:X};if(RY($))return X.push("Cargo.toml [[bin]]"),{type:"cli",found:X};if(K(M($,"build.zig"))){if(X.push("build.zig"),K(M($,"src/main.zig")))return X.push("src/main.zig"),{type:"cli",found:X};if(K(M($,"src/root.zig")))return X.push("src/root.zig"),{type:"library",found:X}}let W=U.some((S)=>S.slug==="svelte"||S.slug==="sveltekit");if(Z?.private===!0&&(K(M($,"pnpm-workspace.yaml"))||Z?.workspaces!==void 0)&&W)return X.push("private workspace","Svelte"),{type:"framework",found:X};if(W)return X.push("Svelte/SvelteKit"),{type:"svelte",found:X};let L=U.some((S)=>S.category==="frontend"),F=U.some((S)=>S.category==="backend");if(Z?.private&&(Z.workspaces||K(M($,"pnpm-workspace.yaml")))&&L&&F)return X.push("private workspace + frontend + backend frameworks"),{type:"enterprise",found:X};let A=SY($,Z);if(A)return X.push(A),{type:"monorepo-root",found:X};let T=wY($,Z,U);if(T)return X.push(T),{type:"website",found:X};if(U.some((S)=>S.slug==="nextjs"||S.slug==="nuxt"))return X.push(U.find((S)=>S.slug==="nextjs")?"Next.js":"Nuxt"),{type:"fullstack",found:X};let b=U.some((S)=>S.category==="frontend"),P=U.some((S)=>S.category==="backend");if(b&&P)return X.push("frontend framework","backend framework"),{type:"fullstack",found:X};if(b)return X.push("frontend framework"),{type:"frontend",found:X};if(P)return X.push("backend framework"),{type:"backend",found:X};let w=FY($);if(w)return X.push(w),{type:"data-science",found:X};let v=TY($,Z);if(v)return X.push(v),{type:"html",found:X};if(Z?.main&&!Z?.bin)return X.push("package.json main (no bin)"),{type:"library",found:X};return X.push("no classifying signals — fallback"),{type:"library",found:X}}function j9($){if(K(M($,"bunfig.toml")))return"Bun";if(K(M($,"deno.json"))||K(M($,"deno.jsonc")))return"Deno";if(T0($))return"Node.js";if(K(M($,"Cargo.toml")))return"Rust";if(K(M($,"go.mod")))return"Go";if(A1($).length>0)return".NET";if(K(M($,"pubspec.yaml")))return"Dart";return"Unknown"}function g9($){if(K(M($,"pubspec.yaml")))return"pub";if(K(M($,"go.mod")))return"go modules";if(A1($).length>0)return"NuGet";if(K(M($,"pom.xml")))return"maven";if(K(M($,"build.gradle"))||K(M($,"build.gradle.kts"))||K(M($,"settings.gradle"))||K(M($,"settings.gradle.kts")))return"gradle";if(K(M($,"bun.lockb"))||K(M($,"bun.lock")))return"bun";if(K(M($,"pnpm-lock.yaml")))return"pnpm";if(K(M($,"yarn.lock")))return"yarn";if(K(M($,"package-lock.json")))return"npm";return"npm"}function x9($){if(K(M($,".github/workflows")))return"GitHub Actions";if(K(M($,".gitlab-ci.yml")))return"GitLab CI";if(K(M($,".circleci")))return"CircleCI";if(K(M($,"Jenkinsfile")))return"Jenkins";return null}function h9($){if(K(M($,"vercel.json")))return"Vercel";if(K(M($,"netlify.toml")))return"Netlify";if(K(M($,"wrangler.toml")))return"Cloudflare";if(K(M($,"Dockerfile")))return"Docker";if(K(M($,"fly.toml")))return"Fly.io";if(K(M($,"render.yaml")))return"Render";return null}function y9($){let Z=M($,"svelte.config.js");if(!K(Z))return null;try{let X=Z0(Z,"utf-8").match(/@sveltejs\/adapter-(\w+)/);if(X){let Q=X[1];switch(Q){case"vercel":return"Vercel";case"node":return"Node";case"static":return"Static";case"cloudflare":return"Cloudflare";case"netlify":return"Netlify";case"auto":return"Auto";default:return Q}}return null}catch{return null}}function f9($){let Z=T0($);if(Z?.devDependencies?.vite||Z?.dependencies?.vite)return"Vite";if(Z?.devDependencies?.webpack||Z?.dependencies?.webpack)return"webpack";if(Z?.devDependencies?.esbuild||Z?.dependencies?.esbuild)return"esbuild";if(K(M($,"tsconfig.json"))&&Z?.devDependencies?.typescript)return"TypeScript (tsc)";return null}function u9($){return["package.json","Cargo.toml","pyproject.toml","go.mod","build.zig","build.zig.zon","src/index.ts","src/index.js","src/main.ts","src/cli.ts","src/main.rs","src/lib.rs","src/main.zig","src/root.zig","src/__init__.py","main.py","__main__.py","main.go","cmd/main.go","README.md","SPECIFICATION.md","BINARY-FORMAT.md","tsconfig.json","wrangler.toml","vercel.json"].filter((U)=>K(M($,U)))}function k9($,Z){let U={};if(Z?.scripts){for(let X of["build","test","lint","dev","start"])if(Z.scripts[X]){let Q=K(M($,"bun.lock"))||K(M($,"bun.lockb"))?"bun run":"npm run";U[X]=`${Q} ${X}`}}if(K(M($,"Cargo.toml"))){if(!U.build)U.build="cargo build --release";if(!U.test)U.test="cargo test";if(!U.lint)U.lint="cargo clippy"}if(K(M($,"build.zig"))){if(!U.build)U.build="zig build";if(!U.test)U.test="zig build test"}if(K(M($,"go.mod"))){if(!U.build)U.build="go build ./...";if(!U.test)U.test="go test ./..."}if(K(M($,"pyproject.toml"))||K(M($,"pytest.ini"))){if(!U.test)U.test="pytest"}return U}function v9($,Z,U,X){let Q=[];if(X&&X!=="Unknown")Q.push(X);let z=new Set(["frontend","backend","database","build","css","state","monorepo"]);for(let J of U)if(z.has(J.category))Q.push(J.name);if(K(M($,"bunfig.toml")))Q.push("Bun");else if(K(M($,"deno.json"))||K(M($,"deno.jsonc")))Q.push("Deno");if(Q.length<3&&Z?.dependencies){let J=Object.keys(Z.dependencies).slice(0,5);for(let H of J)if(!Q.some((q)=>q.toLowerCase().includes(H.toLowerCase())))Q.push(H)}return Q}function m9($){let Z=T0($),U=B3($),X=S9($),Q=E9($),z=Q.type,J=j9($),H=g9($),q=x9($),Y=h9($),G=f9($),_=U.find((E)=>E.category==="frontend"),B=U.find((E)=>E.category==="css"),O=U.find((E)=>E.category==="ui"),D=U.find((E)=>E.category==="state"),V=U.find((E)=>E.category==="backend"),W=U.find((E)=>E.category==="database"),I=w0[z]||w0.library,L=z==="framework",F=U.some((E)=>E.slug==="svelte"||E.slug==="sveltekit"),A=L&&F?"svelte":L?null:null,T=z==="svelte"||A==="svelte",N=T?y9($):null,b=T&&U.some((E)=>E.slug==="sveltekit"),P=new Set(["css_framework","ui_library","database","connection","hosting"]),w={},v=y.filter((E)=>E.path.startsWith("stack."));for(let E of v){let j=E.path.replace("stack.","");if(!I.includes(E.category)){w[j]="slotignored";continue}if(L&&P.has(j)){w[j]="slotignored";continue}switch(j){case"frontend":w[j]=_?.name??(z==="cli"?"CLI":"");break;case"css_framework":w[j]=B?.name??"";break;case"ui_library":w[j]=O?.name??"";break;case"state_management":w[j]=T?D?.name??"Runes":D?.name??"";break;case"backend":w[j]=T?b?"SvelteKit":V?.name??"":V?.name??"";break;case"api_type":w[j]=b?"Server Routes":"";break;case"runtime":w[j]=J!=="Unknown"?J:"";break;case"database":w[j]=W?.name??"";break;case"connection":w[j]=W?.name??"";break;case"hosting":if(T&&N)w[j]=N;else w[j]=Y??"";break;case"build":w[j]=T?"Vite":G??"";break;case"cicd":w[j]=q??"";break;case"package_manager":w[j]=H;break;default:w[j]="";break}}let S={},g=y.filter((E)=>E.path.startsWith("monorepo."));for(let E of g){let j=E.path.replace("monorepo.","");if(!I.includes(E.category))S[j]="slotignored";else S[j]=""}let i0={name:Z?.name??$.split("/").pop()??"project",goal:Z?.description??"",main_language:X,type:z};if(L&&A)i0.framework=A;let W3=v9($,Z,U,X),D3=u9($),I3=k9($,Z),b1={faf_version:w9,project:i0,stack:w,human_context:{who:"",what:Z?.description??"",why:"",where:"",when:"",how:""},monorepo:S,_meta:{found:Q.found}};if(W3.length>0)b1.tech_stack=W3;if(D3.length>0)b1.key_files=D3;if(Object.keys(I3).length>0)b1.commands=I3;return b1}import{existsSync as xY,readFileSync as hY}from"fs";import{join as yY}from"path";var p9={MIN_LENGTH:8,MAX_LENGTH:280},gY=[/^(see|see\s+the?)\s+readme/i,/^(tbd|todo|fixme|coming\s+soon)\b/i,/^(software|application|app|project|tool|library|framework)\.?$/i,/^(for\s+users|for\s+developers)\.?$/i,/^(description|goal|name|title)\.?$/i,/^lorem\s+ipsum/i,/^example(\s+\w+)?\.?$/i];function r($){let Z=$.trim();if(Z.length<p9.MIN_LENGTH)return!1;if(Z.length>p9.MAX_LENGTH)return!1;if(gY.some((U)=>U.test(Z)))return!1;if(/^[\s|\-*+]/.test(Z))return!1;if(Z.split(`
220
+ `).length>4)return!1;return!0}function fY($){let Z=$.split(`
221
+ `),U=0;while(U<Z.length&&/^(#\s|$)/.test(Z[U].trim()))U++;while(U<Z.length){let X=Z[U].trim();if(/^\[!\[/.test(X)){U++;continue}if(/^!\[/.test(X)){U++;continue}if(/^<img\s/i.test(X)){U++;continue}if(X===""){U++;continue}break}return Z.slice(U).join(`
222
+ `)}function uY($){let U=fY($).split(`
223
+ `),X=[];for(let Q of U){let z=Q.trim();if(z===""){if(X.length>0)break;continue}if(/^(#|>|```|---|\||\s*[-*+]\s|\d+\.\s)/.test(z))break;if(/^\*\*[^*]+\*\*\s*$/.test(z)&&X.length===0)continue;X.push(z)}if(X.length===0)return null;return X.join(" ").trim()}function N0($,Z){let U=$.split(`
224
+ `),X=0;while(X<U.length){let z=U[X].trim().match(/^(#{1,6})\s+(.+)$/);if(z&&Z.test(z[2])){let J=z[1].length,H=[];X++;while(X<U.length){let q=U[X].trim(),Y=q.match(/^(#{1,6})\s+/);if(Y&&Y[1].length<=J)break;if(q===""){if(H.length>0)break;X++;continue}if(/^(>|```|---|\||\s*[-*+]\s|\d+\.\s)/.test(q))break;H.push(q),X++}if(H.length===0)return null;return H.join(" ").trim()}X++}return null}function kY($){let Z=N0($,/^(use\s+cases?|goal)\b/i);if(Z&&r(Z))return Z;let U=uY($);if(U&&r(U))return U;return}function vY($){let Z=N0($,/^(about|description|overview|what(\s+is\s+this)?)\b/i);if(Z&&r(Z))return Z;return}function mY($){let Z=N0($,/^(audience|users?|for\s+whom|who(\s+is\s+this\s+for)?)\b/i);if(Z&&r(Z))return Z;return}function pY($){let Z=N0($,/^(why|motivation|problem|rationale)\b/i);if(Z&&r(Z))return Z;return}function lY($){let Z=N0($,/^(deployment|where(\s+it\s+runs)?|hosting)\b/i);if(Z&&r(Z))return Z;return}function dY($){let Z=N0($,/^(status|history|timeline|since|launched)\b/i);if(Z&&r(Z))return Z;return}function cY($){let Z=N0($,/^(architecture|how(\s+it\s+works)?|approach|design)\b/i);if(Z&&r(Z))return Z;return}function V3($){let Z=["README.md","README.MD","Readme.md","readme.md"],U=null;for(let O of Z){let D=yY($,O);if(xY(D)){U=D;break}}if(!U)return{};let X;try{X=hY(U,"utf-8")}catch{return{}}let Q={},z=kY(X);if(z)Q.project={goal:z};let J={},H=vY(X);if(H)J.what=H;let q=mY(X);if(q)J.who=q;let Y=pY(X);if(Y)J.why=Y;let G=lY(X);if(G)J.where=G;let _=dY(X);if(_)J.when=_;let B=cY(X);if(B)J.how=B;if(Object.keys(J).length>0)Q.human_context=J;return Q}import{existsSync as iY,readFileSync as rY}from"fs";import{join as sY}from"path";function aY($,Z){let U=$.split(`
225
+ `),X=!1;for(let Q of U){let z=Q.trim();if(/^\[/.test(z)){X=z==="[package]";continue}if(!X)continue;let J=z.match(new RegExp(`^${Z}\\s*=\\s*(.+)$`));if(J){let H=J[1].trim();H=H.replace(/\s*#.*$/,"").trim();let q=H.match(/^"((?:[^"\\]|\\.)*)"$/)||H.match(/^'((?:[^'\\]|\\.)*)'$/);if(q)return q[1];return H}}return null}function O3($){let Z=sY($,"Cargo.toml");if(!iY(Z))return{};let U;try{U=rY(Z,"utf-8")}catch{return{}}let X=aY(U,"description");if(X&&r(X))return{project:{goal:X}};return{}}function nY($,Z){let U={project:{...Z.project??{},...$.project??{}},human_context:{...Z.human_context??{},...$.human_context??{}}};if(U.project&&Object.keys(U.project).length===0)delete U.project;if(U.human_context&&Object.keys(U.human_context).length===0)delete U.human_context;return U}function l9($){return nY(V3($),O3($))}function oY($){let Z=m9($),U=l9($),X=E$(Z,U);tY(X);let Q=E$(X,G3($));return E$(Q,{human_context:_3($)})}function tY($){let Z=$.project?.type??"library",U=w0[Z]||w0.library;for(let X of y){if(U.includes(X.category))continue;let[Q,z]=X.path.split(".");if(Q==="stack"&&$.stack)$.stack[z]="slotignored";if(Q==="monorepo"&&$.monorepo)$.monorepo[z]="slotignored"}}function E$($,Z){let U={...$};for(let[X,Q]of Object.entries(Z)){let z=U[X];if(V0(z))U[X]=Q;else if(typeof Q==="object"&&Q!==null&&!Array.isArray(Q)&&typeof z==="object"&&z!==null&&!Array.isArray(z))U[X]=E$(z,Q)}return U}export{MH as writeServerCard,_H as writeProjectHtml,JZ as validateFaf,m0 as utcNow,G3 as turboCatSlots,K9 as turboCatScan,a9 as slotsByCategory,Z9 as seedSixWsFromGoal,f$ as scoreFafYaml,mH as runLoop,N9 as relentlessContextDetailed,_3 as relentlessContext,LH as registryName,IH as registryMeta,E6 as readFafRaw,UH as readFaf,Z3 as questionForSlot,iH as publicQuestions,A$ as normalizeAnswer,Q9 as loopVerdict,y$ as kernel,V0 as isPlaceholder,U9 as isHumanSlot,P$ as isEmptyValue,hH as interviewForMissing,rH as gradeAnswers,o0 as getTier,t9 as getNextTier,v6 as generateServerCard,y6 as generateProjectHtml,r6 as fromClaudeDir,j6 as findFafFile,a2 as fafContextBlock,R3 as enrichScore,cH as deriveQuestionSet,X9 as classifyGaps,F1 as canonicalPriority,kH as buildTableOf8,sH as buildReceipt,oY as assembleFreshFaf,q9 as answersMatch,n as TIERS,e6 as STACK_INTERVIEW,s0 as SLOT_BY_PATH,y as SLOTS,$3 as SIX_WS_INTERVIEW,m6 as REGISTRY_PUBLISHER_KEY,B0 as PRIORITY_RANK,n2 as PRIORITY_ORDER,S1 as PLACEHOLDERS,F$ as KNOWLEDGE_TYPES,t6 as INTERVIEW_VERSION,xH as INTERVIEW_PATHS,$9 as INTERVIEW_BY_PATH,l0 as INTERVIEW,K0 as FafmSoul,n0 as FAF_HEX,o9 as ENTERPRISE_SLOTS,X3 as BENCH_VERSION,n9 as BASE_SLOTS,H9 as ALIAS_GROUPS};
225
226
 
226
- //# debugId=E34BAE7E29E0A4C664756E2164756E21
227
+ //# debugId=FD10E0DD605B44E364756E2164756E21
227
228
  //# sourceMappingURL=index.js.map