diff --git a/src/routes/(app)/+page.svelte b/src/routes/(app)/+page.svelte index 6b929795f..66cb37755 100644 --- a/src/routes/(app)/+page.svelte +++ b/src/routes/(app)/+page.svelte @@ -345,8 +345,8 @@ ? { role: 'system', content: - $settings.system + (responseMessage?.userContext ?? null) - ? `\n\nUser Context:\n${responseMessage.userContext.join('\n')}` + $settings.system + responseMessage?.userContext ?? null + ? `\n\nUser Context:\n${(responseMessage?.userContext ?? []).join('\n')}` : '' } : undefined, @@ -605,7 +605,7 @@ role: 'system', content: $settings.system + (responseMessage?.userContext ?? null) - ? `\n\nUser Context:\n${responseMessage.userContext.join('\n')}` + ? `\n\nUser Context:\n${(responseMessage?.userContext ?? []).join('\n')}` : '' } : undefined, diff --git a/src/routes/(app)/c/[id]/+page.svelte b/src/routes/(app)/c/[id]/+page.svelte index 8bf3b6d54..91d6098cd 100644 --- a/src/routes/(app)/c/[id]/+page.svelte +++ b/src/routes/(app)/c/[id]/+page.svelte @@ -351,8 +351,8 @@ ? { role: 'system', content: - $settings.system + (responseMessage?.userContext ?? null) - ? `\n\nUser Context:\n${responseMessage.userContext.join('\n')}` + $settings.system + responseMessage?.userContext ?? null + ? `\n\nUser Context:\n${(responseMessage?.userContext ?? []).join('\n')}` : '' } : undefined, @@ -611,7 +611,7 @@ role: 'system', content: $settings.system + (responseMessage?.userContext ?? null) - ? `\n\nUser Context:\n${responseMessage.userContext.join('\n')}` + ? `\n\nUser Context:\n${(responseMessage?.userContext ?? []).join('\n')}` : '' } : undefined,