Chatbot – Build Your Own Interactive Chatbot

Make a chatbot

This challenge has been written by EU Code Week Team and is part of the EU CODE WEEK CHALLENGES.

Duration

1 hour

Experience

Advanced

Target Audience

  1. Teachers
  2. Students (12-18)

Purpose

  1. Code interactive riddles
  2. Use code to create dialogues between a chatbot and a user

Recommended Materials

  1. Pencil code
  2. Machine learning for kids

Make a chatbot

Teachers

Students (12-18)

Description

Code a conversation between a chatbot and a user who is trying to solve a riddle. Try to make a chatbot that can chat like a person. Instead of a riddle you can create a dialogue between a chatbot and a user.

Instructions

  1. Think of a riddle.
  2. Log in to Pencil Code or create a new account. (When creating a new account keep in mind that real names are not allowed on Pencil Code due to privacy reasons.)
  3. Click Imagine and Make your own.
  4. Use blocks or text-based mode to write your riddle.
  5. Alternatively, you can use this code 1 and adapt it to your riddle or you can select Answering a riddle from the menu and edit it .

Share the link to your work in your Instagram Bio: tap the Edit Profile button on your Instagram and add the link to your work in the Website field. After that, create a new post, add a screenshot of your work, write “Link in Bio”, add the hashtag #EUCodeWeekChallenge and mention @CodeWeekEU.

Example

Check out this example of a riddle.
1. This code has been Adapted from Pencil Code activity Answering the Riddle
Download this challenge as a word document