nextrec 0.5.4__tar.gz → 0.5.5__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 (249) hide show
  1. {nextrec-0.5.4 → nextrec-0.5.5}/PKG-INFO +4 -4
  2. {nextrec-0.5.4 → nextrec-0.5.5}/README.md +3 -3
  3. {nextrec-0.5.4 → nextrec-0.5.5}/README_en.md +3 -3
  4. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/conf.py +1 -1
  5. nextrec-0.5.5/nextrec/__version__.py +1 -0
  6. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/cli.py +6 -3
  7. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/config.py +5 -1
  8. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/predict_config.yaml +2 -0
  9. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/predict_config_template.yaml +4 -0
  10. {nextrec-0.5.4 → nextrec-0.5.5}/pyproject.toml +1 -1
  11. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/pages/FeaturePage.vue +16 -17
  12. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/pages/ModelPage.vue +113 -24
  13. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/pages/PredictPage.vue +17 -13
  14. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/pages/TrainPage.vue +17 -17
  15. nextrec-0.5.5/ui/nextrec-ui/src/presets/afm.yaml +24 -0
  16. nextrec-0.5.5/ui/nextrec-ui/src/presets/apg.yaml +14 -0
  17. nextrec-0.5.5/ui/nextrec-ui/src/presets/autoint.yaml +34 -0
  18. nextrec-0.5.5/ui/nextrec-ui/src/presets/cross_stitch.yaml +25 -0
  19. nextrec-0.5.5/ui/nextrec-ui/src/presets/dcn.yaml +33 -0
  20. nextrec-0.5.5/ui/nextrec-ui/src/presets/deepfm.yaml +28 -0
  21. nextrec-0.5.5/ui/nextrec-ui/src/presets/din.yaml +35 -0
  22. nextrec-0.5.5/ui/nextrec-ui/src/presets/escm.yaml +21 -0
  23. nextrec-0.5.5/ui/nextrec-ui/src/presets/esmm.yaml +32 -0
  24. nextrec-0.5.5/ui/nextrec-ui/src/presets/fibinet.yaml +26 -0
  25. nextrec-0.5.5/ui/nextrec-ui/src/presets/fm.yaml +23 -0
  26. nextrec-0.5.5/ui/nextrec-ui/src/presets/hmoe.yaml +35 -0
  27. nextrec-0.5.5/ui/nextrec-ui/src/presets/masknet.yaml +40 -0
  28. nextrec-0.5.5/ui/nextrec-ui/src/presets/mmoe.yaml +38 -0
  29. nextrec-0.5.5/ui/nextrec-ui/src/presets/pepnet.yaml +26 -0
  30. nextrec-0.5.5/ui/nextrec-ui/src/presets/ple.yaml +50 -0
  31. nextrec-0.5.5/ui/nextrec-ui/src/presets/pnn.yaml +20 -0
  32. nextrec-0.5.5/ui/nextrec-ui/src/presets/poso.yaml +52 -0
  33. nextrec-0.5.5/ui/nextrec-ui/src/presets/share_bottom.yaml +35 -0
  34. nextrec-0.5.5/ui/nextrec-ui/src/presets/widedeep.yaml +26 -0
  35. nextrec-0.5.5/ui/nextrec-ui/src/presets/xdeepfm.yaml +33 -0
  36. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/store/configStore.js +1 -0
  37. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/styles.css +72 -1
  38. nextrec-0.5.4/nextrec/__version__.py +0 -1
  39. nextrec-0.5.4/ui/nextrec-ui/src/presets/afm.yaml +0 -10
  40. nextrec-0.5.4/ui/nextrec-ui/src/presets/apg.yaml +0 -14
  41. nextrec-0.5.4/ui/nextrec-ui/src/presets/autoint.yaml +0 -13
  42. nextrec-0.5.4/ui/nextrec-ui/src/presets/cross_stitch.yaml +0 -25
  43. nextrec-0.5.4/ui/nextrec-ui/src/presets/dcn.yaml +0 -13
  44. nextrec-0.5.4/ui/nextrec-ui/src/presets/deepfm.yaml +0 -12
  45. nextrec-0.5.4/ui/nextrec-ui/src/presets/din.yaml +0 -18
  46. nextrec-0.5.4/ui/nextrec-ui/src/presets/escm.yaml +0 -21
  47. nextrec-0.5.4/ui/nextrec-ui/src/presets/esmm.yaml +0 -16
  48. nextrec-0.5.4/ui/nextrec-ui/src/presets/fibinet.yaml +0 -16
  49. nextrec-0.5.4/ui/nextrec-ui/src/presets/fm.yaml +0 -8
  50. nextrec-0.5.4/ui/nextrec-ui/src/presets/hmoe.yaml +0 -35
  51. nextrec-0.5.4/ui/nextrec-ui/src/presets/masknet.yaml +0 -17
  52. nextrec-0.5.4/ui/nextrec-ui/src/presets/mmoe.yaml +0 -22
  53. nextrec-0.5.4/ui/nextrec-ui/src/presets/pepnet.yaml +0 -26
  54. nextrec-0.5.4/ui/nextrec-ui/src/presets/ple.yaml +0 -33
  55. nextrec-0.5.4/ui/nextrec-ui/src/presets/pnn.yaml +0 -14
  56. nextrec-0.5.4/ui/nextrec-ui/src/presets/poso.yaml +0 -37
  57. nextrec-0.5.4/ui/nextrec-ui/src/presets/share_bottom.yaml +0 -20
  58. nextrec-0.5.4/ui/nextrec-ui/src/presets/widedeep.yaml +0 -12
  59. nextrec-0.5.4/ui/nextrec-ui/src/presets/xdeepfm.yaml +0 -14
  60. {nextrec-0.5.4 → nextrec-0.5.5}/.github/workflows/publish.yml +0 -0
  61. {nextrec-0.5.4 → nextrec-0.5.5}/.github/workflows/tests.yml +0 -0
  62. {nextrec-0.5.4 → nextrec-0.5.5}/.gitignore +0 -0
  63. {nextrec-0.5.4 → nextrec-0.5.5}/.readthedocs.yaml +0 -0
  64. {nextrec-0.5.4 → nextrec-0.5.5}/CODE_OF_CONDUCT.md +0 -0
  65. {nextrec-0.5.4 → nextrec-0.5.5}/CONTRIBUTING.md +0 -0
  66. {nextrec-0.5.4 → nextrec-0.5.5}/LICENSE +0 -0
  67. {nextrec-0.5.4 → nextrec-0.5.5}/MANIFEST.in +0 -0
  68. {nextrec-0.5.4 → nextrec-0.5.5}/assets/Feature Configuration.png +0 -0
  69. {nextrec-0.5.4 → nextrec-0.5.5}/assets/Model Parameters.png +0 -0
  70. {nextrec-0.5.4 → nextrec-0.5.5}/assets/Training Configuration.png +0 -0
  71. {nextrec-0.5.4 → nextrec-0.5.5}/assets/Training logs.png +0 -0
  72. {nextrec-0.5.4 → nextrec-0.5.5}/assets/logo.png +0 -0
  73. {nextrec-0.5.4 → nextrec-0.5.5}/assets/mmoe_tutorial.png +0 -0
  74. {nextrec-0.5.4 → nextrec-0.5.5}/assets/nextrec_diagram.png +0 -0
  75. {nextrec-0.5.4 → nextrec-0.5.5}/assets/test data.png +0 -0
  76. {nextrec-0.5.4 → nextrec-0.5.5}/dataset/ctcvr_task.csv +0 -0
  77. {nextrec-0.5.4 → nextrec-0.5.5}/dataset/ecommerce_task.csv +0 -0
  78. {nextrec-0.5.4 → nextrec-0.5.5}/dataset/match_task.csv +0 -0
  79. {nextrec-0.5.4 → nextrec-0.5.5}/dataset/movielens_100k.csv +0 -0
  80. {nextrec-0.5.4 → nextrec-0.5.5}/dataset/multitask_task.csv +0 -0
  81. {nextrec-0.5.4 → nextrec-0.5.5}/dataset/ranking_task.csv +0 -0
  82. {nextrec-0.5.4 → nextrec-0.5.5}/docs/en/Getting started guide.md +0 -0
  83. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/Makefile +0 -0
  84. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/index.md +0 -0
  85. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/make.bat +0 -0
  86. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/modules.rst +0 -0
  87. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/nextrec.basic.rst +0 -0
  88. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/nextrec.data.rst +0 -0
  89. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/nextrec.loss.rst +0 -0
  90. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/nextrec.rst +0 -0
  91. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/nextrec.utils.rst +0 -0
  92. {nextrec-0.5.4 → nextrec-0.5.5}/docs/rtd/requirements.txt +0 -0
  93. {nextrec-0.5.4 → nextrec-0.5.5}/docs/zh//345/277/253/351/200/237/344/270/212/346/211/213.md" +0 -0
  94. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/__init__.py +0 -0
  95. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/__init__.py +0 -0
  96. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/activation.py +0 -0
  97. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/asserts.py +0 -0
  98. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/callback.py +0 -0
  99. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/features.py +0 -0
  100. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/heads.py +0 -0
  101. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/layers.py +0 -0
  102. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/loggers.py +0 -0
  103. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/metrics.py +0 -0
  104. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/model.py +0 -0
  105. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/session.py +0 -0
  106. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/basic/summary.py +0 -0
  107. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/data/__init__.py +0 -0
  108. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/data/batch_utils.py +0 -0
  109. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/data/data_processing.py +0 -0
  110. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/data/data_utils.py +0 -0
  111. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/data/dataloader.py +0 -0
  112. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/data/preprocessor.py +0 -0
  113. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/loss/__init__.py +0 -0
  114. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/loss/grad_norm.py +0 -0
  115. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/loss/listwise.py +0 -0
  116. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/loss/pairwise.py +0 -0
  117. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/loss/pointwise.py +0 -0
  118. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/generative/__init__.py +0 -0
  119. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/generative/tiger.py +0 -0
  120. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/[pre]aitm.py +0 -0
  121. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/[pre]snr_trans.py +0 -0
  122. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/__init__.py +0 -0
  123. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/apg.py +0 -0
  124. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/cross_stitch.py +0 -0
  125. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/escm.py +0 -0
  126. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/esmm.py +0 -0
  127. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/hmoe.py +0 -0
  128. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/mmoe.py +0 -0
  129. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/pepnet.py +0 -0
  130. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/ple.py +0 -0
  131. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/poso.py +0 -0
  132. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/multi_task/share_bottom.py +0 -0
  133. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/__init__.py +0 -0
  134. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/afm.py +0 -0
  135. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/autoint.py +0 -0
  136. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/dcn.py +0 -0
  137. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/dcn_v2.py +0 -0
  138. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/deepfm.py +0 -0
  139. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/dien.py +0 -0
  140. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/din.py +0 -0
  141. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/eulernet.py +0 -0
  142. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/ffm.py +0 -0
  143. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/fibinet.py +0 -0
  144. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/fm.py +0 -0
  145. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/lr.py +0 -0
  146. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/masknet.py +0 -0
  147. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/pnn.py +0 -0
  148. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/widedeep.py +0 -0
  149. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/ranking/xdeepfm.py +0 -0
  150. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/representation/__init__.py +0 -0
  151. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/representation/rqvae.py +0 -0
  152. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/retrieval/__init__.py +0 -0
  153. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/retrieval/dssm.py +0 -0
  154. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/retrieval/dssm_v2.py +0 -0
  155. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/retrieval/mind.py +0 -0
  156. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/retrieval/sdm.py +0 -0
  157. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/retrieval/youtube_dnn.py +0 -0
  158. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/sequential/hstu.py +0 -0
  159. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/tree_base/__init__.py +0 -0
  160. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/tree_base/base.py +0 -0
  161. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/tree_base/catboost.py +0 -0
  162. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/tree_base/lightgbm.py +0 -0
  163. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/models/tree_base/xgboost.py +0 -0
  164. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/__init__.py +0 -0
  165. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/console.py +0 -0
  166. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/data.py +0 -0
  167. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/embedding.py +0 -0
  168. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/loss.py +0 -0
  169. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/model.py +0 -0
  170. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/onnx_utils.py +0 -0
  171. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/torch_utils.py +0 -0
  172. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec/utils/types.py +0 -0
  173. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/NextRec-CLI.md +0 -0
  174. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/NextRec-CLI_zh.md +0 -0
  175. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/feature_config.yaml +0 -0
  176. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/afm.yaml +0 -0
  177. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/apg.yaml +0 -0
  178. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/autoint.yaml +0 -0
  179. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/cross_stitch.yaml +0 -0
  180. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/dcn.yaml +0 -0
  181. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/deepfm.yaml +0 -0
  182. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/din.yaml +0 -0
  183. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/escm.yaml +0 -0
  184. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/esmm.yaml +0 -0
  185. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/fibinet.yaml +0 -0
  186. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/fm.yaml +0 -0
  187. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/hmoe.yaml +0 -0
  188. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/masknet.yaml +0 -0
  189. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/mmoe.yaml +0 -0
  190. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/pepnet.yaml +0 -0
  191. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/ple.yaml +0 -0
  192. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/pnn.yaml +0 -0
  193. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/poso.yaml +0 -0
  194. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/share_bottom.yaml +0 -0
  195. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/widedeep.yaml +0 -0
  196. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/model_configs/xdeepfm.yaml +0 -0
  197. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/train_config.yaml +0 -0
  198. {nextrec-0.5.4 → nextrec-0.5.5}/nextrec_cli_preset/train_config_template.yaml +0 -0
  199. {nextrec-0.5.4 → nextrec-0.5.5}/pytest.ini +0 -0
  200. {nextrec-0.5.4 → nextrec-0.5.5}/requirements.txt +0 -0
  201. {nextrec-0.5.4 → nextrec-0.5.5}/scripts/format_code.py +0 -0
  202. {nextrec-0.5.4 → nextrec-0.5.5}/scripts/profile_predict.py +0 -0
  203. {nextrec-0.5.4 → nextrec-0.5.5}/test/__init__.py +0 -0
  204. {nextrec-0.5.4 → nextrec-0.5.5}/test/conftest.py +0 -0
  205. {nextrec-0.5.4 → nextrec-0.5.5}/test/helpers.py +0 -0
  206. {nextrec-0.5.4 → nextrec-0.5.5}/test/run_tests.py +0 -0
  207. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_base_model_regularization.py +0 -0
  208. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_generative_models.py +0 -0
  209. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_layers.py +0 -0
  210. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_losses.py +0 -0
  211. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_match_models.py +0 -0
  212. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_multitask_models.py +0 -0
  213. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_onnx_models.py +0 -0
  214. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_preprocessor.py +0 -0
  215. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_ranking_models.py +0 -0
  216. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_utils_console.py +0 -0
  217. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_utils_data.py +0 -0
  218. {nextrec-0.5.4 → nextrec-0.5.5}/test/test_utils_embedding.py +0 -0
  219. {nextrec-0.5.4 → nextrec-0.5.5}/test_requirements.txt +0 -0
  220. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/distributed/example_distributed_training.py +0 -0
  221. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/distributed/example_distributed_training_large_dataset.py +0 -0
  222. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/example_match.py +0 -0
  223. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/example_multitask.py +0 -0
  224. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/example_onnx.py +0 -0
  225. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/example_ranking_din.py +0 -0
  226. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/example_tree.py +0 -0
  227. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/movielen_match_dssm.py +0 -0
  228. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/movielen_ranking_deepfm.py +0 -0
  229. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/notebooks/en/Build semantic ID with RQ-VAE.ipynb +0 -0
  230. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/notebooks/en/Hands on dataprocessor.ipynb +0 -0
  231. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/notebooks/en/Hands on nextrec.ipynb +0 -0
  232. {nextrec-0.5.4 → nextrec-0.5.5}/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
  233. {nextrec-0.5.4 → nextrec-0.5.5}/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
  234. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/notebooks/zh//345/277/253/351/200/237/345/205/245/351/227/250nextrec.ipynb" +0 -0
  235. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/run_all_match_models.py +0 -0
  236. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/run_all_multitask_models.py +0 -0
  237. {nextrec-0.5.4 → nextrec-0.5.5}/tutorials/run_all_ranking_models.py +0 -0
  238. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/Dockerfile +0 -0
  239. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/docker-compose.yml +0 -0
  240. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/index.html +0 -0
  241. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/App.vue +0 -0
  242. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/assets/logo.png +0 -0
  243. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/main.js +0 -0
  244. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/router/index.js +0 -0
  245. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/utils/buildTrainConfig.js +0 -0
  246. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/utils/download.js +0 -0
  247. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/utils/yaml.js +0 -0
  248. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/src/utils/zip.js +0 -0
  249. {nextrec-0.5.4 → nextrec-0.5.5}/ui/nextrec-ui/vite.config.js +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nextrec
