if (interactive()) {
words <- c("excellent","awful")
cfg <- llm_config("openai","gpt-4o-mini", temperature = 0)
llm_fn(words, "Classify '{x}' as Positive/Negative.",
cfg,
.system_prompt="One word.",
.return="columns")
}
Run the code above in your browser using DataLab