nextrec 0.4.18__py3-none-any.whl → 0.4.20__py3-none-any.whl

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.
nextrec/__version__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.4.18"
1
+ __version__ = "0.4.20"
nextrec/cli.py CHANGED
@@ -85,7 +85,8 @@ def train_model(train_config_path: str) -> None:
85
85
  session_id = session_cfg.get("id", "nextrec_cli_session")
86
86
  artifact_root = Path(session_cfg.get("artifact_root", "nextrec_logs"))
87
87
  session_dir = artifact_root / session_id
88
- setup_logger(session_id=session_id)
88
+
89
+ setup_logger(session_id=session_dir.resolve())
89
90
 
90
91
  log_cli_section("CLI")
91
92
  log_kv_lines(
@@ -419,8 +420,7 @@ def predict_model(predict_config_path: str) -> None:
419
420
  session_cfg = cfg.get("session", {}) or {}
420
421
  session_id = session_cfg.get("id") or session_dir.name
421
422
 
422
- setup_logger(session_id=session_id)
423
-
423
+ setup_logger(session_id=session_dir.resolve())
424
424
  log_cli_section("CLI")
425
425
  log_kv_lines(
426
426
  [
@@ -585,13 +585,12 @@ def predict_model(predict_config_path: str) -> None:
585
585
  chunk_size=predict_cfg.get("chunk_size", 20000),
586
586
  )
587
587
 
588
- # Build output path: {checkpoint_path}/predictions/{name}.{save_data_format}
589
588
  save_format = predict_cfg.get(
590
589
  "save_data_format", predict_cfg.get("save_format", "csv")
591
590
  )
592
591
  pred_name = predict_cfg.get("name", "pred")
593
- # Pass filename with extension to let model.predict handle path resolution
594
- save_path = f"{pred_name}.{save_format}"
592
+
593
+ save_path = checkpoint_base / "predictions" / f"{pred_name}.{save_format}"
595
594
 
596
595
  start = time.time()
597
596
  logger.info("")
@@ -600,7 +599,7 @@ def predict_model(predict_config_path: str) -> None:
600
599
  batch_size=batch_size,
601
600
  include_ids=bool(id_columns),
602
601
  return_dataframe=False,
603
- save_path=save_path,
602
+ save_path=str(save_path),
604
603
  save_format=save_format,
605
604
  num_workers=predict_cfg.get("num_workers", 0),
606
605
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nextrec
3
- Version: 0.4.18
3
+ Version: 0.4.20
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
@@ -67,8 +67,8 @@ Description-Content-Type: text/markdown
67
67
  ![Python](https://img.shields.io/badge/Python-3.10+-blue.svg)
68
68
  ![PyTorch](https://img.shields.io/badge/PyTorch-1.10+-ee4c2c.svg)
69
69
  ![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)
70
- ![Version](https://img.shields.io/badge/Version-0.4.18-orange.svg)
71
-
70
+ ![Version](https://img.shields.io/badge/Version-0.4.20-orange.svg)
71
+ [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/zerolovesea/NextRec)
72
72
 
73
73
  中文文档 | [English Version](README_en.md)
74
74
 
@@ -243,11 +243,13 @@ nextrec --mode=train --train_config=path/to/train_config.yaml
243
243
  nextrec --mode=predict --predict_config=path/to/predict_config.yaml
244
244
  ```
245
245
 
246
- > 截止当前版本0.4.18,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
246
+ 预测结果固定保存到 `{checkpoint_path}/predictions/{name}.{save_data_format}`。
247
+
248
+ > 截止当前版本0.4.20,NextRec CLI支持单机训练,分布式训练相关功能尚在开发中。
247
249
 
248
250
  ## 兼容平台
249
251
 
250
- 当前最新版本为0.4.18,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
252
+ 当前最新版本为0.4.20,所有模型和测试代码均已在以下平台通过验证,如果开发者在使用中遇到兼容问题,请在issue区提出错误报告及系统版本:
251
253
 
252
254
  | 平台 | 配置 |
253
255
  |------|------|
@@ -1,6 +1,6 @@
1
1
  nextrec/__init__.py,sha256=_M3oUqyuvQ5k8Th_3wId6hQ_caclh7M5ad51XN09m98,235
2
- nextrec/__version__.py,sha256=my_eRKQWrGqOjGcYUQ3l4O21n-LMG22J283Pb5L90kw,23
3
- nextrec/cli.py,sha256=xeVkW1rMLExu8AZ66jqOe4dNIh22pNz2Cbj-dtpG0_A,24445
2
+ nextrec/__version__.py,sha256=WCSj_sB9bdEmI7lwg4E_Vhy7TRLJmGYIYjp5bfMMYXE,23
3
+ nextrec/cli.py,sha256=rHATyy1v7ERPqkHNUf4-JTlRMdmlfgHd6VBNKR-Ik7o,24347
4
4
  nextrec/basic/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
5
  nextrec/basic/activation.py,sha256=uzTWfCOtBSkbu_Gk9XBNTj8__s241CaYLJk6l8nGX9I,2885
6
6
  nextrec/basic/callback.py,sha256=nn1f8FG9c52vJ-gvwteqPbk3-1QuNS1vmhBlkENdb0I,14636
@@ -72,8 +72,8 @@ nextrec/utils/embedding.py,sha256=akAEc062MG2cD7VIOllHaqtwzAirQR2gq5iW7oKpGAU,14
72
72
  nextrec/utils/feature.py,sha256=rsUAv3ELyDpehVw8nPEEsLCCIjuKGTJJZuFaWB_wrPk,633
73
73
  nextrec/utils/model.py,sha256=fHvFciUuMOVcM1oWiRva4LcArRdZ1R5Uzml-COSqqvM,4688
74
74
  nextrec/utils/torch_utils.py,sha256=AKfYbSOJjEw874xsDB5IO3Ote4X7vnqzt_E0jJny0o8,13468
75
- nextrec-0.4.18.dist-info/METADATA,sha256=5UMrAXqxBzwFPR1SwEMh_9sSOnUA9FnUQj1hF9PTt5w,21301
76
- nextrec-0.4.18.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
77
- nextrec-0.4.18.dist-info/entry_points.txt,sha256=NN-dNSdfMRTv86bNXM7d3ZEPW2BQC6bRi7QP7i9cIps,45
78
- nextrec-0.4.18.dist-info/licenses/LICENSE,sha256=2fQfVKeafywkni7MYHyClC6RGGC3laLTXCNBx-ubtp0,1064
79
- nextrec-0.4.18.dist-info/RECORD,,
75
+ nextrec-0.4.20.dist-info/METADATA,sha256=k_ph4RolNDzWnSYvhiIjopNiQOJHPs2fgeUcyg7-h80,21482
76
+ nextrec-0.4.20.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
77
+ nextrec-0.4.20.dist-info/entry_points.txt,sha256=NN-dNSdfMRTv86bNXM7d3ZEPW2BQC6bRi7QP7i9cIps,45
78
+ nextrec-0.4.20.dist-info/licenses/LICENSE,sha256=2fQfVKeafywkni7MYHyClC6RGGC3laLTXCNBx-ubtp0,1064
79
+ nextrec-0.4.20.dist-info/RECORD,,