Tuesday, July 28, 2020

Running Bot Libre on Amazon EC2 using the Bot Libre Community Edition AMI

You can host your own server running the Bot Libre platform using Amazon EC2. Bot Libre provides a free AMI (Amazon Machine Image) that makes it easy to install and configure the open source Bot Libre Community Edition platform.

The EC2 instance can be launched from either the AWS Marketplace page or the EC2 page.

Launching from the AWS Marketplace:

  1. Search the AWS Marketplace for the Bot Libre Community Edition AMI, and open the page.
  2. Click on "Continue to Subscribe".
  3. Read the Terms and Conditions, and click on "Continue to Configuration".
  4. Select the latest software version, and any region of your choosing. Then, click on "Continue to Launch".
  5. Under "Choose Action", select "Launch through EC2", and click on "Launch". This will take you to the EC2 configuration page.

Launching from the EC2 home page:

  1. Click on "Launch Instance".
  2. Select the "AWS Marketplace".
  3. Search for the Bot Libre Community Edition AMI.
  4. Select it, and click on "Continue". This will take you to the EC2 configuration page.

EC2 configuration:

  1. Select an instance type of your choosing. We recommend having 8 GB of RAM at minimum (e.g. t3a.large). Click on "Next: Configure Instance Details".
  2. Configure your instance details, and click on "Next: Add Storage".
  3. The amount of storage required depends on the amount of content your users will generate. The size of the storage volume can be modified later, if required. Once you have the storage configured, click on "Review and Launch".
  4. Review the instance details, and click on "Lanch".
  5. Select an existing key pair or create a new key pair. This will be used to connect to the instance via SSH.

Retrieving the admin password:

  1. Go to the EC2 Instances page, and find the Public DNS or Public IP of the Bot Libre instance. Note that the DNS and IP will not persist if the instance is stopped.
  2. Copy the DNS or IP into a web browser to load the Bot Libre home page. It can take up to 3 mins for the page to load when launching for the first time.
  3. Once the webpage has loaded for the first time, connect to the instance with SSH using either the DNS or the IP. To log in, use "centos" as the username and use the key you selected during the EC2 configuration. For more information on connecting to an EC2 instance, see this page: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AccessingInstances.html.
    • To get the admin password, use the following command:
    • $ sudo cat /usr/local/tomcat8/logs/catalina.out | grep "ADMIN PASSWORD" 
    • This password will only be available the first time the instance is run.
  4. Log in to Bot Libre on your web browser by using the username "admin" and the password you have just retrieved.

For more information on the Bot Libre Community Edition see Bot Libre Community Edition

Tuesday, July 21, 2020

Running the Bot Libre platform on-premise using Docker

The Bot Libre Community Edition web platform is now available as a Docker container. This means that getting Bot Libre up and running on your server has never been easier!

What is Docker?

Docker is a platform that allows you to run “containers” using OS level virtualization. A container is a software package that is bundled with its required libraries and configuration, so you do not have to perform any additional configuration/installation yourself.

Software You Will Need:


Before starting up the server, make sure to set up your firewall correctly for Bot Libre.

Bot Libre Community Edition requires the following ports to be open:

  • 80 – HTTP
  • 443 – HTTPS
  • 25 – SMTP
  • 465 – SMTPS
  • 110 – POP3
  • 995 – POP3S
  • 143 – IMAP
  • 993 – IMAPS
  • 6665 – IRC

The procedure for how to set up the firewall depends on the firewall you are using. For example, an Amazon EC2 instance would use security groups. For a typical Linux server, iptables can be used.

Deploying Bot Libre using Docker Compose:

First, you will need to download the docker-compose.yml file from our GitHub.

This can be done with the following command:

To build and create the containers for Bot Libre, run the following command:

  • $ sudo docker-compose up --no-start

Running Bot Libre using Docker Compose:

To start the containers, run the following command:

  • $ sudo docker-compose start

To gracefully stop the containers, run the following command:

  • $ sudo docker-compose stop

To view the logs, run the following command:

  • $ sudo docker-compose logs

If you need to run bash on the Tomcat web server container (app-web), first get the name of the container with this command:

  • $ sudo docker ps

Then, use the following command with the container name:

  • $ sudo docker exec -it container_name bash

Friday, June 26, 2020

How to create your own special event bot

Chatbots are an exceptional way to grab users attention for your next special event. They can register and inform people through the web, via email, or even with social media.

To create your own special event bot, first head to Bot Libre or Bot Libre for Business.

Here you'll want to sign up for a new account, and then click on the "Bots" icon at the top of the screen.

Select "New Bot", give your bot a name, and then set the template to special_event_bot. 

Click create and we're almost done!

At this point you've created a bot, but they still have generic special event responses. Let's change that.


Select the Admin box and navigate to the Training & Chat Logs page.

Here you can handle greetings, responses, all the way up to more the advanced topics like conversation flows or Facebook accounts all with a few clicks!

To get you started have a chat with our demo special event bot

If you encountered any issues, or would like help setting up your bot please email us at support@botlibre.com or upgrade to our Platinum service and we can build your bot for you.

Friday, March 13, 2020

Searching Twitter tweets by location

Bot Libre allows to you connect your bot with a Twitter account. This allows you to automate interactions with your community, or automate the posting of information. For a tutorial on creating a Twitter bot see:


Always ensure you comply with Twitter's terms of service and automation rules,


Bot Libre's Twitter integration includes support for auto replies to mentions or direct messages to your bot, auto retweeting, Tweet search, auto replies, and auto posts.  The Tweet search feature allows your bot to search for tweets on Twitter to process with its rules.

In your bot's Admin Console on its Twitter page you can configure your Twitter bot's rules. One option is the "Tweet Search", this allows you to enter multiple Twitter search queries (each on a new line).  A Twitter search can contain a list of keywords, but can also include many other commands, for a full list see,


One option is geo location. This lets you search tweets by location.

For example to queries all tweets on the #chatbots hashtag in the USA you can use:

#chatbots geocode:39.8,-95.583068847656,2500km

To use geocode you need to know the coordinate of the city or location you are interested in. Here is a good website to get the coordinates for a place:


For more geo location examples see:


Tuesday, December 17, 2019

Announcing Bot Libre 8, now open source!

We have released Bot Libre 8!

The worlds most advanced bot platform just got better. Bot Libre 8 is a free and open source platform for developing and hosting bots. Bot Libre 8 includes support for chatbots, virtual agents, virtual assistants, social media bots, SMS bots, IVR bots, IOT bots, game bots, live chat, animated avatars, speech, deep learning analytics, and more. Bot Libre supports bots for the web, mobile, Facebook, Twitter, Skype, Telegram, Kik, WeChat, Slack, email, SMS, IVR, Alexa, Google Home, IRC, and new platforms are being added every month.
The Bot Libre 8 web platform is now open source, download now to host your own bot server. Host on your own server on-premise, or on your own cloud instance on any cloud platform such as Amazon EC2, or Microsoft Azure.

"Bot are the new apps".

Chat and chatbots are the new application paradigm that is replacing mobile and web as the new leading method of engaging your customers and users. Chat lets you engage your customers everywhere, on web, mobile, social media, phone, and on the Internet of things.

Bot Libre lets anyone create a bot for the web, mobile, social media, phone, and the Internet of things. Connect your bot to Twitter, Facebook, Telegram, Skype, Kik, Slack, WeChat, email, SMS, IVR, Alexa, Google Home, and more.

Bot Libre 8 supports rich HTML responses including buttons, links, choices, images, video, and audio. Bot Libre supports HTML responses on the web, mobile, and automatically maps HTML to social media platforms.

Bot Libre bots can be trained using natural language, chat logs, response lists, Twitter feeds, AIML, and scripting. Responses are automatically matched using a heuristic artificial intelligence algorithm and does not require any programming. Responses can also use keywords, topics, required words, labels, repeats, and other meta data.

