news-search-engine

所属分类:特征抽取
开发工具:Python
文件大小:8091KB
下载次数:0
上传日期:2020-04-05 10:13:15
上 传 者sh-1993
说明:  新闻搜索引擎
(News search engine)

文件列表:
code (0, 2020-04-05)
code\index_module.py (3875, 2020-04-05)
code\recommendation_module.py (5653, 2020-04-05)
code\setup.py (1611, 2020-04-05)
code\spider.chinanews.com.clean.py (847, 2020-04-05)
code\spider.chinanews.com.py (5155, 2020-04-05)
code\spider.py (2697, 2020-04-05)
config.ini (260, 2020-04-05)
data (0, 2020-04-05)
data\idf.txt (1041997, 2020-04-05)
data\ir.db (13506560, 2020-04-05)
data\news (0, 2020-04-05)
data\news\1.xml (1360, 2020-04-05)
data\news\10.xml (2299, 2020-04-05)
data\news\100.xml (3795, 2020-04-05)
data\news\1000.xml (1498, 2020-04-05)
data\news\1001.xml (1906, 2020-04-05)
data\news\1002.xml (1198, 2020-04-05)
data\news\1003.xml (1789, 2020-04-05)
data\news\1004.xml (3485, 2020-04-05)
data\news\1005.xml (893, 2020-04-05)
data\news\1006.xml (1368, 2020-04-05)
data\news\1007.xml (1707, 2020-04-05)
data\news\1008.xml (1235, 2020-04-05)
data\news\1009.xml (2053, 2020-04-05)
data\news\101.xml (3750, 2020-04-05)
data\news\1010.xml (3036, 2020-04-05)
data\news\1011.xml (1902, 2020-04-05)
data\news\1012.xml (2056, 2020-04-05)
data\news\1013.xml (1808, 2020-04-05)
data\news\1014.xml (1910, 2020-04-05)
data\news\1015.xml (2460, 2020-04-05)
data\news\1016.xml (2276, 2020-04-05)
data\news\1017.xml (1904, 2020-04-05)
data\news\1018.xml (2367, 2020-04-05)
data\news\1019.xml (896, 2020-04-05)
... ...

# 新闻搜索引擎 # 使用方法 1. 安装python 3.4+环境(推荐[Anaconda](https://www.anaconda.com/distribution/)或[Miniconda](https://docs.conda.io/en/latest/miniconda.html)) 2. 安装lxml html解析器,命令为`pip install lxml` 3. 安装jieba分词组件,命令为`pip install jieba` 4. 安装Flask Web框架,命令为`pip install Flask` 5. 进入web文件夹,运行main.py文件 6. 打开浏览器,访问http://127.0.0.1:5000/ 输入关键词开始测试 如果想抓取最新新闻数据并构建索引,一键运行`./code/setup.py`,再按上面的方法测试。 2020.4.5:新增抓取[中国新闻网](http://www.chinanews.com/scroll-news/news1.html)的爬虫程序。先运行`./code/spider.chinanews.com.py`爬取最近5天新闻(约2500条);然后注释`./code/setup.py`[第38行](https://github.com/01joy/news-search-engine/blob/master/code/setup.py#L38)并运行,自动构建索引。 # 项目介绍 1. [和我一起构建搜索引擎(一)简介](http://bitjoy.net/2016/01/04/introduction-to-building-a-search-engine-1/) 2. [和我一起构建搜索引擎(二)网络爬虫](http://bitjoy.net/2016/01/04/introduction-to-building-a-search-engine-2/) 3. [和我一起构建搜索引擎(三)构建索引](http://bitjoy.net/2016/01/07/introduction-to-building-a-search-engine-3/) 4. [和我一起构建搜索引擎(四)检索模型](http://bitjoy.net/2016/01/07/introduction-to-building-a-search-engine-4/) 5. [和我一起构建搜索引擎(五)推荐阅读](http://bitjoy.net/2016/01/09/introduction-to-building-a-search-engine-5/) 6. [和我一起构建搜索引擎(六)系统展示](http://bitjoy.net/2016/01/09/introduction-to-building-a-search-engine-6/) 7. [和我一起构建搜索引擎(七)总结展望](http://bitjoy.net/2016/01/09/introduction-to-building-a-search-engine-7/) 8. [和我一起构建搜索引擎(八)更新爬虫&修改打分&线上部署](https://bitjoy.net/2020/04/05/introduction-to-building-a-search-engine-8//) # 感谢 * [jieba](https://github.com/fxsjy/jieba) * [scikit-learn](https://github.com/scikit-learn/scikit-learn) * [flask](https://github.com/mitsuhiko/flask)

近期下载者

相关文件


收藏者