compromise
Advanced tools
Comparing version 10.6.1 to 10.7.0
@@ -39,2 +39,9 @@ `compromise` uses semver, with occasional releases to npm and bower. | ||
- move internal lexicon around, to support new format in v11 | ||
- added states & provinces as #Region | ||
- added #Comparable tag for adjectives that conjugate | ||
* 10.7.0 | ||
- improved `places()` parsing | ||
- improved `{min,max}` match syntax | ||
- new `.out('match')` method | ||
- quiet addition of .pack() and .unpack() for owen | ||
@@ -41,0 +48,0 @@ ### v9 |
@@ -5,3 +5,3 @@ { | ||
"description": "natural language processing in the browser", | ||
"version": "10.6.1", | ||
"version": "10.7.0", | ||
"main": "./builds/compromise.js", | ||
@@ -29,6 +29,3 @@ "repository": { | ||
}, | ||
"files": [ | ||
"builds/", | ||
"docs/" | ||
], | ||
"files": ["builds/", "docs/"], | ||
"dependencies": {}, | ||
@@ -35,0 +32,0 @@ "devDependencies": { |
265
README.md
@@ -22,3 +22,3 @@ <div align="center"> | ||
<a href="https://github.com/nlp-compromise/compromise/graphs/contributors"> | ||
contributors | ||
many contributors | ||
</a> | ||
@@ -49,3 +49,3 @@ </sub> | ||
<div> | ||
one javascript file | ||
one javascript file | ||
</div> | ||
@@ -67,3 +67,3 @@ </td> | ||
<div> | ||
<code>npm install compromise</code> | ||
<kbd>npm install compromise</kbd> | ||
</div> | ||
@@ -74,3 +74,3 @@ </td> | ||
<div> | ||
caniuse, youbetcha | ||
caniuse, youbetcha | ||
</div> | ||
@@ -89,70 +89,84 @@ </td> | ||
no jargon, | no config, | no training | ||
| ||
<sub><i>π you can do it!</i></sub> | ||
</h6> | ||
<div align="right"> | ||
<sub><i>π you can do it!</i></sub> | ||
</div> | ||
<table> | ||
<tr> | ||
<td> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/show-all-the-nouns-760733"> | ||
Part-of-Speech tags | ||
</a> | ||
</td> | ||
<td> | ||
<sub><i>nouns, verbs, adjectives..</i></sub> | ||
</td> | ||
<td> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/change-sentence-tense-203483"> | ||
Verb conjugation | ||
</a> | ||
</td> | ||
<td> | ||
<sub><i>change tense of a verb or sentence</i></sub> | ||
</td> | ||
</tr> | ||
<tr> | ||
<td> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/parse-all-the-numbers-278986"> | ||
Number parsing | ||
</a> | ||
</td> | ||
<td> | ||
<sub><i>'seven hundred and fifty' -> 750</i></sub> | ||
</td> | ||
<td> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/named-entity-recognition-208197"> | ||
Named-entities | ||
</a> | ||
</td> | ||
<td> | ||
<sub><i>the people, places, orgs..</i></sub> | ||
</td> | ||
</tr> | ||
<tr> | ||
<td> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/custom-pos-tagging-161281"> | ||
Template-matches | ||
</a> | ||
</td> | ||
<td> | ||
<sub><i>match natural-language forms</i></sub> | ||
</td> | ||
<td> | ||
<a href="https://github.com/nlp-compromise/compromise/wiki/Usage#normalization"> | ||
Text cleanup | ||
</a> | ||
</td> | ||
<td> | ||
<sub><i>contractions, hyphenation, punctuation</i></sub> | ||
</td> | ||
</tr> | ||
</table> | ||
<h3 align="center"> | ||
<a href="http://compromise.cool/docs">API docs</a> | ||
| | ||
<h4 align="center"> | ||
<a href="http://compromise.cool/docs">API doc</a> | ||
| ||
<a href="http://compromise.cool/demos">Demos</a> | ||
| ||
<a href="https://github.com/nlp-compromise/compromise/wiki/QuickStart">QuickStart</a> | ||
| ||
<a href="https://github.com/nlp-compromise/compromise/wiki/Usage">Tutorials</a> | ||
</h3> | ||
#### Client-side! | ||
<table> | ||
<tr> | ||
<td> | ||
<div align="center"> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/show-all-the-nouns-760733"> | ||
Part-of-Speech tagging | ||
</a> | ||
</div> | ||
<div align="center"> | ||
<sub>nouns! verbs! adjectives!</sub> | ||
</div> | ||
</td> | ||
<td> | ||
<div align="center"> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/named-entity-recognition-208197"> | ||
Named-entities | ||
</a> | ||
</div> | ||
<div align="center"> | ||
<sub>people, places, organizations</sub> | ||
</div> | ||
</td> | ||
<td> | ||
<div align="center"> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/parse-all-the-numbers-278986"> | ||
Number parsing | ||
</a> | ||
</div> | ||
<div align="center"> | ||
<sub>seven hundred and fifty == 750</sub> | ||
</div> | ||
</td> | ||
</tr> | ||
<tr> | ||
<td> | ||
<div align="center"> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/custom-pos-tagging-161281"> | ||
Template-matches | ||
</a> | ||
</div> | ||
<div align="center"> | ||
<sub>like a regex for a sentence</sub> | ||
</div> | ||
</td> | ||
<td> | ||
<div align="center"> | ||
<a href="https://nlp-expo.firebaseapp.com/expo/change-sentence-tense-203483"> | ||
Verb conjugation | ||
</a> | ||
</div> | ||
<div align="center"> | ||
<sub>all your base are belong</sub> | ||
</div> | ||
</td> | ||
<td> | ||
<div align="center"> | ||
<a href="https://github.com/nlp-compromise/compromise/wiki/Usage"> | ||
Transformations | ||
</a> | ||
</div> | ||
<div align="center"> | ||
<sub>contractions, style, mood..</sub> | ||
</div> | ||
</td> | ||
</tr> | ||
</table> | ||
#### β‘οΈ Client-side! | ||
```html | ||
@@ -178,4 +192,10 @@ <script src="https://unpkg.com/compromise@latest/builds/compromise.min.js"></script> | ||
## Grab some words, | ||
you can use [pre-defined selections](https://github.com/nlp-compromise/compromise/wiki/Usage#subset-methods) (like **.nouns()**) or grab any pattern with [.match()](https://github.com/nlp-compromise/compromise/wiki/Match-syntax) | ||
## Toss in text, | ||
even if it's just one word: | ||
<ul> | ||
<h3>Grab a part:</h3> | ||
use <a href="https://github.com/nlp-compromise/compromise/wiki/Usage#subset-methods">built-in methods</a> like <b>.nouns()</b>, or <b>.people()</b> - or query any pattern with <b><a href="https://github.com/nlp-compromise/compromise/wiki/Match-syntax">.match()</a></b>: | ||
</ul> | ||
```js | ||
@@ -194,4 +214,7 @@ doc = nlp('Ludwig van Beethoven wrote to Josephine Brunsvik') | ||
### Plural/singular: | ||
grab the noun-phrases, make em plural: | ||
<ul> | ||
<h3>Throw stuff around:</h3> | ||
</ul> | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Nouns"><b>Plural/singular:</b></a> - grab the noun-phrases, make em plural: | ||
```javascript | ||
@@ -204,4 +227,3 @@ doc = nlp('a bottle of beer on the wall.') | ||
### Number parsing: | ||
parse written-out numbers, and change their form: | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Values"><b>Number parsing:</b></a> - parse written-out numbers, and change their form: | ||
```javascript | ||
@@ -218,4 +240,3 @@ doc = nlp('ninety five thousand and fifty two') | ||
### Normalization: | ||
handle the craziness: | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Usage"><b>Normalization:</b></a> - handle the craziness: | ||
```javascript | ||
@@ -226,4 +247,3 @@ doc = nlp("the guest-singer's bjΓΆrk at seven thirty.").normalize().out('text') | ||
### Tense: | ||
_all your base are belong:_ | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Verbs"><b>Tense:</b></a> - switch between conjugations of any verb | ||
```javascript | ||
@@ -241,4 +261,3 @@ let doc = nlp('she sells seashells by the seashore.') | ||
### Named-entities: | ||
get the people, places, organizations: | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Usage"><b> Named-entities:</b></a> - get the people, places, organizations: | ||
```javascript | ||
@@ -253,4 +272,3 @@ doc = nlp('that opera about richard nixon visiting china') | ||
### Error correction: | ||
make it say what you'd like: | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Lexicon"><b>Error correction:</b></a> - make it say what you'd like: | ||
```javascript | ||
@@ -270,4 +288,3 @@ var lexicon={ | ||
### Handy outputs: | ||
get sensible data: | ||
* <a href="https://github.com/nlp-compromise/compromise/wiki/Output"><b> Handy outputs:</b></a> - get sensible data: | ||
```javascript | ||
@@ -298,5 +315,5 @@ doc = nlp('We like Roy! We like Roy!').sentences().out('array') | ||
<td> | ||
<a href="https://www.twitter.com/compromisejs"> | ||
<a href="https://twitter.com/nlp_compromise"> | ||
<img src="https://cloud.githubusercontent.com/assets/399657/21956672/a30cf206-da53-11e6-8c6c-0995cf2aef62.jpg"/> | ||
<div> Twitter </div> | ||
<div> Twitter </div> | ||
</a> | ||
@@ -317,5 +334,5 @@ </td> | ||
<td> | ||
<a href="https://github.com/nlp-compromise/nlp_compromise/wiki/Downstream-projects"> | ||
<a href="https://github.com/nlp-compromise/nlp_compromise/wiki/Projects"> | ||
<img src="https://cloud.githubusercontent.com/assets/399657/26513481/a755ac38-4239-11e7-960a-1c26d85ddc1c.png"/> | ||
<div> Applications </div> | ||
<div> Projects </div> | ||
</a> | ||
@@ -341,9 +358,70 @@ </td> | ||
<p></p> | ||
<ul align="left"> | ||
<p> | ||
<details> | ||
<summary>π Other Languages?</summary> | ||
<p></p> | ||
<ul> | ||
okay! we've got work-in-progress forks for <a href="https://github.com/nlp-compromise/de-compromise">German</a> and <a href="https://github.com/nlp-compromise/fr-compromise">French</a>, in the same philosophy. | ||
<br/> | ||
Get involved! | ||
</ul> | ||
<p></p> | ||
</details> | ||
</p> | ||
<p> | ||
<details> | ||
<summary>βοΈ Isn't javascript too...</summary> | ||
<p></p> | ||
<ul> | ||
yeah.. | ||
<br/> | ||
it wasn't built to compete with the stanford tagger, and may not fit every project. | ||
<br/> | ||
all string stuff is synchronous too, and parallelizing is weird. | ||
<br/> | ||
See <a href="https://github.com/nlp-compromise/compromise/wiki/Speed">here</a> for information about speed & performance. | ||
</ul> | ||
<p></p> | ||
</details> | ||
</p> | ||
<p> | ||
<details> | ||
<summary>π Can it run on my arduino-watch?</summary> | ||
<p></p> | ||
<ul> | ||
Only if it's water-proof! | ||
<br/> | ||
See <a href="https://github.com/nlp-compromise/compromise/wiki/QuickStart">quickStart</a> for all sorts of funny environments. | ||
</ul> | ||
<p></p> | ||
</details> | ||
</p> | ||
<p> | ||
<details> | ||
<summary>β¨ Partial builds?</summary> | ||
<p></p> | ||
<ul> | ||
compromise can't really be tree-shaken, because it's one function. | ||
<br/> .. and the tagging methods are competitive, so it's not recommended to pull things out. | ||
<br/> | ||
It's best to load the library fully, given it's smaller than <a href="https://68.media.tumblr.com/tumblr_m674jlpyPT1ry8fquo1_250.gif">this gif</a>. | ||
<br/> | ||
A plug-in scheme is in the works. | ||
</ul> | ||
<p></p> | ||
</details> | ||
</p> | ||
</ul> | ||
<hr/> | ||
### Don't forget about: | ||
* β¨ **[naturalNode](https://github.com/NaturalNode/natural)** - decidedly fancier, statistical nlp in javascript | ||
* π **[SuperScript](http://superscriptjs.com/)** - clever conversation engine in js | ||
* π **[NodeBox Linguistics](https://www.nodebox.net/code/index.php/Linguistics)** - conjugation, inflection in javascript | ||
* π **[reText](https://github.com/wooorm/retext)** - very impressive [text utilities](https://github.com/wooorm/retext/blob/master/doc/plugins.md) in javascript | ||
* π **[jsPos](https://code.google.com/archive/p/jspos/)** - javascript build of the time-tested Brill-tagger | ||
* π **[spaCy](https://spacy.io/)** - speedy, multilingual tagger in C/python | ||
* **[naturalNode](https://github.com/NaturalNode/natural)** - decidedly fancier, statistical nlp in javascript | ||
* **[superScript](http://superscriptjs.com/)** - clever conversation engine in js | ||
* **[nodeBox Linguistics](https://www.nodebox.net/code/index.php/Linguistics)** - conjugation, inflection in javascript | ||
* **[reText](https://github.com/wooorm/retext)** - very impressive [text utilities](https://github.com/wooorm/retext/blob/master/doc/plugins.md) in javascript | ||
* **[jsPos](https://code.google.com/archive/p/jspos/)** - javascript build of the time-tested Brill-tagger | ||
* **[spaCy](https://spacy.io/)** - speedy, multilingual tagger in C/python | ||
@@ -360,4 +438,3 @@ For the former promise-library, see [jnewman/compromise](https://github.com/jnewman/compromise) | ||
<a href="http://cogcomp.cs.illinois.edu/page/software/">Illinois toolkit</a> | ||
π | ||
) | ||
</div> |
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
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
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
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
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
1240222
27789
424
60