Writing content for a personal chatbot is lot like interviewing yourself. Preferences, stats, interests — it’s like a sixth grader wrote a boring Q&A session. But if you are looking to create a virtual presence to represent You, coming across as realistic and useful is all about content content content.
Organizing your thoughts
I’m using Google Sheets to jot down input patterns and responses before I implement them in StephTheBot. Eventually this text will be AIML (Artificial Intelligence Markup Language), but I suspect I’m going to be going in circles for a while before I have a handle on the overall organization of content, so I want it to be easy to move around.
The Rosie bot I’m starting with has content for basic preferences, but since I’m going to be adapting her to StephTheBot as a representation of myself, I wanted to flesh out the language related to my opinions.
The convention for AIML is to use all caps in patterns that the bot will watch for. The (*) asterisk matches one or more words. AIML allows complex patterns of substitutions, loops, text reductions, synonyms and more, so it’s very helpful to plan out your content in order to identify where you’ll be able to take advantage of these structures.
In my rough notes above, you can see that all these question formats will be equivalent. Once implemented in AIML, asking “Do you enjoy Italian food?” will generate the same response as “How do you feel about Italian food?”
You can also randomize lists of the bot’s responses, adding a bit of variety to its personality. This is how I’m organizing responses regarding emotional state.
Bot planning 101
As you start creating your chatbot’s content, you’ll likely start running into some questions to think about. For example:
- Should my bot respond in full sentences? Consider the responses to “Do you enjoy Italian food?”: “Yes”, “Yes I do”, or “Yes I love Italian food”?
- How do I know what people are going to ask my chatbot? Who will be talking to it and what is its purpose?
- Is my bot a representation of me, or primarily its own identity? When asking StephTheBot if it likes Italian food, is her response a match to my preferences or a character I’ve created?
- How do I construct meaningful, grammatically correct sentences when I’m expecting unknown variables?
My recommendation is to just start writing content down into whatever form of organization works for you.
Chatbots lend themselves very well to iterative processes, and your bot will only get better over time as you and others interact with it.
Simple questions and responses are very easy to implement in AIML, and you can start from there!