@n8n/ai-utilities 0.14.1 → 0.15.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/ai-node-sdk-version.js.map +1 -1
- package/dist/cjs/index.d.ts +3 -0
- package/dist/cjs/index.js +17 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/typecheck.tsbuildinfo +1 -1
- package/dist/cjs/utils/follow-redirects.d.ts +5 -0
- package/dist/cjs/utils/follow-redirects.js +51 -0
- package/dist/cjs/utils/follow-redirects.js.map +1 -0
- package/dist/cjs/utils/n8n-llm-tracing.d.ts +5 -6
- package/dist/cjs/utils/n8n-llm-tracing.js +38 -2
- package/dist/cjs/utils/n8n-llm-tracing.js.map +1 -1
- package/dist/cjs/utils/text-editor.d.ts +105 -0
- package/dist/cjs/utils/text-editor.js +333 -0
- package/dist/cjs/utils/text-editor.js.map +1 -0
- package/dist/esm/ai-node-sdk-version.js.map +1 -1
- package/dist/esm/index.d.ts +3 -0
- package/dist/esm/index.js +17 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/typecheck.tsbuildinfo +1 -1
- package/dist/esm/utils/follow-redirects.d.ts +5 -0
- package/dist/esm/utils/follow-redirects.js +41 -0
- package/dist/esm/utils/follow-redirects.js.map +1 -0
- package/dist/esm/utils/n8n-llm-tracing.d.ts +5 -6
- package/dist/esm/utils/n8n-llm-tracing.js +38 -2
- package/dist/esm/utils/n8n-llm-tracing.js.map +1 -1
- package/dist/esm/utils/text-editor.d.ts +105 -0
- package/dist/esm/utils/text-editor.js +323 -0
- package/dist/esm/utils/text-editor.js.map +1 -0
- package/package.json +17 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-node-sdk-version.js","sourceRoot":"","sources":["../../src/ai-node-sdk-version.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"ai-node-sdk-version.js","sourceRoot":"","sources":["../../src/ai-node-sdk-version.ts"],"names":[],"mappings":";;;AAIa,QAAA,mBAAmB,GAAW,CAAC,CAAC"}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -7,10 +7,13 @@ export { getMetadataFiltersValues, hasLongSequentialRepeat } from './utils/helpe
|
|
|
7
7
|
export { N8nBinaryLoader } from './utils/n8n-binary-loader';
|
|
8
8
|
export { N8nJsonLoader } from './utils/n8n-json-loader';
|
|
9
9
|
export { N8nLlmTracing } from './utils/n8n-llm-tracing';
|
|
10
|
+
export { TextEditorDocument, NoMatchFoundError, MultipleMatchesError, InvalidLineNumberError, InvalidViewRangeError, InvalidPathError, FileExistsError, FileNotFoundError, BatchReplacementError, formatTextWithLineNumbers, findDivergenceContext, parseStrReplacements, } from './utils/text-editor';
|
|
11
|
+
export type { ViewCommand, CreateCommand, StrReplaceCommand, InsertCommand, BatchStrReplaceCommand, TextEditorCommand, TextEditorCommandWithBatch, TextEditorToolCall, TextEditorResult, StrReplacement, BatchReplaceResult, TextEditorDocumentOptions, } from './utils/text-editor';
|
|
10
12
|
export { estimateTokensFromStringList, estimateTokensByCharCount, estimateTextSplitsByTokens, } from './utils/tokenizer/token-estimator';
|
|
11
13
|
export { encodingForModel, getEncoding } from './utils/tokenizer/tiktoken';
|
|
12
14
|
export { makeN8nLlmFailedAttemptHandler } from './utils/failed-attempt-handler/n8nLlmFailedAttemptHandler';
|
|
13
15
|
export { getProxyAgent, getNodeProxyAgent, proxyFetch, type AgentTimeoutOptions, } from './utils/http-proxy-agent';
|
|
16
|
+
export { fetchFollowingRedirects, type FollowRedirectsOptions, } from './utils/follow-redirects';
|
|
14
17
|
export { getConnectionHintNoticeField, metadataFilterField, getBatchingOptionFields, getTemplateNoticeField, } from './utils/shared-fields';
|
|
15
18
|
export { createToolFromNode, createZodSchemaFromArgs, extractFromAIParameters, } from './utils/fromai-tool-factory';
|
|
16
19
|
export { createVectorStoreNode } from './utils/vector-store/createVectorStoreNode/createVectorStoreNode';
|
package/dist/esm/index.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.isBaseChatMemory = exports.fromLcContent = exports.toLcContent = exports.toLcMessage = exports.fromLcMessage = exports.getParametersJsonSchema = exports.processDocument = exports.processDocuments = exports.MemoryVectorStoreManager = exports.createVectorStoreNode = exports.extractFromAIParameters = exports.createZodSchemaFromArgs = exports.createToolFromNode = exports.getTemplateNoticeField = exports.getBatchingOptionFields = exports.metadataFilterField = exports.getConnectionHintNoticeField = exports.fetchFollowingRedirects = exports.proxyFetch = exports.getNodeProxyAgent = exports.getProxyAgent = exports.makeN8nLlmFailedAttemptHandler = exports.getEncoding = exports.encodingForModel = exports.estimateTextSplitsByTokens = exports.estimateTokensByCharCount = exports.estimateTokensFromStringList = exports.parseStrReplacements = exports.findDivergenceContext = exports.formatTextWithLineNumbers = exports.BatchReplacementError = exports.FileNotFoundError = exports.FileExistsError = exports.InvalidPathError = exports.InvalidViewRangeError = exports.InvalidLineNumberError = exports.MultipleMatchesError = exports.NoMatchFoundError = exports.TextEditorDocument = exports.N8nLlmTracing = exports.N8nJsonLoader = exports.N8nBinaryLoader = exports.hasLongSequentialRepeat = exports.getMetadataFiltersValues = exports.validateEmbedDocumentsInput = exports.validateEmbedQueryInput = exports.parseSSEStream = exports.logAiEvent = exports.logWrapper = exports.AI_NODE_SDK_VERSION = void 0;
|
|
4
|
+
exports.supplyModel = exports.supplyMemory = exports.WindowedChatMemory = exports.BaseChatMemory = exports.BaseChatHistory = exports.BaseChatModel = exports.LangchainChatModelAdapter = exports.isToolsInstance = exports.isChatInstance = exports.isBaseChatMessageHistory = void 0;
|
|
4
5
|
var ai_node_sdk_version_1 = require("./ai-node-sdk-version");
|
|
5
6
|
Object.defineProperty(exports, "AI_NODE_SDK_VERSION", { enumerable: true, get: function () { return ai_node_sdk_version_1.AI_NODE_SDK_VERSION; } });
|
|
6
7
|
var log_wrapper_1 = require("./utils/log-wrapper");
|
|
@@ -21,6 +22,19 @@ var n8n_json_loader_1 = require("./utils/n8n-json-loader");
|
|
|
21
22
|
Object.defineProperty(exports, "N8nJsonLoader", { enumerable: true, get: function () { return n8n_json_loader_1.N8nJsonLoader; } });
|
|
22
23
|
var n8n_llm_tracing_1 = require("./utils/n8n-llm-tracing");
|
|
23
24
|
Object.defineProperty(exports, "N8nLlmTracing", { enumerable: true, get: function () { return n8n_llm_tracing_1.N8nLlmTracing; } });
|
|
25
|
+
var text_editor_1 = require("./utils/text-editor");
|
|
26
|
+
Object.defineProperty(exports, "TextEditorDocument", { enumerable: true, get: function () { return text_editor_1.TextEditorDocument; } });
|
|
27
|
+
Object.defineProperty(exports, "NoMatchFoundError", { enumerable: true, get: function () { return text_editor_1.NoMatchFoundError; } });
|
|
28
|
+
Object.defineProperty(exports, "MultipleMatchesError", { enumerable: true, get: function () { return text_editor_1.MultipleMatchesError; } });
|
|
29
|
+
Object.defineProperty(exports, "InvalidLineNumberError", { enumerable: true, get: function () { return text_editor_1.InvalidLineNumberError; } });
|
|
30
|
+
Object.defineProperty(exports, "InvalidViewRangeError", { enumerable: true, get: function () { return text_editor_1.InvalidViewRangeError; } });
|
|
31
|
+
Object.defineProperty(exports, "InvalidPathError", { enumerable: true, get: function () { return text_editor_1.InvalidPathError; } });
|
|
32
|
+
Object.defineProperty(exports, "FileExistsError", { enumerable: true, get: function () { return text_editor_1.FileExistsError; } });
|
|
33
|
+
Object.defineProperty(exports, "FileNotFoundError", { enumerable: true, get: function () { return text_editor_1.FileNotFoundError; } });
|
|
34
|
+
Object.defineProperty(exports, "BatchReplacementError", { enumerable: true, get: function () { return text_editor_1.BatchReplacementError; } });
|
|
35
|
+
Object.defineProperty(exports, "formatTextWithLineNumbers", { enumerable: true, get: function () { return text_editor_1.formatTextWithLineNumbers; } });
|
|
36
|
+
Object.defineProperty(exports, "findDivergenceContext", { enumerable: true, get: function () { return text_editor_1.findDivergenceContext; } });
|
|
37
|
+
Object.defineProperty(exports, "parseStrReplacements", { enumerable: true, get: function () { return text_editor_1.parseStrReplacements; } });
|
|
24
38
|
var token_estimator_1 = require("./utils/tokenizer/token-estimator");
|
|
25
39
|
Object.defineProperty(exports, "estimateTokensFromStringList", { enumerable: true, get: function () { return token_estimator_1.estimateTokensFromStringList; } });
|
|
26
40
|
Object.defineProperty(exports, "estimateTokensByCharCount", { enumerable: true, get: function () { return token_estimator_1.estimateTokensByCharCount; } });
|
|
@@ -34,6 +48,8 @@ var http_proxy_agent_1 = require("./utils/http-proxy-agent");
|
|
|
34
48
|
Object.defineProperty(exports, "getProxyAgent", { enumerable: true, get: function () { return http_proxy_agent_1.getProxyAgent; } });
|
|
35
49
|
Object.defineProperty(exports, "getNodeProxyAgent", { enumerable: true, get: function () { return http_proxy_agent_1.getNodeProxyAgent; } });
|
|
36
50
|
Object.defineProperty(exports, "proxyFetch", { enumerable: true, get: function () { return http_proxy_agent_1.proxyFetch; } });
|
|
51
|
+
var follow_redirects_1 = require("./utils/follow-redirects");
|
|
52
|
+
Object.defineProperty(exports, "fetchFollowingRedirects", { enumerable: true, get: function () { return follow_redirects_1.fetchFollowingRedirects; } });
|
|
37
53
|
var shared_fields_1 = require("./utils/shared-fields");
|
|
38
54
|
Object.defineProperty(exports, "getConnectionHintNoticeField", { enumerable: true, get: function () { return shared_fields_1.getConnectionHintNoticeField; } });
|
|
39
55
|
Object.defineProperty(exports, "metadataFilterField", { enumerable: true, get: function () { return shared_fields_1.metadataFilterField; } });
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;AACA,6DAA4D;AAAnD,0HAAA,mBAAmB,OAAA;AAG5B,mDAAiD;AAAxC,yGAAA,UAAU,OAAA;AACnB,qDAAkD;AAAzC,0GAAA,UAAU,O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