New computer software can replicate your handwriting

Though we don’t really write as much as we type anymore, a group of researchers is trying to give hand-written word a comeback.

The team of computer scientists from the University College London have developed new software that can analyze your handwriting and then replicate it.

The program, called “My Text in Your Handwriting,” can semi-automatically examines a sample of a person’s handwriting, as little as one paragraph, and generate new text saying whatever the user wishes, as if the author had handwritten it themselves.

A real handwriting sample from Arthur Conan Doyle with the synthesized results of the algorithm underneath. Despite its current popularity, he never wrote the Sherlock catchphrase "elementary my dear Watson".
A real handwriting sample from Arthur Conan Doyle with the synthesized results of the algorithm underneath. Despite its current popularity, he never wrote the Sherlock catchphrase “elementary my dear Watson”. (Image via UCL)

“Our software has lots of valuable applications. Stroke victims, for example, may be able to formulate letters without the concern of illegibility, or someone sending flowers as a gift could include a handwritten note without even going into the florist. It could also be used in comic books where a piece of handwritten text can be translated into different languages without losing the author’s original style,” said Dr. Tom Haines, UCL Computer Science, who led the project.

To generate an individual’s handwriting, the program analyzes and replicates the author’s character choices, pen-line texture and color, inter-character ligatures (the joining-up between letters), and vertical and horizontal spacing.

The team’s machine learning algorithm is built around glyphs – a specific instance of a character. The researchers produced different glyphs to represent the same element of writing – the way one individual writes an “a” will usually be different to the way others write an “a”. Although an individual’s writing has slight variations, every author has a recognizable style that appears in their glyphs and their spacing. The software learns which aspects are consistent across an individual’s style and the recreates it.

“Up until now, the only way to produce computer-generated text that resembles a specific person’s handwriting would be to use a relevant font. The problem with such fonts is that it is often clear that the text has not been penned by hand, which loses the character and personal touch of a handwritten piece of text. What we’ve developed removes this problem and so could be used in a wide variety of commercial and personal circumstances,” said Dr. Oisin Mac Aodha, UCL Computer Science.

The system is so flexible that even samples from historical documents can be used with little extra effort. So far, the scientists have analyzed and replicated the handwriting of Abraham Lincoln, Frida Kahlo and Arthur Conan Doyle.

During testing, the team asked people to differentiate between handwritten envelopes and ones that were created by their automatic software. People were fooled by the computer-generated writing 40% of the time.

The software could have negative potential uses, like helping to forge documents, but the team explained it works both ways and could actually help in detecting forgeries.

“Forgery and forensic handwriting analysis are still almost entirely manual processes but by taking the novel approach of viewing handwriting as texture-synthesis, we can use our software to characterize handwriting to quantify the odds that something was forged,” said Dr. Gabriel Brostow, UCL Computer Science. “For example, we could calculate what ratio of people start their ‘o’s’ at the bottom versus the top and this kind of detailed analysis could reduce the forensics service’s reliance on heuristics.”