---
title: 'ICDM: Debiasing ID-based CF Models'
url: https://www.emergentmind.com/topics/id-based-cf-debias-model-icdm
type: topic
---

# ICDM: Debiasing ID-based CF Models

The ID-based Collaborative Filtering Debias Module (ICDM) is a key component in modern large-scale recommender systems that addresses entrenched biases in ID-based collaborative filtering (CF) representations. Implemented within the single-stage Dual-Aligned Semantic IDs (DAS) framework, ICDM is designed to disentangle signal and bias in user and item representations, producing debiased embeddings for contrastive alignment with semantic code-based identifiers, thereby improving downstream recommendation performance and preserving semantic integrity [2508.10584].

## 1. Purpose and Placement of ICDM

ICDM targets two pervasive forms of bias in CF models: **item popularity bias** (a small subset of items dominating clicks) and **user conformity bias** (users disproportionately clicking on popular items). These biases distort learned embeddings and, without correction, can pollute the alignment with semantic identifiers derived from multi-modal large language model (MLLM) features. ICDM operates between the User & Item Semantic Model (which outputs quantized, codebook-based semantic IDs $z_u, z_i$) and the downstream Multi-view Dual-Aligned Mechanism (MDAM), which aligns collaborative and semantic signals. 

The module splits each user or item ID-based representation into a “true” (signal) factor and a “bias” factor, enforces orthogonality and similarity constraints for disentanglement, and utilizes only the debiased factors in the downstream alignment. This ensures that the semantic code space benefits from collaborative cues without inheriting distortion from CF biases.

## 2. Formal Objectives and Loss Functions

Let $U, I \in \mathbb{R}^{d_{CF}}$ denote raw CF embeddings for users and items. Four multi-layer perceptron (MLP) encoders decompose these:

- User-Interest (debiased): $c_u^{int} = f_{int}(U) \in \mathbb{R}^h$
- User-Conformity (bias): $c_u^{con} = f_{con}(U) \in \mathbb{R}^h$
- Item-Content (debiased): $c_i^{pro} = f_{pro}(I) \in \mathbb{R}^h$
- Item-Popularity (bias): $c_i^{pop} = f_{pop}(I) \in \mathbb{R}^h$

Biased representations are constructed as $c_u = \text{MLP}([\;c_u^{int},\,c_u^{con}\;])$ and $c_i = \text{MLP}([\;c_i^{pro},\,c_i^{pop}\;])$.

**Disentangling Losses:**

Two constraints are enforced:

1. **Similarity Penalty**
   $$
   \mathcal{L}_{sim} = \sum_{b=1}^B \left[ (1 - \cos(c_{u_b}^{con}, c_{u_b}^{int})) + (1 - \cos(c_{i_b}^{pop}, c_{i_b}^{pro})) \right]
   $$
2. **Orthogonality Penalty**
   $$
   \mathcal{L}_{orth} = \sum_{b=1}^B \left[ \cos^2(c_{u_b}^{con}, c_{u_b}^{int}) + \cos^2(c_{i_b}^{pop}, c_{i_b}^{pro}) \right]
   $$
   
The combined disentangling loss:
$$
\mathcal{L}_{cf\_disentangled} = \mathcal{L}_{sim} + \mathcal{L}_{orth}
$$

**Supervised CF Objectives:**

- **Biased CF Loss:**
  $$
  \mathcal{L}_{cf\_bias} = -\sum_{(u, i) \in \mathcal{D}^+} \log \frac{\exp(c_u^\top c_i)}{\sum_{j\in neg} \exp(c_u^\top c_{i_j})}
  $$
- **Unbiased CF Loss:**
  $$
  \mathcal{L}_{cf\_unbias} = -\sum_{(u, i) \in \mathcal{D}^+} \log \frac{\exp((c_u^{int})^\top c_i^{pro})}{\sum_{j\in neg} \exp((c_u^{int})^\top c_{i_j}^{pro})}
  $$

The total ICDM loss:
$$
\mathcal{L}_{CF\_all} = \mathcal{L}_{cf\_bias} + \mathcal{L}_{cf\_unbias} + \gamma\,\mathcal{L}_{cf\_disentangled}
$$
with $\gamma$ controlling the tradeoff.

## 3. Multi-view Contrastive Alignment and Mutual Information Framework

ICDM supplies debiased CF signals that are contrastively aligned with Semantic IDs across six cross-views using InfoNCE objectives, which lower-bound mutual information between respective pairs:

1. **Dual User-to-Item:**
   - $z_u \rightarrow c_i^{pro}$: $\mathcal{L}_{u2i,z_u}$
   - $c_u^{int} \rightarrow z_i$: $\mathcal{L}_{u2i,z_i}$
2. **Dual User-to-User / Item-to-Item:**
   - $z_u \leftrightarrow c_u^{int}$: $\mathcal{L}_{u2u}$
   - $z_i \leftrightarrow c_i^{pro}$: $\mathcal{L}_{i2i}$
