mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-05-24 06:30:16 +09:00
fix: tool call returnDirect
This commit is contained in:
parent
8cdbc231ca
commit
cccd518008
@ -38,37 +38,6 @@ export class EdgeTool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async getCustomTools(): Promise<any[]> {
|
async getCustomTools(): Promise<any[]> {
|
||||||
// let searchTool: Tool = new DuckDuckGo();
|
|
||||||
// if (process.env.CHOOSE_SEARCH_ENGINE) {
|
|
||||||
// switch (process.env.CHOOSE_SEARCH_ENGINE) {
|
|
||||||
// case "google":
|
|
||||||
// searchTool = new GoogleSearch();
|
|
||||||
// break;
|
|
||||||
// case "baidu":
|
|
||||||
// searchTool = new BaiduSearch();
|
|
||||||
// break;
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// if (process.env.BING_SEARCH_API_KEY) {
|
|
||||||
// let bingSearchTool = new langchainTools["BingSerpAPI"](
|
|
||||||
// process.env.BING_SEARCH_API_KEY,
|
|
||||||
// );
|
|
||||||
// searchTool = new DynamicTool({
|
|
||||||
// name: "bing_search",
|
|
||||||
// description: bingSearchTool.description,
|
|
||||||
// func: async (input: string) => bingSearchTool.call(input),
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
// if (process.env.SERPAPI_API_KEY) {
|
|
||||||
// let serpAPITool = new langchainTools["SerpAPI"](
|
|
||||||
// process.env.SERPAPI_API_KEY,
|
|
||||||
// );
|
|
||||||
// searchTool = new DynamicTool({
|
|
||||||
// name: "google_search",
|
|
||||||
// description: serpAPITool.description,
|
|
||||||
// func: async (input: string) => serpAPITool.call(input),
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
const webBrowserTool = new WebBrowser({
|
const webBrowserTool = new WebBrowser({
|
||||||
model: this.model,
|
model: this.model,
|
||||||
embeddings: this.embeddings,
|
embeddings: this.embeddings,
|
||||||
@ -79,7 +48,6 @@ export class EdgeTool {
|
|||||||
this.baseUrl,
|
this.baseUrl,
|
||||||
this.callback,
|
this.callback,
|
||||||
);
|
);
|
||||||
dallEAPITool.returnDirect = true;
|
|
||||||
const stableDiffusionTool = new StableDiffusionWrapper();
|
const stableDiffusionTool = new StableDiffusionWrapper();
|
||||||
const arxivAPITool = new ArxivAPIWrapper();
|
const arxivAPITool = new ArxivAPIWrapper();
|
||||||
return [
|
return [
|
||||||
|
Loading…
Reference in New Issue
Block a user