更新配置文件,重构工作流管理逻辑,调整国际化文件文职,优化图像生成和文本转语音服务的工作流解析,确保默认工作流配置必填,调整前端工作流选择逻辑。
This commit is contained in:
@@ -96,7 +96,7 @@ class ConfigManager:
|
||||
def get_image_config(self) -> dict:
|
||||
"""Get image configuration as dict"""
|
||||
return {
|
||||
"default": self.config.image.default,
|
||||
"default_workflow": self.config.image.default_workflow,
|
||||
"comfyui_url": self.config.image.comfyui_url,
|
||||
"runninghub_api_key": self.config.image.runninghub_api_key,
|
||||
"prompt_prefix": self.config.image.prompt_prefix,
|
||||
|
||||
@@ -15,12 +15,16 @@ class LLMConfig(BaseModel):
|
||||
|
||||
class TTSConfig(BaseModel):
|
||||
"""TTS configuration"""
|
||||
default: str = Field(default="edge", description="Default TTS workflow")
|
||||
model_config = {"populate_by_name": True} # Allow both field name and alias
|
||||
|
||||
default_workflow: str = Field(default="edge", description="Default TTS workflow", alias="default")
|
||||
|
||||
|
||||
class ImageConfig(BaseModel):
|
||||
"""Image generation configuration"""
|
||||
default: str = Field(default="image_default.json", description="Default image workflow")
|
||||
model_config = {"populate_by_name": True} # Allow both field name and alias
|
||||
|
||||
default_workflow: str = Field(default=None, description="Default image workflow (required, no fallback)", alias="default")
|
||||
comfyui_url: str = Field(default="http://127.0.0.1:8188", description="ComfyUI Server URL")
|
||||
runninghub_api_key: str = Field(default="", description="RunningHub API Key (optional)")
|
||||
prompt_prefix: str = Field(
|
||||
|
||||
Reference in New Issue
Block a user