chats | R Documentation |
Extract chat objects from a batch result
chats(x, ...)
x |
A batch object |
... |
Additional arguments |
A list of chat objects
# Create a chat processor
chat <- chat_sequential(chat_openai())
# Process a batch of prompts
batch <- chat$batch(list(
"What is R?",
"Explain base R versus tidyverse",
"Explain vectors, lists, and data frames"
))
# Return the chat objects
batch$chats()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.