o
    ¢Äiè  ã                   @  s¬   d dl mZ ddlmZ ddlmZmZ ddlmZm	Z	m
Z
mZmZmZ ddgZG d	d„ deƒZG d
d„ deƒZG dd„ dƒZG dd„ dƒZG dd„ dƒZG dd„ dƒZdS )é    )Úannotationsé   )Úcached_property)ÚSyncAPIResourceÚAsyncAPIResourceé   )ÚCompletionsÚAsyncCompletionsÚCompletionsWithRawResponseÚAsyncCompletionsWithRawResponseÚ CompletionsWithStreamingResponseÚ%AsyncCompletionsWithStreamingResponseÚChatÚ	AsyncChatc                   @  ó6   e Zd Zeddd„ƒZeddd„ƒZedd	d
„ƒZdS )r   Úreturnr   c                 C  ó
   t | jƒS ©zg
        Given a list of messages comprising a conversation, the model will return a response.
        )r   Ú_client©Úself© r   úT/home/kim/smarthome/.venv/lib/python3.10/site-packages/openai/resources/chat/chat.pyÚcompletions   ó   
zChat.completionsÚChatWithRawResponsec                 C  ó   t | ƒS ©a  
        This property can be used as a prefix for any HTTP method call to return
        the raw response object instead of the parsed content.

        For more information, see https://www.github.com/openai/openai-python#accessing-raw-response-data-eg-headers
        )r   r   r   r   r   Úwith_raw_response   ó   zChat.with_raw_responseÚChatWithStreamingResponsec                 C  r   ©zÌ
        An alternative to `.with_raw_response` that doesn't eagerly read the response body.

        For more information, see https://www.github.com/openai/openai-python#with_streaming_response
        )r    r   r   r   r   Úwith_streaming_response%   ó   zChat.with_streaming_responseN)r   r   )r   r   )r   r    ©Ú__name__Ú
__module__Ú__qualname__r   r   r   r"   r   r   r   r   r      ó    	c                   @  r   )r   r   r	   c                 C  r   r   )r	   r   r   r   r   r   r   0   r   zAsyncChat.completionsÚAsyncChatWithRawResponsec                 C  r   r   )r)   r   r   r   r   r   7   r   zAsyncChat.with_raw_responseÚAsyncChatWithStreamingResponsec                 C  r   r!   )r*   r   r   r   r   r"   A   r#   z!AsyncChat.with_streaming_responseN)r   r	   )r   r)   )r   r*   r$   r   r   r   r   r   /   r(   c                   @  ó$   e Zd Zddd„Zeddd	„ƒZd
S )r   Úchatr   r   ÚNonec                 C  ó
   || _ d S ©N©Ú_chat©r   r,   r   r   r   Ú__init__L   ó   
zChatWithRawResponse.__init__r
   c                 C  ó   t | jjƒS r   )r
   r1   r   r   r   r   r   r   O   ó   zChatWithRawResponse.completionsN©r,   r   r   r-   )r   r
   ©r%   r&   r'   r3   r   r   r   r   r   r   r   K   ó    
r   c                   @  r+   )r)   r,   r   r   r-   c                 C  r.   r/   r0   r2   r   r   r   r3   X   r4   z!AsyncChatWithRawResponse.__init__r   c                 C  r5   r   )r   r1   r   r   r   r   r   r   [   r6   z$AsyncChatWithRawResponse.completionsN©r,   r   r   r-   )r   r   r8   r   r   r   r   r)   W   r9   r)   c                   @  r+   )r    r,   r   r   r-   c                 C  r.   r/   r0   r2   r   r   r   r3   d   r4   z"ChatWithStreamingResponse.__init__r   c                 C  r5   r   )r   r1   r   r   r   r   r   r   g   r6   z%ChatWithStreamingResponse.completionsNr7   )r   r   r8   r   r   r   r   r    c   r9   r    c                   @  r+   )r*   r,   r   r   r-   c                 C  r.   r/   r0   r2   r   r   r   r3   p   r4   z'AsyncChatWithStreamingResponse.__init__r   c                 C  r5   r   )r   r1   r   r   r   r   r   r   s   r6   z*AsyncChatWithStreamingResponse.completionsNr:   )r   r   r8   r   r   r   r   r*   o   r9   r*   N)Ú
__future__r   Z_compatr   Z	_resourcer   r   Zcompletions.completionsr   r	   r
   r   r   r   Ú__all__r   r   r   r)   r    r*   r   r   r   r   Ú<module>   s    	