mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
refactor: Update Langchain to 0.1.41 & add support for Claude 3 (#8825)
Signed-off-by: Oleg Ivaniv <me@olegivaniv.com> Co-authored-by: Michael Kret <michael.k@radency.com>
This commit is contained in:
@@ -6,7 +6,7 @@ import {
|
||||
type INodeTypeDescription,
|
||||
type SupplyData,
|
||||
} from 'n8n-workflow';
|
||||
import { BedrockEmbeddings } from 'langchain/embeddings/bedrock';
|
||||
import { BedrockEmbeddings } from '@langchain/community/embeddings/bedrock';
|
||||
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
type SupplyData,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import { OpenAIEmbeddings } from 'langchain/embeddings/openai';
|
||||
import { OpenAIEmbeddings } from '@langchain/openai';
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import {
|
||||
type INodeTypeDescription,
|
||||
type SupplyData,
|
||||
} from 'n8n-workflow';
|
||||
import { CohereEmbeddings } from 'langchain/embeddings/cohere';
|
||||
import { CohereEmbeddings } from '@langchain/cohere';
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
|
||||
@@ -89,7 +89,7 @@ export class EmbeddingsCohere implements INodeType {
|
||||
const credentials = await this.getCredentials('cohereApi');
|
||||
const embeddings = new CohereEmbeddings({
|
||||
apiKey: credentials.apiKey as string,
|
||||
modelName,
|
||||
model: modelName,
|
||||
});
|
||||
|
||||
return {
|
||||
|
||||
@@ -6,7 +6,7 @@ import {
|
||||
type INodeTypeDescription,
|
||||
type SupplyData,
|
||||
} from 'n8n-workflow';
|
||||
import { GooglePaLMEmbeddings } from 'langchain/embeddings/googlepalm';
|
||||
import { GooglePaLMEmbeddings } from '@langchain/community/embeddings/googlepalm';
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import {
|
||||
type INodeTypeDescription,
|
||||
type SupplyData,
|
||||
} from 'n8n-workflow';
|
||||
import { HuggingFaceInferenceEmbeddings } from 'langchain/embeddings/hf';
|
||||
import { HuggingFaceInferenceEmbeddings } from '@langchain/community/embeddings/hf';
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import {
|
||||
type INodeTypeDescription,
|
||||
type SupplyData,
|
||||
} from 'n8n-workflow';
|
||||
import { OllamaEmbeddings } from 'langchain/embeddings/ollama';
|
||||
import { OllamaEmbeddings } from '@langchain/community/embeddings/ollama';
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
import { ollamaDescription, ollamaModel } from '../../llms/LMOllama/description';
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import type { ClientOptions } from 'openai';
|
||||
import { OpenAIEmbeddings } from 'langchain/embeddings/openai';
|
||||
import { OpenAIEmbeddings } from '@langchain/openai';
|
||||
import { logWrapper } from '../../../utils/logWrapper';
|
||||
import { getConnectionHintNoticeField } from '../../../utils/sharedFields';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user