This is an automated email from the ASF dual-hosted git repository.
aradzinski pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft-website.git
The following commit(s) were added to refs/heads/master by this push:
new aa7348e WIP.
aa7348e is described below
commit aa7348e58ed231f729e06247e5c93c2aaeaa9bfe
Author: Aaron Radzinski <[email protected]>
AuthorDate: Wed Sep 23 17:10:24 2020 -0700
WIP.
---
tools/embedded_probe.html | 4 +--
tools/syn_tool.html | 66 ++++++++++++++++++++++++++++++++++++++++++++---
2 files changed, 65 insertions(+), 5 deletions(-)
diff --git a/tools/embedded_probe.html b/tools/embedded_probe.html
index 7481665..213488e 100644
--- a/tools/embedded_probe.html
+++ b/tools/embedded_probe.html
@@ -38,7 +38,7 @@ id: embedded_probe
the client application takes 4 network hops to go server, then to
the data probe and back to the client application (see fig 1. below):
</p>
<figure>
- <img class="img-fluid" src="/images/emb_probe1.png" alt="">
+ <img class="img-fluid" style="max-width: 500px !important;"
src="/images/emb_probe1.png" alt="">
<figcaption><b>Fig 1.</b> Standard Processing Flow</figcaption>
</figure>
<p>
@@ -47,7 +47,7 @@ id: embedded_probe
of network hops to 2 in a similar scenario (see fig 2.):
</p>
<figure>
- <img class="img-fluid" src="/images/emb_probe2.png" alt="">
+ <img class="img-fluid" style="max-width: 500px !important;"
src="/images/emb_probe2.png" alt="">
<figcaption><b>Fig 2.</b> Embedded Processing Flow</figcaption>
</figure>
</section>
diff --git a/tools/syn_tool.html b/tools/syn_tool.html
index f599af9..cfa4f39 100644
--- a/tools/syn_tool.html
+++ b/tools/syn_tool.html
@@ -29,15 +29,75 @@ id: syn_tool
a list of synonyms that are currently missing that you might want
to add to your model.
</p>
<p>
- This tool is accessed via REST call. It's implementation is based
on Google's BERT and Facebook fasttext
- models. It requires <a target="javadoc"
href=/apis/latest/org/apache/nlpcraft/model/NCIntentSample.html">@NCIntentSample</a>
annotations present on intent
- callbacks. In short, the tool scans the data model for intents and
their
+ This tool is accessed via REST call. It is based on Google's BERT
and Facebook fasttext
+ models. It requires <a target="javadoc"
href="/apis/latest/org/apache/nlpcraft/model/NCIntentSample.html">@NCIntentSample</a>
annotations present on intent
+ callbacks. When invoked, the tool scans the given data model for
intents and their
<a target="javadoc"
href="/apis/latest/org/apache/nlpcraft/model/NCIntentSample.html">@NCIntentSample</a>
annotations, and based on these samples tries to determine
which synonyms are missing in the model.
</p>
</section>
<section id="usage">
<h2 class="section-title">Usage</h2>
+ <p>
+ In order to use this tool the <code>ctxword</code> server should
be started and the server's configuration
+ should be updated.
+ </p>
+ <h3 class="section-sub-title"><code>ctxword</code> Server</h3>
+ <p>
+ 'ctxword' server is a Python-based module that provides BERT and
fasttext based implementation
+ for finding a contextually related words for a given word from the
input sentence. NLPCraft server interacts
+ with 'ctxword' server via internal REST interface. To configure
NLPCraft server and start 'ctxword' Python-based
+ server follow these steps:
+ </p>
+ <ol>
+ <li>
+ Install necessary dependencies. <b>This step should only be
performed once:</b>
+ <nav>
+ <div class="nav nav-tabs" role="tablist">
+ <a class="nav-item nav-link active" data-toggle="tab"
href="#nav-nix" role="tab" aria-controls="nav-home"
aria-selected="true">Linux/Unix/MacOS</a>
+ <a class="nav-item nav-link" data-toggle="tab"
href="#nav-win" role="tab" aria-controls="nav-home"
aria-selected="true">Windows</a>
+ </div>
+ </nav>
+ <div class="tab-content">
+ <div class="tab-pane fade show active" id="nav-nix"
role="tabpanel">
+ <p>
+ Run the following command from NLPCraft
installation directory:
+ </p>
+ <pre class="brush: plain">
+ $
src/main/python/ctxword/bin/install_dependencies.sh
+ </pre>
+ </div>
+ <div class="tab-pane fade show" id="nav-win"
role="tabpanel">
+ <pre class="brush: plain">
+ Read
'src\main\python\ctxword\bin\WINDOWS_SETUP.md' file for manual installation
instructions.
+ </pre>
+ </div>
+ </div>
+ </li>
+ <li>
+ <em>Optional.</em>
+ <br/>
+ Configure <code>nlpcraft.server.ctxword.url</code> property in
<code>nlpcraft.conf</code> file (or your own configuration file).
+ This property comes with a default endpoint and you only need
to change it if you change the
+ 'ctxword' module implementation.
+ </li>
+ <li>
+ Start the 'ctxword' server by running the following command
from NLPCraft installation directory:
+ <pre class="brush: plain">
+ src/main/python/ctxword/bin/start_server.{sh|cmd}
+ </pre>
+ <div class="bq info">
+ <p>
+ <b>1st Start</b>
+ </p>
+ Note that on the first start the server will try to load
compressed BERT model which is not yet
+ available. It will then download this library and compress
it which will take a several minutes
+ and may require 10 GB+ of available memory. Subsequent
starts will skip this step, and the
+ server will start much faster.
+ </div>
+ </li>
+ </ol>
+ <h3 class="section-sub-title">REST Call</h3>
</section>
</div>
<div class="col-md-2 third-column">