blob: 5a2cfc2bcc7a8398327954cb95f81cf9ab4258d9 [file] [log] [blame]
<!DOCTYPE HTML>
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (11.0.2) on Fri May 07 16:35:12 PDT 2021 -->
<title>NCModelFileAdapter (Apache NLPCraft 0.7.5)</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="dc.created" content="2021-05-07">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../jquery/jquery-ui.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
<script type="text/javascript" src="../../../../jquery/jszip/dist/jszip.min.js"></script>
<script type="text/javascript" src="../../../../jquery/jszip-utils/dist/jszip-utils.min.js"></script>
<!--[if IE]>
<script type="text/javascript" src="../../../../jquery/jszip-utils/dist/jszip-utils-ie.min.js"></script>
<![endif]-->
<script type="text/javascript" src="../../../../jquery/jquery-3.3.1.js"></script>
<script type="text/javascript" src="../../../../jquery/jquery-migrate-3.0.1.js"></script>
<script type="text/javascript" src="../../../../jquery/jquery-ui.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="NCModelFileAdapter (Apache NLPCraft 0.7.5)";
}
}
catch(err) {
}
//-->
var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10,"i27":10,"i28":10,"i29":10,"i30":10,"i31":10,"i32":10,"i33":10,"i34":10,"i35":10,"i36":10};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
var pathtoroot = "../../../../";
var useModuleDirectories = true;
loadScripts(document, 'script');</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<header role="banner">
<nav role="navigation">
<div class="fixedNav"><link href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet"> <script src="https://nlpcraft.apache.org/javadoc/resources/sh/scripts/XRegExp.js" type="text/javascript"></script> <script src="https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shCore.js" type="text/javascript"></script> <script src="https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shAutoloader.js" type="text/javascript"></script> <link href="https://nlpcraft.apache.org/javadoc/resources/sh/styles/shCoreNLPCraft.css" rel="stylesheet" type="text/css" title="Style"> <link href="https://nlpcraft.apache.org/javadoc/resources/sh/styles/shThemeNLPCraft.css" rel="stylesheet" type="text/css" title="Style"> <link href="https://fonts.googleapis.com/css?family=Roboto+Mono" rel="stylesheet"> <link href="https://fonts.googleapis.com/css?family=Roboto" rel="stylesheet"> <script async defer src="https://buttons.github.io/buttons.js"></script>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a id="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a id="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/NCModelFileAdapter.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
<div class="aboutLanguage">Apache NLPCraft <span style="font-size: 80%">0.7.5</span></div>
</div>
<div class="subNav">
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses.html">All&nbsp;Classes</a></li>
</ul>
<ul class="navListSearch">
<li><label for="search">SEARCH:</label>
<input type="text" id="search" value="search" disabled="disabled">
<input type="reset" id="reset" value="reset" disabled="disabled">
</li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a id="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
</div>
<div class="navPadding">&nbsp;</div>
<script type="text/javascript"><!--
$('.navPadding').css('padding-top', $('.fixedNav').css("height"));
//-->
</script>
</nav>
</header>
<!-- ======== START OF CLASS DATA ======== -->
<main role="main">
<div class="header">
<div class="subTitle"><span class="packageLabelInType">Package</span>&nbsp;<a href="package-summary.html">org.apache.nlpcraft.model</a></div>
<h2 title="Class NCModelFileAdapter" class="title">Class NCModelFileAdapter</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li><a href="NCModelAdapter.html" title="class in org.apache.nlpcraft.model">org.apache.nlpcraft.model.NCModelAdapter</a></li>
<li>
<ul class="inheritance">
<li>org.apache.nlpcraft.model.NCModelFileAdapter</li>
</ul>
</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><code><a href="NCLifecycle.html" title="interface in org.apache.nlpcraft.model">NCLifecycle</a></code>, <code><a href="NCMetadata.html" title="interface in org.apache.nlpcraft.model">NCMetadata</a></code>, <code><a href="NCModel.html" title="interface in org.apache.nlpcraft.model">NCModel</a></code>, <code><a href="NCModelView.html" title="interface in org.apache.nlpcraft.model">NCModelView</a></code></dd>
</dl>
<hr>
<pre>public abstract class <span class="typeNameLabel">NCModelFileAdapter</span>
extends <a href="NCModelAdapter.html" title="class in org.apache.nlpcraft.model">NCModelAdapter</a></pre>
<div class="block">Adapter for data models that can load model configuration from external JSON/YAML file.
<p>
One of the use cases this adapter supports is ability to load model configuration from the external
JSON/YAML file and then update it in the code. For example, a model can load its configuration
from JSON file and then add intents or synonyms loaded from a database to a certain model element.
To support this usage all getters return internal mutable sets or maps, i.e. you can modify them in your sub-class
constructors and those modifications will alter the model's configuration. The following getters return
mutable collections that can be modified by the caller:
<ul>
<li><a href="#getSuspiciousWords()"><code>getSuspiciousWords()</code></a></li>
<li><a href="#getAdditionalStopWords()"><code>getAdditionalStopWords()</code></a></li>
<li><a href="#getIntents()"><code>getIntents()</code></a></li>
<li><a href="#getElements()"><code>getElements()</code></a></li>
<li><a href="#getEnabledBuiltInTokens()"><code>getEnabledBuiltInTokens()</code></a></li>
<li><a href="#getExcludedStopWords()"><code>getExcludedStopWords()</code></a></li>
<li><a href="#getParsers()"><code>getParsers()</code></a></li>
<li><a href="#getMacros()"><code>getMacros()</code></a></li>
<li><a href="#getMetadata()"><code>getMetadata()</code></a></li>
</ul>
<p>
Read full documentation in <a target=_ href="https://nlpcraft.apache.org/data-model.html">Data Model</a> section and review
<a target=_ href="https://github.com/apache/incubator-nlpcraft/tree/master/nlpcraft/src/main/scala/org/apache/nlpcraft/examples/">examples</a>.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelAdapter.html" title="class in org.apache.nlpcraft.model"><code>NCModelAdapter</code></a></dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="field.summary">
<!-- -->
</a>
<h3>Field Summary</h3>
<ul class="blockList">
<li class="blockList"><a id="fields.inherited.from.class.org.apache.nlpcraft.model.NCModelView">
<!-- -->
</a>
<h3>Fields inherited from interface&nbsp;org.apache.nlpcraft.model.<a href="NCModelView.html" title="interface in org.apache.nlpcraft.model">NCModelView</a></h3>
<code><a href="NCModelView.html#CONV_DEPTH_MAX">CONV_DEPTH_MAX</a>, <a href="NCModelView.html#CONV_DEPTH_MIN">CONV_DEPTH_MIN</a>, <a href="NCModelView.html#CONV_TIMEOUT_MAX">CONV_TIMEOUT_MAX</a>, <a href="NCModelView.html#CONV_TIMEOUT_MIN">CONV_TIMEOUT_MIN</a>, <a href="NCModelView.html#DFLT_CONV_DEPTH">DFLT_CONV_DEPTH</a>, <a href="NCModelView.html#DFLT_CONV_TIMEOUT_MS">DFLT_CONV_TIMEOUT_MS</a>, <a href="NCModelView.html#DFLT_ENABLED_BUILTIN_TOKENS">DFLT_ENABLED_BUILTIN_TOKENS</a>, <a href="NCModelView.html#DFLT_IS_DUP_SYNONYMS_ALLOWED">DFLT_IS_DUP_SYNONYMS_ALLOWED</a>, <a href="NCModelView.html#DFLT_IS_NO_NOUNS_ALLOWED">DFLT_IS_NO_NOUNS_ALLOWED</a>, <a href="NCModelView.html#DFLT_IS_NO_USER_TOKENS_ALLOWED">DFLT_IS_NO_USER_TOKENS_ALLOWED</a>, <a href="NCModelView.html#DFLT_IS_NON_ENGLISH_ALLOWED">DFLT_IS_NON_ENGLISH_ALLOWED</a>, <a href="NCModelView.html#DFLT_IS_NOT_LATIN_CHARSET_ALLOWED">DFLT_IS_NOT_LATIN_CHARSET_ALLOWED</a>, <a href="NCModelView.html#DFLT_IS_PERMUTATE_SYNONYMS">DFLT_IS_PERMUTATE_SYNONYMS</a>, <a href="NCModelView.html#DFLT_IS_SPARSE">DFLT_IS_SPARSE</a>, <a href="NCModelView.html#DFLT_IS_SWEAR_WORDS_ALLOWED">DFLT_IS_SWEAR_WORDS_ALLOWED</a>, <a href="NCModelView.html#DFLT_MAX_ELEMENT_SYNONYMS">DFLT_MAX_ELEMENT_SYNONYMS</a>, <a href="NCModelView.html#DFLT_MAX_FREE_WORDS">DFLT_MAX_FREE_WORDS</a>, <a href="NCModelView.html#DFLT_MAX_SUSPICIOUS_WORDS">DFLT_MAX_SUSPICIOUS_WORDS</a>, <a href="NCModelView.html#DFLT_MAX_SYNONYMS_THRESHOLD_ERROR">DFLT_MAX_SYNONYMS_THRESHOLD_ERROR</a>, <a href="NCModelView.html#DFLT_MAX_TOKENS">DFLT_MAX_TOKENS</a>, <a href="NCModelView.html#DFLT_MAX_TOTAL_SYNONYMS">DFLT_MAX_TOTAL_SYNONYMS</a>, <a href="NCModelView.html#DFLT_MAX_UNKNOWN_WORDS">DFLT_MAX_UNKNOWN_WORDS</a>, <a href="NCModelView.html#DFLT_MAX_WORDS">DFLT_MAX_WORDS</a>, <a href="NCModelView.html#DFLT_METADATA">DFLT_METADATA</a>, <a href="NCModelView.html#DFLT_MIN_NON_STOPWORDS">DFLT_MIN_NON_STOPWORDS</a>, <a href="NCModelView.html#DFLT_MIN_TOKENS">DFLT_MIN_TOKENS</a>, <a href="NCModelView.html#DFLT_MIN_WORDS">DFLT_MIN_WORDS</a>, <a href="NCModelView.html#MAX_FREE_WORDS_MAX">MAX_FREE_WORDS_MAX</a>, <a href="NCModelView.html#MAX_FREE_WORDS_MIN">MAX_FREE_WORDS_MIN</a>, <a href="NCModelView.html#MAX_SUSPICIOUS_WORDS_MAX">MAX_SUSPICIOUS_WORDS_MAX</a>, <a href="NCModelView.html#MAX_SUSPICIOUS_WORDS_MIN">MAX_SUSPICIOUS_WORDS_MIN</a>, <a href="NCModelView.html#MAX_SYN_MAX">MAX_SYN_MAX</a>, <a href="NCModelView.html#MAX_SYN_MIN">MAX_SYN_MIN</a>, <a href="NCModelView.html#MAX_TOKENS_MAX">MAX_TOKENS_MAX</a>, <a href="NCModelView.html#MAX_TOKENS_MIN">MAX_TOKENS_MIN</a>, <a href="NCModelView.html#MAX_UNKNOWN_WORDS_MAX">MAX_UNKNOWN_WORDS_MAX</a>, <a href="NCModelView.html#MAX_UNKNOWN_WORDS_MIN">MAX_UNKNOWN_WORDS_MIN</a>, <a href="NCModelView.html#MAX_WORDS_MAX">MAX_WORDS_MAX</a>, <a href="NCModelView.html#MAX_WORDS_MIN">MAX_WORDS_MIN</a>, <a href="NCModelView.html#MIN_NON_STOPWORDS_MAX">MIN_NON_STOPWORDS_MAX</a>, <a href="NCModelView.html#MIN_NON_STOPWORDS_MIN">MIN_NON_STOPWORDS_MIN</a>, <a href="NCModelView.html#MIN_TOKENS_MAX">MIN_TOKENS_MAX</a>, <a href="NCModelView.html#MIN_TOKENS_MIN">MIN_TOKENS_MIN</a>, <a href="NCModelView.html#MIN_WORDS_MAX">MIN_WORDS_MAX</a>, <a href="NCModelView.html#MIN_WORDS_MIN">MIN_WORDS_MIN</a>, <a href="NCModelView.html#MODEL_ID_MAXLEN">MODEL_ID_MAXLEN</a>, <a href="NCModelView.html#MODEL_NAME_MAXLEN">MODEL_NAME_MAXLEN</a>, <a href="NCModelView.html#MODEL_VERSION_MAXLEN">MODEL_VERSION_MAXLEN</a></code></li>
</ul>
</li>
</ul>
</section>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Constructor</th>
<th class="colLast" scope="col">Description</th>
</tr>
<tr class="altColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.lang.String)">NCModelFileAdapter</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;filePath)</code></th>
<td class="colLast">
<div class="block">Creates new model loading its configuration from given file path.</div>
</td>
</tr>
<tr class="rowColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.net.URI)">NCModelFileAdapter</a></span>&#8203;(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/net/URI.html?is-external=true" title="class or interface in java.net" class="externalLink">URI</a>&nbsp;uri)</code></th>
<td class="colLast">
<div class="block">Creates new model loading its configuration from given URI.</div>
</td>
</tr>
</table>
</li>
</ul>
</section>
<!-- ========== METHOD SUMMARY =========== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colSecond" scope="col">Method</th>
<th class="colLast" scope="col">Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getAbstractTokens()">getAbstractTokens</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets s set of named entities (token) IDs that will be considered as abstract tokens.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getAdditionalStopWords()">getAdditionalStopWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets an optional list of stopwords to add to the built-in ones.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getConversationDepth()">getConversationDepth</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum number of requests after which the unused conversation element is automatically "forgotten".</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>long</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getConversationTimeout()">getConversationTimeout</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets timeout in ms after which the unused conversation element is automatically "forgotten".</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getDescription()">getDescription</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets optional short model description.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="NCElement.html" title="interface in org.apache.nlpcraft.model">NCElement</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getElements()">getElements</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets a set of model elements or named entities.</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getEnabledBuiltInTokens()">getEnabledBuiltInTokens</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets a set of IDs for built-in named entities (tokens) that should be enabled and detected for this model.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getExcludedStopWords()">getExcludedStopWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets an optional list of stopwords to exclude from the built-in list of stopwords.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getId()">getId</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets unique, <i>immutable</i> ID of this model.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/List.html?is-external=true" title="class or interface in java.util" class="externalLink">List</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getIntents()">getIntents</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets list of intents and/or fragments declared in JSON/YML model definition, if any.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMacros()">getMacros</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets an optional map of macros to be used in this model.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxElementSynonyms()">getMaxElementSynonyms</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum number of unique synonyms per model element after which either warning or error will be
triggered.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxFreeWords()">getMaxFreeWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum number of free words until automatic rejection.</div>
</td>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxSuspiciousWords()">getMaxSuspiciousWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum number of suspicious words until automatic rejection.</div>
</td>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxTokens()">getMaxTokens</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum number of all tokens (system and user defined) above which user input will be
automatically rejected as too long.</div>
</td>
</tr>
<tr id="i15" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxTotalSynonyms()">getMaxTotalSynonyms</a></span>()</code></th>
<td class="colLast">
<div class="block">Total number of synonyms allowed per model.</div>
</td>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxUnknownWords()">getMaxUnknownWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum number of unknown words until automatic rejection.</div>
</td>
</tr>
<tr id="i17" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxWords()">getMaxWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets maximum word count (<i>including</i> stopwords) above which user input will be automatically
rejected as too long.</div>
</td>
</tr>
<tr id="i18" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMetadata()">getMetadata</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets optional user defined model metadata that can be set by the developer and accessed later.</div>
</td>
</tr>
<tr id="i19" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMinNonStopwords()">getMinNonStopwords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets minimum word count (<i>excluding</i> stopwords) below which user input will be automatically rejected
as ambiguous sentence.</div>
</td>
</tr>
<tr id="i20" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMinTokens()">getMinTokens</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets minimum number of all tokens (system and user defined) below which user input will be
automatically rejected as too short.</div>
</td>
</tr>
<tr id="i21" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMinWords()">getMinWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets minimum word count (<i>including</i> stopwords) below which user input will be automatically
rejected as too short.</div>
</td>
</tr>
<tr id="i22" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getName()">getName</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets descriptive name of this model.</div>
</td>
</tr>
<tr id="i23" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getOrigin()">getOrigin</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets the origin of this model like name of the class, file path or URL.</div>
</td>
</tr>
<tr id="i24" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/List.html?is-external=true" title="class or interface in java.util" class="externalLink">List</a>&lt;<a href="NCCustomParser.html" title="interface in org.apache.nlpcraft.model">NCCustomParser</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getParsers()">getParsers</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets optional user-defined model element parsers for custom NER implementations.</div>
</td>
</tr>
<tr id="i25" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getRestrictedCombinations()">getRestrictedCombinations</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets an optional map of restricted named entity combinations (linkage).</div>
</td>
</tr>
<tr id="i26" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getSuspiciousWords()">getSuspiciousWords</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets an optional list of suspicious words.</div>
</td>
</tr>
<tr id="i27" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a></code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getVersion()">getVersion</a></span>()</code></th>
<td class="colLast">
<div class="block">Gets the version of this model using semantic versioning.</div>
</td>
</tr>
<tr id="i28" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isDupSynonymsAllowed()">isDupSynonymsAllowed</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not duplicate synonyms are allowed.</div>
</td>
</tr>
<tr id="i29" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isMaxSynonymsThresholdError()">isMaxSynonymsThresholdError</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not exceeding <a href="NCModelView.html#getMaxElementSynonyms()"><code>NCModelView.getMaxElementSynonyms()</code></a> will trigger a warning log or throwing an exception.</div>
</td>
</tr>
<tr id="i30" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isNonEnglishAllowed()">isNonEnglishAllowed</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not to allow non-English language in user input.</div>
</td>
</tr>
<tr id="i31" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isNoNounsAllowed()">isNoNounsAllowed</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not to allow user input without a single noun.</div>
</td>
</tr>
<tr id="i32" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isNotLatinCharsetAllowed()">isNotLatinCharsetAllowed</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not to allow non-Latin charset in user input.</div>
</td>
</tr>
<tr id="i33" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isNoUserTokensAllowed()">isNoUserTokensAllowed</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not to allow the user input with no user token detected.</div>
</td>
</tr>
<tr id="i34" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isPermutateSynonyms()">isPermutateSynonyms</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not to permutate multi-word synonyms.</div>
</td>
</tr>
<tr id="i35" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isSparse()">isSparse</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not this model elements allows non-stopword words, the gaps, in their multi-word synonyms.</div>
</td>
</tr>
<tr id="i36" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isSwearWordsAllowed()">isSwearWordsAllowed</a></span>()</code></th>
<td class="colLast">
<div class="block">Whether or not to allow known English swear words in user input.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></h3>
<code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang" class="externalLink">equals</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang" class="externalLink">getClass</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang" class="externalLink">hashCode</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang" class="externalLink">notify</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang" class="externalLink">notifyAll</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang" class="externalLink">toString</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true#wait(long,int)" title="class or interface in java.lang" class="externalLink">wait</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.org.apache.nlpcraft.model.NCLifecycle">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;org.apache.nlpcraft.model.<a href="NCLifecycle.html" title="interface in org.apache.nlpcraft.model">NCLifecycle</a></h3>
<code><a href="NCLifecycle.html#onDiscard()">onDiscard</a>, <a href="NCLifecycle.html#onInit()">onInit</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.org.apache.nlpcraft.model.NCMetadata">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;org.apache.nlpcraft.model.<a href="NCMetadata.html" title="interface in org.apache.nlpcraft.model">NCMetadata</a></h3>
<code><a href="NCMetadata.html#meta(java.lang.String)">meta</a>, <a href="NCMetadata.html#meta(java.lang.String,T)">meta</a>, <a href="NCMetadata.html#metaOpt(java.lang.String)">metaOpt</a>, <a href="NCMetadata.html#metax(java.lang.String)">metax</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.org.apache.nlpcraft.model.NCModel">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;org.apache.nlpcraft.model.<a href="NCModel.html" title="interface in org.apache.nlpcraft.model">NCModel</a></h3>
<code><a href="NCModel.html#onContext(org.apache.nlpcraft.model.NCContext)">onContext</a>, <a href="NCModel.html#onError(org.apache.nlpcraft.model.NCContext,java.lang.Throwable)">onError</a>, <a href="NCModel.html#onMatchedIntent(org.apache.nlpcraft.model.NCIntentMatch)">onMatchedIntent</a>, <a href="NCModel.html#onParsedVariant(org.apache.nlpcraft.model.NCVariant)">onParsedVariant</a>, <a href="NCModel.html#onRejection(org.apache.nlpcraft.model.NCIntentMatch,org.apache.nlpcraft.model.NCRejection)">onRejection</a>, <a href="NCModel.html#onResult(org.apache.nlpcraft.model.NCIntentMatch,org.apache.nlpcraft.model.NCResult)">onResult</a></code></li>
</ul>
</li>
</ul>
</section>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a id="&lt;init&gt;(java.lang.String)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>NCModelFileAdapter</h4>
<pre>public&nbsp;NCModelFileAdapter&#8203;(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;filePath)</pre>
<div class="block">Creates new model loading its configuration from given file path. Only <code>.js</code>,
<code>.json</code>, <code>.yml</code> and <code>.yaml</code> files are supported. File path can be
classpath relative or absolute.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>filePath</code> - Classpath relative or absolute file path to load model configuration from.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>org.apache.nlpcraft.common.NCException</code> - Thrown in case of any errors loading model configuration.</dd>
</dl>
</li>
</ul>
<a id="&lt;init&gt;(java.net.URI)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>NCModelFileAdapter</h4>
<pre>public&nbsp;NCModelFileAdapter&#8203;(<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/net/URI.html?is-external=true" title="class or interface in java.net" class="externalLink">URI</a>&nbsp;uri)</pre>
<div class="block">Creates new model loading its configuration from given URI. Only <code>.js</code>,
<code>.json</code>, <code>.yml</code> and <code>.yaml</code> resources are supported.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>uri</code> - URI to load model configuration from.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>org.apache.nlpcraft.common.NCException</code> - Thrown in case of any errors loading model configuration.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</section>
<!-- ============ METHOD DETAIL ========== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a id="getOrigin()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getOrigin</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getOrigin()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getOrigin()">NCModelView</a></code></span></div>
<div class="block">Gets the origin of this model like name of the class, file path or URL.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Origin of this model like name of the class, file path or URL.</dd>
</dl>
</li>
</ul>
<a id="getIntents()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getIntents</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/List.html?is-external=true" title="class or interface in java.util" class="externalLink">List</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getIntents()</pre>
<div class="block">Gets list of intents and/or fragments declared in JSON/YML model definition, if any.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>List of intents and/or fragments declared in JSON/YML model definition, potentially empty.</dd>
</dl>
</li>
</ul>
<a id="getId()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getId</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getId()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getId()">NCModelView</a></code></span></div>
<div class="block">Gets unique, <i>immutable</i> ID of this model.
<p>
Note that <b>model IDs are immutable</b> while name and version
can be changed freely. Changing model ID is equal to creating a completely new model.
Model IDs (unlike name and version) are not exposed to the end user and only serve a
technical purpose. ID's max length is 32 characters.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>id</code> property:
<pre class="brush: js">
{
"id": "my.model.id"
}
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="NCModelView.html#getId()">getId</a></code>&nbsp;in interface&nbsp;<code><a href="NCModelView.html" title="interface in org.apache.nlpcraft.model">NCModelView</a></code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="NCModelAdapter.html#getId()">getId</a></code>&nbsp;in class&nbsp;<code><a href="NCModelAdapter.html" title="class in org.apache.nlpcraft.model">NCModelAdapter</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Unique, <i>immutable</i> ID of this model.</dd>
</dl>
</li>
</ul>
<a id="getName()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getName</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getName()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getName()">NCModelView</a></code></span></div>
<div class="block">Gets descriptive name of this model. Name's max length is 64 characters.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>name</code> property:
<pre class="brush: js">
{
"name": "My Model"
}
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="NCModelView.html#getName()">getName</a></code>&nbsp;in interface&nbsp;<code><a href="NCModelView.html" title="interface in org.apache.nlpcraft.model">NCModelView</a></code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="NCModelAdapter.html#getName()">getName</a></code>&nbsp;in class&nbsp;<code><a href="NCModelAdapter.html" title="class in org.apache.nlpcraft.model">NCModelAdapter</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Descriptive name for this model.</dd>
</dl>
</li>
</ul>
<a id="getVersion()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getVersion</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getVersion()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getVersion()">NCModelView</a></code></span></div>
<div class="block">Gets the version of this model using semantic versioning. Version's max length is 16 characters.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>version</code> property:
<pre class="brush: js">
{
"version": "1.0.0"
}
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="NCModelView.html#getVersion()">getVersion</a></code>&nbsp;in interface&nbsp;<code><a href="NCModelView.html" title="interface in org.apache.nlpcraft.model">NCModelView</a></code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="NCModelAdapter.html#getVersion()">getVersion</a></code>&nbsp;in class&nbsp;<code><a href="NCModelAdapter.html" title="class in org.apache.nlpcraft.model">NCModelAdapter</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>A version compatible with (<a href="http://www.semver.org">www.semver.org</a>) specification.</dd>
</dl>
</li>
</ul>
<a id="getDescription()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDescription</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&nbsp;getDescription()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getDescription()">NCModelView</a></code></span></div>
<div class="block">Gets optional short model description. This can be displayed by the management tools.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>description</code> property:
<pre class="brush: js">
{
"description": "Model description..."
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Optional short model description.</dd>
</dl>
</li>
</ul>
<a id="getMaxUnknownWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxUnknownWords</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxUnknownWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxUnknownWords()">NCModelView</a></code></span></div>
<div class="block">Gets maximum number of unknown words until automatic rejection. An unknown word is a word
that is not part of Princeton WordNet database. If you expect a very formalized and well
defined input without uncommon slang and abbreviations you can set this to a small number
like one or two. However, in most cases we recommend to leave it as default or set it to a larger
number like five or more.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_UNKNOWN_WORDS"><code>NCModelView.DFLT_MAX_UNKNOWN_WORDS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxUnknownWords</code> property:
<pre class="brush: js">
{
"maxUnknownWords": 2
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum number of unknown words until automatic rejection.</dd>
</dl>
</li>
</ul>
<a id="getMaxFreeWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxFreeWords</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxFreeWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxFreeWords()">NCModelView</a></code></span></div>
<div class="block">Gets maximum number of free words until automatic rejection. A free word is a known word that is
not part of any recognized token. In other words, a word that is present in the user input
but won't be used to understand its meaning. Setting it to a non-zero risks the misunderstanding
of the user input, while setting it to zero often makes understanding logic too rigid. In most
cases we recommend setting to between one and three. If you expect the user input to contain
many <i>noisy</i> idioms, slang or colloquials - you can set it to a larger number.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_FREE_WORDS"><code>NCModelView.DFLT_MAX_FREE_WORDS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxFreeWords</code> property:
<pre class="brush: js">
{
"maxFreeWords": 2
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum number of free words until automatic rejection.</dd>
</dl>
</li>
</ul>
<a id="getMaxSuspiciousWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxSuspiciousWords</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxSuspiciousWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxSuspiciousWords()">NCModelView</a></code></span></div>
<div class="block">Gets maximum number of suspicious words until automatic rejection. A suspicious word is a word
that is defined by the model that should not appear in a valid user input under no circumstances.
A typical example of suspicious words would be words "sex" or "porn" when processing
queries about children books. In most cases this should be set to zero (default) to automatically
reject any such suspicious words in the user input.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_SUSPICIOUS_WORDS"><code>NCModelView.DFLT_MAX_SUSPICIOUS_WORDS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxSuspiciousWords</code> property:
<pre class="brush: js">
{
"maxSuspiciousWords": 2
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum number of suspicious words until automatic rejection.</dd>
</dl>
</li>
</ul>
<a id="getMinWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMinWords</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMinWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMinWords()">NCModelView</a></code></span></div>
<div class="block">Gets minimum word count (<i>including</i> stopwords) below which user input will be automatically
rejected as too short. In almost all cases this value should be greater than or equal to one.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MIN_WORDS"><code>NCModelView.DFLT_MIN_WORDS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>minWords</code> property:
<pre class="brush: js">
{
"minWords": 2
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Minimum word count (<i>including</i> stopwords) below which user input will be automatically
rejected as too short.</dd>
</dl>
</li>
</ul>
<a id="getMaxWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxWords</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxWords()">NCModelView</a></code></span></div>
<div class="block">Gets maximum word count (<i>including</i> stopwords) above which user input will be automatically
rejected as too long. In almost all cases this value should be greater than or equal to one.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_WORDS"><code>NCModelView.DFLT_MAX_WORDS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxWords</code> property:
<pre class="brush: js">
{
"maxWords": 50
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum word count (<i>including</i> stopwords) above which user input will be automatically
rejected as too long.</dd>
</dl>
</li>
</ul>
<a id="getMinTokens()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMinTokens</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMinTokens()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMinTokens()">NCModelView</a></code></span></div>
<div class="block">Gets minimum number of all tokens (system and user defined) below which user input will be
automatically rejected as too short. In almost all cases this value should be greater than or equal to one.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MIN_TOKENS"><code>NCModelView.DFLT_MIN_TOKENS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>minTokens</code> property:
<pre class="brush: js">
{
"minTokens": 1
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Minimum number of all tokens.</dd>
</dl>
</li>
</ul>
<a id="getMaxTokens()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxTokens</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxTokens()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxTokens()">NCModelView</a></code></span></div>
<div class="block">Gets maximum number of all tokens (system and user defined) above which user input will be
automatically rejected as too long. Note that sentences with large number of token can result
in significant processing delay and substantial memory consumption.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_TOKENS"><code>NCModelView.DFLT_MAX_TOKENS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxTokens</code> property:
<pre class="brush: js">
{
"maxTokens": 100
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum number of all tokens.</dd>
</dl>
</li>
</ul>
<a id="getMinNonStopwords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMinNonStopwords</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMinNonStopwords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMinNonStopwords()">NCModelView</a></code></span></div>
<div class="block">Gets minimum word count (<i>excluding</i> stopwords) below which user input will be automatically rejected
as ambiguous sentence.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MIN_NON_STOPWORDS"><code>NCModelView.DFLT_MIN_NON_STOPWORDS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>minNonStopwords</code> property:
<pre class="brush: js">
{
"minNonStopwords": 2
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Minimum word count (<i>excluding</i> stopwords) below which user input will be automatically
rejected as too short.</dd>
</dl>
</li>
</ul>
<a id="isNonEnglishAllowed()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isNonEnglishAllowed</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isNonEnglishAllowed()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isNonEnglishAllowed()">NCModelView</a></code></span></div>
<div class="block">Whether or not to allow non-English language in user input.
Currently, only English language is supported. However, model can choose whether or not
to automatically reject user input that is detected to be a non-English. Note that current
algorithm only works reliably on longer user input (10+ words). On short sentences it will
often produce an incorrect result.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_NON_ENGLISH_ALLOWED"><code>NCModelView.DFLT_IS_NON_ENGLISH_ALLOWED</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>nonEnglishAllowed</code> property:
<pre class="brush: js">
{
"nonEnglishAllowed": false
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to allow non-English language in user input.</dd>
</dl>
</li>
</ul>
<a id="isNotLatinCharsetAllowed()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isNotLatinCharsetAllowed</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isNotLatinCharsetAllowed()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isNotLatinCharsetAllowed()">NCModelView</a></code></span></div>
<div class="block">Whether or not to allow non-Latin charset in user input. Currently, only
Latin charset is supported. However, model can choose whether or not to automatically reject user
input with characters outside of Latin charset. If <code>false</code> such user input will be automatically
rejected.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_NOT_LATIN_CHARSET_ALLOWED"><code>NCModelView.DFLT_IS_NOT_LATIN_CHARSET_ALLOWED</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>nonLatinCharsetAllowed</code> property:
<pre class="brush: js">
{
"nonLatinCharsetAllowed": false
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to allow non-Latin charset in user input.</dd>
</dl>
</li>
</ul>
<a id="isSwearWordsAllowed()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isSwearWordsAllowed</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isSwearWordsAllowed()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isSwearWordsAllowed()">NCModelView</a></code></span></div>
<div class="block">Whether or not to allow known English swear words in user input. If <code>false</code> - user input with
detected known English swear words will be automatically rejected.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_SWEAR_WORDS_ALLOWED"><code>NCModelView.DFLT_IS_SWEAR_WORDS_ALLOWED</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>swearWordsAllowed</code> property:
<pre class="brush: js">
{
"swearWordsAllowed": false
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to allow known swear words in user input.</dd>
</dl>
</li>
</ul>
<a id="isNoNounsAllowed()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isNoNounsAllowed</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isNoNounsAllowed()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isNoNounsAllowed()">NCModelView</a></code></span></div>
<div class="block">Whether or not to allow user input without a single noun. If <code>false</code> such user input
will be automatically rejected. Typically for strict command or query-oriented models this should be set to
<code>false</code> as any command or query should have at least one noun subject. However, for conversational
models this can be set to <code>false</code> to allow for a smalltalk and one-liners.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_NO_NOUNS_ALLOWED"><code>NCModelView.DFLT_IS_NO_NOUNS_ALLOWED</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>noNounsAllowed</code> property:
<pre class="brush: js">
{
"noNounsAllowed": false
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to allow user input without a single noun.</dd>
</dl>
</li>
</ul>
<a id="isPermutateSynonyms()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isPermutateSynonyms</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isPermutateSynonyms()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isPermutateSynonyms()">NCModelView</a></code></span></div>
<div class="block">Whether or not to permutate multi-word synonyms. Automatic multi-word synonyms permutations greatly
increase the total number of synonyms in the system and allows for better multi-word synonym detection.
For example, if permutation is allowed the synonym "a b c" will be automatically converted into a
sequence of synonyms of "a b c", "b a c", "a c b".
<p>
Note that individual model elements can override this property using <a href="NCElement.html#isPermutateSynonyms()"><code>NCElement.isPermutateSynonyms()</code></a>
method.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_PERMUTATE_SYNONYMS"><code>NCModelView.DFLT_IS_PERMUTATE_SYNONYMS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>permutateSynonyms</code> property:
<pre class="brush: js">
{
"permutateSynonyms": true
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to permutate multi-word synonyms.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCElement.html#isPermutateSynonyms()"><code>NCElement.isPermutateSynonyms()</code></a></dd>
</dl>
</li>
</ul>
<a id="isDupSynonymsAllowed()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isDupSynonymsAllowed</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isDupSynonymsAllowed()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isDupSynonymsAllowed()">NCModelView</a></code></span></div>
<div class="block">Whether or not duplicate synonyms are allowed. If <code>true</code> - the model will pick the random
model element when multiple elements found due to duplicate synonyms. If <code>false</code> - model
will print error message and will not deploy.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_DUP_SYNONYMS_ALLOWED"><code>NCModelView.DFLT_IS_DUP_SYNONYMS_ALLOWED</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>dupSynonymsAllowed</code> property:
<pre class="brush: js">
{
"dupSynonymsAllowed": true
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to allow duplicate synonyms.</dd>
</dl>
</li>
</ul>
<a id="getMaxTotalSynonyms()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxTotalSynonyms</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxTotalSynonyms()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxTotalSynonyms()">NCModelView</a></code></span></div>
<div class="block">Total number of synonyms allowed per model. Model won't deploy if total number of synonyms exceeds this
number.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_TOTAL_SYNONYMS"><code>NCModelView.DFLT_MAX_TOTAL_SYNONYMS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxTotalSynonyms</code> property:
<pre class="brush: js">
{
"maxTotalSynonyms": true
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Total number of synonyms allowed per model.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelView.html#getMaxElementSynonyms()"><code>NCModelView.getMaxElementSynonyms()</code></a></dd>
</dl>
</li>
</ul>
<a id="isNoUserTokensAllowed()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isNoUserTokensAllowed</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isNoUserTokensAllowed()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isNoUserTokensAllowed()">NCModelView</a></code></span></div>
<div class="block">Whether or not to allow the user input with no user token detected. If <code>false</code> such user
input will be automatically rejected. Note that this property only applies to user-defined
token (i.e. model element). Even if there are no user defined tokens, the user input may still
contain system token like <code>nlpcraft:city</code> or <code>nlpcraft:date</code>. In many cases models
should be build to allow user input without user tokens. However, set it to <code>false</code> if presence
of at least one user token is mandatory.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_NO_USER_TOKENS_ALLOWED"><code>NCModelView.DFLT_IS_NO_USER_TOKENS_ALLOWED</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>noUserTokensAllowed</code> property:
<pre class="brush: js">
{
"noUserTokensAllowed": false
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not to allow the user input with no user token detected.</dd>
</dl>
</li>
</ul>
<a id="isSparse()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isSparse</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isSparse()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isSparse()">NCModelView</a></code></span></div>
<div class="block">Whether or not this model elements allows non-stopword words, the gaps, in their multi-word synonyms.
<p>
Note that individual model elements can override this property using <a href="NCElement.html#isSparse()"><code>NCElement.isSparse()</code></a>
method.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_IS_SPARSE"><code>NCModelView.DFLT_IS_SPARSE</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>sparse</code>:
<pre class="brush: js, highlight: [2]">
{
"sparse": true
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Optional multi-word synonym sparsity model property.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCElement.html#isSparse()"><code>NCElement.isSparse()</code></a></dd>
</dl>
</li>
</ul>
<a id="getMetadata()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMetadata</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&gt;&nbsp;getMetadata()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMetadata()">NCModelView</a></code></span></div>
<div class="block">Gets optional user defined model metadata that can be set by the developer and accessed later.
By default, it returns an empty map. Note that this metadata is mutable and can be
changed at runtime by the model's code.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>metadata</code> property:
<pre class="brush: js">
{
"metadata": {
"str": "val1",
"num": 100,
"bool": false
}
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Optional user defined model metadata. By default, returns an empty map. Never returns <code>null</code>.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCMetadata.html#meta(java.lang.String)"><code>NCMetadata.meta(String)</code></a>,
<a href="NCMetadata.html#metaOpt(java.lang.String)"><code>NCMetadata.metaOpt(String)</code></a>,
<a href="NCMetadata.html#meta(java.lang.String,T)"><code>NCMetadata.meta(String, Object)</code></a></dd>
</dl>
</li>
</ul>
<a id="getAdditionalStopWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAdditionalStopWords</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getAdditionalStopWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getAdditionalStopWords()">NCModelView</a></code></span></div>
<div class="block">Gets an optional list of stopwords to add to the built-in ones.
<p>
Stopword is an individual word (i.e. sequence of characters excluding whitespaces) that contribute no
semantic meaning to the sentence. For example, 'the', 'wow', or 'hm' provide no semantic meaning to the
sentence and can be safely excluded from semantic analysis.
<p>
NLPCraft comes with a carefully selected list of English stopwords which should be sufficient
for a majority of use cases. However, you can add additional stopwords to this list. The typical
use for user-defined stopwords are jargon parasite words that are specific to the model's domain.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>additionalStopwords</code> property:
<pre class="brush: js">
{
"additionalStopwords": [
"stopword1",
"stopword2"
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Potentially empty list of additional stopwords.</dd>
</dl>
</li>
</ul>
<a id="getExcludedStopWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getExcludedStopWords</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getExcludedStopWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getExcludedStopWords()">NCModelView</a></code></span></div>
<div class="block">Gets an optional list of stopwords to exclude from the built-in list of stopwords.
<p>
Just like you can add additional stopwords via <a href="NCModelView.html#getAdditionalStopWords()"><code>NCModelView.getAdditionalStopWords()</code></a> you can exclude
certain words from the list of stopwords. This can be useful in rare cases when default built-in
stopword has specific meaning of your model. In order to process them you need to exclude them
from the list of stopwords.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>excludedStopwords</code> property:
<pre class="brush: js">
{
"excludedStopwords": [
"excludedStopword1",
"excludedStopword2"
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Potentially empty list of excluded stopwords.</dd>
</dl>
</li>
</ul>
<a id="getSuspiciousWords()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getSuspiciousWords</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getSuspiciousWords()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getSuspiciousWords()">NCModelView</a></code></span></div>
<div class="block">Gets an optional list of suspicious words. A suspicious word is a word that generally should not appear in user
sentence when used with this model. For example, if a particular model is for children oriented book search,
the words "sex" and "porn" should probably NOT appear in the user input and can be automatically rejected
when added here and model's metadata <code>MAX_SUSPICIOUS_WORDS</code> property set to zero.
<p>
Note that by setting model's metadata <code>MAX_SUSPICIOUS_WORDS</code> property to non-zero value you can
adjust the sensitivity of suspicious words auto-rejection logic.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>suspiciousWords</code> property:
<pre class="brush: js">
{
"suspiciousWords": [
"sex",
"porn"
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Potentially empty list of suspicious words in their lemma form.</dd>
</dl>
</li>
</ul>
<a id="getMacros()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMacros</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getMacros()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMacros()">NCModelView</a></code></span></div>
<div class="block">Gets an optional map of macros to be used in this model. Macros and option groups are instrumental
in defining model's elements. See <a href="NCElement.html" title="interface in org.apache.nlpcraft.model"><code>NCElement</code></a> for documentation on macros.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>macros</code> property:
<pre class="brush: js">
{
"macros": [
{
"name": "&lt;OF&gt;",
"macro": "{of|for|per}"
},
{
"name": "&lt;CUR&gt;",
"macro": "{current|present|moment|now}"
}
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Potentially empty map of macros.</dd>
</dl>
</li>
</ul>
<a id="getElements()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getElements</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="NCElement.html" title="interface in org.apache.nlpcraft.model">NCElement</a>&gt;&nbsp;getElements()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getElements()">NCModelView</a></code></span></div>
<div class="block">Gets a set of model elements or named entities. Model can have zero or more user defined elements.
<p>
An element is the main building block of the model. Data model element defines a named entity
that will be automatically recognized in the user input. See also <a href="NCModelView.html#getParsers()"><code>NCModelView.getParsers()</code></a> method on how
to provide programmatic named entity recognizer (NER) implementations.
<p>
Note that unless model elements are loaded dynamically it is highly recommended to declare model
elements in the external JSON/YAML model configuration (under <code>elements</code> property):
<pre class="brush: js">
{
"elements": [
{
"id": "wt:hist",
"synonyms": [
"{&lt;WEATHER&gt;|_} &lt;HISTORY&gt;",
"&lt;HISTORY&gt; {&lt;OF&gt;|_} &lt;WEATHER&gt;"
],
"description": "Past weather conditions."
}
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Set of model elements, potentially empty.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelView.html#getParsers()"><code>NCModelView.getParsers()</code></a></dd>
</dl>
</li>
</ul>
<a id="getEnabledBuiltInTokens()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getEnabledBuiltInTokens</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getEnabledBuiltInTokens()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getEnabledBuiltInTokens()">NCModelView</a></code></span></div>
<div class="block">Gets a set of IDs for built-in named entities (tokens) that should be enabled and detected for this model.
Unless model requests (i.e. enables) the built-in tokens in this method the NLP subsystem will not attempt
to detect them. Explicit enablement of the token significantly improves the overall performance by avoiding
unnecessary token detection. Note that you don't have to specify your own user elements here as they are
always enabled.
<p>
<b>Default</b>
<br>
The following built-in tokens are enabled by default implementation of this method:
<ul>
<li><code>nlpcraft:date</code></li>
<li><code>nlpcraft:continent</code></li>
<li><code>nlpcraft:subcontinent</code></li>
<li><code>nlpcraft:country</code></li>
<li><code>nlpcraft:metro</code></li>
<li><code>nlpcraft:region</code></li>
<li><code>nlpcraft:city</code></li>
<li><code>nlpcraft:num</code></li>
<li><code>nlpcraft:coordinate</code></li>
<li><code>nlpcraft:relation</code></li>
<li><code>nlpcraft:sort</code></li>
<li><code>nlpcraft:limit</code></li>
</ul>
Note that this method can return an empty list if the data model doesn't need any built-in tokens
for its logic. See <a href="NCToken.html" title="interface in org.apache.nlpcraft.model"><code>NCToken</code></a> for the list of all supported built-in tokens.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>enabledBuiltInTokens</code> property:
<pre class="brush: js">
{
"enabledBuiltInTokens": [
"google:person",
"google:location",
"stanford:money"
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Set of built-in tokens, potentially empty but never <code>null</code>, that should be enabled
and detected for this model.</dd>
</dl>
</li>
</ul>
<a id="getAbstractTokens()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAbstractTokens</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&nbsp;getAbstractTokens()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getAbstractTokens()">NCModelView</a></code></span></div>
<div class="block">Gets s set of named entities (token) IDs that will be considered as abstract tokens.
An abstract token is only detected when it is either a constituent part of some other non-abstract token
or referenced by built-in tokens. In other words, an abstract token will not be detected in a standalone
unreferenced position. By default (unless returned by this method), all named entities considered to be
non-abstract.
<p>
Declaring tokens as abstract is important to minimize number of parsing variants automatically
generated as permutation of all possible parsing compositions. For example, if it is known that a particular
named entity will only be used as a constituent part of some other token - declaring such named entity as
abstract can significantly reduce the number of parsing variants leading to a better performance,
and often simpler corresponding intent definition and callback logic.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Set of abstract token IDs. Can be empty but never <code>null</code>.</dd>
</dl>
</li>
</ul>
<a id="getParsers()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getParsers</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/List.html?is-external=true" title="class or interface in java.util" class="externalLink">List</a>&lt;<a href="NCCustomParser.html" title="interface in org.apache.nlpcraft.model">NCCustomParser</a>&gt;&nbsp;getParsers()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getParsers()">NCModelView</a></code></span></div>
<div class="block">Gets optional user-defined model element parsers for custom NER implementations. Note that order of the parsers
is important as they will be invoked in the same order they are returned.
<p>
By default, the data model detects its elements by their synonyms, regexp or IDL expressions. However,
in some cases these methods are not expressive enough. In such cases, a user-defined parser can be defined
for the model that would allow the user to define its own NER logic to detect the model elements in the user
input programmatically. Note that a single parser can detect any number of model elements.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>parser</code> property which is an array
with every element being a fully qualified class name implementing <a href="NCCustomParser.html" title="interface in org.apache.nlpcraft.model"><code>NCCustomParser</code></a> interface:
<pre class="brush: js">
{
"parsers": [
"my.package.Parser1",
"my.package.Parser2"
]
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Custom user parsers for model elements or empty list if not used (default). Never returns <code>null</code>.</dd>
</dl>
</li>
</ul>
<a id="getMaxElementSynonyms()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxElementSynonyms</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getMaxElementSynonyms()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getMaxElementSynonyms()">NCModelView</a></code></span></div>
<div class="block">Gets maximum number of unique synonyms per model element after which either warning or error will be
triggered. Note that there is no technical limit on how many synonyms a model element can have apart
from memory consumption and performance considerations. However, in cases where synonyms are auto-generated
(i.e. from database) this property can serve as a courtesy notification that a model element has too many
synonyms. Also, in general, too many synonyms can potentially lead to a performance degradation.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_ELEMENT_SYNONYMS"><code>NCModelView.DFLT_MAX_ELEMENT_SYNONYMS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxSynonymThreshold</code> property:
<pre class="brush: js">
{
"maxSynonymThreshold": 1000
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum number of unique synonyms per model element after which either warning or
error will be triggered.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelView.html#isMaxSynonymsThresholdError()"><code>NCModelView.isMaxSynonymsThresholdError()</code></a>,
<a href="NCModelView.html#getMaxTotalSynonyms()"><code>NCModelView.getMaxTotalSynonyms()</code></a></dd>
</dl>
</li>
</ul>
<a id="isMaxSynonymsThresholdError()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isMaxSynonymsThresholdError</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;isMaxSynonymsThresholdError()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#isMaxSynonymsThresholdError()">NCModelView</a></code></span></div>
<div class="block">Whether or not exceeding <a href="NCModelView.html#getMaxElementSynonyms()"><code>NCModelView.getMaxElementSynonyms()</code></a> will trigger a warning log or throwing an exception.
Note that throwing exception will prevent data probe from starting.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_MAX_SYNONYMS_THRESHOLD_ERROR"><code>NCModelView.DFLT_MAX_SYNONYMS_THRESHOLD_ERROR</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>maxSynonymThresholdError</code> property:
<pre class="brush: js">
{
"maxSynonymThresholdError": true
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Whether or not exceeding <a href="NCModelView.html#getMaxElementSynonyms()"><code>NCModelView.getMaxElementSynonyms()</code></a> will trigger a warning log or
throwing an exception.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelView.html#getMaxElementSynonyms()"><code>NCModelView.getMaxElementSynonyms()</code></a></dd>
</dl>
</li>
</ul>
<a id="getConversationTimeout()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getConversationTimeout</h4>
<pre class="methodSignature">public&nbsp;long&nbsp;getConversationTimeout()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getConversationTimeout()">NCModelView</a></code></span></div>
<div class="block">Gets timeout in ms after which the unused conversation element is automatically "forgotten".
<p>
Just like in a normal human conversation if we talk about, say, "Chicago", and then don't mention it
for certain period of time during further dialog, the conversation participants subconsciously "forget"
about it and exclude it from conversation context. In other words, the term "Chicago" is no longer in
conversation's short-term-memory.
<p>
Note that both conversation <a href="NCModelView.html#getConversationTimeout()"><code>timeout</code></a> and <a href="NCModelView.html#getConversationDepth()"><code>depth</code></a>
combined define the expiration policy for the conversation management. These two properties allow to
fine tune for different types of dialogs. For example, setting longer timeout and smaller depth mimics
slow-moving but topic-focused conversation. Alternatively, settings shorter timeout and longer depth better
supports fast-moving wide-ranging conversation that may cover multiple topics.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_CONV_TIMEOUT_MS"><code>NCModelView.DFLT_CONV_TIMEOUT_MS</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>conversationTimeout</code> property:
<pre class="brush: js">
{
"conversationTimeout": 300000
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Timeout in ms after which the unused conversation element is automatically "forgotten".</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelView.html#getConversationDepth()"><code>NCModelView.getConversationDepth()</code></a></dd>
</dl>
</li>
</ul>
<a id="getConversationDepth()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getConversationDepth</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getConversationDepth()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getConversationDepth()">NCModelView</a></code></span></div>
<div class="block">Gets maximum number of requests after which the unused conversation element is automatically "forgotten".
<p>
Just like in a normal human conversation if we talk about, say, "Chicago", and then don't mention it
for a certain number of utterances during further dialog, the conversation participants subconsciously "forget"
about it and exclude it from conversation context. In other words, the term "Chicago" is no longer in
conversation's short-term-memory.
<p>
Note that both conversation <a href="NCModelView.html#getConversationTimeout()"><code>timeout</code></a> and <a href="NCModelView.html#getConversationDepth()"><code>depth</code></a>
combined define the expiration policy for the conversation management. These two properties allow to
fine tune for different types of dialogs. For example, setting longer timeout and smaller depth mimics
slow-moving but topic-focused conversation. Alternatively, settings shorter timeout and longer depth better
supports fast-moving wide-ranging conversation that may cover multiple topics.
<p>
<b>Default</b>
<br>
If not provided by the model the default value <a href="NCModelView.html#DFLT_CONV_DEPTH"><code>NCModelView.DFLT_CONV_DEPTH</code></a> will be used.
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>conversationDepth</code> property:
<pre class="brush: js">
{
"conversationDepth": 5
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Maximum number of requests after which the unused conversation element is automatically "forgotten".</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCModelView.html#getConversationTimeout()"><code>NCModelView.getConversationTimeout()</code></a></dd>
</dl>
</li>
</ul>
<a id="getRestrictedCombinations()">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getRestrictedCombinations</h4>
<pre class="methodSignature">public&nbsp;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html?is-external=true" title="class or interface in java.util" class="externalLink">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>,&#8203;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/lang/String.html?is-external=true" title="class or interface in java.lang" class="externalLink">String</a>&gt;&gt;&nbsp;getRestrictedCombinations()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="NCModelView.html#getRestrictedCombinations()">NCModelView</a></code></span></div>
<div class="block">Gets an optional map of restricted named entity combinations (linkage). Returned map is a map of entity ID to a set
of other entity IDs, with each key-value pair defining the restricted combination. Restricting certain entities
from being linked (or referenced) by some other entities allows to reduce "wasteful" parsing variant
generation. For example, it we know that entity with ID "adjective" cannot be sorted, we can restrict it
from being linked with <code>nlpcraft:limit</code> and <code>nlpcraft:sort</code> entities to reduce the
amount of parsing variants being generated.
<p>
Only the following built-in entities can be restricted (i.e., to be the keys in the returned map):
<ul>
<li><code>nlpcraft:limit</code></li>
<li><code>nlpcraft:sort</code></li>
<li><code>nlpcraft:relation</code></li>
</ul>
Note that entity cannot be restricted to itself (entity ID cannot appear as key as well as a
part of the value's set).
<p>
<b>JSON</b>
<br>
If using JSON/YAML model presentation this is set by <code>restrictedCombinations</code> property:
<pre class="brush: js">
{
"restrictedCombinations": {
"nlpcraft:limit": ["adjective"],
"nlpcraft:sort": ["adjective"]
}
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>Optional map of restricted named entity combinations. Can be empty but never <code>null</code>.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="NCVariant.html" title="interface in org.apache.nlpcraft.model"><code>NCVariant</code></a></dd>
</dl>
</li>
</ul>
</li>
</ul>
</section>
</li>
</ul>
</div>
</div>
</main>
<!-- ========= END OF CLASS DATA ========= -->
<footer role="contentinfo">
<nav role="navigation">
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a id="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a id="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/NCModelFileAdapter.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
<div class="aboutLanguage"><span style="vertical-align: super">Apache NLPCraft <span style="font-size: 80%">0.7.5</span></span> <a style="vertical-align: super; margin-right: 10px" href="https://github.com/apache/incubator-nlpcraft" target="github"><i class="fa fa-github github-logo"></i></a> <a class="github-button" href="https://github.com/apache/incubator-nlpcraft/tree/master/nlpcraft-examples" data-icon="octicon-eye" aria-label="NLPCraft Examples">Examples</a> <a class="github-button" href="https://github.com/apache/incubator-nlpcraft" data-icon="octicon-star" aria-label="Star on GitHub">Star</a> <a class="github-button" href="https://github.com/apache/incubator-nlpcraft/fork" data-icon="octicon-repo-forked" aria-label="Fork on GitHub">Fork</a> <script type="text/javascript"> SyntaxHighlighter.defaults["auto-links"] = false; SyntaxHighlighter.defaults["tab-size"] = 2; SyntaxHighlighter.autoloader( 'java https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushJava.js', 'js jscript javascript https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushJScript.js', 'text plain https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushPlain.js', 'py python https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushPython.js', 'ruby rails ror rb https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushRuby.js', 'scala https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushScala.js', 'sql https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushSql.js', 'xml xhtml xslt html https://nlpcraft.apache.org/javadoc/resources/sh/scripts/shBrushXml.js' ); SyntaxHighlighter.all(); </script></div>
</div>
<div class="subNav">
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a id="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</nav>
<p class="legalCopy"><small><center> <br/> <span style="font-size: larger">Copyright &#169; 2021 Apache Software Foundation</span> <br/> <br/> <img src="https://www.apache.org/img/ASF20thAnniversary.jpg" height="64px" alt="ASF Logo"> </center></small></p>
</footer>
</body>
</html>