Package: convlab
ConvLab-3ConvLab-3is a flexible dialog system platform based on aunified data formatfor task-oriented dialog (TOD) datasets. The unified format serves as the adapter between TOD datasets and models: datasets are first transformed to the unified format and then loaded by models. In this way, the cost of adapting $M$ models to $N$ datasets is reduced from $M\times N$ to $M+N$. While retaining all features ofConvLab-2,  ConvLab-3 greatly enlarges supported datasets and models thanks to the unified format, and enhances the utility of reinforcement learning (RL) toolkit for dialog policy module. For typical usage, see ourpaper. Datasets and Trained models are also available onHugging Face Hub.InstallationTutorialsUnified DatasetsModelsContributingCode StructureTeamCitingLicenseUpdates2022.11.30: ConvLab-3 release.InstallationYou can install ConvLab-3 in one of the following ways according to your need. We usetorch>=1.10.1,<=1.13andtransformers>=4.17.0,<=4.24.0. Higher versions oftorchandtransformersmay also work.Git clone and pip install in development mode (Recommend)For the latest and most configurable version, we recommend installing ConvLab-3 in development mode.Clone the newest repository:gitclone--depth1https://github.com/ConvLab/ConvLab-3.gitInstall ConvLab-3 via pip:cdConvLab-3
pipinstall-e.Pip install from PyPITo use ConvLab-3 as an off-the-shelf tool, you can install via:pipinstallconvlabNote that thedatadirectory will not be included due to the package size limitation.Using DockerWe also provideDockerfilefor building docker. Basically it uses therequirement.txtand then installs ConvLab-3 in development mode.# create imagedockerbuild-tconvlab.# run containerdockerrun-ditconvlab# open bash in containerdockerexec-itCONTAINER_IDbashTutorialsGetting Started(Have a try onColab!)Introduction to Unified Data FormatUtility functions for unified datasetsRL ToolkitInteractive Tool[demo video]Unified DatasetsCurrent datasets in unified data format: (DA-U/DA-S stands for user/system dialog acts)DatasetDialogsGoalDA-UDA-SStateAPI resultDataBaseCamrest676:white_check_mark::white_check_mark::white_check_mark::white_check_mark::white_check_mark:WOZ 2.01200:white_check_mark::white_check_mark:KVRET3030:white_check_mark::white_check_mark::white_check_mark:DailyDialog13118:white_check_mark:Taskmaster-113175:white_check_mark::white_check_mark::white_check_mark:Taskmaster-217303:white_check_mark::white_check_mark::white_check_mark:MultiWOZ 2.110438:white_check_mark::white_check_mark::white_check_mark::white_check_mark::white_check_mark:Schema-Guided22825:white_check_mark::white_check_mark::white_check_mark::white_check_mark:MetaLWOZ40203:white_check_mark:CrossWOZ (zh)6012:white_check_mark::white_check_mark::white_check_mark::white_check_mark::white_check_mark::white_check_mark:Taskmaster-323757:white_check_mark::white_check_mark::white_check_mark::white_check_mark:Unified datasets are available underdata/unified_datasetsdirectory as well asHugging Face Hub. We will continue adding more datasets listed inthis issue. If you want to add a listed/custom dataset to ConvLab-3, you can create an issue for discussion and then create pull-request. We will list you as thecontributorsand highly appreciate your contributions!ModelsWe list newly integrated models in ConvLab-3 that support unified data format and obtain strong performance. You can follow the link for more details about these models. Other models can be used in the same way as in ConvLab-2.TaskModelsInputOutputResponse GenerationT5ContextResponseGoal-to-DialogueT5GoalDialogNatural Language UnderstandingT5,BERTNLU,MILUContextDA-UDialog State TrackingT5,SUMBT,SetSUMBT,TripPyContextStateRL PolicyDDPT,PPO,PGState, DA-U, DBDA-SWord-PolicyLAVAContext, State, DBResponseNatural Language GenerationT5,SC-GPTDA-SResponseEnd-to-EndSOLOISTContext, DBState, ResponseUser simulatorTUS,GenTUSGoal, DA-SDA-U, (Response)Trained models are available onHugging Face Hub.ContributingWe welcome contributions from community. Please see issues to find what we need.If you want to add a new dataset, model, or other feature, please describe the dataset/model/feature in an issue with corresponding issue template before creating pull-request.Small change like fixing a bug can be directly made by a pull-request.Code Structure.
├──convlab# Source code, installed in pypi package│├──dialog_agent# Interface for dialog agent and session│├──base_models
││└──t5# T5 models with a unified training script││├──goal2dialogue# T5-Goal2Dialogue││├──dst# T5-DST││├──nlu# T5-NLU││├──nlg# T5-NLG││└──rg# T5-RG││
│├──nlu# NLU models, interface, and evaluation script││├──jointBERT# BERTNLU││├──milu# MILU││└──svm# SVMNLU*││
│├──laug# Language understanding AUGmentation (LAUG) toolkit││
│├──dst# DST models, interface, and evaluation script││├──rule# RuleDST││├──setsumbt# SetSUMBT, has uncertainty estimates││├──sumbt# SUMBT││├──trippy# TripPy││├──trade# TRADE*││├──comer# COMER*││├──mdbt# MDBT*││└──dstc9# scripts for DSTC9 cross-lingual DST evaluation││
│├──policy# Policy models, interface, and RL toolkit││├──vector# vectorizer class││├──plot_results# RL plotting tool││├──mle# MLE (imitation learning) policy││├──pg# Policy Gradient││├──ppo# Proximal Policy Optimization││├──vtrace_DPT# DDPT││├──lava# LAVA││├──rule# Rule policies and rule-based user simulators││├──tus# TUS││├──genTUS# GenTUS││├──dqn# DQN*││├──gdpl# GDPL*││├──vhus# VHUS*││├──hdsa# HDSA*││├──larl# LARL*││└──mdrg# MDRG*││
│├──nlg# NLG models, interface, and evaluation script││├──scgpt# SC-GPT││├──sclstm# SC-LSTM││└──template# TemplateNLG*││
│├──e2e# End2End models││├──soloist# SOLOIST││├──damd# DAMD*││└──sequicity# Sequicity*││
│├──evaluator# Evaluator for interactive evaluation│├──human_eval# Human evaluation with AMT│├──task# Goal generators for MultiWOZ, CrossWOZ, and Camrest│├──util
││└──unified_datasets_util.py# Utility function for unified data format│└──deploy# Deploy system for human conversion│
├──data# Data dir, not included in pypi package│├──...# ConvLab-2 data, not available for pypi installation│└──unified_datasets# Unified datasets, available for pypi installation├──examples
│└──agent_examples# Examples of building user and system agents└──tutorials# Tutorials*: models do not support unified datasets, only support MultiWOZ.TeamConvLab-3is maintained and developed byTsinghua University Conversational AIgroup (THU-COAI), theDialogue Systems and Machine Learning Groupat Heinrich Heine University, Düsseldorf, Germany and Microsoft Research (MSR).We would like to thank all contributors of ConvLab:Yan Fang, Zhuoer Feng, Jianfeng Gao, Qihan Guo, Kaili Huang, Minlie Huang, Sungjin Lee, Bing Li, Jinchao Li, Xiang Li, Xiujun Li, Jiexi Liu, Lingxiao Luo, Wenchang Ma, Mehrad Moradshahi, Baolin Peng, Runze Liang, Ryuichi Takanobu, Dazhen Wan, Hongru Wang, Jiaxin Wen, Yaoqin Zhang, Zheng Zhang, Qi Zhu, Xiaoyan Zhu, Carel van Niekerk, Christian Geishauser, Hsien-chin Lin, Nurul Lubis, Xiaochen Zhu, Michael Heck, Shutong Feng, Milica Gašić.CitingIf you use ConvLab-3 in your research, please cite:@article{zhu2022convlab3,
    title={ConvLab-3: A Flexible Dialogue System Toolkit Based on a Unified Data Format},
    author={Qi Zhu and Christian Geishauser and Hsien-chin Lin and Carel van Niekerk and Baolin Peng and Zheng Zhang and Michael Heck and Nurul Lubis and Dazhen Wan and Xiaochen Zhu and Jianfeng Gao and Milica Gašić and Minlie Huang},
    journal={arXiv preprint arXiv:2211.17148},
    year={2022},
    url={http://arxiv.org/abs/2211.17148}
}LicenseApache License 2.0