I've been trying to use the chatgpt package to learn more about chat gpt. I think I don't understand how to pass in my api key. After installing the package and
library(chatgpt) I gave the command
explain_code("a <- 1;a=1")
and for told
Error in gpt_get_completions(prompt) : `OPENAI_API_KEY` not provided.
So I'm not sure how to pass in the OPENAI_API_KEY. When I tried using the function
gpt_get_completions() I get told "could not find function "gpt_get_completions"
I'm sure this is user error on my end. Any guidance appreciated.