We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 89552ba commit 5f0097bCopy full SHA for 5f0097b
src/models.ts
@@ -47,6 +47,11 @@ export class Models extends BaseModule {
47
params: types.EmbedContentParameters,
48
): Promise<types.EmbedContentResponse> => {
49
if (!this.apiClient.isVertexAI()) {
50
+ const isGeminiEmbedding2Model =
51
+ params.model.includes('gemini-embedding-2');
52
+ if (isGeminiEmbedding2Model) {
53
+ params.contents = tContents(params.contents);
54
+ }
55
return await this.embedContentInternal(params);
56
}
57
const isVertexEmbedContentModel =
0 commit comments