1. A computer-readable storage medium encoded with a computer program, the program comprising instructions that, when executed by one or more computers, cause the one or more computers to perform operations comprising: receiving a multi-term synonym phrase that is a candidate synonym for a multi-term query phrase; and determining that each term of the query phrase is a lexical synonym of a corresponding term of the synonym phrase or shares meaning with the corresponding term of the synonym phrase; in response to determining that each term of the query phrase is a lexical synonym of the corresponding term of the synonym phrase or shares meaning with the corresponding term of the synonym phrase, using the query phrase and the synonym phrase to improve a synonym mapping between a particular term of the query phrase and a term of the synonym phrase that corresponds to the particular term.