nextrec 0.4.6__tar.gz → 0.4.8__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (162) hide show
  1. {nextrec-0.4.6 → nextrec-0.4.8}/.github/workflows/tests.yml +1 -12
  2. {nextrec-0.4.6 → nextrec-0.4.8}/PKG-INFO +32 -26
  3. {nextrec-0.4.6 → nextrec-0.4.8}/README.md +29 -24
  4. {nextrec-0.4.6 → nextrec-0.4.8}/README_en.md +23 -15
  5. nextrec-0.4.8/assets/nextrec_diagram.png +0 -0
  6. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/conf.py +1 -1
  7. nextrec-0.4.8/nextrec/__version__.py +1 -0
  8. nextrec-0.4.8/nextrec/basic/callback.py +413 -0
  9. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/model.py +289 -173
  10. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/cli.py +27 -1
  11. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/loss/loss_utils.py +73 -4
  12. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/match/dssm.py +5 -4
  13. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/match/dssm_v2.py +4 -3
  14. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/match/mind.py +5 -4
  15. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/match/sdm.py +5 -4
  16. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/match/youtube_dnn.py +5 -4
  17. nextrec-0.4.8/nextrec/utils/cli_utils.py +58 -0
  18. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/config.py +5 -4
  19. {nextrec-0.4.6 → nextrec-0.4.8}/pyproject.toml +3 -2
  20. nextrec-0.4.8/test/test_base_model_regularization.py +41 -0
  21. nextrec-0.4.6/assets/nextrec_diagram_en.png +0 -0
  22. nextrec-0.4.6/assets/nextrec_diagram_zh.png +0 -0
  23. nextrec-0.4.6/nextrec/__version__.py +0 -1
  24. nextrec-0.4.6/nextrec/basic/callback.py +0 -35
  25. {nextrec-0.4.6 → nextrec-0.4.8}/.github/workflows/publish.yml +0 -0
  26. {nextrec-0.4.6 → nextrec-0.4.8}/.gitignore +0 -0
  27. {nextrec-0.4.6 → nextrec-0.4.8}/.readthedocs.yaml +0 -0
  28. {nextrec-0.4.6 → nextrec-0.4.8}/CODE_OF_CONDUCT.md +0 -0
  29. {nextrec-0.4.6 → nextrec-0.4.8}/CONTRIBUTING.md +0 -0
  30. {nextrec-0.4.6 → nextrec-0.4.8}/LICENSE +0 -0
  31. {nextrec-0.4.6 → nextrec-0.4.8}/MANIFEST.in +0 -0
  32. {nextrec-0.4.6 → nextrec-0.4.8}/assets/Feature Configuration.png +0 -0
  33. {nextrec-0.4.6 → nextrec-0.4.8}/assets/Model Parameters.png +0 -0
  34. {nextrec-0.4.6 → nextrec-0.4.8}/assets/Training Configuration.png +0 -0
  35. {nextrec-0.4.6 → nextrec-0.4.8}/assets/Training logs.png +0 -0
  36. {nextrec-0.4.6 → nextrec-0.4.8}/assets/logo.png +0 -0
  37. {nextrec-0.4.6 → nextrec-0.4.8}/assets/mmoe_tutorial.png +0 -0
  38. {nextrec-0.4.6 → nextrec-0.4.8}/assets/test data.png +0 -0
  39. {nextrec-0.4.6 → nextrec-0.4.8}/dataset/ctcvr_task.csv +0 -0
  40. {nextrec-0.4.6 → nextrec-0.4.8}/dataset/ecommerce_task.csv +0 -0
  41. {nextrec-0.4.6 → nextrec-0.4.8}/dataset/match_task.csv +0 -0
  42. {nextrec-0.4.6 → nextrec-0.4.8}/dataset/movielens_100k.csv +0 -0
  43. {nextrec-0.4.6 → nextrec-0.4.8}/dataset/multitask_task.csv +0 -0
  44. {nextrec-0.4.6 → nextrec-0.4.8}/dataset/ranking_task.csv +0 -0
  45. {nextrec-0.4.6 → nextrec-0.4.8}/docs/en/Getting started guide.md +0 -0
  46. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/Makefile +0 -0
  47. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/index.md +0 -0
  48. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/make.bat +0 -0
  49. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/modules.rst +0 -0
  50. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/nextrec.basic.rst +0 -0
  51. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/nextrec.data.rst +0 -0
  52. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/nextrec.loss.rst +0 -0
  53. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/nextrec.rst +0 -0
  54. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/nextrec.utils.rst +0 -0
  55. {nextrec-0.4.6 → nextrec-0.4.8}/docs/rtd/requirements.txt +0 -0
  56. {nextrec-0.4.6 → nextrec-0.4.8}/docs/zh//345/277/253/351/200/237/344/270/212/346/211/213.md" +0 -0
  57. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/__init__.py +0 -0
  58. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/__init__.py +0 -0
  59. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/activation.py +0 -0
  60. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/features.py +0 -0
  61. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/layers.py +0 -0
  62. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/loggers.py +0 -0
  63. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/metrics.py +0 -0
  64. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/basic/session.py +0 -0
  65. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/data/__init__.py +0 -0
  66. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/data/batch_utils.py +0 -0
  67. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/data/data_processing.py +0 -0
  68. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/data/data_utils.py +0 -0
  69. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/data/dataloader.py +0 -0
  70. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/data/preprocessor.py +0 -0
  71. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/loss/__init__.py +0 -0
  72. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/loss/listwise.py +0 -0
  73. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/loss/pairwise.py +0 -0
  74. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/loss/pointwise.py +0 -0
  75. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/generative/__init__.py +0 -0
  76. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/generative/hstu.py +0 -0
  77. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/generative/rqvae.py +0 -0
  78. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/generative/tiger.py +0 -0
  79. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/match/__init__.py +0 -0
  80. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/multi_task/__init__.py +0 -0
  81. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/multi_task/esmm.py +0 -0
  82. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/multi_task/mmoe.py +0 -0
  83. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/multi_task/ple.py +0 -0
  84. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/multi_task/poso.py +0 -0
  85. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/multi_task/share_bottom.py +0 -0
  86. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/__init__.py +0 -0
  87. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/afm.py +0 -0
  88. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/autoint.py +0 -0
  89. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/dcn.py +0 -0
  90. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/dcn_v2.py +0 -0
  91. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/deepfm.py +0 -0
  92. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/dien.py +0 -0
  93. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/din.py +0 -0
  94. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/fibinet.py +0 -0
  95. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/fm.py +0 -0
  96. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/masknet.py +0 -0
  97. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/pnn.py +0 -0
  98. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/widedeep.py +0 -0
  99. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/models/ranking/xdeepfm.py +0 -0
  100. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/__init__.py +0 -0
  101. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/device.py +0 -0
  102. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/distributed.py +0 -0
  103. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/embedding.py +0 -0
  104. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/feature.py +0 -0
  105. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/file.py +0 -0
  106. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/initializer.py +0 -0
  107. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/model.py +0 -0
  108. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/optimizer.py +0 -0
  109. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/synthetic_data.py +0 -0
  110. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec/utils/tensor.py +0 -0
  111. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/NextRec-CLI.md +0 -0
  112. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/NextRec-CLI_zh.md +0 -0
  113. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/feature_config.yaml +0 -0
  114. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/afm.yaml +0 -0
  115. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/autoint.yaml +0 -0
  116. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/dcn.yaml +0 -0
  117. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/deepfm.yaml +0 -0
  118. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/din.yaml +0 -0
  119. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/esmm.yaml +0 -0
  120. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/fibinet.yaml +0 -0
  121. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/fm.yaml +0 -0
  122. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/masknet.yaml +0 -0
  123. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/mmoe.yaml +0 -0
  124. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/ple.yaml +0 -0
  125. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/pnn.yaml +0 -0
  126. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/poso.yaml +0 -0
  127. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/share_bottom.yaml +0 -0
  128. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/widedeep.yaml +0 -0
  129. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/model_configs/xdeepfm.yaml +0 -0
  130. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/predict_config.yaml +0 -0
  131. {nextrec-0.4.6 → nextrec-0.4.8}/nextrec_cli_preset/train_config.yaml +0 -0
  132. {nextrec-0.4.6 → nextrec-0.4.8}/pytest.ini +0 -0
  133. {nextrec-0.4.6 → nextrec-0.4.8}/requirements.txt +0 -0
  134. {nextrec-0.4.6 → nextrec-0.4.8}/scripts/format_code.py +0 -0
  135. {nextrec-0.4.6 → nextrec-0.4.8}/test/__init__.py +0 -0
  136. {nextrec-0.4.6 → nextrec-0.4.8}/test/conftest.py +0 -0
  137. {nextrec-0.4.6 → nextrec-0.4.8}/test/run_tests.py +0 -0
  138. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_generative_models.py +0 -0
  139. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_layers.py +0 -0
  140. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_losses.py +0 -0
  141. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_match_models.py +0 -0
  142. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_multitask_models.py +0 -0
  143. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_preprocessor.py +0 -0
  144. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_ranking_models.py +0 -0
  145. {nextrec-0.4.6 → nextrec-0.4.8}/test/test_utils.py +0 -0
  146. {nextrec-0.4.6 → nextrec-0.4.8}/test_requirements.txt +0 -0
  147. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/distributed/example_distributed_training.py +0 -0
  148. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/distributed/example_distributed_training_large_dataset.py +0 -0
  149. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/example_match_dssm.py +0 -0
  150. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/example_multitask.py +0 -0
  151. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/example_ranking_din.py +0 -0
  152. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/movielen_match_dssm.py +0 -0
  153. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/movielen_ranking_deepfm.py +0 -0
  154. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/notebooks/en/Build semantic ID with RQ-VAE.ipynb +0 -0
  155. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/notebooks/en/Hands on dataprocessor.ipynb +0 -0
  156. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/notebooks/en/Hands on nextrec.ipynb +0 -0
  157. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/notebooks/zh//344/275/277/347/224/250RQ-VAE/346/236/204/345/273/272/350/257/255/344/271/211ID.ipynb" +0 -0
  158. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/notebooks/zh//345/246/202/344/275/225/344/275/277/347/224/250DataProcessor/350/277/233/350/241/214/351/242/204/345/244/204/347/220/206.ipynb" +0 -0
  159. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/notebooks/zh//345/277/253/351/200/237/345/205/245/351/227/250nextrec.ipynb" +0 -0
  160. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/run_all_match_models.py +0 -0
  161. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/run_all_multitask_models.py +0 -0
  162. {nextrec-0.4.6 → nextrec-0.4.8}/tutorials/run_all_ranking_models.py +0 -0
