Google wants to predict the next sentences of dead authors

Getty Images

Google is teaching its artificial intelligence how to understand language by making it predict, and replicate, the works of famous dead authors.

The company is building systems that are capable of understanding natural language in the same way humans do, with the works of William Shakespeare, Mark Twain and others currently being analysed. "This work has the potential to enrich products through personalisation," Marc Pickett from Google's Natural Language Understanding research group wrote in a recent blog post.

Researchers training the deep neural network -- using the work of authors from Project Gutenberg -- fed the AI an input sentence and asked it to say what would come next. The network is given millions of lines from a "jumble" of authors and then works out the style of individual writers. Pairs of lines were given to the system, which made a simple 'yes' or 'no' decision to whether they matched up.

Initially the system didn't know the identity of any authors, but still only got things wrong 17 percent of the time.

By giving the network an indication of who the authors were, giving it another factor to compare work against, the computer scientists reduced the error rate to 12.3 percent. This was also improved by a adding a fixed number of previous sentences to give the network more context.

Google isn't the only company using the work of authors to teach its systems how humans communicate. Facebook's AI is being taught using children's books. Mark Zuckerberg's company has released several data sets being used to train its own neural networks. These, according to the New Scientist, include The Jungle Book, A Christmas Carol, and Alice in Wonderland.

In a similar test to Google, Facebook presented its neural network with phrases from books and gave it missing words to select from. The overall aim of both products is to create a system that is able to communicate with humans and provide answers to questions; Facebook's M, Apple's Siri and Google Now could all benefit from such technology.

To take the test one step further, Google's researchers built upon the author analysis technique to try and get the AI to write from beyond the grave.

The researchers wrote: "We get the performance and generalisation of the network across all authors and text it learned on, but influenced by what’s unique to a chosen author. Combined with our generative model, these vectors allow us to generate responses as different authors."

They also tried to predict the personality of the writers. Google admitted its predictions weren't necessarily "particularly accurate," but said its AI had identified William Shakespeare as a private person and Mark Twain as an outgoing person. "When asked 'Who is your favourite author?' and [given] the options 'Mark Twain', “William Shakespeare”, 'myself', and 'nobody', the Twain model responded with 'Mark Twain' and the Shakespeare model responded with 'William Shakespeare'."

Asked who would answer the phone, the AI Shakespeare hoped someone else would answer, while Twain would try and get there first.

This article was originally published by WIRED UK