diff --git a/alex/applications/PublicTransportInfoCS/data/ontology.py b/alex/applications/PublicTransportInfoCS/data/ontology.py index fb837305..9926e076 100644 --- a/alex/applications/PublicTransportInfoCS/data/ontology.py +++ b/alex/applications/PublicTransportInfoCS/data/ontology.py @@ -116,6 +116,10 @@ 'system_informs', 'user_informs', ], + 'route_alternative': [ + # this is necessary to be defined as it is a state variable used by the policy and automatically added to + # the dialogue state + ], # not implemented yet 'transfer_stops': [ diff --git a/alex/applications/PublicTransportInfoCS/hdc_policy.py b/alex/applications/PublicTransportInfoCS/hdc_policy.py index 91a5cbbd..411a734d 100644 --- a/alex/applications/PublicTransportInfoCS/hdc_policy.py +++ b/alex/applications/PublicTransportInfoCS/hdc_policy.py @@ -419,12 +419,10 @@ def get_directions(self, dialogue_state, route_type='true'): departure_time = now if departure_time_rel not in ['none', 'now']: trel_parse = datetime.strptime(departure_time_rel, "%H:%M") - departure_time += timedelta(hours=trel_parse.hour, - minutes=trel_parse.minute) + departure_time += timedelta(hours=trel_parse.hour, minutes=trel_parse.minute) # absolute time else: - time_parsed = datetime.combine(now, - datetime.strptime(departure_time, "%H:%M").time()) + time_parsed = datetime.combine(now, datetime.strptime(departure_time, "%H:%M").time()) time_hour = time_parsed.hour now_hour = now.hour # handle 12hr time