Spaces:
Running
Running
history is forever
Browse files
app.R
CHANGED
@@ -147,8 +147,8 @@ server <- function(input, output, session) {
|
|
147 |
observeEvent(input$user_msg, {
|
148 |
stream <- chat$chat(input$chat)
|
149 |
|
150 |
-
#
|
151 |
-
#
|
152 |
|
153 |
# Parse response
|
154 |
response <- jsonlite::fromJSON(stream)
|
|
|
147 |
observeEvent(input$user_msg, {
|
148 |
stream <- chat$chat(input$chat)
|
149 |
|
150 |
+
# Note: ellmer will preserve full chat history automatically.
|
151 |
+
# Reset wiht chat$set_turns(NULL)
|
152 |
|
153 |
# Parse response
|
154 |
response <- jsonlite::fromJSON(stream)
|