From reTryNoJpg.rb (to search for the url subfield using a url fragment):

query = {"images.thumbnail.url" => /#{url_fragment}/i}
photo = photosColl.find_one(query, :fields => ["images"])