conda env create -f environment.yml
Pazar, Aralık 09, 2018
Salı, Kasım 27, 2018
If you have installed CUDA, only to find it doesn't work, you may want to remove the software. There is no "uninstall" routine from Nvidia, but they kindly gave me the list of things to remove: Note that these instructions refer to the HDD:System/Library directory, and the HDD:Library directory, but you will find them all: (where HDD = name of your system disk)
Delete the following:
If you installed the tookits and samples, delete the following also:
Cuma, Ağustos 25, 2017
Salı, Mart 14, 2017
Once you've launched your chatbot on Messenger, what's next?
Last year, Facebook launched its newest marketing addition to the tech world, the bot. Although Facebook is not the only one to kickstart the new chatbot trend, it is currently seen as the most attractive platform thanks to its 1 billion active users a month, its integrated payment and advertising tools, and the ease with which marketers can develop bots via Messenger. However, once you’ve launched your chatbot on Messenger, what's next? As with any product, bots need to be promoted. To make your task easier, I’ve put together a chatbot marketing guide on how to best market your messenger bot.
Related: 10 Facebook Messenger Chatbot Marketing Expert Tips
Make your bot discoverable
Message button on Facebook page
Message button on your website
These embeddable buttons can be placed anywhere on your website, and once clicked on, will fire up a conversation with your chatbot either directly on your website or on the Messenger mobile app. The two plugins have been made available by Facebook and come in the form of a “Message Us” button and a “Send to Messenger” button. I’ll go into more detail about these in the “Facebook Plugins” section of this post.
Related: How to make your Chatbot Suck Less
Use bot stores as public listings.
Create a dedicated landing page for your bot.
Although you can search for bots on Facebook and bot listing sites, Google is still your best friend. Be sure to create a dedicated landing page for your bot that is optimized for search engines and includes a “Get in Touch” button that directly links to a conversation with your chatbot.
Share relevant, informative and creative content.
- Why did you create your bot?
- What makes it unique?
- What was the journey of its creation?
- Audio content
- Sharing files from time to time
- Adding call to action buttons that link back to your site, products, or services
Get familiar with CAO
Audience engagement with the brand
Audience profiles and geo location
Keywords in profiles
It is likely that if a consumer searches for a specific term, brands with those terms in their brand profile will be at the top of the search results. As with any SEO, it is essential to use the appropriate keywords in the right places. For example, titles, description, posts, hashtags, etc.
The “Message Us” plugin
The “Send to Messenger” plugin
- Make sure your bot is not annoying or spammy.
- Be sure that your bot will respond in a relevant, timely, and polite manner.
- Keep your chatbot focused on specific tasks, campaigns, products, or services.
Pazartesi, Mart 13, 2017
This article there have been some significant market updates which need to be considered. Google bought Api.ai and also released their own home-baked Cloud Natural Language API, Amazon introduced Amazon Lex – conversational API and Wit.ai is updating their Stories and making them even better.
Recent announcements of a bot framework for Skype from Microsoft and a Messaging Platform for Messenger from Facebook have transformed chat through a new platform. More and more developers are coming up with the idea to make their own bot for Slack, Telegram, Skype, Kik, Messenger and, probably, several other platforms that might pop up over the next couple of months.
Thus, we have a rising interest in the under-explored potential of making smart bots with AI capabilities and conversational human-computer interaction as the main paradigm.
In order to build a good conversational interface we need to look beyond a simple search by a substring or regular expressions that we usually use while dealing with strings.
The task of understanding spoken language and free text conversation in plain English is not as straightforward as it might seem at first glance.
Below we look at a possible dialogue structure and demonstrate how to understand the concepts behind advanced natural language processing tools. We also focus on the platforms that we can use for our bots today, including the API – LUIS from Microsoft,
Wit.ai from Facebook, Api.ai from
Assistant team Google, Watson from IBM and Alexa Skill Set, and Lex from Amazon.
Ready to build a conversational bot for your business, but confused with the variety of platforms?
A Dialogue Example
Let’s look at the ways we can ask a system to find ‘asian food near me.’ The variety of search phrases and utterances could look similar to this:
- Asian food near me please
- Food delivery place not far from here
- Thai restaurants in my neighborhood
- Indian restaurant nearby
- Sushi express places please
- Places with asian cuisine
But if we are curious enough, we can also ask Google Keyword Planner for other related ideas and extend our list by about 800 phrases related to the search term “asian food near me”. We use Keyword Planner for such tasks here because it is a great source of aggregated searches that users regularly perform in Google.
Of course, not all of this is directly related to the original search intent, asian food near me. Let’s say, however, that we want to create a curated list of Asian Food places; in this case we can see that the results are still highly relevant to the service that we want to provide to the users.
So therefore we can try to steer the conversation towards the desired ‘asian food’ topic with the help of questions and suggestions from the bot.
Consider the next dialogue examples and suggestions of ways to direct the conversation:
From the example above we see how a broad variety of utterances can be employed by the user for the purpose of finding food.
Also notice how users can say Yes and No during the dialogue for confirmation or decline of the suggested option.
It is clear that chatbots need some way of understanding the language and conversational phrases that are more sophisticated than just a simple text search by phrase or even regular expressions.
Dialogue Structure as NLP engineers see it
From the example above we can see that each expression from the users has the intent to take some action.
An Intent is the core concept in building the conversational UI in chat systems, so the first thing that we can do with the incoming message from the user is to understand its Intent. This means mapping a phrase to a specific action that we can really provide.
Along with the Intent, it’s necessary to extract the parameters of actions from the phrase. In the previous example with ‘asian food’, the words ‘nearby’ or ‘near me’ correspond to the current location of the user.
Parameters, also called entities, often belong to a particular type. Examples of entity types that are commonly supported in language understanding systems are:
- Enumeration (predefined list of named things)
Here are the basic representations of the Intent, Entities and Parameters, as well as Sessions and Contexts which we will discuss later.
A Session usually represents one conversation from beginning to end. An example of one session is when you order a flight from your starting point: ‘I need a flight to London’ (the intent), then through subsequent interactions (questions and answers) you get the information about a booked flight and finish the interaction.
For storing the intermediate states and parameters from previous expressions during the dialogue we usually use Context. We can think about context as a shared basket that we carry through the whole session and use as short term memory. For example, during the flight booking chat, we can store the intent BookFlight in a context and subsequently add other parameters (like FlightDates, FlightDestination, NumberOfStops or MinMaxPrice) from the conversation once we get them from the user.
Unlike a session we can have many contexts during one conversation that nest into one another. Let’s say, after the user expression that represents the BookFlight intent, we started a new context, BookFlightContext, which indicates that we are currently collecting all parameters needed for the booking.
After the question about flight dates, the user decides to request info from the calendar, thus expressing a new intent CalendarEvents, and starting a new context, CalendarEventsContext, that saves the state of user interaction during the dialogue about events in a calendar. The user can even decide to reschedule several events and write a short email to involved parties with apologies and a reason for rescheduling, thus creating another nested context object, NewEmailContext.
So some of the technical tasks of the chat bot app (or conversational agent) are:
- Understand the language in a plain text (or voice translated into text) as well as the Intent with Parameters.
- Process the Intent with Parameters and execute the next action to continue a dialogue with the user. (Result is a response or a subsequent question to continue the conversation by getting more data from the user and filling needed parameters in order to fulfill the action).
- Maintain the Context and its state with all parameters received during the single Session in order to get the required result to the user.
Next, we will look at how the available tools can help us with all of this.
Microsoft Language Understanding Intelligent Service (LUIS)
LUIS was introduced during this year’s Microsoft Build 2016 event in San Francisco, together with Microsoft Bot Framework and Skype Developer Platform, which can be used to create Skype Bots. In this article we leave aside Bot Framework and look at language understanding features from LUIS.
LUIS provides Entities that you can define and then teach to recognize a LUIS system from a free-text expression. There are also Hierarchical Entities that are helpful for recognizing different types or sub-groups. For instance, a FlightDate entity can have a ToDate and a FromDate which can be recognized separately.
Currently, there are limitations of up to 10 Entities of each type per application, which will be enough for a middle-size service.
Besides Intents and Entities, there is also the concept of Actions that can be triggered by the system once the Intent and all required parameters are present.
Moving closer to automatic language understanding and the acting upon completion of Intents with parameters, there is another feature called Action Fulfilment, which is currently present only in preview mode, but you can already play with it and plan for the future. The idea is that once we have an Intent the system can automatically execute predefined Channel Actions like GetCurrentWeather, GetNews or your own JsonRequest to an arbitrary API.
Dialogue support, which also presents only in a preview mode, can help us to organize the conversation and ask relevant questions to the user in order to fill in the missing parameters for the intent.
To train the model with different utterances, LUIS provides a Web interface where we can type an expression, see an output from the model, and make changes in labels or assign new intents. Additionally, LUIS stores all incoming expressions in the Logs section and provides semi-automatic learning features with Suggestion, where the system tries to predict the correct intents that are already present in the model.
Once we have the trained model, we can use the API to ask questions and receive intents, entities and actions with parameters for each expression as an input.
LUIS has the export/import feature for the trained model in a plain JSON with all expressions and markups for entities, which we can then repurpose in our code – or even substitute LUIS completely, if we decide later to build our own NLP engine.
Currently, LUIS is in beta and free to use for up to 100k requests per month and up to 5 requests per second for each account.
Next we will look at Wit.ai from Facebook.
Facebook Wit.ai Bot Engine
Wit.ai, an AI startup that aims to help developers with Natural Language Processing tasks through the API, was acquired by Facebook in January 2015. During the F8 conference in April, 2016, Facebook introduced a major update to their platform and rolled out their own version of Bot Engine that extends a previous intent-oriented approach to the story-oriented approach.
Building the conversation interfaces around story feels more natural and easier to follow than a separate intent string by the context variable. Under the hood, during the logic implementation, you still work extensively with the context and need to do all tasks required to maintain the conversation’s correct state.
In Wit.ai we can use Entities, Intents (it’s actually just a custom entity type here), Context and Actions concepts that together form the model based on Machine Learning, and statistics can be used later for understanding the language.
On the bot side, during the story definition, we can execute any action that we might need to fulfill the context, user action, and prepare data and/or states in the context. Effectively, the Wit.ai Converse API will resolve the user utterance and the given state into the next state/action of your system, thus giving you the tool to build a Finite State Machine that describes sequences of speech acts.
However, all actions are executed on our server, and Wit.ai just orchestrates the process and suggests the next call of state mutations based on the model that we’ve trained.
Everything, from understanding the user inputs to the training expressions and list of entities, is available through the extensive Wit.ai API.
Like other systems, Wit.ai provides a handy Inbox feature where you can access all incoming utterances from the users, and label them if they were not recognized correctly.
In one of the latest updates, Wit.ai introduced the chat UI for testing conversations so we can see steps that systems recognize, which helps during both the creation and the debugging of the model.
Wit.ai supports 50 different languages including English, Chinese, Japanese, Polish, Ukrainian and Russian.
Projects can be Open or Private, without any apparent limitations. Open projects can be forked and you can create you own version of the model on top of existing community projects.
The Wit.ai API is completely free with no limitations on request rates, thus it is a good choice for your next bot experiments.
Wit.ai is continuously pushing new features and capabilities. Since the release of the first version of this article they’ve make a better builder for the Stories and added support for Quick Replies, Branches (if/else) and Jumps in Stories which is great for describing complex flows.
Api.ai – conversational UX Platform
To give you a better understanding of how API is different from other platforms, here is the answer their CEO gave on Product Hunt:
Indeed, the service provides all the features you might expect from a decent conversational platform including support of Intents, Entities, Actions with parameters, Contexts, Speech to Text and Text to Speech capabilities, along with machine learning that works silently and trains your model.
Everything starts from Agents that represent the model and rules for your application.
The interesting thing is that API.ai has built-in domains of knowledge (Intents with Entities and even suggested Replies) on topics like small talk, weather, apps and even wisdom. It means that your new Agent on the system can recognize these Intents without any additional training – and even provide you with the response text which you can use as the next thing your bot will say. There are up to 35 different domains with full English support and partial support for the other six languages.
When you create an Intent, you directly define which Context the Intent should expect and produce as a result. You can also define several speech responses which an agent will return to your app through the API, so you don’t even need to store such variations in your app.
Api.ai provides integrations with different bot platforms including Slack, Facebook Messenger, Kik, Alexa and Cortana.
For example, you can build the conversational flow completely on the platform and then deploy it automatically on Heroku, or use a pre-built Docker container with the app.
There is also an embedded integration mode available so you can have an agent that works without connection to the internet and is independent from any API. Just think about use cases like embedded hiking assistants or in-car assistants.
Api.ai looks like a decent solution that you can use for building sophisticated conversational interfaces. Like LUIS-beta from Microsoft or Wit.ai from Facebook, it’s Free with a limitation in bandwidth and speech recognition feature, though Preferred plan without limitation is also available by request.
Well, Google have bought Api.ai since the first version of this article. Good for the founders, but this means the community has lost the powerful independent NLP service, although a couple of other startups are emerging from the stealth mode.
Amazon Alexa Skill Set
It only works with Amazon Alexa. At first glance, this looks like the simplest language processing algorithm available among all other systems, but it’s deployed, tested and exposed to more than 3 million Amazon Alexa users who are already using conversational interfaces on a daily basis.
With Amazon Alexa Skills Kit you can define Intents and Entities for your task. Alexa system recognizes an intent correctly with variations in words only when you provide every possible example of expressions that could exactly match how users might say it to Alexa. It feels like they are still working on their own version of machine learning in order to simplify the work needed for model training.
The great thing is that a whole new skill for Alexa could easily be built with AWS Lambda functions, that seamlessly integrates with the Alexa Skills Kit.
Anyway, Amazon Alexa Skills Kit is an outstanding system that you should keep in mind,following their development, because Amazon is currently a leading household platform for conversations and custom bot integrations, which they are aggressively pushing forward with new device offerings and features.
Amazon revealed Amazon Lex – a conversational interface API with NLP features and tight integration to Amazon services such as Lambda, Dynamo DB, SNS/SES and others. We’ll look into Amazon Lex internals once it becomes available.
IBM Watson Developer Cloud Services
You probably remember the famous IBM Watson’s game when it won against two humans on the TV quiz show “Jeopardy” in 2011. So the good news is that IBM moved the technology behind the Watson into the cloud and released the set of API that you can use in your own conversational applications.
The API set includes language understanding offerings from a natural language classifier to concept insights and dialogue processing. There are a lot of building blocks that you can use in your application, but you probably will spend a fair amount of time integrating them into one solution.
We’ve used IBM Alchemy Language for sentiment analysis and keywords extraction for our experiments and it worked well. We think that IBM’s solution is the ideal choice for enterprises that want to be 100% sure of their API provider.
For a recent IBM Watson demonstration you can watch a fireside chat with Dr. John Kelly, who leads the Watson team at IBM, at TechCrunch Disrupt 2015 in San Francisco.
IBM Watson is, however, a costly solution and you can expect to pay up to $0.02 per API call in Dialogue API, so it may be too expensive to experiment with in building bots for Facebook Messenger when you still don’t have a working business model.
The full list of available API’s from IBM Watson Developer Cloud available here.
Ready to build a conversational bot for your business, but confused with the variety of platforms? Let’s talk!
In this article, we have seen that there are various systems available for building conversational interfaces.
Our personal preference goes to Wit.ai from Facebook and LUIS from Microsoft, as they provide all the necessary elements for building conversations and they are free (at least for now), so you don’t have to worry about the price.
Anyway, we would recommend you store all data needed for your model in a structured way in your own code repository. This means that later you can retrain the model from scratch, or even change the language understanding provider if needed. You just don’t want to be in a situation when a company shuts down their service and you are completely unprepared. Do you remember Parse?
For the end-to-end solutions that requires less code, we think Api.ai is the way to go. This is also a good option if you need embedded capabilities, avoiding dependence on an internet connection. We are also often using Chatfuel as it’s an easy to build builder of conversational flow with a powerfull JSON API integrations.
Alexa Skills Kit is proprietary for Amazon Echo devices, therefore you can’t use it with arbitrary bots at Slack or Facebook Messenger for language processing, but it is ideal for smart home bots that augment your kitchen or living room environment, and which are built specifically for Alexa. Luckily Amazon Lex will soon be available to the public, so it could pose a great alternative, especially if your infrastructure is already tapped into the AWS ecosystem.
IBM Watson will work smoothly in an enterprise environment when you need to feed large amounts of data, you have a decent budget and you want to have a reliable and proven service provider behind you.
Generally speaking, we expect to see many more platforms and API services for language understanding tasks in 2016, because the field is just beginning to heat up, with the major platforms newly announcing their bot platforms and frameworks.
Google have launched their own NLP service, Cloud Natural Language API, which is packed with text analytics, content classifications & relationship graphs, and deep learning models that you can use for your chatbot needs. We’ll review Google’s offering in a separate article.
Stay tuned and happy chatbot building.
Building our own bot
This article was written as part of our own challenge to build a smart bot with AI capabilities that can help people understand how to build a mobile app, give useful advice and provide an estimation of development and design costs.
Having a website become standard for every business years ago. That same process is just beginning for chatbots.
Chatbots are the new rage as more top brands are advancing the technology and integrating it into their chat systems. Big names such as Facebook and Telegram have already made moves in this arena by creating their own chatbots and chatbot platforms.
Over the past couple months, I've been trying to implement chatbots into my company Due. For many, chatbot marketing can sound overwhelmingly complicated, but a chatbot, not so much. It can truly save you enourments of time.
With numerous advancements and tools being created to make the process easy, making a chatbot does not seem out of the question. So, if you are thinking about jumping on the chatbot bandwagon, here are the top 10 platforms for you to know about.
Chattypeople is the best chatbot platform for creating an AI chatbot on Facebook with integrated Facebook commerce. With Chattypeople you can create a Facebook message both quickly and easily, no coding required. The platform's simplicity makes it ideal for entrepreneurs and marketers in smaller companies, while its technology makes it suitable for enterprise customers. You can make a simple bot answering customer service questions or integrate it with Shopify to monetize your Facebook fan pages. ChattyPeople is where f-commerce and ai-commerce come together. Chattypeople is 100% free to get started.
MEOKAY is one of the top tools to create a conversational Messenger bot. It makes it easy for both skilled developers and non-developers to take part in creating a series of easy to follow steps. Within minutes, you can create conversational scenarios and build advanced dialogues for smooth conversations. Once you are done, link and launch your brand new chatbot.
Smooch acts as more of a chatbot connector that bridges your business apps, (ex: Slack and ZenDesk) with your everyday messenger apps (ex: Facebook Messenger, WeChat, etc.) It links these two together by sending all of your Messenger chat notifications straight to your business apps, which streamlines your conversations into just one application. In the end, this can result in smoother automated workflows and communications across teams. These same connectors also allow you to create chatbots which will respond to your customer chats…. boom!
Related: Make Chats With Chatbots Work
Botsify is another Facebook chatbot platform that helps make it easy to integrate chatbots into the system. Its paid subscription helps you in five easy steps. 1) Log into the botsify.com site, 2) Connect your Facebook account, 3) Setup a webhook, 4) Write up commands for the chatbot you are creating, and 5) Let Botisfy handle the customer service for you. If the paid services are a little too much, they do offer a free service that lets you create as many bots as your lovely imagination can dream up.
If you are looking for another paid platform, Beep Boop may be your next stop. It is a hosting platform that is designed for developers looking to make apps for Facebook Messenger and Slack specifically. First, set up your code using Github, the popular version control repository and Internet hosting service, then input it into the Beep Boop platform to link it with your Facebook Messenger or Slack application. The bots will then be able to interact with your customers with real-time chat and messaging.
Need a Facebook bot? Well, look no further, as Chatfuel makes it easy for you to create your own Facebook and Telegram Chatbot without any coding experience necessary. It works by letting users link to external sources through plugins. Eventually, the platforms hope to open itself to third-party plugins, so anyone can contribute their own plugins and have others benefit from them.
Facebook Messenger Platform
Have you checked out Facebook Messenger’s official page lately? Well, now you can start building your own bot directly through the platform’s landing page. This method though, may be a little bit more complicated than some of the previous ways we’ve discussed, but there are a lot of resources that Facebook Messenger provides in order to help you accomplish your brand new creation. Through full-fledged guides, case studies, a forum for Facebook developers, and more, you are sure to be a chatbot creating professional in no time.
Build a bot directly from one of the top messaging apps themselves. By building a bot in Telegram, you can easily run a bot in the application itself. The company recently open-sourced their chatbot code, making it easy for third-parties to integrate and create bots of their own. Their Telegram API, which they also built, can send customized notifications, news, reminders, or alerts. Integrate the API with other popular apps such as YouTube and Github for a unique customer experience.
A toolkit can be integral to getting started in building chatbots, so insert, BotKit. It gives a helping hand to developers making bots for Facebook Messenger, Slack, Twilio, and more. This BotKit can be used to create clever, conversational applications which map out the way that real humans speak. This essential detail differentiates from some of its other chatbot toolkit counterparts.
Last, but not east coming in with the bot platform for business is FlowXO, which creates bots for Messenger, Slack, SMS, Telegraph and the web. This platform allows for creating various flexibility in bots by giving you the option to create a fully automated bot, human, or a hybrid of both. ChatBot expert Murray Newlands commented that "Where 10 years ago every company needed a website and five years ago every company needed an app, now every company needs to embrace messaging with AI and chatbots."