Datasets:

Modalities:
Tabular
Text
Formats:
parquet
ArXiv:
Libraries:
Datasets
pandas
License:
File size: 11,580 Bytes
3d127dd
 
 
 
 
 
 
 
 
666b20c
5ed1710
 
 
e30b9ec
 
 
5ed1710
e30b9ec
 
5ed1710
 
e30b9ec
 
 
5ed1710
e30b9ec
 
5ed1710
 
e30b9ec
 
 
5ed1710
e30b9ec
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5ba1508
3d127dd
 
 
 
 
 
9b63850
3d127dd
 
 
 
 
763ee6b
 
3d127dd
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5b7739c
3d127dd
9b63850
 
 
 
 
 
 
 
 
7ec4728
9b63850
 
 
 
 
7ec4728
 
 
9b63850
 
7ec4728
 
 
9b63850
 
 
 
 
 
7ec4728
 
 
 
 
9b63850
 
7ec4728
9b63850
 
7ec4728
9b63850
 
7ec4728
9b63850
 
 
 
7ec4728
9b63850
 
 
 
7ec4728
9b63850
 
3d127dd
 
 
 
 
 
 
 
 
 
 
 
66e0328
3d127dd
 
 
 
 
 
 
 
 
 
 
dbba6e1
3d127dd
1cdedcc
 
 
 
 
 
9b63850
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
---
license: apache-2.0
tags:
- recsys
- retrieval
- dataset
pretty_name: Yambda-5B
size_categories:
- 1B<n<10B

configs:
- config_name: flat-50m
  data_files:
#     - flat/50m/likes.parquet
#     - flat/50m/listens.parquet
#     - flat/50m/unlikes.parquet
    - flat/50m/multi_event.parquet
#     - flat/50m/dislikes.parquet
#     - flat/50m/undislikes.parquet
- config_name: flat-500m
  data_files:
#     - flat/500m/likes.parquet
#     - flat/500m/listens.parquet
#     - flat/500m/unlikes.parquet
    - flat/500m/multi_event.parquet
#     - flat/500m/dislikes.parquet
#     - flat/500m/undislikes.parquet
- config_name: flat-5b
  data_files:
#     - flat/5b/likes.parquet
#     - flat/5b/listens.parquet
#     - flat/5b/unlikes.parquet
    - flat/5b/multi_event.parquet
#     - flat/5b/dislikes.parquet
#     - flat/5b/undislikes.parquet
# - config_name: sequential-50m
#   data_files:
#     - sequential/50m/likes.parquet
#     - sequential/50m/listens.parquet
#     - sequential/50m/unlikes.parquet
#     - sequential/50m/multi_event.parquet
#     - sequential/50m/dislikes.parquet
#     - sequential/50m/undislikes.parquet
# - config_name: sequential-500m
#   data_files:
#     - sequential/500m/likes.parquet
#     - sequential/500m/listens.parquet
#     - sequential/500m/unlikes.parquet
#     - sequential/500m/multi_event.parquet
#     - sequential/500m/dislikes.parquet
#     - sequential/500m/undislikes.parquet
# - config_name: sequential-5b
#   data_files:
#     - sequential/5b/likes.parquet
#     - sequential/5b/listens.parquet
#     - sequential/5b/unlikes.parquet
#     - sequential/5b/multi_event.parquet
#     - sequential/5b/dislikes.parquet
#     - sequential/5b/undislikes.parquet

---

# Yambda-5B β€” A Large-Scale Multi-modal Dataset for Ranking And Retrieval

