diff --git a/agent/src/index.ts b/agent/src/index.ts index ee07b21a2a5..b0bde222ca5 100644 --- a/agent/src/index.ts +++ b/agent/src/index.ts @@ -109,6 +109,7 @@ import path from "path"; import { fileURLToPath } from "url"; import yargs from "yargs"; + const __filename = fileURLToPath(import.meta.url); // get the resolved path to the file const __dirname = path.dirname(__filename); // get the name of the directory diff --git a/packages/core/package.json b/packages/core/package.json index 8aa76e07d7c..1598b4a6487 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -40,7 +40,6 @@ "@rollup/plugin-terser": "0.1.0", "@rollup/plugin-typescript": "11.1.6", "@solana/web3.js": "1.95.8", - "@tavily/core": "^0.0.2", "@types/fluent-ffmpeg": "2.1.27", "@types/jest": "29.5.14", "@types/mocha": "10.0.10", diff --git a/packages/core/src/generation.ts b/packages/core/src/generation.ts index d7ebfe73e08..0cd836a5d57 100644 --- a/packages/core/src/generation.ts +++ b/packages/core/src/generation.ts @@ -41,7 +41,6 @@ import { ModelClass, ModelProviderName, ServiceType, - SearchResponse, ActionResponse, IVerifiableInferenceAdapter, VerifiableInferenceOptions, @@ -51,7 +50,7 @@ import { TokenizerType, } from "./types.ts"; import { fal } from "@fal-ai/client"; -import { tavily } from "@tavily/core"; + import BigNumber from "bignumber.js"; import {createPublicClient, http} from "viem"; @@ -1818,28 +1817,6 @@ export const generateCaption = async ( }; }; -export const generateWebSearch = async ( - query: string, - runtime: IAgentRuntime -): Promise => { - try { - const apiKey = runtime.getSetting("TAVILY_API_KEY") as string; - if (!apiKey) { - throw new Error("TAVILY_API_KEY is not set"); - } - const tvly = tavily({ apiKey }); - const response = await tvly.search(query, { - includeAnswer: true, - maxResults: 3, // 5 (default) - topic: "general", // "general"(default) "news" - searchDepth: "basic", // "basic"(default) "advanced" - includeImages: false, // false (default) true - }); - return response; - } catch (error) { - elizaLogger.error("Error:", error); - } -}; /** * Configuration options for generating objects with a model. */ diff --git a/packages/core/src/types.ts b/packages/core/src/types.ts index ff2151e93f7..621ffe81c66 100644 --- a/packages/core/src/types.ts +++ b/packages/core/src/types.ts @@ -1418,28 +1418,6 @@ export interface ITeeLogService extends Service { ): Promise; } -export type SearchImage = { - url: string; - description?: string; -}; - -export type SearchResult = { - title: string; - url: string; - content: string; - rawContent?: string; - score: number; - publishedDate?: string; -}; - -export type SearchResponse = { - answer?: string; - query: string; - responseTime: number; - images: SearchImage[]; - results: SearchResult[]; -}; - export enum ServiceType { IMAGE_DESCRIPTION = "image_description", TRANSCRIPTION = "transcription", @@ -1456,6 +1434,7 @@ export enum ServiceType { IRYS = "irys", TEE_LOG = "tee_log", GOPLUS_SECURITY = "goplus_security", + WEB_SEARCH = "web_search", } export enum LoggingLevel { diff --git a/packages/core/tsup.config.ts b/packages/core/tsup.config.ts index 234178fcd5a..1b939af9a8b 100644 --- a/packages/core/tsup.config.ts +++ b/packages/core/tsup.config.ts @@ -18,7 +18,6 @@ export default defineConfig({ "http", "https", // Add other modules you want to externalize - "@tavily/core", "onnxruntime-node", "sharp", ], diff --git a/packages/plugin-web-search/README.MD b/packages/plugin-web-search/README.MD index 4fbd27dad03..7445498813f 100644 --- a/packages/plugin-web-search/README.MD +++ b/packages/plugin-web-search/README.MD @@ -28,7 +28,7 @@ TAVILY_API_KEY=your_api_key # Required: API key for search service ## Usage -Import and register the plugin in your Eliza configuration: +Import and register the plugin in your Eliza configuration. ```typescript import { webSearchPlugin } from "@elizaos/plugin-web-search"; @@ -39,6 +39,28 @@ export default { }; ``` +**Custom Usage** +If you want custom usage, for example, twitter-client to search the web before posting a tweet, you can also import the webSearchService and use it directly. Here's how you can do it: + +```typescript +// packages/client-twitter/src/post.ts +const webSearchService = new WebSearchService(); +await webSearchService.initialize(runtime); +const latestNews = await webSearchService.search( + "latest news on AI Agents", + // searchOptions +); + +const state = await this.runtime.composeState( + { } // memory, + { // additional keys + latestNews: latestNews, + } +); + +// Then modify the tweet template to include the {{latestNews}} and however you need +``` + ## Features ### Web Search diff --git a/packages/plugin-web-search/package.json b/packages/plugin-web-search/package.json index ce97be8a5fd..0c57546bfa4 100644 --- a/packages/plugin-web-search/package.json +++ b/packages/plugin-web-search/package.json @@ -20,7 +20,9 @@ ], "dependencies": { "@elizaos/core": "workspace:*", - "tsup": "8.3.5" + "@tavily/core": "^0.0.2", + "tsup": "8.3.5", + "js-tiktoken": "1.0.15" }, "scripts": { "build": "tsup --format esm --dts", diff --git a/packages/plugin-web-search/src/actions/webSearch.ts b/packages/plugin-web-search/src/actions/webSearch.ts new file mode 100644 index 00000000000..1cee2215090 --- /dev/null +++ b/packages/plugin-web-search/src/actions/webSearch.ts @@ -0,0 +1,201 @@ +import { + Action, + HandlerCallback, + IAgentRuntime, + Memory, + State, + elizaLogger +} from "@elizaos/core"; +import { encodingForModel, TiktokenModel } from "js-tiktoken"; +import { WebSearchService } from "../services/webSearchService"; +import { SearchResult } from "../types"; + +const DEFAULT_MAX_WEB_SEARCH_TOKENS = 4000; +const DEFAULT_MODEL_ENCODING = "gpt-3.5-turbo"; + +function getTotalTokensFromString( + str: string, + encodingName: TiktokenModel = DEFAULT_MODEL_ENCODING +) { + const encoding = encodingForModel(encodingName); + return encoding.encode(str).length; +} + +function MaxTokens( + data: string, + maxTokens: number = DEFAULT_MAX_WEB_SEARCH_TOKENS +): string { + if (getTotalTokensFromString(data) >= maxTokens) { + return data.slice(0, maxTokens); + } + return data; +} + +export const webSearch: Action = { + name: "WEB_SEARCH", + similes: [ + "SEARCH_WEB", + "INTERNET_SEARCH", + "LOOKUP", + "QUERY_WEB", + "FIND_ONLINE", + "SEARCH_ENGINE", + "WEB_LOOKUP", + "ONLINE_SEARCH", + "FIND_INFORMATION", + ], + suppressInitialMessage: true, + description: + "Perform a web search to find information related to the message.", + validate: async (runtime: IAgentRuntime, message: Memory) => { + const tavilyApiKeyOk = !!runtime.getSetting("TAVILY_API_KEY"); + + return tavilyApiKeyOk; + }, + handler: async ( + runtime: IAgentRuntime, + message: Memory, + state: State, + options: any, + callback: HandlerCallback + ) => { + elizaLogger.log("Composing state for message:", message); + state = (await runtime.composeState(message)) as State; + const userId = runtime.agentId; + elizaLogger.log("User ID:", userId); + + const webSearchPrompt = message.content.text; + elizaLogger.log("web search prompt received:", webSearchPrompt); + + const webSearchService = new WebSearchService(); + await webSearchService.initialize(runtime); + const searchResponse = await webSearchService.search( + webSearchPrompt, + ); + + if (searchResponse && searchResponse.results.length) { + const responseList = searchResponse.answer + ? `${searchResponse.answer}${ + Array.isArray(searchResponse.results) && + searchResponse.results.length > 0 + ? `\n\nFor more details, you can check out these resources:\n${searchResponse.results + .map( + (result: SearchResult, index: number) => + `${index + 1}. [${result.title}](${result.url})` + ) + .join("\n")}` + : "" + }` + : ""; + + callback({ + text: MaxTokens(responseList, DEFAULT_MAX_WEB_SEARCH_TOKENS), + }); + } else { + elizaLogger.error("search failed or returned no data."); + } + }, + examples: [ + [ + { + user: "{{user1}}", + content: { + text: "Find the latest news about SpaceX launches.", + }, + }, + { + user: "{{agentName}}", + content: { + text: "Here is the latest news about SpaceX launches:", + action: "WEB_SEARCH", + }, + }, + ], + [ + { + user: "{{user1}}", + content: { + text: "Can you find details about the iPhone 16 release?", + }, + }, + { + user: "{{agentName}}", + content: { + text: "Here are the details I found about the iPhone 16 release:", + action: "WEB_SEARCH", + }, + }, + ], + [ + { + user: "{{user1}}", + content: { + text: "What is the schedule for the next FIFA World Cup?", + }, + }, + { + user: "{{agentName}}", + content: { + text: "Here is the schedule for the next FIFA World Cup:", + action: "WEB_SEARCH", + }, + }, + ], + [ + { + user: "{{user1}}", + content: { text: "Check the latest stock price of Tesla." }, + }, + { + user: "{{agentName}}", + content: { + text: "Here is the latest stock price of Tesla I found:", + action: "WEB_SEARCH", + }, + }, + ], + [ + { + user: "{{user1}}", + content: { + text: "What are the current trending movies in the US?", + }, + }, + { + user: "{{agentName}}", + content: { + text: "Here are the current trending movies in the US:", + action: "WEB_SEARCH", + }, + }, + ], + [ + { + user: "{{user1}}", + content: { + text: "What is the latest score in the NBA finals?", + }, + }, + { + user: "{{agentName}}", + content: { + text: "Here is the latest score from the NBA finals:", + action: "WEB_SEARCH", + }, + }, + ], + [ + { + user: "{{user1}}", + content: { text: "When is the next Apple keynote event?" }, + }, + { + user: "{{agentName}}", + content: { + text: "Here is the information about the next Apple keynote event:", + action: "WEB_SEARCH", + }, + }, + ], + ], +} as Action; \ No newline at end of file diff --git a/packages/plugin-web-search/src/index.ts b/packages/plugin-web-search/src/index.ts index 528e2609045..7d412611ec6 100644 --- a/packages/plugin-web-search/src/index.ts +++ b/packages/plugin-web-search/src/index.ts @@ -1,211 +1,15 @@ -import { elizaLogger } from "@elizaos/core"; -import { - Action, - HandlerCallback, - IAgentRuntime, - Memory, - Plugin, - State, -} from "@elizaos/core"; -import { generateWebSearch } from "@elizaos/core"; -import { SearchResult } from "@elizaos/core"; -import { encodingForModel, TiktokenModel } from "js-tiktoken"; - -const DEFAULT_MAX_WEB_SEARCH_TOKENS = 4000; -const DEFAULT_MODEL_ENCODING = "gpt-3.5-turbo"; - -function getTotalTokensFromString( - str: string, - encodingName: TiktokenModel = DEFAULT_MODEL_ENCODING -) { - const encoding = encodingForModel(encodingName); - return encoding.encode(str).length; -} - -function MaxTokens( - data: string, - maxTokens: number = DEFAULT_MAX_WEB_SEARCH_TOKENS -): string { - if (getTotalTokensFromString(data) >= maxTokens) { - return data.slice(0, maxTokens); - } - return data; -} - -const webSearch: Action = { - name: "WEB_SEARCH", - similes: [ - "SEARCH_WEB", - "INTERNET_SEARCH", - "LOOKUP", - "QUERY_WEB", - "FIND_ONLINE", - "SEARCH_ENGINE", - "WEB_LOOKUP", - "ONLINE_SEARCH", - "FIND_INFORMATION", - ], - description: - "Perform a web search to find information related to the message.", - validate: async (runtime: IAgentRuntime, message: Memory) => { - const tavilyApiKeyOk = !!runtime.getSetting("TAVILY_API_KEY"); - - return tavilyApiKeyOk; - }, - handler: async ( - runtime: IAgentRuntime, - message: Memory, - state: State, - options: any, - callback: HandlerCallback - ) => { - elizaLogger.log("Composing state for message:", message); - state = (await runtime.composeState(message)) as State; - const userId = runtime.agentId; - elizaLogger.log("User ID:", userId); - - const webSearchPrompt = message.content.text; - elizaLogger.log("web search prompt received:", webSearchPrompt); - - elizaLogger.log("Generating image with prompt:", webSearchPrompt); - const searchResponse = await generateWebSearch( - webSearchPrompt, - runtime - ); - - if (searchResponse && searchResponse.results.length) { - const responseList = searchResponse.answer - ? `${searchResponse.answer}${ - Array.isArray(searchResponse.results) && - searchResponse.results.length > 0 - ? `\n\nFor more details, you can check out these resources:\n${searchResponse.results - .map( - (result: SearchResult, index: number) => - `${index + 1}. [${result.title}](${result.url})` - ) - .join("\n")}` - : "" - }` - : ""; - - callback({ - text: MaxTokens(responseList, DEFAULT_MAX_WEB_SEARCH_TOKENS), - }); - } else { - elizaLogger.error("search failed or returned no data."); - } - }, - examples: [ - [ - { - user: "{{user1}}", - content: { - text: "Find the latest news about SpaceX launches.", - }, - }, - { - user: "{{agentName}}", - content: { - text: "Here is the latest news about SpaceX launches:", - action: "WEB_SEARCH", - }, - }, - ], - [ - { - user: "{{user1}}", - content: { - text: "Can you find details about the iPhone 16 release?", - }, - }, - { - user: "{{agentName}}", - content: { - text: "Here are the details I found about the iPhone 16 release:", - action: "WEB_SEARCH", - }, - }, - ], - [ - { - user: "{{user1}}", - content: { - text: "What is the schedule for the next FIFA World Cup?", - }, - }, - { - user: "{{agentName}}", - content: { - text: "Here is the schedule for the next FIFA World Cup:", - action: "WEB_SEARCH", - }, - }, - ], - [ - { - user: "{{user1}}", - content: { text: "Check the latest stock price of Tesla." }, - }, - { - user: "{{agentName}}", - content: { - text: "Here is the latest stock price of Tesla I found:", - action: "WEB_SEARCH", - }, - }, - ], - [ - { - user: "{{user1}}", - content: { - text: "What are the current trending movies in the US?", - }, - }, - { - user: "{{agentName}}", - content: { - text: "Here are the current trending movies in the US:", - action: "WEB_SEARCH", - }, - }, - ], - [ - { - user: "{{user1}}", - content: { - text: "What is the latest score in the NBA finals?", - }, - }, - { - user: "{{agentName}}", - content: { - text: "Here is the latest score from the NBA finals:", - action: "WEB_SEARCH", - }, - }, - ], - [ - { - user: "{{user1}}", - content: { text: "When is the next Apple keynote event?" }, - }, - { - user: "{{agentName}}", - content: { - text: "Here is the information about the next Apple keynote event:", - action: "WEB_SEARCH", - }, - }, - ], - ], -} as Action; +import { webSearch } from "./actions/webSearch"; +import { Plugin } from "@elizaos/core"; +import { WebSearchService } from "./services/webSearchService"; export const webSearchPlugin: Plugin = { name: "webSearch", - description: "Search web", + description: "Search the web and get news", actions: [webSearch], evaluators: [], providers: [], + services: [new WebSearchService()], + clients: [], }; export default webSearchPlugin; diff --git a/packages/plugin-web-search/src/services/webSearchService.ts b/packages/plugin-web-search/src/services/webSearchService.ts new file mode 100644 index 00000000000..bf55329ba88 --- /dev/null +++ b/packages/plugin-web-search/src/services/webSearchService.ts @@ -0,0 +1,50 @@ +import { + Service, + IAgentRuntime, + ServiceType, +} from "@elizaos/core"; +import { tavily } from "@tavily/core"; +import { IWebSearchService, SearchOptions, SearchResponse } from "../types"; + +export type TavilyClient = ReturnType; // declaring manually because orginal package does not export its types + +export class WebSearchService extends Service implements IWebSearchService { + public tavilyClient: TavilyClient + + async initialize(_runtime: IAgentRuntime): Promise { + const apiKey = _runtime.getSetting("TAVILY_API_KEY") as string; + if (!apiKey) { + throw new Error("TAVILY_API_KEY is not set"); + } + this.tavilyClient = tavily({ apiKey }); + } + + getInstance(): IWebSearchService { + return WebSearchService.getInstance(); + } + + static get serviceType(): ServiceType { + return ServiceType.WEB_SEARCH; + } + + async search( + query: string, + options?: SearchOptions, + ): Promise { + try { + const response = await this.tavilyClient.search(query, { + includeAnswer: options?.includeAnswer || true, + maxResults: options?.limit || 3, + topic: options?.type || "general", + searchDepth: options?.searchDepth || "basic", + includeImages: options?.includeImages || false, + days: options?.days || 3, + }); + + return response; + } catch (error) { + console.error("Web search error:", error); + throw error; + } + } +} diff --git a/packages/plugin-web-search/src/types.ts b/packages/plugin-web-search/src/types.ts new file mode 100644 index 00000000000..e782b9979a3 --- /dev/null +++ b/packages/plugin-web-search/src/types.ts @@ -0,0 +1,40 @@ +import { Service } from "@elizaos/core"; + +export interface IWebSearchService extends Service { + search( + query: string, + options?: SearchOptions, + ): Promise; +} + +export type SearchResult = { + title: string; + url: string; + content: string; + rawContent?: string; + score: number; + publishedDate?: string; +}; + +export type SearchImage = { + url: string; + description?: string; +}; + + +export type SearchResponse = { + answer?: string; + query: string; + responseTime: number; + images: SearchImage[]; + results: SearchResult[]; +}; + +export interface SearchOptions { + limit?: number; + type?: "news" | "general"; + includeAnswer?: boolean; + searchDepth?: "basic" | "advanced"; + includeImages?: boolean; + days?: number; // 1 means current day, 2 means last 2 days +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 176f1ec1dc4..4a1780ff417 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -3086,6 +3086,12 @@ importers: '@elizaos/core': specifier: workspace:* version: link:../core + '@tavily/core': + specifier: ^0.0.2 + version: 0.0.2 + js-tiktoken: + specifier: 1.0.15 + version: 1.0.15 tsup: specifier: 8.3.5 version: 8.3.5(@swc/core@1.10.7(@swc/helpers@0.5.15))(jiti@2.4.2)(postcss@8.5.0)(tsx@4.19.2)(typescript@5.7.3)(yaml@2.7.0) @@ -22928,7 +22934,7 @@ snapshots: '@acuminous/bitsyntax@0.1.2': dependencies: buffer-more-ints: 1.0.0 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 safe-buffer: 5.1.2 transitivePeerDependencies: - supports-color @@ -24181,7 +24187,7 @@ snapshots: '@babel/traverse': 7.26.5 '@babel/types': 7.26.5 convert-source-map: 2.0.0 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 gensync: 1.0.0-beta.2 json5: 2.2.3 semver: 6.3.1 @@ -24961,7 +24967,7 @@ snapshots: '@babel/parser': 7.26.5 '@babel/template': 7.25.9 '@babel/types': 7.26.5 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 globals: 11.12.0 transitivePeerDependencies: - supports-color @@ -25114,7 +25120,7 @@ snapshots: dependencies: '@scure/bip32': 1.6.1 abitype: 1.0.8(typescript@5.6.3)(zod@3.24.1) - axios: 1.7.9(debug@4.4.0) + axios: 1.7.9 axios-mock-adapter: 1.22.0(axios@1.7.9) axios-retry: 4.5.0(axios@1.7.9) bip32: 4.0.0 @@ -27423,7 +27429,7 @@ snapshots: '@eslint/config-array@0.19.1': dependencies: '@eslint/object-schema': 2.1.5 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 minimatch: 3.1.2 transitivePeerDependencies: - supports-color @@ -27453,7 +27459,7 @@ snapshots: '@eslint/eslintrc@3.2.0': dependencies: ajv: 6.12.6 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 espree: 10.3.0 globals: 14.0.0 ignore: 5.3.2 @@ -28492,6 +28498,41 @@ snapshots: - supports-color - ts-node + '@jest/core@29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3))': + dependencies: + '@jest/console': 29.7.0 + '@jest/reporters': 29.7.0 + '@jest/test-result': 29.7.0 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + '@types/node': 20.17.9 + ansi-escapes: 4.3.2 + chalk: 4.1.2 + ci-info: 3.9.0 + exit: 0.1.2 + graceful-fs: 4.2.11 + jest-changed-files: 29.7.0 + jest-config: 29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + jest-haste-map: 29.7.0 + jest-message-util: 29.7.0 + jest-regex-util: 29.6.3 + jest-resolve: 29.7.0 + jest-resolve-dependencies: 29.7.0 + jest-runner: 29.7.0 + jest-runtime: 29.7.0 + jest-snapshot: 29.7.0 + jest-util: 29.7.0 + jest-validate: 29.7.0 + jest-watcher: 29.7.0 + micromatch: 4.0.8 + pretty-format: 29.7.0 + slash: 3.0.0 + strip-ansi: 6.0.1 + transitivePeerDependencies: + - babel-plugin-macros + - supports-color + - ts-node + '@jest/core@29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3))': dependencies: '@jest/console': 29.7.0 @@ -33750,7 +33791,7 @@ snapshots: '@tavily/core@0.0.2': dependencies: - axios: 1.7.9(debug@4.4.0) + axios: 1.7.9 js-tiktoken: 1.0.15 transitivePeerDependencies: - debug @@ -34534,7 +34575,7 @@ snapshots: '@typescript-eslint/types': 8.16.0 '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.6.3) '@typescript-eslint/visitor-keys': 8.16.0 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 eslint: 9.16.0(jiti@2.4.2) optionalDependencies: typescript: 5.6.3 @@ -34597,7 +34638,7 @@ snapshots: dependencies: '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.6.3) '@typescript-eslint/utils': 8.16.0(eslint@9.16.0(jiti@2.4.2))(typescript@5.6.3) - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 eslint: 9.16.0(jiti@2.4.2) ts-api-utils: 1.4.3(typescript@5.6.3) optionalDependencies: @@ -34653,7 +34694,7 @@ snapshots: dependencies: '@typescript-eslint/types': 8.16.0 '@typescript-eslint/visitor-keys': 8.16.0 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 fast-glob: 3.3.3 is-glob: 4.0.3 minimatch: 9.0.5 @@ -35886,7 +35927,7 @@ snapshots: agent-base@6.0.2: dependencies: - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 transitivePeerDependencies: - supports-color @@ -36412,7 +36453,7 @@ snapshots: axios-mock-adapter@1.22.0(axios@1.7.9): dependencies: - axios: 1.7.9(debug@4.4.0) + axios: 1.7.9 fast-deep-equal: 3.1.3 is-buffer: 2.0.5 @@ -36423,7 +36464,7 @@ snapshots: axios-retry@4.5.0(axios@1.7.9): dependencies: - axios: 1.7.9(debug@4.4.0) + axios: 1.7.9 is-retry-allowed: 2.2.0 axios@0.21.4: @@ -36440,7 +36481,7 @@ snapshots: axios@0.27.2: dependencies: - follow-redirects: 1.15.9(debug@4.4.0) + follow-redirects: 1.15.9 form-data: 4.0.1 transitivePeerDependencies: - debug @@ -36477,6 +36518,14 @@ snapshots: transitivePeerDependencies: - debug + axios@1.7.9: + dependencies: + follow-redirects: 1.15.9 + form-data: 4.0.1 + proxy-from-env: 1.1.0 + transitivePeerDependencies: + - debug + axios@1.7.9(debug@4.4.0): dependencies: follow-redirects: 1.15.9(debug@4.4.0) @@ -38005,6 +38054,21 @@ snapshots: - supports-color - ts-node + create-jest@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)): + dependencies: + '@jest/types': 29.6.3 + chalk: 4.1.2 + exit: 0.1.2 + graceful-fs: 4.2.11 + jest-config: 29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + jest-util: 29.7.0 + prompts: 2.4.2 + transitivePeerDependencies: + - '@types/node' + - babel-plugin-macros + - supports-color + - ts-node + create-jest@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3)): dependencies: '@jest/types': 29.6.3 @@ -38599,6 +38663,10 @@ snapshots: dependencies: ms: 2.1.3 + debug@4.4.0: + dependencies: + ms: 2.1.3 + debug@4.4.0(supports-color@5.5.0): dependencies: ms: 2.1.3 @@ -39680,7 +39748,7 @@ snapshots: ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.6 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 escape-string-regexp: 4.0.0 eslint-scope: 8.2.0 eslint-visitor-keys: 4.2.0 @@ -40403,6 +40471,8 @@ snapshots: async: 0.2.10 which: 1.3.1 + follow-redirects@1.15.9: {} + follow-redirects@1.15.9(debug@4.3.7): optionalDependencies: debug: 4.3.7 @@ -41480,7 +41550,7 @@ snapshots: http-proxy-agent@7.0.2: dependencies: agent-base: 7.1.3 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 transitivePeerDependencies: - supports-color @@ -41536,14 +41606,14 @@ snapshots: https-proxy-agent@5.0.1: dependencies: agent-base: 6.0.2 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 transitivePeerDependencies: - supports-color https-proxy-agent@7.0.6: dependencies: agent-base: 7.1.3 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 transitivePeerDependencies: - supports-color @@ -42154,7 +42224,7 @@ snapshots: istanbul-lib-source-maps@4.0.1: dependencies: - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 istanbul-lib-coverage: 3.2.2 source-map: 0.6.1 transitivePeerDependencies: @@ -42290,6 +42360,25 @@ snapshots: - supports-color - ts-node + jest-cli@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)): + dependencies: + '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + '@jest/test-result': 29.7.0 + '@jest/types': 29.6.3 + chalk: 4.1.2 + create-jest: 29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + exit: 0.1.2 + import-local: 3.2.0 + jest-config: 29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + jest-util: 29.7.0 + jest-validate: 29.7.0 + yargs: 17.7.2 + transitivePeerDependencies: + - '@types/node' + - babel-plugin-macros + - supports-color + - ts-node + jest-cli@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3)): dependencies: '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3)) @@ -42409,6 +42498,37 @@ snapshots: - babel-plugin-macros - supports-color + jest-config@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)): + dependencies: + '@babel/core': 7.26.0 + '@jest/test-sequencer': 29.7.0 + '@jest/types': 29.6.3 + babel-jest: 29.7.0(@babel/core@7.26.0) + chalk: 4.1.2 + ci-info: 3.9.0 + deepmerge: 4.3.1 + glob: 7.2.3 + graceful-fs: 4.2.11 + jest-circus: 29.7.0(babel-plugin-macros@3.1.0) + jest-environment-node: 29.7.0 + jest-get-type: 29.6.3 + jest-regex-util: 29.6.3 + jest-resolve: 29.7.0 + jest-runner: 29.7.0 + jest-util: 29.7.0 + jest-validate: 29.7.0 + micromatch: 4.0.8 + parse-json: 5.2.0 + pretty-format: 29.7.0 + slash: 3.0.0 + strip-json-comments: 3.1.1 + optionalDependencies: + '@types/node': 20.17.9 + ts-node: 10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3) + transitivePeerDependencies: + - babel-plugin-macros + - supports-color + jest-config@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3)): dependencies: '@babel/core': 7.26.0 @@ -42765,6 +42885,18 @@ snapshots: - supports-color - ts-node + jest@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)): + dependencies: + '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + '@jest/types': 29.6.3 + import-local: 3.2.0 + jest-cli: 29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3)) + transitivePeerDependencies: + - '@types/node' + - babel-plugin-macros + - supports-color + - ts-node + jest@29.7.0(@types/node@20.17.9)(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3)): dependencies: '@jest/core': 29.7.0(babel-plugin-macros@3.1.0)(ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3)) @@ -45075,7 +45207,7 @@ snapshots: '@yarnpkg/lockfile': 1.1.0 '@yarnpkg/parsers': 3.0.0-rc.46 '@zkochan/js-yaml': 0.0.7 - axios: 1.7.9(debug@4.4.0) + axios: 1.7.9 chalk: 4.1.0 cli-cursor: 3.1.0 cli-spinners: 2.6.1 @@ -48364,7 +48496,7 @@ snapshots: socks-proxy-agent@8.0.5: dependencies: agent-base: 7.1.3 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 socks: 2.8.3 transitivePeerDependencies: - supports-color @@ -49500,6 +49632,27 @@ snapshots: optionalDependencies: '@swc/core': 1.10.7(@swc/helpers@0.5.15) + ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.6.3): + dependencies: + '@cspotcode/source-map-support': 0.8.1 + '@tsconfig/node10': 1.0.11 + '@tsconfig/node12': 1.0.11 + '@tsconfig/node14': 1.0.3 + '@tsconfig/node16': 1.0.4 + '@types/node': 20.17.9 + acorn: 8.14.0 + acorn-walk: 8.3.4 + arg: 4.1.3 + create-require: 1.1.1 + diff: 4.0.2 + make-error: 1.3.6 + typescript: 5.6.3 + v8-compile-cache-lib: 3.0.1 + yn: 3.1.1 + optionalDependencies: + '@swc/core': 1.10.7(@swc/helpers@0.5.15) + optional: true + ts-node@10.9.2(@swc/core@1.10.7(@swc/helpers@0.5.15))(@types/node@20.17.9)(typescript@5.7.3): dependencies: '@cspotcode/source-map-support': 0.8.1 @@ -49680,7 +49833,7 @@ snapshots: tuf-js@2.2.1: dependencies: '@tufjs/models': 2.0.1 - debug: 4.4.0(supports-color@5.5.0) + debug: 4.4.0 make-fetch-happen: 13.0.1 transitivePeerDependencies: - supports-color