Home

Awesome

CPED

made-with-python arxiv GitHub stars GitHub license GitHub repo size Code style: black GitHub last commit

README: English | 中文
This repository provides the implementation details for the paper:
CPED: A Large-Scale Chinese Personalized and Emotional Dialogue Dataset for Conversational AI

For more information, please refer to our paper.

The dataset is also available in luge.ai: https://www.luge.ai/#/luge/dataDetail?id=41

<a name="#Contents">Contents</a>

<a name="#Introduction">Introduction</a>

We construct a dataset named CPED from 40 Chinese TV shows. CPED consists of multisource knowledge related to empathy and personal characteristic. This knowledge covers 13 emotions, gender, Big Five personality traits, 19 dialogue acts and other knowledge. The table below shows a comparison of CPED with some other common conversation data sets.

dataset_comparison

<a name="#Dataset">Dataset Statistics</a>

In order for the dialogue system to learn emotional expression and personalized expression abilities, we provide multiple types of annotation labels listed in the following Table.

# of annos.LabelsNum.
Sentimentpositive, neutral, and negative3
Emotionhappy, grateful, relaxed, other-positive, neutral, angry, sad, feared, depressed, disgusted, astonished, worried and other-negative13
Gendermale, female, and unknown3
Age groupchildren, teenager, young, middle-aged, elderly and unknown6
Big Fivehigh, low, and unknown3
DAgreeting (g), question (q), answer (ans), statement-opinion (sv), statement-non-opinion (sd), apology (fa), command (c), agreement/acceptance (aa), disagreement (dag), acknowledge (a), appreciation (ba), interjection (ij), conventional-closing (fc), thanking (ft), quotation (^q), reject(rj), irony (ir), comfort (cf) and other (oth)19
Scenehome, office, school, mall, hospital, restaurant, sports-venue, entertainment-venue, car, outdoor and other-scene11

Distribution of Gender, Age Group, Sentiment, Emotion and DA in CPED Dataset are shown in the following figure.

The statistics of CPED are listed in the following table.

StatisticsTrainDevTest
# of modalities(v,a,t)(v,a,t)(v,a,t)
# of TV plays2659
# of dialogues8,0869342,815
# of utterances94,18711,13727,438
# of speakers2733881
Avg. # utt. per dial.11.611.99.7
Max # utt. per dial.753134
Avg. # of emot. per dial.2.83.43.2
Avg. # of DAs per dial.3.63.73.2
Avg. utt. length8.38.28.3
Max utt. length1274245
Avg. duration of an utterance2.1s2.12s2.21s

<a name="#Task">Task Definition</a>

CPED allows evaluation of both conversational cognitive tasks and conversation generation tasks, e.g. speaker modeling, personality recognition in conversations, emotion recognition in conversations, DA recognition in conversations, emotion prediction for response, emotional conversation generation, personalized conversation generation, empathetic conversation etc. By being multimodal, CPED can also be applied in multimodal personality or emotion recognition, multimodal conversation generation. It will play a positive role in promoting the development of cognitive intelligence.
We introduced 3 tasks in the project:

<a name="#Usage">Usage</a>

You can create the python virtual environment through the following bash script:

conda create -n py38 python=3.8
conda activate py38
pip install torch==1.9.0+cu102 torchvision==0.10.0+cu102 torchaudio==0.9.0 -f https://download.pytorch.org/whl/torch_stable.html
pip install tensorflow==2.2.0
pip install transformers==4.18.0
python -m pip install paddlepaddle-gpu==2.3.0 -i https://mirror.baidu.com/pypi/simple
pip install pytorch-ignite==0.4.8
pip install notebook
pip install pandas
pip install chardet
pip install matplotlib==3.5.2
python -m pip install paddlenlp -i https://mirrors.aliyun.com/pypi/simple/
python -m pip install ppasr -i https://mirrors.aliyun.com/pypi/simple/ -U
pip install nltk
pip install bert-score

some version of the used packages are as follows:

python=3.8
torch==1.9.0+cu102 
torchvision==0.10.0+cu102 
torchaudio==0.9.0
tensorflow==2.2.0
tensorboard==2.2.2
transformers==4.18.0
paddlepaddle-gpu==2.3.0
paddlenlp==2.3.2
pytorch-ignite==0.4.8
matplotlib==3.5.2
notebook==6.4.11
pandas==1.4.2
chardet==4.0.0
nltk==3.7
bert-score==0.3.11

Please cite our paper if you use CPED or this project:

@article{chen2022cped,
	title={{CPED}: A Large-Scale Chinese Personalized and Emotional Dialogue Dataset for Conversational AI},
	author={Yirong Chen and Weiquan Fan and Xiaofen Xing and Jianxin Pang and Minlie Huang and Wenjing Han and Qianfeng Tie and Xiangmin Xu},
	journal={arXiv preprint arXiv:2205.14727},
	year={2022},
	url={https://arxiv.org/abs/2205.14727}
}

Engineering Research Ceter of Ministry of Education on Human Body Perception