You can use the official DashScope SDK of Alibaba Cloud Model Studio (which supports Python and Java), or call the OpenAI-compatible interface of Alibaba Cloud Model Studio through the multi-language SDKs officially provided by OpenAI (such as Python, Node.js, Java, and Go).
To call realtime voice or multimodal models supported by the Realtime API through AOQ, see AOQ SDK download. For supported models and protocols, see Models and protocol support.
Install the SDK
- Python
- Java
- Node.js
- Go
Requires
python >= 3.9.You can call models on the Alibaba Cloud Model Studio platform using the OpenAI Python SDK or the DashScope Python SDK.- Install the OpenAI Python SDK
- Install the DashScope Python SDK
Install or upgrade the OpenAI Python SDK by running the following command:When the terminal displays
Successfully installed ... openai-x.x.x, the OpenAI Python SDK has been successfully installed.Next steps
After successfully installing the SDK, you can:
- Visit the Model Studio console to select models suitable for your business scenarios.
- Use the text generation models, image generation models, video generation models, speech synthesis models, speech recognition models, Embedding Model, and Reranking Model to start building your application.
- Learn more about compatibility with the OpenAI API.