The $250 Conversation - Chatbots in Healthcare
By: Mike McKenzie
Recently I challenged some programmers to embed Snatchbot.me in their health apps. Manish Verma took up the challenge as did a few others who asked not to be named. One app integrated google maps to a provider directory, another used natural language processing to interview patients for past medical hx and another put user responses in JSON format that loosely resembled a CCD file used for communication of clinical data. Excited does not describe the feeling I got from seeing tangible results delivered so quickly.
Apparently the excitement was contagious because the CEO of RightMovesResources (RMR) asked me how he could integrate a Chatbot on his company's senior care website. I offered to build it and hand the keys over in exchange for his permission to share the details of how I did it with you. Hopefully this will inspire you to get your providers office, hospital, clinic or EMR embedded with this technology. Your users and site visitors will thank you for it.
How much and how long will it take to build the Chatbot? To answer we needed a scope so I asked RMR CEO to put a framework together of what he envisioned for this Chatbot (PM me for a copy). A 5 minute review and one conversation later we had our answers. $250, this bought 2 hours and 5 minutes to review, build, test and obtain client sign off. I had soo much fun doing this I didn't charge for deployment which was a 30 minute webex showing him where to paste the code on their squarespace host.
In somewhat linear fashion I've posted considerations and steps to building the RMR bot below:
HIPAA - HIPAA really bring out the nasty in some people. I call it the HIPAA switch-Mention healthcare and technology in the same sentence and out comes the wagging finger. So, before we get the finger in our comments below lets address this now! Snatchbot's support confirmed their solution is hosted on Amazon AWS across 2 availability zones. Amazon provides a HIPAA compliant environment and if you need to know more than that you can lookup and read Amazon's whitepaper titled "Creating HIPAA-Compliant Medical Data Applications with AWS" or you can PM and I can try to explain it.
SOC2 Compliance --- If you don't know what this is don't worry because Amazon meets the requirement and you can confirm that in their trust center. If you need more information PM me and I can try to explain it further or better yet, ask your CPA.
Setting up Email for Snatchbot.me --- Created a google account for RMR and registered on snatchbot.me using it. The only issue here was I wanted Derek, the CEO at RMR to own the gmail address so it took some coordination when validating the account on his cell phone.
Signing up on Snatchbot.me --- Using the [email protected] account I signed Derek up for a free account on snatchbot.me. All accounts are free but pricing tiers exist if you want to white label a Chatbot or handle more than 10,000 conversations per month.
Discussing the RMR Chatbot --- Derek basically wanted the Chatbot to sit on every page of his company's website. Each topic had its own button a user could select to drill down and answer relevant questions. Responses would be summarized for the user at the end to validate and change before sending to a log file on the Snatchbot.me server. To get things ready I logged in>navigated to My Bots>Clicked Create Bot and named it RMR Bot.
Designing the RMR Chatbot --- The design was super basic. Each interaction or conversation the Chatbot has with a user is tied to an interaction tile. These tiles are linear but the tool has a nice visual map feature that lets you spot check your logic flows. As you create your interaction tiles each name must be unique. To simplify things I prefixed the topic name to its respective tile followed by the information it captured. For example, the topic of Senior Living Options for question 1 was titled SeniorLivOpt_Q1 followed by SeniorLivOpt_Q2 etc.
Designing each Interaction Tile --- Most interaction tiles had predefined buttons I created that the user could select. For example, are you looking at senior care options for your self or a loved one had a tile created that said SELF and another that said LOVED ONE. If the user clicked either button the tile was configured to log the response and move to the next question. If the user typed neither or I don't know the system would offer to let them start the conversation over. For questions that required a text response I simply set the logic in the very easy to use GUI to accept the value and move to the next tile provided the response did not being with an ^ symbol.
Reusing Interaction Tiles --- For things like NAME, EMAIL I created single tiles, placed them at the bottom of the line of interaction tiles and referenced them across each topic in one to many fashion. So Veterans Benefits, Senior Living Options etc. all referenced to those single contact information tiles rather than doing one for each topic.
Summing up a conversation --- Snatchbot lets you sum up your responses using some very basic code. If you wanted an interaction tile to show responses from specific tiles you would simple post in a line of code like this - [responseTo interaction=307640 fallback=NONE]. If that referenced the Loved one or self question you would see the summary page I created showing a line saying Loved One or Self?: followed by the response. If there was no response to the interaction then NONE would default in after the Loved One or Self?.
Testing a conversation --- Snatchbot lets you test your conversation as you are building it. Simply clicking test this bot will activate your bot in a sandbox to fully test its functions. As I built out each topic it was very helpful to check the fidelity of the conversation and make tweaks ad hoc.
Publishing your bot --- there are bunch of ways Snatchbot allows you to do this but we just did a Web Channel. For RMR - we selected Channel, Enabled the Channel, Navigated to Get Embed Code and pasted the Chatbot code into the RMR website. When you visit the site you will see that we configured the Chatbot to pop up as soon as you arrive. See here: www.rightmoveresource.com
Polishing up your bot --- RMR wanted visitors to readily know the intent of the bot so we created an icon that said 'How can we help you?'. Every time a user visits the site the Chatbot button how may we help you hovers in the bottom right of the screen for a user to click. Best of all it renders on mobile the same. Further, you can name the Chatbot who is communicating with the website visitor. In this case we named it Derek.
Upgrades and Costs for the bot --- White labeling the Chatbot was not important to RMR but ensuring it can handle the volume of inquiries coming off their site is. As mentioned above Snatchbot.me offers a paid tier that basically does 2 things over the free version. It removes the 'powered by' icon and increases the available responses to 10K or greater. It does this per bot which is good and bad. Good because you can allocate those 10K uses to your live bot but bad because you can't pay the $30 fee for one bot and share the 10K allocation with another.
Bot Limitations --- Be aware of this! I created a bot with about 250 interactions and when I launched Amazon's Elastic Cloud that serves it must have ripped because the solution appeared to hang up. There could be a myriad of reasons for this so if you are concerned enough about it then consider asking the snatchbot support via their forum.
Bot on Bot Crime --- Its real, it happens and I'm told a lot of it comes from overseas. A bot designed to test or penetrate a website will grab hold of a form or Chatbot on your site and fill out every field multiple times looking for weaknesses. Unchecked- this can steal bandwidth and the number of submissions you have paid for. Snatchbot has done a good job defending against this but its worth discussing with a security expert as I've done before launching it to the general web.
I hope this quick overview inspires you to build a bot for your practice, hospital, clinic etc. This technology appears to hold great promise and with a little elbow grease you can use even more advanced features than I did such as API level integration, integration of vocabularies like SNOMED, RxNorm, LOINC etc. So get creative, get going and most importantly get a pat on the back for not breaking the bank!
Lead Software Developer | Technical Project Manager | Business Analyst
6 年Awesome Mike!
Web app(Python, Django, angular) and mobile app(ionic) development company
6 年Great article!
Mike, thanks for writing this great article. Just want to say here that your detailed analysis on AI has given me wings to integrate many features that I have been thinking of integrating in my product with certain interactive mode. I am integrating Uber, payment gateways, etc API's on my product using AI/ML now which is bringing totally different dimensions to product features for end user perspective. Will show you Product demo shortly. Big thank you to you once again. Thanks Manish
Ophthalmologist at the Veteran Affairs North Texas Health Care Medical Center, Primary Investigator-"Regional Vitamin K Content of the Human Eye: A Pilot Study"
6 年Really great article, well worth the read.
Ophthalmologist at the Veteran Affairs North Texas Health Care Medical Center, Primary Investigator-"Regional Vitamin K Content of the Human Eye: A Pilot Study"
6 年Awesome, very useful and great post. Thanks!