Build Feature Experimentation audiences in ODP

  • Updated
This feature is in beta. Apply on the Optimizely beta signup page or contact your Customer Success Manager.

Use the real-time audience builder to create, edit, and manage audiences for Optimizely Feature Experimentation directly within Optimizely Data Platform (ODP). Create specific customer groups using ODP audiences, attributes, and event data, then target these groups within your flag rules. This unified approach lets you conduct controlled experiments with an expanded dataset without increasing your project's datafile.

Prerequisites

  • An integration between Feature Experimentation and ODP .
  • A Feature Experimentation account.
  • An ODP account.

Create a real-time audience

To access the real-time audience builder, log in using your Feature Experimentation or ODP account. If you log in through a Feature Experimentation instance, click Audiences to redirect to the ODP Audiences page. If you open ODP directly, go to Customers > Audiences. Complete the following steps to create a Feature Experimentation audience:

  1. Click New Audience and select Feature Experimentation Audience.

  2. Enter an Audience Name and an Audience Description. Click Create

  3. Click + Add Group to add your target group of customers using the following attributes:

    1. Attributes – Add your Feature Experimentation attributes
    2. Data Platform Audiences – Add existing ODP audiences. 
    3. Data Platform Attributes – Add ODP attribute conditions.
    4. Data Platform Events – Add ODP event conditions
  4. Add or delete attribute or event conditions
  5. Click Save Changes to add your audience to the list of audiences. You can now use this audience to target audiences for flag rules.

Create an advanced audience using Code Mode

Click Code Mode in Feature Experimentation to access the code editor and define your JSON audience combinations. 

Get audience identifiers

Each condition is a JSON object with an audience_id. You can add these identifiers directly in Code Mode.

Define the conditions

Conditions are joined together in lists.

  • The first element in each list is an operator, "and", "or", or "not", and the rest of the conditions  combine using that operator.
  • You can replace any individual condition with another list, which lets you create a nested structure of "and" and "or" conditions.
  • A "not" list should only have one condition or list, which negates the result. A "not" with a list of other conditions like ["not", ["and", {...}, {...}]] can negate the entire result of the child condition list.

The following example shows how you could define audience combination conditions. You can also create a feature with an audience combination in Optimizely and look at the Code Mode page.

// "User who loves salads"
// or "User who loves sandwiches"
[
  "or",
  {
    "audience_id": 1038980040
  },
  {
    "audience_id": 1033280055
  }
]

// "User who loves salads"
// or "User who loves sandwiches"
// or does not "Like both salads & sandwiches"
[
  "or",
  {
    "audience_id": 1038980040
  },
  {
    "audience_id": 1033280055
  },
  [
    "not",
    {
      "audience_id": 1120870079
    }
  ]
]

// Is not "User who loves salads"
// AND is not "User who loves sandwiches"
[
  "not",
  [
    "and",
    {
      "audience_id": 1038980040
    },
    {
      "audience_id": 1033280055
    }
  ]
]

Troubleshoot code mode

See Create advanced audience combinations in Feature Experimentation to understand common troubleshoot errors that can arise while using Code Mode.

Create attributes

Open the Attributes tab and click New Attribute in ODP to manage attributes that you can use to create your Experimentation audiences. 

Enter the following information when creating an attribute in ODP:

  • Project – Select your Feature Experimentation project. 
  • Attribute Name – Enter an attribute name. 
  • Key / Api Name – Enter an attribute key
  • (Optional) Attribute Description – Enter a detailed description of your attribute.  

Search and filter audiences

Search for a Feature Experimentation audience by entering the audience name in the search bar. You can also filter the audience list by selecting your Feature Experimentation project from the Project drop-down list and FX from the Type drop-down list. 

Use audiences in Feature Experimentation

Use your audiences to target specific users in your targeted deliveriesA/B tests, and multi-armed bandit optimizations.