Week 15 · Unit 7.3: Connections are made · 3 lessons
2
Search engines that learn
Computing 7: Unit 7.3, pp. 82–111
GoalExplain how a search engine uses keywords, machine learning and image recognition.
New words
search engine · a website that searches a huge database of web pages for the pages that match a querykeyword · an important word in a search that the search engine looks formachine learning · a computer learning patterns from data instead of being told every ruleimage recognition · a computer looking for matching patterns in a picture to work out what it shows
Explanation
A search engine keeps a huge database of web pages and returns the ones that match your query. It does not need a full sentence: it picks out the keywords, such as tall lighthouses from “show me pictures of tall lighthouses”. Search engines use machine learning, which means they learn patterns from data, for example which results people choose. They move helpful pages higher up the list. They may also use your location, so a search for swimming pool shows pools near you. In a reverse image search you give a picture instead of words. Image recognition looks for matching patterns of edges, colours and textures in a database of many pictures and returns similar ones. AI can be wrong, so always check results with another source.
your query→pick the keywords→search the database→ranked list of pages
Worked examples
What the user types
Keywords
Where can I find a picture of a cheetah running?
cheetah running picture
Tell me how deep the sea is
sea depth
Finding keywords. The search engine ignores the small words and keeps the ones that carry the meaning.
Learning from choices. For the search “bridge”, people clicked on three pages. The most chosen page moves up the list next time.
picture of a lighthouse→look for matching patterns→find similar pictures→list of matches
How a reverse image search works, step by step. The AI does not “see” like a person: it compares patterns.
Class activity
Be the search engine (no computer): write the titles of eight made-up web pages on cards, for example “Training a puppy”, “Puppy photos”, “Growing tomatoes” and “Tomato soup recipe”. A partner reads out a query in a long sentence. Underline the keywords, find the cards that match and put the best one first. Make a tally of which card the partner prefers each time and move popular cards up the list for the next query. This is machine learning. Then play “draw and guess”: the guessers get better at spotting what a drawing shows after seeing more drawings.
Practice
1
Write the keywords for each query.
Query
Keywords
(a) How fast can a zebra run?
?
(b) Show me photos of a volcano erupting
?
(c) What time does the school bus leave?
?
(a) zebra running speed. (b) volcano eruption photos. (c) school bus timetable.
2
Which search is better, “zebra running speed” or “I would like to know how quickly a zebra can run please”? Why?
The first one is better. A search engine looks for keywords, and the extra words add nothing. Both searches will probably give similar results, but a short keyword search is quicker to type.
3
A search engine counted how often people chose each page for the same query. Which page will it move to the top, and what is one risk of doing this?
Page B has the most clicks, so it moves to the top. The risk is that a popular page is not always the most accurate one, so people must still check facts from other sources.
4
A friend wants to upload a photo of a stranger to a reverse image search to find out who the person is. Give two reasons why this is a bad idea.
You must ask permission before sharing a photo of someone, and a private photo should not be uploaded without a trusted adult. The result could also be wrong, and wrong guesses about a person can hurt them. It is safer not to do it.