You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
paz2s9bc5/准备README.md

23 lines
1.1 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

### 准备
1、爬取病和要相关的数据集
2、数据解析处理存入MySQL-->导出为csv文件-->导入neo4j建立病与药之间双向映射关系以及病和药各自的一些属性
3、spark环境搭建
### 步骤
1、拿到原始句子用户从搜索框输入的问题
2、对原句子进行抽象将病名用nr替换并抽象句子HanLP自定义分词<相应病,自定义词性>以键值对形式存储),比如糖尿病要吃什么药 替换成 nr 要吃什么药
3、抽象句子匹配问题模板一堆问题数据集合由Spark进行训练并计算通过贝叶斯分类器将选择匹配到概率最大的问题模板比如 nr 治疗方法
4、问题模板还原成最终的问题从HanLP自定义分分词中具体化nr比如 nr 治疗方法替换其中的nr=糖尿病,最后效果就是糖尿病 治疗方法
5、拿到问题后去图形数据库neo4j中查找问题的答案比如 match(n:Disease) where n.name='糖尿病' return n.治疗方法
6.图数据库中查询结果返回到界面接收展示。