How To Setup Google Assistant Trivia Game In Detail (Part 1)

Google Assistant is a virtual personal assistant developed by Google and was announced at its developer conference in May 2016. Unlike Google...

Written by Vortana Say · 1 min read

Google Assistant is a virtual personal assistant developed by Google and was announced at its developer conference in May 2016. Unlike Google Now, Google Assistant can engage in two-way conversations. (wikipedia)



There are a lot of built-in features that Google Assistant can provide for users such as games and entertainment, home control, education and reference, shopping, health and fitness and many more as mentioned in here. This article is going to talk about Trivia Game, a feature in game and entertainment, that its template allows you to create your own customized version of trivia game.

According to Leon Nicholls’s recent article in June, Google Assistant Trivia Template, by using the trivia template tool provided, we can create our own fully functioned trivia game with our own set of questions and answers on any topic we like. Later on in his article, Google Assistant Trivia Game, he announced that it’s now available in open source to everyone.

Notice: This article elaborate instructions from Github page with detailed explanations and illustrations of how to setup Google Assistant Trivia Game. If you are familiar with it, you can just go ahead to the link above and follow the instruction. P.S: Feel free to peek in anytime 😉

Sneak Peak: this is what we have after the setup. Using simulator in Actions on Google console we can test our setup for the Trivia game with the default questions and answers.

Before we start, download this zip files from Github page and extract it.

STEP I: Create Project In “Actions On Google” And Add Action Using “API.AI”

Note: “Actions on Google” lets you build apps for the Google Assistant. Your apps can help you engage users through Google Home, eligible Android phones, iPhones, and in the future, through every experience where the Google Assistant is available. (https://developers.google.com/actions/)

  • Click on the project you created in the “Actions on Google” console, and click Use API.AI and then Create Actions on API.AI. Feel free to give any information applicable for our Agent then click Save to save the project.

Note: Api.ai (formerly Speaktoit) is a developer of human–computer interaction technologies based on natural language conversations.

  • Add intents and entities from the downloaded zip folder to api.ai

— Click on the gear icon located in the left navigation menu to see the project settings in the API.AI.

— Select Export and Import.

— Select Restore from zip. Follow the directions to restore from the TriviaGame.zip file in this repo. (The reason why we do restore, because our intents and entities have been defined in the open source trivia game, and we are going to use the same)

RESTORE: Replace the current agent version with a new one. All the intents and entities in the older version will be deleted.

Right now we have created and configured our project in Actions On Google and API.AI consoles. Next, we are going to configure and deploy the downloaded zip folder (project) to firebase. Here is the link to part 2 of the article.

Recommend and share these articles to others if you find them helpful.