Skip to contents

The function `ask_gpt` sends message to ChatGPT and shows the results via the console

Usage

ask_gpt(
  message,
  model = "text-davinci-003",
  maxtoken = 300,
  tempvalue = 0,
  return = "text"
)

Arguments

message

The prompt for ChatGPT

model

The ChatGPT model

maxtoken

Maximal numbers and tokens

tempvalue

The temperature

return

Returns answer as text via the console (default) or raw as a character vector

Value

A character vector.