"""
Generations Module - 生成相关路由模块

将各个子模块的路由组合成统一的 router

子模块:
- script.py  - 脚本分析端点
- tasks.py   - 任务状态端点
- image.py   - 图片生成端点
- video.py   - 视频生成端点
- audio.py   - 音频生成和导出端点
- music.py   - 音乐生成端点
- batch.py   - 批量生成端点
"""
from fastapi import APIRouter

from .script import router as script_router
from .tasks import router as tasks_router
from .image import router as image_router
from .video import router as video_router
from .audio import router as audio_router
from .music import router as music_router
from .batch import router as batch_router

# 创建主路由
router = APIRouter(tags=["generations"])

# 包含所有子路由
router.include_router(script_router)
router.include_router(tasks_router)
router.include_router(image_router)
router.include_router(video_router)
router.include_router(audio_router)
router.include_router(music_router)
router.include_router(batch_router)

# 导出辅助函数供其他模块使用
from .helpers import resolve_service, ensure_url, get_available_styles_from_config

__all__ = [
    "router",
    "resolve_service",
    "ensure_url",
    "get_available_styles_from_config",
]
