compromise
Advanced tools
Comparing version 8.1.0 to 8.2.0
@@ -126,2 +126,7 @@ 'use strict'; | ||
example: 'nlp(\'so you are from Africa?\').insertAt(2, \'like,\').all().out()\n//so you are like, from africa?' | ||
}, | ||
lump: { | ||
desc: 'merge matches into one term, with shared tags.', | ||
returns: 'Text', | ||
example: 'nlp(\'Keanu Reeves said whoa\').match(\'#Person\').lump().all().out(\'terms\')\n//[\'Keanu Reeves\', \'said\', \'whoa\']' | ||
} | ||
@@ -196,3 +201,3 @@ }, | ||
unTag: { | ||
desc: 'remove a particular tag for all these terms.', | ||
desc: 'remove a particular tag for all these terms. Passing in a \'*\' removes all the current tags.', | ||
returns: 'Text', | ||
@@ -199,0 +204,0 @@ example: 'nlp(\'they made a catch & scored a run\').match([\'run\',\'catch\']).unTag(\'#Verb\').nouns().out(\'array\')\n//catch, run' |
@@ -5,3 +5,3 @@ { | ||
"description": "natural language processing in the browser", | ||
"version": "8.1.0", | ||
"version": "8.2.0", | ||
"main": "./builds/compromise.js", | ||
@@ -8,0 +8,0 @@ "repository": { |
@@ -132,8 +132,7 @@ <div align="center"> | ||
```javascript | ||
r = nlp(chomskyFanFic) | ||
r = nlp(freshPrince) | ||
r.places().sort('freq').unique().data() | ||
/*[ | ||
{text: 'MIT lecture hall'}, | ||
{text: '23 Desperado dr.'}, | ||
{text: 'desert island'}, | ||
{text: 'West Philadelphia'}, | ||
{text: 'Bel-Air'} | ||
]*/ | ||
@@ -150,3 +149,3 @@ ``` | ||
###Client-side: | ||
### Client-side: | ||
```html | ||
@@ -161,3 +160,3 @@ <script src="https://unpkg.com/compromise@latest/builds/compromise.min.js"></script> | ||
###Tense: | ||
### Tense: | ||
```javascript | ||
@@ -175,3 +174,3 @@ let r = nlp('she sells seashells by the seashore.') | ||
###Plural/singular: | ||
### Plural/singular: | ||
```javascript | ||
@@ -184,3 +183,3 @@ r = nlp('a bottle of beer on the wall.') | ||
###Negation: | ||
### Negation: | ||
```javascript | ||
@@ -192,3 +191,3 @@ r = nlp('london is calling') | ||
###Number interpretation: | ||
### Number interpretation: | ||
```javascript | ||
@@ -204,3 +203,3 @@ r = nlp('fifth of december') | ||
###Normalization: | ||
### Normalization: | ||
```javascript | ||
@@ -211,3 +210,3 @@ r = nlp("the guest-singer's björk at seven thirty.").normalize().out('text') | ||
###Named-entity recognition: | ||
### Named-entity recognition: | ||
```javascript | ||
@@ -222,3 +221,3 @@ r = nlp('the opera about richard nixon visiting china') | ||
###Fancy outputs: | ||
### Fancy outputs: | ||
```javascript | ||
@@ -278,3 +277,3 @@ r = nlp('Tony Hawk won').out('html') | ||
###Don't forget about: | ||
### Don't forget about: | ||
* **[naturalNode](https://github.com/NaturalNode/natural)** - decidedly fancier, statistical nlp in javascript, too | ||
@@ -281,0 +280,0 @@ * **[SuperScript](http://superscriptjs.com/)** - clever conversation engine in js |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
919307
14651
289