Python Forum
How to add multiple lines response in chatterbot?
Thread Rating:
  • 1 Vote(s) - 2 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to add multiple lines response in chatterbot?
#8
Well, as I said, the code I posted expects a format from the input file more or less like:
  • Each entry will start by a character different to white space
  • Any line that starts with white space will be concatenated to the previous one

So you need to format your input files following this rules (you can -and shall- improve them, your input, your rules... make them practical for you) but if I format your example:
Output:
What are some common warning signs of stress and/or depression in men? General signs of stress: Fast heart rate Muscle tension Increase in blood pressure Tense stomach Long-term signs of stress: Frequent cold or flu Headaches Trouble sleeping Skin problems Digestion problems Poor concentration Negative thoughts Speech problems Anxiety Irritability Feelings of helplessness Poor eating Being accident prone Aggression.
Notice the blanks indenting the text
The array conv will have only 3 lines.
Reply


Messages In This Thread
RE: How to add multiple lines response in chatterbot? - by killerrex - May-17-2018, 10:41 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Amazon AWS - how to install the library chatterbot wpaiva 9 3,930 Feb-01-2020, 08:18 AM
Last Post: brighteningeyes
  Scrape multiple lines with regex greetings 2 3,075 Jul-04-2018, 09:09 PM
Last Post: snippsat

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020