**Industrial-scale music recommendation dataset with organic/recommendation interactions and audio embeddings**

 [πŸ“Œ Overview](#overview) β€’ [πŸ”‘ Key Features](#key-features) β€’ [πŸ“Š Statistics](#statistics) β€’ [πŸ“ Format](#data-format) β€’ [πŸ† Benchmark](#benchmark) β€’ [⬇️ Download](#download) β€’ [❓ FAQ](#faq)

## Overview

The Yambda-5B dataset is a large-scale open database comprising **4.79 billion user-item interactions** collected from **1 million users** and spanning **9.39 million tracks**. The dataset includes both implicit feedback, such as listening events, and explicit feedback, in the form of likes and dislikes. Additionally, it provides distinctive markers for organic versus recommendation-driven interactions, along with precomputed audio embeddings to facilitate content-aware recommendation systems.

Preprint: https://arxiv.org/abs/2505.22238

## Key Features

- 🎡 4.79B user-music interactions (listens, likes, dislikes, unlikes, undislikes)
- πŸ•’ Timestamps with global temporal ordering
- πŸ”Š Audio embeddings for 7.72M tracks
- πŸ’‘ Organic and recommendation-driven interactions
- πŸ“ˆ Multiple dataset scales (50M, 500M, 5B interactions)
- πŸ§ͺ Standardized evaluation protocol with baseline benchmarks

## About Dataset

### Statistics

| Dataset     |     Users |     Items |       Listens |      Likes |   Dislikes |
|-------------|----------:|----------:|--------------:|-----------:|-----------:|
| Yambda-50M  |    10,000 |   934,057 |    46,467,212 |    881,456 |    107,776 |
| Yambda-500M |   100,000 | 3,004,578 |   466,512,103 |  9,033,960 |  1,128,113 |
| Yambda-5B   | 1,000,000 | 9,390,623 | 4,649,567,411 | 89,334,605 | 11,579,143 |

### User History Length Distribution

![user history length](assets/img/user_history_len.png "User History Length")

![user history length log-scale](assets/img/user_history_log_len.png "User History Length Log-scale")

### Item Interaction Count

![item interaction count log-scale](assets/img/item_interactions.png "Item Interaction Count Log-scale")

## Data Format

### File Descriptions

| File                       | Description                                 | Schema                                                                                  |
|----------------------------|---------------------------------------------|-----------------------------------------------------------------------------------------|
| `listens.parquet`          | User listening events with playback details | `uid`, `item_id`, `timestamp`, `is_organic`, `played_ratio_pct`, `track_length_seconds` |
| `likes.parquet`            | User like actions                           | `uid`, `item_id`, `timestamp`, `is_organic`                                             |
| `dislikes.parquet`         | User dislike actions                        | `uid`, `item_id`, `timestamp`, `is_organic`                                             |
| `undislikes.parquet`       | User undislike actions (reverting dislikes) | `uid`, `item_id`, `timestamp`, `is_organic`                                             |
| `unlikes.parquet`          | User unlike actions (reverting likes)       | `uid`, `item_id`, `timestamp`, `is_organic`                                             |
| `embeddings.parquet`       | Track audio-embeddings                      | `item_id`, `embed`, `normalized_embed`                                                  |

### Common Event Structure (Homogeneous)

Most event files (`listens`, `likes`, `dislikes`, `undislikes`, `unlikes`) share this base structure:

| Field        | Type   | Description                                                                         |
|--------------|--------|-------------------------------------------------------------------------------------|
| `uid`        | uint32 | Unique user identifier                                                              |
| `item_id`    | uint32 | Unique track identifier                                                             |
| `timestamp`  | uint32 | Delta times, binned into 5s units.                                                  |
| `is_organic` | uint8  | Boolean flag (0/1) indicating if the interaction was algorithmic (0) or organic (1) |

**Sorting**: All files are sorted by (`uid`, `timestamp`) in ascending order.

### Unified Event Structure (Heterogeneous)

For applications needing all event types in a unified format:

| Field                  | Type              | Description                                                   |
|------------------------|-------------------|---------------------------------------------------------------|
| `uid`                  | uint32            | Unique user identifier                                        |
| `item_id`              | uint32            | Unique track identifier                                       |
| `timestamp`            | uint32            | Timestamp binned into 5s units.granularity                    |
| `is_organic`           | uint8             | Boolean flag for organic interactions                         |
| `event_type`           | enum              | One of: `listen`, `like`, `dislike`, `unlike`, `undislike`    |
| `played_ratio_pct`     | Optional[uint16] | Percentage of track played (1-100), null for non-listen events |
| `track_length_seconds` | Optional[uint32] | Total track duration in seconds, null for non-listen events    |

**Notes**:

- `played_ratio_pct` and `track_length_seconds` are non-null **only** when `event_type = "listen"`
- All fields except the two above are guaranteed non-null

### Sequential (Aggregated) Format

Each dataset is also available in a user-aggregated sequential format with the following structure:

| Field        | Type         | Description                                      |
|--------------|--------------|--------------------------------------------------|
| `uid`        | uint32       | Unique user identifier                           |
| `item_ids`   | List[uint32] | Chronological list of interacted track IDs       |
| `timestamps` | List[uint32] | Corresponding interaction timestamps             |
| `is_organic` | List[uint8]  | Corresponding organic flags for each interaction |
| `played_ratio_pct`     | List[Optional[uint16]] | (Only in `listens` and `multi_event`) Play percentages |
| `track_length_seconds` | List[Optional[uint32]] | (Only in `listens` and `multi_event`) Track durations  |

**Notes**:

- All lists maintain chronological order
- For each user, `len(item_ids) == len(timestamps) == len(is_organic)`
- In multi-event format, null values are preserved in respective lists

## Benchmark

Code for the baseline models can be found in `benchmarks/` directory, see [Reproducibility Guide](benchmarks/README.md)

### Download

Simplest way:
```python
from datasets import load_dataset

ds = load_dataset("yandex/yambda", data_dir="flat/50m", data_files="likes.parquet")
```

Also, we provide simple wrapper for convenient usage:
```python
from typing import Literal
from datasets import Dataset, DatasetDict, load_dataset

class YambdaDataset:
    INTERACTIONS = frozenset([
        "likes", "listens", "multi_event", "dislikes", "unlikes", "undislikes"
    ])

    def __init__(
        self,
        dataset_type: Literal["flat", "sequential"] = "flat",
        dataset_size: Literal["50m", "500m", "5b"] = "50m"
    ):
        assert dataset_type in {"flat", "sequential"}
        assert dataset_size in {"50m", "500m", "5b"}
        self.dataset_type = dataset_type
        self.dataset_size = dataset_size

    def interaction(self, event_type: Literal[
        "likes", "listens", "multi_event", "dislikes", "unlikes", "undislikes"
    ]) -> Dataset:
        assert event_type in YambdaDataset.INTERACTIONS
        return self._download(f"{self.dataset_type}/{self.dataset_size}", event_type)

    def audio_embeddings(self) -> Dataset:
        return self._download("", "embeddings")

    def album_item_mapping(self) -> Dataset:
        return self._download("", "album_item_mapping")

    def artist_item_mapping(self) -> Dataset:
        return self._download("", "artist_item_mapping")

    @staticmethod
    def _download(data_dir: str, file: str) -> Dataset:
        data = load_dataset("yandex/yambda", data_dir=data_dir, data_files=f"{file}.parquet")
        # Returns DatasetDict; extracting the only split
        assert isinstance(data, DatasetDict)
        return data["train"]

dataset = YambdaDataset("flat", "50m")
likes = dataset.interaction("likes")  # returns a HuggingFace Dataset
```

## FAQ

### Are test items presented in training data?

Not all, some test items do appear in the training set, others do not.

### Are test users presented in training data?

Yes, there are no cold users in the test set.

### How are audio embeddings generated?

Using a convolutional neural network inspired by Contrastive Learning of Musical Representations (J. Spijkervet et al., 2021).

### What's the `is_organic` flag?

Indicates whether interactions occurred through organic discovery (True) or recommendation-driven pathways (False)

### Which events are considered recommendation-driven?

Recommendation events include actions from:
- Personalized music feed
- Personalized playlists

### What counts as a "listened" track or \\(Listen_+\\)?

A track is considered "listened" if over 50% of its duration is played.

### What does it mean when played_ratio_pct is greater than 100?

A played_ratio_pct greater than 100% indicates that the user rewound and 
replayed sections of the trackβ€”so the total time listened exceeds the original track length. 
These values are expected behavior and not log noise. See [discussion](https://huggingface.co/datasets/yandex/yambda/discussions/10)