Skip to content

wingbotai/wingbot-watson

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Watson Assistant NLP API integration for Wingbot

Use the Watson Assistant NLP in wingbot chatbot

Installing

npm i -S wingbot-watson

Usage

const { WatsonNlpModel } = require('wingbot-watson');
const { ai } = require('wingbot');

const watsonNlpModel = new WatsonNlpModel({
    username: '<your API username>',
    password: '<your API password>',
    workspaceId: '<your workspace id>',
    serviceUrl: WatsonNlpModel.SERVICE_URL_FRANKFURT // WatsonNlpModel.SERVICE_URL_LONDON
});

ai.register(watsonNlpModel);

API

Classes

WatsonNlpModel

AI Plugin Model

Typedefs

Entity : object
Intent : object
Result : object

WatsonNlpModel

AI Plugin Model

Kind: global class

new WatsonNlpModel(options, [log])

Param Type Description
options object
options.username string the API username
options.password string the API password
options.workspaceId string workspace ID
[options.cacheSize] number
[options.serviceUrl] string model url, default Dallas
[log] Object logging function

WatsonNlpModel.SERVICE_URL_DALLAS : string

Kind: static property of WatsonNlpModel

WatsonNlpModel.SERVICE_URL_FRANKFURT : string

Kind: static property of WatsonNlpModel

WatsonNlpModel.SERVICE_URL_LONDON : string

Kind: static property of WatsonNlpModel

Entity : object

Kind: global typedef

Param Type
entity string
value string
score number

Intent : object

Kind: global typedef

Param Type
intent string
score number
[entities] Array.<Entity>

Result : object

Kind: global typedef

Param Type
entities Array.<Entity>
intents Array.<Intent>

About

Wingbot plugin for Watson Assistant NLP

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors