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

Vortana Say
ProAndroidDev
Published in
4 min readJul 25, 2017

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)

https://www.blog.google/products/assistant/google-assistant-coming-to-more-android-phones/

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. Leave your opinion below!

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

Published in ProAndroidDev

The latest posts from Android Professionals and Google Developer Experts.

Responses (1)

What are your thoughts?