Bot Libre 8 supports programming and scripting your bot using AIML 2, and Self. Self is our own dialect of JavaScript. Self is an object oriented scripting language, and integrated with an object database. Self extends JavaScript to provide support for natural language processing, state machines, object persistence, and includes a class library for accessing web services and utilities. Self also supports all AIML 2 operations, and some aspects of ChatScript patterns.

Bot Libre 8 is more than just bots, but a complete artificial intelligence platform. Bot Libre lets you create deep learning analytics for image recognition, speech and audio recognition, object detection, prediction and data analysis. You can create and train an image recognition analytic without any programming, just by uploading images. You can then access your analytics through our web API and mobile SDK, or from your bot.

New features in Bot Libre 8.0 since 7.0 include:

  • The Bot Libre web platform is now open source, download now to host your own bot server
  • Interactive Voice Response, automate your voice phone call center
  • Redesigned Training & Chat Logs user interface
  • AIML Map, Set, and properties file import support
  • AIML compatibility option
  • Knowledge graph view
  • Redesigned user and bot messaging
  • NLP 4 - Bot Libre's NLP engine has been redesigned to make bots response's better, make training bots easier, and better support international languages
  • User profile avatars and friends (add bot's as your friend using @bot-name)
  • Updated support for Microsoft Speech
  • Analytic testing repository and test reports

Create your own free account and bot today on botlibre.com,
or let us build your bot for you on our commercial service Bot Libre for Business.
or download our open source platform to run on-premise on your own server

Monday, November 18, 2019

How To Connect A Bot to Microsoft Speech

Through Bot Libre, your bots may use Microsoft Speech for text-to-speech. This "How To" will give you a step by step process to connect your bot with Microsoft Speech.

Step 1 - Create a Bot

First you must create a bot that you want to connect to Microsoft Speech, or you can use one of your existing bots. To create a bot, follow the instructions here: How to create your own chat bot in 10 clicks.

Step 2 - Sign Up For Microsoft Account

Click the "Free Account" button to create an account, or sign in if you have an existing one.

Click the "Start Free" button to begin.

If you have an existing Microsoft or Skype account, you can sign in with that. Otherwise, click the "Create one!" link.

You will be asked to enter your email address. Click the "Next" button to continue when ready.

Enter a password to use with this account then click the "Next" button.

You will then need to verify your email address by entering a code that has been emailed to you. Click "Next" to continue.

You will now need to prove you are a human by entering a set of characters. Click "Next" when complete.

You will now need to confirm that the information you have just entered is still accurate. Click "Looks good!" to confirm.

On the next screen, confirm whether you want this account to remain signed in.

Step 3 - Sign Up For Microsoft Azure

You will now need to enter some personal information on the following form. When complete, click the "Next" button.

You will then need to verify your phone number and credit card information.

Once you have finished verifying your information, submit the form to continue.

Click the "Skip and continue to the Azure portal" button to continue.

Step 4 - Create Speech Resource on Azure Portal

You will now be taken to the Azure dashboard. Click the "+Create a resource" link on the left toolbar.

Type "speech" into the search bar and click the "Speech" option that appears in the dropdown.

Next, click the "Create" button on the following screen.

You will now need to fill out the following form. Enter a name and select a location. You will also need to select a pricing tier. For more information about which pricing tier to select, click here.

You will need to create a resource group if you do not already have one. Click the "Create new" link under the Resource group dropdown.

Enter a name for the resource group and press the "OK" button.

Click the "Create" button at the bottom of the form to continue.

It will take a few moments for your Speech resource to be deployed. When it is ready, your screen will appear as below.

Click the "Go to resource" button. You will be taken to the following screen.

Make a note of the URL listed in the step 2b above, "https://eastus.api.cognitive.microsoft.com/sts/v1.0/issuetoken" in this example. You will need URL for a later step.

Next, click on the "Keys" link in step 1 above.

Click on the button to the right of one of the keys to copy it to your clipboard. It does not matter which key you select.

Step 5 - Connect to your Bot Libre Bot

Return to the Bot Libre website and navigate to your bot's admin console by clicking on the gear icon in the bottom menu.

Next, click the "Voice" link.

Select "Microsoft Speech" from the "Speech Provider" dropdown.

Enter the API Key that you copied to the clipboard in the previous step into the "Microsoft Speech API Key" field.

Enter the URL noted from the previous step into the "Microsoft Speech API Endpoint" field.

Click the "Test" button to test that you have entered these values correctly. If you receive an error message, double check that you have entered the values correctly from the Azure portal.

Click "Save" when you are finished.

Your bot will now be speak using the Microsoft Speech voice that you have selected. If you encountered any issues, or would like help setting up your bot please email us at support@botlibre.com or upgrade to our Platinum service and we can build your bot for you.

Tuesday, November 12, 2019

How to Connect a Bot to Email and Gmail

Bot Libre allows a bot to be connected to email. This lets you create a bot to be your first tier of support or customer service for your business. The bot can answer common user questions and differ more difficult questions to your second tier support. Connecting a bot to email can also be used to let your bot send email notification from scripting, such as when a user wishes to escalate an issue from live chat. Email also provides a novel way to let people interact with your bot.

You can connect a bot to any SMTP, POP3, or IMAPS email account, such as Gmail. Connecting a bot to email can allow the bot to read and reply to email messages, and can let the bot send email from scripting. This post will show you step by step instructions on how to connect your bot to a Gmail account.

Step 1 - Create Bot

First you must create the bot that you want to connect to Gmail, or you can use one of your existing bots. To create a bot, follow the instructions here: How to create your own chat bot in 10 clicks.

Step 2 - Connect Bot to Email Account

In the admin console page of your bot click on "Email" link. This will take you to your bot's "Email" settings page.

Step 3 - Configure Email Settings

In the "Email" text input field enter the Gmail email address. In the "User" text input field enter the same email as above. In the "Password" text input field enter the password that you use to login to this email address.

A bot can be connected to an email account in two ways. The bot can either just use the email account to send messages (such as a script that escalates issues through email), or the bot can check for new messages and reply to all messages. If you want your bot to reply to new messages, enable "Reply to Email" check box. Then click save.

Upon successful user credentials authentication you should see the following message at the top of the page.

Note, if there is a problem with connecting your bot to gmail, then at the top of the "Email" page you will see a message highlighted in red colour. At this point go to Step 5 and adjust your email settings.

Step 4 - Test your bot to email replies

In the "Test Email" text input field enter an email to which you want your bot to send message to and click "Test" button. At this point you should see a new "test" message appear in your email.

To test bot's reply to any new messages in your user email account, first send a new message to user@gmail.com account from another account. At this point your user@gmail.com account has a new message. Since the "Reply to Email" check box is enabled there should be grey "Check Email" button to the right of yellow "Disconnect" button. Click on "Check Email" button. At this point the bot will send a reply message to an email that originated the original message.

Note, be careful. Since the "Reply to Email" check box is enabled, the bot will reply to all the new email coming in to the user@gmail.com account. How often the bot checks it messages depends on your account level. For a Bot Libre for Business account the bot will check its email about every 5 minutes. For a Basic Bot Libre account the bot will only check its email once per day.

To disconnect a bot from user@gmail.com account, click on yellow "Disconnect" button. At this point your bot is no longer connected to user@gmail.com account and will not reply to any new messages.

Step 5 - Configuring Gmail Account Settings

By default Gmail does not allow external apps to access an email account. You must enable a few settings in Gmail to enable this.

Sign in to you gmail account. Then click on settings icon and choose settings from the drop down. Then select "Forwarding and POP/IMAP. Make sure "IMAP access" is enabled. Click on "Save Changes" button at the bottom for changes to take effect.

In addition, make sure that you gmail account has "Less Secure Apps" option enabled. For this follow this link Less secure apps access.

Click on option (1) under Turn off "Less secure app access" and click the button to enable it as shown in the image below. At this point you should successfully connect you bot user@gmail.com account by clicking on "Save" button once again.

Your bot should now be able to send and receive email. Please ensure your bot does not spam.