warp-contracts-plugin-nlp
v1.0.8
Published
A NLP (https://github.com/axa-group/nlp.js) plugin for warp contracts
Downloads
11
Readme
Warp Contracts Nlp plugin
This plugin attaches the NlpManager
from the nlp.js library to the SmartWeave
global object.
It can be then used inside the contract like this:
const manager = new SmartWeave.extensions
.NlpManager({languages: ['en'], forceNER: true, nlu: { log: true }});
Installation
yarn add warp-contracts-plugin-nlp
import {NlpExtension} from "warp-contracts-nlp-plugin";
import {WarpFactory} from "warp-contracts";
const warp = WarpFactory.forMainnet()
.use(new NlpExtension())
Requires warp-contract
SDK ver. min. 1.2.18
.