SlideShare a Scribd company logo
Presentation for School of Continuing Studies
Data Science / Engineering
Section I: Advertising Technology Landscape
About Me
- Name: Larkin Liu
- Role: Data Scientist @ StackAdapt since 2016
- Specialties: Apache Spark, Scala, Python, R
- Education: MASc in Industrial Engineering, Specializing
in Operations Research, University of Toronto
- Other Fun Facts:
- Chinese / Canadian
- Competitive MMA fighter, and kickboxer.
- I really like race cars.
What I do ?
Agenda
Increase Profitability of Campaigns
- Ad Tech Landscape
- ML Models
- Logistic Regression
- Bagging: Random Forest
- Boosting: Adaboost (Gradient Boosted Trees, xgboost)
- Survival Regression (Proportional Hazards, Accelerated Failure Time Model)
- (Natural Language Processing)
- AB Testing
- RTB Auction Strategy
Real Time Bidding
- Online advertising goes through a process
known as Real Time Bidding (RTB)
- StackAdapt is a Demand Side Platform
(DSP).
- DSP’s interface with clients running
advertising campaigns, facing the Ad
Exchange.
- Our objective is to win valuable ad
impressions for our client’a campaigns.
Overview (Objectives)
- The ad exchange is a second price
auction.
- We bid on advertisements that are
valuable to our client.
- To accomplish we predict the likelihood
of a defined conversion, based on ML
modelling.
- We set our bid price proportional to our
predicted probability of a conversion.
Key Terms
- KPI - Key Performance Metric
- Win Price - the win price of the advertisement on the ad exchange, actual cost.
- Bid Price - what the DSP bid for the advertisement.
- CPM - Cost per Mille, cost per 1000 impressions.
- eCPC - Effective cost per click (total cost/number of clicks)
- eCPE - Effective cost per engagement (total cost/number of engagements)
- eCPA - Effective cost per action (total cost/number of conversions)
- AB Testing - split testing algorithms between control group and treatment algorithm.
Expectation
Initially we believed that each optimizer we designed will have a desired effect on the intermediate KPI’s
(CTR, eCPC, eCPE, eCPA, etc.), which in turn affect the overall profit of each campaign.
Reality
In reality, we discovered that the effect of each optimizer on various intermediate KPI’s follow a more
complex interaction scheme, which is also dependent on the market dynamics.
Data Science / Engineering
Section II: ML Models
Logistic Regression
Logistic Regression
We interpret the probability of p
i
provided predictor variables x
0,i
, x
1,i
, ..., x
m,i
.
Univariate logistic regression model F(x)
Can be re-written as, interpreted as the Odds ratio, where
F(x) is interpreted as probability of response = 1 (p)
Logistic Regression with
Interaction (IX) Terms
- Basic logistic regression makes a key assumption that all observations are independent of one
another. This is not the case in our data set.
- Interaction terms take into account the interaction between variables. For example, where variables X
and Z may not be independent, and the interaction between X and Z produce an effect on the log
odds.
- When deploying logistic regression for prediction of key KPI’s, the addition of interaction terms crucial
for accurate prediction, as variables are not independent, and the interaction between variables may
have a key effect in predicting KPI’s.
AdaBoost
- Adaptive Boosting (AdaBoost) is a well-established boosting algorithm.
- Unlike bagging, it produces a linear combination of tree results.
- Each weak classifier is trained on the entire dataset.
- Misclassified results are accentuated, and correctly classified results are diminished, depending on
each of the weak classifier results.
- The result is a linear combination of weak classifiers.
- Boosting can resolve the inherent capabilities of a specific class of classifiers, as well as reduce
class imbalance.
AdaBoost
Illustrative example of boosting.
AdaBoost Algorithm
Random Forest
- Random Forest (Breiman 2001) is a very
established bagging classification
algorithm allowing us to perform
classification and regression.
- An extension of the decision tree algorithm,
RF combines a random sampling of the
data, sample of the features, and sample of
the in and combines the result of many
small weak predictors.
- This approach makes RF much more
robust. Preventing overfitting and bias.
Survival Regression
- Proportional Hazards Model
- Accelerated Failure Time Model
- Models were evaluated using Akaike Information
Criterion (AIC), and Root Mean Square Error (RMSE).
- Primarily used to measure the time it takes for users to remain on a site (time on site). The
longer a user remains on a site, the lower the probability.
Survival Modelling
Survival Modelling
- We used a Random Forest model. Parameters,
- m: 33% of Total No. of Features
- No. Trees: 100
- Max Depth: 10 Layers
- Average RMSE across 10-fold cross validation
of 145. (A 25% Improvement from the Survival
Models investigated earlier).
Data Science / Engineering
Section III: RTB Deployment
AB Testing
- Currently our tests run 50/50 splits (S = 0.5), 50% goes to A group (control) 50% goes to B group
(experimental treatment).
- Our goal is to maximize profit, and minimize eCPC, something which we can achieve by deploying
our ML models.
- However, the effect of any model on any specific campaign can vary.
EMR-AB13-IX-5day-dailyUpdate
- Experimental Model Avg eCPC: 0.819
- Control Group eCPC: 0.833
- Experimental Model Profit: 2457.11
- Control Group Profit: 2773.32
EMR-AB14-mean_encoded_logisti
c_regression
- Experimental Model Avg eCPC: 1.246
- Control Group eCPC: 0.675
- Experimental Model Profit: 2285.23
- Control Group Profit: 1086.80
But wait
- Models perform differently with regards to various KPI’s and models on a
campaign-specific basis….
- Solution: a larger proportion of bid requests should go to the model with better KPI
performance.
RTB Optimizer
Our Min*/Max* framework is based off of a PID controller, where we adjust the split (S) proportional to
our objective of attaining a minimum or maximum value.
- Proportional: Immediate Error
- Integral: Cumulative Error
- Derivative: Rate of Change
References
- Zhang, Weinan, “Optimal Real-Time Bidding for Display Advertising”, 2016
- Freund & Schapire, “Experiments with a New Boosting Algorithm”, 1996
QUESTIONS

