Ejemplo n.º 1
0
    def __init__(self, act):
        # parsed is a dict of lists. 'slots' list contains dact items
        parsed = dact._InParseAct(act)
        self.act = parsed['act']
        self.items = parsed['slots']

        self.prompt = None
Ejemplo n.º 2
0
 def __init__(self, act):
     if isinstance(act, DiaAct):
         if isinstance(act, DiaActWithProb):
             self.act = copy.deepcopy(act.act)
             self.items = copy.deepcopy(act.items)
             self.P_Au_O = act.P_Au_O
         else:
             self.act = copy.deepcopy(act.act)
             self.items = copy.deepcopy(act.items)
             self.P_Au_O = 1.0
     else:
         dia_act = dact._InParseAct(act)
         self.act = dia_act['act']
         self.items = dia_act['slots']
         self.P_Au_O = 1.0
Ejemplo n.º 3
0
 def __init__(self, act):
     dia_act = dact._InParseAct(act)
     self.act = dia_act['act']
     self.items = dia_act['slots']
     self.P_Au_O = 1.0
Ejemplo n.º 4
0
 def __init__(self, act):
     # parsed is a dict of lists. 'slots' list contains dact items
     parsed = dact._InParseAct(act)
     self.act = parsed['act']
     self.items = parsed['slots']
Ejemplo n.º 5
0
 def __init__(self, act):
     dia_act = dact._InParseAct(act)
     self.act = dia_act['act']
     self.items = dia_act['slots']
     self.P_Au_O = 1.0