Skip to content
Snippets Groups Projects
Unverified Commit b9570b2e authored by Marcus Schiesser's avatar Marcus Schiesser Committed by GitHub
Browse files

fix: use generic LLMAgent instead of OpenAIAgent (adds support for Gemini and...

fix: use generic LLMAgent instead of OpenAIAgent (adds support for Gemini and Anthropic for Agentic RAG) (#410)
parent 00009ae5
No related branches found
No related tags found
No related merge requests found
---
"create-llama": patch
---
Fix: use generic LLMAgent instead of OpenAIAgent (adds support for Gemini and Anthropic for Agentic RAG)
import {
BaseChatEngine,
BaseToolWithCall,
OpenAIAgent,
LLMAgent,
QueryEngineTool,
} from "llamaindex";
import fs from "node:fs/promises";
......@@ -42,7 +42,7 @@ export async function createChatEngine(documentIds?: string[], params?: any) {
tools.push(...(await createTools(toolConfig)));
}
const agent = new OpenAIAgent({
const agent = new LLMAgent({
tools,
systemPrompt: process.env.SYSTEM_PROMPT,
}) as unknown as BaseChatEngine;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment