probabilistic-earley-parser-javascript icon indicating copy to clipboard operation
probabilistic-earley-parser-javascript copied to clipboard

Error: Cannot find module 'semiring/abstract-expression/atom'

Open gimite opened this issue 7 years ago • 3 comments

I'm interesting in using this package, but I found that it doesn't work with the latest version (1.2.7) of semiring package, at least when I use it from normal JavaScript.

This is because abstract-expression/atom.js is no longer included in semiring package. I was able to make it work by downgrading semiring to 1.2.3.

$ node --version
v9.10.1
$ npm init -y   
$ npm install probabilistic-earley-parser
+ [email protected]
$ npm list
...
  └── [email protected]
$ node
> require('probabilistic-earley-parser')
Error: Cannot find module 'semiring/abstract-expression/atom'
    at Function.Module._resolveFilename (module.js:543:15)
    at Function.Module._load (module.js:470:25)
    at Module.require (module.js:593:17)
    at require (internal/module.js:11:18)
$ npm install [email protected]     
$ node
> require('probabilistic-earley-parser')
{ addState: [Function: addState],
...

Thanks for the package anyway!

gimite avatar Mar 30 '18 13:03 gimite

Thanks, will fix when I get behind a computer. Probably after 7 days.

cacfd3a avatar Mar 30 '18 17:03 cacfd3a

Also this project doesn't have some optimizations and error handling goodies that the java version has. Could you describe your use case? Maybe it would be fruitful to port those features too.

cacfd3a avatar Mar 30 '18 17:03 cacfd3a

Thanks for the reply! I'm thinking of using this package to prototype my app which interprets small subset of English (it's like a chat bot). It's probably OK for my purpose to miss such features, but I will let you know if I encounter any issues.

I posted one question #7 which I encountered while using the package.

gimite avatar Mar 31 '18 09:03 gimite