SHAP

Google's Gemma 4 E2B: The Ultimate Game Changer in On-Device AI

Have you ever worried about the next billing amount when running a generative AI for long hours? This is especially true since high-performance frontier models can easily run continuously for half a day or more. While we understand the incredible performance they offer, I'm sure many of you are wondering, "Isn't there a way to operate generative AI at a lower cost?" So, today, I would like to introduce "Gemma 4 E2B", an open-weight generative AI that you can download and use right on your local PC.

 

1. The Highly Anticipated Open-Weight Generative AI from Google: "Gemma 4 E2B"

Various AI companies have released open-weight generative AI models. My personal focus is on the Gemma series from Google, which is now in its 4th generation. It has steadily powered up with each generation, and among them, the performance of the smallest latest version, "Gemma 4 E2B QAT" (1), is particularly outstanding. This time, I built an application that predicts customer churn by combining machine learning with "Gemma 4 E2B QAT."

Here is its GUI. For this version, it features bilingual specifications supporting both English and Malay. This is the screen for training the machine learning model.

              Model Training Screen (English)]

You can switch it to Malay as shown below. It makes it easy to use even in Kuala Lumpur, the capital of Malaysia!

                Model Training Screen (Malay)

 

2. Exploring the Probability of Individual Customer Churn

Now, let's get down to business. By inputting individual customer data into the machine learning model, you can calculate the probability of that customer churning. Here, the system is set so that if the probability is 50% or higher, the customer is predicted to churn. The churn probability for the customer shown on this screen is 15.01%, so they were judged as "will not churn."

                   Customer Data

What's really important here is the reasoning behind why it decided they wouldn't churn. For this, a metric called SHAP (2) is employed. The graph below shows numerically and visually how much each feature contributed to the decision.

                Churn Probability and SHAP

However, the problem here is that SHAP is mostly well-known only to data scientists, and there's a high chance that ordinary business professionals aren't familiar with it at all. Therefore, simply saying "Please look at this graph" isn't very user-friendly.

This is where today's star, "Gemma 4 E2B QAT," steps in. As shown below, it explains the "basis for the decision" and the "model's accuracy" in plain, easy-to-understand English. With this, even a SHAP beginner can use it with absolute confidence.

        Explanation of Decision Basis and Model Accuracy (English)

Of course, you can switch this to Malay. Generating this much explanatory text in two languages takes only about 35 seconds on a MacBook Air (M4 24GB). Even on a standard Windows PC, it can often be generated in under 5 minutes. Since "Gemma 4 E2B QAT" is compact, its processing speed is incredibly fast. It is well within practical levels for real-world use.

        Explanation of Decision Basis and Model Accuracy (Malay)

 

3. The Quality of the Explanatory Text is Also Excellent

The most important point today is: "How accurate is the text generated by Gemma 4 E2B QAT?"

Small-scale generative AIs often lack the accumulated internal information compared to massive frontier models, so in my past experience, I frequently felt they were difficult to use practically in business. However, with "Gemma 4 E2B QAT," such worries were completely unnecessary. This app can output the prediction results as a PDF, so let's use that to take a closer look.

Here is the SHAP graph that served as the basis for the decision. We naturally want to explain this graph in easy-to-understand English, right?

Here is the explanatory text. What do you think? It's written in clear English, with absolutely no grammatical errors or spelling mistakes. I believe it provides a highly logical explanation based on the SHAP data above. When I first read it myself, I was actually a bit moved, thinking, "Can this little generative AI really do this much?"

 

So, what do you think? There are zero fees for using generative AI in this app. No invoices will be generated. You can use it freely for as many hours as you like. Isn't that fantastic!

Of course, "Gemma 4 E2B QAT" is not omnipotent, so it is necessary to use it strategically in combination with frontier models like Fable5 depending on the situation. However, I am beyond delighted that this ultra-compact generative AI has become a viable option. I feel we should actively use it while fully leveraging its major advantages: being entirely free and allowing highly confidential information to remain securely locked within your PC.

At Toshi Stats, we will continue to tackle tasks in the marketing field using the power of "Machine Learning + Generative AI." Stay tuned!

 

1)  Gemma 4 QAT models: Optimizing model compression for mobile and laptop efficiency, 5 June 2026, Olivier Lacombe, Omar Sanseviero, Google DeepMind

2) Welcome to the SHAP documentation

Copyright © 2026 ToshiStats Co., Ltd. All right reserved.

