Dataset Preview
Duplicate
The full dataset viewer is not available (click to read why). Only showing a preview of the rows.
The dataset generation failed because of a cast error
Error code:   DatasetGenerationCastError
Exception:    DatasetGenerationCastError
Message:      An error occurred while generating the dataset

All the data files must have the same columns, but at some point there are 30 new columns ({'onehot_feat3', 'onehot_feat5', 'onehot_feat4', 'is_lowactive_period', 'friend_user_num', 'is_live_streamer', 'onehot_feat7', 'onehot_feat8', 'onehot_feat14', 'register_days', 'onehot_feat1', 'follow_user_num_range', 'user_active_degree', 'onehot_feat15', 'friend_user_num_range', 'onehot_feat2', 'onehot_feat6', 'onehot_feat16', 'onehot_feat0', 'onehot_feat10', 'register_days_range', 'is_video_author', 'follow_user_num', 'onehot_feat13', 'onehot_feat12', 'onehot_feat11', 'onehot_feat9', 'fans_user_num_range', 'onehot_feat17', 'fans_user_num'}) and 18 missing columns ({'is_follow', 'play_time_ms', 'is_forward', 'is_comment', 'is_rand', 'duration_ms', 'is_like', 'video_id', 'hourmin', 'is_click', 'is_hate', 'profile_stay_time', 'is_profile_enter', 'long_view', 'date', 'comment_stay_time', 'tab', 'time_ms'}).

This happened while the csv dataset builder was generating data using

