slots: brand_list: type: list category_name: type: text city_name: type: text deal_list: type: list name: type: text responses: utter_greet:
- text: Hello! How can I help? utter_ask_city:
- text: Tell me your City? utter_ask_category:
- text: Tell me the category to show you the related brands? utter_goodbye:
- text: Talk to you later.
- text: Bye bye
utter_ask_brand:
- text: Tell me your favourite brand? utter_list_of_deals:
- text: ‘Here are the list of deals:’
- text: “{deal_list}\n\n” utter_list_of_brands:
- text: “{brand_list}\n”
-----This is where i am returning the list
-----This is my list code
for i in range(0, len(brand_response_json["data"][0]["result"])):
title = brand_response_json["data"][0]["result"][i]["offer"][0]["title"]
sub_title = brand_response_json["data"][0]["result"][i]["offer"][0]["sub_title"]
offer_description = brand_response_json["data"][0]["result"][i]["offer"][0]["offer_description"]
print("Deal {} name is: ".format(count) + title)
response_title ="Deal {} name is: ".format(count) + title
list_of_deals.append(response_title)
count = count + 1
if sub_title == "":
print(end='')
response_sub_title = end=''
else:
print("Offer on this deal is: " + sub_title)
response_sub_title = "Offer on this deal is: " + sub_title
list_of_sub_titles.append(response_sub_title)
print("Offer description on this deal is: " + offer_description + "\n")
response_offer_description = "Offer description on this deal is: " + offer_description + "\n"
list_of_deals.append(response_offer_description)
This is the output which was coming