if (FALSE) {
# Get a beautifully formatted response (default)
goose_ask("What is the tidyverse?")
# Get raw unformatted response
raw <- goose_ask("What is R?", format = FALSE)
# Get JSON response (never formatted)
data <- goose_ask("List 5 R packages", output_format = "json")
# Customize formatting
goose_ask("Explain ggplot2", width = 100, color = FALSE)
# For very complex queries, increase timeout
goose_ask("Write a complete Shiny app", timeout = 600)
}
Run the code above in your browser using DataLab