1. A computer-implemented method comprising: accessing query log data that identifies, for a search query: a particular query term and one or more other query terms that are included in the search query, search results that were generated using the search query, a ranking of the search results that were generated using the search query, and a particular search result selected by a user from among the search results that were generated using the search query; determining, using the query kg data, that, (i) in text associated with the particular search result selected by the user, the particular query term is separated from all of the one or more other query terms by at least a predetermined minimum number of terms, and (ii) in text associated with a search result that was ranked higher than the particular search result selected by the user, the particular query term is not separated from all of the one or more other query terms by at least the predetermined minimum number of terms; and based on the determination, incrementing a click count for a query term proximity rule corresponding to the particular query term.