Dataset (BigQuery database) is available at: https://console.cloud.google.com/bigquery?p=firebase-public-project&d=analytics_153293282&t=events_20181003&page=table
Data pre-processing using PySpark.Sql is done in a src/processing.ipynb notebook.
SQL queries which were executed on BigQuery to obtain tables ltv_data, event_data, session_data are stored in src/processing/ directory as *.txt files. The only note here is such that these queries contain placeholders for additional data filtering (last WHERE clause) which is called by the model web app (see demo video for details).
The file src/tree_models.ipynb contains the code of final model (Random Forest with tuned hyperparameters). In addition, linear models were given a try, see implementation at src/linear_models.ipynb.
The end product of the work is a service, built around the model, with the following architecture:

Platform demo video: https://drive.google.com/file/d/1LY0GSFp3YV4-35N3chgULBxnN9SX92fW/view?usp=share_link
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|