Adonis Diaries

Posts Tagged ‘Jon Orwant

How to mine 5 million books already scanned by Google

Mind you that this speech was delivered in 2011. At the time, Google was targeting to scan 15 million books, Not counting magazines and other artistic productions.

Erez Lieberman Aiden: Everyone knows that a picture is worth a thousand words. But we at Harvard were wondering if this was really true. (Laughter) So we assembled a team of experts, spanning Harvard, MIT, The American Heritage Dictionary, The Encyclopedia Britannica and even our proud sponsors, the Google. And we cogitated about this for about four years. And we came to a startling conclusion. Ladies and gentlemen, a picture is not worth a thousand words. In fact, we found some pictures that are worth 500 billion words.

Jean-Baptiste Michel: So how did we get to this conclusion? So Erez and I were thinking about ways to get a big picture of human culture and human history: change over time. So many books actually have been written over the years. So we were thinking, well the best way to learn from them is to read all of these millions of books. Now of course, if there’s a scale for how awesome that is, that has to rank extremely, extremely high. Now the problem is there’s an X-axis for that, which is the practical axis. This is very, very low.

01:32 Now people tend to use an alternative approach, which is to take a few sources and read them very carefully. This is extremely practical, but not so awesome. What you really want to do is to get to the awesome yet practical part of this space. So it turns out there was a company across the river called Google who had started a digitization project a few years back that might just enable this approach. They have digitized millions of books. So what that means is, one could use computational methods to read all of the books in a click of a button. That’s very practical and extremely awesome.

02:03 ELA: Let me tell you a little bit about where books come from. Since time immemorial, there have been authors. These authors have been striving to write books. And this became considerably easier with the development of the printing press some centuries ago. Since then, the authors have won on 129 million distinct occasions, publishing books. Now if those books are not lost to history, then they are somewhere in a library, and many of those books have been getting retrieved from the libraries and digitized by Google, which has scanned 15 million books to date.

02:33 Now when Google digitizes a book, they put it into a really nice format. Now we’ve got the data, plus we have metadata. We have information about things like where was it published, who was the author, when was it published. And what we do is go through all of those records and exclude everything that’s not the highest quality data. What we’re left with is a collection of five million books, 500 billion words, a string of characters a thousand times longer than the human genome — a text which, when written out, would stretch from here to the Moon and back 10 times over — a veritable shard of our cultural genome. Of course what we did when faced with such outrageous hyperbole … (Laughter) was what any self-respecting researchers would have done. We took a page out of XKCD, and we said, “Stand back. We’re going to try science.”

03:34 JM: Now of course, we were thinking, well let’s just first put the data out there for people to do science to it. Now we’re thinking, what data can we release? Well of course, you want to take the books and release the full text of these five million books.

Now Google, and Jon Orwant in particular, told us a little equation that we should learn. So you have five million, that is, five million authors and five million plaintiffs is a massive lawsuit. So, although that would be really, really awesome, again, that’s extremely, extremely impractical. (Laughter)

04:03 Now again, we kind of caved in, and we did the very practical approach, which was a bit less awesome. We said, well instead of releasing the full text, we’re going to release statistics about the books. So take for instance “A gleam of happiness.” It’s four words; we call that a four-gram. We’re going to tell you how many times a particular four-gram appeared in books in 1801, 1802, 1803, all the way up to 2008. That gives us a time series of how frequently this particular sentence was used over time. We do that for all the words and phrases that appear in those books, and that gives us a big table of two billion lines that tell us about the way culture has been changing.

04:34 ELA: So those two billion lines, we call them two billion n-grams. What do they tell us? Well the individual n-grams measure cultural trends. Let me give you an example. Let’s suppose that I am thriving, then tomorrow I want to tell you about how well I did. And so I might say, “Yesterday, I throve.” Alternatively, I could say, “Yesterday, I thrived.” Well which one should I use? How to know?

04:59 As of about six months ago, the state of the art in this field is that you would, for instance, go up to the following psychologist with fabulous hair, and you’d say, “Steve, you’re an expert on the irregular verbs. What should I do?” And he’d tell you, “Well most people say thrived, but some people say throve.” And you also knew, more or less, that if you were to go back in time 200 years and ask the following statesman with equally fabulous hair, (Laughter) “Tom, what should I say?” He’d say, “Well, in my day, most people throve, but some thrived.” So now what I’m just going to show you is raw data. Two rows from this table of two billion entries. What you’re seeing is year by year frequency of “thrived” and “throve” over time. Now this is just two out of two billion rows. So the entire data set is a billion times more awesome than this slide.  

06:05 JM: Now there are many other pictures that are worth 500 billion words. For instance, this one. If you just take influenza, you will see peaks at the time where you knew big flu epidemics were killing people around the globe.

06:16 ELA: If you were not yet convinced, sea levels are rising, so is atmospheric CO2 and global temperature.

06:24 JM: You might also want to have a look at this particular n-gram, and that’s to tell Nietzsche that God is not dead, although you might agree that he might need a better publicist.

06:35 ELA: You can get at some pretty abstract concepts with this sort of thing. For instance, let me tell you the history of the year 1950. Pretty much for the vast majority of history, no one gave a damn about 1950. In 1700, in 1800, in 1900, no one cared. Through the 30s and 40s, no one cared. Suddenly, in the mid-40s, there started to be a buzz.

People realized that 1950 was going to happen, and it could be big. (Laughter) But nothing got people interested in 1950 like the year 1950. (Laughter) People were walking around obsessed. They couldn’t stop talking about all the things they did in 1950, all the things they were planning to do in 1950, all the dreams of what they wanted to accomplish in 1950.

