You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
你好,我尝试使用您的问答模块跑demo,就是运行naiveKGQA.py这个Python脚本,结果直接报如下错误:
问:你好
答:你好
问:孙中山干了什么事?
Traceback (most recent call last):
File "D:\workspace\git\HarvestText\examples\naiveKGQA.py", line 165, in
print("答:"+QA.answer(question0))
File "D:\workspace\git\HarvestText\examples\naiveKGQA.py", line 110, in answer
answers = self.search_answers(search0)
File "D:\workspace\git\HarvestText\examples\naiveKGQA.py", line 99, in search_answers
records = self.KG.query(search0)
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\graph.py", line 1127, in query
result = plugin.get(result, query.Result)
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugin.py", line 107, in get
return p.getClass()
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugin.py", line 69, in getClass
module = import(self.module_path, globals(), locals(), [""])
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugins\sparql_init_.py", line 33, in
from . import parser
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugins\sparql\parser.py", line 184, in
Param('prefix', PN_PREFIX)) + Suppress(':').leaveWhitespace()
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugins\sparql\parserutils.py", line 114, in init
self.name = name
AttributeError: can't set attribute
操作系统:Win10 专业版
python版本:3.6.13
HarvestText版本:0.8.1.8
The text was updated successfully, but these errors were encountered:
你好,我尝试使用您的问答模块跑demo,就是运行naiveKGQA.py这个Python脚本,结果直接报如下错误:
问:你好
答:你好
问:孙中山干了什么事?
Traceback (most recent call last):
File "D:\workspace\git\HarvestText\examples\naiveKGQA.py", line 165, in
print("答:"+QA.answer(question0))
File "D:\workspace\git\HarvestText\examples\naiveKGQA.py", line 110, in answer
answers = self.search_answers(search0)
File "D:\workspace\git\HarvestText\examples\naiveKGQA.py", line 99, in search_answers
records = self.KG.query(search0)
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\graph.py", line 1127, in query
result = plugin.get(result, query.Result)
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugin.py", line 107, in get
return p.getClass()
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugin.py", line 69, in getClass
module = import(self.module_path, globals(), locals(), [""])
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugins\sparql_init_.py", line 33, in
from . import parser
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugins\sparql\parser.py", line 184, in
Param('prefix', PN_PREFIX)) + Suppress(':').leaveWhitespace()
File "D:\ProgramData\anaconda3\envs\kg_env\lib\site-packages\rdflib\plugins\sparql\parserutils.py", line 114, in init
self.name = name
AttributeError: can't set attribute
操作系统:Win10 专业版
python版本:3.6.13
HarvestText版本:0.8.1.8
The text was updated successfully, but these errors were encountered: