Turning Unified Customer Data into Predictive Experiences
Segment has revolutionized how businesses collect and unify customer data. As a leading Customer Data Platform (CDP), Segment provides a central hub for tracking user interactions across websites, mobile apps, servers, and third-party tools, creating a comprehensive view of the customer journey. This unified data is invaluable for understanding your users, but the real challenge lies in activating it – transforming that rich historical and real-time stream into intelligent, personalized experiences as they happen.
How do you use the insights from a user's cross-channel behavior captured in Segment to instantly personalize the search results they see on your website? How do you recommend the perfect next product or piece of content based on their complete interaction history? This is precisely where integrating Segment with Shaped unlocks tremendous value.
Shaped is an AI-native relevance platform designed to ingest real-time event streams, like those unified by Segment, and apply state-of-the-art machine learning to understand user intent, predict behavior, and power personalized search, recommendations, and analytics via simple APIs. This post explains the benefits of connecting these platforms and provides a step-by-step guide on integrating Segment with Shaped using the AWS Kinesis destination.

Why Connect Segment to Shaped? Driving Value Across Use Cases
Connecting Segment's unified data stream to Shaped's AI engine moves you from data collection to intelligent action. It allows you to leverage the comprehensive customer view you've built in Segment to power a wide range of real-time, personalized experiences and gain deeper insights:
- Hyper-Personalized Recommendations: Utilize the rich, cross-channel behavioral data from Segment to deliver truly relevant recommendations:
- Dynamic "For You" Feeds: Curate highly personalized feeds of content or products that adapt based on a user's complete interaction history across all your platforms.
- Contextual Product Recommendations: Suggest relevant items on homepages, product pages, or category listings, informed by Segment data.
- "Similar Item" Discovery: Find items related by deep behavioral patterns learned from Segment events, not just simple metadata.
- Next Best Action/Content: Predict the most relevant next video, article, or action for a user based on their journey so far.
- Cart/Checkout Optimization: Offer intelligent upsells or cross-sells informed by the user's full profile.
- Intelligent & Personalized Search: Transform search from a simple lookup tool into a personalized discovery engine:
- Personalized Search Ranking: Tailor search result order based on individual preferences and behaviors captured across Segment sources.
- Semantic Understanding: Leverage deep learning models trained on Segment data to understand the intent behind queries, improving relevance beyond keywords.
- Improved Keyword Search: Boost the performance of traditional keyword search by incorporating behavioral signals from Segment.
- Advanced Analytics & Deeper Insights: Go beyond standard dashboards by using Shaped's models trained on Segment data:
- Cross-Channel User Journey Analysis: Understand complex user paths and predict future interactions based on patterns learned from the unified Segment data stream.
- Rich User & Item Embeddings: Generate powerful vector representations of users and items for cohort analysis, audience segmentation, and understanding hidden relationships within your catalog and user base.
- Personalization Performance Monitoring: Directly measure the uplift and business impact of AI-driven personalization powered by your Segment data.
- Explainable AI: Gain insights into why the models make certain predictions or recommendations, leveraging the rich feature set derived from Segment events.
- Real-Time Adaptability: Shaped models continuously learn from the live Segment event stream via Kinesis, ensuring all personalization adapts instantly to the latest user interactions.
- Simplified ML Infrastructure: Avoid building and maintaining complex pipelines and ML systems to process Segment data for relevance. Shaped provides the managed AI layer.
How it Works: Segment -> Kinesis -> Shaped
The technical integration leverages AWS Kinesis Data Streams as a reliable, scalable bridge. Segment offers a built-in Kinesis Destination, allowing you to forward your event stream directly to a Kinesis stream provisioned and managed by Shaped. Shaped then securely ingests data from this stream to train its models.
Connecting Segment to Shaped via AWS Kinesis
Here’s the step-by-step process:
Step 1: Create the Shaped Dataset
First, create a dataset in Shaped specifically configured for Segment events. Using the SEGMENT
schema type ensures Shaped sets up the appropriate event schema automatically.
Create a YAML file (e.g., segment_events.yaml
):
Use the Shaped CLI to create the dataset:
Verify the dataset creation status on the Shaped Dashboard or via the CLI (shaped list-datasets
). It will transition from provisioning to ACTIVE
.
Step 2: Retrieve Shaped Kinesis Details
Once the dataset is created in Shaped, retrieve the unique AWS Kinesis Data Stream name and IAM Role ARN associated with it. These are needed for the Segment configuration.
Use the Shaped CLI:
The output will resemble this (ARNs and stream names will be unique to your dataset):
You need two pieces of information for the Segment setup:
- The Stream Name: Extract the name part from the
kinesis_stream_arn
(e.g.,ShapedDatasetStream-abc123
). - The full IAM Role ARN: The value of
kinesis_iam_role_arn
(e.g.,arn:aws:iam::11111111111:role/ShapedDatasetAccessRole-abc123
).
(Note: You can also fetch these details via the Shaped API using a GET request to https://api.shaped.ai/v1/datasets/segment_events
with your API key.)
Step 3: Configure Segment Kinesis Destination
Log in to your Segment workspace and configure the destination:
- Go to the Source you want to stream data from.
- Navigate to Destinations and click Add Destination.
- Search for and select the Amazon Kinesis destination.
- Click Configure Amazon Kinesis.
- Select the Source and click Confirm Source.
- In the destination settings, enter the details obtained from Shaped in Step 2:
- AWS Kinesis Stream Name:
- Enter the Stream Name (e.g.,
ShapedDatasetStream-abc123
). - AWS IAM Role Resource Name (ARN):
- Enter the full IAM Role ARN (e.g.,
arn:aws:iam::11111111111:role/ShapedDatasetAccessRole-abc123
). - AWS Region:
- Enter
us-east-2
(Shaped provisions Kinesis streams in this region for Segment integrations).
- (Optional but Recommended) Filter Events: Consider using Segment's filtering capabilities within the destination settings or upstream in your Source Functions/Protocols to send only the most relevant events for personalization (e.g., key engagement events like views, clicks, purchases, completions). This can improve model focus and efficiency.
- Once configured, Enable the Destination using the toggle switch at the top.
- Save the changes.
Segment will now start forwarding events from your selected source to the Shaped-managed Kinesis stream.
What Happens Next? Fueling AI with Unified Data
With the connection established and data flowing:
- Real-Time Ingestion: Shaped securely ingests the unified event stream from Segment via Kinesis.
- AI Model Training: Shaped automatically trains sophisticated ML models on this rich, cross-channel data, learning complex user behaviors, preferences, and item relationships.
- Personalization APIs: Once models are ready, Shaped's simple APIs allow you to retrieve personalized rankings for search, recommendation slates, or user/item embeddings for analytics – all powered by your Segment data.
- Continuous Adaptation: Models continuously update as new events arrive, ensuring relevance stays high even as user behavior evolves across your platforms.
Conclusion: Activate Your Segment Data for Intelligent Action
Integrating Segment with Shaped transforms your unified customer data from a passive asset into an active driver of real-time personalization and deep user understanding. By following the simple Kinesis integration steps, you can harness the power of state-of-the-art AI to deliver superior recommendations, smarter search results, and richer analytics based on the comprehensive view provided by Segment. Stop just collecting data – start activating it with Shaped to create truly adaptive, personalized experiences.
Ready to unlock the full potential of your Segment data with AI?
Request a demo of Shaped today to see it in action with your specific use case. Or, start exploring immediately with our free trial sandbox.