aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/chatbot/agentsystem
diff options
context:
space:
mode:
authorA.J. Shulman <Shulman.aj@gmail.com>2024-12-19 11:45:00 -0500
committerA.J. Shulman <Shulman.aj@gmail.com>2024-12-19 11:45:00 -0500
commitf915013d2ccfaeb7f04bf8bfea57e6d7d1f66b81 (patch)
tree69cde0426434a687a096ebe987145628afd145b0 /src/client/views/nodes/chatbot/agentsystem
parent9b4c554cca11f5c3105085b54646e684dd235f1d (diff)
image generation works better
Diffstat (limited to 'src/client/views/nodes/chatbot/agentsystem')
-rw-r--r--src/client/views/nodes/chatbot/agentsystem/Agent.ts11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/client/views/nodes/chatbot/agentsystem/Agent.ts b/src/client/views/nodes/chatbot/agentsystem/Agent.ts
index 1eb5e3963..1cf6ca030 100644
--- a/src/client/views/nodes/chatbot/agentsystem/Agent.ts
+++ b/src/client/views/nodes/chatbot/agentsystem/Agent.ts
@@ -21,6 +21,7 @@ import { CreateTextDocTool } from '../tools/CreateTextDocumentTool';
import { DocumentOptions } from '../../../../documents/Documents';
import { CreateAnyDocumentTool } from '../tools/CreateAnyDocTool';
import { ImageCreationTool } from '../tools/ImageCreationTool';
+import { DictionaryTool } from '../tools/DictionaryTool';
dotenv.config();
@@ -60,7 +61,8 @@ export class Agent {
csvData: () => { filename: string; id: string; text: string }[],
addLinkedUrlDoc: (url: string, id: string) => void,
addLinkedDoc: (doc_type: string, data: string | undefined, options: DocumentOptions, id: string) => void,
- createCSVInDash: (url: string, title: string, id: string, data: string) => void
+ createCSVInDash: (url: string, title: string, id: string, data: string) => void,
+ createImage: (result: any, options: DocumentOptions) => void
) {
// Initialize OpenAI client with API key from environment
this.client = new OpenAI({ apiKey: process.env.OPENAI_KEY, dangerouslyAllowBrowser: true });
@@ -74,13 +76,14 @@ export class Agent {
calculate: new CalculateTool(),
rag: new RAGTool(this.vectorstore),
dataAnalysis: new DataAnalysisTool(csvData),
- //websiteInfoScraper: new WebsiteInfoScraperTool(addLinkedUrlDoc),
- //searchTool: new SearchTool(addLinkedUrlDoc),
+ websiteInfoScraper: new WebsiteInfoScraperTool(addLinkedUrlDoc),
+ searchTool: new SearchTool(addLinkedUrlDoc),
createCSV: new CreateCSVTool(createCSVInDash),
noTool: new NoTool(),
- imageCreationTool: new ImageCreationTool(addLinkedDoc),
+ imageCreationTool: new ImageCreationTool(createImage),
//createTextDoc: new CreateTextDocTool(addLinkedDoc),
createAnyDocument: new CreateAnyDocumentTool(addLinkedDoc),
+ dictionary: new DictionaryTool(),
};
}