@@ -45,18 +45,7 @@ jobs:
45
45
  run: |
46
46
  python -c "import torch; print(f'PyTorch version: {torch.__version__}')"
47
47
  python -c "import nextrec; print('NextRec imported successfully')"
48
-
49
- - name: Run tutorial multi-task models
50
- run: |
51
- python tutorials/run_all_multitask_models.py
52
-
53
- - name: Run tutorial ranking models
54
- run: |
55
- python tutorials/run_all_ranking_models.py
56
-
57
- - name: Run tutorial match models
58
- run: |
59
- python tutorials/run_all_match_models.py
48
+
60
49
 
61
50
  - name: Run match model tests
62
51
  run: |
@@ -1,12 +1,13 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nextrec
3
- Version: 0.4.6
3
+ Version: 0.4.8
4
4
  Summary: A comprehensive recommendation library with match, ranking, and multi-task learning models
5
5
  Project-URL: Homepage, https://github.com/zerolovesea/NextRec
6
6
  Project-URL: Repository, https://github.com/zerolovesea/NextRec
7
7
  Project-URL: Documentation, https://github.com/zerolovesea/NextRec/blob/main/README.md
8
8
  Project-URL: Issues, https://github.com/zerolovesea/NextRec/issues
9
- Author-email: zerolovesea <zyaztec@gmail.com>
9
+ Author: Yang Zhou
10
+ Author-email: zyaztec@gmail.com
10
11
  License-File: LICENSE