In fact, 1950 was so fascinating that for years thereafter, people just kept talking about all the amazing things that happened, in ’51, ’52, ’53. Finally in 1954, someone woke up and realized that 1950 had gotten somewhat passé. (Laughter) And just like that, the bubble burst.

And the story of 1950 is the story of every year that we have on record, with a little twist, because now we’ve got these nice charts. And because we have these nice charts, we can measure things. We can say, “Well how fast does the bubble burst?” And it turns out that we can measure that very precisely. Equations were derived, graphs were produced, and the net result is that we find that the bubble bursts faster and faster with each passing year. We are losing interest in the past more rapidly.

08:24 JM: Now a little piece of career advice. So for those of you who seek to be famous, we can learn from the 25 most famous political figures, authors, actors and so on. So if you want to become famous early on, you should be an actor, because then fame starts rising by the end of your 20s — you’re still young, it’s really great. Now if you can wait a little bit, you should be an author, because then you rise to very great heights, like Mark Twain, for instance: extremely famous.

But if you want to reach the very top, you should delay gratification and, of course, become a politician. So here you will become famous by the end of your 50s, and become very, very famous afterward. So scientists also tend to get famous when they’re much older. Like for instance, biologists and physics tend to be almost as famous as actors. One mistake you should not do is become a mathematician. (Laughter) If you do that, you might think, “Oh great. I’m going to do my best work when I’m in my 20s.” But guess what, nobody will really care.

09:17 ELA: There are more sobering notes among the n-grams. For instance, here’s the trajectory of Marc Chagall, an artist born in 1887. And this looks like the normal trajectory of a famous person. He gets more and more and more famous, except if you look in German.

If you look in German, you see something completely bizarre, something you pretty much never see, which is he becomes extremely famous and then all of a sudden plummets, going through a nadir between 1933 and 1945, before rebounding afterward. And of course, what we’re seeing is the fact Marc Chagall was a Jewish artist in Nazi Germany.

09:55 Now these signals are actually so strong that we don’t need to know that someone was censored. We can actually figure it out using really basic signal processing. Here’s a simple way to do it. Well, a reasonable expectation is that somebody’s fame in a given period of time should be roughly the average of their fame before and their fame after. So that’s sort of what we expect. And we compare that to the fame that we observe. And we just divide one by the other to produce something we call a suppression index. If the suppression index is very, very, very small, then you very well might be being suppressed. If it’s very large, maybe you’re benefiting from propaganda.

10:34 JM: Now you can actually look at the distribution of suppression indexes over whole populations. So for instance, here — this suppression index is for 5,000 people picked in English books where there’s no known suppression — it would be like this, basically tightly centered on one. What you expect is basically what you observe. This is distribution as seen in Germany — very different, it’s shifted to the left. People talked about it twice less as it should have been. But much more importantly, the distribution is much wider. There are many people who end up on the far left on this distribution who are talked about 10 times fewer than they should have been. But then also many people on the far right who seem to benefit from propaganda. This picture is the hallmark of censorship in the book record.

11:11 ELA: So culturomics is what we call this method. It’s kind of like genomics. Except genomics is a lens on biology through the window of the sequence of bases in the human genome. Culturomics is similar. It’s the application of massive-scale data collection analysis to the study of human culture. Here, instead of through the lens of a genome, through the lens of digitized pieces of the historical record. The great thing about culturomics is that everyone can do it. Why can everyone do it?

Everyone can do it because three guys, Jon Orwant, Matt Gray and Will Brockman over at Google, saw the prototype of the Ngram Viewer, and they said, “This is so fun. We have to make this available for people.” So in two weeks flat — the two weeks before our paper came out — they coded up a version of the Ngram Viewer for the general public. And so you too can type in any word or phrase that you’re interested in and see its n-gram immediately — also browse examples of all the various books in which your n-gram appears.

12:06 JM: Now this was used over a million times on the first day, and this is really the best of all the queries. So people want to be their best, put their best foot forward. But it turns out in the 18th century, people didn’t really care about that at all. They didn’t want to be their best, they wanted to be their beft. So what happened is, of course, this is just a mistake. It’s not that strove for mediocrity, it’s just that the S used to be written differently, kind of like an F. Now of course, Google didn’t pick this up at the time, so we reported this in the science article that we wrote. But it turns out this is just a reminder that, although this is a lot of fun, when you interpret these graphs, you have to be very careful, and you have to adopt the base standards in the sciences.

12:42 ELA: People have been using this for all kinds of fun purposes. (Laughter) Actually, we’re not going to have to talk, we’re just going to show you all the slides and remain silent. This person was interested in the history of frustration. There’s various types of frustration. If you stub your toe, that’s a one A “argh.” If the planet Earth is annihilated by the Vogons to make room for an interstellar bypass, that’s an eight A “aaaaaaaargh.” This person studies all the “arghs,” from one through eight A’s. And it turns out that the less-frequent “arghs” are, of course, the ones that correspond to things that are more frustrating — except, oddly, in the early 80s. We think that might have something to do with Reagan.

13:28 (Laughter)

13:30 JM: There are many usages of this data, but the bottom line is that the historical record is being digitized. Google has started to digitize 15 million books. That’s 12 percent of all the books that have ever been published. It’s a sizable chunk of human culture. There’s much more in culture: there’s manuscripts, there newspapers, there’s things that are not text, like art and paintings. These all happen to be on our computers, on computers across the world. And when that happens, that will transform the way we have to understand our past, our present and human culture.




September 2021

Blog Stats

  • 1,480,136 hits

Enter your email address to subscribe to this blog and receive notifications of new posts by

Join 810 other followers

%d bloggers like this: