Tuesday, December 29, 2009

Google Advanced Image Search bug

The Google Advanced Image Search page appears to have a bug in its query builder.

Let's say you want to display images of apples or cherries.

Go to the Advanced Image Search page and enter the keyword fruit in the Related to all of the words field. This keyword will disambiguate fruit images from Apple computer images.

In the Related to any of the words field, enter two keywords: apple cherry. Click search. The results display mainly images of apples or cherries based on the search query: fruit apple OR cherry.

The bug appears if you decide to modify the results to include, say, images of avocados. You now want to display images of apples or cherries or avocados.

If you click the Advanced Search link to return to the Advanced Image Search page, add avocado in the Related to any of the words field, then click search, Google runs this query:

fruit apple | cherry apple OR cherry OR avocado

(Note that Google uses both the "|" and the OR symbol to indicate OR).

Since apple | cherry erroneously remains in the query, all results must contain either an apple or a cherry. The last term (apple OR cherry OR avocado) may not return many images of avocados because the results already must include an apple or a cherry.

It is possible, that after the search algorithm runs the term apple | cherry it completely ignores the next term apple OR cherry OR avocado because it has already satisfied the query by returning an apple or a cherry.

You may suggest a user should delete the apple | cherry term in the Related to all of the words field. However, it was written into the field as a query builder by the software based on the user entering keywords apple cherry into the Related to any of the words field.

Note that Google Advanced Web search handles this same situation correctly.

Here is my original SETI research.

No comments: