# HMAR: Hierarchical Masked Attention for Multi-Behaviour Recommendation

arXiv: https://arxiv.org/abs/2405.09638 · HTML: https://mlsanity.com/paper/2405.09638/

## Key facts

- Cited by 2 papers in the map (data through 14 Oct 2026).
- Builds on 15 of its 20 references that are in the map.
- First posted on arXiv 29 Apr 2024.

## Builds on (most cited first, 15 of 15)

- [Adam: A Method for Stochastic Optimization](https://mlsanity.com/paper/1412.6980/) (2014)
- [Self-Attentive Sequential Recommendation](https://mlsanity.com/paper/1808.09781/) (2018)
- [Neural Collaborative Filtering](https://mlsanity.com/paper/1708.05031/) (2017)
- [BERT4Rec: Sequential Recommendation with Bidirectional Encoder Representations from Transformer](https://mlsanity.com/paper/1904.06690/) (2019)
- [Personalized Top-N Sequential Recommendation via Convolutional Sequence Embedding](https://mlsanity.com/paper/1809.07426/) (2018)
- [S^3-Rec: Self-Supervised Learning for Sequential Recommendation with Mutual Information Maximization](https://mlsanity.com/paper/2008.07873/) (2020)
- [ReZero is All You Need: Fast Convergence at Large Depth](https://mlsanity.com/paper/2003.04887/) (2020)
- [Intent Contrastive Learning for Sequential Recommendation](https://mlsanity.com/paper/2202.02519/) (2022)
- [Multi-Behavior Hypergraph-Enhanced Transformer for Sequential Recommendation](https://mlsanity.com/paper/2207.05584/) (2022)
- [Knowledge-Enhanced Hierarchical Graph Transformer Network for Multi-Behavior Recommendation](https://mlsanity.com/paper/2110.04000/) (2021)
- [Graph Meta Network for Multi-Behavior Recommendation](https://mlsanity.com/paper/2110.03969/) (2021)
- [Multiplex Behavioral Relation Learning for Recommendation via Memory Augmented Transformer Network](https://mlsanity.com/paper/2110.04002/) (2021)
- [CARCA: Context and Attribute-Aware Next-Item Recommendation via Cross-Attention](https://mlsanity.com/paper/2204.06519/) (2022)
- [Knowledge Enhancement for Contrastive Multi-Behavior Recommendation](https://mlsanity.com/paper/2301.05403/) (2023)
- [Multi-Behavior Recommendation with Cascading Graph Convolution Networks](https://mlsanity.com/paper/2303.15720/) (2023)

## Built on by (most cited first, 2 of 2)

- [Multi-Behavior Recommender Systems: A Survey](https://mlsanity.com/paper/2503.06963/) (2025)
- [Towards Efficient Hypergraph and Multi-LLM Agent Recommender Systems](https://mlsanity.com/paper/2512.06590/) (2025)

## Abstract (arXiv)

In the context of recommendation systems, addressing multi-behavioral user interactions has become vital for understanding the evolving user behavior. Recent models utilize techniques like graph neural networks and attention mechanisms for modeling diverse behaviors, but capturing sequential patterns in historical interactions remains challenging. To tackle this, we introduce Hierarchical Masked Attention for multi-behavior recommendation (HMAR). Specifically, our approach applies masked self-attention to items of the same behavior, followed by self-attention across all behaviors. Additionally, we propose historical behavior indicators to encode the historical frequency of each items behavior in the input sequence. Furthermore, the HMAR model operates in a multi-task setting, allowing it to learn item behaviors and their associated ranking scores concurrently. Extensive experimental results on four real-world datasets demonstrate that our proposed model outperforms state-of-the-art methods. Our code and datasets are available here (https://github.com/Shereen-Elsayed/HMAR).