3
- Version: 0.5.4
3
+ Version: 0.5.5
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
@@ -73,7 +73,7 @@ Description-Content-Type: text/markdown
73
73
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
74
74
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
75
75
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
76
- ![Version](https://img.shields.io/badge/Version-0.5.4-orange.svg)
76
+ ![Version](https://img.shields.io/badge/Version-0.5.5-orange.svg)
77
77
  [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/zerolovesea/NextRec)
78
78
 
79
79
  中文文档 | [English Version](README_en.md)
@@ -259,11 +259,11 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
259
259
 
260
260
  预测结果固定保存到 `{checkpoint_path}/predictions/{name}.{save_data_format}`。
261
261
 
262
- > 截止当前版本0.5.4,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
262
+ > 截止当前版本0.5.5,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
263
263
 
264
264
  ## 兼容平台
265
265
 
266
- 当前最新版本为0.5.4,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
266
+ 当前最新版本为0.5.5,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
267
267
 
268
268
  | 平台 | 配置 |
269
269
  |------|------|
@@ -8,7 +8,7 @@
8
8
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
9
9
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
10
10
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
11
- ![Version](https://img.shields.io/badge/Version-0.5.4-orange.svg)
11
+ ![Version](https://img.shields.io/badge/Version-0.5.5-orange.svg)
12
12
  [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/zerolovesea/NextRec)
13
13
 
14
14
  中文文档 | [English Version](README_en.md)
@@ -194,11 +194,11 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
194
194
 
195
195
  预测结果固定保存到 `{checkpoint_path}/predictions/{name}.{save_data_format}`。
196
196
 
197
- > 截止当前版本0.5.4,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
197
+ > 截止当前版本0.5.5,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
198
198
 
199
199
  ## 兼容平台
200
200
 
201
- 当前最新版本为0.5.4,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
201
+ 当前最新版本为0.5.5,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
202
202
 
203
203
  | 平台 | 配置 |
204
204
  |------|------|
@@ -8,7 +8,7 @@
8
8
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
9
9
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
10
10
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
11
- ![Version](https://img.shields.io/badge/Version-0.5.4-orange.svg)
11
+ ![Version](https://img.shields.io/badge/Version-0.5.5-orange.svg)
12
12
  [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/zerolovesea/NextRec)
13
13
 
14
14
  English | [中文文档](README.md)
@@ -197,11 +197,11 @@ nextrec --mode=predict --predict_config=path/to/predict_config.yaml
197
197
 
198
198
  Prediction outputs are saved under `{checkpoint_path}/predictions/{name}.{save_data_format}`.
199
199
 
200
- > As of version 0.5.4, NextRec CLI supports single-machine training; distributed training features are currently under development.
200
+ > As of version 0.5.5, NextRec CLI supports single-machine training; distributed training features are currently under development.
201
201
 
202
202
  ## Platform Compatibility
203
203
 
204
- The current version is 0.5.4. 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:
204
+ The current version is 0.5.5. 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:
205
205
 
206
206
  | Platform | Configuration |
207
207
  |----------|---------------|
@@ -11,7 +11,7 @@ sys.path.insert(0, str(PROJECT_ROOT / "nextrec"))
11
11
  project = "NextRec"
12
12
  copyright = "2026, Yang Zhou"
13
13
  author = "Yang Zhou"
14
- release = "0.5.4"
14
+ release = "0.5.5"
15
15
 
16
16
  extensions = [
17
17
  "myst_parser",
@@ -0,0 +1 @@
1
+ __version__ = "0.5.5"
@@ -137,7 +137,7 @@ def train_model(train_config_path: str) -> None:
137
137
  model_cfg = read_yaml(model_cfg_path)
138
138
 
139
139
  # Extract id_column from data config for GAUC metrics
140
- id_column = data_cfg.get("id_column") or data_cfg.get("user_id_column")
140
+ id_column = data_cfg.get("id_column")
141
141
  id_columns = [id_column] if id_column else []
142
142
 
143
143
  log_cli_section("Data")
@@ -378,6 +378,7 @@ def train_model(train_config_path: str) -> None:
378
378
  sparse_features,
379
379
  sequence_features,
380
380
  target,
381
+ id_columns,
381
382
  device,
382
383
  )
383
384
 
@@ -585,14 +586,16 @@ def predict_model(predict_config_path: str) -> None:
585
586
  sparse_features=sparse_features,
586
587
  sequence_features=sequence_features,
587
588
  target=target_cols,
589
+ id_columns=id_columns,
588
590
  device=predict_cfg.get("device", "cpu"),
589
591
  )
590
- model.id_columns = id_columns
592
+
591
593
  model.load_model(
592
594
  model_file, map_location=predict_cfg.get("device", "cpu"), verbose=True
593
595
  )
594
596
 
595
- effective_id_columns = model.id_columns
597
+ effective_id_columns = id_columns or model.id_columns
598
+
596
599
  log_cli_section("Features")
597
600
  log_kv_lines(
598
601
  [
@@ -388,6 +388,7 @@ def build_model_instance(
388
388
  sparse_features: List["SparseFeature"],
389
389
  sequence_features: List["SequenceFeature"],
390
390
  target: List[str],
391
+ id_columns: list[str] | str | None,
391
392
  device: str,
392
393
  ) -> Any:
393
394
  """
@@ -400,6 +401,7 @@ def build_model_instance(
400
401
  sparse_features: List of sparse feature objects
401
402
  sequence_features: List of sequence feature objects
402
403
  target: List of target column names
404
+ id_columns: Identifier column name(s) for GAUC or ID passthrough
403
405
  device: Device string (e.g., 'cpu', 'cuda:0')
404
406
  """
405
407
  dense_map = {f.name: f for f in dense_features}
@@ -436,7 +438,7 @@ def build_model_instance(
436
438
  param.kind == inspect.Parameter.VAR_KEYWORD for param in sig_params.values()
437
439
  )
438
440
 
439
- init_kwargs: Dict[str, Any] = dict(params_cfg)
441
+ init_kwargs = dict(params_cfg)
440
442
 
441
443
  # Explicit bindings (model_config.feature_bindings) take priority
442
444
  for param_name, binding in feature_bindings_cfg.items():
@@ -517,6 +519,8 @@ def build_model_instance(
517
519
 
518
520
  if accepts("target"):
519
521
  init_kwargs.setdefault("target", target)
522
+ if accepts("id_columns") or accepts_var_kwargs:
523
+ init_kwargs.setdefault("id_columns", id_columns)
520
524
  if accepts("device"):
521
525
  init_kwargs.setdefault("device", device)
522
526
 
@@ -6,6 +6,8 @@ predict:
6
6
  data_path: ../dataset/ctcvr_task.csv
7
7
  source_data_format: csv # Input data format: csv, parquet, etc.
8
8
  # Use 'auto' for automatic detection
9
+ id_column: user_id # Column name for user/sample IDs
10
+ # Will be included in prediction output
9
11
  name: pred # Output filename (without extension) or absolute path
10
12
  # Filename -> {checkpoint_path}/predictions/{name}.{save_data_format}
11
13
  # Absolute path -> saved directly (extension auto-added if missing)
@@ -30,6 +30,10 @@ predict:
30
30
  # ----- Data Format Settings -----
31
31
  source_data_format: parquet # Input data format: csv, parquet, etc.
32
32
  # Use 'auto' for automatic detection
33
+
34
+ # ----- Identification Settings -----
35
+ id_column: user_id # Column name for user/sample IDs
36
+ # Will be included in prediction output
33
37
 
34
38
  # ----- Output Settings -----
35
39
  name: pred # Output filename (without extension) or absolute path
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "nextrec"
3
- version = "0.5.4"
3
+ version = "0.5.5"
4
4
  description = "A comprehensive recommendation library with match, ranking, and multi-task learning models"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.10"
@@ -8,7 +8,7 @@
8
8
  </div>
9
9
 
10
10
  <div class="card">
11
- <h2>{{ t('Dense 特征', 'Dense Features') }}</h2>
11
+ <h2>{{ t('稠密特征', 'Dense Features') }}</h2>
12
12
  <div class="inline-list">
13
13
  <div v-for="(item, index) in dense" :key="item.id" class="inline-item">
14
14
  <div class="grid-inline">
@@ -17,11 +17,13 @@
17
17
  <input v-model="item.name" placeholder="user_active_days_7" />
18
18
  </div>
19
19
  <div class="field">
20
- <label>{{ t('归一化方式', 'scaler') }}</label>
20
+ <label>{{ t('缩放方式', 'Scaler') }}</label>
21
21
  <select v-model="item.processor.scaler">
22
22
  <option value="standard">standard</option>
23
23
  <option value="minmax">minmax</option>
24
24
  <option value="robust">robust</option>
25
+ <option value="maxabs">maxabs</option>
26
+ <option value="log">log</option>
25
27
  <option value="none">none</option>
26
28
  </select>
27
29
  </div>
@@ -42,7 +44,7 @@
42
44
  </div>
43
45
  </div>
44
46
  <div class="actions">
45
- <button class="ghost" @click="remove(dense, index)">{{ t('移除', 'Remove') }}</button>
47
+ <button class="icon-button icon-button-small icon-button-danger" @click="remove(dense, index)" aria-label="移除">×</button>
46
48
  </div>
47
49
  </div>
48
50
  </div>
@@ -52,7 +54,7 @@
52
54
  </div>
53
55
 
54
56
  <div class="card">
55
- <h2>{{ t('Sparse 特征', 'Sparse Features') }}</h2>
57
+ <h2>{{ t('稀疏特征', 'Sparse Features') }}</h2>
56
58
  <div class="inline-list">
57
59
  <div v-for="(item, index) in sparse" :key="item.id" class="inline-item">
58
60
  <div class="grid-inline">
@@ -68,10 +70,10 @@
68
70
  <label>{{ t('编码方式', 'encode_method') }}</label>
69
71
  <select v-model="item.processor.encode_method">
70
72
  <option value="hash">hash</option>
71
- <option value="vocab">vocab</option>
73
+ <option value="label">label</option>
72
74
  </select>
73
75
  </div>
74
- <div class="field">
76
+ <div class="field" v-if="item.processor.encode_method === 'hash'">
75
77
  <label>{{ t('哈希桶大小', 'hash_size') }}</label>
76
78
  <input v-model.number="item.processor.hash_size" type="number" />
77
79
  </div>
@@ -89,7 +91,7 @@
89
91
  </div>
90
92
  </div>
91
93
  <div class="actions">
92
- <button class="ghost" @click="remove(sparse, index)">{{ t('移除', 'Remove') }}</button>
94
+ <button class="icon-button icon-button-small icon-button-danger" @click="remove(sparse, index)" aria-label="移除">×</button>
93
95
  </div>
94
96
  </div>
95
97
  </div>
@@ -99,7 +101,7 @@
99
101
  </div>
100
102
 
101
103
  <div class="card">
102
- <h2>{{ t('Sequence 特征', 'Sequence Features') }}</h2>
104
+ <h2>{{ t('序列特征', 'Sequence Features') }}</h2>
103
105
  <div class="inline-list">
104
106
  <div v-for="(item, index) in sequence" :key="item.id" class="inline-item">
105
107
  <div class="grid-inline">
@@ -115,10 +117,10 @@
115
117
  <label>{{ t('编码方式', 'encode_method') }}</label>
116
118
  <select v-model="item.processor.encode_method">
117
119
  <option value="hash">hash</option>
118
- <option value="vocab">vocab</option>
120
+ <option value="label">label</option>
119
121
  </select>
120
122
  </div>
121
- <div class="field">
123
+ <div class="field" v-if="item.processor.encode_method === 'hash'">
122
124
  <label>{{ t('哈希桶大小', 'hash_size') }}</label>
123
125
  <input v-model.number="item.processor.hash_size" type="number" />
124
126
  </div>
@@ -127,7 +129,7 @@
127
129
  <input v-model.number="item.processor.min_freq" type="number" />
128
130
  </div>
129
131
  <div class="field">
130
- <label>{{ t('最大长度', 'max_len') }}</label>
132
+ <label>{{ t('截断最大长度', 'max_len') }}</label>
131
133
  <input v-model.number="item.processor.max_len" type="number" />
132
134
  </div>
133
135
  <div class="field">
@@ -149,10 +151,6 @@
149
151
  <label>{{ t('词表大小', 'vocab_size') }}</label>
150
152
  <input v-model.number="item.embedding.vocab_size" type="number" />
151
153
  </div>
152
- <div class="field">
153
- <label>{{ t('最大长度', 'max_len') }}</label>
154
- <input v-model.number="item.embedding.max_len" type="number" />
155
- </div>
156
154
  <div class="field">
157
155
  <label>{{ t('池化方式', 'combiner') }}</label>
158
156
  <select v-model="item.embedding.combiner">
@@ -173,7 +171,7 @@
173
171
  </div>
174
172
  </div>
175
173
  <div class="actions">
176
- <button class="ghost" @click="remove(sequence, index)">{{ t('移除', 'Remove') }}</button>
174
+ <button class="icon-button icon-button-small icon-button-danger" @click="remove(sequence, index)" aria-label="移除">×</button>
177
175
  </div>
178
176
  </div>
179
177
  </div>
@@ -188,7 +186,7 @@
188
186
  <textarea class="mono" readonly :value="yamlText"></textarea>
189
187
  </div>
190
188
  <div class="actions spaced-top">
191
- <button class="primary" @click="download">{{ t('下载 feature_config.yaml', 'Download feature_config.yaml') }}</button>
189
+ <button class="primary" @click="download">{{ t('下载', 'Download') }}</button>
192
190
  </div>
193
191
  </div>
194
192
  </section>
@@ -230,6 +228,7 @@ function buildSection(items) {
230
228
  continue;
231
229
  }
232
230
  const embedding = { ...item.embedding };
231
+ embedding.max_len = item.processor.max_len;
233
232
  embedding.name = item.name;
234
233
  section[item.name] = {
235
234
  processor_config: { ...item.processor },
@@ -17,27 +17,8 @@
17
17
  </select>
18
18
  </div>
19
19
  </div>
20
- </div>
21
-
22
- <div class="card">
23
- <h2>{{ t('正则配置', 'Regularization') }}</h2>
24
- <div class="grid-inline">
25
- <div class="field">
26
- <label>embedding_l1_reg</label>
27
- <input v-model.number="regEmbeddingL1" type="number" step="0.000001" />
28
- </div>
29
- <div class="field">
30
- <label>embedding_l2_reg</label>
31
- <input v-model.number="regEmbeddingL2" type="number" step="0.000001" />
32
- </div>
33
- <div class="field">
34
- <label>dense_l1_reg</label>
35
- <input v-model.number="regDenseL1" type="number" step="0.000001" />
36
- </div>
37
- <div class="field">
38
- <label>dense_l2_reg</label>
39
- <input v-model.number="regDenseL2" type="number" step="0.000001" />
40
- </div>
20
+ <div v-if="modelNote" class="alert model-note" style="margin-top: 12px;">
21
+ {{ modelNote }}
41
22
  </div>
42
23
  </div>
43
24
 
@@ -52,11 +33,19 @@
52
33
  </div>
53
34
  </div>
54
35
  <div class="field" style="margin-top: 12px;">
55
- <label>{{ t('值', 'Value') }}</label>
36
+ <label>
37
+ {{ t('值', 'Value') }}
38
+ <span
39
+ v-if="paramHelp[entry.key]"
40
+ class="help-icon"
41
+ :title="paramHelp[entry.key]"
42
+ :data-tip="paramHelp[entry.key]"
43
+ >?</span>
44
+ </label>
56
45
  <textarea v-model="entry.raw" class="mono" placeholder="relu 或 123 或 true 或 \nmlp_params:\n hidden_dims: [256, 128]"></textarea>
57
46
  </div>
58
47
  <div class="actions">
59
- <button class="icon-button" @click="removeEntryById(entry.id)" :disabled="paramEntries.length <= 1" aria-label="移除">×</button>
48
+ <button class="icon-button icon-button-small icon-button-danger" @click="removeEntryById(entry.id)" :disabled="paramEntries.length <= 1" aria-label="移除">×</button>
60
49
  </div>
61
50
  </div>
62
51
  </div>
@@ -65,6 +54,28 @@
65
54
  </div>
66
55
  </div>
67
56
 
57
+ <div class="card">
58
+ <h2>{{ t('正则配置', 'Regularization') }}</h2>
59
+ <div class="grid-inline">
60
+ <div class="field">
61
+ <label>embedding_l1_reg</label>
62
+ <input v-model.number="regEmbeddingL1" type="number" step="0.000001" />
63
+ </div>
64
+ <div class="field">
65
+ <label>embedding_l2_reg</label>
66
+ <input v-model.number="regEmbeddingL2" type="number" step="0.000001" />
67
+ </div>
68
+ <div class="field">
69
+ <label>dense_l1_reg</label>
70
+ <input v-model.number="regDenseL1" type="number" step="0.000001" />
71
+ </div>
72
+ <div class="field">
73
+ <label>dense_l2_reg</label>
74
+ <input v-model.number="regDenseL2" type="number" step="0.000001" />
75
+ </div>
76
+ </div>
77
+ </div>
78
+
68
79
  <div class="card">
69
80
  <h2>{{ t('YAML 预览', 'YAML Preview') }}</h2>
70
81
  <div v-if="error" class="alert">{{ error }}</div>
@@ -72,7 +83,7 @@
72
83
  <textarea class="mono" readonly :value="yamlText"></textarea>
73
84
  </div>
74
85
  <div class="actions spaced-top">
75
- <button class="primary" @click="download" :disabled="!!error">{{ t('下载 model_config.yaml', 'Download model_config.yaml') }}</button>
86
+ <button class="primary" @click="download" :disabled="!!error">{{ t('下载', 'Download') }}</button>
76
87
  </div>
77
88
  </div>
78
89
  </section>
@@ -99,6 +110,68 @@ function toParamsText(raw) {
99
110
  return '';
100
111
  }
101
112
 
113
+ function parsePresetComments(raw) {
114
+ const lines = raw.split(/\r?\n/);
115
+ const topComments = [];
116
+ let inTop = true;
117
+ const paramComments = {};
118
+ const pendingByIndent = new Map();
119
+ let inParams = false;
120
+
121
+ for (let i = 0; i < lines.length; i += 1) {
122
+ const line = lines[i];
123
+ const trimmed = line.trim();
124
+ if (inTop) {
125
+ if (trimmed.startsWith('#')) {
126
+ topComments.push(trimmed.replace(/^#+\s?/, ''));
127
+ continue;
128
+ }
129
+ if (trimmed === '') {
130
+ continue;
131
+ }
132
+ inTop = false;
133
+ }
134
+
135
+ if (trimmed.startsWith('params:')) {
136
+ inParams = true;
137
+ continue;
138
+ }
139
+ if (!inParams) {
140
+ continue;
141
+ }
142
+
143
+ const indent = line.match(/^\s*/)?.[0].length ?? 0;
144
+ if (trimmed.startsWith('#') && indent >= 2) {
145
+ pendingByIndent.set(indent, trimmed.replace(/^#+\s?/, ''));
146
+ continue;
147
+ }
148
+
149
+ const match = line.match(/^\s{2,}([A-Za-z0-9_]+):/);
150
+ if (!match) {
151
+ continue;
152
+ }
153
+ const key = match[1];
154
+ let comment = '';
155
+ const inlineIdx = line.indexOf('#');
156
+ if (inlineIdx !== -1) {
157
+ comment = line.slice(inlineIdx + 1).trim();
158
+ } else {
159
+ comment = pendingByIndent.get(indent) || '';
160
+ }
161
+ if (comment) {
162
+ paramComments[key] = comment;
163
+ }
164
+ pendingByIndent.delete(indent);
165
+ }
166
+
167
+ return { top: topComments.join('\n'), params: paramComments };
168
+ }
169
+
170
+ function getPresetRaw(name) {
171
+ const entry = Object.entries(presetModules).find(([path]) => path.endsWith(`/${name}.yaml`));
172
+ return entry ? entry[1] : '';
173
+ }
174
+
102
175
  const presets = Object.entries(presetModules).reduce((acc, [path, raw]) => {
103
176
  const data = parseYaml(raw) || {};
104
177
  const modelName = data.model || filenameToModel(path);
@@ -116,6 +189,8 @@ const lang = computed(() => store.ui.lang);
116
189
  const t = (zh, en) => (lang.value === 'zh' ? zh : en);
117
190
  const error = ref('');
118
191
  const paramEntries = reactive([]);
192
+ const paramHelp = reactive({});
193
+ const modelNote = ref('');
119
194
  const hiddenParamKeys = new Set(['embedding_l1_reg', 'embedding_l2_reg', 'dense_l1_reg', 'dense_l2_reg']);
120
195
  const visibleParamEntries = computed(() => paramEntries.filter((entry) => !hiddenParamKeys.has(entry.key)));
121
196
 
@@ -159,6 +234,12 @@ function applyPreset() {
159
234
  form.paramsText = preset.paramsText;
160
235
  const params = parseYaml(form.paramsText) || {};
161
236
  setEntriesFromParams(params);
237
+ const comments = parsePresetComments(getPresetRaw(modelName));
238
+ modelNote.value = comments.top;
239
+ Object.keys(paramHelp).forEach((key) => delete paramHelp[key]);
240
+ Object.entries(comments.params).forEach(([key, note]) => {
241
+ paramHelp[key] = note;
242
+ });
162
243
  }
163
244
 
164
245
  function addEntry() {
@@ -272,5 +353,13 @@ onMounted(() => {
272
353
  }
273
354
  const params = parseYaml(form.paramsText || '') || {};
274
355
  setEntriesFromParams(params);
356
+ if (preset) {
357
+ const comments = parsePresetComments(getPresetRaw(preset.model));
358
+ modelNote.value = comments.top;
359
+ Object.keys(paramHelp).forEach((key) => delete paramHelp[key]);
360
+ Object.entries(comments.params).forEach(([key, note]) => {
361
+ paramHelp[key] = note;
362
+ });
363
+ }
275
364
  });
276
365
  </script>
@@ -29,11 +29,11 @@
29
29
  <h2>{{ t('Predict 参数', 'Prediction Settings') }}</h2>
30
30
  <div class="grid-2">
31
31
  <div class="field">
32
- <label>{{ t('Data Path', 'Data Path') }}</label>
32
+ <label>{{ t('数据路径', 'Data Path') }}</label>
33
33
  <input v-model="form.predict.data_path" placeholder="/path/to/predict/data" />
34
34
  </div>
35
35
  <div class="field">
36
- <label>{{ t('Source Data Format', 'Source Data Format') }}</label>
36
+ <label>{{ t('源数据格式', 'Source Data Format') }}</label>
37
37
  <select v-model="form.predict.source_data_format">
38
38
  <option value="parquet">parquet</option>
39
39
  <option value="csv">csv</option>
@@ -41,52 +41,56 @@
41
41
  </select>
42
42
  </div>
43
43
  <div class="field">
44
- <label>{{ t('Output Name', 'Output Name') }}</label>
44
+ <label>{{ t('ID ', 'ID Column') }}</label>
45
+ <input v-model="form.predict.id_column" placeholder="user_id" />
46
+ </div>
47
+ <div class="field">
48
+ <label>{{ t('输出名称', 'Output Name') }}</label>
45
49
  <input v-model="form.predict.name" placeholder="pred" />
46
50
  </div>
47
51
  <div class="field">
48
- <label>{{ t('Save Data Format', 'Save Data Format') }}</label>
52
+ <label>{{ t('保存格式', 'Save Data Format') }}</label>
49
53
  <select v-model="form.predict.save_data_format">
50
54
  <option value="csv">csv</option>
51
55
  <option value="parquet">parquet</option>
52
56
  </select>
53
57
  </div>
54
58
  <div class="field">
55
- <label>{{ t('Preview Rows', 'Preview Rows') }}</label>
59
+ <label>{{ t('预览行数', 'Preview Rows') }}</label>
56
60
  <input v-model.number="form.predict.preview_rows" type="number" />
57
61
  </div>
58
62
  <div class="field">
59
- <label>{{ t('Batch Size', 'Batch Size') }}</label>
63
+ <label>{{ t('批大小', 'Batch Size') }}</label>
60
64
  <input v-model.number="form.predict.batch_size" type="number" />
61
65
  </div>
62
66
  <div class="field">
63
- <label>{{ t('Num Workers', 'Num Workers') }}</label>
67
+ <label>{{ t('工作进程数', 'Num Workers') }}</label>
64
68
  <input v-model.number="form.predict.num_workers" type="number" />
65
69
  </div>
66
70
  <div class="field">
67
- <label>{{ t('Num Processes', 'Num Processes') }}</label>
71
+ <label>{{ t('推理进程数', 'Num Processes') }}</label>
68
72
  <input v-model.number="form.predict.num_processes" type="number" />
69
73
  </div>
70
74
  <div class="field">
71
- <label>{{ t('Device', 'Device') }}</label>
75
+ <label>{{ t('设备', 'Device') }}</label>
72
76
  <input v-model="form.predict.device" placeholder="cpu" />
73
77
  </div>
74
78
  <div class="field">
75
- <label>{{ t('Use ONNX', 'Use ONNX') }}</label>
79
+ <label>{{ t('使用 ONNX', 'Use ONNX') }}</label>
76
80
  <select v-model="form.predict.use_onnx">
77
81
  <option :value="false">false</option>
78
82
  <option :value="true">true</option>
79
83
  </select>
80
84
  </div>
81
85
  <div class="field">
82
- <label>{{ t('Streaming', 'Streaming') }}</label>
86
+ <label>{{ t('流式处理', 'Streaming') }}</label>
83
87
  <select v-model="form.predict.streaming">
84
88
  <option :value="true">true</option>
85
89
  <option :value="false">false</option>
86
90
  </select>
87
91
  </div>
88
92
  <div class="field">
89
- <label>{{ t('Chunk Size', 'Chunk Size') }}</label>
93
+ <label>{{ t('分块大小', 'Chunk Size') }}</label>
90
94
  <input v-model.number="form.predict.chunk_size" type="number" />
91
95
  </div>
92
96
  </div>
@@ -98,7 +102,7 @@
98
102
  <textarea class="mono" readonly :value="yamlText"></textarea>
99
103
  </div>
100
104
  <div class="actions spaced-top">
101
- <button class="primary" @click="download">{{ t('下载 predict_config.yaml', 'Download predict_config.yaml') }}</button>
105
+ <button class="primary" @click="download">{{ t('下载', 'Download') }}</button>
102
106
  </div>
103
107
  </div>
104
108
  </section>