> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mixpeek.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Architecture

> How Mixpeek's two-tower design decouples ingestion from retrieval and learns from usage

Mixpeek follows a **two-tower architecture** — a well-known pattern in recommendation systems adapted for multimodal search.

![Two towers: document tower writes N representation spaces at ingest, query tower reads and fuses them at search time, interaction signals close the feedback loop](https://mintcdn.com/mixpeek/o18CfVBlvyb5Tvo5/assets/relevance/two-towers.svg?fit=max\&auto=format\&n=o18CfVBlvyb5Tvo5\&q=85\&s=d4d7244ad08b3393ae7511c8fab8130d)

## Document Tower (Ingestion)

Source files enter through a [bucket](https://docs.mixpeek.com/docs/platform/data-model.md#buckets), trigger one or more [collections](https://docs.mixpeek.com/docs/platform/data-model.md#collections), and pass through the Ray engine for feature extraction. Each collection produces a different representation — text embeddings, multimodal embeddings, metadata, taxonomy labels — all stored as named vectors on a single point in [MVS](https://docs.mixpeek.com/docs/vector-store/overview.md), the Mixpeek Vector Store.

Documents are encoded **once at ingest time**. Adding a new extractor or updating a taxonomy triggers a re-process on the bucket — documents get new representations without changing the ingestion path.

## Query Tower (Retrieval)

A query arrives, gets encoded, and passes through a [multi-stage retriever](https://docs.mixpeek.com/docs/retrieval/retrievers.md). The key stage is **feature search**, which runs a separate vector query per embedding space and fuses the results.

The fusion strategy determines how per-feature scores combine into a final ranking:

| Strategy | Behavior |
| - | - |
| `rrf` | Rank-based, no tuning needed |
| `weighted` | Manual weights you set |
| `learned` | Weights sampled from Beta distributions, updated by user behavior |

See [Fusion Strategies](https://docs.mixpeek.com/docs/relevance/fusion-strategies.md) for the full comparison.

## Closing the Loop

With [learned fusion](https://docs.mixpeek.com/docs/relevance/learned-fusion.md), the two towers aren't static — they're connected by a feedback loop:

1. **Results** are shown to users
2. **Interactions** (clicks, purchases, skips) are stored in the namespace's `mxp_retriever_interactions` collection and, when analytics is enabled, in the analytics store
3. **Thompson Sampling** aggregates interactions into Beta(α, β) distributions per feature — α counts positive signals, β counts non-engagement
4. **Sampled weights** are drawn from those distributions on each query, naturally balancing exploration and exploitation
5. Weights converge toward the optimal blend as interactions accumulate

The system handles cold start through [hierarchical fallback](https://docs.mixpeek.com/docs/relevance/learned-fusion.md#hierarchical-fallback): personal weights → demographic segment → global → uniform prior. With zero interactions, learned fusion behaves identically to RRF.

## What Makes This Different

Standard two-tower systems learn a single embedding space. Mixpeek's document tower fans out into **N representation spaces** (visual, audio, text, multimodal, metadata), and the query tower traverses them in sequence through multi-stage retrieval. Learning happens at the **fusion layer** — which spaces to weight — not inside the embeddings themselves.

This means you can add a new extractor, re-process your data, and the bandit will automatically discover whether the new feature improves results — without retraining any model.

## Related

* [Feedback Loop Tutorial](https://docs.mixpeek.com/docs/tutorials/feedback-loop.md) — step-by-step setup guide
* [Learned Fusion](https://docs.mixpeek.com/docs/relevance/learned-fusion.md) — Thompson Sampling algorithm details
* [Interaction Signals](https://docs.mixpeek.com/docs/retrieval/interactions.md) — which signals to capture and when
* [Fusion Strategies](https://docs.mixpeek.com/docs/relevance/fusion-strategies.md) — all 5 strategies compared


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.