<commit_before># Collaborative Crowd Game #
 
[SayThat](https://saythat.io) is a game where players watch a video together on a big screen (such as a projector), and speak or type to their phones in their language of choice what they see on the screen. Players score points when they correctly guess a word that the Cloud Video Intelligence API produced when analyzing the video. 
 
This game highlights how [Cloud Functions for Firebase](https://firebase.google.com/docs/functions/) can be used to easily add Machine Learning to an app. The code in this repository demonstrates uses of:
 
* Cloud Speech API
* Cloud Translate API
 
Additionally, to analyze the video and produce the words to be guessed, we propose using the Cloud Video Intelligence API to annotate your videos. 
 
### Gameplay Architecture
A game involves the following steps:
 
* The administrator prepares a number of videos to show, and populates a list of relevant words to guess in the Firebase Database, using the data layout described below. Specifically, they add nouns under the path `/admin/scenes/{scene}/nouns/en-US/{noun}`.
  * The Cloud Function `translateNoun` triggers, to translate the noun into all supported languages.
  * The translations are written to `/admin/scene/{scene}/nouns/{language_code}/{noun}`.<commit_msg>Add link to talk video.<commit_after># Collaborative Crowd Game #
 
[SayThat](https://saythat.io) is a game where players watch a video together on a big screen (such as a projector), and speak or type to their phones in their language of choice what they see on the screen. Players score points when they correctly guess a word that the Cloud Video Intelligence API produced when analyzing the video.

The game was first created for a talk at Google I/O 2017 titled **Supercharging Firebase Apps with Machine Learning and Cloud Function**. You can watch the video [here](https://www.youtube.com/watch?v=RdqV_N0sCpM).
 
This game highlights how [Cloud Functions for Firebase](https://firebase.google.com/docs/functions/) can be used to easily add Machine Learning to an app. The code in this repository demonstrates uses of:
 
* Cloud Speech API
* Cloud Translate API
 
Additionally, to analyze the video and produce the words to be guessed, we propose using the Cloud Video Intelligence API to annotate your videos. 
 
### Gameplay Architecture
A game involves the following steps:
 
* The administrator prepares a number of videos to show, and populates a list of relevant words to guess in the Firebase Database, using the data layout described below. Specifically, they add nouns under the path `/admin/scenes/{scene}/nouns/en-US/{noun}`.
  * The Cloud Function `translateNoun` triggers, to translate the noun into all supported languages.
  * The translations are written to `/admin/scene/{scene}/nouns/{language_code}/{noun}`.
{'fraction_non_alphanumeric': 0.0641070799577316, 'fraction_numerical': 0.0017611835153222965, 'mean_word_length': 4.546875, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 5, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1284734', 'n_tokens_mistral': 738, 'n_tokens_neox': 680, 'n_words': 391}