Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Multilight teacher #5043

Merged
merged 15 commits into from
May 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions parlai/core/teachers.py
Original file line number Diff line number Diff line change
Expand Up @@ -1733,8 +1733,8 @@ def _get_ep_from_turns(self, xturns, yturns):
turn['text'] = xturn.get('text')
turn['labels'] = [yturn.get('text')]

turn['x_turn'] = xturn
turn['y_turn'] = yturn
turn['x_turn'] = dict(xturn)
turn['y_turn'] = dict(yturn)

eps.append(turn)
return eps
Expand Down Expand Up @@ -1841,8 +1841,8 @@ def _validate_image_mode_name(self, a):
available_model_names = self.get_available_image_mode_names()
if a not in available_model_names:
raise argparse.ArgumentTypeError(
'\"%s\" unknown image model name. Choose from: %s. Currently suggested resnet is resnet152 and resnext is resnext101_32x48d_wsl.'
% (a, available_model_names)
f'"{a}" unknown image model name. Choose from: {available_model_names}.'
'Currently suggested resnet is resnet152 and resnext is resnext101_32x48d_wsl.'
)
return a

Expand Down
30 changes: 30 additions & 0 deletions parlai/tasks/lccc/test/lccc_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,55 @@ acts:
- 去相机家里吃……
id: lccc
text: 我饿了。
x_turn:
id: partner1
text: 我饿了。
y_turn:
id: partner2
text: 去相机家里吃……
- - episode_done: true
eval_labels:
- 你过来我们什么关系
id: lccc
text: 网络大实话里说的是也许你能在网络里找到你想要的友情但永远不会找到你想要的爱情
x_turn:
id: partner1
text: 网络大实话里说的是也许你能在网络里找到你想要的友情但永远不会找到你想要的爱情
y_turn:
id: partner2
text: 你过来我们什么关系
- - episode_done: true
eval_labels:
- 我不挑食
id: lccc
text: 老铁家好吃贾三不好吃
x_turn:
id: partner1
text: 老铁家好吃贾三不好吃
y_turn:
id: partner2
text: 我不挑食
- - episode_done: true
eval_labels:
- 死鱼皮真会安慰人那不是翘臀是肥肉不!是赘肉!
id: lccc
text: 你有翘臀啊!!!!你的脸还不够小啊?????
x_turn:
id: partner1
text: 你有翘臀啊!!!!你的脸还不够小啊?????
y_turn:
id: partner2
text: 死鱼皮真会安慰人那不是翘臀是肥肉不!是赘肉!
- - episode_done: false
eval_labels:
- 哈哈哈快到南方来
id: lccc
text: 好羡慕原来你们那真的可以光腿
x_turn:
id: partner1
text: 好羡慕原来你们那真的可以光腿
y_turn:
id: partner2
text: 哈哈哈快到南方来
num_episodes: 10000
num_examples: 12943
30 changes: 30 additions & 0 deletions parlai/tasks/lccc/test/lccc_train.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,55 @@ acts:
labels:
- 道歉!!再有时间找你去
text: 你去那儿竟然不喊我生气了,快点给我道歉
x_turn:
id: partner1
text: 你去那儿竟然不喊我生气了,快点给我道歉
y_turn:
id: partner2
text: 道歉!!再有时间找你去
- - episode_done: true
id: lccc
labels:
- SEED早上刚被禁用还有一个月的VIP路线呢禁了之后才买的另一个买了一年结果用了一下午就挂了现在用了个极速网速差的很
text: 我用SEED.24小时签到一次可以用4小时,对于我这种每天晚上逛一下的感觉不错
x_turn:
id: partner1
text: 我用SEED.24小时签到一次可以用4小时,对于我这种每天晚上逛一下的感觉不错
y_turn:
id: partner2
text: SEED早上刚被禁用还有一个月的VIP路线呢禁了之后才买的另一个买了一年结果用了一下午就挂了现在用了个极速网速差的很
- - episode_done: true
id: lccc
labels:
- 干完这一票我的会员等级就要升了!
text: 咬咬牙这回要全入了!
x_turn:
id: partner1
text: 咬咬牙这回要全入了!
y_turn:
id: partner2
text: 干完这一票我的会员等级就要升了!
- - episode_done: true
id: lccc
labels:
- 代表了哪里的普通人?
text: 记得还…我们普通人要搬三天砖才赚来的20元
x_turn:
id: partner1
text: 记得还…我们普通人要搬三天砖才赚来的20元
y_turn:
id: partner2
text: 代表了哪里的普通人?
- - episode_done: true
id: lccc
labels:
- 好得差不多啦
text: 早点好起来啊。生日快乐
x_turn:
id: partner1
text: 早点好起来啊。生日快乐
y_turn:
id: partner2
text: 好得差不多啦
num_episodes: 6820506
num_examples: 8869637
30 changes: 30 additions & 0 deletions parlai/tasks/lccc/test/lccc_valid.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,55 @@ acts:
- 那个饭凉了吧唧的怎么吃啊摔
id: lccc
text: 啊我好爱虾仁蛋黄酱金枪鱼蛋黄酱
x_turn:
id: partner1
text: 啊我好爱虾仁蛋黄酱金枪鱼蛋黄酱
y_turn:
id: partner2
text: 那个饭凉了吧唧的怎么吃啊摔
- - episode_done: true
eval_labels:
- 看了下全文,那女的考试当天就表明身体不舒服了,考试不是她预约是教练自己安排的,教练还让她考试不就是教练的错吗?而且她住院花了31万,赔30万不过分吧
id: lccc
text: 考试撞墙关驾校屁事?你怎么不顺便把考场施工单位也告了?
x_turn:
id: partner1
text: 考试撞墙关驾校屁事?你怎么不顺便把考场施工单位也告了?
y_turn:
id: partner2
text: 看了下全文,那女的考试当天就表明身体不舒服了,考试不是她预约是教练自己安排的,教练还让她考试不就是教练的错吗?而且她住院花了31万,赔30万不过分吧
- - episode_done: true
eval_labels:
- 好好好,偶遇我大闺蜜
id: lccc
text: 我先去穿衣服,准备走了
x_turn:
id: partner1
text: 我先去穿衣服,准备走了
y_turn:
id: partner2
text: 好好好,偶遇我大闺蜜
- - episode_done: true
eval_labels:
- 保存一下
id: lccc
text: 期待小猎豹的表现
x_turn:
id: partner1
text: 期待小猎豹的表现
y_turn:
id: partner2
text: 保存一下
- - episode_done: true
eval_labels:
- 给你一个么么哒
id: lccc
text: 为了你们新年有惊喜,我也是用心良苦了
x_turn:
id: partner1
text: 为了你们新年有惊喜,我也是用心良苦了
y_turn:
id: partner2
text: 给你一个么么哒
num_episodes: 20000
num_examples: 25558
7 changes: 7 additions & 0 deletions parlai/tasks/light_multiparty/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Task: Multi-party chat in LIGHT
================

Multi-party async conversation between 3 role-playing characters.
For more information, please see our projects page: https://parl.ai/projects/multilight.

Tags: #All, #ChitChat, #LIGHT
5 changes: 5 additions & 0 deletions parlai/tasks/light_multiparty/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env python3

# Copyright (c) Facebook, Inc. and its affiliates.
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
Loading