diff --git a/pkg-r/R/querychat.R b/pkg-r/R/querychat.R index c9794009..1bb9d5e8 100644 --- a/pkg-r/R/querychat.R +++ b/pkg-r/R/querychat.R @@ -201,9 +201,9 @@ querychat_server <- function(id, querychat_config) { greeting <- querychat_config[["greeting"]] client <- querychat_config[["client"]] - current_title <- shiny::reactiveVal(NULL) - current_query <- shiny::reactiveVal("") - filtered_df <- shiny::reactive({ + current_title <- shiny::reactiveVal(NULL, label = "current_title") + current_query <- shiny::reactiveVal("", label = "current_query") + filtered_df <- shiny::reactive(label = "filtered_df", { execute_query(data_source, query = DBI::SQL(current_query())) }) @@ -257,11 +257,11 @@ querychat_server <- function(id, querychat_config) { } ) - shiny::observeEvent(input$chat_user_input, { + shiny::observeEvent(input$chat_user_input, label = "on_chat_user_input", { append_stream_task$invoke(chat, input$chat_user_input) }) - shiny::observeEvent(input$chat_update, { + shiny::observeEvent(input$chat_update, label = "on_chat_update", { current_query(input$chat_update$query) current_title(input$chat_update$title) }) diff --git a/pkg-r/R/querychat_app.R b/pkg-r/R/querychat_app.R index f19a8e47..06d55759 100644 --- a/pkg-r/R/querychat_app.R +++ b/pkg-r/R/querychat_app.R @@ -102,7 +102,7 @@ querychat_app <- function(config, ..., bookmark_store = "url") { ) }) - shiny::observeEvent(input$reset_query, { + shiny::observeEvent(input$reset_query, label = "on_reset_query", { qc$update_query("", NULL) }) @@ -127,7 +127,7 @@ querychat_app <- function(config, ..., bookmark_store = "url") { ) }) - shiny::observeEvent(input$close_btn, { + shiny::observeEvent(input$close_btn, label = "on_close_btn", { shiny::stopApp() }) }