Search documentation...

K
ChangelogBook a demoSign up

Sampling

Overview

Model sampling materializes a subset of each of your schema models into separate tables in your data warehouse. These sampled models can then be used by Hightouch to speed up model previews. This can be especially beneficial for significantly large models. By only querying a subset of rows, it reduces the amount of time and warehouse compute required to perform a query.

The sampling process runs in the background on a specified schedule. The process involves materializing a (configurable) percentage of your parent model. Then, for each sampled row, we materialize corresponding rows in each of the related and event models. This ensures a consistent view of the rows associated with each user in the sampled parent model.

Sampling requires WRITE permissions to your data warehouse in order to materialize tables. Please ensure that the Lightning sync engine is enabled for your source.

Currently, sampling is supported on the following sources:

The sampled tables will be materialized in the Hightouch Planner schema.

How to set up sampling

To enable sampling:

  1. Go to a parent model in your schema
  2. Go to the Sampling tab and enable it
DisabledEnabled
Enabling sampling in the Hightouch UI

After enabling Sampling, there are a variety of options that can be configured:

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.

Related models table

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.

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:

Sampling configuration for related model

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.

Sampled audience

Trait: A similar toggle will show up next to the preview button.

Sampled trait

Ready to get started?

Jump right in or a book a demo. Your first destination is always free.

Book a demoSign upBook a demo

Need help?

Our team is relentlessly focused on your success. Don't hesitate to reach out!

Feature requests?

We'd love to hear your suggestions for integrations and other features.

Last updated: Dec 3, 2024

On this page

OverviewHow to set up samplingRelated modelUsing sampling

Was this page helpful?