convlab2.task.crosswoz package

Submodules

convlab2.task.crosswoz.attraction_generator module

class convlab2.task.crosswoz.attraction_generator.AttractionGenerator(database)

Bases: object

generate(goal_num=0, exist_goal=None, random_seed=None)

convlab2.task.crosswoz.goal_generator module

usage: from convlab2.task.crosswoz.goal_generator import GoalGenerator GoalGenerator.generate()

class convlab2.task.crosswoz.goal_generator.CrossDomainGenerator(database)

Bases: object

generate(exist_goal)
generators

transfer probabolity matrix [hotel attraction restaurant] to [do-not-trans hotel attraction restaurant]

class convlab2.task.crosswoz.goal_generator.GoalGenerator

Bases: object

static generate()
class convlab2.task.crosswoz.goal_generator.SingleDomainGenerator(database, domain_index=None)

Bases: object

generate(multi_target=False)
convlab2.task.crosswoz.goal_generator.call_count()
convlab2.task.crosswoz.goal_generator.cross_domain_ratio(all_goal_list)
convlab2.task.crosswoz.goal_generator.domain_count(all_goal_list)
convlab2.task.crosswoz.goal_generator.generate_method(database_dir, single_domain=False, cross_domain=False, multi_target=False, transportation=False)

single_domain: 单领域生成还是多领域单独生成 cross_domain: 是否需要跨领域跳转 multi_target: (单个领域内)是否多目标 transportation: 是否进行出租、地铁生成

convlab2.task.crosswoz.goal_generator.generate_sentence(goal_list=[])
convlab2.task.crosswoz.goal_generator.load_json(database_dir, filename)
convlab2.task.crosswoz.goal_generator.method_split(all_goal_list)
convlab2.task.crosswoz.goal_generator.num_count(all_goal_list)
convlab2.task.crosswoz.goal_generator.total_count(all_goal_list)

convlab2.task.crosswoz.hotel_generator module

class convlab2.task.crosswoz.hotel_generator.HotelGenerator(database)

Bases: object

generate(goal_num=0, exist_goal=None, random_seed=None)

convlab2.task.crosswoz.metro_generator module

class convlab2.task.crosswoz.metro_generator.MetroGenerator

Bases: object

generate(goal_list, goal_num, random_seed=None)

convlab2.task.crosswoz.reorder module

reorder generated goals

convlab2.task.crosswoz.reorder.goals_reorder(goal_list)

convlab2.task.crosswoz.restaurant_generator module

class convlab2.task.crosswoz.restaurant_generator.RestaurantGenerator(database)

Bases: object

generate(goal_num=0, exist_goal=None, random_seed=None)

convlab2.task.crosswoz.sentence_generator module

class convlab2.task.crosswoz.sentence_generator.SentenceGenerator

Bases: object

generate(goals, random_seed=None)

convlab2.task.crosswoz.taxi_generator module

class convlab2.task.crosswoz.taxi_generator.TaxiGenerator

Bases: object

generate(goal_list, goal_num, random_seed=None)

Module contents