Skip to content

Code for TSAN: A Tree-Structured Attention Network for Multi-Party Dialogues

License

Notifications You must be signed in to change notification settings

scape1989/SVRNN-dialogues

Repository files navigation

TSAN-Dialogues

All configuration is in params.py. You should change use_cuda=True if you want to use GPU.

Install Requirements

make install

Dataset

SimDial

Simulated dialogs in JSON are generated with code here. Generate samepls and interpretion by running

cd data/simdial/
python read_simdial.py

Ubuntu Chat Corpus

First download the Ubuntu Chat Corpus from here. Then generate samples from the corpus by running

make dataset data_path=path/to/your/ubuntu/corpus

If you want to use GloVe, download it here.

Train

python train_linear_vrnn.py

or

python train_tree_vrnn.py

Decode

python train_linear_vrnn.py --decode --ckpt_dir run1585003537 --ckpt_name vrnn_5.pt

or

python train_tree_vrnn.py --decode --ckpt_dir run1585003537 --ckpt_name vrnn_5.pt

Interpret

python interpretion.py --ckpt_dir run1585003537 --ckpt_name vrnn_5.pt

Run all of them

python train_interpret.py

and to view the result

tensorboard --logdir /log/ckpt_dir/

Model Architecture

Image 1

About

Code for TSAN: A Tree-Structured Attention Network for Multi-Party Dialogues

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages