Google TensorFlow AI bots drafted into Ocado call centre service
Web retailer builds a better email opener
Like so much in Britain, you can credit the weather for this. Ocado has rolled out AI using Google’s open-source TensorFlow to improve service at its customer call centre.
The online food retailer took six months to build and install a system based on machine learning., using Python, C++, Kubernetes on Google Compute with TensorFlow.
The cloud-based AI will do the heavy lifting for inbound customer emails, opening and scanning for key words and context, before prioritising and forwarding them. On an ordinary day the system handles 2000 messages and double that at busy times such as Christmas.
Ocado isn’t new to the idea of machine learning – the retailer’s 1,000-strong technology unit has worked on data science and intelligent APIs, employed in recommendations, instant orders and to calculate optimal driver routes for years.
But this is the "first time we tried machine learning in customer service with natural language”, the unit’s head of technology Dan Nelson told The Reg.
“In this case it was a problem the business put to us of how to deal with these unusual spikes to improve throughput. We had an awareness of natural language processing – we just looked for solutions.”
The catalyst? The Great British weather.
“You can’t do that if you need more humans and more machines every time”
Nelson wouldn’t say too much: “There was a weather incident – a weather-based problem. These kind of events are outside of our control and cause us to run late.”
Drivers running late prompt a spike in emails from customers who want to know when their weekly shop’s coming.
Ocado employs 250 call centre staff in different shifts and - as you would expect - they open inbound emails. Customer service is key for the company which depends greatly on word-of-mouth to promote its brand. Rapid response is crucial.
But as a rule humans cannot open and parse those emails quickly enough, so the appropriate response is also delayed. Automation seemed the best solution.
“We are a business designed to operate at large scale … you can’t do that if you need more humans and more machines to do it every time,” Nelson said.
Ocado Technology builds most of the parent retailer's technology – for example, the Ocado Smart Platform on Google cloud for data and Amazon’s AWS for compute.
OSP is modular and incorporates web orders, fulfilment, warehousing and delivery systems. Ocado built the system to sell to other retailers as well as for its own use.
This time, Ocado was interested in 'something-out-of-the-box' but drew a blank. So the company built its own neural network.
TensorFlow is Google’s machine learning framework released to open source in November 2015. It's a framework for numerical computation using data-flow graphs. It came from the Google Brain Team inside Google's Machine Intelligence unit.
But like so much in machine learning and artificial intelligence, TensorFlow is new and lacks functionality in many areas. Ocado Technology built key pieces itself.
Kubernetes and Google Compute provide parameter and hyper parameter tuning - lacking in Google’s Cloud ML at the time Ocado kicked off the project six months ago. Hyper parameter turning has since arrived in the Cloud ML beta.
Kubernetes is also used to manage hundreds of machines on Google’s servers.
Nelson told The Reg: “Currently, the technologies in machine learning are still very much on the first step of a long journey to clicking and getting results so you have to export the data and clean the data because there are lots of emails that shouldn’t be there, you have build the network in TensorFlow – specific how may layers, how the layers should be connected, their activation points and how the algorithms should learn.”
When I'm cleansing data
Once constructed, the network had to learn. Ocado fed in data sets so the system could recognise legitimate emails from spam and filtering emails by context. The accuracy of its predictions was tested against real-world examples of actions.
Cleansing the data was a big challenge. Emails fed into the system had to be cleansed so the neural network could learn syntax and words.
Data cleansing pre-dates AI and machine learning. It has bedevilled projects running back decades all the way from today’s big data world of data lakes back through data warehouses, business analytics and humble OLAP.
If the original data is incomplete – fields missing or the same data entered but in different ways, for example - your project may be screwed at a fundamental level.
Another issue was anonymisation of the data. Ocado’s system runs on Google’s Compute servers, but Ocado could not let customers become resident there and so had to strip out key customer identifiers such as names, addresses and phone numbers.
“The model wants to know somebody was mentioned but doesn’t need to know the name,” Nelson said.
It was the weather wot started it, with customers emailing the call centre staff. But Ocado is now interested in running machine learning on social media – watching for whether a customer is upset at the retailer. Also it wants to explore "turning" phone calls.
“It’s a learning experience of where else might I apply natural language,” Nelson said. ®