compromise
Advanced tools
Comparing version 14.4.3 to 14.4.4
@@ -11,2 +11,5 @@ compromise uses semver, and pushes to npm and github frequently | ||
--> | ||
#### 14.4.4 [August 2022] | ||
- **[fix]** - support {root} matches without compromise/two | ||
#### 14.4.3 [August 2022] | ||
@@ -13,0 +16,0 @@ - **[fix]** - guard for toRoot methods in root match |
@@ -5,3 +5,3 @@ { | ||
"description": "modest natural language processing", | ||
"version": "14.4.3", | ||
"version": "14.4.4", | ||
"main": "./src/three.js", | ||
@@ -118,2 +118,2 @@ "unpkg": "./builds/compromise.js", | ||
"license": "MIT" | ||
} | ||
} |
@@ -1,1 +0,1 @@ | ||
export default '14.4.3' | ||
export default '14.4.4' |
@@ -36,6 +36,7 @@ const addVerbs = function (token, world) { | ||
// do we have compromise/two? | ||
if (world.methods.two && world.methods.two.transform) { | ||
regs = regs.map(token => { | ||
// a reg to convert '{foo}' | ||
if (token.root) { | ||
regs = regs.map(token => { | ||
// a reg to convert '{foo}' | ||
if (token.root) { | ||
// check if compromise/two is loaded | ||
if (world.methods.two && world.methods.two.transform && world.methods.two.transform.verbConjugate) { | ||
let choices = [] | ||
@@ -57,8 +58,14 @@ if (!token.pos || token.pos === 'Verb') { | ||
} | ||
} else { | ||
// if no compromise/two, drop down into 'machine' lookup | ||
token.machine = token.root | ||
delete token.id | ||
delete token.root | ||
} | ||
return token | ||
}) | ||
} | ||
} | ||
return token | ||
}) | ||
return regs | ||
} | ||
export default inflectRoot |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
2234839
24961