mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-28 19:00:59 +03:00
lint-fix
This commit is contained in:
+5
-8
@@ -1,6 +1,6 @@
|
||||
import { GoogleVertexAIEmbeddings, GoogleVertexAIEmbeddingsParams} from "langchain/embeddings/googlevertexai";
|
||||
import { GoogleVertexAIEmbeddings, GoogleVertexAIEmbeddingsParams } from 'langchain/embeddings/googlevertexai'
|
||||
import { ICommonObject, INode, INodeData, INodeParams } from '../../../src/Interface'
|
||||
import { getBaseClasses} from '../../../src/utils'
|
||||
import { getBaseClasses } from '../../../src/utils'
|
||||
|
||||
class GoogleVertexAIEmbedding_Embeddings implements INode {
|
||||
label: string
|
||||
@@ -14,7 +14,6 @@ class GoogleVertexAIEmbedding_Embeddings implements INode {
|
||||
credential: INodeParams
|
||||
inputs: INodeParams[]
|
||||
|
||||
|
||||
constructor() {
|
||||
this.label = 'GoogleVertexAI Embeddings'
|
||||
this.name = 'googlevertexaiEmbeddings'
|
||||
@@ -35,22 +34,20 @@ class GoogleVertexAIEmbedding_Embeddings implements INode {
|
||||
name: 'textembedding-gecko'
|
||||
}
|
||||
],
|
||||
default: 'textembedding-gecko',
|
||||
default: 'textembedding-gecko'
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
|
||||
async init(nodeData: INodeData, _: string, options: ICommonObject): Promise<any> {
|
||||
|
||||
const model = nodeData.inputs?.modelName as string
|
||||
const obj: GoogleVertexAIEmbeddingsParams = {
|
||||
model
|
||||
}
|
||||
|
||||
const embedding = new GoogleVertexAIEmbeddings(obj);
|
||||
const embedding = new GoogleVertexAIEmbeddings(obj)
|
||||
return embedding
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = { nodeClass: GoogleVertexAIEmbedding_Embeddings }
|
||||
module.exports = { nodeClass: GoogleVertexAIEmbedding_Embeddings }
|
||||
|
||||
Reference in New Issue
Block a user