Event Data

Cortex extends the value of your business’s unique data by enabling anyone to leverage that data into Machine Learning Pipelines. The types of data supported by Cortex fall into two categories: events and attributes.

Events (required) Attributes (optional)
Actions taken by or on one or more objects at a particular point in time.

Example: Customer A completes a purchase event on item B at time C.
Characteristics or traits associated with the objects tied to your events.

Examples: Customer A has job title X, Item B belongs to category Y.


In this guide, we’ll provide an overview of Event Data and discuss the various ways that it may be ingested into Cortex. For an overview of Attribute Data, click here.

What are events?

Event data consists of a stream of actions taken by your users (or any other type of object) at a particular point in time. Some examples of events include –

User XYZ logs in   →   User XYZ clicks on item ABC   →   User XYZ adds item ABC to cart   →   User XYZ purchases item ABC

Events form the basic building blocks of any Cortex pipeline, so it’s required that event data be present in your account before you may begin building pipelines. At minimum, each event needs to contain three pieces of information listed below.

  • User ID: A unique identifier for the user that completed the event. If your account is configured to make predictions about objects other than users (e.g. items, home listings, etc.), include an ID for these objects instead.
  • Timestamp: Time at which the event was recorded.
  • Type: Type of event that was recorded (e.g. purchase).

Optionally, your events can also include any other information which paints a more detailed picture of the user completing the event, or conditions of the event itself. The more info you include in your events, the wider the set of predictions you can make, and the more accurate your predictions will be.

Your events can reference more than one type of object (e.g. user and item), but each Cortex account can only be configured to make predictions about one or the other. If you’d like to generate personalized recommendations for each user, your events must also contain an item ID indicating which item the user interacted with. For example, an ecommerce company might include the following details for a customer purchase event.

user_id: ABC           # REQUIRED: Unique ID for the user completing the event
type: purchase         # REQUIRED: Type of event completed by the user
timestamp: 1590451200  # REQUIRED: Timestamp of when the event occurred
device: mobile         # The device on which the event occurred
coupon_discount: 4.99  # The dollar amount of discounts applied to the purchase
sale_price: 45.00      # The final sale price that the user paid
item_id: XYZ           # Unique ID for the purchased item

How do I send event data into Cortex?

There are two ways that you can ingest event data into Cortex:

1) Real-time APIs

Cortex offers a set of scalable APIs to stream live events into the platform right as they occur. These APIs can be deployed server-side or client-side (including integrations with Google Tag Manager and Tealium).

For details about how to send event data into Cortex via real-time APIs, read the documentation for Vidora’s Behavioral API.

2) Batch File Uploads

Alternatively, you may transfer batches of event data into Cortex from your data lake or analytics vendor. To do this, schedule a recurring file upload into a directory hosted by either you or Vidora (e.g. AWS S3 bucket). Your Cortex account will automatically ingest events contained inside any file uploaded to this directory.

Read this guide for more details about how to implement a batch file upload.

Related Links

Still have questions? Reach out to support@vidora.com for more info!

Table of Contents