More Related Content

PDF
Using genetic algorithms and simulation as decision support in marketing stra...
PPTX
Ensemble hybrid learning technique
PPTX
(Machine Learning) Ensemble learning
PDF
Ensemble modeling and Machine Learning
PPTX
Design patterns
PPT
Churn model for telecom
PPTX
Boosting Approach to Solving Machine Learning Problems
PPTX
MachineLearning-v0.1
Using genetic algorithms and simulation as decision support in marketing stra...
Ensemble hybrid learning technique
(Machine Learning) Ensemble learning
Ensemble modeling and Machine Learning
Design patterns
Churn model for telecom
Boosting Approach to Solving Machine Learning Problems
MachineLearning-v0.1

Similar to StackAdapt Machine Learning Pipeline (20)

PPTX
Deepak-Computational Advertising-The LinkedIn Way
PPTX
Chapter8_What_Is_Machine_Learning Testing Cases
PDF
Stock Price Trend Forecasting using Supervised Learning
PDF
Deep Learning Introduction for Engineering
PPTX
Developing Web-scale Machine Learning at LinkedIn - From Soup to Nuts
PDF
Machine Learning deep learning artificial
PPTX
Towards Increasing Predictability of Machine Learning Research
PDF
ML Foundations: A 3-Day Journey into Machine Learning
PDF
Performance Comparision of Machine Learning Algorithms
PPTX
24AI201_AI_Unit_4 (1).pptx Artificial intelligence
PDF
Machine learning in credit risk modeling : a James white paper
PPTX
Predicting Employee Attrition
PDF
Stock Market Prediction Using ANN
PPTX
Data-Driven (Reinforcement Learning-Based) Control
PPTX
Automated Machine Learning (Auto ML)
PPTX
11.1. PPT on How to crack ML Competitions all steps explained.pptx
PPT
Machine-Learning-Algorithms- A Overview.ppt
PPT
Machine-Learning-Algorithms- A Overview.ppt
PPTX
Employee Retention Prediction: A Data Science Project by Devangi Shukla
PDF
Supervised Learning.pdf
Deepak-Computational Advertising-The LinkedIn Way
Chapter8_What_Is_Machine_Learning Testing Cases
Stock Price Trend Forecasting using Supervised Learning
Deep Learning Introduction for Engineering
Developing Web-scale Machine Learning at LinkedIn - From Soup to Nuts
Machine Learning deep learning artificial
Towards Increasing Predictability of Machine Learning Research
ML Foundations: A 3-Day Journey into Machine Learning
Performance Comparision of Machine Learning Algorithms
24AI201_AI_Unit_4 (1).pptx Artificial intelligence
Machine learning in credit risk modeling : a James white paper
Predicting Employee Attrition
Stock Market Prediction Using ANN
Data-Driven (Reinforcement Learning-Based) Control
Automated Machine Learning (Auto ML)
11.1. PPT on How to crack ML Competitions all steps explained.pptx
Machine-Learning-Algorithms- A Overview.ppt
Machine-Learning-Algorithms- A Overview.ppt
Employee Retention Prediction: A Data Science Project by Devangi Shukla
Supervised Learning.pdf
Ad

Recently uploaded (20)

PDF
How to Migrate SBCGlobal Email to Yahoo Easily
PDF
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PPTX
history of c programming in notes for students .pptx
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PDF
Digital Systems & Binary Numbers (comprehensive )
PDF
Nekopoi APK 2025 free lastest update
PDF
PTS Company Brochure 2025 (1).pdf.......
PDF
Upgrade and Innovation Strategies for SAP ERP Customers
PDF
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
PDF
System and Network Administration Chapter 2
PPTX
VVF-Customer-Presentation2025-Ver1.9.pptx
PDF
System and Network Administraation Chapter 3
PDF
T3DD25 TYPO3 Content Blocks - Deep Dive by André Kraus
PPT
Introduction Database Management System for Course Database
PPTX
assetexplorer- product-overview - presentation
PPTX
Operating system designcfffgfgggggggvggggggggg
PDF
Digital Strategies for Manufacturing Companies
PDF
2025 Textile ERP Trends: SAP, Odoo & Oracle
PDF
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
How to Migrate SBCGlobal Email to Yahoo Easily
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
history of c programming in notes for students .pptx
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Digital Systems & Binary Numbers (comprehensive )
Nekopoi APK 2025 free lastest update
PTS Company Brochure 2025 (1).pdf.......
Upgrade and Innovation Strategies for SAP ERP Customers
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
System and Network Administration Chapter 2
VVF-Customer-Presentation2025-Ver1.9.pptx
System and Network Administraation Chapter 3
T3DD25 TYPO3 Content Blocks - Deep Dive by André Kraus
Introduction Database Management System for Course Database
assetexplorer- product-overview - presentation
Operating system designcfffgfgggggggvggggggggg
Digital Strategies for Manufacturing Companies
2025 Textile ERP Trends: SAP, Odoo & Oracle
EN-Survey-Report-SAP-LeanIX-EA-Insights-2025.pdf
Ad

