Git Product home page Git Product logo

bi-seq2seq's Introduction

Bi-Seq2Seq

An implementation of "Two are Better than One: An Ensemble of Retrieval- and Generation-Based Dialog Systems".
This code serves as a baseline of "Response Generation by Context-aware Prototype Editing" (https://arxiv.org/abs/1806.07042).

Code:

Run preprocess() to generate some pickle files for training. (./data/train.pkl, ./data/test.pkl, ./data/val.pkl)
Run train_onehotkey(batch_size=32) for training. Models are saved under "./model".
Run generate_batches(model_path='./model/epoch.10.model',batch_size=32) to generate results(./output/result).

Data preparing:

'./data/train.query',(raw querys, line by line) './data/train.reply',
'./data/train.target',
'./data/val.query',
'./data/val.reply',
'./data/val.target',
'./data/test.query',
'./data/test.reply',
'./data/test.target', (If you don't have a target file, you can let query as the target to run preprocess())
'./data/embedding' (fasttext's format)

Dataset

You can contact the authors of “Two are Better than One: An Ensemble of Retrieval- and Generation-Based Dialog Systems” (https://arxiv.org/abs/1610.07149) if you are trying to reproduce this work. You can also get a dataset to run this code at https://github.com/MarkWuNLP/ResponseEdit.

bi-seq2seq's People

Contributors

jimth001 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

bi-seq2seq's Issues

__call__() missing 2 required positional arguments: 'inputs' and 'state'

你好,在运行biseq2seq时,第51行报这样的错误,call() missing 2 required positional arguments: 'inputs' and 'state', 谷歌得到此issues下的结果https://github.com/tensorflow/models/issues/3491, 但是我用的就是tf 1.7.0; 是否把decoder的参数补上就可以正常运行?那么在deep_components.py中decoder.__call__里的encoder_outputs ,encoder_len分别对应的是?
————————
非常感谢

How do you prepare the embedding file?

Hi!
I recently read the paper of bi-seq2seq and noticed your impressive works. When reproducing the paper work and using your codes, I am confused by the embedding file mentioned in your code.
The dataset I asked from Mark Wu does not contain such embedding file. I noticed that you used fasttext as embedding.
May I know how you generate the embedding file? Or if possible, would you mind sharing your original preprocessed dataset for me?
Really appreciate your good works! Looking forward to your response.

Regards,
Flitter

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.