=Paper=
{{Paper
|id=Vol-3276/SSS-22_FinalPaper_133
|storemode=property
|title=How to Teach AI Programming for Elementary
Students?
|pdfUrl=https://ceur-ws.org/Vol-3276/SSS-22_FinalPaper_133.pdf
|volume=Vol-3276
|authors=Hiromitsu Yamaguchi,Hirofumi Abe,Toshiyuki
Shimazaki,Kenzo Ozaki,Masayuki Numao
|dblpUrl=https://dblp.org/rec/conf/aaaiss/YamaguchiASON22
}}
==How to Teach AI Programming for Elementary
Students?==
How to Teach AI Programming for Elementary Students? – A Case Study of AI
Conversation Robot Programming at UEC Programming School
Hiromitsu Yamaguchi, Hirofumi Abe, Toshiyuki Shimazaki,
Kenzo Ozaki, Masayuki Numao
Department of Communication Engineering and Informatics,
The University of Electro-Communications
Abstract Comparison with AIML
In order to increase the number of human resources with pro- When you execute the following code, if the result of voice
gramming thinking, programming education has become in- recognition is ”Hello”, you will say ”Nice to meet you!” If
dispensable from elementary school students in Japan as well. ”Goodbye”, say ”See you again!”
To utilize communication robots for programming education
Developed a scripting language for communication robots Listing 3: Description example
that even beginners can program I actually used it in a pro- 1 /speech-to-text
gramming class. 2 /if/Hello/Nice to meet you!
3 /if/Goodbye/See you again!
Basic syntax
The script language developed this time supports speech The code below describes the same process in AIML
recognition and speech synthesis. If you want to say some- (2001). AIML was developed by Carnegie Mellon Univer-
thing, write it in natural language without any special gram- sity. It is a world-renowned rule-based language for chat-
mar. Listing 1 is a example. bots.
Listing 4: AIML
Listing 1: Utterance example
1
1 Hello. 2
2 I am a robot. Nice to meet you. 3 Hello
4 Nice to meet you!
Code written in natural language is spoken in order from template>
the top. Since it can be written in natural language, anyone 5
who can input using the keyboard can write it. No special 6
7 Goodbye
programming knowledge is required. 8 See you again!
Listing 2 is an example of conditional branching. This 9
script says ”Hello” when the robot recognizes ”Greeting” 10
by voice. When he recognizes other words, he says, ”I see.”
Lines with ”/” at the beginning of the line are command
lines. The line with ”:” at the beginning becomes a label and Comparing the two in Listing 3 and Listing 4 It can be
can be specified as the transition destination of the goto or if seen that the script language devised this time can easily de-
command. Lines beginning with ”//” are comment lines. scribe the same contents.
XML is a difficult grammar for beginners and elementary
Listing 2: Conditional branching example school students, and it is difficult to notice grammar mis-
takes. The script language used this time can be spoken in
1 :LOOP natural language, Since the control syntax is also the mini-
2 /speech-to-text
3 /if/greeting/:GREETING
mum number of characters, I thought that it could be used
4 I see. as a language for programming education.
5 /goto/:LOOP
6 Evaluation robot configuration
7 :GREETING
Figure 1 shows a robot developed to evaluate this script lan-
8 hello
9 /goto/:LOOP guage. The robot has a built-in Linux-based single board
___________________________________ computer and A speaker, a microphone, a motor, a button
In T. Kido, K. Takadama (Eds.), Proceedings of the AAAI 2022 Spring Symposium with LED, and a monitor are connected.
“How Fair is Fair? Achieving Wellbeing AI”, Stanford University, Palo Alto, California,
USA, March 21–23, 2022. Copyright © 2022 for this paper by its authors. Use permitted
under Creative Commons License Attribution 4.0 International (CC BY 4.0).
39
Listing 5: Loop example
1 :LOOP
2 Hello
3 /goto/:LOOP
Creating a presentation
Finally, the students actually developed a thematic presen-
tation program. You can make a robot give a presentation
Figure 1: Evaluation robot by creating a program. The theme of the presentation was
”Thanks to my family, which I can’t usually say.” Listing 6
shows an example presentation script.
The single board computer has a built-in web server and
The image specified in the script language can be displayed Listing 6: Presentation example
via a web browser. Because the script language can also be 1 /image/title.png
edited via a web browser No special development environ- 2 Gratitude.
ment is required. 3 I’m Taro Yamada,
4 5th grade at Tokyo Elementary School.
Example of use in programming classroom 5 /image/slide1.png
6 Dad, mom, thank you for your hard work
Used as a teaching material in the summer course of the Uni- every day.
versity of Electro-Communications programming class held
in August 2018. The target students were 50 students from A presentation is made by arranging the combinations of
the 5th grade of elementary school to the 2nd grade of high slide images and utterances in order. The image command is
school, and each class was held for 2 days, for a total of 4 a command to display a slide image on the screen.
days.
summary
Understanding the network Some students in the programming class started touching the
The main theme of the first day was network learning. The keyboard a few months ago, As a result, everyone was able
evaluation robot has built-in WiFi and can connect to the In- to complete the presentation script.
ternet. Have students understand how TCP / IP, IP addresses Understanding the network and basic control of program-
and ports work They learned to operate their robot remotely ming The students enjoyed learning.
from their PC. Visual programming languages are often used in program-
Because all the robots are connected to the same WiFi ming classes for beginners and you think Text-based pro-
router Students who understand how IP addresses and ports gramming languages aren’t for beginners. It was shown that
work Noticed that other people’s robots can also be oper- it can be used for elementary school students by devising a
ated remotely they started to operate another student’s robot script language.
remotely. The student noticed that his robot was being op-
erated remotely with others and changed a password on his Future tasks
robot. The reason for creating the script developed this time is the
From this experience, students learned the importance of sense of incongruity with the watching robot for the elderly.
security in networks. A watching robot developed by your grandson is better than
being watched by an off-the-shelf robot. I think it will be a
Understanding control syntax robot that is loved like a treasure.
It is still difficult in reality for AI to automatically learn
On the second day, they developed a script that gives a theme and perform various tasks. At present, it takes time and effort
and makes the presentation a robot. to create a rule-based mechanism. An easy-to-write scripting
First of all, We told the students that the robot would language will be needed to gain the power of many non-
speak when you typed Japanese characters into the editor. engineers.
Students who understand that the robot speaks when enter- Elementary school students develop a communication
ing a Japanese document. Then start trying what happens robot for their summer vacation homework and you can see
when you enter a random sentence. They understood that a service using robots in the town. We would like to expand
you can make the robot talk while having fun. the range of activities to build a richer and more enjoyable
Next, I gave some simple control syntax that are label and world.
goto command. Listing 5 shows the sample code.
When this scenario is executed, the robot repeatedly says References
”Hello”. Students enjoyed the behavior of a broken robot AIML Foundation. 2001. http://www.aiml.foundation/. Ac-
and understood loop control. cessed: 2022-01-24.
40