diff --git a/kiwi-nlp/.nojekyll b/kiwi-nlp/.nojekyll new file mode 100644 index 00000000..e2ac6616 --- /dev/null +++ b/kiwi-nlp/.nojekyll @@ -0,0 +1 @@ +TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false. \ No newline at end of file diff --git a/kiwi-nlp/assets/highlight.css b/kiwi-nlp/assets/highlight.css new file mode 100644 index 00000000..2c1852aa --- /dev/null +++ b/kiwi-nlp/assets/highlight.css @@ -0,0 +1,78 @@ +:root { + --light-hl-0: #AF00DB; + --dark-hl-0: #C586C0; + --light-hl-1: #000000; + --dark-hl-1: #D4D4D4; + --light-hl-2: #001080; + --dark-hl-2: #9CDCFE; + --light-hl-3: #A31515; + --dark-hl-3: #CE9178; + --light-hl-4: #0000FF; + --dark-hl-4: #569CD6; + --light-hl-5: #795E26; + --dark-hl-5: #DCDCAA; + --light-hl-6: #0070C1; + --dark-hl-6: #4FC1FF; + --light-hl-7: #008000; + --dark-hl-7: #6A9955; + --light-code-background: #FFFFFF; + --dark-code-background: #1E1E1E; +} + +@media (prefers-color-scheme: light) { :root { + --hl-0: var(--light-hl-0); + --hl-1: var(--light-hl-1); + --hl-2: var(--light-hl-2); + --hl-3: var(--light-hl-3); + --hl-4: var(--light-hl-4); + --hl-5: var(--light-hl-5); + --hl-6: var(--light-hl-6); + --hl-7: var(--light-hl-7); + --code-background: var(--light-code-background); +} } + +@media (prefers-color-scheme: dark) { :root { + --hl-0: var(--dark-hl-0); + --hl-1: var(--dark-hl-1); + --hl-2: var(--dark-hl-2); + --hl-3: var(--dark-hl-3); + --hl-4: var(--dark-hl-4); + --hl-5: var(--dark-hl-5); + --hl-6: var(--dark-hl-6); + --hl-7: var(--dark-hl-7); + --code-background: var(--dark-code-background); +} } + +:root[data-theme='light'] { + --hl-0: var(--light-hl-0); + --hl-1: var(--light-hl-1); + --hl-2: var(--light-hl-2); + --hl-3: var(--light-hl-3); + --hl-4: var(--light-hl-4); + --hl-5: var(--light-hl-5); + --hl-6: var(--light-hl-6); + --hl-7: var(--light-hl-7); + --code-background: var(--light-code-background); +} + +:root[data-theme='dark'] { + --hl-0: var(--dark-hl-0); + --hl-1: var(--dark-hl-1); + --hl-2: var(--dark-hl-2); + --hl-3: var(--dark-hl-3); + --hl-4: var(--dark-hl-4); + --hl-5: var(--dark-hl-5); + --hl-6: var(--dark-hl-6); + --hl-7: var(--dark-hl-7); + --code-background: var(--dark-code-background); +} + +.hl-0 { color: var(--hl-0); } +.hl-1 { color: var(--hl-1); } +.hl-2 { color: var(--hl-2); } +.hl-3 { color: var(--hl-3); } +.hl-4 { color: var(--hl-4); } +.hl-5 { color: var(--hl-5); } +.hl-6 { color: var(--hl-6); } +.hl-7 { color: var(--hl-7); } +pre, code { background: var(--code-background); } diff --git a/kiwi-nlp/assets/icons.js b/kiwi-nlp/assets/icons.js new file mode 100644 index 00000000..e88e8ca7 --- /dev/null +++ b/kiwi-nlp/assets/icons.js @@ -0,0 +1,18 @@ +(function() { + addIcons(); + function addIcons() { + if (document.readyState === "loading") return document.addEventListener("DOMContentLoaded", addIcons); + const svg = document.body.appendChild(document.createElementNS("http://www.w3.org/2000/svg", "svg")); + svg.innerHTML = `""`; + svg.style.display = "none"; + if (location.protocol === "file:") updateUseElements(); + } + + function updateUseElements() { + document.querySelectorAll("use").forEach(el => { + if (el.getAttribute("href").includes("#icon-")) { + el.setAttribute("href", el.getAttribute("href").replace(/.*#/, "#")); + } + }); + } +})() \ No newline at end of file diff --git a/kiwi-nlp/assets/icons.svg b/kiwi-nlp/assets/icons.svg new file mode 100644 index 00000000..e371b8b5 --- /dev/null +++ b/kiwi-nlp/assets/icons.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/kiwi-nlp/assets/main.js b/kiwi-nlp/assets/main.js new file mode 100644 index 00000000..7d7f77a0 --- /dev/null +++ b/kiwi-nlp/assets/main.js @@ -0,0 +1,60 @@ +"use strict"; +window.translations={"copy":"Copy","copied":"Copied!","normally_hidden":"This member is normally hidden due to your filter settings."}; +"use strict";(()=>{var Ce=Object.create;var ie=Object.defineProperty;var Oe=Object.getOwnPropertyDescriptor;var _e=Object.getOwnPropertyNames;var Re=Object.getPrototypeOf,Me=Object.prototype.hasOwnProperty;var Fe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var De=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of _e(e))!Me.call(t,i)&&i!==n&&ie(t,i,{get:()=>e[i],enumerable:!(r=Oe(e,i))||r.enumerable});return t};var Ae=(t,e,n)=>(n=t!=null?Ce(Re(t)):{},De(e||!t||!t.__esModule?ie(n,"default",{value:t,enumerable:!0}):n,t));var ue=Fe((ae,le)=>{(function(){var t=function(e){var n=new t.Builder;return n.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){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. +`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},t.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},t.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),m=s.str.charAt(1),p;m in s.node.edges?p=s.node.edges[m]:(p=new t.TokenSet,s.node.edges[m]=p),s.str.length==1&&(p.final=!0),i.push({node:p,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=this.length)return t.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},t.QueryLexer.prototype.width=function(){return this.pos-this.start},t.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},t.QueryLexer.prototype.backup=function(){this.pos-=1},t.QueryLexer.prototype.acceptDigitRun=function(){var e,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(t.QueryLexer.TERM)),e.ignore(),e.more())return t.QueryLexer.lexText},t.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.EDIT_DISTANCE),t.QueryLexer.lexText},t.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.BOOST),t.QueryLexer.lexText},t.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(t.QueryLexer.TERM)},t.QueryLexer.termSeparator=t.tokenizer.separator,t.QueryLexer.lexText=function(e){for(;;){var n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,this.currentClause={},this.lexemeIdx=0},t.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=t.QueryParser.parseClause;e;)e=e(this);return this.query},t.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},t.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},t.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},t.QueryParser.parseClause=function(e){var n=e.peekLexeme();if(n!=null)switch(n.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof ae=="object"?le.exports=n():e.lunr=n()}(this,function(){return t})})()});var se=[];function G(t,e){se.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible()),document.body.style.display||(this.ensureFocusedElementVisible(),this.updateIndexVisibility(),this.scrollToHash())}createComponents(e){se.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}showPage(){document.body.style.display&&(document.body.style.removeProperty("display"),this.ensureFocusedElementVisible(),this.updateIndexVisibility(),this.scrollToHash())}scrollToHash(){if(location.hash){let e=document.getElementById(location.hash.substring(1));if(!e)return;e.scrollIntoView({behavior:"instant",block:"start"})}}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e&&!e.checkVisibility()){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r}}updateIndexVisibility(){let e=document.querySelector(".tsd-index-content"),n=e?.open;e&&(e.open=!0),document.querySelectorAll(".tsd-index-section").forEach(r=>{r.style.display="block";let i=Array.from(r.querySelectorAll(".tsd-index-link")).every(s=>s.offsetParent==null);r.style.display=i?"none":"block"}),e&&(e.open=n)}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(!n)return;let r=n.offsetParent==null,i=n;for(;i!==document.body;)i instanceof HTMLDetailsElement&&(i.open=!0),i=i.parentElement;if(n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let s=document.createElement("p");s.classList.add("warning"),s.textContent=window.translations.normally_hidden,n.prepend(s)}r&&e.scrollIntoView()}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent=window.translations.copied,e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent=window.translations.copy},100)},1e3)})})}};var oe=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var pe=Ae(ue());async function ce(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=pe.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function fe(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{ce(e,t)}),ce(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");i.addEventListener("mouseup",()=>{te(t)}),r.addEventListener("focus",()=>t.classList.add("has-focus")),Ve(t,i,r,e)}function Ve(t,e,n,r){n.addEventListener("input",oe(()=>{Ne(t,e,n,r)},200)),n.addEventListener("keydown",i=>{i.key=="Enter"?He(e,t):i.key=="ArrowUp"?(de(e,n,-1),i.preventDefault()):i.key==="ArrowDown"&&(de(e,n,1),i.preventDefault())}),document.body.addEventListener("keypress",i=>{i.altKey||i.ctrlKey||i.metaKey||!n.matches(":focus")&&i.key==="/"&&(i.preventDefault(),n.focus())}),document.body.addEventListener("keyup",i=>{t.classList.contains("has-focus")&&(i.key==="Escape"||!e.matches(":focus-within")&&!n.matches(":focus"))&&(n.blur(),te(t))})}function te(t){t.classList.remove("has-focus")}function Ne(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=he(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` + ${he(l.parent,i)}.${d}`);let m=document.createElement("li");m.classList.value=l.classes??"";let p=document.createElement("a");p.href=r.base+l.url,p.innerHTML=u+d,m.append(p),p.addEventListener("focus",()=>{e.querySelector(".current")?.classList.remove("current"),m.classList.add("current")}),e.appendChild(m)}}function de(t,e,n){let r=t.querySelector(".current");if(!r)r=t.querySelector(n==1?"li:first-child":"li:last-child"),r&&r.classList.add("current");else{let i=r;if(n===1)do i=i.nextElementSibling??void 0;while(i instanceof HTMLElement&&i.offsetParent==null);else do i=i.previousElementSibling??void 0;while(i instanceof HTMLElement&&i.offsetParent==null);i?(r.classList.remove("current"),i.classList.add("current")):n===-1&&(r.classList.remove("current"),e.focus())}}function He(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),te(e)}}function he(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(ee(t.substring(s,o)),`${ee(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(ee(t.substring(s))),i.join("")}var Be={"&":"&","<":"<",">":">","'":"'",'"':"""};function ee(t){return t.replace(/[&<>"'"]/g,e=>Be[e])}var I=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",ye="mousemove",H="mouseup",J={x:0,y:0},me=!1,ne=!1,je=!1,D=!1,ve=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(ve?"is-mobile":"not-mobile");ve&&"ontouchstart"in document.documentElement&&(je=!0,F="touchstart",ye="touchmove",H="touchend");document.addEventListener(F,t=>{ne=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(ye,t=>{if(ne&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(H,()=>{ne=!1});document.addEventListener("click",t=>{me&&(t.preventDefault(),t.stopImmediatePropagation(),me=!1)});var X=class extends I{constructor(e){super(e),this.className=this.el.dataset.toggle||"",this.el.addEventListener(H,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(F,n=>this.onDocumentPointerDown(n)),document.addEventListener(H,n=>this.onDocumentPointerUp(n))}setActive(e){if(this.active==e)return;this.active=e,document.documentElement.classList.toggle("has-"+this.className,e),this.el.classList.toggle("active",e);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(e){D||(this.setActive(!0),e.preventDefault())}onDocumentPointerDown(e){if(this.active){if(e.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(e){if(!D&&this.active&&e.target.closest(".col-sidebar")){let n=e.target.closest("a");if(n){let r=window.location.href;r.indexOf("#")!=-1&&(r=r.substring(0,r.indexOf("#"))),n.href.substring(0,r.length)==r&&setTimeout(()=>this.setActive(!1),250)}}}};var re;try{re=localStorage}catch{re={getItem(){return null},setItem(){}}}var Q=re;var ge=document.head.appendChild(document.createElement("style"));ge.dataset.for="filters";var Y=class extends I{constructor(e){super(e),this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ge.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } +`,this.app.updateIndexVisibility()}fromLocalStorage(){let e=Q.getItem(this.key);return e?e==="true":this.el.checked}setLocalStorage(e){Q.setItem(this.key,e.toString()),this.value=e,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),this.app.updateIndexVisibility()}};var Z=class extends I{constructor(e){super(e),this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let n=Q.getItem(this.key);this.el.open=n?n==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let r=this.summary.querySelector("a");r&&r.addEventListener("click",()=>{location.assign(r.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function Ee(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,xe(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),xe(t.value)})}function xe(t){document.documentElement.dataset.theme=t}var K;function we(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",Le),Le())}async function Le(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();K=t.dataset.base,K.endsWith("/")||(K+="/"),t.innerHTML="";for(let s of i)Se(s,t,[]);window.app.createComponents(t),window.app.showPage(),window.app.ensureActivePageVisible()}function Se(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-accordion`:"tsd-accordion";let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.dataset.key=i.join("$"),o.innerHTML='',be(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)Se(u,l,i)}else be(t,r,t.class)}function be(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=K+t.path,n&&(r.className=n),location.pathname===r.pathname&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else e.appendChild(document.createElement("span")).textContent=t.text}G(X,"a[data-toggle]");G(Z,".tsd-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Te=document.getElementById("tsd-theme");Te&&Ee(Te);var qe=new U;Object.defineProperty(window,"app",{value:qe});fe();we();})(); +/*! Bundled license information: + +lunr/lunr.js: + (** + * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9 + * Copyright (C) 2020 Oliver Nightingale + * @license MIT + *) + (*! + * lunr.utils + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Set + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.tokenizer + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Pipeline + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Vector + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.stemmer + * Copyright (C) 2020 Oliver Nightingale + * Includes code from - http://tartarus.org/~martin/PorterStemmer/js.txt + *) + (*! + * lunr.stopWordFilter + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.trimmer + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.TokenSet + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Index + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Builder + * Copyright (C) 2020 Oliver Nightingale + *) +*/ diff --git a/kiwi-nlp/assets/navigation.js b/kiwi-nlp/assets/navigation.js new file mode 100644 index 00000000..023185ae --- /dev/null +++ b/kiwi-nlp/assets/navigation.js @@ -0,0 +1 @@ +window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAA42UzU6EMBRG36VrIg7J+MNuzMREzSRGxrgwLhq4SDOlbdpLlDG+uwEVCgMt237nO1xKuK9fBOETSUx2FNOCBERRLEhMQFSlCdvDswJLTgJyYCIj8dV30HUSRVMYd9rD+c4D+2A3FeMZ6L6ZcmoMmNAKh4ZVZDtaZKPfTW9gAkHnNAUTdulQEa0vRmNMtpvAVdxJrYrJZpu4qo8aqKC8PkK2lwcQk5YxtFD4InXm8zWMR4fNI9kRskTR2fkG0FKh842HlEuZgEAQKdxLJuY/xQm1VPkEpuLodf5iS6Sz92gDy0Sc4YLxLM6lbS/6TuRyUtalXoVjIit3amolt5AzwZDJ6bsaIj7ZXlNhcqlLe8OMbBbj0j0b0LN/1n/oWzMbU4u0N2Ct/tZMG4za59eXq3U02DcZ8FvGwYwVfeJ3aFVACQngqaSLpi1vPycghgIjBgAA" \ No newline at end of file diff --git a/kiwi-nlp/assets/search.js b/kiwi-nlp/assets/search.js new file mode 100644 index 00000000..625781a7 --- /dev/null +++ b/kiwi-nlp/assets/search.js @@ -0,0 +1 @@ +window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAA7WdXY/bttKA/4v21t2IIqmP3PW0OEDPQfoWb9L2wggKZa3dVWNLhiQnTYP89wNSX0NyKI289VU29nBmSD4cUjOy9DVo6s9t8Hr/NfhYVofgdRRmCZPRLqjyUxG8Dt7Uh+L47/JYtMEuuDTH4HXQfTkX7av5i/vn7nQMdsHDMW/bog1eB8G33agvlpLHk7Y//lCNlzXdTUJA4S44501RdaZHs5lIzkZ+bYvm97o5TGbKqiuax/yhaF+N3y36zMJITNo+UzTdDVK4x5NDHhNd/rRuoRe6zkD7UDfFuolR7DojdVM+kYb9DkiSTcEJ/qUp8io/fvm7OLyrPxYVZtGWoU/4Y92cyBrvBmm8H46j2wDALS6BQDXYdnnT0U2O4i8zWlQoG7jJXnizQQ8mPi4tkX8Ukpl3KiNLq2uUIRsFDV5k2Bs7UKvLIcRvEs7buy/n+sfisazKrqzRxW1K0GdNBR6ivrtBFu+I5aIP+KapG6q9UfglBh/qFl3VmL1B9mXmqsOWObqDDTYatgF51+RVqxZW4R1hIEJH5FA8tlSFd4OwvyvQS/8gdmV1yY9K/oeFCXSsYy23ugKH9V+X8nj4vnlC+z99SR/Kk3t09Cq8M4TxXsz+eQwq7U9N3hXfH4/1qW7OzwTDaKMrHTjW+eHH4jG/HLsfywd0Ji3rbosXmNaLh24XiL/A6JvLsSs3WIXyV5q9tEWjNFC4grIvMKe2K6q5UfZKc2dzk6RYRZpcaVwvw3fwGm1lyb5bulRbNdd9OdeUDo5yLzCjAuS756Zon+sjeopCTNptNpiP0sn6f8vPpZYBW9Wg6RX4bjGwRqGYFT40Rd4Vq7ruJjncb+iXx9IH9fW6oVHsajufiqaF5wivpVlwky14eFBXDD9VjzW6z45f0ne5t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6ObFg0cFjQEhbL1CfM3Qp6G5GC7rjI5vB+IPAlNH4Gp5uChyBVwghzZPhlU1g2QI6gyFp2P8rhsBAzGy0w3On1anHjaGAt4x2yoD6muF530AhgCSjRa5RoQ1IAqJyQlsMs6pj2SHOAUJSem+xZS+Ac8Tr3vHlSWCOYSyjrYB2OQ8BQyzxUqul5CFgPlVSu7uQh1DVXHDVS1wjS4kI2HPiAbVdTkQY2WhavGuXExHw0lVS+fMnIqA6vlmdm4iAk8yJk+ycE8CBPB1ybhltdx1epQJ0gRlIqTqOZfcwvnIJHBoAHskGVWXV1W3/7FUwUMa+Shz4/iHlQAncI/pGyZibnFKpxEnozOs9ENPHwlVGO7K1lw/egAdoI2YirQwVmAIxeDVsaENVLB3+n411s5BoRx8J9Nt7wSgAf4lpRPPZ6mA/h0nOkBZb5ucvAz1wztk2PXaFKzNS8LT4qXW5u6IA614OM5NuGHljbQjQR0mDDqtNCTDkgnYtPqpBN0YOliynu3UoHsvKLcRBHojT+OVcq33QumIES4K4HwwvPQc9AyAQg7ZOrTZ51SqPzOwMAyxEtDipX70JzjQgaBOr3Je2aFQGxbzaAOuXuLkpPfY1EEw9b1JiOgNCKqcNy/RScjBV4EzPaUNjdweWSskK0MtWsE4FTdXfdmYhBv1JCKP7fhecy3Oh8oLB6/37b9/+B9hrh39pjgAA"; \ No newline at end of file diff --git a/kiwi-nlp/assets/style.css b/kiwi-nlp/assets/style.css new file mode 100644 index 00000000..d0c980d4 --- /dev/null +++ b/kiwi-nlp/assets/style.css @@ -0,0 +1,1438 @@ +:root { + /* Light */ + --light-color-background: #f2f4f8; + --light-color-background-secondary: #eff0f1; + --light-color-warning-text: #222; + --light-color-background-warning: #e6e600; + --light-color-icon-background: var(--light-color-background); + --light-color-accent: #c5c7c9; + --light-color-active-menu-item: var(--light-color-accent); + --light-color-text: #222; + --light-color-text-aside: #6e6e6e; + --light-color-link: #1f70c2; + --light-color-focus-outline: #3584e4; + + --light-color-ts-keyword: #056bd6; + --light-color-ts-project: #b111c9; + --light-color-ts-module: var(--light-color-ts-project); + --light-color-ts-namespace: var(--light-color-ts-project); + --light-color-ts-enum: #7e6f15; + --light-color-ts-enum-member: var(--light-color-ts-enum); + --light-color-ts-variable: #4760ec; + --light-color-ts-function: #572be7; + --light-color-ts-class: #1f70c2; + --light-color-ts-interface: #108024; + --light-color-ts-constructor: var(--light-color-ts-class); + --light-color-ts-property: var(--light-color-ts-variable); + --light-color-ts-method: var(--light-color-ts-function); + --light-color-ts-call-signature: var(--light-color-ts-method); + --light-color-ts-index-signature: var(--light-color-ts-property); + --light-color-ts-constructor-signature: var(--light-color-ts-constructor); + --light-color-ts-parameter: var(--light-color-ts-variable); + /* type literal not included as links will never be generated to it */ + --light-color-ts-type-parameter: #a55c0e; + --light-color-ts-accessor: var(--light-color-ts-property); + --light-color-ts-get-signature: var(--light-color-ts-accessor); + --light-color-ts-set-signature: var(--light-color-ts-accessor); + --light-color-ts-type-alias: #d51270; + /* reference not included as links will be colored with the kind that it points to */ + --light-color-document: #000000; + + --light-external-icon: url("data:image/svg+xml;utf8,"); + --light-color-scheme: light; + + /* Dark */ + --dark-color-background: #2b2e33; + --dark-color-background-secondary: #1e2024; + --dark-color-background-warning: #bebe00; + --dark-color-warning-text: #222; + --dark-color-icon-background: var(--dark-color-background-secondary); + --dark-color-accent: #9096a2; + --dark-color-active-menu-item: #5d5d6a; + --dark-color-text: #f5f5f5; + --dark-color-text-aside: #dddddd; + --dark-color-link: #00aff4; + --dark-color-focus-outline: #4c97f2; + + --dark-color-ts-keyword: #3399ff; + --dark-color-ts-project: #e358ff; + --dark-color-ts-module: var(--dark-color-ts-project); + --dark-color-ts-namespace: var(--dark-color-ts-project); + --dark-color-ts-enum: #f4d93e; + --dark-color-ts-enum-member: var(--dark-color-ts-enum); + --dark-color-ts-variable: #798dff; + --dark-color-ts-function: #a280ff; + --dark-color-ts-class: #8ac4ff; + --dark-color-ts-interface: #6cff87; + --dark-color-ts-constructor: var(--dark-color-ts-class); + --dark-color-ts-property: var(--dark-color-ts-variable); + --dark-color-ts-method: var(--dark-color-ts-function); + --dark-color-ts-call-signature: var(--dark-color-ts-method); + --dark-color-ts-index-signature: var(--dark-color-ts-property); + --dark-color-ts-constructor-signature: var(--dark-color-ts-constructor); + --dark-color-ts-parameter: var(--dark-color-ts-variable); + /* type literal not included as links will never be generated to it */ + --dark-color-ts-type-parameter: #e07d13; + --dark-color-ts-accessor: var(--dark-color-ts-property); + --dark-color-ts-get-signature: var(--dark-color-ts-accessor); + --dark-color-ts-set-signature: var(--dark-color-ts-accessor); + --dark-color-ts-type-alias: #ff6492; + /* reference not included as links will be colored with the kind that it points to */ + --dark-color-document: #ffffff; + + --dark-external-icon: url("data:image/svg+xml;utf8,"); + --dark-color-scheme: dark; +} + +@media (prefers-color-scheme: light) { + :root { + --color-background: var(--light-color-background); + --color-background-secondary: var(--light-color-background-secondary); + --color-background-warning: var(--light-color-background-warning); + --color-warning-text: var(--light-color-warning-text); + --color-icon-background: var(--light-color-icon-background); + --color-accent: var(--light-color-accent); + --color-active-menu-item: var(--light-color-active-menu-item); + --color-text: var(--light-color-text); + --color-text-aside: var(--light-color-text-aside); + --color-link: var(--light-color-link); + --color-focus-outline: var(--light-color-focus-outline); + + --color-ts-keyword: var(--light-color-ts-keyword); + --color-ts-module: var(--light-color-ts-module); + --color-ts-namespace: var(--light-color-ts-namespace); + --color-ts-enum: var(--light-color-ts-enum); + --color-ts-enum-member: var(--light-color-ts-enum-member); + --color-ts-variable: var(--light-color-ts-variable); + --color-ts-function: var(--light-color-ts-function); + --color-ts-class: var(--light-color-ts-class); + --color-ts-interface: var(--light-color-ts-interface); + --color-ts-constructor: var(--light-color-ts-constructor); + --color-ts-property: var(--light-color-ts-property); + --color-ts-method: var(--light-color-ts-method); + --color-ts-call-signature: var(--light-color-ts-call-signature); + --color-ts-index-signature: var(--light-color-ts-index-signature); + --color-ts-constructor-signature: var( + --light-color-ts-constructor-signature + ); + --color-ts-parameter: var(--light-color-ts-parameter); + --color-ts-type-parameter: var(--light-color-ts-type-parameter); + --color-ts-accessor: var(--light-color-ts-accessor); + --color-ts-get-signature: var(--light-color-ts-get-signature); + --color-ts-set-signature: var(--light-color-ts-set-signature); + --color-ts-type-alias: var(--light-color-ts-type-alias); + --color-document: var(--light-color-document); + + --external-icon: var(--light-external-icon); + --color-scheme: var(--light-color-scheme); + } +} + +@media (prefers-color-scheme: dark) { + :root { + --color-background: var(--dark-color-background); + --color-background-secondary: var(--dark-color-background-secondary); + --color-background-warning: var(--dark-color-background-warning); + --color-warning-text: var(--dark-color-warning-text); + --color-icon-background: var(--dark-color-icon-background); + --color-accent: var(--dark-color-accent); + --color-active-menu-item: var(--dark-color-active-menu-item); + --color-text: var(--dark-color-text); + --color-text-aside: var(--dark-color-text-aside); + --color-link: var(--dark-color-link); + --color-focus-outline: var(--dark-color-focus-outline); + + --color-ts-keyword: var(--dark-color-ts-keyword); + --color-ts-module: var(--dark-color-ts-module); + --color-ts-namespace: var(--dark-color-ts-namespace); + --color-ts-enum: var(--dark-color-ts-enum); + --color-ts-enum-member: var(--dark-color-ts-enum-member); + --color-ts-variable: var(--dark-color-ts-variable); + --color-ts-function: var(--dark-color-ts-function); + --color-ts-class: var(--dark-color-ts-class); + --color-ts-interface: var(--dark-color-ts-interface); + --color-ts-constructor: var(--dark-color-ts-constructor); + --color-ts-property: var(--dark-color-ts-property); + --color-ts-method: var(--dark-color-ts-method); + --color-ts-call-signature: var(--dark-color-ts-call-signature); + --color-ts-index-signature: var(--dark-color-ts-index-signature); + --color-ts-constructor-signature: var( + --dark-color-ts-constructor-signature + ); + --color-ts-parameter: var(--dark-color-ts-parameter); + --color-ts-type-parameter: var(--dark-color-ts-type-parameter); + --color-ts-accessor: var(--dark-color-ts-accessor); + --color-ts-get-signature: var(--dark-color-ts-get-signature); + --color-ts-set-signature: var(--dark-color-ts-set-signature); + --color-ts-type-alias: var(--dark-color-ts-type-alias); + --color-document: var(--dark-color-document); + + --external-icon: var(--dark-external-icon); + --color-scheme: var(--dark-color-scheme); + } +} + +html { + color-scheme: var(--color-scheme); +} + +body { + margin: 0; +} + +:root[data-theme="light"] { + --color-background: var(--light-color-background); + --color-background-secondary: var(--light-color-background-secondary); + --color-background-warning: var(--light-color-background-warning); + --color-warning-text: var(--light-color-warning-text); + --color-icon-background: var(--light-color-icon-background); + --color-accent: var(--light-color-accent); + --color-active-menu-item: var(--light-color-active-menu-item); + --color-text: var(--light-color-text); + --color-text-aside: var(--light-color-text-aside); + --color-link: var(--light-color-link); + --color-focus-outline: var(--light-color-focus-outline); + + --color-ts-keyword: var(--light-color-ts-keyword); + --color-ts-module: var(--light-color-ts-module); + --color-ts-namespace: var(--light-color-ts-namespace); + --color-ts-enum: var(--light-color-ts-enum); + --color-ts-enum-member: var(--light-color-ts-enum-member); + --color-ts-variable: var(--light-color-ts-variable); + --color-ts-function: var(--light-color-ts-function); + --color-ts-class: var(--light-color-ts-class); + --color-ts-interface: var(--light-color-ts-interface); + --color-ts-constructor: var(--light-color-ts-constructor); + --color-ts-property: var(--light-color-ts-property); + --color-ts-method: var(--light-color-ts-method); + --color-ts-call-signature: var(--light-color-ts-call-signature); + --color-ts-index-signature: var(--light-color-ts-index-signature); + --color-ts-constructor-signature: var( + --light-color-ts-constructor-signature + ); + --color-ts-parameter: var(--light-color-ts-parameter); + --color-ts-type-parameter: var(--light-color-ts-type-parameter); + --color-ts-accessor: var(--light-color-ts-accessor); + --color-ts-get-signature: var(--light-color-ts-get-signature); + --color-ts-set-signature: var(--light-color-ts-set-signature); + --color-ts-type-alias: var(--light-color-ts-type-alias); + --color-document: var(--light-color-document); + + --external-icon: var(--light-external-icon); + --color-scheme: var(--light-color-scheme); +} + +:root[data-theme="dark"] { + --color-background: var(--dark-color-background); + --color-background-secondary: var(--dark-color-background-secondary); + --color-background-warning: var(--dark-color-background-warning); + --color-warning-text: var(--dark-color-warning-text); + --color-icon-background: var(--dark-color-icon-background); + --color-accent: var(--dark-color-accent); + --color-active-menu-item: var(--dark-color-active-menu-item); + --color-text: var(--dark-color-text); + --color-text-aside: var(--dark-color-text-aside); + --color-link: var(--dark-color-link); + --color-focus-outline: var(--dark-color-focus-outline); + + --color-ts-keyword: var(--dark-color-ts-keyword); + --color-ts-module: var(--dark-color-ts-module); + --color-ts-namespace: var(--dark-color-ts-namespace); + --color-ts-enum: var(--dark-color-ts-enum); + --color-ts-enum-member: var(--dark-color-ts-enum-member); + --color-ts-variable: var(--dark-color-ts-variable); + --color-ts-function: var(--dark-color-ts-function); + --color-ts-class: var(--dark-color-ts-class); + --color-ts-interface: var(--dark-color-ts-interface); + --color-ts-constructor: var(--dark-color-ts-constructor); + --color-ts-property: var(--dark-color-ts-property); + --color-ts-method: var(--dark-color-ts-method); + --color-ts-call-signature: var(--dark-color-ts-call-signature); + --color-ts-index-signature: var(--dark-color-ts-index-signature); + --color-ts-constructor-signature: var( + --dark-color-ts-constructor-signature + ); + --color-ts-parameter: var(--dark-color-ts-parameter); + --color-ts-type-parameter: var(--dark-color-ts-type-parameter); + --color-ts-accessor: var(--dark-color-ts-accessor); + --color-ts-get-signature: var(--dark-color-ts-get-signature); + --color-ts-set-signature: var(--dark-color-ts-set-signature); + --color-ts-type-alias: var(--dark-color-ts-type-alias); + --color-document: var(--dark-color-document); + + --external-icon: var(--dark-external-icon); + --color-scheme: var(--dark-color-scheme); +} + +*:focus-visible, +.tsd-accordion-summary:focus-visible svg { + outline: 2px solid var(--color-focus-outline); +} + +.always-visible, +.always-visible .tsd-signatures { + display: inherit !important; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + line-height: 1.2; +} + +h1 { + font-size: 1.875rem; + margin: 0.67rem 0; +} + +h2 { + font-size: 1.5rem; + margin: 0.83rem 0; +} + +h3 { + font-size: 1.25rem; + margin: 1rem 0; +} + +h4 { + font-size: 1.05rem; + margin: 1.33rem 0; +} + +h5 { + font-size: 1rem; + margin: 1.5rem 0; +} + +h6 { + font-size: 0.875rem; + margin: 2.33rem 0; +} + +dl, +menu, +ol, +ul { + margin: 1em 0; +} + +dd { + margin: 0 0 0 40px; +} + +.container { + max-width: 1700px; + padding: 0 2rem; +} + +/* Footer */ +footer { + border-top: 1px solid var(--color-accent); + padding-top: 1rem; + padding-bottom: 1rem; + max-height: 3.5rem; +} +footer > p { + margin: 0 1em; +} + +.container-main { + margin: 0 auto; + /* toolbar, footer, margin */ + min-height: calc(100vh - 41px - 56px - 4rem); +} + +@keyframes fade-in { + from { + opacity: 0; + } + to { + opacity: 1; + } +} +@keyframes fade-out { + from { + opacity: 1; + visibility: visible; + } + to { + opacity: 0; + } +} +@keyframes fade-in-delayed { + 0% { + opacity: 0; + } + 33% { + opacity: 0; + } + 100% { + opacity: 1; + } +} +@keyframes fade-out-delayed { + 0% { + opacity: 1; + visibility: visible; + } + 66% { + opacity: 0; + } + 100% { + opacity: 0; + } +} +@keyframes pop-in-from-right { + from { + transform: translate(100%, 0); + } + to { + transform: translate(0, 0); + } +} +@keyframes pop-out-to-right { + from { + transform: translate(0, 0); + visibility: visible; + } + to { + transform: translate(100%, 0); + } +} +body { + background: var(--color-background); + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", + Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji"; + font-size: 16px; + color: var(--color-text); +} + +a { + color: var(--color-link); + text-decoration: none; +} +a:hover { + text-decoration: underline; +} +a.external[target="_blank"] { + background-image: var(--external-icon); + background-position: top 3px right; + background-repeat: no-repeat; + padding-right: 13px; +} +a.tsd-anchor-link { + color: var(--color-text); +} + +code, +pre { + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + padding: 0.2em; + margin: 0; + font-size: 0.875rem; + border-radius: 0.8em; +} + +pre { + position: relative; + white-space: pre; + white-space: pre-wrap; + word-wrap: break-word; + padding: 10px; + border: 1px solid var(--color-accent); +} +pre code { + padding: 0; + font-size: 100%; +} +pre > button { + position: absolute; + top: 10px; + right: 10px; + opacity: 0; + transition: opacity 0.1s; + box-sizing: border-box; +} +pre:hover > button, +pre > button.visible { + opacity: 1; +} + +blockquote { + margin: 1em 0; + padding-left: 1em; + border-left: 4px solid gray; +} + +.tsd-typography { + line-height: 1.333em; +} +.tsd-typography ul { + list-style: square; + padding: 0 0 0 20px; + margin: 0; +} +.tsd-typography .tsd-index-panel h3, +.tsd-index-panel .tsd-typography h3, +.tsd-typography h4, +.tsd-typography h5, +.tsd-typography h6 { + font-size: 1em; +} +.tsd-typography h5, +.tsd-typography h6 { + font-weight: normal; +} +.tsd-typography p, +.tsd-typography ul, +.tsd-typography ol { + margin: 1em 0; +} +.tsd-typography table { + border-collapse: collapse; + border: none; +} +.tsd-typography td, +.tsd-typography th { + padding: 6px 13px; + border: 1px solid var(--color-accent); +} +.tsd-typography thead, +.tsd-typography tr:nth-child(even) { + background-color: var(--color-background-secondary); +} + +.tsd-breadcrumb { + margin: 0; + padding: 0; + color: var(--color-text-aside); +} +.tsd-breadcrumb a { + color: var(--color-text-aside); + text-decoration: none; +} +.tsd-breadcrumb a:hover { + text-decoration: underline; +} +.tsd-breadcrumb li { + display: inline; +} +.tsd-breadcrumb li:after { + content: " / "; +} + +.tsd-comment-tags { + display: flex; + flex-direction: column; +} +dl.tsd-comment-tag-group { + display: flex; + align-items: center; + overflow: hidden; + margin: 0.5em 0; +} +dl.tsd-comment-tag-group dt { + display: flex; + margin-right: 0.5em; + font-size: 0.875em; + font-weight: normal; +} +dl.tsd-comment-tag-group dd { + margin: 0; +} +code.tsd-tag { + padding: 0.25em 0.4em; + border: 0.1em solid var(--color-accent); + margin-right: 0.25em; + font-size: 70%; +} +h1 code.tsd-tag:first-of-type { + margin-left: 0.25em; +} + +dl.tsd-comment-tag-group dd:before, +dl.tsd-comment-tag-group dd:after { + content: " "; +} +dl.tsd-comment-tag-group dd pre, +dl.tsd-comment-tag-group dd:after { + clear: both; +} +dl.tsd-comment-tag-group p { + margin: 0; +} + +.tsd-panel.tsd-comment .lead { + font-size: 1.1em; + line-height: 1.333em; + margin-bottom: 2em; +} +.tsd-panel.tsd-comment .lead:last-child { + margin-bottom: 0; +} + +.tsd-filter-visibility h4 { + font-size: 1rem; + padding-top: 0.75rem; + padding-bottom: 0.5rem; + margin: 0; +} +.tsd-filter-item:not(:last-child) { + margin-bottom: 0.5rem; +} +.tsd-filter-input { + display: flex; + width: -moz-fit-content; + width: fit-content; + align-items: center; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; +} +.tsd-filter-input input[type="checkbox"] { + cursor: pointer; + position: absolute; + width: 1.5em; + height: 1.5em; + opacity: 0; +} +.tsd-filter-input input[type="checkbox"]:disabled { + pointer-events: none; +} +.tsd-filter-input svg { + cursor: pointer; + width: 1.5em; + height: 1.5em; + margin-right: 0.5em; + border-radius: 0.33em; + /* Leaving this at full opacity breaks event listeners on Firefox. + Don't remove unless you know what you're doing. */ + opacity: 0.99; +} +.tsd-filter-input input[type="checkbox"]:focus-visible + svg { + outline: 2px solid var(--color-focus-outline); +} +.tsd-checkbox-background { + fill: var(--color-accent); +} +input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { + stroke: var(--color-text); +} +.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-background { + fill: var(--color-background); + stroke: var(--color-accent); + stroke-width: 0.25rem; +} +.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-checkmark { + stroke: var(--color-accent); +} + +.settings-label { + font-weight: bold; + text-transform: uppercase; + display: inline-block; +} + +.tsd-filter-visibility .settings-label { + margin: 0.75rem 0 0.5rem 0; +} + +.tsd-theme-toggle .settings-label { + margin: 0.75rem 0.75rem 0 0; +} + +.tsd-hierarchy { + list-style: square; + margin: 0; +} +.tsd-hierarchy .target { + font-weight: bold; +} + +.tsd-full-hierarchy:not(:last-child) { + margin-bottom: 1em; + padding-bottom: 1em; + border-bottom: 1px solid var(--color-accent); +} +.tsd-full-hierarchy, +.tsd-full-hierarchy ul { + list-style: none; + margin: 0; + padding: 0; +} +.tsd-full-hierarchy ul { + padding-left: 1.5rem; +} +.tsd-full-hierarchy a { + padding: 0.25rem 0 !important; + font-size: 1rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} + +.tsd-panel-group.tsd-index-group { + margin-bottom: 0; +} +.tsd-index-panel .tsd-index-list { + list-style: none; + line-height: 1.333em; + margin: 0; + padding: 0.25rem 0 0 0; + overflow: hidden; + display: grid; + grid-template-columns: repeat(3, 1fr); + column-gap: 1rem; + grid-template-rows: auto; +} +@media (max-width: 1024px) { + .tsd-index-panel .tsd-index-list { + grid-template-columns: repeat(2, 1fr); + } +} +@media (max-width: 768px) { + .tsd-index-panel .tsd-index-list { + grid-template-columns: repeat(1, 1fr); + } +} +.tsd-index-panel .tsd-index-list li { + -webkit-page-break-inside: avoid; + -moz-page-break-inside: avoid; + -ms-page-break-inside: avoid; + -o-page-break-inside: avoid; + page-break-inside: avoid; +} + +.tsd-flag { + display: inline-block; + padding: 0.25em 0.4em; + border-radius: 4px; + color: var(--color-comment-tag-text); + background-color: var(--color-comment-tag); + text-indent: 0; + font-size: 75%; + line-height: 1; + font-weight: normal; +} + +.tsd-anchor { + position: relative; + top: -100px; +} + +.tsd-member { + position: relative; +} +.tsd-member .tsd-anchor + h3 { + display: flex; + align-items: center; + margin-top: 0; + margin-bottom: 0; + border-bottom: none; +} + +.tsd-navigation.settings { + margin: 1rem 0; +} +.tsd-navigation > a, +.tsd-navigation .tsd-accordion-summary { + width: calc(100% - 0.25rem); + display: flex; + align-items: center; +} +.tsd-navigation a, +.tsd-navigation summary > span, +.tsd-page-navigation a { + display: flex; + width: calc(100% - 0.25rem); + align-items: center; + padding: 0.25rem; + color: var(--color-text); + text-decoration: none; + box-sizing: border-box; +} +.tsd-navigation a.current, +.tsd-page-navigation a.current { + background: var(--color-active-menu-item); +} +.tsd-navigation a:hover, +.tsd-page-navigation a:hover { + text-decoration: underline; +} +.tsd-navigation ul, +.tsd-page-navigation ul { + margin-top: 0; + margin-bottom: 0; + padding: 0; + list-style: none; +} +.tsd-navigation li, +.tsd-page-navigation li { + padding: 0; + max-width: 100%; +} +.tsd-navigation .tsd-nav-link { + display: none; +} +.tsd-nested-navigation { + margin-left: 3rem; +} +.tsd-nested-navigation > li > details { + margin-left: -1.5rem; +} +.tsd-small-nested-navigation { + margin-left: 1.5rem; +} +.tsd-small-nested-navigation > li > details { + margin-left: -1.5rem; +} + +.tsd-page-navigation ul { + padding-left: 1.75rem; +} + +#tsd-sidebar-links a { + margin-top: 0; + margin-bottom: 0.5rem; + line-height: 1.25rem; +} +#tsd-sidebar-links a:last-of-type { + margin-bottom: 0; +} + +a.tsd-index-link { + padding: 0.25rem 0 !important; + font-size: 1rem; + line-height: 1.25rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} +.tsd-accordion-summary { + list-style-type: none; /* hide marker on non-safari */ + outline: none; /* broken on safari, so just hide it */ +} +.tsd-accordion-summary::-webkit-details-marker { + display: none; /* hide marker on safari */ +} +.tsd-accordion-summary, +.tsd-accordion-summary a { + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + user-select: none; + + cursor: pointer; +} +.tsd-accordion-summary a { + width: calc(100% - 1.5rem); +} +.tsd-accordion-summary > * { + margin-top: 0; + margin-bottom: 0; + padding-top: 0; + padding-bottom: 0; +} +.tsd-accordion .tsd-accordion-summary > svg { + margin-left: 0.25rem; +} +.tsd-index-content > :not(:first-child) { + margin-top: 0.75rem; +} +.tsd-index-heading { + margin-top: 1.5rem; + margin-bottom: 0.75rem; +} + +.tsd-kind-icon { + margin-right: 0.5rem; + width: 1.25rem; + height: 1.25rem; + min-width: 1.25rem; + min-height: 1.25rem; +} +.tsd-kind-icon path { + transform-origin: center; + transform: scale(1.1); +} +.tsd-signature > .tsd-kind-icon { + margin-right: 0.8rem; +} + +.tsd-panel { + margin-bottom: 2.5rem; +} +.tsd-panel.tsd-member { + margin-bottom: 4rem; +} +.tsd-panel:empty { + display: none; +} +.tsd-panel > h1, +.tsd-panel > h2, +.tsd-panel > h3 { + margin: 1.5rem -1.5rem 0.75rem -1.5rem; + padding: 0 1.5rem 0.75rem 1.5rem; +} +.tsd-panel > h1.tsd-before-signature, +.tsd-panel > h2.tsd-before-signature, +.tsd-panel > h3.tsd-before-signature { + margin-bottom: 0; + border-bottom: none; +} + +.tsd-panel-group { + margin: 2rem 0; +} +.tsd-panel-group.tsd-index-group { + margin: 2rem 0; +} +.tsd-panel-group.tsd-index-group details { + margin: 2rem 0; +} +.tsd-panel-group > .tsd-accordion-summary { + margin-bottom: 1rem; +} + +#tsd-search { + transition: background-color 0.2s; +} +#tsd-search .title { + position: relative; + z-index: 2; +} +#tsd-search .field { + position: absolute; + left: 0; + top: 0; + right: 2.5rem; + height: 100%; +} +#tsd-search .field input { + box-sizing: border-box; + position: relative; + top: -50px; + z-index: 1; + width: 100%; + padding: 0 10px; + opacity: 0; + outline: 0; + border: 0; + background: transparent; + color: var(--color-text); +} +#tsd-search .field label { + position: absolute; + overflow: hidden; + right: -40px; +} +#tsd-search .field input, +#tsd-search .title, +#tsd-toolbar-links a { + transition: opacity 0.2s; +} +#tsd-search .results { + position: absolute; + visibility: hidden; + top: 40px; + width: 100%; + margin: 0; + padding: 0; + list-style: none; + box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); +} +#tsd-search .results li { + background-color: var(--color-background); + line-height: initial; + padding: 4px; +} +#tsd-search .results li:nth-child(even) { + background-color: var(--color-background-secondary); +} +#tsd-search .results li.state { + display: none; +} +#tsd-search .results li.current:not(.no-results), +#tsd-search .results li:hover:not(.no-results) { + background-color: var(--color-accent); +} +#tsd-search .results a { + display: flex; + align-items: center; + padding: 0.25rem; + box-sizing: border-box; +} +#tsd-search .results a:before { + top: 10px; +} +#tsd-search .results span.parent { + color: var(--color-text-aside); + font-weight: normal; +} +#tsd-search.has-focus { + background-color: var(--color-accent); +} +#tsd-search.has-focus .field input { + top: 0; + opacity: 1; +} +#tsd-search.has-focus .title, +#tsd-search.has-focus #tsd-toolbar-links a { + z-index: 0; + opacity: 0; +} +#tsd-search.has-focus .results { + visibility: visible; +} +#tsd-search.loading .results li.state.loading { + display: block; +} +#tsd-search.failure .results li.state.failure { + display: block; +} + +#tsd-toolbar-links { + position: absolute; + top: 0; + right: 2rem; + height: 100%; + display: flex; + align-items: center; + justify-content: flex-end; +} +#tsd-toolbar-links a { + margin-left: 1.5rem; +} +#tsd-toolbar-links a:hover { + text-decoration: underline; +} + +.tsd-signature { + margin: 0 0 1rem 0; + padding: 1rem 0.5rem; + border: 1px solid var(--color-accent); + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + font-size: 14px; + overflow-x: auto; +} + +.tsd-signature-keyword { + color: var(--color-ts-keyword); + font-weight: normal; +} + +.tsd-signature-symbol { + color: var(--color-text-aside); + font-weight: normal; +} + +.tsd-signature-type { + font-style: italic; + font-weight: normal; +} + +.tsd-signatures { + padding: 0; + margin: 0 0 1em 0; + list-style-type: none; +} +.tsd-signatures .tsd-signature { + margin: 0; + border-color: var(--color-accent); + border-width: 1px 0; + transition: background-color 0.1s; +} +.tsd-signatures .tsd-index-signature:not(:last-child) { + margin-bottom: 1em; +} +.tsd-signatures .tsd-index-signature .tsd-signature { + border-width: 1px; +} +.tsd-description .tsd-signatures .tsd-signature { + border-width: 1px; +} + +ul.tsd-parameter-list, +ul.tsd-type-parameter-list { + list-style: square; + margin: 0; + padding-left: 20px; +} +ul.tsd-parameter-list > li.tsd-parameter-signature, +ul.tsd-type-parameter-list > li.tsd-parameter-signature { + list-style: none; + margin-left: -20px; +} +ul.tsd-parameter-list h5, +ul.tsd-type-parameter-list h5 { + font-size: 16px; + margin: 1em 0 0.5em 0; +} +.tsd-sources { + margin-top: 1rem; + font-size: 0.875em; +} +.tsd-sources a { + color: var(--color-text-aside); + text-decoration: underline; +} +.tsd-sources ul { + list-style: none; + padding: 0; +} + +.tsd-page-toolbar { + position: sticky; + z-index: 1; + top: 0; + left: 0; + width: 100%; + color: var(--color-text); + background: var(--color-background-secondary); + border-bottom: 1px var(--color-accent) solid; + transition: transform 0.3s ease-in-out; +} +.tsd-page-toolbar a { + color: var(--color-text); + text-decoration: none; +} +.tsd-page-toolbar a.title { + font-weight: bold; +} +.tsd-page-toolbar a.title:hover { + text-decoration: underline; +} +.tsd-page-toolbar .tsd-toolbar-contents { + display: flex; + justify-content: space-between; + height: 2.5rem; + margin: 0 auto; +} +.tsd-page-toolbar .table-cell { + position: relative; + white-space: nowrap; + line-height: 40px; +} +.tsd-page-toolbar .table-cell:first-child { + width: 100%; +} +.tsd-page-toolbar .tsd-toolbar-icon { + box-sizing: border-box; + line-height: 0; + padding: 12px 0; +} + +.tsd-widget { + display: inline-block; + overflow: hidden; + opacity: 0.8; + height: 40px; + transition: + opacity 0.1s, + background-color 0.2s; + vertical-align: bottom; + cursor: pointer; +} +.tsd-widget:hover { + opacity: 0.9; +} +.tsd-widget.active { + opacity: 1; + background-color: var(--color-accent); +} +.tsd-widget.no-caption { + width: 40px; +} +.tsd-widget.no-caption:before { + margin: 0; +} + +.tsd-widget.options, +.tsd-widget.menu { + display: none; +} +input[type="checkbox"] + .tsd-widget:before { + background-position: -120px 0; +} +input[type="checkbox"]:checked + .tsd-widget:before { + background-position: -160px 0; +} + +img { + max-width: 100%; +} + +.tsd-anchor-icon { + display: inline-flex; + align-items: center; + margin-left: 0.5rem; + vertical-align: middle; + color: var(--color-text); +} + +.tsd-anchor-icon svg { + width: 1em; + height: 1em; + visibility: hidden; +} + +.tsd-anchor-link:hover > .tsd-anchor-icon svg { + visibility: visible; +} + +.deprecated { + text-decoration: line-through !important; +} + +.warning { + padding: 1rem; + color: var(--color-warning-text); + background: var(--color-background-warning); +} + +.tsd-kind-project { + color: var(--color-ts-project); +} +.tsd-kind-module { + color: var(--color-ts-module); +} +.tsd-kind-namespace { + color: var(--color-ts-namespace); +} +.tsd-kind-enum { + color: var(--color-ts-enum); +} +.tsd-kind-enum-member { + color: var(--color-ts-enum-member); +} +.tsd-kind-variable { + color: var(--color-ts-variable); +} +.tsd-kind-function { + color: var(--color-ts-function); +} +.tsd-kind-class { + color: var(--color-ts-class); +} +.tsd-kind-interface { + color: var(--color-ts-interface); +} +.tsd-kind-constructor { + color: var(--color-ts-constructor); +} +.tsd-kind-property { + color: var(--color-ts-property); +} +.tsd-kind-method { + color: var(--color-ts-method); +} +.tsd-kind-call-signature { + color: var(--color-ts-call-signature); +} +.tsd-kind-index-signature { + color: var(--color-ts-index-signature); +} +.tsd-kind-constructor-signature { + color: var(--color-ts-constructor-signature); +} +.tsd-kind-parameter { + color: var(--color-ts-parameter); +} +.tsd-kind-type-literal { + color: var(--color-ts-type-literal); +} +.tsd-kind-type-parameter { + color: var(--color-ts-type-parameter); +} +.tsd-kind-accessor { + color: var(--color-ts-accessor); +} +.tsd-kind-get-signature { + color: var(--color-ts-get-signature); +} +.tsd-kind-set-signature { + color: var(--color-ts-set-signature); +} +.tsd-kind-type-alias { + color: var(--color-ts-type-alias); +} + +/* if we have a kind icon, don't color the text by kind */ +.tsd-kind-icon ~ span { + color: var(--color-text); +} + +* { + scrollbar-width: thin; + scrollbar-color: var(--color-accent) var(--color-icon-background); +} + +*::-webkit-scrollbar { + width: 0.75rem; +} + +*::-webkit-scrollbar-track { + background: var(--color-icon-background); +} + +*::-webkit-scrollbar-thumb { + background-color: var(--color-accent); + border-radius: 999rem; + border: 0.25rem solid var(--color-icon-background); +} + +/* mobile */ +@media (max-width: 769px) { + .tsd-widget.options, + .tsd-widget.menu { + display: inline-block; + } + + .container-main { + display: flex; + } + html .col-content { + float: none; + max-width: 100%; + width: 100%; + } + html .col-sidebar { + position: fixed !important; + overflow-y: auto; + -webkit-overflow-scrolling: touch; + z-index: 1024; + top: 0 !important; + bottom: 0 !important; + left: auto !important; + right: 0 !important; + padding: 1.5rem 1.5rem 0 0; + width: 75vw; + visibility: hidden; + background-color: var(--color-background); + transform: translate(100%, 0); + } + html .col-sidebar > *:last-child { + padding-bottom: 20px; + } + html .overlay { + content: ""; + display: block; + position: fixed; + z-index: 1023; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: rgba(0, 0, 0, 0.75); + visibility: hidden; + } + + .to-has-menu .overlay { + animation: fade-in 0.4s; + } + + .to-has-menu .col-sidebar { + animation: pop-in-from-right 0.4s; + } + + .from-has-menu .overlay { + animation: fade-out 0.4s; + } + + .from-has-menu .col-sidebar { + animation: pop-out-to-right 0.4s; + } + + .has-menu body { + overflow: hidden; + } + .has-menu .overlay { + visibility: visible; + } + .has-menu .col-sidebar { + visibility: visible; + transform: translate(0, 0); + display: flex; + flex-direction: column; + gap: 1.5rem; + max-height: 100vh; + padding: 1rem 2rem; + } + .has-menu .tsd-navigation { + max-height: 100%; + } + #tsd-toolbar-links { + display: none; + } + .tsd-navigation .tsd-nav-link { + display: flex; + } +} + +/* one sidebar */ +@media (min-width: 770px) { + .container-main { + display: grid; + grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); + grid-template-areas: "sidebar content"; + margin: 2rem auto; + } + + .col-sidebar { + grid-area: sidebar; + } + .col-content { + grid-area: content; + padding: 0 1rem; + } +} +@media (min-width: 770px) and (max-width: 1399px) { + .col-sidebar { + max-height: calc(100vh - 2rem - 42px); + overflow: auto; + position: sticky; + top: 42px; + padding-top: 1rem; + } + .site-menu { + margin-top: 1rem; + } +} + +/* two sidebars */ +@media (min-width: 1200px) { + .container-main { + grid-template-columns: minmax(0, 1fr) minmax(0, 2.5fr) minmax(0, 20rem); + grid-template-areas: "sidebar content toc"; + } + + .col-sidebar { + display: contents; + } + + .page-menu { + grid-area: toc; + padding-left: 1rem; + } + .site-menu { + grid-area: sidebar; + } + + .site-menu { + margin-top: 1rem 0; + } + + .page-menu, + .site-menu { + max-height: calc(100vh - 2rem - 42px); + overflow: auto; + position: sticky; + top: 42px; + } +} diff --git a/kiwi-nlp/classes/KiwiBuilder.html b/kiwi-nlp/classes/KiwiBuilder.html new file mode 100644 index 00000000..9882ac15 --- /dev/null +++ b/kiwi-nlp/classes/KiwiBuilder.html @@ -0,0 +1,16 @@ +KiwiBuilder | kiwi-nlp

Class KiwiBuilder

Used to create Kiwi instances. Main entry point for the API. +It is recommended to create a KiwiBuilder and the Kiwi instances in a worker to prevent blocking the main thread.

+

Methods

Methods

  • Creates a new Kiwi instance. +Note: Even though this method is async, the construction of the Kiwi instance happens in the same +JavaScript context. This means that this method can hang your application if not called in a worker.

    +

    Parameters

    • buildArgs: BuildArgs

      Arguments for building the Kiwi instance. See BuildArgs for more information.

      +

    Returns Promise<Kiwi>

    a Kiwi instance that is ready for morphological analysis.

    +
  • Get the version of the Kiwi wasm module.

    +

    Returns string

    The version of the Kiwi wasm module.

    +
  • Creates a new KiwiBuilder instance. This internally loads the wasm file.

    +

    Parameters

    • wasmPath: string

      Path to the kiwi-wasm.wasm file. This is located at /dist/kiwi-wasm.wasm in the npm package. +It is up to the user to serve this file. See the package-demo project for an example of how to include this file as a static asset with vite.

      +

    Returns Promise<KiwiBuilder>

\ No newline at end of file diff --git a/kiwi-nlp/enums/Match.html b/kiwi-nlp/enums/Match.html new file mode 100644 index 00000000..9d1ebc86 --- /dev/null +++ b/kiwi-nlp/enums/Match.html @@ -0,0 +1,22 @@ +Match | kiwi-nlp

Enumeration Match

Describes matching options when performing morphological analysis. +These options can be combined using the bitwise OR operator.

+

Enumeration Members

all: 8388671
allWithNormalizing: 8454207
email: 2
emoji: 32
hashtag: 4
joinAdjSuffix: 1048576
joinAdvSuffix: 2097152
joinAffix: 4063232
joinNounPrefix: 131072
joinNounSuffix: 262144
joinVSuffix: 1572864
joinVerbSuffix: 524288
mention: 8
none: 0
normalizeCoda: 65536
serial: 16
splitComplex: 4194304
url: 1
zCoda: 8388608
\ No newline at end of file diff --git a/kiwi-nlp/enums/Space.html b/kiwi-nlp/enums/Space.html new file mode 100644 index 00000000..8a360df6 --- /dev/null +++ b/kiwi-nlp/enums/Space.html @@ -0,0 +1,4 @@ +Space | kiwi-nlp

Enumeration Space

Enumeration Members

Enumeration Members

insertSpace: 2
noSpace: 1
none: 0
\ No newline at end of file diff --git a/kiwi-nlp/hierarchy.html b/kiwi-nlp/hierarchy.html new file mode 100644 index 00000000..b71c4081 --- /dev/null +++ b/kiwi-nlp/hierarchy.html @@ -0,0 +1 @@ +kiwi-nlp
\ No newline at end of file diff --git a/kiwi-nlp/index.html b/kiwi-nlp/index.html new file mode 100644 index 00000000..1a0863cd --- /dev/null +++ b/kiwi-nlp/index.html @@ -0,0 +1,12 @@ +kiwi-nlp

kiwi-nlp

kiwi-nlp, 한국어 형태소 분석기 Kiwi의 TypeScript/JavaScript 바인딩

Additionally to the requirements of the main project, you need to install Emscripten and npm.

+

To build the package, simply run ./build.sh.

+

This is currently only supported on Linux and macOS. You can run the build script on Windows by using WSL.

+

You can pass the --demo flag to build the demo in package-demo as well. +If you pass --demo-dev, a development server for the demo will be started.

+

Running the above command also automatically upgrades to package version if it doesn't match the version in the main project.

+

The documentation for the package can be generated by running npm run doc inside the package directory.

+

The main entry point for the API is KiwiBuilder, which is used to create instances Kiwi.

+
import { KiwiBuilder, Match } from 'kiwi-nlp';

async function example() {
const builder = await KiwiBuilder.create('path to kiwi-wasm.wasm');

const kiwi = await builder.build({
modelFiles: {
'combiningRule.txt': '/path/to/model/combiningRule.txt',
'default.dict': '/path/to/model/default.dict',
'extract.mdl': '/path/to/model/extract.mdl',
'multi.dict': '/path/to/model/multi.dict',
'sj.knlm': '/path/to/model/sj.knlm',
'sj.morph': '/path/to/model/sj.morph',
'skipbigram.mdl': '/path/to/model/skipbigram.mdl',
'typo.dict': '/path/to/model/typo.dict',
}
});

const tokens = kiwi.analyze('다음은 예시 텍스트입니다.', Match.allWithNormalizing);
/* Output: {
"score": -39.772212982177734,
"tokens": [
{
"length": 2,
"lineNumber": 0,
"pairedToken": 4294967295,
"position": 0,
"score": -6.5904083251953125,
"sentPosition": 0,
"str": "다음",
"subSentPosition": 0,
"tag": "NNG",
"typoCost": 0,
"typoFormId": 0,
"wordPosition": 0
},
{
"length": 1,
"lineNumber": 0,
"pairedToken": 4294967295,
"position": 2,
"score": -1.844599723815918,
"sentPosition": 0,
"str": "은",
"subSentPosition": 0,
"tag": "JX",
"typoCost": 0,
"typoFormId": 0,
"wordPosition": 0
},
...
]
} */
} +
+ +
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/BuildArgs.html b/kiwi-nlp/interfaces/BuildArgs.html new file mode 100644 index 00000000..9503c54b --- /dev/null +++ b/kiwi-nlp/interfaces/BuildArgs.html @@ -0,0 +1,37 @@ +BuildArgs | kiwi-nlp

Interface BuildArgs

interface BuildArgs {
    integrateAllomorph?: boolean;
    loadDefaultDict?: boolean;
    loadMultiDict?: boolean;
    loadTypoDict?: boolean;
    modelFiles: ModelFiles;
    modelType?: "knlm" | "sbg";
    preanalyzedWords?: PreanalyzedWord[];
    typoCostThreshold?: number;
    typos?:
        | "basic"
        | "none"
        | TypoTransformer
        | "continual"
        | "basicWithContinual";
    userDicts?: string[];
    userWords?: UserWord[];
}

Properties

integrateAllomorph?: boolean

If true, unify phonological variants. +Outputs endings that change form depending on the positivity/negativity of the preceding vowel, such as /아/ and /어/ or /았/ and /었/, as one. +Defaults to true

+
loadDefaultDict?: boolean

If true, the default dictionary is loaded. +The default dictionary consists of proper noun headings extracted from Wikipedia and Namuwiki. +Defaults to true.

+
loadMultiDict?: boolean

If true, the built-in polysemous dictionary is loaded. +The polysemous dictionary consists of proper nouns listed in WikiData. +Defaults to true.

+
loadTypoDict?: boolean

If true, the built-in typo dictionary is loaded. +The typo dictionary consists of a subset of common misspellings and variant endings that are commonly used on the internet. +Defaults to true.

+
modelFiles: ModelFiles

The model files to load. Required.

+
modelType?: "knlm" | "sbg"

Specifies the language model to use for morphological analysis. Defaults to 'knlm'.

+
    +
  • knlm: Fast and can model the relationships between morphemes within a short distance (usually two or three) with high accuracy. However, it has the limitation that it cannot take into account the relationships between morphemes over a long distance.
  • +
  • sbg: Driven by internally calibrating the results of SkipBigram to the results of KNLM. At a processing time increase of about 30% compared to KNLM, it is able to model relationships between morphemes over large distances (up to 8 real morphemes) with moderate accuracy.
  • +
+
preanalyzedWords?: PreanalyzedWord[]

Preanalyzed words to load.

+
typoCostThreshold?: number

The maximum typo cost to consider when correcting typos. Typos beyond this cost will not be explored. Defaults to 2.5.

+
typos?:
    | "basic"
    | "none"
    | TypoTransformer
    | "continual"
    | "basicWithContinual"

The typo information to use for correction. +Can be one of the built in none, basic, continual, basicWithContinual typo sets, or a custom TypoTransformer. +Defaults to none, which disables typo correction.

+
userDicts?: string[]

Additional user dictionaries to load. Used files must appear in the modelFiles object.

+
userWords?: UserWord[]

Additional user words to load.

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/Kiwi.html b/kiwi-nlp/interfaces/Kiwi.html new file mode 100644 index 00000000..a6a7d443 --- /dev/null +++ b/kiwi-nlp/interfaces/Kiwi.html @@ -0,0 +1,75 @@ +Kiwi | kiwi-nlp

Interface Kiwi

Interface that performs the actual morphological analysis. +Cannot be constructed directly, use KiwiBuilder to create a new instance.

+
interface Kiwi {
    analyze: ((str: string, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenResult);
    analyzeTopN: ((str: string, n: number, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenResult[]);
    createMorphemeSet: ((morphs: Morph[]) => number);
    destroyMorphemeSet: ((id: number) => void);
    getCutOffThreshold: (() => number);
    getIntegrateAllomorphic: (() => boolean);
    getMaxUnkFormSize: (() => number);
    getSpacePenalty: (() => number);
    getSpaceTolerance: (() => number);
    getTypoCostWeight: (() => number);
    getUnkScoreBias: (() => number);
    getUnkScoreScale: (() => number);
    isTypoTolerant: (() => boolean);
    joinSent: ((morphs: SentenceJoinMorph[], lmSearch?: boolean, withRanges?: boolean) => SentenceJoinResult);
    ready: (() => boolean);
    setCutOffThreshold: ((v: number) => void);
    setIntegrateAllomorphic: ((v: boolean) => void);
    setMaxUnkFormSize: ((v: number) => void);
    setSpacePenalty: ((v: number) => void);
    setSpaceTolerance: ((v: number) => void);
    setTypoCostWeight: ((v: number) => void);
    setUnkScoreBias: ((v: number) => void);
    setUnkScoreScale: ((v: number) => void);
    splitIntoSents: ((str: string, matchOptions?: Match, withTokenResult?: boolean) => SentenceSplitResult);
    tokenize: ((str: string, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenInfo[]);
    tokenizeTopN: ((str: string, n: number, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenInfo[][]);
}

Properties

analyze: ((str: string, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenResult)

Performs morphological analysis. Returns a single list of tokens along with an analysis score. Use tokenize if the result score is not needed. Use analyzeTopN if you need multiple results.

+

Type declaration

    • (str, matchOptions?, blockList?, pretokenized?): TokenResult
    • Parameters

      • str: string

        String to analyze

        +
      • OptionalmatchOptions: Match

        Specifies the special string pattern extracted. This can be set to any combination of Match by using the bitwise OR operator.

        +
      • OptionalblockList: number | Morph[]

        Specifies a list of morphemes to prohibit from appearing as candidates in the analysis.

        +
      • Optionalpretokenized: PretokenizedSpan[]

        Predefines the result of morphological analysis of a specific segment of text prior to morphological analysis. The section of text defined by this value will always be tokenized in that way only.

        +

      Returns TokenResult

      A single TokenResult object.

      +
analyzeTopN: ((str: string, n: number, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenResult[])

Performs morphological analysis. Returns multiple list of tokens along with an analysis score. Use tokenizeTopN if the result scores are not needed. Use analyze if you need only one result.

+

Type declaration

    • (str, n, matchOptions?, blockList?, pretokenized?): TokenResult[]
    • Parameters

      • str: string

        String to analyze

        +
      • n: number

        Number of results to return

        +
      • OptionalmatchOptions: Match

        Specifies the special string pattern extracted. This can be set to any combination of Match by using the bitwise OR operator.

        +
      • OptionalblockList: number | Morph[]

        Specifies a list of morphemes to prohibit from appearing as candidates in the analysis.

        +
      • Optionalpretokenized: PretokenizedSpan[]

        Predefines the result of morphological analysis of a specific segment of text prior to morphological analysis. The section of text defined by this value will always be tokenized in that way only.

        +

      Returns TokenResult[]

      A list of TokenResult objects.

      +
createMorphemeSet: ((morphs: Morph[]) => number)

Creates a reusable morpheme set from a list of morphemes. This is intended to be used as the blockList parameter for the analyse and tokenize methods. +NOTE: The morpheme set must be destroyed using destroyMorphemeSet when it is no longer needed. Otherwise, it will cause a memory leak. +If you are using the morpheme set only once, you can pass the morpheme list directly to the blockList parameter instead of creating a morpheme set.

+

Type declaration

    • (morphs): number
    • Parameters

      • morphs: Morph[]

        List of morphemes to create a set from

        +

      Returns number

      an handle to the created morpheme set

      +
destroyMorphemeSet: ((id: number) => void)

Destroys a morpheme set created by createMorphemeSet.

+

Type declaration

    • (id): void
    • Parameters

      • id: number

        Handle to the morpheme set to destroy

        +

      Returns void

getCutOffThreshold: (() => number)
getIntegrateAllomorphic: (() => boolean)
getMaxUnkFormSize: (() => number)
getSpacePenalty: (() => number)
getSpaceTolerance: (() => number)
getTypoCostWeight: (() => number)
getUnkScoreBias: (() => number)
getUnkScoreScale: (() => number)
isTypoTolerant: (() => boolean)

Tells you if the current Kiwi object was created with typo correction turned on.

+

Type declaration

    • (): boolean
    • Returns boolean

      true if typo correction is turned on.

      +
joinSent: ((morphs: SentenceJoinMorph[], lmSearch?: boolean, withRanges?: boolean) => SentenceJoinResult)

Combines morphemes and restores them to a sentence. Endings are changed to the appropriate form to match the preceding morpheme.

+

Type declaration

    • (morphs, lmSearch?, withRanges?): SentenceJoinResult
    • Parameters

      • morphs: SentenceJoinMorph[]

        List of morphemes to combine

        +
      • OptionallmSearch: boolean

        When there is an ambiguous morpheme that can be restored in more than one form, if this value is true, the language model is explored to select the best form. If false, no exploration is performed, but restoration is faster.

        +
      • OptionalwithRanges: boolean

        Wehther to include the ranges of the morphemes in the returned SentenceJoinResult object.

        +

      Returns SentenceJoinResult

ready: (() => boolean)

Tells whether the current Kiwi object is ready to perform morphological analysis.

+

Type declaration

    • (): boolean
    • Returns boolean

      true if it is ready for morphological analysis.

      +
setCutOffThreshold: ((v: number) => void)
setIntegrateAllomorphic: ((v: boolean) => void)
setMaxUnkFormSize: ((v: number) => void)
setSpacePenalty: ((v: number) => void)
setSpaceTolerance: ((v: number) => void)
setTypoCostWeight: ((v: number) => void)
setUnkScoreBias: ((v: number) => void)
setUnkScoreScale: ((v: number) => void)
splitIntoSents: ((str: string, matchOptions?: Match, withTokenResult?: boolean) => SentenceSplitResult)

Returns the input text split into sentences. This method uses stemming internally during the sentence splitting process, so it can also be used to get stemming results simultaneously with sentence splitting.

+

Type declaration

    • (str, matchOptions?, withTokenResult?): SentenceSplitResult
    • Parameters

      • str: string

        String to split

        +
      • OptionalmatchOptions: Match

        Specifies the special string pattern extracted. This can be set to any combination of Match by using the bitwise OR operator.

        +
      • OptionalwithTokenResult: boolean

        Specifies whether to include the result of morphological analysis in the returned SentenceSplitResult object.

        +

      Returns SentenceSplitResult

      A SentenceSplitResult object.

      +
tokenize: ((str: string, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenInfo[])

Performs morphological analysis. Returns a single list of tokens. Use analyze if the result score is needed. Use tokenizeTopN if you need multiple results.

+

Type declaration

    • (str, matchOptions?, blockList?, pretokenized?): TokenInfo[]
    • Parameters

      • str: string

        String to analyze

        +
      • OptionalmatchOptions: Match

        Specifies the special string pattern extracted. This can be set to any combination of Match by using the bitwise OR operator.

        +
      • OptionalblockList: number | Morph[]

        Specifies a list of morphemes to prohibit from appearing as candidates in the analysis.

        +
      • Optionalpretokenized: PretokenizedSpan[]

        Predefines the result of morphological analysis of a specific segment of text prior to morphological analysis. The section of text defined by this value will always be tokenized in that way only.

        +

      Returns TokenInfo[]

      A list of TokenInfo object.

      +
tokenizeTopN: ((str: string, n: number, matchOptions?: Match, blockList?: number | Morph[], pretokenized?: PretokenizedSpan[]) => TokenInfo[][])

Performs morphological analysis. Returns multiple lists of tokens. Use analyzeTopN if the result scores are needed. Use tokenize if you need only one result.

+

Type declaration

    • (str, n, matchOptions?, blockList?, pretokenized?): TokenInfo[][]
    • Parameters

      • str: string

        String to analyze

        +
      • n: number

        Number of results to return

        +
      • OptionalmatchOptions: Match

        Specifies the special string pattern extracted. This can be set to any combination of Match by using the bitwise OR operator.

        +
      • OptionalblockList: number | Morph[]

        Specifies a list of morphemes to prohibit from appearing as candidates in the analysis.

        +
      • Optionalpretokenized: PretokenizedSpan[]

        Predefines the result of morphological analysis of a specific segment of text prior to morphological analysis. The section of text defined by this value will always be tokenized in that way only.

        +

      Returns TokenInfo[][]

      A list of lists of TokenInfo objects.

      +
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/Morph.html b/kiwi-nlp/interfaces/Morph.html new file mode 100644 index 00000000..9e9e59d5 --- /dev/null +++ b/kiwi-nlp/interfaces/Morph.html @@ -0,0 +1,3 @@ +Morph | kiwi-nlp

Interface Morph

interface Morph {
    form: string;
    tag: string;
}

Hierarchy (view full)

Properties

Properties

form: string
tag: string
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/PreanalyzedToken.html b/kiwi-nlp/interfaces/PreanalyzedToken.html new file mode 100644 index 00000000..b22d677e --- /dev/null +++ b/kiwi-nlp/interfaces/PreanalyzedToken.html @@ -0,0 +1,9 @@ +PreanalyzedToken | kiwi-nlp

Interface PreanalyzedToken

interface PreanalyzedToken {
    end?: number;
    form: string;
    start?: number;
    tag: string;
}

Properties

Properties

end?: number

Ebd position of the token in the preanalyzed word. If omitted, all token positions are automatically calculated.

+
form: string

Form of the token.

+
start?: number

Start position of the token in the preanalyzed word. If omitted, all token positions are automatically calculated.

+
tag: string

Part-of-speech tag of the token.

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/PreanalyzedWord.html b/kiwi-nlp/interfaces/PreanalyzedWord.html new file mode 100644 index 00000000..25dd20d1 --- /dev/null +++ b/kiwi-nlp/interfaces/PreanalyzedWord.html @@ -0,0 +1,8 @@ +PreanalyzedWord | kiwi-nlp

Interface PreanalyzedWord

interface PreanalyzedWord {
    analyzed: PreanalyzedToken[];
    form: string;
    score?: number;
}

Properties

Properties

analyzed: PreanalyzedToken[]

The result of the morphological analysis of form.

+
form: string

Form to add.

+
score?: number

The weighted score of the morpheme sequence to add. +If there are multiple morpheme combinations that match the form, the word with the higher score will be prioritized.

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/PretokenizedSpan.html b/kiwi-nlp/interfaces/PretokenizedSpan.html new file mode 100644 index 00000000..c2f61c90 --- /dev/null +++ b/kiwi-nlp/interfaces/PretokenizedSpan.html @@ -0,0 +1,4 @@ +PretokenizedSpan | kiwi-nlp

Interface PretokenizedSpan

interface PretokenizedSpan {
    end: number;
    start: number;
    tokenization: PretokenizedToken[];
}

Properties

Properties

end: number
start: number
tokenization: PretokenizedToken[]
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/PretokenizedToken.html b/kiwi-nlp/interfaces/PretokenizedToken.html new file mode 100644 index 00000000..f3912659 --- /dev/null +++ b/kiwi-nlp/interfaces/PretokenizedToken.html @@ -0,0 +1,5 @@ +PretokenizedToken | kiwi-nlp

Interface PretokenizedToken

interface PretokenizedToken {
    end: number;
    form: string;
    start: number;
    tag: string;
}

Hierarchy (view full)

Properties

Properties

end: number
form: string
start: number
tag: string
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/SentenceJoinMorph.html b/kiwi-nlp/interfaces/SentenceJoinMorph.html new file mode 100644 index 00000000..7224f543 --- /dev/null +++ b/kiwi-nlp/interfaces/SentenceJoinMorph.html @@ -0,0 +1,4 @@ +SentenceJoinMorph | kiwi-nlp

Interface SentenceJoinMorph

interface SentenceJoinMorph {
    form: string;
    space?: Space;
    tag: string;
}

Hierarchy (view full)

Properties

Properties

form: string
space?: Space
tag: string
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/SentenceJoinResult.html b/kiwi-nlp/interfaces/SentenceJoinResult.html new file mode 100644 index 00000000..9c8d1875 --- /dev/null +++ b/kiwi-nlp/interfaces/SentenceJoinResult.html @@ -0,0 +1,3 @@ +SentenceJoinResult | kiwi-nlp

Interface SentenceJoinResult

interface SentenceJoinResult {
    ranges: SentenceSpan[];
    str: string;
}

Properties

Properties

ranges: SentenceSpan[]
str: string
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/SentenceSpan.html b/kiwi-nlp/interfaces/SentenceSpan.html new file mode 100644 index 00000000..996ac7ae --- /dev/null +++ b/kiwi-nlp/interfaces/SentenceSpan.html @@ -0,0 +1,3 @@ +SentenceSpan | kiwi-nlp

Interface SentenceSpan

interface SentenceSpan {
    end: number;
    start: number;
}

Properties

Properties

end: number
start: number
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/SentenceSplitResult.html b/kiwi-nlp/interfaces/SentenceSplitResult.html new file mode 100644 index 00000000..19e96683 --- /dev/null +++ b/kiwi-nlp/interfaces/SentenceSplitResult.html @@ -0,0 +1,5 @@ +SentenceSplitResult | kiwi-nlp

Interface SentenceSplitResult

interface SentenceSplitResult {
    spans: SentenceSpan[];
    tokenResult: TokenResult;
}

Properties

Properties

spans: SentenceSpan[]

Array of SentenceSpan objects representing the start and end positions of each sentence.

+
tokenResult: TokenResult

Array of TokenResult objects representing the morphological analysis result of the input string.

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/TokenInfo.html b/kiwi-nlp/interfaces/TokenInfo.html new file mode 100644 index 00000000..fcb3f2dd --- /dev/null +++ b/kiwi-nlp/interfaces/TokenInfo.html @@ -0,0 +1,28 @@ +TokenInfo | kiwi-nlp

Interface TokenInfo

Describes a single morpheme in the input string of the morphological analysis.

+
interface TokenInfo {
    length: number;
    lineNumber: number;
    morphId: number;
    pairedToken: number;
    position: number;
    score: number;
    sentPosition: number;
    str: string;
    subSentPosition: number;
    tag: string;
    typoCost: number;
    typoFormId: number;
    wordPosition: number;
}

Properties

length: number

Length of the morpheme in the input string.

+
lineNumber: number

Line index in the input string.

+
morphId: number

The id of the morpheme information in the used Kiwi object. -1 indicates OOV.

+
pairedToken: number

For morphemes belonging to SSO, SSC part of speech tags, the position of the paired morpheme (-1 means no corresponding morpheme).

+
position: number

The start position in the input string.

+
score: number

Language model score of the morpheme.

+
sentPosition: number

Sentence index in the input string.

+
str: string

The form of the morpheme.

+
subSentPosition: number

The index of the sub-sentence enclosed in quotation marks or parentheses. Starts at 1. A value of 0 indicates that it is not a subordinate sentence.

+
tag: string

Part of speech tag of the morpheme.

+
typoCost: number

Cost of the typo that was corrected. If no typo correction was performed, this value is 0.

+
typoFormId: number

Typo correction form if typo correction was performed. Id of pretokenized span if no typo correction was performed.

+
wordPosition: number

Word index in the input string (space based).

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/TokenResult.html b/kiwi-nlp/interfaces/TokenResult.html new file mode 100644 index 00000000..4a5d6963 --- /dev/null +++ b/kiwi-nlp/interfaces/TokenResult.html @@ -0,0 +1,5 @@ +TokenResult | kiwi-nlp

Interface TokenResult

interface TokenResult {
    score: number;
    tokens: TokenInfo[];
}

Properties

Properties

score: number

The score of the morphological analysis result.

+
tokens: TokenInfo[]

Array of TokenInfo objects representing the morphemes in the input string.

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/TypoDefinition.html b/kiwi-nlp/interfaces/TypoDefinition.html new file mode 100644 index 00000000..6158b6a7 --- /dev/null +++ b/kiwi-nlp/interfaces/TypoDefinition.html @@ -0,0 +1,11 @@ +TypoDefinition | kiwi-nlp

Interface TypoDefinition

interface TypoDefinition {
    condition?:
        | "none"
        | "any"
        | "vowel"
        | "applosive";
    cost?: number;
    error: string[];
    orig: string[];
}

Properties

Properties

condition?:
    | "none"
    | "any"
    | "vowel"
    | "applosive"

Conditions under which typos can be replaced. +One of none, any (after any letter), vowel (after a vowel), or applosive (after an applosive). +Defaults to none when omitted.

+
cost?: number

Replacement cost. Defaults to 1.

+
error: string[]

The typos to be replaced

+
orig: string[]

Source strings

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/TypoTransformer.html b/kiwi-nlp/interfaces/TypoTransformer.html new file mode 100644 index 00000000..cd9e65cb --- /dev/null +++ b/kiwi-nlp/interfaces/TypoTransformer.html @@ -0,0 +1,5 @@ +TypoTransformer | kiwi-nlp

Interface TypoTransformer

interface TypoTransformer {
    continualTypoCost?: number;
    defs: TypoDefinition[];
}

Properties

continualTypoCost?: number

The cost of continual typos. Defaults to 1.

+

A list of TypoDefinition that define typo generation rules.

+
\ No newline at end of file diff --git a/kiwi-nlp/interfaces/UserWord.html b/kiwi-nlp/interfaces/UserWord.html new file mode 100644 index 00000000..e626e012 --- /dev/null +++ b/kiwi-nlp/interfaces/UserWord.html @@ -0,0 +1,14 @@ +UserWord | kiwi-nlp

Interface UserWord

A single user word to add.

+
interface UserWord {
    origWord?: string;
    score?: number;
    tag?: string;
    word: string;
}

Properties

Properties

origWord?: string

The original morpheme of the morpheme to be added. +If the morpheme to be added is a variant of a particular morpheme, the original morpheme can be passed as this argument. +If it is not present, it can be omitted.

+
score?: number

The weighted score of the morpheme to add. +If there are multiple morpheme combinations that match the form,the word with the higher score will be prioritized. +Defaults to 0.

+
tag?: string

Part-of-speech tag. Defaults to 'NNP'.

+
word: string

The word to add.

+
\ No newline at end of file diff --git a/kiwi-nlp/modules.html b/kiwi-nlp/modules.html new file mode 100644 index 00000000..f8612964 --- /dev/null +++ b/kiwi-nlp/modules.html @@ -0,0 +1,23 @@ +kiwi-nlp
\ No newline at end of file diff --git a/kiwi-nlp/types/KiwiAsync.html b/kiwi-nlp/types/KiwiAsync.html new file mode 100644 index 00000000..9712e800 --- /dev/null +++ b/kiwi-nlp/types/KiwiAsync.html @@ -0,0 +1,4 @@ +KiwiAsync | kiwi-nlp

Type Alias KiwiAsync

KiwiAsync: AsyncMethods<Kiwi>

Interface that performs the actual morphological analysis. +Same as Kiwi, but with all methods returning promises. This can be used when the original Kiwi object is constructed with a Web Worker. +Cannot be constructed directly.

+
\ No newline at end of file diff --git a/kiwi-nlp/types/ModelFiles.html b/kiwi-nlp/types/ModelFiles.html new file mode 100644 index 00000000..2ab919c5 --- /dev/null +++ b/kiwi-nlp/types/ModelFiles.html @@ -0,0 +1,3 @@ +ModelFiles | kiwi-nlp

Type Alias ModelFiles

ModelFiles: {
    [name: string]: ArrayBufferView | string;
}

A single file to be loaded. The key is the name of the file and the value is the file data. +The file data can be a string representing a URL or an ArrayBufferView directly containing the file data.

+
\ No newline at end of file diff --git a/kiwi-nlp/types/MorphemeSet.html b/kiwi-nlp/types/MorphemeSet.html new file mode 100644 index 00000000..0b2eb39b --- /dev/null +++ b/kiwi-nlp/types/MorphemeSet.html @@ -0,0 +1 @@ +MorphemeSet | kiwi-nlp

Type Alias MorphemeSet

MorphemeSet: number
\ No newline at end of file