Giter VIP home page Giter VIP logo

homo's Introduction

Homo

一个高性能,易于扩展且完全开源的自然交互系统

Build Status Go Report

演示视频(BiliBili): https://www.bilibili.com/video/av54654613

https://www.bilibili.com/video/av54654613

功能

  • 离线唤醒
    • 基于开源轻量级语音识别引擎PocketSphinx实现
    • 使用开源工具集CMUCLMTK进行离线语言模型训练
  • 在线语音识别
    • 调用百度在线语音识别API
  • 语音合成:
    • 调用百度在线语音合成API
  • 自然语言理解
    • 基于开源自然语言理解框架Rasa NLU实现
    • 采用开源信息提取工具集MITIE构建用于Rasa NLU进行实体识别和意图识别的模型
    • 意图识别分类采用开源机器学习框架scikit-learn
    • 中文分词采用开源分词组件jieba
  • 情感分析
    • 基于支持向量机(SVM)算法进行情感极性分析
    • word2vec模型构建采用开源主题建模工具Gensim
    • (可选)基于逻辑回归(Logistic Regression)算法的情感极性分类器实现

目录

安装和配置

安装和配置请阅读文档: https://blog.codist.me/homo/

运行

1.运行自然语言理解引擎

进入nlu的文件夹,source对应的python虚拟环境并启动http服务器:

cd nlu
source env3.6/bin/activate

python -m rasa_nlu.server \
       -c configs/rasa/config_jieba_mitie_sklearn.yml \
       --path models

或者直接运行脚本nlu_server.sh

cd nlu
./nlu_server.sh

2.运行文本情感分析引擎

进入sentiment文件夹,source对应的python虚拟环境并启动http服务器:

cd sentiment
source env3.6/bin/activate
python server.py

或直接运行脚本:

cd sentiment
./server.sh 

注意:加载word2vec模型需要花费5~7分钟时间

3.运行主程序

./homo-webview

了解详细启动参数请阅读文档

文件结构

  • cmd:用户交互部分,Golang实现
    • interact:控制台UI实现(已停止维护)
    • webview:webview UI实现
  • module:主体架构各模块,Golang实现
    • audio:底层音频硬件交互
    • baidu:baidu在线语音识别&合成API交互
    • nlu:自然语言理解引擎交互
    • sphinx:语音识别引擎sphinx交互
    • com:通用模块
  • sentiment:文本情感分析引擎,用到的数据集,模型构建和模型加载,用Python实现
  • nlu:自然语言理解引擎,用到的数据集,模型构建和模型加载,用Python实现
  • sphinx:离线唤醒模块,包括数据集及模块构建
  • docs:项目详细设计文档

开发文档

1. 离线唤醒实现

参见文档:wake_up.md

2. 自然语言理解实现

参见文档:nlu.md

3. 文本情感分析实现

用语音识别得到的文本进行情感分析

参见文档:sentiment.md

发展路线

  • 多平台支持

    • Windows
    • Macos
  • 完善文档

    • 在多个平台上的编译配置
    • 如何进一步扩展和完善自然语言理解引擎
  • Python部分用Go或Rust或C++重写

    • 替代用到的机器学习库
    • 文本情感分析部分:SVM...
    • 自然语言理解部分:MITIE...
  • 添加对英文的支持

    • 离线唤醒
    • 语音识别
    • 语音合成
    • 文档

贡献

欢迎通过 issues 提出问题和建议,或通过 Pull Requests 向本项目提交修改

捐赠

如果你觉得这个项目对你有帮助,可以请作者喝一杯咖啡,支持作者继续开发

donate.png

协议

MIT

Copyright (c) 2019-present Codist

homo's People

Contributors

vufa avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.