上传者: 38641366
|
上传时间: 2021-12-12 18:03:29
|
文件大小: 51KB
|
文件类型: -
whoosh的官方介绍:http://whoosh.readthedocs.io/en/latest/quickstart.html
因为做的是中文的全文检索需要导入jieba工具包以及whoosh工具包
直接上代码吧
from whoosh.qparser import QueryParser
from whoosh.index import create_in
from whoosh.index import open_dir
from whoosh.fields import *
from jieba.analyse import ChineseAnalyzer
from get_co