"use strict";(()=>{varQe=Object.create;varae=Object.defineProperty;varPe=Object.getOwnPropertyDescriptor;varCe=Object.getOwnPropertyNames;varOe=Object.getPrototypeOf,Re=Object.prototype.hasOwnProperty;var_e=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);varMe=(t,e,n,r)=>{if(e&&typeofe=="object"||typeofe=="function")for(letiofCe(e))!Re.call(t,i)&&i!==n&&ae(t,i,{get:()=>e[i],enumerable:!(r=Pe(e,i))||r.enumerable});returnt};varDe=(t,e,n)=>(n=t!=null?Qe(Oe(t)):{},Me(e||!t||!t.__esModule?ae(n,"default",{value:t,enumerable:!0}):n,t));varde=_e((ce,he)=>{(function(){vart=function(e){varn=newt.Builder;returnn.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){returnfunction(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){returne==null?"":e.toString()},t.utils.clone=function(e){if(e==null)returne;for(varn=Object.create(null),r=Object.keys(e),i=0;i<r.length;i++){vars=r[i],o=e[s];if(Array.isArray(o)){n[s]=o.slice();continue}if(typeofo=="string"||typeofo=="number"||typeofo=="boolean"){n[s]=o;continue}thrownewTypeError("clone is not deep and does not support nested objects")}returnn},t.FieldRef=function(e,n,r){this.docRef=e,this.fieldName=n,this._stringValue=r},t.FieldRef.joiner="/",t.FieldRef.fromString=function(e){varn=e.indexOf(t.FieldRef.joiner);if(n===-1)throw"malformed field ref string";varr=e.slice(0,n),i=e.slice(n+1);returnnewt.FieldRef(i,r,e)},t.FieldRef.prototype.toString=function(){returnthis._stringValue==null&&(this._stringValue=this.fieldName+t.FieldRef.joiner+this.docRef),this._stringValue};t.Set=function(e){if(this.elements=Object.create(null),e){this.length=e.length;for(varn=0;n<this.length;n++)this.elements[e[n]]=!0}elsethis.length=0},t.Set.complete={intersect:function(e){returne},union:function(){returnthis},contains:function(){return!0}},t.Set.empty={intersect:function(){returnthis},union:function(e){returne},contains:function(){return!1}},t.Set.prototype.contains=function(e){return!!this.elements[e]},t.Set.prototype.intersect=function(e){varn,r,i,s=[];if(e===t.Set.complete)returnthis;if(e===t.Set.empty)returne;this.length<e.length?(n=this,r=e):(n=e,r=this),i=Object.keys(n.elements);for(varo=0;o<i.length;o++){vara=i[o];ainr.elements&&s.push(a)}returnnewt.Set(s)},t.Set.prototype.union=function(e){returne===t.Set.complete?t.Set.complete:e===t.Set.empty?this:newt.Set(Object.keys(this.elements).concat(Object.keys(e.elements)))},t.idf=function(e,n){varr=0;for(variine)i!="_index"&&(r+=Object.keys(e[i]).length);vars=(n-r+.5)/(r+.5);returnMath.log(1+Math.abs(s))},t.Token=function(e,n){this.str=e||"",this.metadata=n||{}},t.Token.prototype.toString=function(){returnthis.str},t.Token.prototype.update=function(e){returnthis.str=e(this.str,this.metadata),this},t.Token.prototype.clone=function(e){returne=e||function(n){returnn},newt.Token(e(this.str,this.metadata),this.metadata)};t.tokenizer=function(e,n){if(e==null||e==null)return[];if(Array.isArray(e))returne.map(function(m){returnnewt.Token(t.utils.asString(m).toLowerCase(),t.utils.clone(n))});for(varr=e.toString().toLowerCase(),i=r.length,s=[],o=0,a=0;o<=i;o++){varu=r.charAt(o),l=o-a;if(u.match(t.tokenizer.separator)||o==i){if(l>0){varh=t.utils.clone(n)||{};h.position=[a,l],h.index=s.length,s.push(newt.Token(r.slice(a,o),h))}a=o+1}}returns},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){ninthis.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){varn=e.label&&e.labelinthis.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index.