{ "info": { "author": "XuMing", "author_email": "xuming624@qq.com", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "Natural Language :: Chinese (Simplified)", "Natural Language :: Chinese (Traditional)", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Topic :: Text Processing", "Topic :: Text Processing :: Indexing", "Topic :: Text Processing :: Linguistic" ], "description": "![alt text](docs/public/logo.svg)\n\n[![PyPI version](https://badge.fury.io/py/dialogbot.svg)](https://badge.fury.io/py/dialogbot)\n[![Contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen.svg)](CONTRIBUTING.md)\n[![License Apache 2.0](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](https://github.com/deepmipt/DeepPavlov/blob/master/LICENSE)\n![Language](https://img.shields.io/badge/Language-Python-blue.svg)\n![Python3](https://img.shields.io/badge/Python-3.X-red.svg)\n\n# dialogbot\ndialogbot, provide complete dialogue model technology. Combining task-based dialogue model, search-based dialogue model and generative dialogue model, output the optimal dialogue response.\n\nBase on **semantic analysis(tensorflow)**, **knowledge graph(neo4j)** and **data mining(spider)**.\n\n---\n\n# Feature\n\n### Retrieval Dialogue Bot\n\nCompute questions similarity, use\n\n- TFIDF\n- BM25\n- OneHot\n- Query Vector\n\n### Goal Oriented Dialogue Bot\n\n- End to End Memory Networks(memn2n)\n- BABi dataset\n\n### Generative Dialogue Bot\n\n- Sequence To Sequence Model(seq2seq)\n- Taobao dataset\n\n\n# Quick Start\n\n### Requirements and Installation\n\nThe project is based on Tensorflow 1.12.0+ and Python 3.6+.\nThen, simply do:\n\n```\npip3 install dialogbot\n```\n\nor\n\n```\ngit clone https://github.com/shibing624/dialogbot.git\ncd dialogbot\npython3 setup.py install\n```\n\n### Example Usage\n\nLet's run chat bot:\n\n```python\nimport dialogbot import Bot\n\nbot = Bot()\nresponse = bot.answer('\u4eb2 \u5403\u4e86\u5417\uff1f')\nprint(response)\n\n```\n\nDone!\n\nThis should print:\n\n```console\nquery: \"\u4eb2 \u5403\u4e86\u5417\uff1f\"\n\nanswer: \"\u5403\u4e86\u7684\uff0c\u4f60\u597d\u5440\"\n```\n\n\n## Demo\n\nhttp://www.borntowin.cn:8821\n\n## Contact\n\nPlease email your questions or comments to [xuming(shibing624)](http://www.borntowin.cn/).\n\n## Contributing\n\nThanks for your interest in contributing! There are many ways to get involved;\nstart with our [contributor guidelines](CONTRIBUTING.md) and then\ncheck these [open issues](https://github.com/shibing624/dialogbot/issues) for specific tasks.\n\nFor contributors looking to get deeper into the API we suggest cloning the repository and checking out the unit\ntests for examples of how to call methods. Nearly all classes and methods are documented, so finding your way around\nthe code should hopefully be easy.\n\n\n# reference\n\n- A Network-based End-to-End Trainable Task-oriented Dialogue System\nWen T H, Vandyke D, Mrksic N, et al. A Network-based End-to-End Trainable Task-oriented Dialogue System[J]. 2016.\n\u5f53\u524d\u6784\u5efa\u4e00\u4e2a\u8bf8\u5982\u5bbe\u9986\u9884\u8ba2\u6216\u6280\u672f\u652f\u6301\u670d\u52a1\u7684 task-oriented \u7684\u5bf9\u8bdd\u7cfb\u7edf\u5f88\u96be\uff0c\u4e3b\u8981\u662f\u56e0\u4e3a\u96be\u4ee5\u83b7\u53d6\u8bad\u7ec3\u6570\u636e\u3002\u73b0\u6709\u4e24\u79cd\u65b9\u5f0f\u89e3\u51b3\u95ee\u9898\uff1a\n\u2022\t\u5c06\u8fd9\u4e2a\u95ee\u9898\u770b\u505a\u662f partially observable Markov Decision Process (POMDP)\uff0c\u5229\u7528\u5f3a\u5316\u5b66\u4e60\u5728\u7ebf\u4e0e\u771f\u5b9e\u7528\u6237\u4ea4\u4e92\u3002\u4f46\u662f\u8bed\u8a00\u7406\u89e3\u548c\u8bed\u8a00\u751f\u6210\u6a21\u5757\u4ecd\u7136\u9700\u8981\u8bed\u6599\u53bb\u8bad\u7ec3\u3002\u800c\u4e14\u4e3a\u4e86\u8ba9 RL \u80fd\u8fd0\u4f5c\u8d77\u6765\uff0cstate \u548c action space \u5fc5\u987b\u5c0f\u5fc3\u8bbe\u8ba1\uff0c\u8fd9\u5c31\u9650\u5236\u4e86\u6a21\u578b\u7684\u8868\u8fbe\u80fd\u529b\u3002\u540c\u65f6 rewad function \u5f88\u96be\u8bbe\u8ba1\uff0c\u8fd0\u884c\u65f6\u4e5f\u96be\u4ee5\u8861\u91cf\n\u2022\t\u5229\u7528 seq2seq \u6765\u505a\uff0c\u8fd9\u53c8\u9700\u8981\u5927\u91cf\u8bed\u6599\u8bad\u7ec3\u3002\u540c\u65f6\uff0c\u8fd9\u7c7b\u6a21\u578b\u65e0\u6cd5\u505a\u5230\u4e0e\u6570\u636e\u5e93\u4ea4\u4e92\u4ee5\u53ca\u6574\u5408\u5176\u4ed6\u6709\u7528\u7684\u4fe1\u606f\uff0c\u4ece\u800c\u751f\u6210\u5b9e\u7528\u7684\u76f8\u5e94\u3002\n\u672c\u6587\u63d0\u51fa\u4e86\u5e73\u8861\u4e24\u79cd\u65b9\u6cd5\u7684\u7b56\u7565\u3002\n- How NOT To Evaluate Your Dialogue System: An Empirical Study of Unsupervised Evaluation Metrics for Dialogue Response Generation\n\n- A. Bordes, Y. Boureau, J. Weston. Learning End-to-End Goal-Oriented Dialog 2016\n\n- [chatbot-MemN2N-tensorflow](https://github.com/vyraun/chatbot-MemN2N-tensorflow)\n\n- End-to-End Reinforcement Learning of Dialogue Agents for Information Access\n2016\u5e74\u5361\u8010\u57fa\u6885\u9686\u5927\u5b66\u7814\u7a76\u56e2\u961f\u5229\u7528\u6df1\u5ea6\u5f3a\u5316\u5b66\u4e60\u8fdb\u884c\u5bf9\u8bdd\u72b6\u6001\u8ffd\u8e2a\u548c\u7ba1\u7406\n\n- Zhao T, Eskenazi M. Towards End-to-End Learning for Dialog State Tracking and Management using Deep Reinforcement Learning [J]. arXiv preprint arXiv:1606.02560, 2016.\n2016\u5e74\u9ebb\u7701\u7406\u5de5\u5927\u5b66\u7814\u7a76\u56e2\u961f\u63d0\u51fa\u5c42\u6b21\u5316DQN\u6a21\u578b\uff0c\u5176\u4ee3\u7801\u91c7\u7528Keras\u5b9e\u73b0\u5e76\u5f00\u6e90[ code ]\uff0c\u8be5\u5de5\u4f5c\u53d1\u8868\u5728NIPS2016\u4e0a\u3002\n\n- Kulkarni T D, Narasimhan K R, Saeedi A, et al. Hierarchical deep reinforcement learning: Integrating temporal abstraction and intrinsic motivation [J]. arXiv preprint arXiv:1604.06057, 2016.\n\n- BBQ-Networks: Efficient Exploration in Deep Reinforcement Learning for Task-Oriented Dialogue Systems\nAAAI2018 \u5f55\u7528\u6587\u7ae0\uff0c\u5c06\u6df1\u5ea6\u5f3a\u5316\u5b66\u4e60\u7528\u4e8e\u5bf9\u8bdd\u7cfb\u7edf\u3002BBQ network \u8fd9\u4e2a\u540d\u5b57\u5f88\u6709\u610f\u601d\uff0c\u5de5\u4f5c\u6765\u81ea\u5fae\u8f6f\u7814\u7a76\u9662\u548c CMU\u3002\n\u63d0\u51fa\u4e86\u4e00\u79cd\u65b0\u7684\u7b97\u6cd5\uff0c\u53ef\u4ee5\u663e\u8457\u63d0\u5347\u5bf9\u8bdd\u7cfb\u7edf\u4e2d\u6df1\u5ea6 Q \u5b66\u4e60\u667a\u80fd\u4f53\u7684\u63a2\u7d22\u6548\u7387\u3002\u6211\u4eec\u7684\u667a\u80fd\u4f53\u901a\u8fc7\u6c64\u666e\u68ee\u91c7\u6837\uff08Thompson sampling\uff09\u8fdb\u884c\u63a2\u7d22\uff0c\u53ef\u4ee5\u4ece Bayes-by-Backprop \u795e\u7ecf\u7f51\u7edc\u4e2d\u62bd\u53d6\u8499\u7279\u5361\u6d1b\u6837\u672c\u3002\u6211\u4eec\u7684\u7b97\u6cd5\u7684\u5b66\u4e60\u901f\u5ea6\u6bd4 \u03b5-greedy\u3001\u6ce2\u5c14\u5179\u66fc\u3001bootstrapping \u548c\u57fa\u4e8e\u5185\u5728\u5956\u52b1\uff08intrinsic-reward\uff09\u7684\u65b9\u6cd5\u7b49\u5e38\u7528\u7684\u63a2\u7d22\u7b56\u7565\u5feb\u5f97\u591a\u3002\u6b64\u5916\uff0c\u6211\u4eec\u8fd8\u8868\u660e\uff1a\u5f53 Q \u5b66\u4e60\u53ef\u80fd\u5931\u8d25\u65f6\uff0c\u53ea\u9700\u5c06\u5c11\u6570\u51e0\u4e2a\u6210\u529f episode \u7684\u7ecf\u5386\u53e0\u52a0\u5230\u91cd\u653e\u7f13\u51b2\uff08replay buffer\uff09\u4e4b\u4e0a\uff0c\u5c31\u80fd\u4f7f\u8be5 Q \u5b66\u4e60\u53ef\u884c\u3002\n- Deep Reinforcement Learning with Double Q-Learning\n\n- Deep Attention Recurrent Q-Network\n\n- SimpleDS: A Simple Deep Reinforcement Learning Dialogue System\n\n- Deep Reinforcement Learning with a Natural Language Action Space\n\n- Integrating User and Agent Models: A Deep Task-Oriented Dialogue System\n\n- A Deep Reinforcement Learning Chatbot\n\u8499\u7279\u5229\u5c14\u7b97\u6cd5\u7814\u7a76\u5b9e\u9a8c\u5ba4\uff08MILA\uff09\u4e3a\u53c2\u4e0e\u4e9a\u9a6c\u900a Alexa \u5927\u5956\u8d5b\u800c\u5f00\u53d1\u7684\u6df1\u5ea6\u5f3a\u5316\u5b66\u4e60\u804a\u5929\u673a\u5668\u4eba\u3002\nMILABOT \u80fd\u591f\u4e0e\u4eba\u7c7b\u5c31\u6d41\u884c\u7684\u95f2\u804a\u8bdd\u9898\u8fdb\u884c\u8bed\u97f3\u548c\u6587\u672c\u4ea4\u6d41\u3002\u8be5\u7cfb\u7edf\u5305\u62ec\u4e00\u7cfb\u5217\u81ea\u7136\u8bed\u8a00\u751f\u6210\u548c\u68c0\u7d22\u6a21\u578b\uff0c\u5982\u6a21\u677f\u6a21\u578b\u3001\u8bcd\u888b\u6a21\u578b\u3001\u5e8f\u5217\u5230\u5e8f\u5217\u795e\u7ecf\u7f51\u7edc\u548c\u9690\u53d8\u91cf\u795e\u7ecf\u7f51\u7edc\u6a21\u578b\u3002\n\u901a\u8fc7\u5c06\u5f3a\u5316\u5b66\u4e60\u5e94\u7528\u5230\u4f17\u5305\u6570\u636e\u548c\u771f\u5b9e\u7528\u6237\u4e92\u52a8\u4e2d\u8fdb\u884c\u8bad\u7ec3\uff0c\u8be5\u7cfb\u7edf\u5b66\u4e60\u4ece\u81ea\u8eab\u5305\u542b\u7684\u4e00\u7cfb\u5217\u6a21\u578b\u4e2d\u9009\u62e9\u5408\u9002\u7684\u6a21\u578b\u4f5c\u4e3a\u54cd\u5e94\u3002\n\u771f\u5b9e\u7528\u6237\u4f7f\u7528 A/B \u6d4b\u8bd5\u5bf9\u8be5\u7cfb\u7edf\u8fdb\u884c\u8bc4\u4f30\uff0c\u5176\u6027\u80fd\u5927\u5927\u4f18\u4e8e\u7ade\u4e89\u7cfb\u7edf\u3002\u7531\u4e8e\u5176\u673a\u5668\u5b66\u4e60\u67b6\u6784\uff0c\u8be5\u7cfb\u7edf\u7684\u6027\u80fd\u5728\u989d\u5916\u6570\u636e\u7684\u5e2e\u52a9\u4e0b\u8fd8\u6709\u53ef\u80fd\u7ee7\u7eed\u63d0\u5347\u3002\n\n\n# [License](/LICENSE)\n\nThe Apache License 2.0", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/shibing624/dialogbot", "keywords": "NLP,chatbot,dialogbot,dialogue,dialog", "license": "Apache 2.0", "maintainer": "", "maintainer_email": "", "name": "dialogbot", "package_url": "https://pypi.org/project/dialogbot/", "platform": "", "project_url": "https://pypi.org/project/dialogbot/", "project_urls": { "Homepage": "https://github.com/shibing624/dialogbot" }, "release_url": "https://pypi.org/project/dialogbot/0.0.4/", "requires_dist": null, "requires_python": "", "summary": "Dialog robot, ChatBot", "version": "0.0.4" }, "last_serial": 5637509, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "6aecb32e55ab889c6adc084a481a8558", "sha256": "83e1aee25d858e36ddac06a533336f0c4b44d981aadb2bd472c117e15a4f4a81" }, "downloads": -1, "filename": "dialogbot-0.0.1.tar.gz", "has_sig": false, "md5_digest": "6aecb32e55ab889c6adc084a481a8558", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1287135, "upload_time": "2019-06-21T05:59:58", "url": "https://files.pythonhosted.org/packages/ef/c7/6a1f3b97b475b818120206e9214a6cf1ddd0ec3e0c295e078397b5d5fc48/dialogbot-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "5b94cc619058288e7fd8d678c0b8ebd4", "sha256": "585f28248dc90057276993996af2380000a528882684e584cbd500e27e0f4caa" }, "downloads": -1, "filename": "dialogbot-0.0.2.tar.gz", "has_sig": false, "md5_digest": "5b94cc619058288e7fd8d678c0b8ebd4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1313400, "upload_time": "2019-06-24T02:50:52", "url": "https://files.pythonhosted.org/packages/08/37/547454c372f2998525c13f9088d7b095456b232bc8917ee841a479736af8/dialogbot-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "80355e3e3b5b95df1b806ad3f211bc65", "sha256": "6fb4b915bb02419ecf4f9b3b3141ee69099f819a1dca8a710e463094313ac392" }, "downloads": -1, "filename": "dialogbot-0.0.3.tar.gz", "has_sig": false, "md5_digest": "80355e3e3b5b95df1b806ad3f211bc65", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1768994, "upload_time": "2019-06-24T11:20:47", "url": "https://files.pythonhosted.org/packages/b9/9d/d00a1ba0a64cbb0d91515f9406206fde434b7cfcf194d310acc0069f28da/dialogbot-0.0.3.tar.gz" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "c993abbf1611c275766fc4d40982b231", "sha256": "2c2bbd8dd7e748a158e4fa79391077546603fe1c1169ac73811727f3a5d5e7fe" }, "downloads": -1, "filename": "dialogbot-0.0.4.tar.gz", "has_sig": false, "md5_digest": "c993abbf1611c275766fc4d40982b231", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13077271, "upload_time": "2019-08-06T04:08:54", "url": "https://files.pythonhosted.org/packages/5e/e2/ce97b71c59e6f68bf2d3267e690af74d6712f71906b376bcc8026ce79296/dialogbot-0.0.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c993abbf1611c275766fc4d40982b231", "sha256": "2c2bbd8dd7e748a158e4fa79391077546603fe1c1169ac73811727f3a5d5e7fe" }, "downloads": -1, "filename": "dialogbot-0.0.4.tar.gz", "has_sig": false, "md5_digest": "c993abbf1611c275766fc4d40982b231", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13077271, "upload_time": "2019-08-06T04:08:54", "url": "https://files.pythonhosted.org/packages/5e/e2/ce97b71c59e6f68bf2d3267e690af74d6712f71906b376bcc8026ce79296/dialogbot-0.0.4.tar.gz" } ] }