ReadyAI – Middle School

Lesson 3: Facial Recognition, Speech

Essential Question

How can AI interact with humans?

Summary of Lesson

Applying the principles of object identification, students will assist their AI units to identify faces. Additionally, students will employ speech recognition and generation to associate their AI units with their commands.

Agenda

Assessment

Can students …

  • program Cozmo to identify a face
  • program Cozmo to speak to the person it identifies?
  • evaluate uses for the AI principle of facial recognition, speech recognition, and speech generation?
  • produce a written script for their production scenario?

Objectives

Students will be able to

  • identify recognition functions within their AI units.
  • program their AI units to recognize faces and oral commands.
  • create a scenario in which Cozmo employs facial recognition, speech recognition, and speech generation.

Tools and Materials

Connecting to Prior Knowledge

What is a robot? What can AI recognize?

Support
If you have any question about the lesson plan, please contact info@ReadyAI.org

Teaching Guide

Ice Breakers (5 minutes)

Teacher writes the following sentences on the board or shares them with students via Handout 3.1:

  1. Find something with such cream.
  2. Wreck a nice beach
  3. My chess caught that home
  4. You got us into humor.

Teacher explains that these are sentences that were generated with speech recognition, but that the sentences were incorrectly transcribed. Teacher asks the students to try to “decipher” what was the intended sentence:

  1. Find somewhere with a touchscreen.
  2. Recognize speech.
  3. I just got back home.
  4. You’ve got a sense of humor.

Teacher asks, “How does Cozmo recognize faces and words?”

Teacher resources:

PowerPoint 3

Handout 3.1 assists students in seeing how speech to text goes wrong.

Teacher Resource 3.1 provides the answers to Handout 3.1.

Check for understanding:

What problems are there in speech recognition?

Transition:

How does Cozmo recognize faces and words?

Teacher Presentation (15 minutes)

Having pre-programmed AI unit to recognize himself/herself, teacher begins Presentation module by demonstrating possibilities of facial and speech recognition as well as speech generation before transitioning to presenting how to set up these functions.

Teacher states that last lesson, students programmed Cozmo to recognize objects. Teacher asks, “If Cozmo can recognize objects, what else is possible?”

  • After allowing students to provide some ideas, teacher highlights how AI can recognize faces. Additionally, ff AI can recognize people, what is possible?
  • Possible answers recognizing their voices.
  • Teacher may also ask for applications of recognizing faces and voices. Possible answers include ensuring security, confirming identity, enhancing personal interactions, among other ideas.
  • Teacher may use Class PowerPoint to review potential applications for Facial ID or highlight appropriate videos such as https://www.youtube.com/watch?v=z-t1h0Y8vuM

Teacher then demonstrates software, including how to program facial and speech recognition and speech generation. Teacher may also give a brief overview using the PowerPoint on how these features work.

  • Teacher outlines steps for students through Handout 3.2 or by writing on a board.

Teacher resources:

See Teacher Resource 3.2 for an optional facial recognition technology.

Check for understanding:

What are the steps necessary to program the facial and speech recognition?

Transition:

Where might these features be useful?

Guided Practice (15 minutes)

Teacher distributes AI-IN-A-BOX. Using previous or newly defined roles (See Handout 2.1 if necessary), students set up the AI-IN-A-BOX.

Teacher provides a scenario for students to train Cozmo to accommodate. Teacher may create his or her own, or use the following:

Teacher says, “We will program Cozmo to greet his ‘master’ but tell others that they are trespassing.”

Teacher circulates as students also begin to program Cozmo to recognize one human face in the group. For other human faces, Cozmo should be programmed to say, “You are trespassing.”

  • Teacher may encourage students who move faster than other groups to also program additional faces so that Cozmo recognizes more than one person.
  • Students should also be reminded of “speak” function and program Cozmo to say the name of the person.
  • Teacher may encourage advanced groups to begin programming Cozmo to recognize and respond to simple voice prompts, such as “Am I trespassing?”, to which Cozmo may respond yes or no, depending on whether he recognizes the face asking him.
  • Students may reference Handout 3.2 for assistance on programming conditions. Teacher answers may be found in teacher resource 3.4.

Teacher resources:

Teacher Resource 3.3 assists in programming Cozmo to recognize and respond to simple voice prompts.

Handout 3.2 includes assistance in programming and options for creating new lines of coding for students to follow.

Teacher resource 3.4 provides answers for the “trespassing program.”

Check for understanding:

How does Cozmo differentiate one human from another?

Transition:

What applications might you make of speech and facial recognition as well as speech generation?

Student Production (20 minutes)

Teacher then prompts students that it is time to think creatively.

Teacher says, “We just practiced one scenario, that is, AI telling who should be somewhere and who shouldn’t be somewhere.”

Teacher continues, “Now, your group will have about 15 minutes to create a scenario where AI can use 1) facial recognition, 2) speech generation, and 3) speech recognition. You will share what your ideas and a script that would help bring those ideas to live at the end of the session.”

Teacher says, “Imagine you want to create a Firefighting AI Robot. I want you to program a cube to be a ‘fire.’ What does Cozmo say when he sees the fire?”

Teacher adds, “You also want Cozmo to respond to someone saying, ‘Fire!’ What will Cozmo say when he hears someone say ‘Fire!’?”

Each group will each be given approximately 15 minutes. Each group should create a script to accompany their scenario, which can be documented (and if the teacher chooses for grading) on Handout 3.3.

The teacher should circulate and ensure groups are being given suggestions and advice regarding their scenarios and scripting for Cozmo.

During the last five minutes of the student production time frame, students should briefly present their ideas, and if time permits, demonstrate them.

Teacher resources:

Handout 3.3 can be used to document students’ programming scripts.

Teacher Resource 3.5 combines different lines of programming for Cozmo to respond to fires.

Check for understanding:

What scenario did you create?

What scripted commands did you create?

Transition:

Teacher asks, “Where in the world would AI need to recognize objects?”

Closure (5 minutes)

Teacher gathers students’ comments on where and when AI needs to recognize people.

Students should assist in packing up AI-IN-A-BOXTM.

Teacher also provides each student a copy of the rubric (Handout 3.4) and mentions that this will be discussed more in Lesson 4. Teacher says he/she will discuss it more next time.

Teacher resources:

Check for understanding:

Have students share their thoughts