feat(kernel): 添加算法切换设置

This commit is contained in:
2025-12-21 06:48:30 +08:00
parent e303d4dc1e
commit 0a365b568a
6 changed files with 18 additions and 5 deletions

View File

@@ -32,7 +32,11 @@ try:
except Exception as e:
print("未能加载自定义用户配置")
logger.warning("未能加载自定义用户配置, 错误: %s", e)
if pathlib.Path(rootdir / "default" / "config" / "config_dev.toml").exists():
logger.debug("使用开发设置")
config_var: ContextVar[ConfigFile] = ContextVar(
"config_var", default=ConfigFile(workdir / "config" / "config_dev.toml")
)
# runtime_var: ContextVar = ContextVar('runtime_var', default=dict()) # 运行时共享数据