GithubHelp home page GithubHelp logo

seq2seq_chatbot's Introduction

DEPRECATED

This project was built in 2016 (the old tensorflow era), and some design choices no longer make sense under the new tensorflow. You are likely to find better seq2seq tutorial/implementation somewhere else.

seq2seq_chatbot

An implementation of Seq2seq chatbot in tensorflow.

Features

  • dynamic rnn with smart loader (padding free)
  • beam search on prediction (fast approximation on global optimum)
  • signal indicator for decoder (partial control on decoder)

A technical report: https://docs.google.com/gview?url=http://sudongqi.com/Documents/2016_02.pdf&embedded=true

Python 2.7 dependency

  • tensorflow 1.8
  • numpy
  • json

Instruction

  • run "python train.py" and wait (5 minutes on GTX 1080 Ti with cuda 9.0 and cudnn 7.0) until training is completed
  • run "python test.py" to enter the interactive session with the chatbot

Try your own data

it's possible to run it on your own data, but you need to generate at least 2 files with the same format like those in bbt_data.

  • text.txt this is the training data contatining the pair in number token format
  • dict.json this is the dicitonary to translate from number token to English word token in test time
  • actors.json (optional) this is for signal indication in test time
  • summary.json (optional) this file contain the length info for selecting the right bucket options for training

OpenSubtitles data

If you want to train on openSubtitles (english 2016) dataset, this project provide a data processing script (data_processing/openSub_data_generator.py) for openSubtitles. Get OpenSubtitles data from here: http://opus.lingfil.uu.se/OpenSubtitles2016.php

seq2seq_chatbot's People

Contributors

sudongqi 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.