mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-09 05:39:12 +00:00
Chats are not using specified Agent
The function createNewConversation is never called with the agentSlug specified so its always opening a new Conversation with the Base Agent
This commit is contained in:
@@ -962,7 +962,9 @@ export class KhojChatView extends KhojPaneView {
|
|||||||
let endpoint = `${this.setting.khojUrl}/api/chat/sessions`;
|
let endpoint = `${this.setting.khojUrl}/api/chat/sessions`;
|
||||||
if (agentSlug) {
|
if (agentSlug) {
|
||||||
endpoint += `?agent_slug=${encodeURIComponent(agentSlug)}`;
|
endpoint += `?agent_slug=${encodeURIComponent(agentSlug)}`;
|
||||||
}
|
} else if (this.currentAgent) {
|
||||||
|
endpoint += `?agent_slug=${encodeURIComponent(this.currentAgent)}`;
|
||||||
|
}
|
||||||
|
|
||||||
const response = await fetch(endpoint, {
|
const response = await fetch(endpoint, {
|
||||||
method: "POST",
|
method: "POST",
|
||||||
|
|||||||
Reference in New Issue
Block a user