3. **Dual Co-occurrence:**
   - User co-click $z_u \leftrightarrow y_u$: $\mathcal{L}_{co\_u2u}$
   - Item co-click $z_i \leftrightarrow y_i$: $\mathcal{L}_{co\_i2i}$

Total alignment loss:
$$
\mathcal{L}_{Align\_all} = \mathcal{L}_{u2i,z_u} + \mathcal{L}_{u2i,z_i} + \mathcal{L}_{u2u} + \mathcal{L}_{i2i} + \mathcal{L}_{co\_u2u} + \mathcal{L}_{co\_i2i}
$$

Each term encourages mutual information maximization between semantic and collaborative representations, facilitating more robust multimodal recommendation.

## 4. Joint Training Objective and Unified Optimization

ICDM operates within a single-stage end-to-end system. The complete loss integrates semantic quantization, ICDM, and multi-view alignment:
$$
\min_{\text{all parameters}}
    \underbrace{\mathcal{L}_{Sem\_all}}_{\text{quantization}}
    + \alpha\,\underbrace{\mathcal{L}_{CF\_all}}_{\text{ICDM}}
    + \beta\,\underbrace{\mathcal{L}_{Align\_all}}_{\text{MDAM}}
$$
with hyperparameters $\alpha,\;\beta$ tuning the relative importance of each sub-module.

All modules—including RQ-VAE codebooks for semantic vector quantization, four MLPs for factor disentanglement, and the contrastive aligner—are optimized jointly via AdamW. The one-stage nature of DAS avoids information loss and inflexibility associated with prior two-stage approaches.

## 5. Implementation Workflow

A high-level pseudocode outline for a training iteration is as follows:

```python
# Inputs: Pretrained MLLM features, ID-based features
# Modules: UISM (semantic quantization), ICDM (CF debias), MDAM (alignment)
for minibatch:
    # 1. Semantic quantization (UISM)
    s_u, s_i = MLLM_encoders(...)
    z_u, z_i = quantize_and_pool(s_u, s_i)
    L_Sem = reconstruction_loss(s_u, z_u) + ...

    # 2. CF Debias (ICDM)
    U, I = ID_feature_encoder(...)
    c_u^int = f_int(U); c_u^con = f_con(U)
    c_i^pro = f_pro(I); c_i^pop = f_pop(I)
    L_cf_disentangled = similarity_and_orth_losses(...)
    c_u = MLP([c_u^int, c_u^con])
    c_i = MLP([c_i^pro, c_i^pop])
    L_cf_bias = biased_cf_loss(...)
    L_cf_unbias = unbiased_cf_loss(...)
    L_CF_all = L_cf_bias + L_cf_unbias + gamma * L_cf_disentangled

    # 3. Multi-view alignment (MDAM)
    positives = collect_pairs(...)
    L_Align_all = nce_losses(positives)

    # 4. Global loss and step
    L_total = L_Sem + alpha * L_CF_all + beta * L_Align_all
    optimizer.step(L_total)
```

## 6. Hyperparameter Scheme, Ablations, and Empirical Findings

### Key Hyperparameters

| Module                    | Value(s)                        | Notes                                    |
|---------------------------|---------------------------------|------------------------------------------|
| Semantic quantization     | $d_{user}=1024$, $d_{item}=256$ | 3 codebooks, 512 codes/level, dim=32     |
| ICDM: $\gamma$, $\alpha$  | $0.1$, $1.0$                    | Disentangle term, UISM-ICDM loss balance |
| Alignment: $\beta$, $\tau$| $0.5$, $\tau\in\{0.07,0.1\}$     | InfoNCE temperature, co-occ. bank $10^6$ |
| Optimization              | AdamW, lr $=1\!\times\!10^{-4}$ | batch $=1024$, 16$\times$A100 GPUs       |

### Offline Ablations

Incremental ablations highlight that inclusion of ICDM improves AUC from 0.8048 to 0.8050 and GAUC from 0.7433 to 0.7434. Removal of any dual-u2i, dual-i2i/u2u, or co-occurrence terms each reduces AUC by 0.4–0.6 ‰, indicating the necessity of multi-view contrastive mechanisms for optimal information integration.

### Online Performance

Deployment results show a +3.48% overall increase in eCPM, with +8.98% in cold-start user segments. *This suggests effective transfer of collaborative signals to semantic ID space and improved generalizability in data-sparse regimes.*

## 7. Significance and Role within Industrial Recommender Systems

ICDM functions as a debiasing intermediary that ensures collaborative signals can be contrastively integrated with semantic codes free from the confounding effects of popularity and conformity. In one-stage frameworks such as DAS, this enables simultaneous optimization of semantic quantization, collaborative filtering, and contrastive alignment. The design permits maximization of mutual information, minimizes information loss, and allows fine-grained control over the transfer of collaborative cues [2508.10584]. The result is more robust, accurate, and generalizable recommender systems, as validated in extensive industrial deployments.

Source: https://www.emergentmind.com/topics/id-based-cf-debias-model-icdm