This is an automated email from the ASF dual-hosted git repository. sergeykamov pushed a commit to branch NLPCRAFT-513 in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft-website.git
commit 13f029788ffb1c4f6295955ba1f7a7fc866d0528 Author: skhdl <[email protected]> AuthorDate: Sat Oct 29 09:53:29 2022 +0400 WIP. --- api-components.html | 46 +++++++++++++++++----------------- built-in-builder.html | 30 +++++++++++----------- built-in-entity-parser.html | 58 +++++++++++++++++++++---------------------- built-in-overview.html | 18 +++++++------- built-in-token-enricher.html | 22 ++++++++-------- built-in-token-parser.html | 4 +-- custom-components.html | 28 ++++++++++----------- examples/light_switch.html | 4 +-- examples/light_switch_fr.html | 18 +++++++------- examples/light_switch_ru.html | 16 ++++++------ examples/pizzeria.html | 20 +++++++-------- examples/time.html | 8 +++--- first-example.html | 4 +-- short-term-memory.html | 8 +++--- 14 files changed, 142 insertions(+), 142 deletions(-) diff --git a/api-components.html b/api-components.html index ab17278..ec78f18 100644 --- a/api-components.html +++ b/api-components.html @@ -28,9 +28,9 @@ id: api-components <p> NLPCraft project is based on two main concepts <code>Data Model</code> and <code>Client</code> which have API representations - <a href="apis/latest/org/apache/nlpcraft/NCModel.html">NCModel</a> and - <a href="apis/latest/org/apache/nlpcraft/NCModelClient.html">NCModelClient</a>. - For work with the system you should prepare <a href="apis/latest/org/apache/nlpcraft/NCModel.html">NCModel</a> instance + {% scaladoc NCModel NCModel %} and + {% scaladoc NCModelClient NCModelClient %}. + For work with the system you should prepare {% scaladoc NCModel NCModel %} instance which is based on configuration and list of components named <code>Pipeline</code>. After you just communicate with prepared model via client's methods. </p> @@ -78,7 +78,7 @@ id: api-components <tr> <td><code>Token</code></td> <td> - <code>Token</code> represented as <a href="apis/latest/org/apache/nlpcraft/NCToken.html">NCToken</a> + <code>Token</code> represented as {% scaladoc NCToken NCToken %} is simple string, part of user input, which split according to some rules for instance by spaces and some additional conditions which depend on language and some expectations. So user input "<b>Where is it?</b>" contains four tokens: @@ -95,13 +95,13 @@ id: api-components product, etc., that can be denoted with a proper name. It can be abstract or have a physical existence. Each <code>entity</code> can contain one or more tokens. <code>Entities</code> represented as - <a href="apis/latest/org/apache/nlpcraft/NCEntity.html">NCEntity</a> are input for searching <code>intents</code> according to <a href="intent-matching.html">Intent matching</a> conditions. + {% scaladoc NCEntity NCEntity %} are input for searching <code>intents</code> according to <a href="intent-matching.html">Intent matching</a> conditions. </td> </tr> <tr> <td><code>Variant</code></td> <td> - <code>Variant</code> represented as <a href="apis/latest/org/apache/nlpcraft/NCVariant.html">NCVariant</a> + <code>Variant</code> represented as {% scaladoc NCVariant NCVariant %} is a list of <code>entities</code>. Potentially, each <code>token</code> can be recognized as different <code>entities</code>, so user input can be processed as set of <code>variants</code>. @@ -217,7 +217,7 @@ id: api-components <h2 class="section-title">Client responsibility<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <code>Client</code> represented as <a href="apis/latest/org/apache/nlpcraft/NCModelClient.html">NCModelClient</a> + <code>Client</code> represented as {% scaladoc NCModelClient NCModelClient %} is necessary for communication with the <code>Data Model</code>. Base client methods are described below. </p> @@ -233,9 +233,9 @@ id: api-components <td><a href="apis/latest/org/apache/nlpcraft/NCModelClient.html#ask-fffff9ce">ask()</a></td> <td> Passes user text input to the model and receives back execution - <a href="apis/latest/org/apache/nlpcraft/NCResult.html">NCResult</a> or + {% scaladoc NCResult NCResult %} or rejection exception if there isn't any triggered intents. - <a href="apis/latest/org/apache/nlpcraft/NCResult.html">NCResult</a> is wrapper on + {% scaladoc NCResult NCResult %} is wrapper on callback method execution result with additional information. </td> </tr> @@ -279,7 +279,7 @@ id: api-components <p> <code>Data Model</code> configuration represented as - <a href="apis/latest/org/apache/nlpcraft/NCModelConfig.html">NCModelConfig</a> + {% scaladoc NCModelConfig NCModelConfig %} contains set of parameters which are described below. </p> <table class="gradient-table"> @@ -327,7 +327,7 @@ id: api-components <h2 class="section-title">Model pipeline <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - Model <code>Pipeline</code> is represented as <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a> and + Model <code>Pipeline</code> is represented as {% scaladoc NCPipeline NCPipeline %} and contains following components: </p> @@ -341,7 +341,7 @@ id: api-components </thead> <tbody> <tr> - <td><a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a></td> + <td>{% scaladoc NCTokenParser NCTokenParser %}</td> <td>Mandatory single</td> <td> <code>Token parser</code> should be able to parse user input plain text and split this text @@ -352,7 +352,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a></td> + <td> {% scaladoc NCTokenEnricher NCTokenEnricher %}</td> <td>Optional list</td> <td> <code>Tokens enricher</code> is a component which allow to add additional properties for prepared tokens, @@ -361,7 +361,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCTokenValidator.html">NCTokenValidator</a></td> + <td> {% scaladoc NCTokenValidator NCTokenValidator %}</td> <td>Optional list</td> <td> <code>Token validator</code> is a component which allow to inspect prepared tokens and @@ -369,7 +369,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCEntityParser.html">NCEntityParser</a></td> + <td> {% scaladoc NCEntityParser NCEntityParser %}</td> <td>Mandatory list</td> <td> <code>Entity parser</code> is a component which allow to find user defined named entities @@ -381,7 +381,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCEntityEnricher.html">NCEntityEnricher</a></td> + <td> {% scaladoc NCEntityEnricher NCEntityEnricher %}</td> <td>Optional list</td> <td> <code>Entity enricher</code> is component which allows to add additional properties for prepared entities. @@ -389,7 +389,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCEntityMapper.html">NCEntityMapper</a></td> + <td> {% scaladoc NCEntityMapper NCEntityMapper %}</td> <td>Optional list</td> <td> <code>Entity mappers</code> is component which allows to map one set of entities to another after the entities @@ -397,7 +397,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCEntityValidator.html">NCEntityValidator</a></td> + <td> {% scaladoc NCEntityValidator NCEntityValidator %}</td> <td>Optional list</td> <td> <code>Entity validator</code> is a component which allow to inspect prepared entities and @@ -405,7 +405,7 @@ id: api-components </td> </tr> <tr> - <td> <a href="apis/latest/org/apache/nlpcraft/NCVariantFilter.html">NCVariantFilter</a></td> + <td> {% scaladoc NCVariantFilter NCVariantFilter %}</td> <td>Optional single</td> <td> <code>Variant filter</code> is a component which allows filtering detected variants and rejecting undesirable. @@ -415,9 +415,9 @@ id: api-components </table> <p> - Below <a href="apis/latest/org/apache/nlpcraft/NCModel.html">NCModel</a> creation example. - <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a> is prepared using - <a href="apis/latest/org/apache/nlpcraft/NCPipelineBuilder.html">NCPipelineBuilder</a> class helper. + Below {% scaladoc NCModel NCModel %} creation example. + {% scaladoc NCPipeline NCPipeline %} is prepared using + {% scaladoc NCPipelineBuilder NCPipelineBuilder %} class helper. </p> <pre class="brush: scala, highlight: []"> @@ -443,7 +443,7 @@ id: api-components <h2 class="section-title">Model behavior overriding<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - There are also several <a href="/apis/latest/org/apache/nlpcraft/NCModel.html">NCModel</a> + There are also several {% scaladoc NCModel NCModel %} callbacks that you can override to affect model behavior during <a href="/intent-matching.html#model_callbacks">intent matching</a> to perform logging, debugging, statistic or usage collection, explicit update or initialization of diff --git a/built-in-builder.html b/built-in-builder.html index e06abb5..1dc50d2 100644 --- a/built-in-builder.html +++ b/built-in-builder.html @@ -26,21 +26,21 @@ id: built-in-builder <h2 class="section-title">Pipeline builder<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/NCPipelineBuilder.html">NCPipelineBuilder</a> class - is designed for simplifying preparing <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a> instance. - It allows to construct <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a> instance + {% scaladoc NCPipelineBuilder NCPipelineBuilder %} class + is designed for simplifying preparing {% scaladoc NCPipeline NCPipeline %} instance. + It allows to construct {% scaladoc NCPipeline NCPipeline %} instance adding nested components via its methods. It also contains a number of methods <a href="apis/latest/org/apache/nlpcraft/NCPipelineBuilder.html#withSemantic-fffff4b0">withSemantic()</a> which allow to prepare pipeline instance based on - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser">NCSemanticEntityParser</a> and configured language. + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} and configured language. Currently only <b>English</b> language is supported with broad set of built-in components: - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCOpenNLPTokenParser.html">NCOpenNLPTokenParser</a>, - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher.html">NCOpenNLPLemmaPosTokenEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnStopWordsTokenEnricher.html">NCEnStopWordsTokenEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnSwearWordsTokenEnricher.html">NCEnSwearWordsTokenEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnQuotesTokenEnricher.html">NCEnQuotesTokenEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnDictionaryTokenEnricher.html">NCEnDictionaryTokenEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnBracketsTokenEnricher.html">NCEnBracketsTokenEnricher</a>. + {% scaladoc nlp/parsers/NCOpenNLPTokenParser NCOpenNLPTokenParser %}, + {% scaladoc nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher NCOpenNLPLemmaPosTokenEnricher %}, + {% scaladoc nlp/enrichers/NCEnStopWordsTokenEnricher NCEnStopWordsTokenEnricher %}, + {% scaladoc nlp/enrichers/NCEnSwearWordsTokenEnricher NCEnSwearWordsTokenEnricher %}, + {% scaladoc nlp/enrichers/NCEnQuotesTokenEnricher NCEnQuotesTokenEnricher %}, + {% scaladoc nlp/enrichers/NCEnDictionaryTokenEnricher NCEnDictionaryTokenEnricher %}, + {% scaladoc nlp/enrichers/NCEnBracketsTokenEnricher NCEnBracketsTokenEnricher %}. </p> </section> @@ -87,18 +87,18 @@ id: built-in-builder <li> <code>Line 6</code> defines token parser <code>NCStanfordNLPTokenParser</code>, pipeline mandatory component. Note that this one instance is used for two places: in pipeline definition on <code>line 12</code> and - in <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> definition on <code>line 14</code>. + in {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} definition on <code>line 14</code>. </li> <li> <code>Line 13</code> defines configured - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnStopWordsTokenEnricher.html">NCEnStopWordsTokenEnricher </a> + {% scaladoc nlp/enrichers/NCEnStopWordsTokenEnricher NCEnStopWordsTokenEnricher %} token enricher. </li> <li> - <code>Line 14</code> defines <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + <code>Line 14</code> defines {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} configured in YAML file <code>pizzeria_model.yaml</code>. - It uses also simple implementation of <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticStemmer.html">NCSemanticStemmer</a> + It uses also simple implementation of {% scaladoc nlp/parsers/NCSemanticStemmer NCSemanticStemmer %} created on <code>line 7</code> and token parser prepared on <code>line 6</code>. </li> <li> diff --git a/built-in-entity-parser.html b/built-in-entity-parser.html index 1cd3868..7110a16 100644 --- a/built-in-entity-parser.html +++ b/built-in-entity-parser.html @@ -26,7 +26,7 @@ id: built-in-entity-parser <h2 class="section-title">Built-in Entity Parser<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/NCEntityParser.html">NCEntityParser</a> + {% scaladoc NCEntityParser NCEntityParser %} is a component which allows to find user defined named entities based on prepared tokens as input. </p> @@ -57,7 +57,7 @@ id: built-in-entity-parser <h2 class="section-title">OpenNLP Based Parser<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCOpenNLPTokenParser.html">NCOpenNLPTokenParser</a> is wrapper on <a href="https://opennlp.apache.org/">Apache OpenNLP</a> NER components. + {% scaladoc nlp/parsers/NCOpenNLPTokenParser NCOpenNLPTokenParser %} is wrapper on <a href="https://opennlp.apache.org/">Apache OpenNLP</a> NER components. Look at the supported NER finders models <a href="https://opennlp.sourceforge.net/models-1.5/">here</a>. For example for English language are accessible: <code>Location</code>, <code>Money</code>, <code>Person</code>, <code>Organization</code>, <code>Date</code>, <code>Time</code> and <code>Percentage</code>. @@ -82,11 +82,11 @@ id: built-in-entity-parser <h2 class="section-title">NLP Parser<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCOpenNLPTokenParser.html">NCOpenNLPTokenParser</a> converts NLP tokens into entities with four mandatory properties: + {% scaladoc nlp/parsers/NCOpenNLPTokenParser NCOpenNLPTokenParser %} converts NLP tokens into entities with four mandatory properties: <code>nlp:token:text</code>, <code>nlp:token:index</code>, <code>nlp:token:startCharIndex</code> and <code>nlp:token:endCharIndex</code>. - However, if any other <a href="apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> components - are registered in the <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a> + However, if any other {% scaladoc NCTokenEnricher NCTokenEnricher %} components + are registered in the {% scaladoc NCPipeline NCPipeline %} and they add other properties into the tokens, these properties also will be copied with names prefixed with <code>nlp:token:</code>. It is language independent component. @@ -99,10 +99,10 @@ id: built-in-entity-parser <p> Semantic entity parser - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> - is synonyms based implementation of <a href="apis/latest/org/apache/nlpcraft/NCEntityParser.html">NCEntityParser</a>. + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} + is synonyms based implementation of {% scaladoc NCEntityParser NCEntityParser %}. This parser provides simple but very powerful way to find domain specific data in the input text. - It defines list of <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticElement.html">NCSemanticElement</a> + It defines list of {% scaladoc nlp/parsers/NCSemanticElement NCSemanticElement %} which are represent <a href="https://en.wikipedia.org/wiki/Named-entity_recognition">Named entities</a>. We will name this list as <code>Semantic Model</code>. </p> @@ -195,7 +195,7 @@ id: built-in-entity-parser <h3 class="sub-section-title">Elements</h3> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticElement.html">NCSemanticElement</a> represents + {% scaladoc nlp/parsers/NCSemanticElement NCSemanticElement %} represents NER element for its detection un the user input. <p> @@ -224,7 +224,7 @@ id: built-in-entity-parser </div> <p> - Each <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticElement.html">NCSemanticElement</a> + Each {% scaladoc nlp/parsers/NCSemanticElement NCSemanticElement %} is presented by <code>id</code>, <code>groups</code>, <code>synonyms</code>, <code>values</code> and <code>properties</code>. <p> <span id="synonyms" class="section-sub-title">Synonyms <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></span> @@ -280,7 +280,7 @@ id: built-in-entity-parser </p> <p> Note that this synonyms definition is also used in the following - <a href="/apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticElement.html">NCSemanticElement</a> methods: + {% scaladoc nlp/parsers/NCSemanticElement NCSemanticElement %} methods: </p> <ul> <li><code>getSynonyms()</code> - gets synonyms to match on.</li> @@ -295,7 +295,7 @@ id: built-in-entity-parser </p> <p> When a semantic element is recognized it is made available to the model's matching logic as an instance of - the <a href="/apis/latest/org/apache/nlpcraft/NCToken.html">NCToken</a> interface. + the {% scaladoc NCToken NCToken %} interface. This interface has a method <a href="/apis/latest/org/apache/nlpcraft/NCToken.html">getValue()</a> which returns the name of the value, if any, by which @@ -364,12 +364,12 @@ id: built-in-entity-parser <p> Note that the proper grouping of the elements is also necessary for the correct operation of Short-Term-Memory (STM) in the conversational context. Consider a - <a href="/apis/latest/org/apache/nlpcraft/NCToken.html">NCToken</a> that + {% scaladoc NCToken NCToken %} that represents a previously found semantic element that is stored in the conversation. Such token will be overridden in the conversation by the more <b>recent token</b> from the <b>same group</b> - a critical rule of maintaining the proper conversational context. See - <a href="/apis/latest/org/apache/nlpcraft/NCConversation.html">NCConversation</a> + {% scaladoc NCConversation NCConversation %} for mode details. </p> @@ -379,7 +379,7 @@ id: built-in-entity-parser together with option groups allow for significant simplification of this task. Macros allow you to give a name to an often used set of words or option groups and reuse it without repeating those words or option groups again and again. A model provides a list of macros via - <a href="/apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">macros</a> method. + {% scaladoc nlp/parsers/NCSemanticEntityParser macros %} method. Each macro has a name in a form of <code><X></code> where <code>X</code> is any string, and a string value. Note that macros can be nested (but not recursive), i.e. macro value can include references to other macros. When macro name <code>X</code> is encountered in the synonym it gets recursively @@ -638,14 +638,14 @@ id: built-in-entity-parser <code>Line 5</code> shows <code>macro</code> parameter definition. </li> <li> - <code>Line 10</code> shows <code>macro</code> list of <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticElement.html">NCSemanticElement</a> parameter usage. + <code>Line 10</code> shows <code>macro</code> list of {% scaladoc nlp/parsers/NCSemanticElement NCSemanticElement %} parameter usage. </li> <li> Note that usage <a href="apis/latest/org/apache/nlpcraft/NCPipelineBuilder.html#withSemantic-fffff4b0">withSemantic()</a> method which represented on <code>line 3</code> is optional. - You can add <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCNLPEntityParser.html">NCNLPEntityParser</a> - as usual <a href="apis/latest/org/apache/nlpcraft/NCEntityParser.html">NCEntityParser</a> - when you define your <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a>. + You can add {% scaladoc nlp/parsers/NCNLPEntityParser NCNLPEntityParser %} + as usual {% scaladoc NCEntityParser NCEntityParser %} + when you define your {% scaladoc NCPipeline NCPipeline %}. </li> </ul> @@ -684,10 +684,10 @@ id: built-in-entity-parser </ul> <p> - If you want to use <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + If you want to use {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} with not English language, you have to provide custom - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticStemmer.html">NCSemanticStemmer</a> and - <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc nlp/parsers/NCSemanticStemmer NCSemanticStemmer %} and + {% scaladoc NCTokenParser NCTokenParser %} implementations for required language. Look at the <a href="examples/light_switch_fr.html">Light Switch FR</a> for more details. </p> @@ -711,16 +711,16 @@ id: built-in-entity-parser <ul> <li> <code>Line 4</code> includes <code>NCFrTokenParser</code> import. - Its custom <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + Its custom {% scaladoc NCTokenParser NCTokenParser %} implementation for French language, described here: <a href="examples/light_switch_fr.html">Light Switch FR</a>. </li> <li> - <code>Line 8</code> defines custom <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticStemmer.html">NCSemanticStemmer</a> + <code>Line 8</code> defines custom {% scaladoc nlp/parsers/NCSemanticStemmer NCSemanticStemmer %} implementation for French language. </li> <li> As you can see, <code>NCFrSemanticEntityParser</code> is very simple extension of - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} base class, look at <code>line 7</code>. </li> </ul> @@ -730,10 +730,10 @@ id: built-in-entity-parser <p> If you want to use - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} with any not English language you have to provide custom - <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticStemmer.html">NCSemanticStemmer</a> and - <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc nlp/parsers/NCSemanticStemmer NCSemanticStemmer %} and + {% scaladoc NCTokenParser NCTokenParser %} implementations for this desirable language. Look at the <a href="examples/light_switch_fr.html">Light Switch FR</a> for more details. </p> @@ -753,4 +753,4 @@ id: built-in-entity-parser <li><a href="#parser-semantic-extending">SemanticParser Languages Extending</a></li> {% include quick-links.html %} </ul> -</div> \ No newline at end of file +</div> diff --git a/built-in-overview.html b/built-in-overview.html index f65663e..d301839 100644 --- a/built-in-overview.html +++ b/built-in-overview.html @@ -26,7 +26,7 @@ id: built-in-overview <h2 class="section-title">Built-in Components Overview<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - Model <a href="apis/latest/org/apache/nlpcraft/NCPipeline.html">NCPipeline</a> contains + Model {% scaladoc NCPipeline NCPipeline %} contains chain of components traits which are responsible for sentence processing. Some built-in implementations of these traits are described below. </p> @@ -35,17 +35,17 @@ id: built-in-overview <ul> <li> Pipeline components which have built-in implementations and can have broad range of uses: - <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a>, - <a href="apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/NCEntityParser.html">NCEntityParser</a>. + {% scaladoc NCTokenParser NCTokenParser %}, + {% scaladoc NCTokenEnricher NCTokenEnricher %}, + {% scaladoc NCEntityParser NCEntityParser %}. </li> <li> Pipeline components which can't have built-in implementations because their logic are depended on concrete user model: - <a href="apis/latest/org/apache/nlpcraft/NCTokenValidator.html">NCTokenValidator</a>, - <a href="apis/latest/org/apache/nlpcraft/NCEntityEnricher.html">NCEntityEnricher</a>, - <a href="apis/latest/org/apache/nlpcraft/NCEntityValidator.html">NCEntityValidator</a>, - <a href="apis/latest/org/apache/nlpcraft/NCEntityMapper.html">NCEntityMapper</a> and - <a href="apis/latest/org/apache/nlpcraft/NCVariantFilter.html">NCVariantFilter</a>. + {% scaladoc NCTokenValidator NCTokenValidator %}, + {% scaladoc NCEntityEnricher NCEntityEnricher %}, + {% scaladoc NCEntityValidator NCEntityValidator %}, + {% scaladoc NCEntityMapper NCEntityMapper %} and + {% scaladoc NCVariantFilter NCVariantFilter %}. </li> </ul> diff --git a/built-in-token-enricher.html b/built-in-token-enricher.html index b0ea4ed..158e245 100644 --- a/built-in-token-enricher.html +++ b/built-in-token-enricher.html @@ -26,7 +26,7 @@ id: built-in-token-enricher <h2 class="section-title">Built-in Token Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> + {% scaladoc NCTokenEnricher NCTokenEnricher %} is a component which allows to add additional properties to prepared tokens, like part of speech, quote, stop-words flags or any other. NLPCraft provides English language default set of token enrichers implementations. @@ -37,7 +37,7 @@ id: built-in-token-enricher <h2 class="section-title">Lemma And POS Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher.html">NCOpenNLPLemmaPosTokenEnricher</a> - + {% scaladoc nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher NCOpenNLPLemmaPosTokenEnricher %} - this component allows to add <code>lemma</code> and <code>pos</code> values to processed token. Look at these links fpr more details: <a href="https://en.wikipedia.org/wiki/Lemma_(morphology)">Lemma</a> and @@ -54,7 +54,7 @@ id: built-in-token-enricher <h2 class="section-title">Brackets Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnBracketsTokenEnricher.html">NCEnBracketsTokenEnricher</a> - + {% scaladoc nlp/enrichers/NCEnBracketsTokenEnricher NCEnBracketsTokenEnricher %} - this component allows to add <code>brackets</code> boolean flag to processed token. </p> </section> @@ -62,7 +62,7 @@ id: built-in-token-enricher <h2 class="section-title">Quotes Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnQuotesTokenEnricher.html">NCEnQuotesTokenEnricher</a> - + {% scaladoc nlp/enrichers/NCEnQuotesTokenEnricher NCEnQuotesTokenEnricher %} - this component allows to add <code>quoted</code> boolean flag to processed token. </p> </section> @@ -70,32 +70,32 @@ id: built-in-token-enricher <h2 class="section-title">Dictionary Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnDictionaryTokenEnricher.html">NCEnDictionaryTokenEnricher</a> - + {% scaladoc nlp/enrichers/NCEnDictionaryTokenEnricher NCEnDictionaryTokenEnricher %} - this component allows to add <code>dict</code> boolean flag to processed token. Note that it requires already defined <code>lemma</code> token property. - You can use <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher.html">NCOpenNLPLemmaPosTokenEnricher</a> or any another component which sets + You can use {% scaladoc nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher NCOpenNLPLemmaPosTokenEnricher %} or any another component which sets <code>lemma</code> into the token. Note that you have to define it in model pipilene token enricher list before - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnDictionaryTokenEnricher.html">NCEnDictionaryTokenEnricher</a>. + {% scaladoc nlp/enrichers/NCEnDictionaryTokenEnricher NCEnDictionaryTokenEnricher %}. </p> </section> <section id="enricher-opennlp-stopword"> <h2 class="section-title">Stop-words Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnStopWordsTokenEnricher.html">NCEnStopWordsTokenEnricher</a> - + {% scaladoc nlp/enrichers/NCEnStopWordsTokenEnricher NCEnStopWordsTokenEnricher %} - this component allows to add <code>stopword</code> boolean flag to processed token. It is based on predefined rules for English language, but it can be also extended by custom user word list and excluded list. Note that it requires already defined <code>lemma</code> token property. - You can use <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher.html">NCOpenNLPLemmaPosTokenEnricher</a> or any another component which sets + You can use {% scaladoc nlp/enrichers/NCOpenNLPLemmaPosTokenEnricher NCOpenNLPLemmaPosTokenEnricher %} or any another component which sets <code>lemma</code> into the toke. Note that you have to define it in model pipilene token enricher list before - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnStopWordsTokenEnricher.html">NCEnStopWordsTokenEnricher</a>. + {% scaladoc nlp/enrichers/NCEnStopWordsTokenEnricher NCEnStopWordsTokenEnricher %}. </p> </section> <section id="enricher-opennlp-swearword"> <h2 class="section-title">Swear-words Enricher<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/nlp/enrichers/NCEnSwearWordsTokenEnricher.html">NCEnSwearWordsTokenEnricher</a> - + {% scaladoc nlp/enrichers/NCEnSwearWordsTokenEnricher NCEnSwearWordsTokenEnricher %} - this component allows to add <code>swear</code> boolean flag to processed token. </p> </section> diff --git a/built-in-token-parser.html b/built-in-token-parser.html index edc4ef7..83a2f10 100644 --- a/built-in-token-parser.html +++ b/built-in-token-parser.html @@ -26,7 +26,7 @@ id: built-in-token-parser <h2 class="section-title">Built-in Token Parser<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc NCTokenParser NCTokenParser %} component implementation should parse user input plain text and split this text into <code>tokens</code> list. @@ -41,7 +41,7 @@ id: built-in-token-parser <section id="parser-opennlp"> <h2 class="section-title">Apache OpenNLP Based Parser<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - There is <a href="apis/latest/org/apache/nlpcraft/nlp/parsers/NCOpenNLPTokenParser.html">NCOpenNLPTokenParser</a> implementation. + There is {% scaladoc nlp/parsers/NCOpenNLPTokenParser NCOpenNLPTokenParser %} implementation. This implementation is wrapper on <a href="https://opennlp.apache.org/">Apache OpenNLP</a> project tokenizer. diff --git a/custom-components.html b/custom-components.html index 7dec715..2f082f1 100644 --- a/custom-components.html +++ b/custom-components.html @@ -35,14 +35,14 @@ id: custom-components <section id="token-parser"> <h2 class="section-title">Token parser <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> trait. + You have to implement {% scaladoc NCTokenParser NCTokenParser %} trait. </p> <p> It's not often situation when you need to prepare your own language tokenizer. Mostly it can be necessary if you want to work with some new language. You have to prepare new implementation once and can use it for all projects on this language. Usually you just should find open source solution and wrap it for. - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> trait. + You have to implement {% scaladoc NCTokenParser NCTokenParser %} trait. </p> <pre class="brush: scala, highlight: [2, 6]"> import org.apache.nlpcraft.* @@ -74,7 +74,7 @@ id: custom-components <ul> <li> <code>NCFrTokenParser</code> is a simple wrapper which implements - <a href="apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> methods based on + {% scaladoc NCTokenParser NCTokenParser %} methods based on open source <a href="https://languagetool.org">Language Tool</a> library. </li> </ul> @@ -83,7 +83,7 @@ id: custom-components <section id="token-enricher"> <h2 class="section-title">Token enricher <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> trait. + You have to implement {% scaladoc NCTokenEnricher NCTokenEnricher %} trait. </p> <p> Tokens enricher is component which allows to add additional properties to prepared tokens. @@ -122,7 +122,7 @@ id: custom-components </pre> <ul> <li> - <code>Lines 25 and 26</code> enriches <a href="apis/latest/org/apache/nlpcraft/NCToken.html">NCToken</a> + <code>Lines 25 and 26</code> enriches {% scaladoc NCToken NCToken %} by two new properties which can be used for <a href="intent-matching.html">Intent matching</a> later. </li> </ul> @@ -131,7 +131,7 @@ id: custom-components <section id="token-validator"> <h2 class="section-title">Token validator<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCTokenValidator.html">NCTokenValidator</a> trait. + You have to implement {% scaladoc NCTokenValidator NCTokenValidator %} trait. </p> <p> @@ -147,7 +147,7 @@ id: custom-components <ul> <li> - There is anonymous instance of <a href="apis/latest/org/apache/nlpcraft/NCTokenValidator.html">NCTokenValidator</a> + There is anonymous instance of {% scaladoc NCTokenValidator NCTokenValidator %} created. </li> <li> @@ -159,7 +159,7 @@ id: custom-components <section id="entity-parser"> <h2 class="section-title">Entity parser <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCEntityParser.html">NCEntityParser</a> trait. + You have to implement {% scaladoc NCEntityParser NCEntityParser %} trait. </p> <p> @@ -196,7 +196,7 @@ id: custom-components <section id="entity-enricher"> <h2 class="section-title">Entity enricher <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCEntityEnricher.html">NCEntityEnricher</a> trait. + You have to implement {% scaladoc NCEntityEnricher NCEntityEnricher %} trait. </p> <p> Entity enricher is component which allows to add additional properties to prepared entities. @@ -234,7 +234,7 @@ id: custom-components <section id="entity-mapper"> <h2 class="section-title">Entity mapper<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCEntityMapper.html">NCEntityMapper</a> trait. + You have to implement {% scaladoc NCEntityMapper NCEntityMapper %} trait. </p> <p> @@ -282,7 +282,7 @@ id: custom-components <section id="entity-validator"> <h2 class="section-title">Entity validator<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCEntityValidator.html">NCEntityValidator</a> trait. + You have to implement {% scaladoc NCEntityValidator NCEntityValidator %} trait. </p> <p> This component is designed for entities inspection, an exception can be thrown from user code to break user input processing. @@ -297,7 +297,7 @@ id: custom-components <ul> <li> - There is anonymous instance of <a href="apis/latest/org/apache/nlpcraft/NCEntityValidator.html">NCEntityValidator</a> + There is anonymous instance of {% scaladoc NCEntityValidator NCEntityValidator %} created. </li> <li> @@ -309,7 +309,7 @@ id: custom-components <section id="variant-filter"> <h2 class="section-title">Variant filter<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> - You have to implement <a href="apis/latest/org/apache/nlpcraft/NCVariantFilter.html">NCVariantFilter</a> trait. + You have to implement {% scaladoc NCVariantFilter NCVariantFilter %} trait. </p> <p> @@ -324,7 +324,7 @@ id: custom-components <ul> <li> - There is anonymous instance of <a href="apis/latest/org/apache/nlpcraft/NCVariantFilter.html">NCVariantFilter</a> + There is anonymous instance of {% scaladoc NCVariantFilter NCVariantFilter %} created. </li> <li> diff --git a/examples/light_switch.html b/examples/light_switch.html index 6f586b6..5234431 100644 --- a/examples/light_switch.html +++ b/examples/light_switch.html @@ -82,7 +82,7 @@ fa_icon: fa-cube <h2 class="section-title">Data Model<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> We are going to start with declaring the static part of our model using YAML which we will later load using - <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> in our Scala-based model implementation. + {% scaladoc NCModelAdapter NCModelAdapter %} in our Scala-based model implementation. Open <code>src/main/resources/<b>light_switch.yaml</b></code> file and replace its content with the following YAML: </p> @@ -181,7 +181,7 @@ fa_icon: fa-cube </p> <ul> <li> - On <code>line 6</code> our class extends <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> that allows us to pass + On <code>line 6</code> our class extends {% scaladoc NCModelAdapter NCModelAdapter %} that allows us to pass prepared configuration and pipeline into model. </li> <li> diff --git a/examples/light_switch_fr.html b/examples/light_switch_fr.html index 423377d..0416e8f 100644 --- a/examples/light_switch_fr.html +++ b/examples/light_switch_fr.html @@ -69,22 +69,22 @@ fa_icon: fa-cube <li><code>LightSwitchFrModel.scala</code> - Model implementation.</li> <li> <code>NCFrSemanticEntityParser.scala</code> - Semantic entity parser, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} for French language. </li> <li> <code>NCFrLemmaPosTokenEnricher.scala</code> - Lemma and point of speech token enricher, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> + {% scaladoc NCTokenEnricher NCTokenEnricher %} for French language. </li> <li> <code>NCFrStopWordsTokenEnricher.scala</code> - Stop-words token enricher, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> + {% scaladoc NCTokenEnricher NCTokenEnricher %} for French language. </li> <li> <code>NCFrTokenParser.scala</code> - Token parser, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc NCTokenParser NCTokenParser %} for French language. </li> <li><code>LightSwitchFrModelSpec.scala</code> - Test that allows to test your model.</li> @@ -120,7 +120,7 @@ fa_icon: fa-cube <h2 class="section-title">Data Model<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> We are going to start with declaring the static part of our model using YAML which we will later load using - <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> in our Scala-based model implementation. + {% scaladoc NCModelAdapter NCModelAdapter %} in our Scala-based model implementation. Open <code>src/main/resources/<b>lightswitch_model_fr.yaml</b></code> file and replace its content with the following YAML: </p> @@ -226,7 +226,7 @@ fa_icon: fa-cube </p> <ul> <li> - On <code>line 11</code> our class extends <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> that allows us to pass + On <code>line 11</code> our class extends {% scaladoc NCModelAdapter NCModelAdapter %} that allows us to pass prepared configuration and pipeline into model. </li> <li> @@ -294,11 +294,11 @@ fa_icon: fa-cube <ul> <li> <code>NCFrTokenParser</code> is a simple wrapper which implements - <a href="../apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc NCTokenParser NCTokenParser %} based on open source <a href="https://languagetool.org">Language Tool</a> library. </li> <li> - <code>Line 19</code> creates the <a href="../apis/latest/org/apache/nlpcraft/NCToken.html">NCToken</a> instance. + <code>Line 19</code> creates the {% scaladoc NCToken NCToken %} instance. </li> </ul> @@ -501,4 +501,4 @@ fa_icon: fa-cube <li><a href="#testing">Testing</a></li> {% include quick-links.html %} </ul> -</div> \ No newline at end of file +</div> diff --git a/examples/light_switch_ru.html b/examples/light_switch_ru.html index 7e607ee..05980c3 100644 --- a/examples/light_switch_ru.html +++ b/examples/light_switch_ru.html @@ -69,22 +69,22 @@ fa_icon: fa-cube <li><code>LightSwitchRuModel.scala</code> - Model implementation.</li> <li> <code>NCRuSemanticEntityParser.scala</code> - Semantic entity parser, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} for Russian language. </li> <li> <code>NCRuLemmaPosTokenEnricher.scala</code> - Lemma and point of speech token enricher, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> + {% scaladoc NCTokenEnricher NCTokenEnricher %} for Russian language. </li> <li> <code>NCRuStopWordsTokenEnricher.scala</code> - Stop-words token enricher, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/NCTokenEnricher.html">NCTokenEnricher</a> + {% scaladoc NCTokenEnricher NCTokenEnricher %} for Russian language. </li> <li> <code>NCRuTokenParser.scala</code> - Token parser, custom implementation of - <a href="../apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc NCTokenParser NCTokenParser %} for Russian language. </li> <li><code>LightSwitchRuModelSpec.scala</code> - Test that allows to test your model.</li> @@ -120,7 +120,7 @@ fa_icon: fa-cube <h2 class="section-title">Data Model<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> We are going to start with declaring the static part of our model using YAML which we will later load using - <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> in our Scala-based model implementation. + {% scaladoc NCModelAdapter NCModelAdapter %} in our Scala-based model implementation. Open <code>src/main/resources/<b>lightswitch_model_ru.yaml</b></code> file and replace its content with the following YAML: </p> @@ -223,7 +223,7 @@ fa_icon: fa-cube </p> <ul> <li> - On <code>line 11</code> our class extends <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> that allows us to pass + On <code>line 11</code> our class extends {% scaladoc NCModelAdapter NCModelAdapter %} that allows us to pass prepared configuration and pipeline into model. </li> <li> @@ -295,11 +295,11 @@ fa_icon: fa-cube <ul> <li> <code>NCRuTokenParser</code> is a simple wrapper which implements - <a href="../apis/latest/org/apache/nlpcraft/NCTokenParser.html">NCTokenParser</a> + {% scaladoc NCTokenParser NCTokenParser %} based on open source <a href="https://languagetool.org">Language Tool</a> library. </li> <li> - <code>Line 19</code> creates the <a href="../apis/latest/org/apache/nlpcraft/NCToken.html">NCToken</a> instance. + <code>Line 19</code> creates the {% scaladoc NCToken NCToken %} instance. </li> </ul> diff --git a/examples/pizzeria.html b/examples/pizzeria.html index 9c9f4f7..7dfc401 100644 --- a/examples/pizzeria.html +++ b/examples/pizzeria.html @@ -61,8 +61,8 @@ fa_icon: fa-cube <li><code>PizzeriaModel.scala</code> - Model implementation.</li> <li><code>PizzeriaOrder.scala</code> - Pizza order state representation.</li> <li><code>PizzeriaModelPipeline.scala</code> - Model pipeline definition class.</li> - <li><code>PizzeriaOrderMapper.scala</code> - <a href="../apis/latest/org/apache/nlpcraft/NCEntityMapper.html">NCEntityMapper</a> custom implementation.</li> - <li><code>PizzeriaOrderValidator.scala</code> - <a href="../apis/latest/org/apache/nlpcraft/NCEntityValidator.html">NCEntityValidator</a> custom implementation.</li> + <li><code>PizzeriaOrderMapper.scala</code> - {% scaladoc NCEntityMapper NCEntityMapper %} custom implementation.</li> + <li><code>PizzeriaOrderValidator.scala</code> - {% scaladoc NCEntityValidator NCEntityValidator %} custom implementation.</li> <li><code>PizzeriaModelSpec.scala</code> - Test that allows to test your model.</li> </ul> <pre class="brush: plain, highlight: [7, 11, 12, 13, 14, 15, 19]"> @@ -91,7 +91,7 @@ fa_icon: fa-cube <h2 class="section-title">Data Model<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> We are going to start with declaring the static part of our model using YAML which we will later load using - <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> custom implementation in our Scala-based model implementation. + {% scaladoc NCModelAdapter NCModelAdapter %} custom implementation in our Scala-based model implementation. Open <code>src/main/resources/<b>pizzeria_model.yaml</b></code> file and replace its content with the following YAML: </p> @@ -487,14 +487,14 @@ fa_icon: fa-cube <ul> <li> <code>Line 12</code> declares <code>PizzeriaExtractors</code> helper object which provides - conversion methods from <a href="../apis/latest/org/apache/nlpcraft/NCEntity.html">NCEntity</a> objects and model data objects. + conversion methods from {% scaladoc NCEntity NCEntity %} objects and model data objects. </li> <li> <code>Line 27</code> defines <code>PizzeriaModel</code> companion object which contains static content and helper methods. </li> <li> - On <code>line 114</code> our class <code>PizzeriaModel</code> extends <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> that allows us to pass + On <code>line 114</code> our class <code>PizzeriaModel</code> extends {% scaladoc NCModelAdapter NCModelAdapter %} that allows us to pass prepared configuration and pipeline into the model. </li> <li> @@ -510,7 +510,7 @@ fa_icon: fa-cube In its callback current order state is changed. If processed order is in valid state user receives order confirmation request like "<i>Is order ready?</i>", otherwise user receives request which asks him to specify the order. - Both responses have <a href="../apis/latest/org/apache/nlpcraft/NCResultType.html#ASK_DIALOG-0">ASK_DIALOG</a> type. + Both responses have {% scaladoc NCResultType#ASK_DIALOG-0 ASK_DIALOG %} type. </li> <li> @@ -563,7 +563,7 @@ fa_icon: fa-cube </pre> <p> - <code>PizzeriaOrderValidator</code> is implementation of <a href="../apis/latest/org/apache/nlpcraft/NCEntityValidator.html">NCEntityValidator</a>. + <code>PizzeriaOrderValidator</code> is implementation of {% scaladoc NCEntityValidator NCEntityValidator %}. It is designed for validation order content that allows to reject invalid orders right away. <p> @@ -636,7 +636,7 @@ fa_icon: fa-cube </pre> <p> - <code>PizzeriaOrderMapper</code> is implementation of <a href="../apis/latest/org/apache/nlpcraft/NCEntityMapper.html">NCEntityMapper</a>. + <code>PizzeriaOrderMapper</code> is implementation of {% scaladoc NCEntityMapper NCEntityMapper %}. It is designed for complex compound entities building based on another entities. <p> <ul> @@ -645,7 +645,7 @@ fa_icon: fa-cube helper methods. </li> <li> - <code>Line 25</code> defines <code>PizzeriaOrderMapper</code> model which implements <a href="../apis/latest/org/apache/nlpcraft/NCEntityMapper.html">NCEntityMapper</a>. + <code>Line 25</code> defines <code>PizzeriaOrderMapper</code> model which implements {% scaladoc NCEntityMapper NCEntityMapper %}. </li> <li> <code>Line 30</code> defines helper method @@ -717,7 +717,7 @@ fa_icon: fa-cube <code>Line 14</code> defines the pipeline. </li> <li> - <code>Line 30</code> declares <a href="../apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + <code>Line 30</code> declares {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} which is based on YAM model definition <code>pizzeria_model.yaml</code>. </li> <li> diff --git a/examples/time.html b/examples/time.html index 4ccdcd1..b5aa6e5 100644 --- a/examples/time.html +++ b/examples/time.html @@ -86,7 +86,7 @@ fa_icon: fa-cube <h2 class="section-title">Data Model<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> We are going to start with declaring the static part of our model using YAML which we will later load using - <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> in our Scala-based model implementation. + {% scaladoc NCModelAdapter NCModelAdapter %} in our Scala-based model implementation. Open <code>src/main/resources/<b>time_model.yaml</b></code> file and replace its content with the following YAML: </p> @@ -208,7 +208,7 @@ fa_icon: fa-cube </p> <ul> <li> - On <code>line 17</code> our class extends <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> that allows us to pass + On <code>line 17</code> our class extends {% scaladoc NCModelAdapter NCModelAdapter %} that allows us to pass prepared configuration and pipeline into model. </li> <li> @@ -225,9 +225,9 @@ fa_icon: fa-cube <code>Line 19</code> creates pipeline based on built-in components: <ul> <li>Built-in English language - <a href="../apis/latest/org/apache/nlpcraft/nlp/parsers/NCSemanticEntityParser.html">NCSemanticEntityParser</a> + {% scaladoc nlp/parsers/NCSemanticEntityParser NCSemanticEntityParser %} configured with <code>time_model.yaml</code>.</li> - <li>Entity parser <a href="../apis/latest/org/apache/nlpcraft/nlp/parsers/NCOpenNLPTokenParser.html">NCOpenNLPTokenParser</a> + <li>Entity parser {% scaladoc nlp/parsers/NCOpenNLPTokenParser NCOpenNLPTokenParser %} configured by <code>opennlp/en-ner-location.bin</code> for GEO locations detection. </li> </ul> diff --git a/first-example.html b/first-example.html index 2f2fd84..883a62e 100644 --- a/first-example.html +++ b/first-example.html @@ -78,7 +78,7 @@ id: first-example <h2 class="section-title">Data Model<a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2> <p> We are going to start with declaring the static part of our model using YAML which we will later load using - <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> in our Scala-based model implementation. + {% scaladoc NCModelAdapter NCModelAdapter %} in our Scala-based model implementation. Open <code>src/main/resources/<b>light_switch.yaml</b></code> file and replace its content with the following YAML: </p> @@ -177,7 +177,7 @@ id: first-example </p> <ul> <li> - On <code>line 6</code> our class extends <a href="../apis/latest/org/apache/nlpcraft/NCModelAdapter.html">NCModelAdapter</a> that allows us to pass + On <code>line 6</code> our class extends {% scaladoc NCModelAdapter NCModelAdapter %} that allows us to pass prepared configuration and pipeline into model. </li> <li> diff --git a/short-term-memory.html b/short-term-memory.html index e349c31..5c35a30 100644 --- a/short-term-memory.html +++ b/short-term-memory.html @@ -112,7 +112,7 @@ id: short_term_memory period of time, i.e. it “forgets” the conversational context after few minutes of inactivity. Note also that conversational context can also be cleared explicitly via <a href="https://app.swaggerhub.com/apis-docs/Apache-NLPCraft/apache-nlpcraft/{{site.latest_version}}" target="swaggerhub">REST API</a> - or from the <a class="not-code" target="javadoc" href="/apis/latest/org/apache/nlpcraft/NCConversation.html">code</a>. + or from the {% scaladoc NCConversation code %}. </p> <p> To understand the algorithm behind the STM management let's back up a few steps... @@ -264,11 +264,11 @@ id: short_term_memory can have a "soft" context switch where you don't change the topic of the conversation 100% but yet sufficiently enough to forget at least some parts of the previously collected context. NLPCraft has a built-in algorithm to detect the hard switch in the conversation. It also exposes - <a class="not-code" target="javadoc" href="/apis/latest/org/apache/nlpcraft/NCConversation.html">API</a> to perform a selective reset on the + {% scaladoc NCConversation API %} to perform a selective reset on the conversation in case of "soft" switch. </p> <p> - See <a class="javadoc" href="/apis/latest/org/apache/nlpcraft/NCConversation.html">NCConversion</a> interface + See {% scaladoc NCConversation NCConversion %} interface for API details for STM management. </p> </section> @@ -452,7 +452,7 @@ id: short_term_memory </p> <p> In NLPCraft you can also explicitly reset conversation context through - <a class="not-code" target="javadoc" href="/apis/latest/org/apache/nlpcraft/NCConversation.html">API</a> + {% scaladoc NCConversation API %} or by switching the model on the request. </p> </section>
