mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-28 19:00:59 +03:00
add custom tool
This commit is contained in:
@@ -18,6 +18,7 @@ export const notEmptyRegex = '(.|\\s)*\\S(.|\\s)*' //return true if string is no
|
||||
*/
|
||||
export const getBaseClasses = (targetClass: any) => {
|
||||
const baseClasses: string[] = []
|
||||
const skipClassNames = ['BaseLangChain', 'Serializable']
|
||||
|
||||
if (targetClass instanceof Function) {
|
||||
let baseClass = targetClass
|
||||
@@ -26,7 +27,7 @@ export const getBaseClasses = (targetClass: any) => {
|
||||
const newBaseClass = Object.getPrototypeOf(baseClass)
|
||||
if (newBaseClass && newBaseClass !== Object && newBaseClass.name) {
|
||||
baseClass = newBaseClass
|
||||
baseClasses.push(baseClass.name)
|
||||
if (!skipClassNames.includes(baseClass.name)) baseClasses.push(baseClass.name)
|
||||
} else {
|
||||
break
|
||||
}
|
||||
@@ -284,3 +285,31 @@ const handleEscapeDoubleQuote = (value: string): string => {
|
||||
}
|
||||
return newValue === '' ? value : newValue
|
||||
}
|
||||
|
||||
export const availableDependencies = [
|
||||
'@dqbd/tiktoken',
|
||||
'@getzep/zep-js',
|
||||
'@huggingface/inference',
|
||||
'@pinecone-database/pinecone',
|
||||
'@supabase/supabase-js',
|
||||
'axios',
|
||||
'cheerio',
|
||||
'chromadb',
|
||||
'cohere-ai',
|
||||
'd3-dsv',
|
||||
'form-data',
|
||||
'graphql',
|
||||
'html-to-text',
|
||||
'langchain',
|
||||
'linkifyjs',
|
||||
'mammoth',
|
||||
'moment',
|
||||
'node-fetch',
|
||||
'pdf-parse',
|
||||
'pdfjs-dist',
|
||||
'playwright',
|
||||
'puppeteer',
|
||||
'srt-parser-2',
|
||||
'typeorm',
|
||||
'weaviate-ts-client'
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user