I think sessions are finally decoupled

This commit is contained in:
perf3ct 2025-04-16 22:56:47 +00:00
parent 5e1fc5625d
commit c1ea9e376a
No known key found for this signature in database
GPG Key ID: 569C4EEC436F5232
2 changed files with 3 additions and 2 deletions

View File

@ -94,7 +94,8 @@ export async function setupStreamingResponse(
try { try {
const streamResponse = await server.post<any>(`llm/chat/${chatNoteId}/messages/stream`, { const streamResponse = await server.post<any>(`llm/chat/${chatNoteId}/messages/stream`, {
content: messageParams.content, content: messageParams.content,
includeContext: messageParams.useAdvancedContext, useAdvancedContext: messageParams.useAdvancedContext,
showThinking: messageParams.showThinking,
options: { options: {
temperature: 0.7, temperature: 0.7,
maxTokens: 2000 maxTokens: 2000

View File

@ -294,7 +294,7 @@ class RestChatService {
role: msg.role as 'user' | 'assistant' | 'system', role: msg.role as 'user' | 'assistant' | 'system',
content: msg.content content: msg.content
})), })),
query: content, query: content || '', // Ensure query is always a string, even if content is null/undefined
noteId: session.noteContext ?? undefined, noteId: session.noteContext ?? undefined,
showThinking: showThinking, showThinking: showThinking,
options: pipelineOptions, options: pipelineOptions,