Skip to contentSkip to navigationSkip to topbar
On this page

Customer Memory


Customer Memory is a feature that allows an AI Assistant to become customer-aware. By integrating with Twilio Segment, the Assistant can access and store relevant customer data, enabling it to personalize interactions based on previous engagements and customer profiles. Two key engines power this capability:


Configure Customer Memory

configure-customer-memory page anchor

In the Twilio Console, navigate to the Segment Workspace section of AI Assistants Settings(link takes you to an external page).

If you already have a Segment workspace with Unify

if-you-already-have-a-segment-workspace-with-unify page anchor
  1. Name your workspace for reference from within AI Assistants.
  2. Find your Space ID In Segment: From Segment, visit Unify -> Unify Settings -> API access and copy your "space ID" (begins with spa_) to the Segment Workspace Space ID field in AI Assistants Settings.
  3. Profile access token: From the same API access screen, click the Generate Token button to generate a new Profile access token for your AI Assistants. Store the token value securely, and copy it to the Segment Workspace Profile Access Token settings in AI Assistants.
  4. Write Key: Required to write data back to Segment. You can either use an existing source or create a new Segment source:
  • Create a new source:
    1. From Segment, view your Connections -> Sources create a new Node.js source.
    2. Click into the new source -> Settings -> API Keys and copy the 'Write Key' into the Segment Workspace Write Key setting in AI Assistants.
    3. Connect your new source to your Unify space: Visit Unify -> Unify Settings -> Profile sources and click Connect source to add your newly created Node.js source.
  • Use an existing source:
    1. In Segment, go to an existing source -> Settings -> API Keys and copy the Write Key from your new source into the Segment Workspace Write Key setting in AI Assistants.

If you don't have a Segment account

if-you-dont-have-a-segment-account page anchor
  1. From AI Assistants Settings, create a free Segment account using your Twilio credentials.
  2. Once you've created your account, the necessary values will auto populate in the Assistants Segment configuration.

Once you've configured your Segment settings, you can enable the AI Personalization Engine and AI Perception Engine for each Assistant you create in your Assistant's base configuration, (Assistant -> Settings).

When your Assistant uses either customer engine, it passes the identity associated with that session to Segment. If you're using the API, the identity parameter of the POST request defines the identity. In the Simulator, you define the identity from the UI.

The user identity must match the form: type:value, and the type field must correlate with an identifier on the profile within Segment. Learn more about identity resolution in the Segment Unify documentation(link takes you to an external page). For example:

1
"email:example@example.com"
2
// or
3
"phone:15554455"

You can debug responses from each engine in the Simulator to understand what data your Assistant is receiving from or sending to Segment.


Manage Segment profile data via API

manage-segment-profile-data-via-api page anchor

You can manage your Segment profile data using the Segment Profile API(link takes you to an external page).

Need some help?

Terms of service

Copyright © 2024 Twilio Inc.