示例#1
0
agent_params['agent_act_level'] = params['act_level']

agent_params['experience_replay_pool_size'] = params['experience_replay_pool_size']
agent_params['dqn_hidden_size'] = params['dqn_hidden_size']
agent_params['batch_size'] = params['batch_size']
agent_params['gamma'] = params['gamma']
agent_params['predict_mode'] = params['predict_mode']
agent_params['trained_model_path'] = params['trained_model_path']
agent_params['warm_start'] = params['warm_start']
agent_params['cmd_input_mode'] = params['cmd_input_mode']


if agt == 0:
    agent = AgentCmd(course_kb, act_set, slot_set, agent_params)
elif agt == 1:
    agent = InformAgent(course_kb, act_set, slot_set, agent_params)
elif agt == 2:
    agent = RequestAllAgent(course_kb, act_set, slot_set, agent_params)
elif agt == 3:
    agent = RandomAgent(course_kb, act_set, slot_set, agent_params)
elif agt == 4:
    agent = EchoAgent(course_kb, act_set, slot_set, agent_params)
elif agt == 5:
    agent = RequestBasicsAgent(course_kb, act_set, slot_set, agent_params)
elif agt == 9:
    agent = AgentDQN(course_kb, act_set, slot_set, agent_params)
    
################################################################################
#    Add your agent here
################################################################################
else:
示例#2
0
agent_params['agent_act_level'] = params['act_level']

agent_params['experience_replay_pool_size'] = params[
    'experience_replay_pool_size']
agent_params['dqn_hidden_size'] = params['dqn_hidden_size']
agent_params['batch_size'] = params['batch_size']
agent_params['gamma'] = params['gamma']
agent_params['predict_mode'] = params['predict_mode']
agent_params['trained_model_path'] = params['trained_model_path']
agent_params['warm_start'] = params['warm_start']
agent_params['cmd_input_mode'] = params['cmd_input_mode']

if agt == 0:
    agent = AgentCmd(kb, act_set, slot_set, agent_params)
elif agt == 1:
    agent = InformAgent(kb, act_set, slot_set, agent_params)
elif agt == 2:
    agent = RequestAllAgent(kb, act_set, slot_set, agent_params)
elif agt == 3:
    agent = RandomAgent(kb, act_set, slot_set, agent_params)
elif agt == 4:
    #agent = EchoAgent(kb, act_set, slot_set, agent_params)
    agent = RequestInformSlotAgent(kb, act_set, slot_set, agent_params,
                                   movie_request_slots, movie_inform_slots)
elif agt == 5:  # movie request rule agent
    agent = RequestBasicsAgent(kb, act_set, slot_set, agent_params,
                               movie_request_slots)
elif agt == 6:  # restaurant request rule agent
    agent = RequestBasicsAgent(kb, act_set, slot_set, agent_params,
                               restaurant_request_slots)
elif agt == 7:  # taxi request agent
示例#3
0
agent_params['agent_act_level'] = params['act_level']

agent_params['experience_replay_pool_size'] = params[
    'experience_replay_pool_size']
agent_params['dqn_hidden_size'] = params['dqn_hidden_size']
agent_params['batch_size'] = params['batch_size']
agent_params['gamma'] = params['gamma']
agent_params['predict_mode'] = params['predict_mode']
agent_params['trained_model_path'] = params['trained_model_path']
agent_params['warm_start'] = params['warm_start']
agent_params['cmd_input_mode'] = params['cmd_input_mode']

if agt == 0:
    agent = AgentCmd(movie_kb, act_set, slot_set, agent_params)
elif agt == 1:
    agent = InformAgent(movie_kb, act_set, slot_set, agent_params)
elif agt == 2:
    agent = RequestAllAgent(movie_kb, act_set, slot_set, agent_params)
elif agt == 3:
    agent = RandomAgent(movie_kb, act_set, slot_set, agent_params)
elif agt == 4:
    agent = EchoAgent(movie_kb, act_set, slot_set, agent_params)
elif agt == 5:
    agent = RequestBasicsAgent(movie_kb, act_set, slot_set, agent_params)
elif agt == 9:
    agent = AgentDQN(movie_kb, act_set, slot_set, agent_params)

################################################################################
#    Add your agent here
################################################################################
else: