Audience | Marketers, Platform admins |
Prerequisites |
|
Sampling speeds up audience and trait previews in Customer Studio by materializing a small, representative subset of your schema models into your data warehouse. For large datasets, this optimization can significantly reduce query times and warehouse compute during campaign building.
Learning objectives
After reading this article, you'll be able to:
- Explain how sampling works and when to use it
- Enable and configure sampling for parent and related models
- Use sampled models for faster trait and audience previews
- Monitor and troubleshoot sampling jobs
Overview
Sampling creates a reduced version of your schema models by materializing a subset of rows into dedicated tables in your data warehouse. This allows Hightouch to query smaller, faster subsets of data when generating previews in Customer Studio.
How it works
Here’s how it works:
- A configurable percentage of rows is sampled from your parent model.
- For each sampled parent row, corresponding rows in related and event models are also materialized.
- The sampled tables are stored in the Hightouch Planner schema of your warehouse.
- Sampling runs on a configurable schedule in the background.
This setup allows previews (like traits or audiences) to query a representative subset of your data—ideal for faster iteration and testing.
Supported warehouses
Currently, sampling is supported on the following sources:
The sampled tables will be materialized in the Hightouch Planner schema.
Set up sampling
To enable sampling:
- Go to a parent model in your schema
- Go to the
Sampling
tab - Toggle sampling on
Disabled | Enabled |
---|---|
![]() | ![]() |
You can then configure:
- Sample size: Determines the percentage of your parent model (and any related models) that will be sampled.
- Sample frequency: Determines how often the models get resampled. This schedule also applies to sampling for related models as well unless they're overridden.
- Related models: This table lists all of the related events and models. Tick the checkbox next to each related model you want to sample.
By default, each model will inherit the sampling schedule configured for the parent model. You can override the schedule if you wish.
Last run: This table lists information about the most recent run for each sampled model. If the sampling job has failed, hover over the status to see the error message.
Related model
Sampling for related models is controlled through its parent model. However, you can check if the related model is being sampled by going to the Sampling tab:
Using sampling
After sampling has been enabled and at least one run has successfully completed, you will be able to use the sampled model for certain preview features, such as the ones below.
- Audience: A toggle will be present that allows you to use the sampled model. The result will also indicate that an approximation was returned.
- Trait: A similar toggle will show up next to the preview button.