The OpenAI Python library provides convenient access to the OpenAI REST API from any Python 3.7+ application. It includes type definitions for request params and response fields, supports both synchronous and asynchronous clients, and provides helper functions for streaming responses.

10m read timeFrom github.com
Post cover image
Table of contents
DocumentationInstallationUsageAsync usageStreaming responsesModule-level clientUsing typesPaginationNested paramsFile uploadsHandling errorsAdvancedMicrosoft Azure OpenAIVersioningRequirements

Sort: