Question Answering PPP-QuestionParsing-Grammatical 실행해보기 AI

Open source Question answering framework


Question Parsing module for the PPP using a grammatical approch

Updated on Mar 29

설치하려고 시도하는데, 잘 안 되네.

virtualenv python=python3.5 pvenv
source pvenv/bin/activate

pip3 install git+

Ppp/PPP-QuestionParsing-Grammatical/demo$ python 
Traceback (most recent call last):
  File "", line 1, in <module>
    from corenlp import StanfordCoreNLP
ImportError: No module named 'corenlp'

pip install corenlp-python

You can install the main dependencies (especially CoreNLP) using the script file from (clone the Scripts repository and run bash

라는데, Scripts repository에는 bootstrap_corenlp.sh가 없다.

에 설명이 있었다.

CORENLP="stanford-corenlp-full-2015-01-30" CORENLP_OPTIONS="-parse.flags \" -makeCopulaHead\"" python3 -m corenlp

demo를 실행시켜 보기 위해서
를 git clone.



도 git clone

stanford-corenlp-full-2015-01-30 를 받고 싶은데, 아직 못 찾겠다.

cd Scripts

CORENLP="stanford-corenlp-full-*" CORENLP_OPTIONS="-parse.flags \" -makeCopulaHead\"" python -m corenlp -H -p 

8080 port로 실행 된다.

다른 terminal에서 source pvenv/bin/activate 하고
cd PPP-QuestionParsing-Grammatical/demo

corenlp directory나 port를 조금씩 고쳐가면서 demo1부터 실행.

python demo1.python 은 실행 됐다.

demo3.python에서 port를 8080로 고치기.

demo3가 json error가 나는 중. -_-

PPP-QuestionParsing-Grammatical/demo$ python3 >
Where is the capital of Belgium?
Traceback (most recent call last):
  File "", line 29, in <module>
  File "", line 24, in get_tree
    result = nlp.parse(sentence)
  File "", line 17, in parse
    result = r.json()['sentences'][0]
.../site-packages/requests/", line 826, in json
    return complexjson.loads(self.text, **kwargs)
  File "/usr/lib/python3.5/json/", line 319, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.5/json/", line 339, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.5/json/", line 357, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) - - [23/Aug/2016 00:15:13] "POST /?properties=%7B%22annotators%22%3A+%22tokenize%2Cssplit%2Cpos%2Clemma%2Cner%2Cparse%22%2C+%22outputFormat%22%3A+%22json%22%2C+%22parse.flags%22%3A+%22+-makeCopulaHead%22%7D HTTP/1.1" 404 -

$ pip install jsonrpclib

했더니, 이제는 corenlp도 안 뜬다.

Ppp/Scripts$ CORENLP="stanford-corenlp-full-2014-08-27" CORENLP_OPTIONS="-parse.flags \" -makeCopulaHead\"" python3 -m corenlp -p 9000
Traceback (most recent call last):
  File "/usr/lib/python3.5/", line 184, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.5/", line 85, in _run_code
    exec(code, run_globals)

    from jsonrpclib.SimpleJSONRPCServer import SimpleJSONRPCServer
ImportError: No module named 'jsonrpclib'

을 보면,

git clone

을 썼었나 보다.


댓글 입력 영역