11
12
  Keywords: ctr,deep-learning,match,pytorch,ranking,recommendation
12
13
  Classifier: Development Status :: 3 - Alpha
@@ -65,9 +66,9 @@ Description-Content-Type: text/markdown
65
66
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
66
67
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
67
68
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
68
- ![Version](https://img.shields.io/badge/Version-0.4.6-orange.svg)
69
+ ![Version](https://img.shields.io/badge/Version-0.4.8-orange.svg)
69
70
 
70
- 中文文档 | [English Version](README_en.md) |
71
+ 中文文档 | [English Version](README_en.md)
71
72
 
72
73
  **统一、高效、可扩展的推荐系统框架**
73
74
 
@@ -80,7 +81,7 @@ Description-Content-Type: text/markdown
80
81
  - [安装](#安装)
81
82
  - [架构](#架构)
82
83
  - [5分钟快速上手](#5分钟快速上手)
83
- - [命令行工具](#命令行工具)
84
+ - [命令行工具 NextRec-CLI](#命令行工具)
84
85
  - [兼容平台](#兼容平台)
85
86
  - [支持模型](#支持模型)
86
87
  - [贡献指南](#贡献指南)
@@ -90,35 +91,30 @@ Description-Content-Type: text/markdown
90
91
  NextRec是一个基于PyTorch的现代推荐系统框架,旨在为研究工程团队提供快速的建模、训练与评估流。框架内置丰富的模型库、数据处理工具和工程化训练组件。此外提供了易上手的接口,命令行工具及教程,推荐算法学习者能以最快速度了解模型架构,复现学术论文并进行训练和部署。
91
92
 
92
93
  ## Why NextRec
93
-
94
- - **统一的特征工程与数据流水线**:NextRec框架提供了统一的特征定义、可持久化的数据处理、并对批处理进行了优化,符合工业大数据Spark/Hive场景下,基于离线特征的模型训练推理流程。
95
94
  - **多场景推荐能力**:覆盖排序(CTR/CVR)、召回、多任务学习、生成式召回等推荐/营销模型,持续跟进业界进展。
96
- - **友好的工程体验**:支持各种格式数据(`csv/parquet/pathlike`)的流式预处理/分布式训练/推理,GPU加速与可视化指标监控,方便业务算法工程师和推荐算法学习者快速复现实验。
95
+ - **统一的特征工程与数据流水线**:NextRec框架提供了统一的特征定义、可持久化的数据处理、批处理优化,符合工业大数据Spark/Hive场景下,基于离线特征的模型训练推理流程。
96
+ - **友好的工程体验**:支持多种格式数据(`csv/parquet/pathlike`)的流式处理/分布式训练/推理与可视化指标监控,方便业务算法工程师和推荐算法学习者快速复现实验。
97
97
  - **灵活的命令行工具**:支持通过命令行和配置文件,一键启动训练和推理进程,方便快速实验迭代和敏捷部署。
98
98
  - **高效训练与评估**:内置多种优化器、学习率调度、早停、模型检查点与详细的日志管理,开箱即用。
99
99
 
100
100
  ## NextRec近期进展
101
101
 
102
- - **12/12/2025** 在v0.4.6中加入了生成式召回中常见的[RQ-VAE](/nextrec/models/generative/rqvae.py)模块。配套的[数据集](/dataset/ecommerce_task.csv)和[代码](tutorials/notebooks/zh/使用RQ-VAE构建语义ID.ipynby)已经同步在仓库中
102
+ - **12/12/2025** 在v0.4.8中加入了[RQ-VAE](/nextrec/models/generative/rqvae.py)模块。配套的[数据集](/dataset/ecommerce_task.csv)和[代码](tutorials/notebooks/zh/使用RQ-VAE构建语义ID.ipynby)已经同步在仓库中
103
103
  - **07/12/2025** 发布了NextRec CLI命令行工具,它允许用户根据配置文件进行一键训练和推理,我们提供了相关的[教程](/nextrec_cli_preset/NextRec-CLI_zh.md)和[教学代码](/nextrec_cli_preset)
104
- - **03/12/2025** NextRec获得100颗🌟,感谢大家的支持
104
+ - **03/12/2025** NextRec获得了100颗🌟!感谢大家的支持
105
105
  - **06/12/2025** 在v0.4.1中支持了单机多卡的分布式DDP训练,并且提供了配套的[代码](tutorials/distributed)
106
106
  - **23/11/2025** 在v0.2.2中对basemodel进行了逻辑上的大幅重构和流程统一,并且对listwise/pairwise/pointwise损失进行了统一
107
107
  - **11/11/2025** NextRec v0.1.0发布,我们提供了10余种Ranking模型,4种多任务模型和4种召回模型,以及统一的训练/日志/指标管理系统
108
108
 
109
109
  ## 架构
110
110
 
111
- NextRec采用模块化工程设计,核心组件包括:Feature Spec驱动的Embedding架构;模型基类BaseModel;独立Layer模块;支持训练和推理的统一的DataLoader;开箱即用的模型库等。
112
-
113
- ![NextRec架构](assets/nextrec_diagram_zh.png)
111
+ NextRec采用模块化工程设计,核心组件包括:统一特征驱动的BaseModel架构;独立Layer模块;支持训练推理的统一的DataLoader;命令行工具NextCLI等。
114
112
 
115
- > 项目的架构借鉴了一些优秀的开源推荐算法库,例如DataWhaleChina社区的[torch-rechub](https://github.com/datawhalechina/torch-rechub)。torch-rechub在开发架构和模型实现上相对成熟,本人也参与了其中一小部分的维护,欢迎感兴趣的开发者前往了解。
116
-
117
- ---
113
+ ![NextRec架构](assets/nextrec_diagram.png)
118
114
 
119
115
  ## 安装
120
116
 
121
- 开发者可以通过`pip install nextrec`快速安装NextRec的最新版本,环境要求为Python 3.10+。如果需要执行示例代码,则需要先拉取仓库:
117
+ 开发者可以通过`pip install nextrec`快速安装NextRec的最新版本,环境要求为Python 3.10+(对于需要使用CUDA加速的开发者,建议安装对应版本的pytorch)。如果需要执行示例代码,则需要先拉取仓库:
122
118
 
123
119
  ```bash
124
120
  git clone https://github.com/zerolovesea/NextRec.git
@@ -245,11 +241,11 @@ nextrec --mode=train --train_config=path/to/train_config.yaml
245
241
  nextrec --mode=predict --predict_config=path/to/predict_config.yaml
246
242
  ```
247
243
 
248
- > 截止当前版本0.4.6,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
244
+ > 截止当前版本0.4.8,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
249
245
 
250
246
  ## 兼容平台
251
247
 
252
- 当前最新版本为0.4.6,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
248
+ 当前最新版本为0.4.8,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
253
249
 
254
250
  | 平台 | 配置 |
255
251
  |------|------|
@@ -273,7 +269,7 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
273
269
  | [PNN](nextrec/models/ranking/pnn.py) | Product-based Neural Networks for User Response Prediction | ICDM 2016 | 已支持 |
274
270
  | [AutoInt](nextrec/models/ranking/autoint.py) | AutoInt: Automatic Feature Interaction Learning | CIKM 2019 | 已支持 |
275
271
  | [DCN](nextrec/models/ranking/dcn.py) | Deep & Cross Network for Ad Click Predictions | ADKDD 2017 | 已支持 |
276
- | [DCN v2](nextrec/models/ranking/dcn_v2.py) | DCN V2: Improved Deep & Cross Network and Practical Lessons for Web-scale Learning to Rank Systems | KDD 2021 | 开发中 |
272
+ | [DCN v2](nextrec/models/ranking/dcn_v2.py) | DCN V2: Improved Deep & Cross Network and Practical Lessons for Web-scale Learning to Rank Systems | KDD 2021 | 已支持 |
277
273
  | [DIN](nextrec/models/ranking/din.py) | Deep Interest Network for Click-Through Rate Prediction | KDD 2018 | 已支持 |
278
274
  | [DIEN](nextrec/models/ranking/dien.py) | Deep Interest Evolution Network for Click-Through Rate Prediction | AAAI 2019 | 已支持 |
279
275
  | [MaskNet](nextrec/models/ranking/masknet.py) | MaskNet: Introducing Feature-wise Gating Blocks for High-dimensional Sparse Recommendation Data | 2020 | 已支持 |
@@ -337,21 +333,15 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
337
333
  - 实际行为
338
334
  - 环境信息(Python 版本、PyTorch 版本等)
339
335
 
340
- ---
341
-
342
336
  ## 许可证
343
337
 
344
338
  本项目采用 [Apache 2.0 许可证](./LICENSE)。
345
339
 
346
- ---
347
-
348
340
  ## 联系方式
349
341
 
350
342
  - **GitHub Issues**: [提交问题](https://github.com/zerolovesea/NextRec/issues)
351
343
  - **邮箱**: zyaztec@gmail.com
352
344
 
353
- ---
354
-
355
345
  ## 致谢
356
346
 
357
347
  NextRec 的开发受到以下优秀项目的启发:
@@ -362,6 +352,22 @@ NextRec 的开发受到以下优秀项目的启发:
362
352
 
363
353
  感谢开源社区的所有贡献者!
364
354
 
355
+
356
+ ## 引用
357
+
358
+ 如果您在研究或工作中使用了本框架,欢迎引用本项目:
359
+
360
+ ```bibtex
361
+ @misc{nextrec,
362
+ title = {NextRec},
363
+ author = {Yang Zhou},
364
+ year = {2025},
365
+ publisher = {GitHub},
366
+ journal = {GitHub repository},
367
+ howpublished = {\url{https://github.com/zerolovesea/NextRec}},
368
+ note = {A unified, efficient, and extensible PyTorch-based recommendation library}
369
+ }
370
+ ```
365
371
  ---
366
372
 
367
373
  <div align="center">
@@ -7,9 +7,9 @@
7
7
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
8
8
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
9
9
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
10
- ![Version](https://img.shields.io/badge/Version-0.4.6-orange.svg)
10
+ ![Version](https://img.shields.io/badge/Version-0.4.8-orange.svg)
11
11
 
12
- 中文文档 | [English Version](README_en.md) |
12
+ 中文文档 | [English Version](README_en.md)
13
13
 
14
14
  **统一、高效、可扩展的推荐系统框架**
15
15
 
@@ -22,7 +22,7 @@
22
22
  - [安装](#安装)
23
23
  - [架构](#架构)
24
24
  - [5分钟快速上手](#5分钟快速上手)
25
- - [命令行工具](#命令行工具)
25
+ - [命令行工具 NextRec-CLI](#命令行工具)
26
26
  - [兼容平台](#兼容平台)
27
27
  - [支持模型](#支持模型)
28
28
  - [贡献指南](#贡献指南)
@@ -32,35 +32,30 @@
32
32
  NextRec是一个基于PyTorch的现代推荐系统框架,旨在为研究工程团队提供快速的建模、训练与评估流。框架内置丰富的模型库、数据处理工具和工程化训练组件。此外提供了易上手的接口,命令行工具及教程,推荐算法学习者能以最快速度了解模型架构,复现学术论文并进行训练和部署。
33
33
 
34
34
  ## Why NextRec
35
-
36
- - **统一的特征工程与数据流水线**:NextRec框架提供了统一的特征定义、可持久化的数据处理、并对批处理进行了优化,符合工业大数据Spark/Hive场景下,基于离线特征的模型训练推理流程。
37
35
  - **多场景推荐能力**:覆盖排序(CTR/CVR)、召回、多任务学习、生成式召回等推荐/营销模型,持续跟进业界进展。
38
- - **友好的工程体验**:支持各种格式数据(`csv/parquet/pathlike`)的流式预处理/分布式训练/推理,GPU加速与可视化指标监控,方便业务算法工程师和推荐算法学习者快速复现实验。
36
+ - **统一的特征工程与数据流水线**:NextRec框架提供了统一的特征定义、可持久化的数据处理、批处理优化,符合工业大数据Spark/Hive场景下,基于离线特征的模型训练推理流程。
37
+ - **友好的工程体验**:支持多种格式数据(`csv/parquet/pathlike`)的流式处理/分布式训练/推理与可视化指标监控,方便业务算法工程师和推荐算法学习者快速复现实验。
39
38
  - **灵活的命令行工具**:支持通过命令行和配置文件,一键启动训练和推理进程,方便快速实验迭代和敏捷部署。
40
39
  - **高效训练与评估**:内置多种优化器、学习率调度、早停、模型检查点与详细的日志管理,开箱即用。
41
40
 
42
41
  ## NextRec近期进展
43
42
 
44
- - **12/12/2025** 在v0.4.6中加入了生成式召回中常见的[RQ-VAE](/nextrec/models/generative/rqvae.py)模块。配套的[数据集](/dataset/ecommerce_task.csv)和[代码](tutorials/notebooks/zh/使用RQ-VAE构建语义ID.ipynby)已经同步在仓库中
43
+ - **12/12/2025** 在v0.4.8中加入了[RQ-VAE](/nextrec/models/generative/rqvae.py)模块。配套的[数据集](/dataset/ecommerce_task.csv)和[代码](tutorials/notebooks/zh/使用RQ-VAE构建语义ID.ipynby)已经同步在仓库中
45
44
  - **07/12/2025** 发布了NextRec CLI命令行工具,它允许用户根据配置文件进行一键训练和推理,我们提供了相关的[教程](/nextrec_cli_preset/NextRec-CLI_zh.md)和[教学代码](/nextrec_cli_preset)
46
- - **03/12/2025** NextRec获得100颗🌟,感谢大家的支持
45
+ - **03/12/2025** NextRec获得了100颗🌟!感谢大家的支持
47
46
  - **06/12/2025** 在v0.4.1中支持了单机多卡的分布式DDP训练,并且提供了配套的[代码](tutorials/distributed)
48
47
  - **23/11/2025** 在v0.2.2中对basemodel进行了逻辑上的大幅重构和流程统一,并且对listwise/pairwise/pointwise损失进行了统一
49
48
  - **11/11/2025** NextRec v0.1.0发布,我们提供了10余种Ranking模型,4种多任务模型和4种召回模型,以及统一的训练/日志/指标管理系统
50
49
 
51
50
  ## 架构
52
51
 
53
- NextRec采用模块化工程设计,核心组件包括:Feature Spec驱动的Embedding架构;模型基类BaseModel;独立Layer模块;支持训练和推理的统一的DataLoader;开箱即用的模型库等。
54
-
55
- ![NextRec架构](assets/nextrec_diagram_zh.png)
52
+ NextRec采用模块化工程设计,核心组件包括:统一特征驱动的BaseModel架构;独立Layer模块;支持训练推理的统一的DataLoader;命令行工具NextCLI等。
56
53
 
57
- > 项目的架构借鉴了一些优秀的开源推荐算法库,例如DataWhaleChina社区的[torch-rechub](https://github.com/datawhalechina/torch-rechub)。torch-rechub在开发架构和模型实现上相对成熟,本人也参与了其中一小部分的维护,欢迎感兴趣的开发者前往了解。
58
-
59
- ---
54
+ ![NextRec架构](assets/nextrec_diagram.png)
60
55
 
61
56
  ## 安装
62
57
 
63
- 开发者可以通过`pip install nextrec`快速安装NextRec的最新版本,环境要求为Python 3.10+。如果需要执行示例代码,则需要先拉取仓库:
58
+ 开发者可以通过`pip install nextrec`快速安装NextRec的最新版本,环境要求为Python 3.10+(对于需要使用CUDA加速的开发者,建议安装对应版本的pytorch)。如果需要执行示例代码,则需要先拉取仓库:
64
59
 
65
60
  ```bash
66
61
  git clone https://github.com/zerolovesea/NextRec.git
@@ -187,11 +182,11 @@ nextrec --mode=train --train_config=path/to/train_config.yaml
187
182
  nextrec --mode=predict --predict_config=path/to/predict_config.yaml
188
183
  ```
189
184
 
190
- > 截止当前版本0.4.6,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
185
+ > 截止当前版本0.4.8,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
191
186
 
192
187
  ## 兼容平台
193
188
 
194
- 当前最新版本为0.4.6,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
189
+ 当前最新版本为0.4.8,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
195
190
 
196
191
  | 平台 | 配置 |
197
192
  |------|------|
@@ -215,7 +210,7 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
215
210
  | [PNN](nextrec/models/ranking/pnn.py) | Product-based Neural Networks for User Response Prediction | ICDM 2016 | 已支持 |
216
211
  | [AutoInt](nextrec/models/ranking/autoint.py) | AutoInt: Automatic Feature Interaction Learning | CIKM 2019 | 已支持 |
217
212
  | [DCN](nextrec/models/ranking/dcn.py) | Deep & Cross Network for Ad Click Predictions | ADKDD 2017 | 已支持 |
218
- | [DCN v2](nextrec/models/ranking/dcn_v2.py) | DCN V2: Improved Deep & Cross Network and Practical Lessons for Web-scale Learning to Rank Systems | KDD 2021 | 开发中 |
213
+ | [DCN v2](nextrec/models/ranking/dcn_v2.py) | DCN V2: Improved Deep & Cross Network and Practical Lessons for Web-scale Learning to Rank Systems | KDD 2021 | 已支持 |
219
214
  | [DIN](nextrec/models/ranking/din.py) | Deep Interest Network for Click-Through Rate Prediction | KDD 2018 | 已支持 |
220
215
  | [DIEN](nextrec/models/ranking/dien.py) | Deep Interest Evolution Network for Click-Through Rate Prediction | AAAI 2019 | 已支持 |
221
216
  | [MaskNet](nextrec/models/ranking/masknet.py) | MaskNet: Introducing Feature-wise Gating Blocks for High-dimensional Sparse Recommendation Data | 2020 | 已支持 |
@@ -279,21 +274,15 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
279
274
  - 实际行为
280
275
  - 环境信息(Python 版本、PyTorch 版本等)
281
276
 
282
- ---
283
-
284
277
  ## 许可证
285
278
 
286
279
  本项目采用 [Apache 2.0 许可证](./LICENSE)。
287
280
 
288
- ---
289
-
290
281
  ## 联系方式
291
282
 
292
283
  - **GitHub Issues**: [提交问题](https://github.com/zerolovesea/NextRec/issues)
293
284
  - **邮箱**: zyaztec@gmail.com
294
285
 
295
- ---
296
-
297
286
  ## 致谢
298
287
 
299
288
  NextRec 的开发受到以下优秀项目的启发:
@@ -304,6 +293,22 @@ NextRec 的开发受到以下优秀项目的启发:
304
293
 
305
294
  感谢开源社区的所有贡献者!
306
295
 
296
+
297
+ ## 引用
298
+
299
+ 如果您在研究或工作中使用了本框架,欢迎引用本项目:
300
+
301
+ ```bibtex
302
+ @misc{nextrec,
303
+ title = {NextRec},
304
+ author = {Yang Zhou},
305
+ year = {2025},
306
+ publisher = {GitHub},
307
+ journal = {GitHub repository},
308
+ howpublished = {\url{https://github.com/zerolovesea/NextRec}},
309
+ note = {A unified, efficient, and extensible PyTorch-based recommendation library}
310
+ }
311
+ ```
307
312
  ---
308
313
 
309
314
  <div align="center">
@@ -7,7 +7,7 @@
7
7
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
8
8
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
9
9
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
10
- ![Version](https://img.shields.io/badge/Version-0.4.6-orange.svg)
10
+ ![Version](https://img.shields.io/badge/Version-0.4.8-orange.svg)
11
11
 
12
12
  English | [中文文档](README.md)
13
13
 
@@ -34,8 +34,8 @@ NextRec is a modern recommendation framework built on PyTorch, delivering a unif
34
34
 
35
35
  ## Why NextRec
36
36
 
37
- - **Unified feature engineering & data pipeline**: NextRec provide unified Dense/Sparse/Sequence feature definitions, DataProcessor, and batch-optimized RecDataLoader, matching offline feature training/inference in industrial big-data settings.
38
37
  - **Multi-scenario coverage**: Ranking (CTR/CVR), retrieval, multi-task learning, and more marketing/rec models, with a continuously expanding model zoo.
38
+ - **Unified feature engineering & data pipeline**: NextRec provide unified Dense/Sparse/Sequence feature definitions, DataProcessor, and batch-optimized RecDataLoader, matching offline feature training/inference in industrial big-data settings.
39
39
  - **Developer-friendly experience**: `Stream processing/distributed training/inference` for `csv/parquet/pathlike` data, plus GPU/MPS acceleration and visualization support.
40
40
  - **Flexible CLI tooling**: Start training and inference via command line and config files for rapid experiment iteration and agile deployment.
41
41
  - **Efficient training & evaluation**: Standardized engine with optimizers, LR schedulers, early stopping, checkpoints, and detailed logging out of the box.
@@ -51,13 +51,10 @@ NextRec is a modern recommendation framework built on PyTorch, delivering a unif
51
51
 
52
52
  ## Architecture
53
53
 
54
- NextRec adopts a modular design, enabling full-pipeline reusability and scalability across data processing → model construction → training & evaluation → inference & deployment. Its core components include: a Feature-Spec-driven Embedding architecture, the BaseModel abstraction, a set of independent reusable Layers, a unified DataLoader for both training and inference, and a ready-to-use Model Zoo.
54
+ NextRec adopts a modular engineering design. The core components include: a unified feature-driven BaseModel architecture; independent Layer modules; a unified DataLoader supporting both training and inference; the NextCLI command-line tool, and more.
55
55
 
56
- ![NextRec Architecture](assets/nextrec_diagram_en.png)
56
+ ![NextRec Architecture](assets/nextrec_diagram.png)
57
57
 
58
- > The project borrows ideas from excellent open-source rec libraries, for example: [torch-rechub](https://github.com/datawhalechina/torch-rechub). torch-rechub remains mature in architecture and models; the author contributed a bit there—feel free to check it out.
59
-
60
- ---
61
58
 
62
59
  ## Installation
63
60
 
@@ -189,11 +186,11 @@ nextrec --mode=train --train_config=path/to/train_config.yaml
189
186
  nextrec --mode=predict --predict_config=path/to/predict_config.yaml
190
187
  ```
191
188
 
192
- > As of version 0.4.6, NextRec CLI supports single-machine training; distributed training features are currently under development.
189
+ > As of version 0.4.8, NextRec CLI supports single-machine training; distributed training features are currently under development.
193
190
 
194
191
  ## Platform Compatibility
195
192
 
196
- The current version is 0.4.6. All models and test code have been validated on the following platforms. If you encounter compatibility issues, please report them in the issue tracker with your system version:
193
+ The current version is 0.4.8. All models and test code have been validated on the following platforms. If you encounter compatibility issues, please report them in the issue tracker with your system version:
197
194
 
198
195
  | Platform | Configuration |
199
196
  |----------|---------------|
@@ -283,21 +280,15 @@ When submitting issues on GitHub, please include:
283
280
  - Actual behavior
284
281
  - Environment info (Python version, PyTorch version, etc.)
285
282
 
286
- ---
287
-
288
283
  ## License
289
284
 
290
285
  This project is licensed under the [Apache 2.0 License](./LICENSE).
291
286
 
292
- ---
293
-
294
287
  ## Contact
295
288
 
296
289
  - **GitHub Issues**: [Submit an issue](https://github.com/zerolovesea/NextRec/issues)
297
290
  - **Email**: zyaztec@gmail.com
298
291
 
299
- ---
300
-
301
292
  ## Acknowledgements
302
293
 
303
294
  NextRec is inspired by the following great open-source projects:
@@ -308,6 +299,23 @@ NextRec is inspired by the following great open-source projects:
308
299
 
309
300
  Special thanks to all open-source contributors!
310
301
 
302
+ ## Citation
303
+
304
+ If you use this framework in your research or work, please consider citing:
305
+
306
+ ```bibtex
307
+ @misc{nextrec,
308
+ title = {NextRec},
309
+ author = {Yang Zhou},
310
+ year = {2025},
311
+ publisher = {GitHub},
312
+ journal = {GitHub repository},
313
+ howpublished = {\url{https://github.com/zerolovesea/NextRec}},
314
+ note = {A unified, efficient, and extensible PyTorch-based recommendation library}
315
+ }
316
+
317
+ ```
318
+
311
319
  ---
312
320
 
313
321
  <div align="center">
Binary file
@@ -11,7 +11,7 @@ sys.path.insert(0, str(PROJECT_ROOT / "nextrec"))
11
11
  project = "NextRec"
12
12
  copyright = "2025, Yang Zhou"
13
13
  author = "Yang Zhou"
14
- release = "0.4.6"
14
+ release = "0.4.8"
15
15
 
16
16
  extensions = [
17
17
  "myst_parser",
@@ -0,0 +1 @@
1
+ __version__ = "0.4.8"