async def upload_file(
        self,
        file_path: str | None = None,
        file_content: bytes | None = None,
        file_name: str | None = None,
    ) -> Any:
        """
        Upload a file for OCR processing.

        Args:
            file_path: Path to the file to upload
            file_content: Binary content of the file
            file_name: Name of the file (required if file_content is provided)

        Returns:
            The uploaded file object
        """
        if file_path:
            file_name = os.path.basename(file_path)
            with open(file_path, "rb") as f:
                file_content = f.read()
        elif not file_content or not file_name:
            raise ValueError(
                "Either file_path or (file_content and file_name) must be provided"
            )

        return await self.mistral.files.upload_async(
            file={
                "file_name": file_name,
                "content": file_content,
            },
            purpose="ocr",
        )

        Upload a file for OCR processing.

        Args:
            file_path: Path to the file to upload
            file_content: Binary content of the file
            file_name: Name of the file (required if file_content is provided)

        Returns:
            The uploaded file object
        
py/core/providers/ocr/mistral.py