⚙️ Optimizer

⚙️ Optimizer


Input your goal and per-channel and total budget spend constraints, and receive a budget that is optimized for your selected target (profit, ROI, or revenue)


📥 Inputs

  • Realistic channel budgets

  • Planned promotions or holidays

  • Committed spend levels

  • Objective - Outcome Target, Efficiency Target, or Maximize Profit

  • Constraints

  • Model Selection


🗳️ Objectives

Efficiency Target

Selecting the Efficiency Target allows you to maximize the cost-based efficiency of all of the marketing dollars spent during the time period selected. This value includes the effect that will be realized both immediately and in the future.

When to use: Use this when you want to spend as much as possible while maintaining a certain level of efficiency.

Total outcome

Total outcome is the complete effect on the KPI produced by the spend on a channel during the selected period, regardless of when this effect will be realized.

For channels that have a time shift, some of the outcome will be realized immediately on the day of spend, but the full effect will not be realized until some point in the future. The length of time, and pattern for when the full effect will be realized is estimated based on the time shift curve which can be viewed directly using the Shift Curves report.

“KPI” above is referring to the relevant business metric Recast is modeling (ex. Revenue, Conversions, etc)

When to use: Use this objective when you are trying to hit a certain goal in conversions or revenue as efficiently as possible

Profit

For ROI Models: Total Outcome * contribution margin - Total Spend

For CPA models: Total Outcome * value per acquisition - Total Spend

When to use: Use when you want to maximize the value of your conversions minus marketing spend


🪢 KPI Selection

The first step in optimizing is selecting what you want to optimize. If you only have one KPI modeled by Recast, this is straightforward. However, if you have multiple KPIs you can select which one you’d like to optimize for. By default, you’ll have one KPI for each Recast model. But your model building team can also create aggregate KPIs that sum across multiple models. For example, a total revenue KPI might be composed of Amazon revenue plus Walmart revenue plus online subscriptions multiplied by some lifetime value number, as seen in “Total Revenue” below:

If the KPI you’re interested in does not yet exist in Recast, you can make your own by doing Custom Model Weights and inputting the weights you want to use. Learn more by visiting Optimize across multiple models.


Adjusting Spikes

Once you’ve selected your KPI you can adjust the spike calendar for the time period you are optimizing for. Having an accurate spike calendar is important as spikes will make it more or less difficult to hit your objective. Spikes shown in red are spikes that have not happened yet and can be deleted if they are no longer going to happen.

Strategy

In general, the optimizer iteratively makes small nudges to your budget that help get it closer to your goal. It repeats this process over and over until you have your final recommendation. The Recast model doesn’t just return one simulation of what might happen in the future, it returns hundreds of simulations of what could happen. These hundreds of simulations are what we use to provide things like uncertainty around channel ROIs/CPAs. The important thing to remember is that the strategy you select impacts which of those simulations we’re trying to optimize

Strategy Options

Base: targets the mean of all the simulations and tries to make budget changes so that the mean outcome is as good as possible. Good for making sure your average result is as good as possible.

Conservative: targets the 20th percentile and tries to make budget changes so that the 20th percentile outcome is as good as possible (and 80% of simulations will be even better than that). Good for making sure your “worst case” scenario is as good as possible, regardless of how good the “best case” scenarios are. “Hedging your bets”.

Aggressive: targets the 80th percentile and tries to make budget changes so that the 80th percentile outcome is as good as possible (whether or not the bottom 80% of simulations are poor). Good for making sure your “best case” scenario is as good as possible, regardless of how bad the “worst case” scenarios are. “High Risk, High Reward”.

How percentiles are calculated.

Conservative and Aggressive both target percentiles rather than the mean. Percentiles put all the simulations in order from smallest to largest. Then for an Xth percentile, we look for the simulation below which X% of the simulations fall. When you calculate a mean, every single simulation influences that mean, but when you calculate a percentile, it’s looking at a single simulation (whichever one is at the 20th or 80th percentile). In math-y terms, the mean is a smooth function, percentiles are not. The consequence of this is that small changes in the input of Conservative and Aggressive optimizations can cause large changes to the output. We recommend using Base if consistency between different scenarios is important.

Intuition

Here the gray vertical lines represent the possible forecasted KPIs we get from our hundreds of simulations, the green dots represent the 20th percentile (a “worst case” scenario: 80% of simulations forecast a higher KPI than this one) and the red dots represent the 80th percentile (a “best case” scenario: only 20% of simulations forecast a higher KPI than this one). 

 

You can see that Budget 2 has a higher floor (green dot is higher than in Budget 1) but a lower ceiling (red dot is lower than in Budget 1). The Aggressive setting will prefer Budget 1, because its “best case” scenario is better than in Budget 2. But Conservative will prefer Budget 2 because its “worst case” scenario is better than in Budget 1. Base would consider these Budgets similar, because their mean predicted KPIs are similar.


Total Spend Constraint

The Total Spend Constraint allows you to fix your total budget in the optimizer exactly equal to a single value. This is useful if you have an exact budget you would like to spend fully.

The total spend constraint provides these options:

  • No overall spend constraint: this optimizes over your constraints without a fixed total budget.

  • Total spend constraint on all channels: This includes lower funnel channels in the total spend constraint.

If no budget is uploaded in the optimizer, the total spend constraint will equal the entire budget generated by the optimizer. If a budget is uploaded, the optimizer will first account for the total budget uploaded then optimize the remaining total spend. Channels that do not appear in any constraints will default to a spend of $0 if no budget is provided.

Note that the sum of max constraints will have to be greater or equal to the total spend constraint. The optimizer will cap the total budget equal to the total spend constraint.

Make sure the constraints allow the total spend to be reached. If not, the optimizer will error.


🔳 Introduction to setting constraints

The optimizer can be constrained to only search through budgets that you would be capable of implementing. The way that constraints work is as follows:

  • Each row in the constraints table below is a separate constraint.

  • Each row constrains the optimized spend to be between the “min” and “max” across all of the channels included in the “channels” section

The example below will constrain meta_prospecting plus meta_retargeting to be between $0 and $1,000,000 of spend between 2025-03-23 and 2025-03-31, and will constrain influencers to be exactly $100,000 of spend during the same time period.

You can set multiple constraints for different sub-periods. For example, if you are optimizing a quarter you can set different constraints for channels each month but clicking the ‘Add constraint’ button. Note that the Optimizer does not allow setting constraints for overlapping time periods.

Screenshot 2025-03-24 at 11.32.18 AM.png

Optimized spend is in addition to spend specified in the uploaded budget, so you may specify “min” and “max” to be negative, if you are trying to find optimal ways to reduce spend relative to your original plan. See the section on “Finding how to reduce spend by a fixed amount” for more details.

If your model has context variables click the dropdown button to check the values that will be used.


Lower funnel constraints