
    6i                         d Z ddlmZmZ ddlmZmZmZ ddlZddl	Z	ddl
mZ  e	j                  e      Z G d de      Zy)	z
Base provider class for batch processing.

This module defines the abstract base class that all batch providers must implement.
    )ABCabstractmethod)AnyOptionalUnionN   )BatchJobInfoc            	       &   e Zd ZdZe	 ddeeej                  f   de	e
eef      defd       Zedede
eef   fd       Zededefd	       Zeded
eddfd       Zedede
eef   fd       Zedede
eef   fd       Zeddedee   fd       Zy)BatchProviderz2Abstract base class for batch processing providersNfile_path_or_buffermetadatareturnc                      y)z(Submit a batch job and return the job IDN )selfr   r   kwargss       j/root/.openclaw/workspace/visionaryfx/venv/lib/python3.12/site-packages/instructor/batch/providers/base.pysubmit_batchzBatchProvider.submit_batch   s     	    batch_idc                      y)zGet the status of a batch jobNr   r   r   s     r   
get_statuszBatchProvider.get_status        	r   c                      y)z"Retrieve batch results as a stringNr   r   s     r   retrieve_resultszBatchProvider.retrieve_results"   r   r   	file_pathc                      y)z Download batch results to a fileNr   )r   r   r   s      r   download_resultszBatchProvider.download_results'   r   r   c                      y)zCancel a batch jobNr   r   s     r   cancel_batchzBatchProvider.cancel_batch,   r   r   c                      y)zDelete a batch jobNr   r   s     r   delete_batchzBatchProvider.delete_batch1   r   r   limitc                      y)zList batch jobsNr   )r   r$   s     r   list_batcheszBatchProvider.list_batches6   r   r   )N)
   )__name__
__module____qualname____doc__r   r   strioBytesIOr   dictr   r   r   r   r   r!   r#   intlistr	   r&   r   r   r   r   r      sB   < .2"3

?3 4S>*
 
  3 4S>            S T#s(^   S T#s(^   # tL/A  r   r   )r+   abcr   r   typingr   r   r   r-   loggingmodelsr	   	getLoggerr(   loggerr   r   r   r   <module>r8      s<    $ ' ' 	  !			8	$)C )r   