0.0.10 • Published 4 years ago
hoodie-plugin-scampi-nlp v0.0.10
hoodie-plugin-scampi-nlp
Hoodie plugin for the Scampi App utilising NLP techniques including the activity matcher. This app is build with Hoodie. Find out more on docs.hood.ie
Setup
git clone git@bitbucket.org:kzachos/scampi-nlp.git
cd scampi-nlp
npm install
npm start
Updates
1. Updating Activity JSON
Add new json file to folder called
/hoodie
In
es-api.js
changevar inputfile = require("./ActivityJSONvVERSIONNUMBER.json");
to name of latest version- In terminal, run
npm start
- In Postman App select
post
and inbody
selectraw
withJSON
type. Then enter the following in thebody
:
{
"description" : "go to church",
"es_index": "activities"
}
then, do call the following api endpoints:
http://localhost:4001/hoodie/scampi-nlp/esDeleteIndex
http://localhost:4001/hoodie/scampi-nlp/esCreateIndex
http://localhost:4001/hoodie/scampi-nlp/esBulkIndex
Finally, call the following api endpoint to test the new acitivity list is up-to-date
http://localhost:4001/hoodie/scampi-nlp/esSearch
(change thedescription
text to whatever you want to test)
2. Updating published NPM module
- In
package.json
increment version number at attribute called e.g. from“version": "0.0.5"
to“version": "0.0.6"
- (Might need to run
npm login
if not already logged in) - Run
npm publish
to publish the new version to NPM
3. Updating scampi-app
- Go to scampi-app
- Run
npm install --save hoodie-plugin-scampi-nlp@0.0.6