nlp-regex

1.1.0 • Public • Published

nlp-regex

A small library providing nlp regex processing and text similarity functios. Work is in progress. Code is commented.

Installation

npm install nlp-regex

Usage

res = require('nlp-regex'); var e,ue;

// strings to compare str1 = 'This jouse is very nice.'; str2 = 'This house is very nice and warm.';

//basic escape and unescape functions console.log("Escape "+"

Hello World!

"); e = res.escape('

Hello World!

'); console.log(e); ue = res.unescape(e); console.log("Unescape previous escaped string!"); console.log(ue+'\n');

// text similarity functions console.log("Jaro distance: "+res.jDist(str1,str2)); console.log("Jaro-Winkler distance: "+res.jwDist(str1,str2)); console.log("Levenshtein distance: "+res.lsDist(str1,str2)); console.log("Similar text(%): "+res.sText(str1,str2,true));

Release History

  • 1.0.0 Initial release

Readme

Keywords

Package Sidebar

Install

npm i nlp-regex

Weekly Downloads

0

Version

1.1.0

License

MIT

Last publish

Collaborators

  • jgiro