StackAdapt Machine Learning Pipeline

  • 1. Presentation for School of Continuing Studies
  • 2. Data Science / Engineering Section I: Advertising Technology Landscape
  • 3. About Me - Name: Larkin Liu - Role: Data Scientist @ StackAdapt since 2016 - Specialties: Apache Spark, Scala, Python, R - Education: MASc in Industrial Engineering, Specializing in Operations Research, University of Toronto - Other Fun Facts: - Chinese / Canadian - Competitive MMA fighter, and kickboxer. - I really like race cars.
  • 5. Agenda Increase Profitability of Campaigns - Ad Tech Landscape - ML Models - Logistic Regression - Bagging: Random Forest - Boosting: Adaboost (Gradient Boosted Trees, xgboost) - Survival Regression (Proportional Hazards, Accelerated Failure Time Model) - (Natural Language Processing) - AB Testing - RTB Auction Strategy
  • 6. Real Time Bidding - Online advertising goes through a process known as Real Time Bidding (RTB) - StackAdapt is a Demand Side Platform (DSP). - DSP’s interface with clients running advertising campaigns, facing the Ad Exchange. - Our objective is to win valuable ad impressions for our client’a campaigns.
  • 7. Overview (Objectives) - The ad exchange is a second price auction. - We bid on advertisements that are valuable to our client. - To accomplish we predict the likelihood of a defined conversion, based on ML modelling. - We set our bid price proportional to our predicted probability of a conversion.
  • 8. Key Terms - KPI - Key Performance Metric - Win Price - the win price of the advertisement on the ad exchange, actual cost. - Bid Price - what the DSP bid for the advertisement. - CPM - Cost per Mille, cost per 1000 impressions. - eCPC - Effective cost per click (total cost/number of clicks) - eCPE - Effective cost per engagement (total cost/number of engagements) - eCPA - Effective cost per action (total cost/number of conversions) - AB Testing - split testing algorithms between control group and treatment algorithm.
  • 9. Expectation Initially we believed that each optimizer we designed will have a desired effect on the intermediate KPI’s (CTR, eCPC, eCPE, eCPA, etc.), which in turn affect the overall profit of each campaign.
  • 10. Reality In reality, we discovered that the effect of each optimizer on various intermediate KPI’s follow a more complex interaction scheme, which is also dependent on the market dynamics.
  • 11. Data Science / Engineering Section II: ML Models
  • 12. Logistic Regression Logistic Regression We interpret the probability of p i provided predictor variables x 0,i , x 1,i , ..., x m,i . Univariate logistic regression model F(x) Can be re-written as, interpreted as the Odds ratio, where F(x) is interpreted as probability of response = 1 (p)
  • 13. Logistic Regression with Interaction (IX) Terms - Basic logistic regression makes a key assumption that all observations are independent of one another. This is not the case in our data set. - Interaction terms take into account the interaction between variables. For example, where variables X and Z may not be independent, and the interaction between X and Z produce an effect on the log odds. - When deploying logistic regression for prediction of key KPI’s, the addition of interaction terms crucial for accurate prediction, as variables are not independent, and the interaction between variables may have a key effect in predicting KPI’s.
  • 14. AdaBoost - Adaptive Boosting (AdaBoost) is a well-established boosting algorithm. - Unlike bagging, it produces a linear combination of tree results. - Each weak classifier is trained on the entire dataset. - Misclassified results are accentuated, and correctly classified results are diminished, depending on each of the weak classifier results. - The result is a linear combination of weak classifiers. - Boosting can resolve the inherent capabilities of a specific class of classifiers, as well as reduce class imbalance.
  • 17. Random Forest - Random Forest (Breiman 2001) is a very established bagging classification algorithm allowing us to perform classification and regression. - An extension of the decision tree algorithm, RF combines a random sampling of the data, sample of the features, and sample of the in and combines the result of many small weak predictors. - This approach makes RF much more robust. Preventing overfitting and bias.
  • 18. Survival Regression - Proportional Hazards Model - Accelerated Failure Time Model - Models were evaluated using Akaike Information Criterion (AIC), and Root Mean Square Error (RMSE). - Primarily used to measure the time it takes for users to remain on a site (time on site). The longer a user remains on a site, the lower the probability.
  • 20. Survival Modelling - We used a Random Forest model. Parameters, - m: 33% of Total No. of Features - No. Trees: 100 - Max Depth: 10 Layers - Average RMSE across 10-fold cross validation of 145. (A 25% Improvement from the Survival Models investigated earlier).
  • 21. Data Science / Engineering Section III: RTB Deployment
  • 22. AB Testing - Currently our tests run 50/50 splits (S = 0.5), 50% goes to A group (control) 50% goes to B group (experimental treatment). - Our goal is to maximize profit, and minimize eCPC, something which we can achieve by deploying our ML models. - However, the effect of any model on any specific campaign can vary.
  • 23. EMR-AB13-IX-5day-dailyUpdate - Experimental Model Avg eCPC: 0.819 - Control Group eCPC: 0.833 - Experimental Model Profit: 2457.11 - Control Group Profit: 2773.32
  • 24. EMR-AB14-mean_encoded_logisti c_regression - Experimental Model Avg eCPC: 1.246 - Control Group eCPC: 0.675 - Experimental Model Profit: 2285.23 - Control Group Profit: 1086.80
  • 25. But wait - Models perform differently with regards to various KPI’s and models on a campaign-specific basis…. - Solution: a larger proportion of bid requests should go to the model with better KPI performance.
  • 26. RTB Optimizer Our Min*/Max* framework is based off of a PID controller, where we adjust the split (S) proportional to our objective of attaining a minimum or maximum value. - Proportional: Immediate Error - Integral: Cumulative Error - Derivative: Rate of Change
  • 27. References - Zhang, Weinan, “Optimal Real-Time Bidding for Display Advertising”, 2016 - Freund & Schapire, “Experiments with a New Boosting Algorithm”, 1996