Files
mindfulness/server/app/features/personalized_reco/reco_engine/defaults.py
2026-02-02 16:47:37 +08:00

15 lines
478 B
Python
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
from __future__ import annotations
from app.features.personalized_reco.reco_engine.types import RecoEngineConfig, Scene
def get_default_engine_config(scene: Scene) -> RecoEngineConfig:
"""
获取推荐引擎默认配置(返回副本,避免被意外修改)。
"""
# V1三种场景目前共用一套默认值保留 scene 参数便于后续按场景拆分
base = RecoEngineConfig()
return RecoEngineConfig.model_validate(base.model_dump())