13. A non-transitory computer-readable medium storing software comprising instructions executable by one or more computers which, upon such execution, cause the one or more computers to perform operations comprising: selecting a pair of words; receiving a document having an associated title or anchor; determining that a word of the pair of words occurs in the title or anchor of the document and that a different word of the pair of words occurs within the document; determining a co-occurrence frequency of the word of the pair of words and the different word of the pair of words in a collection of documents; and determining that the word and the different word are synonyms based at least upon determining that the word of the pair of words occurs in the title or anchor of the document and that the different word of the pair of words occurs in text within the document and based at least on the determined co-occurrence frequency of the word of the pair of words and the different word of the pair of words.
13. A non-transitory computer-readable medium storing software comprising instructions executable by one or more computers which, upon such execution, cause the one or more computers to perform operations comprising: selecting a pair of words; receiving a document having an associated title or anchor; determining that a word of the pair of words occurs in the title or anchor of the document and that a different word of the pair of words occurs within the document; determining a co-occurrence frequency of the word of the pair of words and the different word of the pair of words in a collection of documents; and determining that the word and the different word are synonyms based at least upon determining that the word of the pair of words occurs in the title or anchor of the document and that the different word of the pair of words occurs in text within the document and based at least on the determined co-occurrence frequency of the word of the pair of words and the different word of the pair of words. 15. The computer-readable medium of claim 13 , wherein the operations further comprise: generating an alternative search query for a search query that includes the first word or the second word using the synonym of the first word or the second word.