"""
AI Service Provider Module

This module provides a unified interface for AI service providers with:
- Abstract interfaces for different AI capabilities (Image, Video, Text, Audio, Music)
- Provider registry for dynamic service discovery
- Health monitoring and automatic fallback
- Dependency injection for FastAPI

Requirement 7: Decouple AI service providers
"""

from src.services.provider.base import (
    # 状态 and Response Types
    TaskStatus,
    ServiceResponse,
    GenerationResult,
    
    # Base Provider Interfaces
    AIProvider,
    ImageProvider,
    VideoProvider,
    TextProvider,
    AudioProvider,
    MusicProvider,
    
    # Base Service Classes
    BaseService,
    BaseImageService,
    BaseVideoService,
    BaseLLMService,
    BaseAudioService,
    BaseMusicService,
    
    # 工具 Functions
    map_provider_status,
    is_terminal_status,
)

from src.services.provider.registry import (
    ModelRegistry,
    ModelType,
    ServiceConfig,
    ServiceFactory,
)

from src.services.provider.dependencies import (
    # 基本 Dependencies
    get_llm_service,
    get_image_service,
    get_video_service,
    get_audio_service,
    
    # Health-Aware Dependencies
    get_healthy_llm_service,
    get_healthy_image_service,
    
    # 自定义 Dependency Factory
    create_service_dependency,
)

from src.services.provider.fallback import (
    ProviderService,
)

from src.services.provider.health import (
    health_monitor,
    HealthStatus,
    ServiceHealth,
)

__all__ = [
    # 状态 and Response Types
    "TaskStatus",
    "ServiceResponse",
    "GenerationResult",
    
    # Base Provider Interfaces
    "AIProvider",
    "ImageProvider",
    "VideoProvider",
    "TextProvider",
    "AudioProvider",
    "MusicProvider",
    
    # Base Service Classes
    "BaseService",
    "BaseImageService",
    "BaseVideoService",
    "BaseLLMService",
    "BaseAudioService",
    "BaseMusicService",
    
    # 注册表
    "ModelRegistry",
    "ModelType",
    "ServiceConfig",
    "ServiceFactory",
    
    # Dependencies
    "get_llm_service",
    "get_image_service",
    "get_video_service",
    "get_audio_service",
    "get_healthy_llm_service",
    "get_healthy_image_service",
    "create_service_dependency",
    
    # Fallback
    "ProviderService",
    
    # Health
    "health_monitor",
    "HealthStatus",
    "ServiceHealth",
    
    # 工具 Functions
    "map_provider_status",
    "is_terminal_status",
]
