O'Reilly Hacks
oreilly.comO'Reilly NetworkSafari BookshelfConferences Sign In/My Account | View Cart   
Book List Learning Lab PDFs O'Reilly Gear Newsletters Press Room Jobs  

Like a Version
Gather a list of what Google thinks are synonyms for a keyword you provide
The Code
[Discuss (0) | Link to this hack]

The Google ~ synonym operator ["Special Syntax" in ] widens your search criteria to include not only the specific keywords in your search, but also words Google has found to be synonyms of, or at least in some way related to, your query words. So while, for example, food facts may only match a handful of pages of interest to you, ~food ~facts seeks out nutrition information, cooking trivia, and more. And finding these synonyms is an entertaining and potentially useful exercise in and of itself. Here's one way...

Let's say we're looking for all the synonyms for the word "car." First, we search Google for ~car to find all the pages that contain a synonym for "car" In its search results, Google highlights synonyms in bold, just as it highlights regular keyword matches. Scanning the results (the second page is shown in ) for ~car finds car, cars, motor, auto, BMW, and other synonyms in boldface.

Figure 1. ~car turns up bolded synonyms in Google search results

Now let's focus on the synonyms rather than our original keyword, "car." We'll do so by excluding the word "car" from our query, like so: ~car -car. This saves us from having to wade through page after page of matches for the word "car."

Once again, we scan the search results for new synonyms. (I ran across automotive, racing, vehicle, and motor.)

Make a note of any new bolded synonyms and subtract them from the query (e.g., ~car-car -automotive -racing -vehicle -motor) until you hit Google's 10-word limit ["The 10-Word Limit" in Chapter 1], after which Google starts ignoring any additional words that you tack on.

In the end, you'll have compiled a goodly list of synonyms, some of which you'd not have found in your typical thesaurus thanks to Google's algorithmic approach to synonyms.

O'Reilly Home | Privacy Policy

© 2007 O'Reilly Media, Inc.
Website: | Customer Service: | Book issues:

All trademarks and registered trademarks appearing on oreilly.com are the property of their respective owners.