from functools import lru_cache
from mini_videorag.temporal.api.services import WorkflowService, StorageService


@lru_cache
def get_workflow_service() -> WorkflowService:
    """
    Get workflow service singleton.

    Returns:
        WorkflowService instance configured from environment
    """
    return WorkflowService()


@lru_cache
def get_storage_service() -> StorageService:
    """
    Get storage service singleton.

    Returns:
        StorageService instance configured from environment
    """
    return StorageService()