Notice: This is for educational purpose only. ToshiStats Co., Ltd. and I do not accept any responsibility or liability for loss or damage occasioned to any person or property through using materials, instructions, methods, algorithms or ideas contained herein, or acting or refraining from acting as a result of such use. ToshiStats Co., Ltd. and I expressly disclaim all implied warranties, including merchantability or fitness for any particular purpose. There will be no duty on ToshiStats Co., Ltd. and me to correct any errors or defects in the report, the codes and the software.

Maximizing Customer Retention: Churn Prevention Strategies Using AI and Machine Learning

It is always sad when customers who have taken the time to purchase our products or services end up leaving. If possible, we want to catch the signs early and take action to prevent them from churning. However, identifying customers who are likely to churn beforehand is no easy task. That is why, this time, I tried creating a customer churn prediction model. I would like to take on the challenge of predicting and countering customer churn using machine learning and generative AI. For formulating the key churn prevention strategies, I used Gemini 3.5 Flash (1), which offers a fantastic balance of performance and cost. Let's get started.

Gemini 3.5 Flash

 

1. Customer Churn Prediction Model

Using the created customer churn prediction model, let's first take a look at a general customer.

General Customer

The churn probability is 15.0%, indicating a "high likelihood of continuation," so no countermeasures are needed at this time. That's a relief.

SHAP Analysis of a General Customer

At this point, some of you might be wondering, "But why did the model decide that the likelihood of continuation is high?" This is where "SHAP" (2), shown in the figure above, comes into play. Simply put, it is a "value that indicates which data influenced the model's decision and to what extent." The SHAP graph for this customer extends significantly to the left in the negative direction, indicating that the churn probability is low. SHAP values are assigned to individual customers and show why the model made its decision for each specific customer. It is very helpful for us when trying to understand the results.

 

2. How to Prevent Customer Churn

Now, let's look at a customer who is on the verge of churning. Unlike before, the churn probability is 54.5%, indicating a "high likelihood of churning," which suggests that some countermeasures are necessary.

Customer Likely to Churn

Analysis of a Customer Likely to Churn

SHAP Analysis of a Customer Likely to Churn

You can see that the SHAP graph, unlike the previous one, extends significantly to the right. In particular, tenure and MonthlyCharges are large, serving as the main factors that increased this customer's churn probability.

Also, in the explanatory text for "Individual Customer Analysis," it states:

“To retain this customer, we recommend proactive outreach with a targeted retention offer. Specifically, we can address their high monthly charges by offering a loyalty discount, or incentivize them to transition from a flexible month-to-month contract to a more stable longer-term contract.”

This is a personalized retention measure for this specific customer. It is not a generic strategy. This is because, as stated in the explanation, it was created by the generative AI, Gemini 3.5 Flash, based on the individual customer's analysis results:

“The primary factors driving up their churn risk are their tenure (SHAP: +0.2620), high monthly charges (SHAP: +0.0655), and having a month-to-month contract (SHAP: +0.0311).”

It is trustworthy precisely because it is a measure tailored to the individual customer's situation. Fantastic!

 

3. For Further Development

In machine learning and AI, the quantity and quality of the input data are always the key. As these increase, diverse analyses become possible, and accuracy improves. In other words, I believe it is possible to elevate this into a marketing analytics platform in the future. I am really looking forward to its future developments. As the core technologies for this product development, I used Google Gemini 3.5 Flash for natural language processing, Choice-Learn for machine learning, and Google ADK for AI agent implementation. For app development, I am using ClaudeCode. These core technologies do not need to be fixed forever; I think it is best to flexibly use or replace them as needed. Since technological advancement is fast, I plan to adopt the optimal tools available at any given time.

 

What did you think? I felt that with "Machine Learning + AI," we can create fantastic products where they complement each other perfectly. I'm excited about future developments. Here at Toshi Stats, we plan to continue tackling tasks in the marketing field using "Machine Learning + AI." Stay tuned!

 

You can enjoy our video news “ToshiStats AI Weekly Review” from this link, too!

1) Gemini 3.5 Flash Best for frontier performance across agents and coding,  Google DeepMind
2) Welcome to the SHAP documentation

Copyright © 2026 ToshiStats Co., Ltd. All right reserved.

Notice: This is for educational purpose only. ToshiStats Co., Ltd. and I do not accept any responsibility or liability for loss or damage occasioned to any person or property through using materials, instructions, methods, algorithms or ideas contained herein, or acting or refraining from acting as a result of such use. ToshiStats Co., Ltd. and I expressly disclaim all implied warranties, including merchantability or fitness for any particular purpose. There will be no duty on ToshiStats Co., Ltd. and me to correct any errors or defects in the report, the codes and the software.