completion interface
#Complete interface
The completion interface is suitable for older clients or scripts that still rely on the prompt field. New projects usually give priority to using the chat interface.
Path
POST /v1/completions
Base URL Please log in to the official website and view and copy it on the User Center - [API Key] page.
Applicable scenarios
- Legacy OpenAI SDK.
- Simple text continuation.
- Script tasks that do not require multiple rounds of messages.
Migration suggestions
If the client supports chat completions, it is recommended to change the prompt to the messages structure. The compatibility and capability range are usually better.