I am trying to build a simple chat bot using Pythons's chatterbot.
I am training this bot with the help of ListTrainer.
I have created a txt file containing questions-answers.
Problem I am facing with it is that if answers contains multiple lines, bot includes only first line in response.
Can you please help me to solve this issue?
from chatterbot.trainers import ListTrainer
from chatterbot import ChatBot
bot = ChatBot('MyBot')
conv = open('chats.txt','r').readlines()
request = input('You:')
response = bot.get_response(request)
And sample of chat.txt file is as below-
What are some common warning signs of stress and/or depression in men?
1. General signs of stress: Fast heart rate, Muscle tension Increase in blood pressure, Tense stomach
2. Long-term signs of stress: Frequent cold or flu, Headaches Trouble, sleeping Skin problems