Success StoriesMarch 21, 2024

How PTC Is Transforming eCommerce with Generative AI, DataStax Astra DB, and Vector Search

How PTC Is Transforming eCommerce with Generative AI, DataStax Astra DB, and Vector Search

Picture yourself establishing a home office and determining the essential products you need to purchase. You’ll likely conduct research on different home office setups, make some initial decisions on which products to buy, and then conduct a text-based search on your preferred eCommerce platform.

PTC Computer's vision was to transform how users engage with their eCommerce platform. The PTC eCommerce platform front-end communicates with backend REST APIs built on PHP (deployed with Laravel) and MySQL (deployed in Digital Ocean). Recognizing the limitations of their MySQL database, they sought a solution that could power their vision effectively. After careful consideration, they chose to partner with DataStax to build: 

  1. A next-generation multi-modal (text, voice, and image) and multilingual (English and Khmer) enhanced AI search engine to help users find the right products
  2. An AI assistant that offers personalized product recommendations, provides customer support and engages with customers via voice in English and Khmer.

With the AI assistant, PTC customers get a seamless omnichannel experience, whether they visit the store and interact with the self-service kiosk, web page, or mobile application. The PTC team is developing features to empower their store sales associates with customer insights gathered from all channels.

PTC’s architecture

Astra Streaming's real-time data pipelines are set up to retrieve pertinent and valuable contextual data swiftly. This includes product inventory, customer profiles, preferences, past interactions across different channels, previous purchases, product documentation, images, manuals, warranty policies, and support knowledge base information. This data is instantly acquired using change data capture (CDC) patterns from existing platforms. Subsequently, employing large language models and multi-modal models contextualizes this enterprise data, storing it efficiently in DataStax Astra DB.

Customers using PTC’s webpage or mobile application can now use natural language queries, voice in their local language (Khmer), and images to interact with AI-powered search or the conversational AI Assistant. If required, the user query is translated to English and analyzed using the LLM to classify intent and route the query to the appropriate flow. 

Hybrid search

LLMs are leveraged to perform named entity recognition to extract keywords like brand, category, specifications, and price and to perform hybrid searches to provide better relevance to search queries. Astra DB’s vector search provides this capability with Index Analyzers for storage attached indexes (SAI), unlocking Astra users' text search. It allows you to find individual words (or stemmed tokens) that have been indexed in a text column, just like other WHERE clauses. This capability combines vector search (approximate nearest neighbor, or ANN) and other SAI indexes to achieve hybrid search. 

Conversational memory

The AI Assistant leverages a well-established architecture pattern named retrieval-augmented generation (RAG). All the assistant data, including the user questions and the assistant responses, chat history, and associated customer behavior, feeds back into Astra DB. This enables the user to have a human-like conversation with the “memory” of past questions and answers; the assistant also incorporates this into its current thinking. 

Data analytics and customer segmentation

With all the previous engagement history, browsing history, and purchases, the AI Assistant agent can talk to a customer differently if the customer is identified as having high intent to buy versus just browsing. This data collection is powerful and can be used to further segment and/or profile customers to run targeted promotional campaigns that translate to increased sales and revenue.

Astra DB minimized hallucinations with higher relevance, providing more throughput and faster response times for PTC. Real-time data and ecosystem integrations made it easier for PTC developers to build production-ready GenAI applications faster. Reading and indexing data at the same time and the ability to store all the vector and structured data together to build a complete RAG application helped the PTC team provide a better user experience. 

What’s next?

As the team continues to innovate, it will provide an improved personalized experience and improve efficiency by automating processes through the AI assistant. The AI assistant will guide the customer to checkout, query delivery status, answer questions about products, solve any technical issues through the support knowledge base, and help submit warranty claims. 

Get started building on Astra DB for free.

Discover more
Vector Search
Share

One-stop Data API for Production GenAI

Astra DB gives JavaScript developers a complete data API and out-of-the-box integrations that make it easier to build production RAG apps with high relevancy and low latency.