MCPcopy
hub / github.com/ChatGPTNextWeb/NextChat / onUpdate

Function onUpdate

app/store/chat.ts:464–472  ·  view source on GitHub ↗
(message)

Source from the content-addressed store, hash-verified

462 messages: sendMessages,
463 config: { ...modelConfig, stream: true },
464 onUpdate(message) {
465 botMessage.streaming = true;
466 if (message) {
467 botMessage.content = message;
468 }
469 get().updateTargetSession(session, (session) => {
470 session.messages = session.messages.concat();
471 });
472 },
473 async onFinish(message) {
474 botMessage.streaming = false;
475 if (message) {

Callers

nothing calls this directly

Calls 1

getFunction · 0.70

Tested by

no test coverage detected