Aito.ai — Using time series forecasting for predicting Freska’s customer churn
This is a real-life case example of using time series forecasting to predict customer churn for a high growth startup. Freska is a Nordic success story disrupting the cleaning industry.
Predicting customer churn is relatively simple when using snapshot data. Within Python, you could set up a predictive model to predict future customer churn based on the characteristics of customers that have churned in the past. However, if you want to predict churn from time series (that is from customer lifecycle data), the prediction becomes more tricky.
Another option for doing the prediction over a time series would be creating a neural network model. This model might work for starters but would set problems once you want to incorporate new or more complex data later on. It’s not scalable. Also, the neural network only predicts the churn, but it couldn’t explain what factors are indicators for their probable churn.
Aito’s predictive database, except for doing the predictive part, will also return explainable results — as in, giving you the reason why a certain customer might be churning. The reason could be because the customer satisfaction ratings are low, or in case of a service business, there could have been too many changes in who is taking care of their case. Having these explainable results will help the company not only to anticipate but also to decrease the churn rate — thanks to explaining the underlying reasons behind the important numbers.
And we’re not stopping there. By amending the data with data about actions taken in order to retain the customer, the Recommend API endpoint could also be used to recommend the most suitable action to prevent a possible churn. As you might now realize, it’s not snapshot data Aito uses — it’s the whole database.
Customer case: predicting churn for Freska
Freska, a modern home cleaning company based in Finland, Sweden and Norway, have been using an RFM (recency, frequency & monetary) model to predict its customer churn so far. To reach a better churn rate prediction accuracy, Freska started a POC (proof of concept) with Aito’s predictive database.
Let’s look at the different steps involved in setting up churn prediction with Aito.
1. Collecting the data
For this POC, we use 2 different data sources:
a. Customer bookings, which contains:
- Address information: Postcode, City, Country
- Booking details: Worker, Duration, Frequency, Canceled, if the cleaning place hasdogs, hascats, hasotherpets, PetsInfo, cleaning area, notes
- Satisfaction metrics: RatingOverall, RatingBehavior, RatingQuality, RatingOnTime, ApprovedByCustomer
- Marketing information: SalesAgents, SalesAgency
b. Monthly customer metrics data, containing:
- Number of months from first booking, total booking hours this month
- A field that is manually entered telling if the customer churned this month (True, False)
2. Preprocessing the data
a. We aggregate the bookings data table and the customer metrics data table into 1 table so that the monthly information (metrics and bookings) of a customer is merged.
The combined table looks like this:
b. Aito does not natively support time-series format. So in order to use the different monthly data points, we do another aggregation so each customer will only have one entry. The table now has more columns to store the status of the previous x month, and now looks like this:
Prev0month is the information of the previous month (comparing to the predicting month). Prev1Month is the information of the previous 2 months E.g: Predicting July, Prev0Month = June, Prev1Month = may
3. Using the predict api endpoint
We can now use Aito Predict query to predict the churn status next month of customer with id 0:
"bookingHoursThisMonth": "2 3",
"bookingHours1MonthAgo": "1 1",
As Aito uses all the data in the table as training data, it means it uses also the “churnStatusThisMonth” column values for inference. We solve this by using the data of the previous months but giving Aito the churn status of this month. And as such, using the information from the latest month to predict the next month.
The POC started a couple of weeks ago and the upcoming weeks will be used for further experimentation and iteration. Maximizing churn rate prediction accuracy, improving, maybe adding the RFM model’s intelligence, even adding other data sources like the company’s action data (e.g. marketing & sales information) to see how it affects the results.
These next steps will be covered in a forthcoming blog post. Follow us on Twitter to be the first one to know. If you don’t want to wait, request a trial and we explain how to do the same for your company.
Originally published at https://aito.ai.