hf://datasets/numberbeat6/kuairand/user_features_1k.csv (at revision b86438794b71ac3ebb95d96e167f52d22edccda7), ['hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/log_random_4_22_to_5_08_1k.csv', 'hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/log_standard_4_08_to_4_21_1k.csv', 'hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/log_standard_4_22_to_5_08_1k.csv', 'hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/user_features_1k.csv']

Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)
Traceback:    Traceback (most recent call last):
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1848, in _prepare_split_single
                  writer.write_table(table)
                  ~~~~~~~~~~~~~~~~~~^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/arrow_writer.py", line 765, in write_table
                  self._write_table(pa_table, writer_batch_size=writer_batch_size)
                  ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/arrow_writer.py", line 773, in _write_table
                  pa_table = table_cast(pa_table, self._schema)
                File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2378, in table_cast
                  return cast_table_to_schema(table, schema)
                File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2306, in cast_table_to_schema
                  raise CastError(
                  ...<3 lines>...
                  )
              datasets.table.CastError: Couldn't cast
              user_id: int64
              user_active_degree: string
              is_lowactive_period: int64
              is_live_streamer: int64
              is_video_author: int64
              follow_user_num: int64
              follow_user_num_range: string
              fans_user_num: int64
              fans_user_num_range: string
              friend_user_num: int64
              friend_user_num_range: string
              register_days: int64
              register_days_range: string
              onehot_feat0: int64
              onehot_feat1: int64
              onehot_feat2: int64
              onehot_feat3: int64
              onehot_feat4: double
              onehot_feat5: int64
              onehot_feat6: int64
              onehot_feat7: int64
              onehot_feat8: int64
              onehot_feat9: int64
              onehot_feat10: int64
              onehot_feat11: int64
              onehot_feat12: double
              onehot_feat13: double
              onehot_feat14: double
              onehot_feat15: double
              onehot_feat16: double
              onehot_feat17: double
              -- schema metadata --
              pandas: '{"index_columns": [{"kind": "range", "name": null, "start": 0, "' + 4200
              to
              {'user_id': Value('int64'), 'video_id': Value('int64'), 'date': Value('int64'), 'hourmin': Value('int64'), 'time_ms': Value('int64'), 'is_click': Value('int64'), 'is_like': Value('int64'), 'is_follow': Value('int64'), 'is_comment': Value('int64'), 'is_forward': Value('int64'), 'is_hate': Value('int64'), 'long_view': Value('int64'), 'play_time_ms': Value('int64'), 'duration_ms': Value('int64'), 'profile_stay_time': Value('int64'), 'comment_stay_time': Value('int64'), 'is_profile_enter': Value('int64'), 'is_rand': Value('int64'), 'tab': Value('int64')}
              because column names don't match
              
              During handling of the above exception, another exception occurred:
              
              Traceback (most recent call last):
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1369, in compute_config_parquet_and_info_response
                  parquet_operations, partial, estimated_dataset_info = stream_convert_to_parquet(
                                                                        ~~~~~~~~~~~~~~~~~~~~~~~~~^
                      builder, max_dataset_size_bytes=max_dataset_size_bytes
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                  )
                  ^
                File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 948, in stream_convert_to_parquet
                  builder._prepare_split(split_generator=splits_generators[split], file_format="parquet")
                  ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1694, in _prepare_split
                  for job_id, done, content in self._prepare_split_single(
                                               ~~~~~~~~~~~~~~~~~~~~~~~~~~^
                      gen_kwargs=gen_kwargs, job_id=job_id, **_prepare_split_args
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                  ):
                  ^
                File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1850, in _prepare_split_single
                  raise DatasetGenerationCastError.from_cast_error(
                  ...<4 lines>...
                  )
              datasets.exceptions.DatasetGenerationCastError: An error occurred while generating the dataset
              
              All the data files must have the same columns, but at some point there are 30 new columns ({'onehot_feat3', 'onehot_feat5', 'onehot_feat4', 'is_lowactive_period', 'friend_user_num', 'is_live_streamer', 'onehot_feat7', 'onehot_feat8', 'onehot_feat14', 'register_days', 'onehot_feat1', 'follow_user_num_range', 'user_active_degree', 'onehot_feat15', 'friend_user_num_range', 'onehot_feat2', 'onehot_feat6', 'onehot_feat16', 'onehot_feat0', 'onehot_feat10', 'register_days_range', 'is_video_author', 'follow_user_num', 'onehot_feat13', 'onehot_feat12', 'onehot_feat11', 'onehot_feat9', 'fans_user_num_range', 'onehot_feat17', 'fans_user_num'}) and 18 missing columns ({'is_follow', 'play_time_ms', 'is_forward', 'is_comment', 'is_rand', 'duration_ms', 'is_like', 'video_id', 'hourmin', 'is_click', 'is_hate', 'profile_stay_time', 'is_profile_enter', 'long_view', 'date', 'comment_stay_time', 'tab', 'time_ms'}).
              
              This happened while the csv dataset builder was generating data using
              
              hf://datasets/numberbeat6/kuairand/user_features_1k.csv (at revision b86438794b71ac3ebb95d96e167f52d22edccda7), ['hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/log_random_4_22_to_5_08_1k.csv', 'hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/log_standard_4_08_to_4_21_1k.csv', 'hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/log_standard_4_22_to_5_08_1k.csv', 'hf://datasets/numberbeat6/kuairand@b86438794b71ac3ebb95d96e167f52d22edccda7/user_features_1k.csv']
              
              Please either edit the data files to have matching columns, or separate them into different configurations (see docs at https://hf.co/docs/hub/datasets-manual-configuration#multiple-configurations)

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

user_id
int64
video_id
int64
date
int64
hourmin
int64
time_ms
int64
is_click
int64
is_like
int64
is_follow
int64
is_comment
int64
is_forward
int64
is_hate
int64
long_view
int64
play_time_ms
int64
duration_ms
int64
profile_stay_time
int64
comment_stay_time
int64
is_profile_enter
int64
is_rand
int64
tab
int64
0
5,543
20,220,430
1,800
1,651,314,030,792
0
0
0
0
0
0
0
863
30,066
0
0
0
1
1
0
1,836
20,220,502
1,200
1,651,466,607,423
0
0
0
0
0
0
0
1,190
132,433
0
0
0
1
1
0
721
20,220,502
1,700
1,651,481,542,743
0
0
0
0
0
0
0
1,528
25,266
0
0
0
1
1
0
442
20,220,502
1,800
1,651,488,577,163
0
0
0
0
0
0
0
1,490
12,000
0
0
0
1
1
0
62
20,220,503
800
1,651,535,940,163
0
0
0
0
0
0
0
1,419
169,500
0
0
0
1
1
0
7,303
20,220,504
900
1,651,625,898,330
0
0
0
0
0
0
0
1,105
55,533
0
0
0
1
1
0
6,308
20,220,504
900
1,651,628,052,625
0
0
0
0
0
0
0
1,704
7,600
0
0
0
1
1
0
6,614
20,220,506
700
1,651,793,743,336
0
0
0
0
0
0
0
1,141
0
0
0
0
1
1
0
5,066
20,220,506
700
1,651,793,764,164
0
0
0
0
0
0
0
1,409
16,966
0
0
0
1
1
0
4,327
20,220,506
1,000
1,651,804,528,290
0
0
0
0
0
0
0
1,287
150,233
0
0
0
1
1
0
5,898
20,220,506
1,200
1,651,809,553,889
0
0
0
0
0
0
0
2,142
37,616
0
0
0
1
1
0
3,240
20,220,506
1,200
1,651,809,591,045
0
0
0
0
0
0
0
1,162
40,633
0
0
0
1
1
0
3,823
20,220,506
1,200
1,651,809,736,919
0
0
0
0
0
0
0
1,148
172,000
0
0
0
1
1
0
3,941
20,220,506
1,200
1,651,809,779,255
0
0
0
0
0
0
0
986
31,103
0
0
0
1
1
0
2,697
20,220,506
1,300
1,651,816,004,634
0
0
0
0
0
0
0
1,513
87,366
0
0
0
1
1
0
7,250
20,220,506
1,500
1,651,820,195,531
0
0
0
0
0
0
0
1,120
19,866
0
0
0
1
1
0
6,323
20,220,506
1,900
1,651,835,921,949
0
0
0
0
0
0
0
1,486
94,933
0
0
0
1
1
0
3,656
20,220,506
1,900
1,651,836,004,194
0
0
0
0
0
0
0
947
41,000
0
0
0
1
1
0
4,047
20,220,506
1,900
1,651,836,013,096
0
0
0
0
0
0
0
750
38,200
0
0
0
1
1
0
3,725
20,220,506
1,900
1,651,836,177,136
0
0
0
0
0
0
0
1,533
134,734
0
0
0
1
1
0
3,603
20,220,506
1,900
1,651,836,904,029
0
0
0
0
0
0
0
2,104
13,933
0
0
0
1
1
0
6,735
20,220,506
1,900
1,651,836,935,884
0
0
0
0
0
0
0
1,056
0
0
0
0
1
1
0
1,052
20,220,506
1,900
1,651,837,022,496
0
0
0
0
0
0
0
1,075
156,120
0
0
0
1
1
0
6,857
20,220,506
1,900
1,651,837,066,894
0
0
0
0
0
0
0
1,050
149,933
0
0
0
1
1
0
6,441
20,220,506
2,000
1,651,839,975,333
0
0
0
0
0
0
0
1,114
382,566
0
0
0
1
1
0
809
20,220,506
2,100
1,651,841,744,088
0
0
0
0
0
0
0
1,100
248,800
0
0
0
1
1
0
892
20,220,506
2,100
1,651,842,018,902
0
0
0
0
0
0
0
1,065
46,000
0
0
0
1
1
0
2,848
20,220,506
2,100
1,651,842,137,584
0
0
0
0
0
0
0
1,324
140,720
0
0
0
1
1
0
4,946
20,220,506
2,100
1,651,842,407,947
0
0
0
0
0
0
0
832
36,733
0
0
0
1
1
0
527
20,220,506
2,100
1,651,842,674,079
0
0
0
0
0
0
0
1,416
10,388
0
0
0
1
1
0
1,983
20,220,506
2,100
1,651,842,869,824
0
0
0
0
0
0
0
994
14,733
0
0
0
1
1
0
1,488
20,220,506
2,100
1,651,842,880,164
0
0
0
0
0
0
0
1,163
111,233
0
0
0
1
1
0
3,366
20,220,506
2,100
1,651,843,015,965
0
0
0
0
0
0
0
1,146
206,933
0
0
0
1
1
0
5,344
20,220,506
2,100
1,651,843,086,825
0
0
0
0
0
0
0
1,098
87,400
0
0
0
1
1
0
1,016
20,220,506
2,100
1,651,843,526,729
0
0
0
0
0
0
0
821
8,833
0
0
0
1
1
0
1,012
20,220,506
2,100
1,651,843,579,917
0
0
0
0
0
0
0
981
0
0
0
0
1
1
0
6,961
20,220,506
2,100
1,651,843,612,861
0
0
0
0
0
0
0
798
82,700
0
0
0
1
1
0
6,313
20,220,506
2,100
1,651,843,669,039
0
0
0
0
0
0
0
1,024
118,993
0
0
0
1
1
0
404
20,220,506
2,100
1,651,843,975,609
0
0
0
0
0
0
0
910
68,880
0
0
0
1
1
0
6,620
20,220,506
2,100
1,651,844,039,851
0
0
0
0
0
0
0
609
83,133
0
0
0
1
1
0
488
20,220,506
2,100
1,651,844,052,487
0
0
0
0
0
0
0
450
110,800
0
0
0
1
1
0
6,649
20,220,506
2,100
1,651,844,093,959
0
0
0
0
0
0
0
1,241
113,933
0
0
0
1
1
0
2,330
20,220,506
2,100
1,651,844,123,512
0
0
0
0
0
0
0
1,156
104,916
0
0
0
1
1
0
3,588
20,220,506
2,100
1,651,844,135,917
0
0
0
0
0
0
0
1,623
91,840
0
0
0
1
1
0
3,748
20,220,506
2,100
1,651,844,159,805
0
0
0
0
0
0
0
753
17,633
0
0
0
1
1
0
1,196
20,220,506
2,100
1,651,844,182,014
0
0
0
0
0
0
0
724
146,200
0
0
0
1
1
0
5,619
20,220,507
1,300
1,651,899,131,849
0
0
0
0
0
0
0
1,412
26,840
0
0
0
1
1
0
3,611
20,220,507
1,900
1,651,922,125,595
0
0
0
0
0
0
0
1,542
169,433
0
0
0
1
1
0
7,098
20,220,507
2,100
1,651,929,189,668
0
0
0
0
0
0
0
928
6,966
0
0
0
1
1
0
3,629
20,220,507
2,100
1,651,929,341,829
0
0
0
0
0
0
0
1,148
215,200
0
0
0
1
1
0
5,737
20,220,507
2,100
1,651,929,400,666
0
0
0
0
0
0
0
762
73,016
0
0
0
1
1
0
142
20,220,507
2,100
1,651,929,681,516
0
0
0
0
0
0
0
986
123,333
0
0
0
1
1
0
3,184
20,220,507
2,100
1,651,929,812,787
0
0
0
0
0
0
0
774
310,000
0
0
0
1
1
0
1,395
20,220,507
2,100
1,651,929,941,607
0
0
0
0
0
0
0
1,065
32,150
0
0
0
1
1
0
6,344
20,220,508
800
1,651,967,443,080
0
0
0
0
0
0
0
179
84,366
0
0
0
1
1
0
5,636
20,220,508
1,300
1,651,987,370,336
0
0
0
0
0
0
0
848
68,400
0
0
0
1
1
0
3,389
20,220,508
1,400
1,651,991,651,272
0
0
0
0
0
0
0
1,108
16,033
0
0
0
1
1
0
5,347
20,220,508
1,600
1,651,999,484,622
0
0
0
0
0
0
0
927
15,033
0
0
0
1
1
0
3,120
20,220,508
1,600
1,651,999,561,064
0
0
0
0
0
0
0
690
213,433
0
0
0
1
1
0
3,717
20,220,508
2,100
1,652,015,124,396
0
0
0
0
0
0
0
1,605
22,900
0
0
0
1
1
0
2,039
20,220,508
2,100
1,652,017,507,750
0
0
0
0
0
0
0
1,079
201,440
0
0
0
1
1
0
4,055
20,220,508
2,100
1,652,017,516,557
0
0
0
0
0
0
0
686
65,382
0
0
0
1
1
0
549
20,220,508
2,100
1,652,017,525,086
0
0
0
0
0
0
0
1,014
123,350
0
0
0
1
1
1
4,848
20,220,425
600
1,650,839,585,601
0
0
0
0
0
0
0
2,155
98,731
0
0
0
1
1
1
4,803
20,220,426
1,100
1,650,943,403,416
0
0
0
0
0
0
0
2,345
14,800
0
0
0
1
1
1
2,559
20,220,429
2,100
1,651,238,444,226
0
0
0
0
0
0
0
1,845
39,280
0
0
0
1
1
1
2,533
20,220,430
1,000
1,651,285,378,867
0
0
0
0
0
0
0
1,471
79,350
0
0
0
1
1
1
5,928
20,220,503
1,000
1,651,543,649,677
0
0
0
0
0
0
0
3,481
7,450
0
0
0
1
1
1
2,840
20,220,503
1,000
1,651,544,160,038
1
0
0
0
0
0
1
66,449
61,166
0
0
0
1
1
1
6,017
20,220,503
1,100
1,651,547,790,758
0
0
0
0
0
0
0
6,129
20,500
0
0
0
1
1
1
6,718
20,220,503
1,400
1,651,559,685,619
0
0
0
0
0
0
0
2,496
24,650
0
0
0
1
1
1
7,052
20,220,503
1,900
1,651,577,790,172
0
0
0
0
0
0
0
1,809
123,866
0
0
0
1
1
1
2,984
20,220,506
600
1,651,789,226,930
1
0
0
0
0
0
1
24,792
96,466
0
0
0
1
1
1
3,027
20,220,506
600
1,651,789,881,792
1
0
0
0
0
0
1
16,920
15,250
0
0
0
1
1
1
591
20,220,507
600
1,651,876,377,881
0
0
0
0
0
0
0
1,840
166,850
0
0
0
1
1
1
3,074
20,220,508
1,100
1,651,981,414,195
0
0
0
0
0
0
0
1,927
29,000
0
0
0
1
1
1
5,393
20,220,508
1,100
1,651,981,811,308
0
0
0
0
0
0
0
1,672
143,866
0
0
0
1
1
1
5,992
20,220,508
1,200
1,651,982,382,581
0
0
0
0
0
0
0
2,461
111,716
0
0
0
1
1
1
348
20,220,508
1,200
1,651,982,568,435
0
0
0
0
0
0
0
3,806
11,666
0
0
0
1
1
1
2,240
20,220,508
1,200
1,651,982,685,140
0
0
0
0
0
0
0
3,895
87,083
0
0
0
1
1
1
4,358
20,220,508
1,300
1,651,987,734,241
0
0
0
0
0
0
0
4,127
33,533
0
0
0
1
1
1
4,309
20,220,508
1,300
1,651,988,240,993
0
0
0
0
0
0
0
1,429
85,733
0
0
0
1
1
1
2,052
20,220,508
2,300
1,652,021,737,024
0
0
0
0
0
0
0
1,530
136,766
0
0
0
1
1
1
2,708
20,220,508
2,300
1,652,023,102,784
0
0
0
0
0
0
0
2,771
185,560
0
0
0
1
1
1
793
20,220,508
2,300
1,652,023,255,023
0
0
0
0
0
0
0
1,857
31,206
0
0
0
1
1
2
4,579
20,220,422
2,100
1,650,631,589,489
0
0
0
0
0
0
0
5,809
7,916
0
0
0
1
1
2
7,227
20,220,423
2,100
1,650,719,390,655
0
0
0
0
0
0
0
4,617
105,062
0
0
0
1
1
2
4,931
20,220,425
1,000
1,650,852,003,875
1
0
0
0
0
0
1
146,853
326,466
0
0
0
1
1
2
254
20,220,426
1,000
1,650,941,322,891
0
0
0
0
0
0
0
4,185
121,400
0
0
0
1
1
2
6,801
20,220,426
1,100
1,650,941,876,349
1
0
0
0
0
0
1
43,207
35,600
0
0
0
1
1
2
5,770
20,220,427
1,500
1,651,044,662,195
1
0
0
0
0
0
1
32,192
35,016
0
0
0
1
1
2
5,726
20,220,427
2,000
1,651,060,457,221
0
0
0
0
0
0
0
1,190
125,040
0
0
0
1
1
2
4,325
20,220,427
2,000
1,651,061,885,599
0
0
0
0
0
0
0
1,867
15,033
0
0
0
1
1
2
1,871
20,220,427
2,100
1,651,067,023,833
0
0
0
0
0
0
0
3,540
117,100
0
0
0
1
1
2
6,417
20,220,428
2,200
1,651,154,897,254
0
0
0
0
0
0
0
1,554
11,066
0
0
0
1
1
2
54
20,220,429
1,000
1,651,198,193,935
0
0
0
0
0
0
0
4,889
201,166
0
0
0
1
1
2
6,918
20,220,429
1,400
1,651,213,819,046
1
0
0
0
0
0
1
47,796
40,766
0
0
0
1
1
2
662
20,220,429
1,900
1,651,231,982,643
1
0
0
0
0
0
1
41,808
116,933
0
0
0
1
1
2
4,174
20,220,430
1,300
1,651,297,445,628
1
0
0
0
0
0
1
73,829
155,300
0
3,303
0
1
1
2
3,474
20,220,430
1,300
1,651,297,632,845
0
0
0
0
0
0
0
3,936
240,533
0
0
0
1
1
End of preview.

YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

KuaiRand: An Unbiased Sequential Recommendation Dataset with Randomly Exposed Videos

LICENSE

KuaiRand is an unbiased sequential recommendation dataset collected from the recommendation logs of the video-sharing mobile app, Kuaishou (快手). It is the first recommendation dataset with millions of intervened interactions of randomly exposed items inserted in the standard recommendation feeds!

Overview:

The following figure gives an example of the dataset. It illustrates a user interaction sequence along with the user's rich feedback signals.

kuaidata

These feedback signals are collected from the two main user interfaces (UI) in Kuaishou APP shown as follows:

kuaishou-app

In the random exposure stage, each recommended video in the dataset has an equal probability being replaced by a random video sampled from an item pools. About $0.37%$ Interactions are replaced in the final results.

Advantages:

Compared with other datasets with random exposure, KuaiRand has the following advantages:

  • ✅ It is the first sequential recommendation dataset with millions of intervened interactions of randomly exposed items inserted in the standard recommendation feeds.
  • ✅ It has the most comprehensive side information including explicit user IDs, interaction timestamps, and rich features for users and items.
  • ✅ It has 15 policies with each catered for a special recommendation scenario in Kuaishou App.
  • ✅ We introduce 12 feedback signals (e.g., click, like, and view time) for each interaction to describe the user's comprehensive feedback.
  • ✅ Each user has thousands of historical interactions on average.
  • ✅ It has three versions to support various research directions in recommendation.

Three Versions and Suggestions:

We release three versions of KuaiRand for different usage:

  • KuaiRand-27K (23GB logs +23GB features): the complete KuaiRand dataset that has over 27K users and 32 millions videos.
  • KuaiRand-1K (829MB logs + 3.5GB features): randomly sample 1,000 users from KuaiRand-27K, then remove all irrelevant videos. There are 4 millions videos rest.
  • KuaiRand-Pure (184MB logs + 10MB features): only keeps the logs for the 7582 videos in the candidate pool.

The user_id and video_id are re-indexed. A visualization of their ID spaces is shown as follows.

kuaidata

The basic statistics of the three versions are summarized as follows:
Dataset Collection Policy #Users #Items #Interactions #User features #Item features Feedback Timestamp
KuaiRand-27K 15 policies 27,285 32,038,725 322,278,385 30 62 12 signals ✔️
Random policy 27,285 7,583 1,186,059 30 62 12 signals ✔️
KuaiRand-1K 15 policies 1,000 4,369,953 11,713,045 30 62 12 signals ✔️
Random policy 1,000 7,388 43,028 30 62 12 signals ✔️
KuaiRand-Pure 15 policies 27,285 7,551 1,436,609 30 62 12 signals ✔️
Random policy 27,285 7,583 1,186,059 30 62 12 signals ✔️

Which version should I use?

  • Reasons to use KuaiRand-27K or KuaiRand-1K:
    • Your research needs rigorous sequential logs, such as off-policy evaluation (OPE), Reinforcement learning (RL), or long sequential recommendation.
  • Reasons to use KuaiRand-Pure:
    • The sequential information is not necessary in your research OR If you are OK with the incomplete sequential logs. For example, if you are studying debiasing in collaborative filtering models or multi-task modeling in recommendation.
    • If your model can only run with small-size data.

Download the data

We provides several options to download the datasets:

Option 1. Download via the "wget" command.

KuaiRand-27K (compressed size: 9.21GB; uncompressed size: 46GB)
wget https://chongming.myds.me:61364/data/KuaiRand-27K.tar.gz --no-check-certificate
tar -zxvf KuaiRand-27K.tar.gz
KuaiRand-1K (compressed size: 1GB; uncompressed size: 4.3GB)
wget https://chongming.myds.me:61364/data/KuaiRand-1K.tar.gz --no-check-certificate
tar -zxvf KuaiRand-1K.tar.gz
KuaiRand-Pure (compressed size: 45.2MB; uncompressed size: 194MB)
wget https://chongming.myds.me:61364/data/KuaiRand-Pure.tar.gz --no-check-certificate
tar -zxvf KuaiRand-Pure.tar.gz

Option 2. Download manually through the following links:

The script loaddata.py provides a simple way to load the data via Pandas in Python.


Data Descriptions

The file structure of the three datasets are listed as follows:

KuaiRand-27K (46GB)
KuaiRand-27K
├── data (46GB)
│   ├── log_random_4_22_to_5_08_27k.csv (83MB)
│   ├── log_standard_4_08_to_4_21_27k_part1.csv (4.8GB)
│   ├── log_standard_4_08_to_4_21_27k_part2.csv (4.8GB)
│   ├── log_standard_4_22_to_5_08_27k_part1.csv (6.6GB)
│   ├── log_standard_4_22_to_5_08_27k_part2.csv (6.6GB)
│   ├── user_features_27k.csv (3.4MB)
│   ├── video_features_basic_27k.csv (2.6GB)
│   ├── video_features_statistic_27k_part1.csv (6.7GB)
│   ├── video_features_statistic_27k_part2.csv (6.7GB)
│   └── video_features_statistic_27k_part3.csv (6.7GB)
└── load_data_27k.py
KuaiRand-1K (4.3GB)
KuaiRand-1K
├── data (4.3GB)
│   ├── log_random_4_22_to_5_08_1k.csv (2.9MB)
│   ├── log_standard_4_08_to_4_21_1k.csv (368MB)
│   ├── log_standard_4_22_to_5_08_1k.csv (481MB)
│   ├── user_features_1k.csv (132KB)
│   ├── video_features_basic_1k.csv (368MB)
│   └── video_features_statistic_1k.csv (3.1GB)
└── load_data_1k.py
KuaiRand-Pure (194MB)
KuaiRand-Pure
├── data (194MB)
│   ├── log_random_4_22_to_5_08_pure.csv (83MB)
│   ├── log_standard_4_08_to_4_21_pure.csv (80MB)
│   ├── log_standard_4_22_to_5_08_pure.csv (21MB)
│   ├── user_features_pure.csv (3.4MB)
│   ├── video_features_basic_pure.csv (612KB)
│   └── video_features_statistic_pure.csv (6.3MB)
└── load_data_pure.py

1️⃣ Descriptions of the fields in log_xxx.csv

There are three log files:

  • log_random_4_22_to_5_08.csv contains all interactions resulted from random intervention.
  • log_standard_4_22_to_5_08.csv contains all interactions of standard recommendation.
  • log_standard_4_08_to_4_21.csv contains all interactions of standard recommendation for the same users in the previous two weeks (2022.04.08 ~ 2022.04.21).
Field Name: Description Type Example
user_id The ID of the video. int64 17387
video_id The ID of the video. int64 1123453
date The date of this interaction int64 20220421
hourmin The time of this interaction (format: HHSS). int64 400
time_ms The timestamp of this interaction in millisecond. int64 1650485801301
is_click A binary feedback signal. In the two-column UI, it indicates a click; In the single-column UI, it means valid_play: which equals 1 when: play_duration >= video_duration if video_duration <= 7s, or play_duration > 7 if video_duration > 7s. int64 1
is_like A binary feedback signal indicating the user hit the like button. int64 0
is_follow A binary feedback signal indicating the user hit the follow the author button. int64 0
is_comment A binary feedback signal indicating the user writed comment in the comments section of this video int64 0
is_forward A binary feedback signal indicating the user forwarded this video. int64 0
is_hate A binary feedback signal indicating the user hated this video. int64 0
long_view A binary feedback signal. It equals 1 when: play_duration >= video_duration if video_duration <= 18s, or play_duration >=18 if video_duration > 18s. int64 1
play_time_ms The user's view time in millisecond. int64 151024
duration_ms The video's duration time in millisecond. int64 104400
profile_stay_time The time that the user stayed in this author's profile. int64 0
comment_stay_time The time that the user stayed in the comments section of this video int64 0
is_profile_enter A binary feedback signal indicating the user enters the author profile int64 0
is_rand A binary signal indicating if this video is generated by the random intervention (i.e., a random exposed video). int64 0
tab indicating the scenario of this interaction, e.g., in the recommendation page or the main page of the App. In range of [0,14]. int64 1

2️⃣ Descriptions of the fields in user_features.csv

Field Name: Description Type Example
user_id The ID of the user. int64 25621
user_active_degree In the set of {'high_active', 'full_active', 'middle_active', 'UNKNOWN'}. str "full_active"
is_lowactive_period Is this user in its low active period int64 0
is_live_streamer Is this user a live streamer? int64 0
is_video_author Has this user uploaded any video? int64 1
follow_user_num The number of users that this user follows. int64 5
follow_user_num_range The range of the number of users that this user follows. In the set of {'0', '(0,10]', '(10,50]', '(100,150]', '(150,250]', '(250,500]', '(50,100]', '500+'} str "(0,10]"
fans_user_num The number of the fans of this user. int64 312
fans_user_num_range The range of the number of fans of this user. In the set of {'0', '[1,10)', '[10,100)', '[100,1k)', '[1k,5k)', '[5k,1w)', '[1w,10w)'} str "[100,1k)"
friend_user_num The number of friends that this user has. int64 0
friend_user_num_range The range of the number of friends that this user has. In the set of {'0', '[1,5)', '[5,30)', '[30,60)', '[60,120)', '[120,250)', '250+'} str "0"
register_days The days since this user has registered. int64 3624
register_days_range The range of the registered days. In the set of {'15-30', '31-60', '61-90', '91-180', '181-365', '366-730', '730+'}. str "730+"
onehot_feat0 An encrypted feature of the user. Each value indicate the position of "1" in the one-hot vector. Range: {0,1} int64 1
onehot_feat1 An encrypted feature. Range: {0, 1, ..., 6} int64 2
onehot_feat2 An encrypted feature. Range: {0, 1, ..., 49} int64 2
onehot_feat3 An encrypted feature. Range: {0, 1, ..., 1470} int64 1153
onehot_feat4 An encrypted feature. Range: {0, 1, ..., 14} int64 4
onehot_feat5 An encrypted feature. Range: {0, 1, ..., 33} int64 0
onehot_feat6 An encrypted feature. Range: {0, 1, 2} int64 0
onehot_feat7 An encrypted feature. Range: {0, 1, ..., 117} int64 31
onehot_feat8 An encrypted feature. Range: {0, 1, ..., 453} int64 354
onehot_feat9 An encrypted feature. Range: {0, 1, ..., 6} int64 3
onehot_feat10 An encrypted feature. Range: {0, 1, ..., 4} int64 3
onehot_feat11 An encrypted feature. Range: {0, 1, ..., 4} int64 2
onehot_feat12 An encrypted feature. Range: {0, 1} int64 1
onehot_feat13 An encrypted feature. Range: {0, 1} int64 0
onehot_feat14 An encrypted feature. Range: {0, 1} int64 0
onehot_feat15 An encrypted feature. Range: {0, 1} int64 0
onehot_feat16 An encrypted feature. Range: {0, 1} int64 0
onehot_feat17 An encrypted feature. Range: {0, 1} int64 0

3️⃣ Descriptions of the fields in video_features_basic.csv

Field Name: Description Type Example
video_id The ID of the video. int64 3784
author_id The ID of the author of this video. In the range of [0, 8839734] int64 441
video_type Type of this video (NORMAL or AD). str "NORMAL"
upload_dt Upload date of this video. str "2020-07-08"
upload_type The upload type of this video. str "ShortImport"
visible_status The visible state of this video on the APP now. int 1
video_duration The time duration of this duration (in millisecond). Int64 17200.0
server_width The width of this video on the server. int64 720
server_height The height of this video on the server. int64 1280
music_id Background music ID of this video. int64 989206467
music_type Background music type of this video. int64 4
tag A list of key categories (labels) of this video. str "12,65"

4️⃣ Descriptions of the fields in video_features_statistic.csv

‼️ Different from the basic features, the statistical features are the average statistics of the video each day over the one month. For example, in the following table, the video 9288071 have 66 counts over this one month (a video can have multiple counts each day on different scenarios, e.g., on April 8, show_cnt=80 on the main page and show_cnt=65 on the recommendation page of the App)

Field Name: Description Type Example
video_id The ID of the video. int64 9288071
counts The number of statistics. int64 66
show_cnt The number of shows of this video (averaged on each day and each scenario over the one month. This applies to all the following fields) float64 75.212
show_user_num The number of users who received the recommendation of this video. float64 66.985
play_cnt The number of plays. float64 9.409
play_user_num The number of users who plays this video. float64 8.121
play_duration The total time duration of playing this video (in millisecond). float64 93700.333
complete_play_cnt The number of complete plays. complete play: finishing playing the whole video, i.e., #(play_duration >= video_duration). float64 0.182
complete_play_user_num The number of users who perform the complete play. float64 0.182
valid_play_cnt valid play: play_duration >= video_duration if video_duration <= 7s, or play_duration > 7 if video_duration > 7s. float64 3.545
valid_play_user_num The number of users who perform the complete play. float64 3.136
long_time_play_cnt long time play: play_duration >= video_duration if video_duration <= 18s, or play_duration >=18 if video_duration > 18s. float64 1.909
long_time_play_user_num The number of users who perform the long time play. float64 1.848
short_time_play_cnt short time play: play_duration < min(3s, video_duration). float64 5.015
short_time_play_user_num The number of users who perform the short time play. float64 4.545
play_progress The average video playing ratio (=play_duration/video_duration) float64 0.016
comment_stay_duration Total time of staying in the comments section float64 2302.712
like_cnt Total likes float64 0.303
like_user_num The number of users who hit the "like" button. float64 0.303
click_like_cnt The number of the "like" resulted from double click float64 0.030
double_click_cnt The number of users who double click the video. float64 0.273
cancel_like_cnt The number of likes that are cancelled by users. float64 0.485
cancel_like_user_num The number of users who cancel their like. float64 0.485
comment_cnt The number of comments within this day. float64 0.015
comment_user_num The number of users who comment this video. float64 0.015
direct_comment_cnt The number of direct comments (depth=1). float64 0.015
reply_comment_cnt The number of reply comments (depth>1). float64 0.000
delete_comment_cnt The number of deleted comments. float64 0.015
delete_comment_user_num The number of users who delete their comments. float64 0.015
comment_like_cnt The number of comment likes. float64 0.000
comment_like_user_num The number of users who like the comments. float64 0.000
follow_cnt The number of increased follows from this video. float64 0.000
follow_user_num The number of users who follow the author of this video due to this video. float64 0.000
cancel_follow_cnt The number of decreased follows from this video. float64 0.000
cancel_follow_user_num The number of users who cancel their following of the author of this video due to this video. float64 0.000
share_cnt The times of successfully sharing this video. float64 0.000
share_user_num The number of users who succeed to share this video. float64 0.000
download_cnt The times of downloading this video. float64 0.030
download_user_num The number of users who download this video. float64 0.030
report_cnt The times of reporting this video. float64 0.000
report_user_num The number of users who report this video. float64 0.000
reduce_similar_cnt The times of reducing similar content of this video. float64 0.015
reduce_similar_user_num The number of users who choose to reduce similar content of this video. float64 0.015
collect_cnt The times of adding this video to favorite videos. float64 0.061
collect_user_num The number of users who add this video to their favorite videos. float64 0.061
cancel_collect_cnt The times of removing this video from favorite videos. float64 0.091
cancel_collect_user_num The number of users who remove this video from their favorite videos float64 0.091
direct_comment_user_num The number of users who write comments directly under this video (level=1). float64 0.015
reply_comment_user_num The number of users who reply the existing comments (level>1). float64 0.000
share_all_cnt The times of sharing this video (no need to be successful). float64 0.015
share_all_user_num The number of users who share this video (no need to be successful). float64 0.015
outsite_share_all_cnt The times of sharing this video outside Kuaishou App. float64 0.000
Downloads last month
396