ChatGPT
ChatGPT is a library with utilities to interact with the OpenAI ChatGPT API.
Functionsβ
constructorβ
Constructor to create a ChatGPT instance.
Input:
_apiKey
(string
): The API key to interact with the OpenAI ChatGPT.
completeβ
Complete a chat with the OpenAI ChatGPT.
Input:
-
messages
(``): The messages to complete the chat. -
model
(string
): The model of ChatGPT. -
temperature
(string
): The temperature of this request.
Output:
message
(string
): The response from the OpenAI ChatGPT.
completeβ
Complete a chat with the OpenAI ChatGPT.
Input:
messages
(``): The messages to complete the chat.
Output:
message
(string
): The response from the OpenAI ChatGPT.