ecosystem.Ai's Two-Tower Module is now live in Workbench2, so we thought we'd take the opportunity to talk about this revolutionary approach to machine learning, and how it can enhance personalization strategies at scale.
One of the primary challenges for organizations attempting personalization at scale, is that most models can't handle the complexity. The two-tower approach solves this by creating a communication layer between data sets.
What is the Two-Tower Approach?
You can think of a two-tower neural network as a translator fluent in two different languages, standing between two people who'd otherwise have no way to understand each other. Also called a dual-encoder architecture, the name "two-tower" refers to two separate neural networks — the towers — trained together against a single objective: learning to speak the same language. In a recommender system, one tower encodes the user (their behavior, context, history); the other encodes the item (its attributes, metadata, description). Each tower learns to translate its side of the equation into the same vector space, so that a user and an item end up as mathematical profiles that can be placed side by side and compared directly. Compatibility between a customer and an offer is the similarity of their two vectors.
Understanding Vectors
A vector (or embedding) is simply a long list of numbers (with special properties defined by the domain) that acts like a mathematical fingerprint for data. It is typically used to translate text, images, or audio into a format machines can understand. What makes a vector useful is that it can represent two things at once: a magnitude (how big) and a direction (which way). The two-tower approach, at its most basic level, involves transforming raw features into vectors. These vectors are then projected into a vector space, where similarity can be measured. How similarity is measured depends on the type of vector space you are using.
For example, if the vector for "kitten" is mathematically very close to the vector for "cat", the AI understands that they share a similar context. This is the core technology powering modern vector databases, Retrieval-Augmented Generation (RAG), and smart search engines, and, of course, the two-tower approach.
The Three Main Components of the Two-Tower Approach
1. The Raw Features (The Inputs)
Raw features are just the basic, messy facts about two different things. For example, tower A knows things about the customer such as their age, location, and past clicks. Tower B knows things about the product like its price, color, text description, and category. But these two sets of data look completely different — a classic example of comparing apples to pears. You cannot directly compare a user's age of "25" to a product category of "Running Shoes".
2. The Neural Networks (The Translators)
Each tower acts as an independent translator, in the form of a neural network. A neural network is a set of machine learning algorithms inspired by the human brain that use interconnected artificial 'neurons' to recognize complex patterns and make decisions. Tower A takes the messy user data, processes it through the network, and translates it into a customer profile represented by a vector. Tower B takes the messy product data and translates it into a product profile, also represented by a vector.
3. The Shared Embedding Space (The Universal Language)
The shared embedding space is a universal concept language that both 'translators' use. Instead of using words, they translate every raw feature into a long list of numbers (a vector). That vector is a point in the shared embedding space, with a magnitude and direction relative to every other vector in it. When the user's vector and the item's vector land in this same space, you can directly compare how alike they are. Different methods are used to deduce similarity, including cosine, which asks if the vectors point the same way (direction), or euclidean distance which asks how close the two points are in the space (position).
How the Two-Tower Model is used for Customer Engagement
Imagine a library where every book has already been filed onto a shelf by topic (done once, in advance). When a reader walks in, you just figure out what shelf matches their interest and grab nearby books — you don't re-read every book in the library each time someone walks in. The two-tower approach uses a similar mechanism. Because the two towers don't need to look at each other while running, you can pre-compute the product side ahead of time. Overnight, you convert your entire catalogue, which might include millions of items, into vectors once, and store them.
Then, when a customer interacts with your channel, you only need to compute their vector (one quick calculation), then compare it against all the pre-computed product vectors using simple math. Once you've determined which vectors point in a similar direction, you attain a viable product recommendation. This is what makes two-tower models the standard choice for large-scale candidate retrieval — the process of isolating a small, relevant subset of products from a gargantuan catalogue, for millions of customers.
Advantages of the Two-Tower Approach for Customer Engagement
Sub-Second Responsiveness
The two-tower approach pre-calculates product profiles offline which means it can compare a live customer against millions of items in milliseconds, enabling near real-time responses.
Personalization from Moment One (Cold Start)
Traditional systems shy away from new users or new products because they have no historical data. The two-tower approach considers the traits of a new customer (e.g., location, device, referral link) and infers what their persona might be by comparing them to existing customers, recommending the associated items from the catalogue that have vectors pointing in similar directions.
Detecting Real-Time Intent
Customer intent changes fast. A user browsing for office wear in the morning might switch to looking for gym gear at lunch. The User Tower can update a customer's digital profile on the fly based on real-time behavior, updating learnings to make recommendations that have the highest probability of conversion based on current context.
Surfacing Niche Recommendations
Older systems only recommend best-sellers because they have the most data. The two-tower approach understands the meaning behind products. It can surface a niche, low-volume item to the exact customer who wants it based on text or feature alignment, surprising the customer with highly tailored discovery.
Multi-Channel Application
Because the system translates customers and content into a single universal language (embeddings), you can use the exact same model to power personalization across different touchpoints such as on-site search results, in-app home feeds, or push notifications.
Configuring Your Own Two-tower Recommender with ecosystem.Ai
We've brought the two-tower approach's dual-encoder retrieval to ecosystem.Ai's Workbench2. Here, you can configure your own two-tower recommender. The Module is split across three ecosystem components, each with a clear responsibility:
- Workbench2 is the control plane. Users create saved Two-Tower configurations, choose an engine, launch jobs, run concept tests, export embeddings, and bind the exported run to a deployment.
- ecosystem-notebooks is the PyTorch training and embedding sidecar. It is used when the saved configuration selects the pytorch_notebooks engine.
- ecosystem-runtime is the real-time scoring plane. It does not train models; it reads the deployed configuration and ranks the request's offer matrix using exported embeddings and similarity scoring.
You can find out more about the Two-tower Module on ecosystem.Ai's developer site.
Two-tower Approach Use Cases
The two-tower approach was initially developed to solve the scalability problem in large-scale recommender systems and search engines, where evaluating millions of user-item pairs jointly is impossible in real-time.
Consider a customer logging into an e-commerce website. On the website, there are thousands of products that the customer can choose from, but they only end up buying two or three items. Recommenders have no conception as to why this might be. All they know is that for every positive result (item bought, offer taken up) there are thousands of negative results, with an accompanying absence of data. The two-tower approach solves the problem of sparse data by finding similarities between profiles rather than relying solely on raw data.
Key use cases for the two-tower approach include:
- Large-Scale Recommender Systems: Standard for content platforms (e.g., YouTube, Instagram, TikTok) to match user context and history with millions of videos or posts in real-time.
- E-Commerce Product Retrieval: Powers personalized product recommendations by matching a user's session data with product catalogs and features like titles, brands, and categories.
- Semantic Search Engines: Maps complex natural language search queries directly to relevant web pages, documents, or ads, bypassing simple keyword matching.
Conclusion
Every recommender system is really answering the same question: does this business understand its customer, or is it guessing? For decades, most systems guessed, matching best-sellers to everyone, treating new customers as blank slates, and waiting for enough data to accumulate before making a confident move.
The two-tower approach changes this by translating customers and products into a shared mathematical language. It doesn't need a customer's full history to understand them, only enough signal to place them on the map, and the map does the rest.
Sub-second responsiveness, cold-start personalization, niche discovery, and multi-channel consistency are all downstream of the same architectural decision to separate the "who" from the "what" so that both can be understood on their own terms, then brought together at the moment it counts.
With ecosystem.Ai's Two-Tower Module now live in Workbench2, that architecture isn't theoretical. It's configurable — a capability you can shape around your own customers, your own catalogue, and your own definition of what a good match looks like.
Sources
- Huang, J., Chen, J., Lin, J., Qin, J., Feng, Z., Zhang, W. and Yu, Y. (2025) 'A comprehensive survey on retrieval methods in recommender systems', ACM Transactions on Information Systems, 44(1), Article 28. doi: 10.1145/3771925.
- Roizner, M. (2023) Two-tower networks and negative sampling in recommender systems. Towards Data Science. Available at: towardsdatascience.com (Accessed: 9 July 2026).
- ecosystem.Ai (n.d.) Two-Tower Module. Available at: developer.ecosystem.ai (Accessed: 9 July 2026).




