Hosting NLU Engines

Digital Agent communicates with two services to work correctly: Duckling and a Language Server. If your Digital Agent installation has no internet access, you'll have to host these services on-prem. When following the different hosting methods, look for a section on on-prem hosting for further details.

Duckling​

We use Duckling to extract system entities (time, email, currency, etc.). This service is very light and requires minimal resources.


Hosting Duckling on Linux and Mac​

On these two Operating Systems, Duckling must be compiled. Therefore, you will need to install the software development tools and build from the source.

Please follow the instructions. We may provide some binaries in the future for common OS'.

Hosting Duckling on Windows​

If you run Digital Agent on Windows, there is a .zip file. Double-click on run-duckling.bat (the bat file sets the console's code page to UTF-8, then runs the executable). The folder zoneinfo includes the Olson timezones, which are already available by default on other OS.


Configuring your Chatbot​

When you have successfully installed the duckling binary, edit the file data/global/config/nlu.json and set the parameter ducklingURL to where you run Duckling, for example, if it's on the same server as Digital Agent (and if you use the default port of 8000), you will set:


{
  ...
  "ducklingURL": "http://localhost:8000"
}

Language Server​

The Language Server is used to provide the language models necessary to run the NLU. It is quite resource-intensive to host a language server due to the model sizes. To make it easy to get started, the default installation uses a Digital Agent-hosted Language Server. You can swap it out for your own (see below).


Note:

The NLU server is not the same as the language server, and uses the models provided by the language server.


The NLU server is not the same as the language server, and uses the models provided by the language server.


DimensionsRAM UsageDisk Usage
100about 1.3 Gbabout 900 Mb
300about 3.5 Gbabout 3 Gb

All of this is per language.


Note:

300 is the number of dimensions the model has. More dimensions mean the model size is bigger. You can choose a lighter model if your server specs are limited, but keep in mind that you need to change the --dim parameter when you start the Language Server.


AbbreviationLanguage
arArabic
enEnglish
frFrench
jaJapanese
ptPortuguese
ruRussian
deGerman
esSpanish
heHebrew
itItalian
nlDutch
plPolish