From 043a9bd2afb68ef8ace721515e69b12a2307b9c8 Mon Sep 17 00:00:00 2001 From: Hoang Vo Date: Fri, 29 Nov 2024 15:39:25 +0700 Subject: [PATCH 1/5] refactor: use json schema instead of openapi schema --- README.md | 2 +- javascript/eslint.config.js | 2 +- javascript/openapi-ts.config.ts | 12 - javascript/package.json | 2 +- javascript/src/anthropic/anthropic.ts | 2 +- javascript/src/cohere/cohere.ts | 2 +- javascript/src/google/google.ts | 2 +- javascript/src/index.ts | 4 +- javascript/src/mistral/mistral.ts | 2 +- javascript/src/models/language-model.ts | 2 +- javascript/src/openai/openai.ts | 2 +- javascript/src/schema/index.ts | 1 + .../types.gen.ts => schema/schema.ts} | 560 +-- javascript/src/schemas/index.ts | 3 - javascript/src/schemas/schemas.gen.ts | 642 --- javascript/src/utils/audio.utils.ts | 2 +- javascript/src/utils/message.utils.ts | 2 +- javascript/src/utils/stream.utils.ts | 9 +- javascript/src/utils/usage.utils.ts | 2 +- package-lock.json | 3454 ++--------------- package.json | 6 +- .../json-schema-to-typescript+15.0.3.patch | 26 + schema/schema.json | 638 +++ schemas/openapi.json | 605 --- 24 files changed, 1401 insertions(+), 4583 deletions(-) delete mode 100644 javascript/openapi-ts.config.ts create mode 100644 javascript/src/schema/index.ts rename javascript/src/{schemas/types.gen.ts => schema/schema.ts} (58%) delete mode 100644 javascript/src/schemas/index.ts delete mode 100644 javascript/src/schemas/schemas.gen.ts create mode 100644 patches/json-schema-to-typescript+15.0.3.patch create mode 100644 schema/schema.json delete mode 100644 schemas/openapi.json diff --git a/README.md b/README.md index d542577..454e063 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ A unified LLM API. ## Specification -The specification serves as the basis to implement the unified LLM SDK in different programming languages. The specification is expressed using JSON schema and can be found in [openapi.json](../schemas/openapi.json). +The specification serves as the basis to implement the unified LLM SDK in different programming languages. The specification is expressed using JSON schema and can be found in [schema.json](../schema/schema.json). Implementations in different programming languages should adhere to this specification but may adapt it to the idioms of the respective language or provide additional functionalities. diff --git a/javascript/eslint.config.js b/javascript/eslint.config.js index 0046447..20dc538 100644 --- a/javascript/eslint.config.js +++ b/javascript/eslint.config.js @@ -14,7 +14,7 @@ export default [ globals: { ...globals.browser, ...globals.node }, parserOptions: { projectService: { - allowDefaultProject: ["*.js", "*.mjs", "openapi-ts.config.ts"], + allowDefaultProject: ["*.js", "*.mjs"], }, tsconfigRootDir: import.meta.dirname, }, diff --git a/javascript/openapi-ts.config.ts b/javascript/openapi-ts.config.ts deleted file mode 100644 index 139550c..0000000 --- a/javascript/openapi-ts.config.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { defineConfig } from "@hey-api/openapi-ts"; - -export default defineConfig({ - client: "@hey-api/client-fetch", - input: "../schemas/openapi.json", - output: "./src/schemas/", - exportCore: false, - plugins: [ - "@hey-api/schemas", // preserves default output - "@hey-api/types", // preserves default output - ], -}); diff --git a/javascript/package.json b/javascript/package.json index cdd423a..2a4b503 100644 --- a/javascript/package.json +++ b/javascript/package.json @@ -4,7 +4,7 @@ "version": "0.1.6", "description": "A unified LLM SDK", "scripts": { - "generate": "npx @hey-api/openapi-ts", + "generate": "json2ts --bannerComment=false --unreachableDefinitions=true -i ../schema/schema.json -o src/schema/schema.ts", "build": "tshy", "lint": "eslint src", "test": "tsx --test --experimental-test-coverage --env-file=../.env \"**/*.test.ts\"" diff --git a/javascript/src/anthropic/anthropic.ts b/javascript/src/anthropic/anthropic.ts index 1edcdbe..e77ff7f 100644 --- a/javascript/src/anthropic/anthropic.ts +++ b/javascript/src/anthropic/anthropic.ts @@ -14,7 +14,7 @@ import type { TextPart, Tool, ToolCallPart, -} from "../schemas/index.js"; +} from "../schema/index.js"; import { convertAudioPartsToTextParts } from "../utils/message.utils.js"; import { ContentDeltaAccumulator } from "../utils/stream.utils.js"; import { calculateCost } from "../utils/usage.utils.js"; diff --git a/javascript/src/cohere/cohere.ts b/javascript/src/cohere/cohere.ts index ad427ed..5618adb 100644 --- a/javascript/src/cohere/cohere.ts +++ b/javascript/src/cohere/cohere.ts @@ -13,7 +13,7 @@ import { PartialModelResponse, Tool, ToolCallPart, -} from "../schemas/types.gen.js"; +} from "../schema/index.js"; import { convertAudioPartsToTextParts } from "../utils/message.utils.js"; import { ContentDeltaAccumulator } from "../utils/stream.utils.js"; import { calculateCost } from "../utils/usage.utils.js"; diff --git a/javascript/src/google/google.ts b/javascript/src/google/google.ts index e5991bf..a69249b 100644 --- a/javascript/src/google/google.ts +++ b/javascript/src/google/google.ts @@ -29,7 +29,7 @@ import type { PartialModelResponse, Tool, ToolResultPart, -} from "../schemas/index.js"; +} from "../schema/index.js"; import { mapAudioFormatToMimeType } from "../utils/audio.utils.js"; import { convertAudioPartsToTextParts } from "../utils/message.utils.js"; import type { InternalContentDelta } from "../utils/stream.utils.js"; diff --git a/javascript/src/index.ts b/javascript/src/index.ts index 0651ac0..0769e6a 100644 --- a/javascript/src/index.ts +++ b/javascript/src/index.ts @@ -1,4 +1,2 @@ -import * as schemas from "./schemas/schemas.gen.js"; export * from "./models/language-model.js"; -export * from "./schemas/types.gen.js"; -export { schemas }; +export * from "./schema/schema.ts"; diff --git a/javascript/src/mistral/mistral.ts b/javascript/src/mistral/mistral.ts index e75d658..0fcefd6 100644 --- a/javascript/src/mistral/mistral.ts +++ b/javascript/src/mistral/mistral.ts @@ -13,7 +13,7 @@ import { PartialModelResponse, Tool, ToolCallPart, -} from "../schemas/types.gen.js"; +} from "../schema/index.js"; import { convertAudioPartsToTextParts } from "../utils/message.utils.js"; import { ContentDeltaAccumulator, diff --git a/javascript/src/models/language-model.ts b/javascript/src/models/language-model.ts index 409e5c1..a4ec6f4 100644 --- a/javascript/src/models/language-model.ts +++ b/javascript/src/models/language-model.ts @@ -2,7 +2,7 @@ import type { LanguageModelInput, ModelResponse, PartialModelResponse, -} from "../schemas/index.js"; +} from "../schema/index.js"; export type LanguageModelCapability = | "streaming" diff --git a/javascript/src/openai/openai.ts b/javascript/src/openai/openai.ts index 8e561a7..44c3dce 100644 --- a/javascript/src/openai/openai.ts +++ b/javascript/src/openai/openai.ts @@ -17,7 +17,7 @@ import type { TextPartDelta, Tool, ToolCallPartDelta, -} from "../schemas/index.js"; +} from "../schema/index.js"; import { convertAudioPartsToTextParts } from "../utils/message.utils.js"; import type { InternalContentDelta } from "../utils/stream.utils.js"; import { diff --git a/javascript/src/schema/index.ts b/javascript/src/schema/index.ts new file mode 100644 index 0000000..20cdc26 --- /dev/null +++ b/javascript/src/schema/index.ts @@ -0,0 +1 @@ +export * from "./schema.js"; diff --git a/javascript/src/schemas/types.gen.ts b/javascript/src/schema/schema.ts similarity index 58% rename from javascript/src/schemas/types.gen.ts rename to javascript/src/schema/schema.ts index 60e8ca0..83db0ea 100644 --- a/javascript/src/schemas/types.gen.ts +++ b/javascript/src/schema/schema.ts @@ -1,20 +1,8 @@ -// This file is auto-generated by @hey-api/openapi-ts - -/** - * Represents a message generated by the model. - */ -export type AssistantMessage = { - role: "assistant"; - content: Array; -}; - -/** - * The container format of the audio. - */ -export type AudioContainer = "wav" | "ogg" | "flac" | "webm"; - /** * The encoding of the audio. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "AudioEncoding". */ export type AudioEncoding = | "linear16" @@ -24,39 +12,85 @@ export type AudioEncoding = | "aac" | "mp3" | "opus"; +/** + * The container format of the audio. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "AudioContainer". + */ +export type AudioContainer = "wav" | "ogg" | "flac" | "webm"; +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "Part". + */ +export type Part = + | TextPart + | ImagePart + | AudioPart + | ToolCallPart + | ToolResultPart; +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "Message". + */ +export type Message = UserMessage | AssistantMessage | ToolMessage; +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "Modality". + */ +export type Modality = "text" | "audio"; +export interface LlmSdk { + [k: string]: unknown; +} /** - * A part of the message that contains an audio. + * A part of the message that contains text. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "TextPart". */ -export type AudioPart = { - type: "audio"; - container?: AudioContainer; +export interface TextPart { + type: "text"; + text: string; +} +/** + * A part of the message that contains an image. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ImagePart". + */ +export interface ImagePart { + type: "image"; /** - * The base64-encoded audio data. + * The MIME type of the image. E.g. "image/jpeg", "image/png". */ - audioData: string; - encoding?: AudioEncoding; + mimeType: string; /** - * The sample rate of the audio. E.g. 44100, 48000. + * The base64-encoded image data. */ - sampleRate?: number; + imageData: string; /** - * The number of channels of the audio. E.g. 1, 2. + * The width of the image in pixels. */ - channels?: number; + width?: number; /** - * The transcript of the audio. + * The height of the image in pixels. */ - transcript?: string; -}; - -export type AudioPartDelta = { + height?: number; +} +/** + * A part of the message that contains an audio. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "AudioPart". + */ +export interface AudioPart { type: "audio"; + container?: AudioContainer; /** * The base64-encoded audio data. */ - audioData?: string; - container?: AudioContainer; + audioData: string; encoding?: AudioEncoding; /** * The sample rate of the audio. E.g. 44100, 48000. @@ -70,299 +104,339 @@ export type AudioPartDelta = { * The transcript of the audio. */ transcript?: string; -}; - -export type ContentDelta = { - index: number; - part: TextPartDelta | ToolCallPartDelta | AudioPartDelta; -}; - +} /** - * A part of the message that contains an image. + * A part of the message that represents a call to a tool the model wants to use. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolCallPart". */ -export type ImagePart = { - type: "image"; - /** - * The MIME type of the image. E.g. "image/jpeg", "image/png". - */ - mimeType: string; +export interface ToolCallPart { + type: "tool-call"; /** - * The base64-encoded image data. + * The ID of the tool call, used to match the tool result with the tool call. */ - imageData: string; + toolCallId: string; /** - * The width of the image in pixels. + * The name of the tool to call. */ - width?: number; + toolName: string; /** - * The height of the image in pixels. + * The arguments to pass to the tool. */ - height?: number; -}; - -export type LanguageModelInput = { + args: { + [k: string]: unknown; + } | null; +} +/** + * A part of the message that represents the result of a tool call. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolResultPart". + */ +export interface ToolResultPart { + type: "tool-result"; /** - * A system prompt is a way of providing context and instructions to the model + * The ID of the tool call from previous assistant message. */ - systemPrompt?: string; + toolCallId: string; /** - * A list of messages comprising the conversation so far. + * The name of the tool that was called. */ - messages: Array; + toolName: string; /** - * Definitions of tools that the model may use. + * The result of the tool call. */ - tools?: Array; + result: + | { + [k: string]: unknown; + } + | unknown[]; /** - * Determines how the model should choose which tool to use. "auto" - The model will automatically choose the tool to use or not use any tools. "none" - The model will not use any tools. "required" - The model will be forced to use a tool. { type: "tool", toolName: "toolName" } - The model will use the specified tool. + * Marks the tool result as an error. */ - toolChoice?: - | ToolChoiceAuto - | ToolChoiceNone - | ToolChoiceRequired - | ToolChoiceTool; + isError?: boolean; +} +/** + * Represents a message sent by the user. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "UserMessage". + */ +export interface UserMessage { + role: "user"; + content: (TextPart | ImagePart | AudioPart)[]; +} +/** + * Represents a message generated by the model. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "AssistantMessage". + */ +export interface AssistantMessage { + role: "assistant"; + content: (TextPart | ToolCallPart | AudioPart)[]; +} +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "TextPartDelta". + */ +export interface TextPartDelta { + type: "text"; + text: string; +} +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolCallPartDelta". + */ +export interface ToolCallPartDelta { + type: "tool-call"; /** - * The format that the model must output + * The ID of the tool call, used to match the tool result with the tool call. */ - responseFormat?: ResponseFormatJson | ResponseFormatText; + toolCallId?: string; /** - * The maximum number of tokens that can be generated in the chat completion. + * The name of the tool to call. */ - maxTokens?: number; + toolName?: string; /** - * Amount of randomness injected into the response. Ranges from 0.0 to 1.0 + * The partial JSON string of the arguments to pass to the tool. */ - temperature?: number; + args?: string; +} +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "AudioPartDelta". + */ +export interface AudioPartDelta { + type: "audio"; /** - * An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0 + * The base64-encoded audio data. */ - topP?: number; + audioData?: string; + container?: AudioContainer; + encoding?: AudioEncoding; /** - * Only sample from the top K options for each subsequent token. Used to remove "long tail" low probability responses. Ranges from 0.0 to 1.0 + * The sample rate of the audio. E.g. 44100, 48000. */ - topK?: number; + sampleRate?: number; /** - * Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics. + * The number of channels of the audio. E.g. 1, 2. */ - presencePenalty?: number; + channels?: number; /** - * Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim. + * The transcript of the audio. */ - frequencyPenalty?: number; + transcript?: string; +} +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ContentDelta". + */ +export interface ContentDelta { + index: number; + part: TextPartDelta | ToolCallPartDelta | AudioPartDelta; +} +/** + * Represents a JSON schema. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "JSONSchema". + */ +export interface JSONSchema { + [k: string]: unknown; +} +/** + * Represents a tool that can be used by the model. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "Tool". + */ +export interface Tool { /** - * The seed (integer), if set and supported by the model, to enable deterministic results. + * The name of the tool. */ - seed?: number; + name: string; /** - * The modalities that the model should support. + * A description of the tool. */ - modalities?: Array; + description: string; /** - * Extra options that the model may support. + * The JSON schema of the parameters that the tool accepts. The type must be "object". */ - extra?: { - [key: string]: unknown; - }; -}; - -export type Message = UserMessage | AssistantMessage | ToolMessage; - -export type Modality = "text" | "audio"; - + parameters: JSONSchema | null; +} /** - * Represents the response generated by the model. + * Represents tool result in the message history. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolMessage". */ -export type ModelResponse = { - content: Array; - usage?: ModelUsage; - /** - * The cost of the response. - */ - cost?: number; -}; - +export interface ToolMessage { + role: "tool"; + content: ToolResultPart[]; +} /** * Represents the token usage of the model. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ModelTokensDetail". */ -export type ModelTokensDetail = { +export interface ModelTokensDetail { textTokens?: number; audioTokens?: number; imageTokens?: number; -}; - +} /** * Represents the token usage of the model. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ModelUsage". */ -export type ModelUsage = { +export interface ModelUsage { inputTokens: number; outputTokens: number; inputTokensDetail?: ModelTokensDetail; outputTokensDetail?: ModelTokensDetail; -}; - -export type Part = - | TextPart - | ImagePart - | AudioPart - | ToolCallPart - | ToolResultPart; - -export type PartialModelResponse = { - delta: ContentDelta; -}; - -export type ResponseFormatJson = { - type: "json"; - /** - * The JSON schema of the response that the model must output. Not all models support this option. - */ - schema?: { - [key: string]: unknown; - }; -}; - -export type ResponseFormatText = { - type: "text"; -}; - -/** - * A part of the message that contains text. - */ -export type TextPart = { - type: "text"; - text: string; -}; - -export type TextPartDelta = { - type: "text"; - text: string; -}; - +} /** - * Represents a tool that can be used by the model. + * Represents the response generated by the model. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ModelResponse". */ -export type Tool = { - /** - * The name of the tool. - */ - name: string; - /** - * A description of the tool. - */ - description: string; +export interface ModelResponse { + content: (TextPart | ToolCallPart | AudioPart)[]; + usage?: ModelUsage; /** - * The JSON schema of the parameters that the tool accepts. The type must be "object". + * The cost of the response. */ - parameters: { - [key: string]: unknown; - } | null; -}; - + cost?: number; +} /** - * A part of the message that represents a call to a tool the model wants to use. + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "PartialModelResponse". */ -export type ToolCallPart = { - type: "tool-call"; - /** - * The ID of the tool call, used to match the tool result with the tool call. - */ - toolCallId: string; - /** - * The name of the tool to call. - */ - toolName: string; - /** - * The arguments to pass to the tool. - */ - args: { - [key: string]: unknown; - } | null; -}; - -export type ToolCallPartDelta = { - type: "tool-call"; - /** - * The ID of the tool call, used to match the tool result with the tool call. - */ - toolCallId?: string; - /** - * The name of the tool to call. - */ - toolName?: string; - /** - * The partial JSON string of the arguments to pass to the tool. - */ - args?: string; -}; - +export interface PartialModelResponse { + delta: ContentDelta; +} /** * The model will automatically choose the tool to use or not use any tools. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolChoiceAuto". */ -export type ToolChoiceAuto = { +export interface ToolChoiceAuto { type: "auto"; -}; - +} /** * The model will not use any tools. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolChoiceNone". */ -export type ToolChoiceNone = { +export interface ToolChoiceNone { type: "none"; -}; - +} /** * The model will be forced to use a tool. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolChoiceRequired". */ -export type ToolChoiceRequired = { +export interface ToolChoiceRequired { type: "required"; -}; - +} /** * The model will use the specified tool. + * + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ToolChoiceTool". */ -export type ToolChoiceTool = { +export interface ToolChoiceTool { type: "tool"; toolName: string; -}; - +} /** - * Represents tool result in the message history. + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ResponseFormatText". */ -export type ToolMessage = { - role: "tool"; - content: Array; -}; - +export interface ResponseFormatText { + type: "text"; +} /** - * A part of the message that represents the result of a tool call. + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "ResponseFormatJson". */ -export type ToolResultPart = { - type: "tool-result"; +export interface ResponseFormatJson { + type: "json"; + schema?: JSONSchema; +} +/** + * This interface was referenced by `LlmSdk`'s JSON-Schema + * via the `definition` "LanguageModelInput". + */ +export interface LanguageModelInput { /** - * The ID of the tool call from previous assistant message. + * A system prompt is a way of providing context and instructions to the model */ - toolCallId: string; + systemPrompt?: string; /** - * The name of the tool that was called. + * A list of messages comprising the conversation so far. */ - toolName: string; + messages: Message[]; /** - * The result of the tool call. + * Definitions of tools that the model may use. */ - result: - | { - [key: string]: unknown; - } - | unknown[]; + tools?: Tool[]; /** - * Marks the tool result as an error. + * Determines how the model should choose which tool to use. "auto" - The model will automatically choose the tool to use or not use any tools. "none" - The model will not use any tools. "required" - The model will be forced to use a tool. { type: "tool", toolName: "toolName" } - The model will use the specified tool. */ - isError?: boolean; -}; - -/** - * Represents a message sent by the user. - */ -export type UserMessage = { - role: "user"; - content: Array; -}; + toolChoice?: + | ToolChoiceAuto + | ToolChoiceNone + | ToolChoiceRequired + | ToolChoiceTool; + /** + * The format that the model must output + */ + responseFormat?: ResponseFormatJson | ResponseFormatText; + /** + * The maximum number of tokens that can be generated in the chat completion. + */ + maxTokens?: number; + /** + * Amount of randomness injected into the response. Ranges from 0.0 to 1.0 + */ + temperature?: number; + /** + * An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0 + */ + topP?: number; + /** + * Only sample from the top K options for each subsequent token. Used to remove "long tail" low probability responses. Ranges from 0.0 to 1.0 + */ + topK?: number; + /** + * Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics. + */ + presencePenalty?: number; + /** + * Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim. + */ + frequencyPenalty?: number; + /** + * The seed (integer), if set and supported by the model, to enable deterministic results. + */ + seed?: number; + /** + * The modalities that the model should support. + */ + modalities?: Modality[]; + /** + * Extra options that the model may support. + */ + extra?: { + [k: string]: unknown; + }; +} diff --git a/javascript/src/schemas/index.ts b/javascript/src/schemas/index.ts deleted file mode 100644 index 013818c..0000000 --- a/javascript/src/schemas/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -// This file is auto-generated by @hey-api/openapi-ts -export * from "./schemas.gen.js"; -export * from "./types.gen.js"; diff --git a/javascript/src/schemas/schemas.gen.ts b/javascript/src/schemas/schemas.gen.ts deleted file mode 100644 index 04bae66..0000000 --- a/javascript/src/schemas/schemas.gen.ts +++ /dev/null @@ -1,642 +0,0 @@ -// This file is auto-generated by @hey-api/openapi-ts - -export const TextPartSchema = { - type: "object", - description: "A part of the message that contains text.", - properties: { - type: { - type: "string", - const: "text", - }, - text: { - type: "string", - }, - }, - required: ["type", "text"], -} as const; - -export const ImagePartSchema = { - type: "object", - description: "A part of the message that contains an image.", - properties: { - type: { - type: "string", - const: "image", - }, - mimeType: { - type: "string", - description: - 'The MIME type of the image. E.g. "image/jpeg", "image/png".', - }, - imageData: { - type: "string", - description: "The base64-encoded image data.", - }, - width: { - type: "integer", - description: "The width of the image in pixels.", - }, - height: { - type: "integer", - description: "The height of the image in pixels.", - }, - }, - required: ["type", "mimeType", "imageData"], -} as const; - -export const AudioEncodingSchema = { - type: "string", - enum: ["linear16", "flac", "mulaw", "alaw", "aac", "mp3", "opus"], - description: "The encoding of the audio.", -} as const; - -export const AudioContainerSchema = { - type: "string", - enum: ["wav", "ogg", "flac", "webm"], - description: "The container format of the audio.", -} as const; - -export const AudioPartSchema = { - type: "object", - description: "A part of the message that contains an audio.", - properties: { - type: { - type: "string", - const: "audio", - }, - container: { - $ref: "#/components/schemas/AudioContainer", - }, - audioData: { - type: "string", - description: "The base64-encoded audio data.", - }, - encoding: { - $ref: "#/components/schemas/AudioEncoding", - }, - sampleRate: { - type: "integer", - description: "The sample rate of the audio. E.g. 44100, 48000.", - }, - channels: { - type: "integer", - description: "The number of channels of the audio. E.g. 1, 2.", - }, - transcript: { - type: "string", - description: "The transcript of the audio.", - }, - }, - required: ["type", "audioData"], -} as const; - -export const ToolCallPartSchema = { - type: "object", - description: - "A part of the message that represents a call to a tool the model wants to use.", - properties: { - type: { - type: "string", - const: "tool-call", - }, - toolCallId: { - type: "string", - description: - "The ID of the tool call, used to match the tool result with the tool call.", - }, - toolName: { - type: "string", - description: "The name of the tool to call.", - }, - args: { - type: "object", - additionalProperties: true, - description: "The arguments to pass to the tool.", - nullable: true, - }, - }, - required: ["type", "toolCallId", "toolName", "args"], -} as const; - -export const ToolResultPartSchema = { - type: "object", - description: - "A part of the message that represents the result of a tool call.", - properties: { - type: { - type: "string", - const: "tool-result", - }, - toolCallId: { - type: "string", - description: "The ID of the tool call from previous assistant message.", - }, - toolName: { - type: "string", - description: "The name of the tool that was called.", - }, - result: { - anyOf: [ - { - type: "object", - }, - { - type: "array", - }, - ], - description: "The result of the tool call.", - }, - isError: { - type: "boolean", - description: "Marks the tool result as an error.", - }, - }, - required: ["type", "toolCallId", "toolName", "result"], -} as const; - -export const PartSchema = { - oneOf: [ - { - $ref: "#/components/schemas/TextPart", - }, - { - $ref: "#/components/schemas/ImagePart", - }, - { - $ref: "#/components/schemas/AudioPart", - }, - { - $ref: "#/components/schemas/ToolCallPart", - }, - { - $ref: "#/components/schemas/ToolResultPart", - }, - ], -} as const; - -export const UserMessageSchema = { - type: "object", - description: "Represents a message sent by the user.", - properties: { - role: { - type: "string", - const: "user", - }, - content: { - type: "array", - items: { - oneOf: [ - { - $ref: "#/components/schemas/TextPart", - }, - { - $ref: "#/components/schemas/ImagePart", - }, - { - $ref: "#/components/schemas/AudioPart", - }, - ], - }, - }, - }, - required: ["role", "content"], -} as const; - -export const AssistantMessageSchema = { - type: "object", - description: "Represents a message generated by the model.", - properties: { - role: { - type: "string", - const: "assistant", - }, - content: { - type: "array", - items: { - oneOf: [ - { - $ref: "#/components/schemas/TextPart", - }, - { - $ref: "#/components/schemas/ToolCallPart", - }, - { - $ref: "#/components/schemas/AudioPart", - }, - ], - }, - }, - }, - required: ["role", "content"], -} as const; - -export const TextPartDeltaSchema = { - type: "object", - properties: { - type: { - type: "string", - const: "text", - }, - text: { - type: "string", - }, - }, - required: ["type", "text"], -} as const; - -export const ToolCallPartDeltaSchema = { - type: "object", - properties: { - type: { - type: "string", - const: "tool-call", - }, - toolCallId: { - type: "string", - description: - "The ID of the tool call, used to match the tool result with the tool call.", - }, - toolName: { - type: "string", - description: "The name of the tool to call.", - }, - args: { - type: "string", - description: - "The partial JSON string of the arguments to pass to the tool.", - }, - }, - required: ["type"], -} as const; - -export const AudioPartDeltaSchema = { - type: "object", - properties: { - type: { - type: "string", - const: "audio", - }, - audioData: { - type: "string", - description: "The base64-encoded audio data.", - }, - container: { - $ref: "#/components/schemas/AudioContainer", - }, - encoding: { - $ref: "#/components/schemas/AudioEncoding", - }, - sampleRate: { - type: "integer", - description: "The sample rate of the audio. E.g. 44100, 48000.", - }, - channels: { - type: "integer", - description: "The number of channels of the audio. E.g. 1, 2.", - }, - transcript: { - type: "string", - description: "The transcript of the audio.", - }, - }, - required: ["type"], -} as const; - -export const ContentDeltaSchema = { - type: "object", - properties: { - index: { - type: "integer", - }, - part: { - oneOf: [ - { - $ref: "#/components/schemas/TextPartDelta", - }, - { - $ref: "#/components/schemas/ToolCallPartDelta", - }, - { - $ref: "#/components/schemas/AudioPartDelta", - }, - ], - }, - }, - required: ["index", "part"], -} as const; - -export const ToolSchema = { - type: "object", - description: "Represents a tool that can be used by the model.", - properties: { - name: { - type: "string", - description: "The name of the tool.", - }, - description: { - type: "string", - description: "A description of the tool.", - }, - parameters: { - type: "object", - description: - 'The JSON schema of the parameters that the tool accepts. The type must be "object".', - nullable: true, - }, - }, - required: ["name", "description", "parameters"], -} as const; - -export const ToolMessageSchema = { - type: "object", - description: "Represents tool result in the message history.", - properties: { - role: { - type: "string", - const: "tool", - }, - content: { - type: "array", - items: { - $ref: "#/components/schemas/ToolResultPart", - }, - }, - }, - required: ["role", "content"], -} as const; - -export const MessageSchema = { - oneOf: [ - { - $ref: "#/components/schemas/UserMessage", - }, - { - $ref: "#/components/schemas/AssistantMessage", - }, - { - $ref: "#/components/schemas/ToolMessage", - }, - ], -} as const; - -export const ModelTokensDetailSchema = { - type: "object", - description: "Represents the token usage of the model.", - properties: { - textTokens: { - type: "integer", - }, - audioTokens: { - type: "integer", - }, - imageTokens: { - type: "integer", - }, - }, -} as const; - -export const ModelUsageSchema = { - type: "object", - description: "Represents the token usage of the model.", - properties: { - inputTokens: { - type: "integer", - }, - outputTokens: { - type: "integer", - }, - inputTokensDetail: { - $ref: "#/components/schemas/ModelTokensDetail", - }, - outputTokensDetail: { - $ref: "#/components/schemas/ModelTokensDetail", - }, - }, - required: ["inputTokens", "outputTokens"], -} as const; - -export const ModelResponseSchema = { - type: "object", - description: "Represents the response generated by the model.", - properties: { - content: { - type: "array", - items: { - oneOf: [ - { - $ref: "#/components/schemas/TextPart", - }, - { - $ref: "#/components/schemas/ToolCallPart", - }, - { - $ref: "#/components/schemas/AudioPart", - }, - ], - }, - }, - usage: { - $ref: "#/components/schemas/ModelUsage", - }, - cost: { - type: "number", - description: "The cost of the response.", - }, - }, - required: ["content"], -} as const; - -export const PartialModelResponseSchema = { - type: "object", - properties: { - delta: { - $ref: "#/components/schemas/ContentDelta", - }, - }, - required: ["delta"], -} as const; - -export const ToolChoiceAutoSchema = { - type: "object", - description: - "The model will automatically choose the tool to use or not use any tools.", - properties: { - type: { - type: "string", - const: "auto", - }, - }, - required: ["type"], -} as const; - -export const ToolChoiceNoneSchema = { - type: "object", - description: "The model will not use any tools.", - properties: { - type: { - type: "string", - const: "none", - }, - }, - required: ["type"], -} as const; - -export const ToolChoiceRequiredSchema = { - type: "object", - description: "The model will be forced to use a tool.", - properties: { - type: { - type: "string", - const: "required", - }, - }, - required: ["type"], -} as const; - -export const ToolChoiceToolSchema = { - type: "object", - description: "The model will use the specified tool.", - properties: { - type: { - type: "string", - const: "tool", - }, - toolName: { - type: "string", - }, - }, - required: ["type", "toolName"], -} as const; - -export const ResponseFormatTextSchema = { - type: "object", - properties: { - type: { - type: "string", - const: "text", - }, - }, - required: ["type"], -} as const; - -export const ResponseFormatJsonSchema = { - type: "object", - properties: { - type: { - type: "string", - const: "json", - }, - schema: { - type: "object", - description: - "The JSON schema of the response that the model must output. Not all models support this option.", - }, - }, - required: ["type"], -} as const; - -export const ModalitySchema = { - type: "string", - enum: ["text", "audio"], -} as const; - -export const LanguageModelInputSchema = { - type: "object", - properties: { - systemPrompt: { - type: "string", - description: - "A system prompt is a way of providing context and instructions to the model", - }, - messages: { - type: "array", - items: { - $ref: "#/components/schemas/Message", - }, - description: "A list of messages comprising the conversation so far.", - }, - tools: { - type: "array", - items: { - $ref: "#/components/schemas/Tool", - }, - description: "Definitions of tools that the model may use.", - }, - toolChoice: { - oneOf: [ - { - $ref: "#/components/schemas/ToolChoiceAuto", - }, - { - $ref: "#/components/schemas/ToolChoiceNone", - }, - { - $ref: "#/components/schemas/ToolChoiceRequired", - }, - { - $ref: "#/components/schemas/ToolChoiceTool", - }, - ], - description: - 'Determines how the model should choose which tool to use. "auto" - The model will automatically choose the tool to use or not use any tools. "none" - The model will not use any tools. "required" - The model will be forced to use a tool. { type: "tool", toolName: "toolName" } - The model will use the specified tool.', - }, - responseFormat: { - oneOf: [ - { - $ref: "#/components/schemas/ResponseFormatJson", - }, - { - $ref: "#/components/schemas/ResponseFormatText", - }, - ], - description: "The format that the model must output", - }, - maxTokens: { - type: "integer", - description: - "The maximum number of tokens that can be generated in the chat completion.", - }, - temperature: { - type: "number", - description: - "Amount of randomness injected into the response. Ranges from 0.0 to 1.0", - }, - topP: { - type: "number", - description: - "An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0", - }, - topK: { - type: "number", - description: - 'Only sample from the top K options for each subsequent token. Used to remove "long tail" low probability responses. Ranges from 0.0 to 1.0', - }, - presencePenalty: { - type: "number", - description: - "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics.", - }, - frequencyPenalty: { - type: "number", - description: - "Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim.", - }, - seed: { - type: "integer", - description: - "The seed (integer), if set and supported by the model, to enable deterministic results.", - }, - modalities: { - type: "array", - items: { - $ref: "#/components/schemas/Modality", - }, - description: "The modalities that the model should support.", - }, - extra: { - type: "object", - description: "Extra options that the model may support.", - }, - }, - required: ["messages"], -} as const; diff --git a/javascript/src/utils/audio.utils.ts b/javascript/src/utils/audio.utils.ts index 8e742b5..1f3de3b 100644 --- a/javascript/src/utils/audio.utils.ts +++ b/javascript/src/utils/audio.utils.ts @@ -1,4 +1,4 @@ -import type { AudioContainer, AudioEncoding } from "../schemas/types.gen.js"; +import type { AudioContainer, AudioEncoding } from "../schema/types.gen.js"; export function base64ToArrayBuffer(base64: string): ArrayBuffer { const binaryString = atob(base64); diff --git a/javascript/src/utils/message.utils.ts b/javascript/src/utils/message.utils.ts index ecc4e3f..0d54f5a 100644 --- a/javascript/src/utils/message.utils.ts +++ b/javascript/src/utils/message.utils.ts @@ -1,4 +1,4 @@ -import type { Message } from "../schemas/types.gen.js"; +import type { Message } from "../schema/types.gen.js"; export function convertAudioPartsToTextParts(message: T): T { return { diff --git a/javascript/src/utils/stream.utils.ts b/javascript/src/utils/stream.utils.ts index e5ed0f1..380ab2c 100644 --- a/javascript/src/utils/stream.utils.ts +++ b/javascript/src/utils/stream.utils.ts @@ -5,7 +5,7 @@ import type { TextPartDelta, ToolCallPart, ToolCallPartDelta, -} from "../schemas/index.js"; +} from "../schema/index.js"; import { arrayBufferToBase64, base64ToArrayBuffer, @@ -161,11 +161,10 @@ export function guessDeltaIndex( matchingDelta = allContentDeltas.findLast((contentDelta) => { if (part.type === "text" || part.type === "audio") { return contentDelta.part.type === part.type; - } else { - // we won't be able to reliably match tool calls - // because there can be multiple tool calls with the same tool name - return false; } + // we won't be able to reliably match tool calls + // because there can be multiple tool calls with the same tool name + return false; }); } if (matchingDelta) { diff --git a/javascript/src/utils/usage.utils.ts b/javascript/src/utils/usage.utils.ts index fd43099..91e8a3c 100644 --- a/javascript/src/utils/usage.utils.ts +++ b/javascript/src/utils/usage.utils.ts @@ -1,5 +1,5 @@ import type { LanguageModelPricing } from "../models/language-model.js"; -import type { ModelUsage } from "../schemas/types.gen.js"; +import type { ModelUsage } from "../schema/index.js"; export function calculateCost( usage: ModelUsage, diff --git a/package-lock.json b/package-lock.json index 7c6d067..9579256 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4,6 +4,7 @@ "requires": true, "packages": { "": { + "hasInstallScript": true, "workspaces": [ "javascript" ], @@ -19,7 +20,6 @@ }, "devDependencies": { "@eslint/js": "^9.14.0", - "@hey-api/openapi-ts": "^0.55.0", "@types/audio-context": "^1.0.3", "@types/audio-play": "^2.3.2", "@types/node": "^22.9.0", @@ -27,7 +27,8 @@ "eslint-config-prettier": "^9.1.0", "eslint-plugin-prettier": "^5.2.1", "globals": "^15.12.0", - "ibm-openapi-validator": "^1.25.0", + "json-schema-to-typescript": "^15.0.3", + "patch-package": "^8.0.0", "prettier": "^3.3.3", "tshy": "^3.0.2", "tsx": "^4.19.2", @@ -89,15 +90,6 @@ "url": "https://github.com/sponsors/philsturgeon" } }, - "node_modules/@asyncapi/specs": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@asyncapi/specs/-/specs-4.3.1.tgz", - "integrity": "sha512-EfexhJu/lwF8OdQDm28NKLJHFkx0Gb6O+rcezhZYLPIoNYKXJMh2J1vFGpwmfAcTTh+ffK44Oc2Hs1Q4sLBp+A==", - "dev": true, - "dependencies": { - "@types/json-schema": "^7.0.11" - } - }, "node_modules/@aws-crypto/crc32": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/@aws-crypto/crc32/-/crc32-3.0.0.tgz", @@ -1531,40 +1523,6 @@ "node": ">=18.0.0" } }, - "node_modules/@hey-api/openapi-ts": { - "version": "0.55.0", - "resolved": "https://registry.npmjs.org/@hey-api/openapi-ts/-/openapi-ts-0.55.0.tgz", - "integrity": "sha512-GpOdpSbtYOfF5+G7P2CFUlVFl9hYMynKoM3Yw48EeCP1vuI85TBbjnMja1GkX5Ek4kLjvDmwP2dGHq+kL5b4LQ==", - "dev": true, - "license": "FSL-1.1-MIT", - "dependencies": { - "@apidevtools/json-schema-ref-parser": "11.7.2", - "c12": "2.0.1", - "commander": "12.1.0", - "handlebars": "4.7.8" - }, - "bin": { - "openapi-ts": "bin/index.cjs" - }, - "engines": { - "node": "^18.0.0 || >=20.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/mrlubos" - }, - "peerDependencies": { - "typescript": "^5.x" - } - }, - "node_modules/@hey-api/openapi-ts/node_modules/commander": { - "version": "12.1.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-12.1.0.tgz", - "integrity": "sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==", - "dev": true, - "engines": { - "node": ">=18" - } - }, "node_modules/@hoangvvo/llm-sdk": { "resolved": "javascript", "link": true @@ -1607,60 +1565,6 @@ "dev": true, "license": "BSD-3-Clause" }, - "node_modules/@ibm-cloud/openapi-ruleset": { - "version": "1.23.2", - "resolved": "https://registry.npmjs.org/@ibm-cloud/openapi-ruleset/-/openapi-ruleset-1.23.2.tgz", - "integrity": "sha512-yNdrVw9OZ8AHb1FR+o4k1ST5c+kXOKOMKYkRi1nFBtOlOuAZU+FMym9tnFa3lOS9+ePipul5DBJj3Hhd70vFpw==", - "dev": true, - "dependencies": { - "@ibm-cloud/openapi-ruleset-utilities": "1.4.0", - "@stoplight/spectral-formats": "^1.7.0", - "@stoplight/spectral-functions": "^1.9.0", - "@stoplight/spectral-rulesets": "^1.20.2", - "chalk": "^4.1.2", - "lodash": "^4.17.21", - "loglevel": "^1.9.2", - "loglevel-plugin-prefix": "0.8.4", - "minimatch": "^6.2.0", - "validator": "^13.11.0" - }, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@ibm-cloud/openapi-ruleset-utilities": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@ibm-cloud/openapi-ruleset-utilities/-/openapi-ruleset-utilities-1.4.0.tgz", - "integrity": "sha512-m033WjdlX3k5aSpK2iNX61hS4INEJXUpAxr1l1wBamRQklZpXE2EZKcDQ5AuqVMyz4VV9e46RTp6MAcwXh0gbA==", - "dev": true, - "engines": { - "node": ">=16.0.0" - } - }, - "node_modules/@ibm-cloud/openapi-ruleset/node_modules/brace-expansion": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", - "dev": true, - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/@ibm-cloud/openapi-ruleset/node_modules/minimatch": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-6.2.0.tgz", - "integrity": "sha512-sauLxniAmvnhhRjFwPNnJKaPFYyddAgbYdeUpHULtCT/GhzdCx/MDNy+Y40lBxTQUrMzDE8e0S43Z5uqfO0REg==", - "dev": true, - "dependencies": { - "brace-expansion": "^2.0.1" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/@isaacs/cliui": { "version": "8.0.2", "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", @@ -1764,30 +1668,6 @@ "dev": true, "license": "MIT" }, - "node_modules/@jsep-plugin/regex": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.3.tgz", - "integrity": "sha512-XfZgry4DwEZvSFtS/6Y+R48D7qJYJK6R9/yJFyUFHCIUMEEHuJ4X95TDgJp5QkmzfLYvapMPzskV5HpIDrREug==", - "dev": true, - "engines": { - "node": ">= 10.16.0" - }, - "peerDependencies": { - "jsep": "^0.4.0||^1.0.0" - } - }, - "node_modules/@jsep-plugin/ternary": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@jsep-plugin/ternary/-/ternary-1.1.3.tgz", - "integrity": "sha512-qtLGzCNzPVJ3kdH6/zoLWDPjauHIKiLSBAR71Wa0+PWvGA8wODUQvRgxtpUA5YqAYL3CQ8S4qXhd/9WuWTZirg==", - "dev": true, - "engines": { - "node": ">= 10.16.0" - }, - "peerDependencies": { - "jsep": "^0.4.0||^1.0.0" - } - }, "node_modules/@mistralai/mistralai": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/@mistralai/mistralai/-/mistralai-1.3.0.tgz", @@ -1857,56 +1737,6 @@ "url": "https://opencollective.com/unts" } }, - "node_modules/@rollup/plugin-commonjs": { - "version": "22.0.2", - "resolved": "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-22.0.2.tgz", - "integrity": "sha512-//NdP6iIwPbMTcazYsiBMbJW7gfmpHom33u1beiIoHDEM0Q9clvtQB1T0efvMqHeKsGohiHo97BCPCkBXdscwg==", - "dev": true, - "dependencies": { - "@rollup/pluginutils": "^3.1.0", - "commondir": "^1.0.1", - "estree-walker": "^2.0.1", - "glob": "^7.1.6", - "is-reference": "^1.2.1", - "magic-string": "^0.25.7", - "resolve": "^1.17.0" - }, - "engines": { - "node": ">= 12.0.0" - }, - "peerDependencies": { - "rollup": "^2.68.0" - } - }, - "node_modules/@rollup/pluginutils": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-3.1.0.tgz", - "integrity": "sha512-GksZ6pr6TpIjHm8h9lSQ8pi8BE9VeubNT0OMJ3B5uZJ8pz73NPiqOtCog/x2/QzM1ENChPKxMDhiQuRHsqc+lg==", - "dev": true, - "dependencies": { - "@types/estree": "0.0.39", - "estree-walker": "^1.0.1", - "picomatch": "^2.2.2" - }, - "engines": { - "node": ">= 8.0.0" - }, - "peerDependencies": { - "rollup": "^1.20.0||^2.0.0" - } - }, - "node_modules/@rollup/pluginutils/node_modules/@types/estree": { - "version": "0.0.39", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.39.tgz", - "integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==", - "dev": true - }, - "node_modules/@rollup/pluginutils/node_modules/estree-walker": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-1.0.1.tgz", - "integrity": "sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg==", - "dev": true - }, "node_modules/@smithy/abort-controller": { "version": "3.1.6", "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-3.1.6.tgz", @@ -2510,854 +2340,175 @@ "node": ">=16.0.0" } }, - "node_modules/@stoplight/json": { - "version": "3.21.7", - "resolved": "https://registry.npmjs.org/@stoplight/json/-/json-3.21.7.tgz", - "integrity": "sha512-xcJXgKFqv/uCEgtGlPxy3tPA+4I+ZI4vAuMJ885+ThkTHFVkC+0Fm58lA9NlsyjnkpxFh4YiQWpH+KefHdbA0A==", - "dev": true, + "node_modules/@thi.ng/bitstream": { + "version": "2.4.3", + "resolved": "https://registry.npmjs.org/@thi.ng/bitstream/-/bitstream-2.4.3.tgz", + "integrity": "sha512-XfqT0G1WUjF/cJtdbwncoR4Z2NUPgQQEztq8FheoO110u2FxVxINhdkqO96qW8Fw+TD9JqdUPvT8IQbt7YF2ZA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/postspectacular" + }, + { + "type": "patreon", + "url": "https://patreon.com/thing_umbrella" + } + ], "dependencies": { - "@stoplight/ordered-object-literal": "^1.0.3", - "@stoplight/path": "^1.3.2", - "@stoplight/types": "^13.6.0", - "jsonc-parser": "~2.2.1", - "lodash": "^4.17.21", - "safe-stable-stringify": "^1.1" + "@thi.ng/errors": "^2.5.17" }, "engines": { - "node": ">=8.3.0" + "node": ">=18" } }, - "node_modules/@stoplight/json-ref-readers": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/@stoplight/json-ref-readers/-/json-ref-readers-1.2.2.tgz", - "integrity": "sha512-nty0tHUq2f1IKuFYsLM4CXLZGHdMn+X/IwEUIpeSOXt0QjMUbL0Em57iJUDzz+2MkWG83smIigNZ3fauGjqgdQ==", - "dev": true, - "dependencies": { - "node-fetch": "^2.6.0", - "tslib": "^1.14.1" - }, + "node_modules/@thi.ng/errors": { + "version": "2.5.17", + "resolved": "https://registry.npmjs.org/@thi.ng/errors/-/errors-2.5.17.tgz", + "integrity": "sha512-ohBAZcGNEIEOgJ9BPH4tjIsOjVgsnMGh4a2j63r6El68efr8RRN4G+GNkDaqV/jk9wbHKZZPt2t6suJMliPyxg==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/postspectacular" + }, + { + "type": "patreon", + "url": "https://patreon.com/thing_umbrella" + } + ], "engines": { - "node": ">=8.3.0" + "node": ">=18" } }, - "node_modules/@stoplight/json-ref-readers/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==", + "node_modules/@types/audio-context": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@types/audio-context/-/audio-context-1.0.3.tgz", + "integrity": "sha512-qACIhwTztJ2t/kfLsloj8FC9TJW9lUnOrejvyqJn1vtS8WiWlwsCACQWjUbJvAIFZLt1P1O204HAmdsl7G2pzw==", "dev": true }, - "node_modules/@stoplight/json-ref-resolver": { - "version": "3.1.6", - "resolved": "https://registry.npmjs.org/@stoplight/json-ref-resolver/-/json-ref-resolver-3.1.6.tgz", - "integrity": "sha512-YNcWv3R3n3U6iQYBsFOiWSuRGE5su1tJSiX6pAPRVk7dP0L7lqCteXGzuVRQ0gMZqUl8v1P0+fAKxF6PLo9B5A==", + "node_modules/@types/audio-play": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/@types/audio-play/-/audio-play-2.3.2.tgz", + "integrity": "sha512-tGQbApfao04cIIiN6GtAJFjnJsdiN1L3zL90a8BKqsTycO0XxlQ8BR436MoZIlR2fBdP0IUJdTVbDweiHLVPnQ==", + "dev": true + }, + "node_modules/@types/json-schema": { + "version": "7.0.15", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", + "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", + "dev": true + }, + "node_modules/@types/lodash": { + "version": "4.17.13", + "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.17.13.tgz", + "integrity": "sha512-lfx+dftrEZcdBPczf9d0Qv0x+j/rfNCMuC6OcfXmO8gkfeNAY88PgKUbvG56whcN23gc27yenwF6oJZXGFpYxg==", "dev": true, + "license": "MIT" + }, + "node_modules/@types/node": { + "version": "22.9.0", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.9.0.tgz", + "integrity": "sha512-vuyHg81vvWA1Z1ELfvLko2c8f34gyA0zaic0+Rllc5lbCnbSyuvb2Oxpm6TAUAC/2xZN3QGqxBNggD1nNR2AfQ==", + "license": "MIT", "dependencies": { - "@stoplight/json": "^3.21.0", - "@stoplight/path": "^1.3.2", - "@stoplight/types": "^12.3.0 || ^13.0.0", - "@types/urijs": "^1.19.19", - "dependency-graph": "~0.11.0", - "fast-memoize": "^2.5.2", - "immer": "^9.0.6", - "lodash": "^4.17.21", - "tslib": "^2.6.0", - "urijs": "^1.19.11" - }, - "engines": { - "node": ">=8.3.0" + "undici-types": "~6.19.8" } }, - "node_modules/@stoplight/ordered-object-literal": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/@stoplight/ordered-object-literal/-/ordered-object-literal-1.0.5.tgz", - "integrity": "sha512-COTiuCU5bgMUtbIFBuyyh2/yVVzlr5Om0v5utQDgBCuQUOPgU1DwoffkTfg4UBQOvByi5foF4w4T+H9CoRe5wg==", - "dev": true, - "engines": { - "node": ">=8" + "node_modules/@types/node-fetch": { + "version": "2.6.11", + "resolved": "https://registry.npmjs.org/@types/node-fetch/-/node-fetch-2.6.11.tgz", + "integrity": "sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g==", + "dependencies": { + "@types/node": "*", + "form-data": "^4.0.0" } }, - "node_modules/@stoplight/path": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/@stoplight/path/-/path-1.3.2.tgz", - "integrity": "sha512-lyIc6JUlUA8Ve5ELywPC8I2Sdnh1zc1zmbYgVarhXIp9YeAB0ReeqmGEOWNtlHkbP2DAA1AL65Wfn2ncjK/jtQ==", + "node_modules/@types/uuid": { + "version": "9.0.8", + "resolved": "https://registry.npmjs.org/@types/uuid/-/uuid-9.0.8.tgz", + "integrity": "sha512-jg+97EGIcY9AGHJJRaaPVgetKDsrTgbRjQ5Msgjh/DQKEFl0DtyRr/VCOyD1T2R1MNeWPK/u7JoGhlDZnKBAfA==", + "license": "MIT" + }, + "node_modules/@ungap/structured-clone": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", + "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", "dev": true, - "engines": { - "node": ">=8" + "license": "ISC" + }, + "node_modules/@wasm-audio-decoders/common": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/@wasm-audio-decoders/common/-/common-9.0.5.tgz", + "integrity": "sha512-b9JNh9sPAvn8PVIizNh9D60WkfQong/u9ea873H47u7zvVDLctxYIp2aZw9CQqXaQdk7JB3MoU5UHiseO40swg==", + "dependencies": { + "@eshaz/web-worker": "1.2.2", + "simple-yenc": "^1.0.4" } }, - "node_modules/@stoplight/spectral-cli": { - "version": "6.13.1", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-cli/-/spectral-cli-6.13.1.tgz", - "integrity": "sha512-v6ipX4w6wRhtbOotwdPL7RrEkP0m1OwHTIyqzVrAPi932F/zkee24jmf1CHNrTynonmfGoU6/XpeqUHtQdKDFw==", - "dev": true, - "dependencies": { - "@stoplight/json": "~3.21.0", - "@stoplight/path": "1.3.2", - "@stoplight/spectral-core": "^1.18.3", - "@stoplight/spectral-formatters": "^1.3.0", - "@stoplight/spectral-parsers": "^1.0.3", - "@stoplight/spectral-ref-resolver": "^1.0.4", - "@stoplight/spectral-ruleset-bundler": "^1.5.4", - "@stoplight/spectral-ruleset-migrator": "^1.9.6", - "@stoplight/spectral-rulesets": ">=1", - "@stoplight/spectral-runtime": "^1.1.2", - "@stoplight/types": "^13.6.0", - "chalk": "4.1.2", - "fast-glob": "~3.2.12", - "hpagent": "~1.2.0", - "lodash": "~4.17.21", - "pony-cause": "^1.0.0", - "stacktracey": "^2.1.7", - "tslib": "^2.3.0", - "yargs": "~17.7.2" - }, - "bin": { - "spectral": "dist/index.js" + "node_modules/@wasm-audio-decoders/flac": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/@wasm-audio-decoders/flac/-/flac-0.2.5.tgz", + "integrity": "sha512-8M//CgB3PlkWwn47KcwD0tO6DZBA7/AGG0ukHSG0G97UbNEUNINvKDWAKPVWznzHsqeBP6axw+K/38dzng64JA==", + "dependencies": { + "@wasm-audio-decoders/common": "9.0.5", + "codec-parser": "2.5.0" }, - "engines": { - "node": "^12.20 || >= 14.13" + "funding": { + "type": "individual", + "url": "https://github.com/sponsors/eshaz" } }, - "node_modules/@stoplight/spectral-cli/node_modules/fast-glob": { - "version": "3.2.12", - "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.12.tgz", - "integrity": "sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w==", - "dev": true, + "node_modules/@wasm-audio-decoders/ogg-vorbis": { + "version": "0.1.16", + "resolved": "https://registry.npmjs.org/@wasm-audio-decoders/ogg-vorbis/-/ogg-vorbis-0.1.16.tgz", + "integrity": "sha512-HcEx4LPZbbzjhs9bTXgMaXLVCSMSo/egY9paJxAnE9tsYbvseAaGtVddLYktl3Qi/G+nW/ZzUXg4144izJjqCw==", "dependencies": { - "@nodelib/fs.stat": "^2.0.2", - "@nodelib/fs.walk": "^1.2.3", - "glob-parent": "^5.1.2", - "merge2": "^1.3.0", - "micromatch": "^4.0.4" + "@wasm-audio-decoders/common": "9.0.5", + "codec-parser": "2.5.0" }, - "engines": { - "node": ">=8.6.0" + "funding": { + "type": "individual", + "url": "https://github.com/sponsors/eshaz" } }, - "node_modules/@stoplight/spectral-cli/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "node_modules/@yarnpkg/lockfile": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@yarnpkg/lockfile/-/lockfile-1.1.0.tgz", + "integrity": "sha512-GpSwvyXOcOOlV70vbnzjj4fW5xW/FdUF6nQEt1ENy7m4ZCczi1+/buVUPAqmGfqznsORNFzUMjctTIp8a9tuCQ==", "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/abort-controller": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz", + "integrity": "sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==", "dependencies": { - "is-glob": "^4.0.1" + "event-target-shim": "^5.0.0" }, "engines": { - "node": ">= 6" + "node": ">=6.5" } }, - "node_modules/@stoplight/spectral-core": { - "version": "1.19.1", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-core/-/spectral-core-1.19.1.tgz", - "integrity": "sha512-YiWhXdjyjn4vCl3102ywzwCEJzncxapFcj4dxcj1YP/bZ62DFeGJ8cEaMP164vSw2kI3rX7EMMzI/c8XOUnTfQ==", + "node_modules/acorn": { + "version": "8.14.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.14.0.tgz", + "integrity": "sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA==", "dev": true, - "dependencies": { - "@stoplight/better-ajv-errors": "1.0.3", - "@stoplight/json": "~3.21.0", - "@stoplight/path": "1.3.2", - "@stoplight/spectral-parsers": "^1.0.0", - "@stoplight/spectral-ref-resolver": "^1.0.4", - "@stoplight/spectral-runtime": "^1.0.0", - "@stoplight/types": "~13.6.0", - "@types/es-aggregate-error": "^1.0.2", - "@types/json-schema": "^7.0.11", - "ajv": "^8.17.1", - "ajv-errors": "~3.0.0", - "ajv-formats": "~2.1.0", - "es-aggregate-error": "^1.0.7", - "jsonpath-plus": "7.1.0", - "lodash": "~4.17.21", - "lodash.topath": "^4.5.2", - "minimatch": "3.1.2", - "nimma": "0.2.2", - "pony-cause": "^1.0.0", - "simple-eval": "1.0.0", - "tslib": "^2.3.0" + "license": "MIT", + "bin": { + "acorn": "bin/acorn" }, "engines": { - "node": "^12.20 || >= 14.13" + "node": ">=0.4.0" } }, - "node_modules/@stoplight/spectral-core/node_modules/@stoplight/better-ajv-errors": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@stoplight/better-ajv-errors/-/better-ajv-errors-1.0.3.tgz", - "integrity": "sha512-0p9uXkuB22qGdNfy3VeEhxkU5uwvp/KrBTAbrLBURv6ilxIVwanKwjMc41lQfIVgPGcOkmLbTolfFrSsueu7zA==", + "node_modules/acorn-jsx": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", + "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", "dev": true, - "dependencies": { - "jsonpointer": "^5.0.0", - "leven": "^3.1.0" - }, - "engines": { - "node": "^12.20 || >= 14.13" - }, + "license": "MIT", "peerDependencies": { - "ajv": ">=8" - } - }, - "node_modules/@stoplight/spectral-core/node_modules/@stoplight/types": { - "version": "13.6.0", - "resolved": "https://registry.npmjs.org/@stoplight/types/-/types-13.6.0.tgz", - "integrity": "sha512-dzyuzvUjv3m1wmhPfq82lCVYGcXG0xUYgqnWfCq3PCVR4BKFhjdkHrnJ+jIDoMKvXb05AZP/ObQF6+NpDo29IQ==", - "dev": true, - "dependencies": { - "@types/json-schema": "^7.0.4", - "utility-types": "^3.10.0" - }, - "engines": { - "node": "^12.20 || >=14.13" - } - }, - "node_modules/@stoplight/spectral-core/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/@stoplight/spectral-core/node_modules/ajv-errors": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ajv-errors/-/ajv-errors-3.0.0.tgz", - "integrity": "sha512-V3wD15YHfHz6y0KdhYFjyy9vWtEVALT9UrxfN3zqlI6dMioHnJrqOYfyPKol3oqrnCM9uwkcdCwkJ0WUcbLMTQ==", - "dev": true, - "peerDependencies": { - "ajv": "^8.0.1" - } - }, - "node_modules/@stoplight/spectral-core/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, - "node_modules/@stoplight/spectral-core/node_modules/nimma": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/nimma/-/nimma-0.2.2.tgz", - "integrity": "sha512-V52MLl7BU+tH2Np9tDrIXK8bql3MVUadnMIl/0/oZSGC9keuro0O9UUv9QKp0aMvtN8HRew4G7byY7H4eWsxaQ==", - "dev": true, - "dependencies": { - "@jsep-plugin/regex": "^1.0.1", - "@jsep-plugin/ternary": "^1.0.2", - "astring": "^1.8.1", - "jsep": "^1.2.0" - }, - "engines": { - "node": "^12.20 || >=14.13" - }, - "optionalDependencies": { - "jsonpath-plus": "^6.0.1", - "lodash.topath": "^4.5.2" - } - }, - "node_modules/@stoplight/spectral-core/node_modules/nimma/node_modules/jsonpath-plus": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-6.0.1.tgz", - "integrity": "sha512-EvGovdvau6FyLexFH2OeXfIITlgIbgZoAZe3usiySeaIDm5QS+A10DKNpaPBBqqRSZr2HN6HVNXxtwUAr2apEw==", - "dev": true, - "optional": true, - "engines": { - "node": ">=10.0.0" - } - }, - "node_modules/@stoplight/spectral-formats": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-formats/-/spectral-formats-1.7.0.tgz", - "integrity": "sha512-vJ1vIkA2s96fdJp0d3AJBGuPAW3sj8yMamyzR+dquEFO6ZAoYBo/BVsKKQskYzZi/nwljlRqUmGVmcf2PncIaA==", - "dev": true, - "dependencies": { - "@stoplight/json": "^3.17.0", - "@stoplight/spectral-core": "^1.8.0", - "@types/json-schema": "^7.0.7", - "tslib": "^2.3.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@stoplight/spectral-formatters": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-formatters/-/spectral-formatters-1.4.0.tgz", - "integrity": "sha512-nxYQldDzVg32pxQ4cMX27eMtB1A39ea+GSf0wIJ20mqkSBfIgLnRZ+GKkBxhgF9JzSolc4YtweydsubGQGd7ag==", - "dev": true, - "dependencies": { - "@stoplight/path": "^1.3.2", - "@stoplight/spectral-core": "^1.15.1", - "@stoplight/spectral-runtime": "^1.1.0", - "@stoplight/types": "^13.15.0", - "@types/markdown-escape": "^1.1.3", - "chalk": "4.1.2", - "cliui": "7.0.4", - "lodash": "^4.17.21", - "markdown-escape": "^2.0.0", - "node-sarif-builder": "^2.0.3", - "strip-ansi": "6.0", - "text-table": "^0.2.0", - "tslib": "^2.5.0" - }, - "engines": { - "node": "^12.20 || >=14.13" - } - }, - "node_modules/@stoplight/spectral-functions": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-functions/-/spectral-functions-1.9.0.tgz", - "integrity": "sha512-T+xl93ji8bpus4wUsTq8Qr2DSu2X9PO727rbxW61tTCG0s17CbsXOLYI+Ezjg5P6aaQlgXszGX8khtc57xk8Yw==", - "dev": true, - "dependencies": { - "@stoplight/better-ajv-errors": "1.0.3", - "@stoplight/json": "^3.17.1", - "@stoplight/spectral-core": "^1.7.0", - "@stoplight/spectral-formats": "^1.7.0", - "@stoplight/spectral-runtime": "^1.1.0", - "ajv": "^8.17.1", - "ajv-draft-04": "~1.0.0", - "ajv-errors": "~3.0.0", - "ajv-formats": "~2.1.0", - "lodash": "~4.17.21", - "tslib": "^2.3.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@stoplight/spectral-functions/node_modules/@stoplight/better-ajv-errors": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@stoplight/better-ajv-errors/-/better-ajv-errors-1.0.3.tgz", - "integrity": "sha512-0p9uXkuB22qGdNfy3VeEhxkU5uwvp/KrBTAbrLBURv6ilxIVwanKwjMc41lQfIVgPGcOkmLbTolfFrSsueu7zA==", - "dev": true, - "dependencies": { - "jsonpointer": "^5.0.0", - "leven": "^3.1.0" - }, - "engines": { - "node": "^12.20 || >= 14.13" - }, - "peerDependencies": { - "ajv": ">=8" - } - }, - "node_modules/@stoplight/spectral-functions/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/@stoplight/spectral-functions/node_modules/ajv-draft-04": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/ajv-draft-04/-/ajv-draft-04-1.0.0.tgz", - "integrity": "sha512-mv00Te6nmYbRp5DCwclxtt7yV/joXJPGS7nM+97GdxvuttCOfgI3K4U25zboyeX0O+myI8ERluxQe5wljMmVIw==", - "dev": true, - "peerDependencies": { - "ajv": "^8.5.0" - }, - "peerDependenciesMeta": { - "ajv": { - "optional": true - } - } - }, - "node_modules/@stoplight/spectral-functions/node_modules/ajv-errors": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ajv-errors/-/ajv-errors-3.0.0.tgz", - "integrity": "sha512-V3wD15YHfHz6y0KdhYFjyy9vWtEVALT9UrxfN3zqlI6dMioHnJrqOYfyPKol3oqrnCM9uwkcdCwkJ0WUcbLMTQ==", - "dev": true, - "peerDependencies": { - "ajv": "^8.0.1" - } - }, - "node_modules/@stoplight/spectral-functions/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, - "node_modules/@stoplight/spectral-parsers": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-parsers/-/spectral-parsers-1.0.4.tgz", - "integrity": "sha512-nCTVvtX6q71M8o5Uvv9kxU31Gk1TRmgD6/k8HBhdCmKG6FWcwgjiZouA/R3xHLn/VwTI/9k8SdG5Mkdy0RBqbQ==", - "dev": true, - "dependencies": { - "@stoplight/json": "~3.21.0", - "@stoplight/types": "^14.1.1", - "@stoplight/yaml": "~4.3.0", - "tslib": "^2.3.1" - }, - "engines": { - "node": "^12.20 || >=14.13" - } - }, - "node_modules/@stoplight/spectral-parsers/node_modules/@stoplight/types": { - "version": "14.1.1", - "resolved": "https://registry.npmjs.org/@stoplight/types/-/types-14.1.1.tgz", - "integrity": "sha512-/kjtr+0t0tjKr+heVfviO9FrU/uGLc+QNX3fHJc19xsCNYqU7lVhaXxDmEID9BZTjG+/r9pK9xP/xU02XGg65g==", - "dev": true, - "dependencies": { - "@types/json-schema": "^7.0.4", - "utility-types": "^3.10.0" - }, - "engines": { - "node": "^12.20 || >=14.13" - } - }, - "node_modules/@stoplight/spectral-ref-resolver": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-ref-resolver/-/spectral-ref-resolver-1.0.4.tgz", - "integrity": "sha512-5baQIYL0NJTSVy8v6RxOR4U51xOUYM8wJri1YvlAT6bPN8m0EIxMwfVYi0xUZEMVeHcWx869nIkoqyWmOutF2A==", - "dev": true, - "dependencies": { - "@stoplight/json-ref-readers": "1.2.2", - "@stoplight/json-ref-resolver": "~3.1.6", - "@stoplight/spectral-runtime": "^1.1.2", - "dependency-graph": "0.11.0", - "tslib": "^2.3.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@stoplight/spectral-ruleset-bundler": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-ruleset-bundler/-/spectral-ruleset-bundler-1.6.0.tgz", - "integrity": "sha512-8CU7e4aEGdfU9ncVDtlnJSawg/6epzAHrQTjuNu1QfKAOoiwyG7oUk2XUTHWcvq6Q67iUctb0vjOokR+MPVg0Q==", - "dev": true, - "dependencies": { - "@rollup/plugin-commonjs": "~22.0.2", - "@stoplight/path": "1.3.2", - "@stoplight/spectral-core": ">=1", - "@stoplight/spectral-formats": "^1.7.0", - "@stoplight/spectral-functions": ">=1", - "@stoplight/spectral-parsers": ">=1", - "@stoplight/spectral-ref-resolver": "^1.0.4", - "@stoplight/spectral-ruleset-migrator": "^1.9.6", - "@stoplight/spectral-rulesets": ">=1", - "@stoplight/spectral-runtime": "^1.1.0", - "@stoplight/types": "^13.6.0", - "@types/node": "*", - "pony-cause": "1.1.1", - "rollup": "~2.79.0", - "tslib": "^2.3.1", - "validate-npm-package-name": "3.0.0" - }, - "engines": { - "node": "^12.20 || >= 14.13" - } - }, - "node_modules/@stoplight/spectral-ruleset-migrator": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-ruleset-migrator/-/spectral-ruleset-migrator-1.10.0.tgz", - "integrity": "sha512-nDfkVfYeWWv0UvILC4TWZSnRqQ4rHgeOJO1/lHQ7XHeG5iONanQ639B1aK6ZS6vuUc8gwuyQsrPF67b4sHIyYw==", - "dev": true, - "dependencies": { - "@stoplight/json": "~3.21.0", - "@stoplight/ordered-object-literal": "~1.0.4", - "@stoplight/path": "1.3.2", - "@stoplight/spectral-functions": "^1.0.0", - "@stoplight/spectral-runtime": "^1.1.0", - "@stoplight/types": "^13.6.0", - "@stoplight/yaml": "~4.2.3", - "@types/node": "*", - "ajv": "^8.17.1", - "ast-types": "0.14.2", - "astring": "^1.7.5", - "reserved": "0.1.2", - "tslib": "^2.3.1", - "validate-npm-package-name": "3.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@stoplight/spectral-ruleset-migrator/node_modules/@stoplight/yaml": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/@stoplight/yaml/-/yaml-4.2.3.tgz", - "integrity": "sha512-Mx01wjRAR9C7yLMUyYFTfbUf5DimEpHMkRDQ1PKLe9dfNILbgdxyrncsOXM3vCpsQ1Hfj4bPiGl+u4u6e9Akqw==", - "dev": true, - "dependencies": { - "@stoplight/ordered-object-literal": "^1.0.1", - "@stoplight/types": "^13.0.0", - "@stoplight/yaml-ast-parser": "0.0.48", - "tslib": "^2.2.0" - }, - "engines": { - "node": ">=10.8" - } - }, - "node_modules/@stoplight/spectral-ruleset-migrator/node_modules/@stoplight/yaml-ast-parser": { - "version": "0.0.48", - "resolved": "https://registry.npmjs.org/@stoplight/yaml-ast-parser/-/yaml-ast-parser-0.0.48.tgz", - "integrity": "sha512-sV+51I7WYnLJnKPn2EMWgS4EUfoP4iWEbrWwbXsj0MZCB/xOK8j6+C9fntIdOM50kpx45ZLC3s6kwKivWuqvyg==", - "dev": true - }, - "node_modules/@stoplight/spectral-ruleset-migrator/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/@stoplight/spectral-ruleset-migrator/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, - "node_modules/@stoplight/spectral-rulesets": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-rulesets/-/spectral-rulesets-1.20.2.tgz", - "integrity": "sha512-7Y8orZuNyGyeHr9n50rMfysgUJ+/zzIEHMptt66jiy82GUWl+0nr865DkMuXdC5GryfDYhtjoRTUCVsXu80Nkg==", - "dev": true, - "dependencies": { - "@asyncapi/specs": "^4.1.0", - "@stoplight/better-ajv-errors": "1.0.3", - "@stoplight/json": "^3.17.0", - "@stoplight/spectral-core": "^1.8.1", - "@stoplight/spectral-formats": "^1.7.0", - "@stoplight/spectral-functions": "^1.5.1", - "@stoplight/spectral-runtime": "^1.1.1", - "@stoplight/types": "^13.6.0", - "@types/json-schema": "^7.0.7", - "ajv": "^8.17.1", - "ajv-formats": "~2.1.0", - "json-schema-traverse": "^1.0.0", - "leven": "3.1.0", - "lodash": "~4.17.21", - "tslib": "^2.3.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@stoplight/spectral-rulesets/node_modules/@stoplight/better-ajv-errors": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@stoplight/better-ajv-errors/-/better-ajv-errors-1.0.3.tgz", - "integrity": "sha512-0p9uXkuB22qGdNfy3VeEhxkU5uwvp/KrBTAbrLBURv6ilxIVwanKwjMc41lQfIVgPGcOkmLbTolfFrSsueu7zA==", - "dev": true, - "dependencies": { - "jsonpointer": "^5.0.0", - "leven": "^3.1.0" - }, - "engines": { - "node": "^12.20 || >= 14.13" - }, - "peerDependencies": { - "ajv": ">=8" - } - }, - "node_modules/@stoplight/spectral-rulesets/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/@stoplight/spectral-rulesets/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, - "node_modules/@stoplight/spectral-runtime": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@stoplight/spectral-runtime/-/spectral-runtime-1.1.2.tgz", - "integrity": "sha512-fr5zRceXI+hrl82yAVoME+4GvJie8v3wmOe9tU+ZLRRNonizthy8qDi0Z/z4olE+vGreSDcuDOZ7JjRxFW5kTw==", - "dev": true, - "dependencies": { - "@stoplight/json": "^3.17.0", - "@stoplight/path": "^1.3.2", - "@stoplight/types": "^12.3.0", - "abort-controller": "^3.0.0", - "lodash": "^4.17.21", - "node-fetch": "^2.6.7", - "tslib": "^2.3.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@stoplight/spectral-runtime/node_modules/@stoplight/types": { - "version": "12.5.0", - "resolved": "https://registry.npmjs.org/@stoplight/types/-/types-12.5.0.tgz", - "integrity": "sha512-dwqYcDrGmEyUv5TWrDam5TGOxU72ufyQ7hnOIIDdmW5ezOwZaBFoR5XQ9AsH49w7wgvOqB2Bmo799pJPWnpCbg==", - "dev": true, - "dependencies": { - "@types/json-schema": "^7.0.4", - "utility-types": "^3.10.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@stoplight/types": { - "version": "13.20.0", - "resolved": "https://registry.npmjs.org/@stoplight/types/-/types-13.20.0.tgz", - "integrity": "sha512-2FNTv05If7ib79VPDA/r9eUet76jewXFH2y2K5vuge6SXbRHtWBhcaRmu+6QpF4/WRNoJj5XYRSwLGXDxysBGA==", - "dev": true, - "dependencies": { - "@types/json-schema": "^7.0.4", - "utility-types": "^3.10.0" - }, - "engines": { - "node": "^12.20 || >=14.13" - } - }, - "node_modules/@stoplight/yaml": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/@stoplight/yaml/-/yaml-4.3.0.tgz", - "integrity": "sha512-JZlVFE6/dYpP9tQmV0/ADfn32L9uFarHWxfcRhReKUnljz1ZiUM5zpX+PH8h5CJs6lao3TuFqnPm9IJJCEkE2w==", - "dev": true, - "dependencies": { - "@stoplight/ordered-object-literal": "^1.0.5", - "@stoplight/types": "^14.1.1", - "@stoplight/yaml-ast-parser": "0.0.50", - "tslib": "^2.2.0" - }, - "engines": { - "node": ">=10.8" - } - }, - "node_modules/@stoplight/yaml-ast-parser": { - "version": "0.0.50", - "resolved": "https://registry.npmjs.org/@stoplight/yaml-ast-parser/-/yaml-ast-parser-0.0.50.tgz", - "integrity": "sha512-Pb6M8TDO9DtSVla9yXSTAxmo9GVEouq5P40DWXdOie69bXogZTkgvopCq+yEvTMA0F6PEvdJmbtTV3ccIp11VQ==", - "dev": true - }, - "node_modules/@stoplight/yaml/node_modules/@stoplight/types": { - "version": "14.1.1", - "resolved": "https://registry.npmjs.org/@stoplight/types/-/types-14.1.1.tgz", - "integrity": "sha512-/kjtr+0t0tjKr+heVfviO9FrU/uGLc+QNX3fHJc19xsCNYqU7lVhaXxDmEID9BZTjG+/r9pK9xP/xU02XGg65g==", - "dev": true, - "dependencies": { - "@types/json-schema": "^7.0.4", - "utility-types": "^3.10.0" - }, - "engines": { - "node": "^12.20 || >=14.13" - } - }, - "node_modules/@thi.ng/bitstream": { - "version": "2.4.3", - "resolved": "https://registry.npmjs.org/@thi.ng/bitstream/-/bitstream-2.4.3.tgz", - "integrity": "sha512-XfqT0G1WUjF/cJtdbwncoR4Z2NUPgQQEztq8FheoO110u2FxVxINhdkqO96qW8Fw+TD9JqdUPvT8IQbt7YF2ZA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/postspectacular" - }, - { - "type": "patreon", - "url": "https://patreon.com/thing_umbrella" - } - ], - "dependencies": { - "@thi.ng/errors": "^2.5.17" - }, - "engines": { - "node": ">=18" - } - }, - "node_modules/@thi.ng/errors": { - "version": "2.5.17", - "resolved": "https://registry.npmjs.org/@thi.ng/errors/-/errors-2.5.17.tgz", - "integrity": "sha512-ohBAZcGNEIEOgJ9BPH4tjIsOjVgsnMGh4a2j63r6El68efr8RRN4G+GNkDaqV/jk9wbHKZZPt2t6suJMliPyxg==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/postspectacular" - }, - { - "type": "patreon", - "url": "https://patreon.com/thing_umbrella" - } - ], - "engines": { - "node": ">=18" - } - }, - "node_modules/@types/audio-context": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@types/audio-context/-/audio-context-1.0.3.tgz", - "integrity": "sha512-qACIhwTztJ2t/kfLsloj8FC9TJW9lUnOrejvyqJn1vtS8WiWlwsCACQWjUbJvAIFZLt1P1O204HAmdsl7G2pzw==", - "dev": true - }, - "node_modules/@types/audio-play": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/@types/audio-play/-/audio-play-2.3.2.tgz", - "integrity": "sha512-tGQbApfao04cIIiN6GtAJFjnJsdiN1L3zL90a8BKqsTycO0XxlQ8BR436MoZIlR2fBdP0IUJdTVbDweiHLVPnQ==", - "dev": true - }, - "node_modules/@types/es-aggregate-error": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/@types/es-aggregate-error/-/es-aggregate-error-1.0.6.tgz", - "integrity": "sha512-qJ7LIFp06h1QE1aVxbVd+zJP2wdaugYXYfd6JxsyRMrYHaxb6itXPogW2tz+ylUJ1n1b+JF1PHyYCfYHm0dvUg==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, - "node_modules/@types/estree": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.6.tgz", - "integrity": "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==", - "dev": true - }, - "node_modules/@types/json-schema": { - "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", - "dev": true - }, - "node_modules/@types/markdown-escape": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@types/markdown-escape/-/markdown-escape-1.1.3.tgz", - "integrity": "sha512-JIc1+s3y5ujKnt/+N+wq6s/QdL2qZ11fP79MijrVXsAAnzSxCbT2j/3prHRouJdZ2yFLN3vkP0HytfnoCczjOw==", - "dev": true - }, - "node_modules/@types/node": { - "version": "22.9.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.9.0.tgz", - "integrity": "sha512-vuyHg81vvWA1Z1ELfvLko2c8f34gyA0zaic0+Rllc5lbCnbSyuvb2Oxpm6TAUAC/2xZN3QGqxBNggD1nNR2AfQ==", - "license": "MIT", - "dependencies": { - "undici-types": "~6.19.8" - } - }, - "node_modules/@types/node-fetch": { - "version": "2.6.11", - "resolved": "https://registry.npmjs.org/@types/node-fetch/-/node-fetch-2.6.11.tgz", - "integrity": "sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g==", - "dependencies": { - "@types/node": "*", - "form-data": "^4.0.0" - } - }, - "node_modules/@types/sarif": { - "version": "2.1.7", - "resolved": "https://registry.npmjs.org/@types/sarif/-/sarif-2.1.7.tgz", - "integrity": "sha512-kRz0VEkJqWLf1LLVN4pT1cg1Z9wAuvI6L97V3m2f5B76Tg8d413ddvLBPTEHAZJlnn4XSvu0FkZtViCQGVyrXQ==", - "dev": true - }, - "node_modules/@types/urijs": { - "version": "1.19.25", - "resolved": "https://registry.npmjs.org/@types/urijs/-/urijs-1.19.25.tgz", - "integrity": "sha512-XOfUup9r3Y06nFAZh3WvO0rBU4OtlfPB/vgxpjg+NRdGU6CN6djdc6OEiH+PcqHCY6eFLo9Ista73uarf4gnBg==", - "dev": true - }, - "node_modules/@types/uuid": { - "version": "9.0.8", - "resolved": "https://registry.npmjs.org/@types/uuid/-/uuid-9.0.8.tgz", - "integrity": "sha512-jg+97EGIcY9AGHJJRaaPVgetKDsrTgbRjQ5Msgjh/DQKEFl0DtyRr/VCOyD1T2R1MNeWPK/u7JoGhlDZnKBAfA==", - "license": "MIT" - }, - "node_modules/@ungap/structured-clone": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", - "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", - "dev": true, - "license": "ISC" - }, - "node_modules/@wasm-audio-decoders/common": { - "version": "9.0.5", - "resolved": "https://registry.npmjs.org/@wasm-audio-decoders/common/-/common-9.0.5.tgz", - "integrity": "sha512-b9JNh9sPAvn8PVIizNh9D60WkfQong/u9ea873H47u7zvVDLctxYIp2aZw9CQqXaQdk7JB3MoU5UHiseO40swg==", - "dependencies": { - "@eshaz/web-worker": "1.2.2", - "simple-yenc": "^1.0.4" - } - }, - "node_modules/@wasm-audio-decoders/flac": { - "version": "0.2.5", - "resolved": "https://registry.npmjs.org/@wasm-audio-decoders/flac/-/flac-0.2.5.tgz", - "integrity": "sha512-8M//CgB3PlkWwn47KcwD0tO6DZBA7/AGG0ukHSG0G97UbNEUNINvKDWAKPVWznzHsqeBP6axw+K/38dzng64JA==", - "dependencies": { - "@wasm-audio-decoders/common": "9.0.5", - "codec-parser": "2.5.0" - }, - "funding": { - "type": "individual", - "url": "https://github.com/sponsors/eshaz" - } - }, - "node_modules/@wasm-audio-decoders/ogg-vorbis": { - "version": "0.1.16", - "resolved": "https://registry.npmjs.org/@wasm-audio-decoders/ogg-vorbis/-/ogg-vorbis-0.1.16.tgz", - "integrity": "sha512-HcEx4LPZbbzjhs9bTXgMaXLVCSMSo/egY9paJxAnE9tsYbvseAaGtVddLYktl3Qi/G+nW/ZzUXg4144izJjqCw==", - "dependencies": { - "@wasm-audio-decoders/common": "9.0.5", - "codec-parser": "2.5.0" - }, - "funding": { - "type": "individual", - "url": "https://github.com/sponsors/eshaz" - } - }, - "node_modules/abort-controller": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz", - "integrity": "sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==", - "dependencies": { - "event-target-shim": "^5.0.0" - }, - "engines": { - "node": ">=6.5" - } - }, - "node_modules/acorn": { - "version": "8.14.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.14.0.tgz", - "integrity": "sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA==", - "dev": true, - "license": "MIT", - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/acorn-jsx": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" + "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, "node_modules/agentkeepalive": { @@ -3388,45 +2539,6 @@ "url": "https://github.com/sponsors/epoberezkin" } }, - "node_modules/ajv-formats": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz", - "integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==", - "dev": true, - "dependencies": { - "ajv": "^8.0.0" - }, - "peerDependencies": { - "ajv": "^8.0.0" - }, - "peerDependenciesMeta": { - "ajv": { - "optional": true - } - } - }, - "node_modules/ajv-formats/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ajv-formats/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, "node_modules/ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", @@ -3473,89 +2585,21 @@ "dev": true, "license": "Python-2.0" }, - "node_modules/array-buffer-byte-length": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.1.tgz", - "integrity": "sha512-ahC5W1xgou+KTXix4sAO8Ki12Q+jf4i0+tmk3sC+zgcynshkHxzpXdImBehiUYKKKDwvfFiJl1tZt6ewscS1Mg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.5", - "is-array-buffer": "^3.0.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/array-union": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", - "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/arraybuffer.prototype.slice": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.3.tgz", - "integrity": "sha512-bMxMKAjg13EBSVscxTaYA4mRc5t1UAXa2kXiGTNfZ079HIWXEkKmkgFrh/nJqamaLSrXO5H4WFFkPEaLJWbs3A==", - "dev": true, - "dependencies": { - "array-buffer-byte-length": "^1.0.1", - "call-bind": "^1.0.5", - "define-properties": "^1.2.1", - "es-abstract": "^1.22.3", - "es-errors": "^1.2.1", - "get-intrinsic": "^1.2.3", - "is-array-buffer": "^3.0.4", - "is-shared-array-buffer": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/as-table": { - "version": "1.0.55", - "resolved": "https://registry.npmjs.org/as-table/-/as-table-1.0.55.tgz", - "integrity": "sha512-xvsWESUJn0JN421Xb9MQw6AsMHRCUknCe0Wjlxvjud80mU4E6hQf1A6NzQKcYNmYw62MfzEtXc+badstZP3JpQ==", - "dev": true, - "dependencies": { - "printable-characters": "^1.0.42" - } - }, - "node_modules/ast-types": { - "version": "0.14.2", - "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.14.2.tgz", - "integrity": "sha512-O0yuUDnZeQDL+ncNGlJ78BiO4jnYI3bvMsD5prT0/nsgijG/LpNBIr63gTjVTNsiGkgQhiyCShTgxt8oXOrklA==", - "dev": true, - "dependencies": { - "tslib": "^2.0.1" - }, - "engines": { - "node": ">=4" - } - }, - "node_modules/astring": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/astring/-/astring-1.9.0.tgz", - "integrity": "sha512-LElXdjswlqjWrPpJFg1Fx4wpkOCxj1TDHlSV4PlaRxHGWko024xICaa97ZkMfs6DRKlCguiAI+rbXv5GWwXIkg==", - "dev": true, - "bin": { - "astring": "bin/astring" - } - }, "node_modules/asynckit": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" }, + "node_modules/at-least-node": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", + "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">= 4.0.0" + } + }, "node_modules/atob-lite": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/atob-lite/-/atob-lite-2.0.0.tgz", @@ -3819,30 +2863,9 @@ "resolved": "https://registry.npmjs.org/audio-type/-/audio-type-2.2.1.tgz", "integrity": "sha512-En9AY6EG1qYqEy5L/quryzbA4akBpJrnBZNxeKTqGHC2xT9Qc4aZ8b7CcbOMFTTc/MGdoNyp+SN4zInZNKxMYA==", "engines": { - "node": ">=14" - } - }, - "node_modules/available-typed-arrays": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", - "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", - "dev": true, - "dependencies": { - "possible-typed-array-names": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=14" } }, - "node_modules/backslash": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/backslash/-/backslash-0.2.0.tgz", - "integrity": "sha512-Avs+8FUZ1HF/VFP4YWwHQZSGzRPm37ukU1JQYQWijuHhtXdOuAzcZ8PcAzfIw898a8PyBzdn+RtnKA6MzW0X2A==", - "dev": true - }, "node_modules/balanced-match": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", @@ -3972,68 +2995,6 @@ "resolved": "https://registry.npmjs.org/buffer-to-arraybuffer/-/buffer-to-arraybuffer-0.0.6.tgz", "integrity": "sha512-i/ndmmCF5QC1D75QCO1EPwYRPIVRVs2yLwkl2bc8R5P1ORHGZZAbTwmYM/vpXt7KzCe+Y57E8YPGTJywgWBNRw==" }, - "node_modules/builtins": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/builtins/-/builtins-1.0.3.tgz", - "integrity": "sha512-uYBjakWipfaO/bXI7E8rq6kpwHRZK5cNYrUv2OzZSI/FvmdMyXJ2tG9dKcjEC5YHmHpUAwsargWIZNWdxb/bnQ==", - "dev": true - }, - "node_modules/c12": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/c12/-/c12-2.0.1.tgz", - "integrity": "sha512-Z4JgsKXHG37C6PYUtIxCfLJZvo6FyhHJoClwwb9ftUkLpPSkuYqn6Tr+vnaN8hymm0kIbcg6Ey3kv/Q71k5w/A==", - "dev": true, - "dependencies": { - "chokidar": "^4.0.1", - "confbox": "^0.1.7", - "defu": "^6.1.4", - "dotenv": "^16.4.5", - "giget": "^1.2.3", - "jiti": "^2.3.0", - "mlly": "^1.7.1", - "ohash": "^1.1.4", - "pathe": "^1.1.2", - "perfect-debounce": "^1.0.0", - "pkg-types": "^1.2.0", - "rc9": "^2.1.2" - }, - "peerDependencies": { - "magicast": "^0.3.5" - }, - "peerDependenciesMeta": { - "magicast": { - "optional": true - } - } - }, - "node_modules/c12/node_modules/chokidar": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.1.tgz", - "integrity": "sha512-n8enUVCED/KVRQlab1hr3MVpcVMvxtZjmEa956u+4YijlmQED223XMSYj2tLuKvr4jcCTzNNMpQDUer72MMmzA==", - "dev": true, - "dependencies": { - "readdirp": "^4.0.1" - }, - "engines": { - "node": ">= 14.16.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, - "node_modules/c12/node_modules/readdirp": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-4.0.2.tgz", - "integrity": "sha512-yDMz9g+VaZkqBYS/ozoBJwaBhTbZo3UNYQHNRw1D3UFQB8oHB4uS/tAODO+ZLjGWmUbKnIlOWO+aaIiAxrUWHA==", - "dev": true, - "engines": { - "node": ">= 14.16.0" - }, - "funding": { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - }, "node_modules/call-bind": { "version": "1.0.7", "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", @@ -4115,22 +3076,20 @@ "node": ">= 6" } }, - "node_modules/chownr": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", + "node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", "engines": { - "node": ">=10" - } - }, - "node_modules/citty": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/citty/-/citty-0.1.6.tgz", - "integrity": "sha512-tskPPKEs8D2KPafUypv2gxwJP8h/OaJmC82QQGGDQcHvXX43xF2VDACcJVmZ0EuSxkpO9Kc4MlrA3q0+FG58AQ==", - "dev": true, - "dependencies": { - "consola": "^3.2.3" + "node": ">=8" } }, "node_modules/clamp": { @@ -4138,26 +3097,6 @@ "resolved": "https://registry.npmjs.org/clamp/-/clamp-1.0.1.tgz", "integrity": "sha512-kgMuFyE78OC6Dyu3Dy7vcx4uy97EIbVxJB/B0eJ3bUNAkwdNcxYzgKltnyADiYwsR7SEqkkUPsEUT//OVS6XMA==" }, - "node_modules/cliui": { - "version": "7.0.4", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", - "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", - "dev": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.0", - "wrap-ansi": "^7.0.0" - } - }, - "node_modules/clone": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", - "integrity": "sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==", - "dev": true, - "engines": { - "node": ">=0.8" - } - }, "node_modules/codec-parser": { "version": "2.5.0", "resolved": "https://registry.npmjs.org/codec-parser/-/codec-parser-2.5.0.tgz", @@ -4231,21 +3170,6 @@ "node": ">= 0.8" } }, - "node_modules/commander": { - "version": "10.0.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz", - "integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==", - "dev": true, - "engines": { - "node": ">=14" - } - }, - "node_modules/commondir": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", - "integrity": "sha512-W9pAhw0ja1Edb5GVdIF1mjZw/ASI0AlShXM83UUGe2DVr5TdAPEA1OA8m/g8zWp9x6On7gqufY+FatDbC3MDQg==", - "dev": true - }, "node_modules/concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", @@ -4253,30 +3177,6 @@ "dev": true, "license": "MIT" }, - "node_modules/confbox": { - "version": "0.1.8", - "resolved": "https://registry.npmjs.org/confbox/-/confbox-0.1.8.tgz", - "integrity": "sha512-RMtmw0iFkeR4YV+fUOSucriAQNb9g8zFR52MWCtl+cCZOFRNL6zeB395vPzFhEjjn4fMxXudmELnl/KF/WrK6w==", - "dev": true - }, - "node_modules/consola": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/consola/-/consola-3.2.3.tgz", - "integrity": "sha512-I5qxpzLv+sJhTVEoLYNcTW+bThDCPsit0vLNKShZx6rLtpilNpmmeTPaeqJb9ZE9dV3DGaeby6Vuhrw38WjeyQ==", - "dev": true, - "engines": { - "node": "^14.18.0 || >=16.10.0" - } - }, - "node_modules/console-table-printer": { - "version": "2.12.1", - "resolved": "https://registry.npmjs.org/console-table-printer/-/console-table-printer-2.12.1.tgz", - "integrity": "sha512-wKGOQRRvdnd89pCeH96e2Fn4wkbenSP6LMHfjfyNLMbGuHEFbMqQNuxXqd0oXG9caIOQ1FTvc5Uijp9/4jujnQ==", - "dev": true, - "dependencies": { - "simple-wcswidth": "^1.0.1" - } - }, "node_modules/cross-spawn": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", @@ -4300,63 +3200,6 @@ "node": ">=0.12.0" } }, - "node_modules/data-uri-to-buffer": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/data-uri-to-buffer/-/data-uri-to-buffer-2.0.2.tgz", - "integrity": "sha512-ND9qDTLc6diwj+Xe5cdAgVTbLVdXbtxTJRXRhli8Mowuaan+0EJOtdqJ0QCHNSSPyoXGx9HX2/VMnKeC34AChA==", - "dev": true - }, - "node_modules/data-view-buffer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/data-view-buffer/-/data-view-buffer-1.0.1.tgz", - "integrity": "sha512-0lht7OugA5x3iJLOWFhWK/5ehONdprk0ISXqVFn/NFrDu+cuc8iADFrGQz5BnRK7LLU3JmkbXSxaqX+/mXYtUA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.6", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/data-view-byte-length": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/data-view-byte-length/-/data-view-byte-length-1.0.1.tgz", - "integrity": "sha512-4J7wRJD3ABAzr8wP+OcIcqq2dlUKp4DVflx++hs5h5ZKydWMI6/D/fAot+yh6g2tHh8fLFTvNOaVN357NvSrOQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/data-view-byte-offset": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/data-view-byte-offset/-/data-view-byte-offset-1.0.0.tgz", - "integrity": "sha512-t/Ygsytq+R995EJ5PZlD4Cu56sWa8InXySaViRzw9apusqsOO2bQP+SbYzAhR0pFKoB+43lYy8rWban9JSuXnA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.6", - "es-errors": "^1.3.0", - "is-data-view": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/debug": { "version": "4.3.5", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", @@ -4382,18 +3225,6 @@ "dev": true, "license": "MIT" }, - "node_modules/defaults": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz", - "integrity": "sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==", - "dev": true, - "dependencies": { - "clone": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/define-data-property": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", @@ -4410,29 +3241,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/define-properties": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", - "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", - "dev": true, - "dependencies": { - "define-data-property": "^1.0.1", - "has-property-descriptors": "^1.0.0", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/defu": { - "version": "6.1.4", - "resolved": "https://registry.npmjs.org/defu/-/defu-6.1.4.tgz", - "integrity": "sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==", - "dev": true - }, "node_modules/delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", @@ -4441,34 +3249,6 @@ "node": ">=0.4.0" } }, - "node_modules/dependency-graph": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/dependency-graph/-/dependency-graph-0.11.0.tgz", - "integrity": "sha512-JeMq7fEshyepOWDfcfHK06N3MhyPhz++vtqWhMT5O9A3K42rdsEDpfdVqjaqaAhsw6a+ZqeDvQVtD0hFHQWrzg==", - "dev": true, - "engines": { - "node": ">= 0.6.0" - } - }, - "node_modules/destr": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/destr/-/destr-2.0.3.tgz", - "integrity": "sha512-2N3BOUU4gYMpTP24s5rF5iP7BDr7uNTCs4ozw3kf/eKfvWSIu93GEBi5m427YoyJoeOzQ5smuu4nNAPGb8idSQ==", - "dev": true - }, - "node_modules/dir-glob": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", - "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", - "dev": true, - "license": "MIT", - "dependencies": { - "path-type": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/doctrine": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", @@ -4482,18 +3262,6 @@ "node": ">=6.0.0" } }, - "node_modules/dotenv": { - "version": "16.4.5", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.5.tgz", - "integrity": "sha512-ZmdL2rui+eB2YwhsWzjInR8LldtZHGDoQ1ugH85ppHKwpUHL7j7rN0Ti9NCnGiQbhaZ11FpR+7ao1dNsmduNUg==", - "dev": true, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://dotenvx.com" - } - }, "node_modules/eastasianwidth": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", @@ -4506,88 +3274,6 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, - "node_modules/es-abstract": { - "version": "1.23.3", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.23.3.tgz", - "integrity": "sha512-e+HfNH61Bj1X9/jLc5v1owaLYuHdeHHSQlkhCBiTK8rBvKaULl/beGMxwrMXjpYrv4pz22BlY570vVePA2ho4A==", - "dev": true, - "dependencies": { - "array-buffer-byte-length": "^1.0.1", - "arraybuffer.prototype.slice": "^1.0.3", - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", - "data-view-buffer": "^1.0.1", - "data-view-byte-length": "^1.0.1", - "data-view-byte-offset": "^1.0.0", - "es-define-property": "^1.0.0", - "es-errors": "^1.3.0", - "es-object-atoms": "^1.0.0", - "es-set-tostringtag": "^2.0.3", - "es-to-primitive": "^1.2.1", - "function.prototype.name": "^1.1.6", - "get-intrinsic": "^1.2.4", - "get-symbol-description": "^1.0.2", - "globalthis": "^1.0.3", - "gopd": "^1.0.1", - "has-property-descriptors": "^1.0.2", - "has-proto": "^1.0.3", - "has-symbols": "^1.0.3", - "hasown": "^2.0.2", - "internal-slot": "^1.0.7", - "is-array-buffer": "^3.0.4", - "is-callable": "^1.2.7", - "is-data-view": "^1.0.1", - "is-negative-zero": "^2.0.3", - "is-regex": "^1.1.4", - "is-shared-array-buffer": "^1.0.3", - "is-string": "^1.0.7", - "is-typed-array": "^1.1.13", - "is-weakref": "^1.0.2", - "object-inspect": "^1.13.1", - "object-keys": "^1.1.1", - "object.assign": "^4.1.5", - "regexp.prototype.flags": "^1.5.2", - "safe-array-concat": "^1.1.2", - "safe-regex-test": "^1.0.3", - "string.prototype.trim": "^1.2.9", - "string.prototype.trimend": "^1.0.8", - "string.prototype.trimstart": "^1.0.8", - "typed-array-buffer": "^1.0.2", - "typed-array-byte-length": "^1.0.1", - "typed-array-byte-offset": "^1.0.2", - "typed-array-length": "^1.0.6", - "unbox-primitive": "^1.0.2", - "which-typed-array": "^1.1.15" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/es-aggregate-error": { - "version": "1.0.13", - "resolved": "https://registry.npmjs.org/es-aggregate-error/-/es-aggregate-error-1.0.13.tgz", - "integrity": "sha512-KkzhUUuD2CUMqEc8JEqsXEMDHzDPE8RCjZeUBitsnB1eNcAJWQPiciKsMXe3Yytj4Flw1XLl46Qcf9OxvZha7A==", - "dev": true, - "dependencies": { - "define-data-property": "^1.1.4", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.2", - "es-errors": "^1.3.0", - "function-bind": "^1.1.2", - "globalthis": "^1.0.3", - "has-property-descriptors": "^1.0.2", - "set-function-name": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/es-define-property": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", @@ -4607,49 +3293,6 @@ "node": ">= 0.4" } }, - "node_modules/es-object-atoms": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.0.0.tgz", - "integrity": "sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw==", - "dev": true, - "dependencies": { - "es-errors": "^1.3.0" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-set-tostringtag": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.3.tgz", - "integrity": "sha512-3T8uNMC3OQTHkFUsFq8r/BwAXLHvU/9O9mE0fBc/MY5iq/8H7ncvO947LmYA6ldWw9Uh8Yhf25zu6n7nML5QWQ==", - "dev": true, - "dependencies": { - "get-intrinsic": "^1.2.4", - "has-tostringtag": "^1.0.2", - "hasown": "^2.0.1" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/es-to-primitive": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", - "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", - "dev": true, - "dependencies": { - "is-callable": "^1.1.4", - "is-date-object": "^1.0.1", - "is-symbol": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/esbuild": { "version": "0.23.1", "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.23.1.tgz", @@ -4689,15 +3332,6 @@ "@esbuild/win32-x64": "0.23.1" } }, - "node_modules/escalade": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", - "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, "node_modules/escape-string-regexp": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", @@ -4886,19 +3520,6 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/esprima": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", - "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", - "dev": true, - "bin": { - "esparse": "bin/esparse.js", - "esvalidate": "bin/esvalidate.js" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/esquery": { "version": "1.5.0", "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", @@ -4935,12 +3556,6 @@ "node": ">=4.0" } }, - "node_modules/estree-walker": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", - "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==", - "dev": true - }, "node_modules/esutils": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", @@ -4968,29 +3583,6 @@ "node": ">=0.8.x" } }, - "node_modules/execa": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/execa/-/execa-8.0.1.tgz", - "integrity": "sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==", - "dev": true, - "dependencies": { - "cross-spawn": "^7.0.3", - "get-stream": "^8.0.1", - "human-signals": "^5.0.0", - "is-stream": "^3.0.0", - "merge-stream": "^2.0.0", - "npm-run-path": "^5.1.0", - "onetime": "^6.0.0", - "signal-exit": "^4.1.0", - "strip-final-newline": "^3.0.0" - }, - "engines": { - "node": ">=16.17" - }, - "funding": { - "url": "https://github.com/sindresorhus/execa?sponsor=1" - } - }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -5044,22 +3636,10 @@ }, "node_modules/fast-levenshtein": { "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", - "dev": true, - "license": "MIT" - }, - "node_modules/fast-memoize": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/fast-memoize/-/fast-memoize-2.5.2.tgz", - "integrity": "sha512-Ue0LwpDYErFbmNnZSF0UH6eImUwDmogUO1jyE+JbN2gsQz/jICm1Ve7t9QT0rNSsfJt+Hs4/S3GnsDVjL4HVrw==", - "dev": true - }, - "node_modules/fast-uri": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.0.2.tgz", - "integrity": "sha512-GR6f0hD7XXyNJa25Tb9BuIdN0tdr+0BMi6/CJPH3wJO1JjNG3n/VsSw38AwRdKZABm8lGbPfakLRkYzx2V9row==", - "dev": true + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", + "dev": true, + "license": "MIT" }, "node_modules/fast-xml-parser": { "version": "4.4.1", @@ -5142,6 +3722,16 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/find-yarn-workspace-root": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/find-yarn-workspace-root/-/find-yarn-workspace-root-2.0.0.tgz", + "integrity": "sha512-1IMnbjt4KzsQfnhnzNd8wUEgXZ44IzZaZmnLYx7D5FZlaHt2gW20Cri8Q+E/t5tIj4+epTBub+2Zxu/vNILzqQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "micromatch": "^4.0.2" + } + }, "node_modules/flat-cache": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", @@ -5164,15 +3754,6 @@ "dev": true, "license": "ISC" }, - "node_modules/for-each": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", - "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", - "dev": true, - "dependencies": { - "is-callable": "^1.1.3" - } - }, "node_modules/foreground-child": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.2.1.tgz", @@ -5228,41 +3809,19 @@ } }, "node_modules/fs-extra": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", - "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==", + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", "dev": true, + "license": "MIT", "dependencies": { + "at-least-node": "^1.0.0", "graceful-fs": "^4.2.0", "jsonfile": "^6.0.1", "universalify": "^2.0.0" }, "engines": { - "node": ">=12" - } - }, - "node_modules/fs-minipass": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", - "dev": true, - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/fs-minipass/node_modules/minipass": { - "version": "3.3.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", - "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", - "dev": true, - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=8" + "node": ">=10" } }, "node_modules/fs.realpath": { @@ -5293,42 +3852,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/function.prototype.name": { - "version": "1.1.6", - "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", - "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.2.0", - "es-abstract": "^1.22.1", - "functions-have-names": "^1.2.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/functions-have-names": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", - "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true, - "engines": { - "node": "6.* || 8.* || >= 10.*" - } - }, "node_modules/get-intrinsic": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", @@ -5347,45 +3870,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/get-source": { - "version": "2.0.12", - "resolved": "https://registry.npmjs.org/get-source/-/get-source-2.0.12.tgz", - "integrity": "sha512-X5+4+iD+HoSeEED+uwrQ07BOQr0kEDFMVqqpBuI+RaZBpBpHCuXxo70bjar6f0b0u/DQJsJ7ssurpP0V60Az+w==", - "dev": true, - "dependencies": { - "data-uri-to-buffer": "^2.0.0", - "source-map": "^0.6.1" - } - }, - "node_modules/get-stream": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-8.0.1.tgz", - "integrity": "sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==", - "dev": true, - "engines": { - "node": ">=16" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/get-symbol-description": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.2.tgz", - "integrity": "sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.5", - "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/get-tsconfig": { "version": "4.7.5", "resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.7.5.tgz", @@ -5398,25 +3882,6 @@ "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" } }, - "node_modules/giget": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/giget/-/giget-1.2.3.tgz", - "integrity": "sha512-8EHPljDvs7qKykr6uw8b+lqLiUc/vUg+KVTI0uND4s63TdsZM2Xus3mflvF0DDG9SiM4RlCkFGL+7aAjRmV7KA==", - "dev": true, - "dependencies": { - "citty": "^0.1.6", - "consola": "^3.2.3", - "defu": "^6.1.4", - "node-fetch-native": "^1.6.3", - "nypm": "^0.3.8", - "ohash": "^1.1.3", - "pathe": "^1.1.2", - "tar": "^6.2.0" - }, - "bin": { - "giget": "dist/cli.mjs" - } - }, "node_modules/glob": { "version": "7.2.3", "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", @@ -5464,43 +3929,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/globalthis": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.4.tgz", - "integrity": "sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==", - "dev": true, - "dependencies": { - "define-properties": "^1.2.1", - "gopd": "^1.0.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/globby": { - "version": "11.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", - "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", - "dev": true, - "license": "MIT", - "dependencies": { - "array-union": "^2.1.0", - "dir-glob": "^3.0.1", - "fast-glob": "^3.2.9", - "ignore": "^5.2.0", - "merge2": "^1.4.1", - "slash": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/gopd": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", @@ -5516,7 +3944,8 @@ "version": "4.2.11", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/graphemer": { "version": "1.4.0", @@ -5525,36 +3954,6 @@ "dev": true, "license": "MIT" }, - "node_modules/handlebars": { - "version": "4.7.8", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.7.8.tgz", - "integrity": "sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ==", - "dev": true, - "dependencies": { - "minimist": "^1.2.5", - "neo-async": "^2.6.2", - "source-map": "^0.6.1", - "wordwrap": "^1.0.0" - }, - "bin": { - "handlebars": "bin/handlebars" - }, - "engines": { - "node": ">=0.4.7" - }, - "optionalDependencies": { - "uglify-js": "^3.1.4" - } - }, - "node_modules/has-bigints": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", - "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -5598,21 +3997,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/has-tostringtag": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", - "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", - "dev": true, - "dependencies": { - "has-symbols": "^1.0.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/hasown": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", @@ -5624,24 +4008,6 @@ "node": ">= 0.4" } }, - "node_modules/hpagent": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/hpagent/-/hpagent-1.2.0.tgz", - "integrity": "sha512-A91dYTeIB6NoXG+PxTQpCCDDnfHsW9kc06Lvpu1TEe9gnd6ZFeiBoRO9JvzEv6xK7EX97/dUE8g/vBMTqTS3CA==", - "dev": true, - "engines": { - "node": ">=14" - } - }, - "node_modules/human-signals": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-5.0.0.tgz", - "integrity": "sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==", - "dev": true, - "engines": { - "node": ">=16.17.0" - } - }, "node_modules/humanize-ms": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/humanize-ms/-/humanize-ms-1.2.1.tgz", @@ -5650,83 +4016,6 @@ "ms": "^2.0.0" } }, - "node_modules/ibm-openapi-validator": { - "version": "1.25.0", - "resolved": "https://registry.npmjs.org/ibm-openapi-validator/-/ibm-openapi-validator-1.25.0.tgz", - "integrity": "sha512-GaFmYaarnHuvnN30YWDgT5UZLt1jFNqORMgRacI1WQmu1jHlcOD0Xl1xX6ZVK1gPL4q9DNri56tFjNPSPwolmw==", - "dev": true, - "dependencies": { - "@ibm-cloud/openapi-ruleset": "1.23.2", - "@ibm-cloud/openapi-ruleset-utilities": "1.4.0", - "@stoplight/spectral-cli": "^6.13.1", - "@stoplight/spectral-core": "^1.19.1", - "@stoplight/spectral-parsers": "^1.0.4", - "@stoplight/spectral-ref-resolver": "^1.0.4", - "ajv": "^8.17.1", - "chalk": "^4.1.2", - "commander": "^10.0.1", - "console-table-printer": "^2.12.1", - "find-up": "5.0.0", - "globby": "^11.0.4", - "js-yaml": "^3.14.1", - "json-dup-key-validator": "^1.0.3", - "lodash": "^4.17.21", - "nimma": "^0.7.0", - "pad": "^2.3.0", - "semver": "^7.6.0" - }, - "bin": { - "lint-openapi": "src/cli-validator/index.js" - }, - "engines": { - "node": ">=16.0.0", - "npm": ">=8.3.0" - } - }, - "node_modules/ibm-openapi-validator/node_modules/ajv": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", - "integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==", - "dev": true, - "dependencies": { - "fast-deep-equal": "^3.1.3", - "fast-uri": "^3.0.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/ibm-openapi-validator/node_modules/argparse": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", - "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", - "dev": true, - "dependencies": { - "sprintf-js": "~1.0.2" - } - }, - "node_modules/ibm-openapi-validator/node_modules/js-yaml": { - "version": "3.14.1", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", - "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", - "dev": true, - "dependencies": { - "argparse": "^1.0.7", - "esprima": "^4.0.0" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, - "node_modules/ibm-openapi-validator/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "dev": true - }, "node_modules/ieee754": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", @@ -5757,16 +4046,6 @@ "node": ">= 4" } }, - "node_modules/immer": { - "version": "9.0.21", - "resolved": "https://registry.npmjs.org/immer/-/immer-9.0.21.tgz", - "integrity": "sha512-bc4NBHqOqSfRW7POMkHd51LvClaeMXpm8dx0e8oE2GORbq5aRK7Bxl4FyzVLdGtLmvLKL7BTDBG5ACQm4HWjTA==", - "dev": true, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/immer" - } - }, "node_modules/import-fresh": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", @@ -5810,36 +4089,6 @@ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, - "node_modules/internal-slot": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.7.tgz", - "integrity": "sha512-NGnrKwXzSms2qUUih/ILZ5JBqNTSa1+ZmP6flaIp6KmSElgE9qdndzS3cqjrDovwFdmwsGsLdeFgB6suw+1e9g==", - "dev": true, - "dependencies": { - "es-errors": "^1.3.0", - "hasown": "^2.0.0", - "side-channel": "^1.0.4" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/is-array-buffer": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.4.tgz", - "integrity": "sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "get-intrinsic": "^1.2.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-audio-buffer": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-audio-buffer/-/is-audio-buffer-1.1.0.tgz", @@ -5850,18 +4099,6 @@ "resolved": "https://registry.npmjs.org/is-base64/-/is-base64-0.1.0.tgz", "integrity": "sha512-WRRyllsGXJM7ZN7gPTCCQ/6wNPTRDwiWdPK66l5sJzcU/oOzcIcRRf0Rux8bkpox/1yjt0F6VJRsQOIG2qz5sg==" }, - "node_modules/is-bigint": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", - "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", - "dev": true, - "dependencies": { - "has-bigints": "^1.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", @@ -5874,22 +4111,6 @@ "node": ">=8" } }, - "node_modules/is-boolean-object": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", - "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-browser": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-browser/-/is-browser-2.1.0.tgz", @@ -5902,46 +4123,19 @@ "funding": [ { "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "engines": { - "node": ">=4" - } - }, - "node_modules/is-callable": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", - "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-core-module": { - "version": "2.15.1", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.15.1.tgz", - "integrity": "sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==", - "dev": true, - "dependencies": { - "hasown": "^2.0.2" - }, + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=4" } }, "node_modules/is-data-uri": { @@ -5955,34 +4149,20 @@ "node": ">=0.10.0" } }, - "node_modules/is-data-view": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-data-view/-/is-data-view-1.0.1.tgz", - "integrity": "sha512-AHkaJrsUVW6wq6JS8y3JnM/GJF/9cf+k20+iDzlSaJrinEo5+7vRiteOSwBhHRiAyQATN1AmY4hwzxJKPmYf+w==", - "dev": true, - "dependencies": { - "is-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-date-object": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", - "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "node_modules/is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" + "license": "MIT", + "bin": { + "is-docker": "cli.js" }, "engines": { - "node": ">= 0.4" + "node": ">=8" }, "funding": { - "url": "https://github.com/sponsors/ljharb" + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/is-extglob": { @@ -6017,18 +4197,6 @@ "node": ">=0.10.0" } }, - "node_modules/is-negative-zero": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.3.tgz", - "integrity": "sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -6039,21 +4207,6 @@ "node": ">=0.12.0" } }, - "node_modules/is-number-object": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", - "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", - "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-path-inside": { "version": "3.0.3", "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", @@ -6077,120 +4230,25 @@ "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.2.2.tgz", "integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==" }, - "node_modules/is-reference": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/is-reference/-/is-reference-1.2.1.tgz", - "integrity": "sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ==", - "dev": true, - "dependencies": { - "@types/estree": "*" - } - }, - "node_modules/is-regex": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", - "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-shared-array-buffer": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.3.tgz", - "integrity": "sha512-nA2hv5XIhLR3uVzDDfCIknerhx8XUKnstuOERPNNIinXG7v9u+ohXF67vxm4TPTEPU6lm61ZkwP3c9PCB97rhg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-stream": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-3.0.0.tgz", - "integrity": "sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==", - "dev": true, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/is-string": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", - "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", - "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-symbol": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", - "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", - "dev": true, - "dependencies": { - "has-symbols": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-typed-array": { - "version": "1.1.13", - "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.13.tgz", - "integrity": "sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==", + "node_modules/is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", "dev": true, + "license": "MIT", "dependencies": { - "which-typed-array": "^1.1.14" + "is-docker": "^2.0.0" }, "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/is-weakref": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", - "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" + "node": ">=8" } }, "node_modules/isarray": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/isexe": { "version": "2.0.0", @@ -6217,15 +4275,6 @@ "@pkgjs/parseargs": "^0.11.0" } }, - "node_modules/jiti": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/jiti/-/jiti-2.3.2.tgz", - "integrity": "sha512-9ZLDe7kYLCyWTAP6EIyg3B4ZuHy5W0gdy6y1rgrWrAOpTrUU+vKuKa1+OXB7MBkujyvm6a2b7i0ETHQDbgY98A==", - "dev": true, - "bin": { - "jiti": "lib/jiti-cli.mjs" - } - }, "node_modules/js-base64": { "version": "3.7.2", "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.2.tgz", @@ -6245,15 +4294,6 @@ "js-yaml": "bin/js-yaml.js" } }, - "node_modules/jsep": { - "version": "1.3.9", - "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", - "integrity": "sha512-i1rBX5N7VPl0eYb6+mHNp52sEuaS2Wi8CDYx1X5sn9naevL78+265XJqy1qENEk7mRKwS06NHpUqiBwR7qeodw==", - "dev": true, - "engines": { - "node": ">= 10.16.0" - } - }, "node_modules/json-buffer": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", @@ -6261,13 +4301,28 @@ "dev": true, "license": "MIT" }, - "node_modules/json-dup-key-validator": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/json-dup-key-validator/-/json-dup-key-validator-1.0.3.tgz", - "integrity": "sha512-JvJcV01JSiO7LRz7DY1Fpzn4wX2rJ3dfNTiAfnlvLNdhhnm0Pgdvhi2SGpENrZn7eSg26Ps3TPhOcuD/a4STXQ==", + "node_modules/json-schema-to-typescript": { + "version": "15.0.3", + "resolved": "https://registry.npmjs.org/json-schema-to-typescript/-/json-schema-to-typescript-15.0.3.tgz", + "integrity": "sha512-iOKdzTUWEVM4nlxpFudFsWyUiu/Jakkga4OZPEt7CGoSEsAsUgdOZqR6pcgx2STBek9Gm4hcarJpXSzIvZ/hKA==", "dev": true, + "license": "MIT", "dependencies": { - "backslash": "^0.2.0" + "@apidevtools/json-schema-ref-parser": "^11.5.5", + "@types/json-schema": "^7.0.15", + "@types/lodash": "^4.17.7", + "is-glob": "^4.0.3", + "js-yaml": "^4.1.0", + "lodash": "^4.17.21", + "minimist": "^1.2.8", + "prettier": "^3.2.5", + "tinyglobby": "^0.2.9" + }, + "bin": { + "json2ts": "dist/src/cli.js" + }, + "engines": { + "node": ">=16.0.0" } }, "node_modules/json-schema-traverse": { @@ -6277,6 +4332,25 @@ "dev": true, "license": "MIT" }, + "node_modules/json-stable-stringify": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.1.1.tgz", + "integrity": "sha512-SU/971Kt5qVQfJpyDveVhQ/vya+5hvrjClFOcr8c0Fq5aODJjMwutrOfCU+eCnVD5gpx1Q3fEqkyom77zH1iIg==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.5", + "isarray": "^2.0.5", + "jsonify": "^0.0.1", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/json-stable-stringify-without-jsonify": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", @@ -6284,17 +4358,12 @@ "dev": true, "license": "MIT" }, - "node_modules/jsonc-parser": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-2.2.1.tgz", - "integrity": "sha512-o6/yDBYccGvTz1+QFevz6l6OBZ2+fMVu2JZ9CIhzsYRX4mjaK5IyX9eldUdCmga16zlgQxyrj5pt9kzuj2C02w==", - "dev": true - }, "node_modules/jsonfile": { "version": "6.1.0", "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", "dev": true, + "license": "MIT", "dependencies": { "universalify": "^2.0.0" }, @@ -6302,22 +4371,14 @@ "graceful-fs": "^4.1.6" } }, - "node_modules/jsonpath-plus": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-7.1.0.tgz", - "integrity": "sha512-gTaNRsPWO/K2KY6MrqaUFClF9kmuM6MFH5Dhg1VYDODgFbByw1yb7xu3hrViE/sz+dGOeMWgCzwUwQtAnCTE9g==", - "dev": true, - "engines": { - "node": ">=12.0.0" - } - }, - "node_modules/jsonpointer": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/jsonpointer/-/jsonpointer-5.0.1.tgz", - "integrity": "sha512-p/nXbhSEcu3pZRdkW1OfJhpsVtW1gd4Wa1fnQc9YLiTfAjn0312eMKimbdIQzuZl9aa9xUGaRlP9T/CJE/ditQ==", + "node_modules/jsonify": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.1.tgz", + "integrity": "sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==", "dev": true, - "engines": { - "node": ">=0.10.0" + "license": "Public Domain", + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/keyv": { @@ -6330,13 +4391,14 @@ "json-buffer": "3.0.1" } }, - "node_modules/leven": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", - "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "node_modules/klaw-sync": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/klaw-sync/-/klaw-sync-6.0.0.tgz", + "integrity": "sha512-nIeuVSzdCCs6TDPTqI8w1Yre34sSq7AkZ4B3sfOBbI2CgVSB4Du4aLQijFU2+lhAFCwt9+42Hel6lQNIv6AntQ==", "dev": true, - "engines": { - "node": ">=6" + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.1.11" } }, "node_modules/levn": { @@ -6382,31 +4444,6 @@ "dev": true, "license": "MIT" }, - "node_modules/lodash.topath": { - "version": "4.5.2", - "resolved": "https://registry.npmjs.org/lodash.topath/-/lodash.topath-4.5.2.tgz", - "integrity": "sha512-1/W4dM+35DwvE/iEd1M9ekewOSTlpFekhw9mhAtrwjVqUr83/ilQiyAvmg4tVX7Unkcfl1KC+i9WdaT4B6aQcg==", - "dev": true - }, - "node_modules/loglevel": { - "version": "1.9.2", - "resolved": "https://registry.npmjs.org/loglevel/-/loglevel-1.9.2.tgz", - "integrity": "sha512-HgMmCqIJSAKqo68l0rS2AanEWfkxaZ5wNiEFb5ggm08lDs9Xl2KxBlX3PTcaD2chBM1gXAYf491/M2Rv8Jwayg==", - "dev": true, - "engines": { - "node": ">= 0.6.0" - }, - "funding": { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/loglevel" - } - }, - "node_modules/loglevel-plugin-prefix": { - "version": "0.8.4", - "resolved": "https://registry.npmjs.org/loglevel-plugin-prefix/-/loglevel-plugin-prefix-0.8.4.tgz", - "integrity": "sha512-WpG9CcFAOjz/FtNht+QJeGpvVl/cdR6P0z6OcXSkr8wFJOsV2GRj2j10JLfjuA4aYkcKCNIEqRGCyTife9R8/g==", - "dev": true - }, "node_modules/lru-cache": { "version": "11.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.0.0.tgz", @@ -6416,27 +4453,6 @@ "node": "20 || >=22" } }, - "node_modules/magic-string": { - "version": "0.25.9", - "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.9.tgz", - "integrity": "sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ==", - "dev": true, - "dependencies": { - "sourcemap-codec": "^1.4.8" - } - }, - "node_modules/markdown-escape": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/markdown-escape/-/markdown-escape-2.0.0.tgz", - "integrity": "sha512-Trz4v0+XWlwy68LJIyw3bLbsJiC8XAbRCKF9DbEtZjyndKOGVx6n+wNB0VfoRmY2LKboQLeniap3xrb6LGSJ8A==", - "dev": true - }, - "node_modules/merge-stream": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", - "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", - "dev": true - }, "node_modules/merge2": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", @@ -6480,18 +4496,6 @@ "node": ">= 0.6" } }, - "node_modules/mimic-fn": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-4.0.0.tgz", - "integrity": "sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==", - "dev": true, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/minimatch": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", @@ -6506,70 +4510,12 @@ } }, "node_modules/minimist": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", - "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/minipass": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", - "integrity": "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/minizlib": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", - "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", - "dev": true, - "dependencies": { - "minipass": "^3.0.0", - "yallist": "^4.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/minizlib/node_modules/minipass": { - "version": "3.3.6", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", - "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", - "dev": true, - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "dev": true, - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/mlly": { - "version": "1.7.2", - "resolved": "https://registry.npmjs.org/mlly/-/mlly-1.7.2.tgz", - "integrity": "sha512-tN3dvVHYVz4DhSXinXIk7u9syPYaJvio118uomkovAtWBT+RdbP6Lfh/5Lvo519YMmwBafwlh20IPTXIStscpA==", + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", "dev": true, - "dependencies": { - "acorn": "^8.12.1", - "pathe": "^1.1.2", - "pkg-types": "^1.2.0", - "ufo": "^1.5.4" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/mpg123-decoder": { @@ -6613,24 +4559,6 @@ "node": ">=4" } }, - "node_modules/neo-async": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", - "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", - "dev": true - }, - "node_modules/nimma": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/nimma/-/nimma-0.7.0.tgz", - "integrity": "sha512-Q2883SBl8RiCsQSzoK8efH+ByD8KArcU7CNNXtkWf0VVLT7ECXbsL7uM/YcrQ49l17m6UxqmvGa6sVUwfnP+9A==", - "dev": true, - "dependencies": { - "astring": "^1.8.6" - }, - "engines": { - "node": ">=18" - } - }, "node_modules/node-domexception": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/node-domexception/-/node-domexception-1.0.0.tgz", @@ -6668,25 +4596,6 @@ } } }, - "node_modules/node-fetch-native": { - "version": "1.6.4", - "resolved": "https://registry.npmjs.org/node-fetch-native/-/node-fetch-native-1.6.4.tgz", - "integrity": "sha512-IhOigYzAKHd244OC0JIMIUrjzctirCmPkaIfhDeGcEETWof5zKYUW7e7MYvChGWh/4CJeXEgsRyGzuF334rOOQ==", - "dev": true - }, - "node_modules/node-sarif-builder": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/node-sarif-builder/-/node-sarif-builder-2.0.3.tgz", - "integrity": "sha512-Pzr3rol8fvhG/oJjIq2NTVB0vmdNNlz22FENhhPojYRZ4/ee08CfK4YuKmuL54V9MLhI1kpzxfOJ/63LzmZzDg==", - "dev": true, - "dependencies": { - "@types/sarif": "^2.1.4", - "fs-extra": "^10.0.0" - }, - "engines": { - "node": ">=14" - } - }, "node_modules/node-wav": { "version": "0.0.2", "resolved": "https://registry.npmjs.org/node-wav/-/node-wav-0.0.2.tgz", @@ -6704,53 +4613,6 @@ "node": ">=0.10.0" } }, - "node_modules/npm-run-path": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-5.3.0.tgz", - "integrity": "sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==", - "dev": true, - "dependencies": { - "path-key": "^4.0.0" - }, - "engines": { - "node": "^12.20.0 || ^14.13.1 || >=16.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/npm-run-path/node_modules/path-key": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-4.0.0.tgz", - "integrity": "sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==", - "dev": true, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/nypm": { - "version": "0.3.12", - "resolved": "https://registry.npmjs.org/nypm/-/nypm-0.3.12.tgz", - "integrity": "sha512-D3pzNDWIvgA+7IORhD/IuWzEk4uXv6GsgOxiid4UU3h9oq5IqV1KtPDi63n4sZJ/xcWlr88c0QM2RgN5VbOhFA==", - "dev": true, - "dependencies": { - "citty": "^0.1.6", - "consola": "^3.2.3", - "execa": "^8.0.1", - "pathe": "^1.1.2", - "pkg-types": "^1.2.0", - "ufo": "^1.5.4" - }, - "bin": { - "nypm": "dist/cli.mjs" - }, - "engines": { - "node": "^14.16.0 || >=16.10.0" - } - }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", @@ -6775,28 +4637,11 @@ "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.4" } }, - "node_modules/object.assign": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.5.tgz", - "integrity": "sha512-byy+U7gp+FVwmyzKPYhW2h5l3crpmGsxl7X2s8y43IgxvG4g3QZ6CffDtsNQy1WsmZpQbO+ybo0AlW7TY6DcBQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.5", - "define-properties": "^1.2.1", - "has-symbols": "^1.0.3", - "object-keys": "^1.1.1" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/ogg-opus-decoder": { "version": "1.6.13", "resolved": "https://registry.npmjs.org/ogg-opus-decoder/-/ogg-opus-decoder-1.6.13.tgz", @@ -6811,12 +4656,6 @@ "url": "https://github.com/sponsors/eshaz" } }, - "node_modules/ohash": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/ohash/-/ohash-1.1.4.tgz", - "integrity": "sha512-FlDryZAahJmEF3VR3w1KogSEdWX3WhA5GPakFx4J81kEAiHyLMpdLLElS8n8dfNadMgAne/MywcvmogzscVt4g==", - "dev": true - }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -6826,16 +4665,18 @@ "wrappy": "1" } }, - "node_modules/onetime": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-6.0.0.tgz", - "integrity": "sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==", + "node_modules/open": { + "version": "7.4.2", + "resolved": "https://registry.npmjs.org/open/-/open-7.4.2.tgz", + "integrity": "sha512-MVHddDVweXZF3awtlAS+6pgKLlm/JgxZ90+/NBurBoQctVOOB/zDdVjcyPzQ+0laDGbsWgrRkflI65sQeOgT9Q==", "dev": true, + "license": "MIT", "dependencies": { - "mimic-fn": "^4.0.0" + "is-docker": "^2.0.0", + "is-wsl": "^2.1.1" }, "engines": { - "node": ">=12" + "node": ">=8" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" @@ -6910,6 +4751,16 @@ "url": "https://github.com/sponsors/eshaz" } }, + "node_modules/os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/p-limit": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", @@ -6948,18 +4799,6 @@ "integrity": "sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw==", "dev": true }, - "node_modules/pad": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/pad/-/pad-2.3.0.tgz", - "integrity": "sha512-lxrgnOG5AXmzMRT1O5urWtYFxHnFSE+QntgTHij1nvS4W+ubhQLmQRHmZXDeEvk9I00itAixLqU9Q6fE0gW3sw==", - "dev": true, - "dependencies": { - "wcwidth": "^1.0.1" - }, - "engines": { - "node": ">= 4.0.0" - } - }, "node_modules/parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", @@ -6973,6 +4812,51 @@ "node": ">=6" } }, + "node_modules/patch-package": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/patch-package/-/patch-package-8.0.0.tgz", + "integrity": "sha512-da8BVIhzjtgScwDJ2TtKsfT5JFWz1hYoBl9rUQ1f38MC2HwnEIkK8VN3dKMKcP7P7bvvgzNDbfNHtx3MsQb5vA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@yarnpkg/lockfile": "^1.1.0", + "chalk": "^4.1.2", + "ci-info": "^3.7.0", + "cross-spawn": "^7.0.3", + "find-yarn-workspace-root": "^2.0.0", + "fs-extra": "^9.0.0", + "json-stable-stringify": "^1.0.2", + "klaw-sync": "^6.0.0", + "minimist": "^1.2.6", + "open": "^7.4.2", + "rimraf": "^2.6.3", + "semver": "^7.5.3", + "slash": "^2.0.0", + "tmp": "^0.0.33", + "yaml": "^2.2.2" + }, + "bin": { + "patch-package": "index.js" + }, + "engines": { + "node": ">=14", + "npm": ">5" + } + }, + "node_modules/patch-package/node_modules/rimraf": { + "version": "2.7.1", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", + "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", + "deprecated": "Rimraf versions prior to v4 are no longer supported", + "dev": true, + "license": "ISC", + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + } + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -7002,12 +4886,6 @@ "node": ">=8" } }, - "node_modules/path-parse": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", - "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", - "dev": true - }, "node_modules/path-scurry": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-2.0.0.tgz", @@ -7033,22 +4911,6 @@ "node": ">=16 || 14 >=14.17" } }, - "node_modules/path-type": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", - "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/pathe": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-1.1.2.tgz", - "integrity": "sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==", - "dev": true - }, "node_modules/pcm-convert": { "version": "1.6.5", "resolved": "https://registry.npmjs.org/pcm-convert/-/pcm-convert-1.6.5.tgz", @@ -7096,12 +4958,6 @@ "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" }, - "node_modules/perfect-debounce": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/perfect-debounce/-/perfect-debounce-1.0.0.tgz", - "integrity": "sha512-xCy9V055GLEqoFaHoC1SoLIaLmWctgCUaBaWxDZ7/Zx4CTyX7cJQLJOok/orfjZAh9kEYpjJa4d0KcJmCbctZA==", - "dev": true - }, "node_modules/performance-now": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", @@ -7125,17 +4981,6 @@ "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/pkg-types": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pkg-types/-/pkg-types-1.2.0.tgz", - "integrity": "sha512-+ifYuSSqOQ8CqP4MbZA5hDpb97n3E8SVWdJe+Wms9kj745lmd3b7EZJiqvmLwAlmRfjrI7Hi5z3kdBJ93lFNPA==", - "dev": true, - "dependencies": { - "confbox": "^0.1.7", - "mlly": "^1.7.1", - "pathe": "^1.1.2" - } - }, "node_modules/polite-json": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/polite-json/-/polite-json-5.0.0.tgz", @@ -7148,24 +4993,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/pony-cause": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/pony-cause/-/pony-cause-1.1.1.tgz", - "integrity": "sha512-PxkIc/2ZpLiEzQXu5YRDOUgBlfGYBY8156HY5ZcRAwwonMk5W/MrJP2LLkG/hF7GEQzaHo2aS7ho6ZLCOvf+6g==", - "dev": true, - "engines": { - "node": ">=12.0.0" - } - }, - "node_modules/possible-typed-array-names": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.0.0.tgz", - "integrity": "sha512-d7Uw+eZoloe0EHDIYoe+bQ5WXnGMOpmiZFTuMWCwpjzzkL2nTjcKiAk4hh8TjnGye2TwWOk3UXucZ+3rbmBa8Q==", - "dev": true, - "engines": { - "node": ">= 0.4" - } - }, "node_modules/prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -7204,12 +5031,6 @@ "node": ">=6.0.0" } }, - "node_modules/printable-characters": { - "version": "1.0.42", - "resolved": "https://registry.npmjs.org/printable-characters/-/printable-characters-1.0.42.tgz", - "integrity": "sha512-dKp+C4iXWK4vVYZmYSd0KBH5F/h1HoZRsbJ82AVKRO3PEo8L4lBS/vLwhVtpwwuYcoIsVY+1JYKR268yn480uQ==", - "dev": true - }, "node_modules/process": { "version": "0.11.10", "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", @@ -7278,16 +5099,6 @@ ], "license": "MIT" }, - "node_modules/rc9": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/rc9/-/rc9-2.1.2.tgz", - "integrity": "sha512-btXCnMmRIBINM2LDZoEmOogIZU7Qe7zn4BpomSKZ/ykbLObuBdvG+mFq11DL6fjH1DRwHhrlgtYWG96bJiC7Cg==", - "dev": true, - "dependencies": { - "defu": "^6.1.4", - "destr": "^2.0.3" - } - }, "node_modules/readable-stream": { "version": "4.5.2", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-4.5.2.tgz", @@ -7316,68 +5127,6 @@ "node": ">=8.10.0" } }, - "node_modules/regexp.prototype.flags": { - "version": "1.5.3", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.3.tgz", - "integrity": "sha512-vqlC04+RQoFalODCbCumG2xIOvapzVMHwsyIGM/SIE8fRhFFsXeH8/QQ+s0T0kDAhKc4k30s73/0ydkHQz6HlQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-errors": "^1.3.0", - "set-function-name": "^2.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/require-from-string": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", - "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/reserved": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/reserved/-/reserved-0.1.2.tgz", - "integrity": "sha512-/qO54MWj5L8WCBP9/UNe2iefJc+L9yETbH32xO/ft/EYPOTCR5k+azvDUgdCOKwZH8hXwPd0b8XBL78Nn2U69g==", - "dev": true, - "engines": { - "node": ">=0.8" - } - }, - "node_modules/resolve": { - "version": "1.22.8", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", - "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", - "dev": true, - "dependencies": { - "is-core-module": "^2.13.0", - "path-parse": "^1.0.7", - "supports-preserve-symlinks-flag": "^1.0.0" - }, - "bin": { - "resolve": "bin/resolve" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/resolve-from": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", @@ -7497,21 +5246,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/rollup": { - "version": "2.79.2", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.79.2.tgz", - "integrity": "sha512-fS6iqSPZDs3dr/y7Od6y5nha8dW1YnbgtsyotCVvoFGKbERG++CVRFv1meyGDE1SNItQA8BrnCw7ScdAhRJ3XQ==", - "dev": true, - "bin": { - "rollup": "dist/bin/rollup" - }, - "engines": { - "node": ">=10.0.0" - }, - "optionalDependencies": { - "fsevents": "~2.3.2" - } - }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -7536,24 +5270,6 @@ "queue-microtask": "^1.2.2" } }, - "node_modules/safe-array-concat": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.2.tgz", - "integrity": "sha512-vj6RsCsWBCf19jIeHEfkRMw8DPiBb+DMXklQ/1SGDHOMlHdPUkZXFQ2YdplS23zESTijAcurb1aSgJA3AgMu1Q==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "get-intrinsic": "^1.2.4", - "has-symbols": "^1.0.3", - "isarray": "^2.0.5" - }, - "engines": { - "node": ">=0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -7574,29 +5290,6 @@ ], "license": "MIT" }, - "node_modules/safe-regex-test": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.3.tgz", - "integrity": "sha512-CdASjNJPvRa7roO6Ra/gLYBTzYzzPyyBXxIMdGW3USQLyjWEls2RgW5UBTXaQVp+OrpeCK3bLem8smtmheoRuw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.6", - "es-errors": "^1.3.0", - "is-regex": "^1.1.4" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/safe-stable-stringify": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/safe-stable-stringify/-/safe-stable-stringify-1.1.1.tgz", - "integrity": "sha512-ERq4hUjKDbJfE4+XtZLFPCDi8Vb1JqaxAPTxWFLBx8XcAlf9Bda/ZJdVezs/NAfsMQScyIlUMx+Yeu7P7rx5jw==", - "dev": true - }, "node_modules/sample-rate": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/sample-rate/-/sample-rate-2.0.1.tgz", @@ -7631,21 +5324,6 @@ "node": ">= 0.4" } }, - "node_modules/set-function-name": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.2.tgz", - "integrity": "sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==", - "dev": true, - "dependencies": { - "define-data-property": "^1.1.4", - "es-errors": "^1.3.0", - "functions-have-names": "^1.2.3", - "has-property-descriptors": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - } - }, "node_modules/shebang-command": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", @@ -7698,24 +5376,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/simple-eval": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/simple-eval/-/simple-eval-1.0.0.tgz", - "integrity": "sha512-kpKJR+bqTscgC0xuAl2xHN6bB12lHjC2DCUfqjAx19bQyO3R2EVLOurm3H9AUltv/uFVcSCVNc6faegR+8NYLw==", - "dev": true, - "dependencies": { - "jsep": "^1.1.2" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/simple-wcswidth": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/simple-wcswidth/-/simple-wcswidth-1.0.1.tgz", - "integrity": "sha512-xMO/8eNREtaROt7tJvWJqHBDTMFN4eiQ5I4JRMuilwfnFcV5W9u7RUkueNkdw0jPqGMX36iCywelS5yilTuOxg==", - "dev": true - }, "node_modules/simple-yenc": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/simple-yenc/-/simple-yenc-1.0.4.tgz", @@ -7726,31 +5386,15 @@ } }, "node_modules/slash": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", - "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-2.0.0.tgz", + "integrity": "sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==", "dev": true, + "license": "MIT", "engines": { - "node": ">=0.10.0" + "node": ">=6" } }, - "node_modules/sourcemap-codec": { - "version": "1.4.8", - "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", - "integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==", - "deprecated": "Please use @jridgewell/sourcemap-codec instead", - "dev": true - }, "node_modules/speaker": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/speaker/-/speaker-0.5.5.tgz", @@ -7766,22 +5410,6 @@ "node": ">=8.6" } }, - "node_modules/sprintf-js": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", - "dev": true - }, - "node_modules/stacktracey": { - "version": "2.1.8", - "resolved": "https://registry.npmjs.org/stacktracey/-/stacktracey-2.1.8.tgz", - "integrity": "sha512-Kpij9riA+UNg7TnphqjH7/CzctQ/owJGNbFkfEeve4Z4uxT5+JapVLFXcsurIfN34gnTWZNJ/f7NMG0E8JDzTw==", - "dev": true, - "dependencies": { - "as-table": "^1.0.36", - "get-source": "^2.0.12" - } - }, "node_modules/string_decoder": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", @@ -7829,55 +5457,6 @@ "node": ">=8" } }, - "node_modules/string.prototype.trim": { - "version": "1.2.9", - "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.9.tgz", - "integrity": "sha512-klHuCNxiMZ8MlsOihJhJEBJAiMVqU3Z2nEXWfWnIqjN0gEFS9J9+IxKozWWtQGcgoa1WUZzLjKPTr4ZHNFTFxw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-abstract": "^1.23.0", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/string.prototype.trimend": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.8.tgz", - "integrity": "sha512-p73uL5VCHCO2BZZ6krwwQE3kCzM7NKmis8S//xEC6fQonchbum4eP6kR4DLEjQFO3Wnj3Fuo8NM0kOSjVdHjZQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/string.prototype.trimstart": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.8.tgz", - "integrity": "sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "define-properties": "^1.2.1", - "es-object-atoms": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/strip-ansi": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", @@ -7904,18 +5483,6 @@ "node": ">=8" } }, - "node_modules/strip-final-newline": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-3.0.0.tgz", - "integrity": "sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==", - "dev": true, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/strip-json-comments": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", @@ -7948,18 +5515,6 @@ "node": ">=8" } }, - "node_modules/supports-preserve-symlinks-flag": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", - "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", - "dev": true, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/sync-content": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/sync-content/-/sync-content-2.0.1.tgz", @@ -8089,29 +5644,67 @@ "url": "https://opencollective.com/unts" } }, - "node_modules/tar": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.2.1.tgz", - "integrity": "sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==", + "node_modules/text-table": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", + "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", + "dev": true, + "license": "MIT" + }, + "node_modules/tinyglobby": { + "version": "0.2.10", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.10.tgz", + "integrity": "sha512-Zc+8eJlFMvgatPZTl6A9L/yht8QqdmUNtURHaKZLmKBE12hNPSrqNkUp2cs3M/UKmNVVAMFQYSjYIVHDjW5zew==", "dev": true, + "license": "MIT", "dependencies": { - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "minipass": "^5.0.0", - "minizlib": "^2.1.1", - "mkdirp": "^1.0.3", - "yallist": "^4.0.0" + "fdir": "^6.4.2", + "picomatch": "^4.0.2" }, "engines": { - "node": ">=10" + "node": ">=12.0.0" } }, - "node_modules/text-table": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", + "node_modules/tinyglobby/node_modules/fdir": { + "version": "6.4.2", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.2.tgz", + "integrity": "sha512-KnhMXsKSPZlAhp7+IjUkRZKPb4fUyccpDrdFXbi4QL1qkmFh9kVY09Yox+n4MaOb3lHZ1Tv829C3oaaXoMYPDQ==", "dev": true, - "license": "MIT" + "license": "MIT", + "peerDependencies": { + "picomatch": "^3 || ^4" + }, + "peerDependenciesMeta": { + "picomatch": { + "optional": true + } + } + }, + "node_modules/tinyglobby/node_modules/picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/tmp": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.0.33.tgz", + "integrity": "sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==", + "dev": true, + "license": "MIT", + "dependencies": { + "os-tmpdir": "~1.0.2" + }, + "engines": { + "node": ">=0.6.0" + } }, "node_modules/to-array-buffer": { "version": "1.2.4", @@ -8337,79 +5930,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/typed-array-buffer": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.2.tgz", - "integrity": "sha512-gEymJYKZtKXzzBzM4jqa9w6Q1Jjm7x2d+sh19AdsD4wqnMPDYyvwpsIc2Q/835kHuo3BEQ7CjelGhfTsoBb2MQ==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "es-errors": "^1.3.0", - "is-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - } - }, - "node_modules/typed-array-byte-length": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.1.tgz", - "integrity": "sha512-3iMJ9q0ao7WE9tWcaYKIptkNBuOIcZCCT0d4MRvuuH88fEoEH62IuQe0OtraD3ebQEoTRk8XCBoknUNc1Y67pw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-proto": "^1.0.3", - "is-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typed-array-byte-offset": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.2.tgz", - "integrity": "sha512-Ous0vodHa56FviZucS2E63zkgtgrACj7omjwd/8lTEMEPFFyjfixMZ1ZXenpgCFBBt4EC1J2XsyVS2gkG0eTFA==", - "dev": true, - "dependencies": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", - "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-proto": "^1.0.3", - "is-typed-array": "^1.1.13" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/typed-array-length": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.6.tgz", - "integrity": "sha512-/OxDN6OtAk5KBpGb28T+HZc2M+ADtvRxXrKKbUwtsLgdoxgX13hyy7ek6bFRl5+aBs2yZzB0c4CnQfAtVypW/g==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.7", - "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-proto": "^1.0.3", - "is-typed-array": "^1.1.13", - "possible-typed-array-names": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/typedarray-methods": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/typedarray-methods/-/typedarray-methods-1.0.1.tgz", @@ -8668,40 +6188,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/ufo": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/ufo/-/ufo-1.5.4.tgz", - "integrity": "sha512-UsUk3byDzKd04EyoZ7U4DOlxQaD14JUKQl6/P7wiX4FNvUfm3XL246n9W5AmqwW5RSFJ27NAuM0iLscAOYUiGQ==", - "dev": true - }, - "node_modules/uglify-js": { - "version": "3.18.0", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.18.0.tgz", - "integrity": "sha512-SyVVbcNBCk0dzr9XL/R/ySrmYf0s372K6/hFklzgcp2lBFyXtw4I7BOdDjlLhE1aVqaI/SHWXWmYdlZxuyF38A==", - "dev": true, - "optional": true, - "bin": { - "uglifyjs": "bin/uglifyjs" - }, - "engines": { - "node": ">=0.8.0" - } - }, - "node_modules/unbox-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", - "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-bigints": "^1.0.2", - "has-symbols": "^1.0.3", - "which-boxed-primitive": "^1.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/undici-types": { "version": "6.19.8", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", @@ -8712,6 +6198,7 @@ "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", "dev": true, + "license": "MIT", "engines": { "node": ">= 10.0.0" } @@ -8726,27 +6213,12 @@ "punycode": "^2.1.0" } }, - "node_modules/urijs": { - "version": "1.19.11", - "resolved": "https://registry.npmjs.org/urijs/-/urijs-1.19.11.tgz", - "integrity": "sha512-HXgFDgDommxn5/bIv0cnQZsPhHDA90NPHD6+c/v21U5+Sx5hoP8+dP9IZXBU1gIfvdRfhG8cel9QNPeionfcCQ==", - "dev": true - }, "node_modules/url-join": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/url-join/-/url-join-4.0.1.tgz", "integrity": "sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA==", "license": "MIT" }, - "node_modules/utility-types": { - "version": "3.11.0", - "resolved": "https://registry.npmjs.org/utility-types/-/utility-types-3.11.0.tgz", - "integrity": "sha512-6Z7Ma2aVEWisaL6TvBCy7P8rm2LQoPv6dJ7ecIaIixHcwfbJ0x7mWdbcwlIM5IGQxPZSFYeqRCqlOOeKoJYMkw==", - "dev": true, - "engines": { - "node": ">= 4" - } - }, "node_modules/uuid": { "version": "9.0.1", "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", @@ -8760,24 +6232,6 @@ "uuid": "dist/bin/uuid" } }, - "node_modules/validate-npm-package-name": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/validate-npm-package-name/-/validate-npm-package-name-3.0.0.tgz", - "integrity": "sha512-M6w37eVCMMouJ9V/sdPGnC5H4uDr73/+xdq0FBLO3TFFX1+7wiUY6Es328NN+y43tmY+doUdN9g9J21vqB7iLw==", - "dev": true, - "dependencies": { - "builtins": "^1.0.3" - } - }, - "node_modules/validator": { - "version": "13.12.0", - "resolved": "https://registry.npmjs.org/validator/-/validator-13.12.0.tgz", - "integrity": "sha512-c1Q0mCiPlgdTVVVIJIrBuxNicYE+t/7oKeI9MWLj3fh/uq2Pxh/3eeWbVZ4OcGW1TUf53At0njHw5SMdA3tmMg==", - "dev": true, - "engines": { - "node": ">= 0.10" - } - }, "node_modules/walk-up-path": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/walk-up-path/-/walk-up-path-4.0.0.tgz", @@ -8787,15 +6241,6 @@ "node": "20 || >=22" } }, - "node_modules/wcwidth": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", - "integrity": "sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==", - "dev": true, - "dependencies": { - "defaults": "^1.0.3" - } - }, "node_modules/web-audio-stream": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/web-audio-stream/-/web-audio-stream-3.0.1.tgz", @@ -8876,41 +6321,6 @@ "node": ">= 8" } }, - "node_modules/which-boxed-primitive": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", - "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", - "dev": true, - "dependencies": { - "is-bigint": "^1.0.1", - "is-boolean-object": "^1.1.0", - "is-number-object": "^1.0.4", - "is-string": "^1.0.5", - "is-symbol": "^1.0.3" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, - "node_modules/which-typed-array": { - "version": "1.1.15", - "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.15.tgz", - "integrity": "sha512-oV0jmFtUky6CXfkqehVvBP/LSWJ2sy4vWMioiENyJLePrBO/yKyV9OyJySfAKosh+RYkIl5zJCNZ8/4JncrpdA==", - "dev": true, - "dependencies": { - "available-typed-arrays": "^1.0.7", - "call-bind": "^1.0.7", - "for-each": "^0.3.3", - "gopd": "^1.0.1", - "has-tostringtag": "^1.0.2" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/word-wrap": { "version": "1.2.5", "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", @@ -8921,29 +6331,6 @@ "node": ">=0.10.0" } }, - "node_modules/wordwrap": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", - "integrity": "sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==", - "dev": true - }, - "node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, "node_modules/wrap-ansi-cjs": { "name": "wrap-ansi", "version": "7.0.0", @@ -8977,60 +6364,17 @@ "node": ">=0.4" } }, - "node_modules/y18n": { - "version": "5.0.8", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", - "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", - "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, - "node_modules/yargs": { - "version": "17.7.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", - "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", - "dev": true, - "dependencies": { - "cliui": "^8.0.1", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.3", - "y18n": "^5.0.5", - "yargs-parser": "^21.1.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs-parser": { - "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", - "dev": true, - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs/node_modules/cliui": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", + "node_modules/yaml": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.6.1.tgz", + "integrity": "sha512-7r0XPzioN/Q9kXBro/XPnA6kznR73DHq+GXh5ON7ZozRO6aMjbmiBuKste2wslTFkC5d1dw0GooOCepZXJ2SAg==", "dev": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.1", - "wrap-ansi": "^7.0.0" + "license": "ISC", + "bin": { + "yaml": "bin.mjs" }, "engines": { - "node": ">=12" + "node": ">= 14" } }, "node_modules/yocto-queue": { diff --git a/package.json b/package.json index 8087386..4e848a8 100644 --- a/package.json +++ b/package.json @@ -5,11 +5,10 @@ ], "scripts": { "format": "prettier --write .", - "lint:schema": "lint-openapi schemas/openapi.json" + "postinstall": "patch-package" }, "devDependencies": { "@eslint/js": "^9.14.0", - "@hey-api/openapi-ts": "^0.55.0", "@types/audio-context": "^1.0.3", "@types/audio-play": "^2.3.2", "@types/node": "^22.9.0", @@ -17,7 +16,8 @@ "eslint-config-prettier": "^9.1.0", "eslint-plugin-prettier": "^5.2.1", "globals": "^15.12.0", - "ibm-openapi-validator": "^1.25.0", + "json-schema-to-typescript": "^15.0.3", + "patch-package": "^8.0.0", "prettier": "^3.3.3", "tshy": "^3.0.2", "tsx": "^4.19.2", diff --git a/patches/json-schema-to-typescript+15.0.3.patch b/patches/json-schema-to-typescript+15.0.3.patch new file mode 100644 index 0000000..b654b46 --- /dev/null +++ b/patches/json-schema-to-typescript+15.0.3.patch @@ -0,0 +1,26 @@ +diff --git a/node_modules/json-schema-to-typescript/dist/src/parser.js b/node_modules/json-schema-to-typescript/dist/src/parser.js +index c9c6779..89de019 100644 +--- a/node_modules/json-schema-to-typescript/dist/src/parser.js ++++ b/node_modules/json-schema-to-typescript/dist/src/parser.js +@@ -318,7 +318,7 @@ function parseSchema(schema, options, processed, usedNames, parentSchemaName) { + const ast = parse(value, options, key, processed, usedNames); + const comment = `This interface was referenced by \`${parentSchemaName}\`'s JSON-Schema definition + via the \`patternProperty\` "${key.replace('*/', '*\\/')}".`; +- ast.comment = ast.comment ? `${ast.comment}\n\n${comment}` : comment; ++ ast.comment = ast.comment ? `${ast.comment}\n\n${comment}` : ''; + return { + ast, + isPatternProperty: !singlePatternProperty, +diff --git a/node_modules/json-schema-to-typescript/src/parser.ts b/node_modules/json-schema-to-typescript/src/parser.ts +index 92acdeb..14009ee 100644 +--- a/node_modules/json-schema-to-typescript/src/parser.ts ++++ b/node_modules/json-schema-to-typescript/src/parser.ts +@@ -400,7 +400,7 @@ function parseSchema( + const ast = parse(value, options, key, processed, usedNames) + const comment = `This interface was referenced by \`${parentSchemaName}\`'s JSON-Schema definition + via the \`patternProperty\` "${key.replace('*/', '*\\/')}".` +- ast.comment = ast.comment ? `${ast.comment}\n\n${comment}` : comment ++ ast.comment = ast.comment ? `${ast.comment}\n\n${comment}` : '' + return { + ast, + isPatternProperty: !singlePatternProperty, diff --git a/schema/schema.json b/schema/schema.json new file mode 100644 index 0000000..5585526 --- /dev/null +++ b/schema/schema.json @@ -0,0 +1,638 @@ +{ + "title": "llm-sdk", + "$schema": "http://json-schema.org/draft-07/schema#", + "definitions": { + "TextPart": { + "type": "object", + "description": "A part of the message that contains text.", + "properties": { + "type": { + "type": "string", + "const": "text" + }, + "text": { + "type": "string" + } + }, + "required": ["type", "text"], + "additionalProperties": false + }, + "ImagePart": { + "type": "object", + "description": "A part of the message that contains an image.", + "properties": { + "type": { + "type": "string", + "const": "image" + }, + "mimeType": { + "type": "string", + "description": "The MIME type of the image. E.g. \"image/jpeg\", \"image/png\"." + }, + "imageData": { + "type": "string", + "description": "The base64-encoded image data." + }, + "width": { + "type": "integer", + "description": "The width of the image in pixels." + }, + "height": { + "type": "integer", + "description": "The height of the image in pixels." + } + }, + "required": ["type", "mimeType", "imageData"], + "additionalProperties": false + }, + "AudioEncoding": { + "type": "string", + "enum": ["linear16", "flac", "mulaw", "alaw", "aac", "mp3", "opus"], + "description": "The encoding of the audio." + }, + "AudioContainer": { + "type": "string", + "enum": ["wav", "ogg", "flac", "webm"], + "description": "The container format of the audio." + }, + "AudioPart": { + "type": "object", + "description": "A part of the message that contains an audio.", + "properties": { + "type": { + "type": "string", + "const": "audio" + }, + "container": { + "$ref": "#/definitions/AudioContainer" + }, + "audioData": { + "type": "string", + "description": "The base64-encoded audio data." + }, + "encoding": { + "$ref": "#/definitions/AudioEncoding" + }, + "sampleRate": { + "type": "integer", + "description": "The sample rate of the audio. E.g. 44100, 48000." + }, + "channels": { + "type": "integer", + "description": "The number of channels of the audio. E.g. 1, 2." + }, + "transcript": { + "type": "string", + "description": "The transcript of the audio." + } + }, + "required": ["type", "audioData"], + "additionalProperties": false + }, + "ToolCallPart": { + "type": "object", + "description": "A part of the message that represents a call to a tool the model wants to use.", + "properties": { + "type": { + "type": "string", + "const": "tool-call" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call, used to match the tool result with the tool call." + }, + "toolName": { + "type": "string", + "description": "The name of the tool to call." + }, + "args": { + "oneOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "description": "The arguments to pass to the tool." + } + }, + "required": ["type", "toolCallId", "toolName", "args"], + "additionalProperties": false + }, + "ToolResultPart": { + "type": "object", + "description": "A part of the message that represents the result of a tool call.", + "properties": { + "type": { + "type": "string", + "const": "tool-result" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call from previous assistant message." + }, + "toolName": { + "type": "string", + "description": "The name of the tool that was called." + }, + "result": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "array" + } + ], + "description": "The result of the tool call." + }, + "isError": { + "type": "boolean", + "description": "Marks the tool result as an error." + } + }, + "required": ["type", "toolCallId", "toolName", "result"], + "additionalProperties": false + }, + "Part": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ImagePart" + }, + { + "$ref": "#/definitions/AudioPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/ToolResultPart" + } + ] + }, + "UserMessage": { + "type": "object", + "description": "Represents a message sent by the user.", + "properties": { + "role": { + "type": "string", + "const": "user" + }, + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ImagePart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "AssistantMessage": { + "type": "object", + "description": "Represents a message generated by the model.", + "properties": { + "role": { + "type": "string", + "const": "assistant" + }, + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "TextPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "text" + }, + "text": { + "type": "string" + } + }, + "required": ["type", "text"], + "additionalProperties": false + }, + "ToolCallPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "tool-call" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call, used to match the tool result with the tool call." + }, + "toolName": { + "type": "string", + "description": "The name of the tool to call." + }, + "args": { + "type": "string", + "description": "The partial JSON string of the arguments to pass to the tool." + } + }, + "required": ["type"], + "additionalProperties": false + }, + "AudioPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "audio" + }, + "audioData": { + "type": "string", + "description": "The base64-encoded audio data." + }, + "container": { + "$ref": "#/definitions/AudioContainer" + }, + "encoding": { + "$ref": "#/definitions/AudioEncoding" + }, + "sampleRate": { + "type": "integer", + "description": "The sample rate of the audio. E.g. 44100, 48000." + }, + "channels": { + "type": "integer", + "description": "The number of channels of the audio. E.g. 1, 2." + }, + "transcript": { + "type": "string", + "description": "The transcript of the audio." + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ContentDelta": { + "type": "object", + "properties": { + "index": { + "type": "integer" + }, + "part": { + "oneOf": [ + { + "$ref": "#/definitions/TextPartDelta" + }, + { + "$ref": "#/definitions/ToolCallPartDelta" + }, + { + "$ref": "#/definitions/AudioPartDelta" + } + ] + } + }, + "required": ["index", "part"], + "additionalProperties": false + }, + "JSONSchema": { + "type": "object", + "description": "Represents a JSON schema." + }, + "Tool": { + "type": "object", + "description": "Represents a tool that can be used by the model.", + "properties": { + "name": { + "type": "string", + "description": "The name of the tool." + }, + "description": { + "type": "string", + "description": "A description of the tool." + }, + "parameters": { + "description": "The JSON schema of the parameters that the tool accepts. The type must be \"object\".", + "oneOf": [ + { + "$ref": "#/definitions/JSONSchema" + }, + { + "type": "null" + } + ] + } + }, + "required": ["name", "description", "parameters"], + "additionalProperties": false + }, + "ToolMessage": { + "type": "object", + "description": "Represents tool result in the message history.", + "properties": { + "role": { + "type": "string", + "const": "tool" + }, + "content": { + "type": "array", + "items": { + "$ref": "#/definitions/ToolResultPart" + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "Message": { + "oneOf": [ + { + "$ref": "#/definitions/UserMessage" + }, + { + "$ref": "#/definitions/AssistantMessage" + }, + { + "$ref": "#/definitions/ToolMessage" + } + ] + }, + "ModelTokensDetail": { + "type": "object", + "description": "Represents the token usage of the model.", + "properties": { + "textTokens": { + "type": "integer" + }, + "audioTokens": { + "type": "integer" + }, + "imageTokens": { + "type": "integer" + } + }, + "additionalProperties": false + }, + "ModelUsage": { + "type": "object", + "description": "Represents the token usage of the model.", + "properties": { + "inputTokens": { + "type": "integer" + }, + "outputTokens": { + "type": "integer" + }, + "inputTokensDetail": { + "$ref": "#/definitions/ModelTokensDetail" + }, + "outputTokensDetail": { + "$ref": "#/definitions/ModelTokensDetail" + } + }, + "required": ["inputTokens", "outputTokens"], + "additionalProperties": false + }, + "ModelResponse": { + "type": "object", + "description": "Represents the response generated by the model.", + "properties": { + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + }, + "usage": { + "$ref": "#/definitions/ModelUsage" + }, + "cost": { + "type": "number", + "description": "The cost of the response." + } + }, + "required": ["content"], + "additionalProperties": false + }, + "PartialModelResponse": { + "type": "object", + "properties": { + "delta": { + "$ref": "#/definitions/ContentDelta" + } + }, + "required": ["delta"], + "additionalProperties": false + }, + "ToolChoiceAuto": { + "type": "object", + "description": "The model will automatically choose the tool to use or not use any tools.", + "properties": { + "type": { + "type": "string", + "const": "auto" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceNone": { + "type": "object", + "description": "The model will not use any tools.", + "properties": { + "type": { + "type": "string", + "const": "none" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceRequired": { + "type": "object", + "description": "The model will be forced to use a tool.", + "properties": { + "type": { + "type": "string", + "const": "required" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceTool": { + "type": "object", + "description": "The model will use the specified tool.", + "properties": { + "type": { + "type": "string", + "const": "tool" + }, + "toolName": { + "type": "string" + } + }, + "required": ["type", "toolName"], + "additionalProperties": false + }, + "ResponseFormatText": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "text" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ResponseFormatJson": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "json" + }, + "schema": { + "$ref": "#/definitions/JSONSchema" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "Modality": { + "type": "string", + "enum": ["text", "audio"] + }, + "LanguageModelInput": { + "type": "object", + "properties": { + "systemPrompt": { + "type": "string", + "description": "A system prompt is a way of providing context and instructions to the model" + }, + "messages": { + "type": "array", + "items": { + "$ref": "#/definitions/Message" + }, + "description": "A list of messages comprising the conversation so far." + }, + "tools": { + "type": "array", + "items": { + "$ref": "#/definitions/Tool" + }, + "description": "Definitions of tools that the model may use." + }, + "toolChoice": { + "oneOf": [ + { + "$ref": "#/definitions/ToolChoiceAuto" + }, + { + "$ref": "#/definitions/ToolChoiceNone" + }, + { + "$ref": "#/definitions/ToolChoiceRequired" + }, + { + "$ref": "#/definitions/ToolChoiceTool" + } + ], + "description": "Determines how the model should choose which tool to use. \"auto\" - The model will automatically choose the tool to use or not use any tools. \"none\" - The model will not use any tools. \"required\" - The model will be forced to use a tool. { type: \"tool\", toolName: \"toolName\" } - The model will use the specified tool." + }, + "responseFormat": { + "oneOf": [ + { + "$ref": "#/definitions/ResponseFormatJson" + }, + { + "$ref": "#/definitions/ResponseFormatText" + } + ], + "description": "The format that the model must output" + }, + "maxTokens": { + "type": "integer", + "description": "The maximum number of tokens that can be generated in the chat completion." + }, + "temperature": { + "type": "number", + "description": "Amount of randomness injected into the response. Ranges from 0.0 to 1.0" + }, + "topP": { + "type": "number", + "description": "An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0" + }, + "topK": { + "type": "number", + "description": "Only sample from the top K options for each subsequent token. Used to remove \"long tail\" low probability responses. Ranges from 0.0 to 1.0" + }, + "presencePenalty": { + "type": "number", + "description": "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics." + }, + "frequencyPenalty": { + "type": "number", + "description": "Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim." + }, + "seed": { + "type": "integer", + "description": "The seed (integer), if set and supported by the model, to enable deterministic results." + }, + "modalities": { + "type": "array", + "items": { + "$ref": "#/definitions/Modality" + }, + "description": "The modalities that the model should support." + }, + "extra": { + "type": "object", + "description": "Extra options that the model may support." + } + }, + "required": ["messages"], + "additionalProperties": false + } + } +} diff --git a/schemas/openapi.json b/schemas/openapi.json deleted file mode 100644 index 8290798..0000000 --- a/schemas/openapi.json +++ /dev/null @@ -1,605 +0,0 @@ -{ - "openapi": "3.1.0", - "info": { - "title": "LLM SDK Schema", - "version": "0.0.0" - }, - "components": { - "schemas": { - "TextPart": { - "type": "object", - "description": "A part of the message that contains text.", - "properties": { - "type": { - "type": "string", - "const": "text" - }, - "text": { - "type": "string" - } - }, - "required": ["type", "text"] - }, - "ImagePart": { - "type": "object", - "description": "A part of the message that contains an image.", - "properties": { - "type": { - "type": "string", - "const": "image" - }, - "mimeType": { - "type": "string", - "description": "The MIME type of the image. E.g. \"image/jpeg\", \"image/png\"." - }, - "imageData": { - "type": "string", - "description": "The base64-encoded image data." - }, - "width": { - "type": "integer", - "description": "The width of the image in pixels." - }, - "height": { - "type": "integer", - "description": "The height of the image in pixels." - } - }, - "required": ["type", "mimeType", "imageData"] - }, - "AudioEncoding": { - "type": "string", - "enum": ["linear16", "flac", "mulaw", "alaw", "aac", "mp3", "opus"], - "description": "The encoding of the audio." - }, - "AudioContainer": { - "type": "string", - "enum": ["wav", "ogg", "flac", "webm"], - "description": "The container format of the audio." - }, - "AudioPart": { - "type": "object", - "description": "A part of the message that contains an audio.", - "properties": { - "type": { - "type": "string", - "const": "audio" - }, - "container": { - "$ref": "#/components/schemas/AudioContainer" - }, - "audioData": { - "type": "string", - "description": "The base64-encoded audio data." - }, - "encoding": { - "$ref": "#/components/schemas/AudioEncoding" - }, - "sampleRate": { - "type": "integer", - "description": "The sample rate of the audio. E.g. 44100, 48000." - }, - "channels": { - "type": "integer", - "description": "The number of channels of the audio. E.g. 1, 2." - }, - "transcript": { - "type": "string", - "description": "The transcript of the audio." - } - }, - "required": ["type", "audioData"] - }, - "ToolCallPart": { - "type": "object", - "description": "A part of the message that represents a call to a tool the model wants to use.", - "properties": { - "type": { - "type": "string", - "const": "tool-call" - }, - "toolCallId": { - "type": "string", - "description": "The ID of the tool call, used to match the tool result with the tool call." - }, - "toolName": { - "type": "string", - "description": "The name of the tool to call." - }, - "args": { - "type": "object", - "additionalProperties": true, - "description": "The arguments to pass to the tool.", - "nullable": true - } - }, - "required": ["type", "toolCallId", "toolName", "args"] - }, - "ToolResultPart": { - "type": "object", - "description": "A part of the message that represents the result of a tool call.", - "properties": { - "type": { - "type": "string", - "const": "tool-result" - }, - "toolCallId": { - "type": "string", - "description": "The ID of the tool call from previous assistant message." - }, - "toolName": { - "type": "string", - "description": "The name of the tool that was called." - }, - "result": { - "anyOf": [ - { - "type": "object" - }, - { - "type": "array" - } - ], - "description": "The result of the tool call." - }, - "isError": { - "type": "boolean", - "description": "Marks the tool result as an error." - } - }, - "required": ["type", "toolCallId", "toolName", "result"] - }, - "Part": { - "oneOf": [ - { - "$ref": "#/components/schemas/TextPart" - }, - { - "$ref": "#/components/schemas/ImagePart" - }, - { - "$ref": "#/components/schemas/AudioPart" - }, - { - "$ref": "#/components/schemas/ToolCallPart" - }, - { - "$ref": "#/components/schemas/ToolResultPart" - } - ] - }, - "UserMessage": { - "type": "object", - "description": "Represents a message sent by the user.", - "properties": { - "role": { - "type": "string", - "const": "user" - }, - "content": { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/TextPart" - }, - { - "$ref": "#/components/schemas/ImagePart" - }, - { - "$ref": "#/components/schemas/AudioPart" - } - ] - } - } - }, - "required": ["role", "content"] - }, - "AssistantMessage": { - "type": "object", - "description": "Represents a message generated by the model.", - "properties": { - "role": { - "type": "string", - "const": "assistant" - }, - "content": { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/TextPart" - }, - { - "$ref": "#/components/schemas/ToolCallPart" - }, - { - "$ref": "#/components/schemas/AudioPart" - } - ] - } - } - }, - "required": ["role", "content"] - }, - "TextPartDelta": { - "type": "object", - "properties": { - "type": { - "type": "string", - "const": "text" - }, - "text": { - "type": "string" - } - }, - "required": ["type", "text"] - }, - "ToolCallPartDelta": { - "type": "object", - "properties": { - "type": { - "type": "string", - "const": "tool-call" - }, - "toolCallId": { - "type": "string", - "description": "The ID of the tool call, used to match the tool result with the tool call." - }, - "toolName": { - "type": "string", - "description": "The name of the tool to call." - }, - "args": { - "type": "string", - "description": "The partial JSON string of the arguments to pass to the tool." - } - }, - "required": ["type"] - }, - "AudioPartDelta": { - "type": "object", - "properties": { - "type": { - "type": "string", - "const": "audio" - }, - "audioData": { - "type": "string", - "description": "The base64-encoded audio data." - }, - "container": { - "$ref": "#/components/schemas/AudioContainer" - }, - "encoding": { - "$ref": "#/components/schemas/AudioEncoding" - }, - "sampleRate": { - "type": "integer", - "description": "The sample rate of the audio. E.g. 44100, 48000." - }, - "channels": { - "type": "integer", - "description": "The number of channels of the audio. E.g. 1, 2." - }, - "transcript": { - "type": "string", - "description": "The transcript of the audio." - } - }, - "required": ["type"] - }, - "ContentDelta": { - "type": "object", - "properties": { - "index": { - "type": "integer" - }, - "part": { - "oneOf": [ - { - "$ref": "#/components/schemas/TextPartDelta" - }, - { - "$ref": "#/components/schemas/ToolCallPartDelta" - }, - { - "$ref": "#/components/schemas/AudioPartDelta" - } - ] - } - }, - "required": ["index", "part"] - }, - "Tool": { - "type": "object", - "description": "Represents a tool that can be used by the model.", - "properties": { - "name": { - "type": "string", - "description": "The name of the tool." - }, - "description": { - "type": "string", - "description": "A description of the tool." - }, - "parameters": { - "type": "object", - "description": "The JSON schema of the parameters that the tool accepts. The type must be \"object\".", - "nullable": true - } - }, - "required": ["name", "description", "parameters"] - }, - "ToolMessage": { - "type": "object", - "description": "Represents tool result in the message history.", - "properties": { - "role": { - "type": "string", - "const": "tool" - }, - "content": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ToolResultPart" - } - } - }, - "required": ["role", "content"] - }, - "Message": { - "oneOf": [ - { - "$ref": "#/components/schemas/UserMessage" - }, - { - "$ref": "#/components/schemas/AssistantMessage" - }, - { - "$ref": "#/components/schemas/ToolMessage" - } - ] - }, - "ModelTokensDetail": { - "type": "object", - "description": "Represents the token usage of the model.", - "properties": { - "textTokens": { - "type": "integer" - }, - "audioTokens": { - "type": "integer" - }, - "imageTokens": { - "type": "integer" - } - } - }, - "ModelUsage": { - "type": "object", - "description": "Represents the token usage of the model.", - "properties": { - "inputTokens": { - "type": "integer" - }, - "outputTokens": { - "type": "integer" - }, - "inputTokensDetail": { - "$ref": "#/components/schemas/ModelTokensDetail" - }, - "outputTokensDetail": { - "$ref": "#/components/schemas/ModelTokensDetail" - } - }, - "required": ["inputTokens", "outputTokens"] - }, - "ModelResponse": { - "type": "object", - "description": "Represents the response generated by the model.", - "properties": { - "content": { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/TextPart" - }, - { - "$ref": "#/components/schemas/ToolCallPart" - }, - { - "$ref": "#/components/schemas/AudioPart" - } - ] - } - }, - "usage": { - "$ref": "#/components/schemas/ModelUsage" - }, - "cost": { - "type": "number", - "description": "The cost of the response." - } - }, - "required": ["content"] - }, - "PartialModelResponse": { - "type": "object", - "properties": { - "delta": { - "$ref": "#/components/schemas/ContentDelta" - } - }, - "required": ["delta"] - }, - "ToolChoiceAuto": { - "type": "object", - "description": "The model will automatically choose the tool to use or not use any tools.", - "properties": { - "type": { - "type": "string", - "const": "auto" - } - }, - "required": ["type"] - }, - "ToolChoiceNone": { - "type": "object", - "description": "The model will not use any tools.", - "properties": { - "type": { - "type": "string", - "const": "none" - } - }, - "required": ["type"] - }, - "ToolChoiceRequired": { - "type": "object", - "description": "The model will be forced to use a tool.", - "properties": { - "type": { - "type": "string", - "const": "required" - } - }, - "required": ["type"] - }, - "ToolChoiceTool": { - "type": "object", - "description": "The model will use the specified tool.", - "properties": { - "type": { - "type": "string", - "const": "tool" - }, - "toolName": { - "type": "string" - } - }, - "required": ["type", "toolName"] - }, - "ResponseFormatText": { - "type": "object", - "properties": { - "type": { - "type": "string", - "const": "text" - } - }, - "required": ["type"] - }, - "ResponseFormatJson": { - "type": "object", - "properties": { - "type": { - "type": "string", - "const": "json" - }, - "schema": { - "type": "object", - "description": "The JSON schema of the response that the model must output. Not all models support this option." - } - }, - "required": ["type"] - }, - "Modality": { - "type": "string", - "enum": ["text", "audio"] - }, - "LanguageModelInput": { - "type": "object", - "properties": { - "systemPrompt": { - "type": "string", - "description": "A system prompt is a way of providing context and instructions to the model" - }, - "messages": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Message" - }, - "description": "A list of messages comprising the conversation so far." - }, - "tools": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Tool" - }, - "description": "Definitions of tools that the model may use." - }, - "toolChoice": { - "oneOf": [ - { - "$ref": "#/components/schemas/ToolChoiceAuto" - }, - { - "$ref": "#/components/schemas/ToolChoiceNone" - }, - { - "$ref": "#/components/schemas/ToolChoiceRequired" - }, - { - "$ref": "#/components/schemas/ToolChoiceTool" - } - ], - "description": "Determines how the model should choose which tool to use. \"auto\" - The model will automatically choose the tool to use or not use any tools. \"none\" - The model will not use any tools. \"required\" - The model will be forced to use a tool. { type: \"tool\", toolName: \"toolName\" } - The model will use the specified tool." - }, - "responseFormat": { - "oneOf": [ - { - "$ref": "#/components/schemas/ResponseFormatJson" - }, - { - "$ref": "#/components/schemas/ResponseFormatText" - } - ], - "description": "The format that the model must output" - }, - "maxTokens": { - "type": "integer", - "description": "The maximum number of tokens that can be generated in the chat completion." - }, - "temperature": { - "type": "number", - "description": "Amount of randomness injected into the response. Ranges from 0.0 to 1.0" - }, - "topP": { - "type": "number", - "description": "An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0" - }, - "topK": { - "type": "number", - "description": "Only sample from the top K options for each subsequent token. Used to remove \"long tail\" low probability responses. Ranges from 0.0 to 1.0" - }, - "presencePenalty": { - "type": "number", - "description": "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics." - }, - "frequencyPenalty": { - "type": "number", - "description": "Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim." - }, - "seed": { - "type": "integer", - "description": "The seed (integer), if set and supported by the model, to enable deterministic results." - }, - "modalities": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Modality" - }, - "description": "The modalities that the model should support." - }, - "extra": { - "type": "object", - "description": "Extra options that the model may support." - } - }, - "required": ["messages"] - } - } - } -} From 0365f422c3fc813604ed115a13b15532c6b61fce Mon Sep 17 00:00:00 2001 From: Hoang Vo Date: Sat, 7 Dec 2024 04:34:23 +0700 Subject: [PATCH 2/5] refactor: use typed errors --- javascript/src/anthropic/anthropic.ts | 44 ++++++++++++++++--------- javascript/src/cohere/cohere.ts | 30 +++++++++-------- javascript/src/errors/errors.ts | 31 ++++++++++++++++++ javascript/src/google/google.ts | 35 ++++++++++---------- javascript/src/index.ts | 2 +- javascript/src/mistral/mistral.ts | 47 ++++++++++++++++++--------- javascript/src/openai/openai.ts | 28 +++++++++++----- javascript/src/utils/audio.utils.ts | 8 +++-- javascript/src/utils/message.utils.ts | 2 +- javascript/src/utils/stream.utils.ts | 6 ++-- 10 files changed, 154 insertions(+), 79 deletions(-) create mode 100644 javascript/src/errors/errors.ts diff --git a/javascript/src/anthropic/anthropic.ts b/javascript/src/anthropic/anthropic.ts index e77ff7f..1d9d8f8 100644 --- a/javascript/src/anthropic/anthropic.ts +++ b/javascript/src/anthropic/anthropic.ts @@ -1,4 +1,9 @@ import Anthropic from "@anthropic-ai/sdk"; +import { + InvalidValueError, + ModelUnsupportedMessagePart, + NotImplementedError, +} from "../errors/errors.js"; import type { LanguageModel, LanguageModelMetadata, @@ -170,11 +175,12 @@ export function convertToAnthropicMessages( input: part.args, }; case "audio": - throw new Error("Audio parts are not supported"); + throw new ModelUnsupportedMessagePart("anthropic", part.type); default: { const exhaustiveCheck: never = part; - throw new Error( - `Unsupported message part type: ${(exhaustiveCheck as { type: string }).type}`, + throw new InvalidValueError( + "part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -228,11 +234,12 @@ export function convertToAnthropicMessages( }, }; case "audio": - throw new Error("Audio parts are not supported"); + throw new ModelUnsupportedMessagePart("anthropic", part.type); default: { const exhaustiveCheck: never = part; - throw new Error( - `Unsupported message part type: ${(exhaustiveCheck as { type: string }).type}`, + throw new InvalidValueError( + "part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -243,8 +250,9 @@ export function convertToAnthropicMessages( default: { const exhaustiveCheck: never = message; - throw new Error( - `Unsupported message role: ${(exhaustiveCheck as { role: string }).role}`, + throw new InvalidValueError( + "message.role", + (exhaustiveCheck as { role: string }).role, ); } } @@ -287,8 +295,9 @@ export function convertToAnthropicToolChoice( } default: { const exhaustiveCheck: never = toolChoice; - throw new Error( - `Unsupported tool choice type: ${(exhaustiveCheck as { type: string }).type}`, + throw new InvalidValueError( + "toolChoice.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -333,8 +342,9 @@ export function mapAnthropicBlock(block: Anthropic.Messages.ContentBlock) { } satisfies ToolCallPart; default: { const exhaustiveCheck: never = block; - throw new Error( - `Unsupported block type: ${(exhaustiveCheck as { type: string }).type}`, + throw new NotImplementedError( + "block.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -370,8 +380,9 @@ export function mapAnthropicStreamEvent( } default: { const exhaustiveCheck: never = chunk.content_block; - throw new Error( - `Unsupported content block type: ${(exhaustiveCheck as { type: string }).type}`, + throw new NotImplementedError( + "content_block.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -399,8 +410,9 @@ export function mapAnthropicStreamEvent( ]; default: { const exhaustiveCheck: never = chunk.delta; - throw new Error( - `Unsupported delta type: ${(exhaustiveCheck as { type: string }).type}`, + throw new NotImplementedError( + "delta.type", + (exhaustiveCheck as { type: string }).type, ); } } diff --git a/javascript/src/cohere/cohere.ts b/javascript/src/cohere/cohere.ts index 5618adb..ee0020b 100644 --- a/javascript/src/cohere/cohere.ts +++ b/javascript/src/cohere/cohere.ts @@ -1,4 +1,8 @@ import { Cohere, CohereClientV2 } from "cohere-ai"; +import { + InvalidValueError, + ModelUnsupportedMessagePart, +} from "../errors/errors.js"; import { LanguageModel, LanguageModelMetadata, @@ -188,8 +192,9 @@ export function convertToCohereMessages( } default: { const exhaustiveCheck: never = message; - throw new Error( - `Unsupport message role: ${(exhaustiveCheck as { role: string }).role}`, + throw new InvalidValueError( + "message.role", + (exhaustiveCheck as { role: string }).role, ); } } @@ -217,12 +222,9 @@ export function convertToCohereMessageParam(parts: Part[]): { }); break; } - case "audio": { - throw new Error("Audio is not supported"); - } - case "image": { - throw new Error("Image is not supported"); - } + case "audio": + case "image": + throw new ModelUnsupportedMessagePart("cohere", part.type); case "tool-call": { toolCalls = toolCalls ?? []; toolCalls.push({ @@ -252,8 +254,9 @@ export function convertToCohereMessageParam(parts: Part[]): { } default: { const exhaustiveCheck: never = part; - throw new Error( - `Unsupported part type: ${(exhaustiveCheck as { type: string }).type}`, + throw new InvalidValueError( + "part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -353,10 +356,9 @@ export function convertToCohereResponseFormat( }; default: { const exhaustiveCheck: never = responseFormat; - throw new Error( - `Unsupported response format type: ${ - (exhaustiveCheck as { type: string }).type - }`, + throw new InvalidValueError( + "responseFormat.type", + (exhaustiveCheck as { type: string }).type, ); } } diff --git a/javascript/src/errors/errors.ts b/javascript/src/errors/errors.ts new file mode 100644 index 0000000..dfd2981 --- /dev/null +++ b/javascript/src/errors/errors.ts @@ -0,0 +1,31 @@ +export class ModelUnsupportedMessagePart extends Error { + constructor(provider: string, part: string) { + super(`${provider} does not support message part: ${part}`); + } +} + +export class InvalidValueError extends Error { + constructor( + public parameterName: string, + public parameterValue: unknown, + extraMessage?: string, + ) { + super( + `${parameterName} is invalid: ${String(parameterValue)}` + + (extraMessage ? `. ${extraMessage}` : ""), + ); + } +} + +export class NotImplementedError extends Error { + constructor( + public parameterName: string, + public prameterValue: unknown, + extraMessage?: string, + ) { + super( + `${parameterName} is not implemented: ${String(prameterValue)}` + + (extraMessage ? `. ${extraMessage}` : ""), + ); + } +} diff --git a/javascript/src/google/google.ts b/javascript/src/google/google.ts index a69249b..eea1bae 100644 --- a/javascript/src/google/google.ts +++ b/javascript/src/google/google.ts @@ -14,6 +14,7 @@ import type { UsageMetadata, } from "@google/generative-ai"; import { FunctionCallingMode, GoogleGenerativeAI } from "@google/generative-ai"; +import { InvalidValueError, NotImplementedError } from "../errors/errors.js"; import type { LanguageModel, LanguageModelMetadata, @@ -206,9 +207,7 @@ export function convertToGoogleMessages( } default: { const exhaustiveCheck: never = part; - throw new Error( - `Unsupported part type: ${(exhaustiveCheck as { type: string }).type}`, - ); + throw new InvalidValueError("part.type", exhaustiveCheck); } } }); @@ -231,9 +230,7 @@ export function convertToGoogleMessages( }; default: { const exhaustiveCheck: never = message; - throw new Error( - `Unsupported message role: ${(exhaustiveCheck as { role: string }).role}`, - ); + throw new InvalidValueError("message.role", exhaustiveCheck); } } }); @@ -293,9 +290,7 @@ export function convertToGoogleToolConfig( }; default: { const exhaustiveCheck: never = toolChoice; - throw new Error( - `Unsupported tool choice type: ${(exhaustiveCheck as { type: string }).type}`, - ); + throw new InvalidValueError("toolChoice.type", exhaustiveCheck); } } } @@ -419,8 +414,9 @@ export function mapGooglePart(part: GooglePart): Part | undefined { audioData: part.inlineData.data, }; } - throw new Error( - "unsupported inlineData mimeType: " + part.inlineData.mimeType, + throw new NotImplementedError( + "inlineData.mimeType", + part.inlineData.mimeType, ); } if (part.functionCall) { @@ -437,7 +433,10 @@ export function mapGooglePart(part: GooglePart): Part | undefined { }; } if (part.codeExecutionResult) { - throw new Error("codeExecutionResult is not supported"); + throw new NotImplementedError( + "part.codeExecutionResult", + part.codeExecutionResult, + ); } if (part.functionResponse) { return { @@ -448,12 +447,13 @@ export function mapGooglePart(part: GooglePart): Part | undefined { }; } if (part.fileData) { - throw new Error("fileData is not supported"); + throw new NotImplementedError("part.fileData", part.fileData); } - // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition + if (part.executableCode) { - throw new Error("executableCode is not supported"); + throw new NotImplementedError("part.executableCode", part.executableCode); } + return undefined; } @@ -494,8 +494,9 @@ export function mapGoogleDelta( } default: { const exhaustiveCheck: never = part; - throw new Error( - `Unsupported part type: ${(exhaustiveCheck as { type: string }).type}`, + throw new NotImplementedError( + "part.type", + (exhaustiveCheck as { type: string }).type, ); } } diff --git a/javascript/src/index.ts b/javascript/src/index.ts index 0769e6a..ee1e1f4 100644 --- a/javascript/src/index.ts +++ b/javascript/src/index.ts @@ -1,2 +1,2 @@ export * from "./models/language-model.js"; -export * from "./schema/schema.ts"; +export * from "./schema/schema.js"; diff --git a/javascript/src/mistral/mistral.ts b/javascript/src/mistral/mistral.ts index 0fcefd6..d49cbbc 100644 --- a/javascript/src/mistral/mistral.ts +++ b/javascript/src/mistral/mistral.ts @@ -1,5 +1,10 @@ import { Mistral } from "@mistralai/mistralai"; import * as MistralComponents from "@mistralai/mistralai/models/components/index.js"; +import { + InvalidValueError, + ModelUnsupportedMessagePart, + NotImplementedError, +} from "../errors/errors.js"; import { LanguageModel, LanguageModelMetadata, @@ -189,11 +194,13 @@ export function convertToMistralMessages( break; } case "audio": { - throw new Error("Audio parts are not supported"); + throw new ModelUnsupportedMessagePart("mistral", "audio"); } default: { - throw new Error( - `Unsupported message part type: ${(part as { type: string }).type}`, + const exhaustiveCheck: never = part; + throw new InvalidValueError( + "part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -236,11 +243,13 @@ export function convertToMistralMessages( }; } case "audio": { - throw new Error("Audio parts are not supported"); + throw new ModelUnsupportedMessagePart("mistral", "audio"); } default: { - throw new Error( - `Unsupported message part type: ${(part as { type: string }).type}`, + const exhaustiveCheck: never = part; + throw new InvalidValueError( + "part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -250,8 +259,9 @@ export function convertToMistralMessages( } default: { const exhaustiveCheck: never = message; - throw new Error( - `Unsupported message role: ${(exhaustiveCheck as { role: string }).role}`, + throw new InvalidValueError( + "message.role", + (exhaustiveCheck as { role: string }).role, ); } } @@ -317,8 +327,9 @@ export function convertToMistralResponseFormat( return { type: "text" }; default: { const exhaustiveCheck: never = responseFormat; - throw new Error( - `Unsupported response format: ${(exhaustiveCheck as { type: string }).type}`, + throw new InvalidValueError( + "responseFormat.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -345,11 +356,13 @@ export function mapMistralMessage( }); break; case "image_url": - throw new Error("Image URL chunks are not supported"); + case "reference": + throw new NotImplementedError("message.part", chunk.type); default: { const exhaustiveCheck: never = chunk; - throw new Error( - `Unsupported message part type: ${(exhaustiveCheck as { type: string }).type}`, + throw new NotImplementedError( + "message.part", + (exhaustiveCheck as { type: string }).type, ); } } @@ -415,11 +428,13 @@ export function mapMistralDelta( break; } case "image_url": - throw new Error("Image URL chunks are not supported"); + case "reference": + throw new NotImplementedError("message.part", chunk.type); default: { const exhaustiveCheck: never = chunk; - throw new Error( - `Unsupported message part type: ${(exhaustiveCheck as { type: string }).type}`, + throw new NotImplementedError( + "message.part", + (exhaustiveCheck as { type: string }).type, ); } } diff --git a/javascript/src/openai/openai.ts b/javascript/src/openai/openai.ts index 44c3dce..ce88ec1 100644 --- a/javascript/src/openai/openai.ts +++ b/javascript/src/openai/openai.ts @@ -1,4 +1,5 @@ import OpenAI from "openai"; +import { InvalidValueError, NotImplementedError } from "../errors/errors.js"; import type { LanguageModel, LanguageModelMetadata, @@ -238,8 +239,10 @@ export function convertToOpenAIMessages( ); } default: { - throw new Error( - `Unsupported message part type: ${(part as { type: string }).type}`, + const exhaustiveCheck: never = part; + throw new InvalidValueError( + "message.part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -293,8 +296,10 @@ export function convertToOpenAIMessages( }; } default: { - throw new Error( - `Unsupported message part type: ${(part as { type: string }).type}`, + const exhaustiveCheck: never = part; + throw new InvalidValueError( + "message.part.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -305,8 +310,9 @@ export function convertToOpenAIMessages( } default: { const exhaustiveCheck: never = message; - throw new Error( - `Unsupported message role: ${(exhaustiveCheck as { role: string }).role}`, + throw new InvalidValueError( + "message.role", + (exhaustiveCheck as { role: string }).role, ); } } @@ -454,8 +460,9 @@ export function convertToOpenAIResponseFormat( return { type: "text" }; default: { const exhaustiveCheck: never = responseFormat; - throw new Error( - `Unsupported response format: ${(exhaustiveCheck as { type: string }).type}`, + throw new InvalidValueError( + "responseFormat.type", + (exhaustiveCheck as { type: string }).type, ); } } @@ -484,7 +491,10 @@ export function mapOpenAIAudioFormat(format: PossibleOpenAIAudioFormat): { return { encoding: "alaw" }; default: { const exhaustiveCheck: never = format; - throw new Error(`Unsupported audio format: ${exhaustiveCheck as string}`); + throw new NotImplementedError( + "format", + (exhaustiveCheck as { type: string }).type, + ); } } } diff --git a/javascript/src/utils/audio.utils.ts b/javascript/src/utils/audio.utils.ts index 1f3de3b..d7941a6 100644 --- a/javascript/src/utils/audio.utils.ts +++ b/javascript/src/utils/audio.utils.ts @@ -1,4 +1,4 @@ -import type { AudioContainer, AudioEncoding } from "../schema/types.gen.js"; +import type { AudioContainer, AudioEncoding } from "../schema/index.js"; export function base64ToArrayBuffer(base64: string): ArrayBuffer { const binaryString = atob(base64); @@ -10,11 +10,13 @@ export function base64ToArrayBuffer(base64: string): ArrayBuffer { return bytes.buffer; } -export function arrayBufferToBase64(arrayBuffer: ArrayBuffer): string { +export function arrayBufferToBase64( + arrayBuffer: ArrayBuffer | Float32Array | Int16Array, +): string { if (arrayBuffer instanceof Float32Array) { arrayBuffer = floatTo16BitPCM(arrayBuffer); } else if (arrayBuffer instanceof Int16Array) { - arrayBuffer = arrayBuffer.buffer; + arrayBuffer = arrayBuffer.buffer as ArrayBuffer; } let binary = ""; const bytes = new Uint8Array(arrayBuffer); diff --git a/javascript/src/utils/message.utils.ts b/javascript/src/utils/message.utils.ts index 0d54f5a..578878a 100644 --- a/javascript/src/utils/message.utils.ts +++ b/javascript/src/utils/message.utils.ts @@ -1,4 +1,4 @@ -import type { Message } from "../schema/types.gen.js"; +import type { Message } from "../schema/index.js"; export function convertAudioPartsToTextParts(message: T): T { return { diff --git a/javascript/src/utils/stream.utils.ts b/javascript/src/utils/stream.utils.ts index 380ab2c..934abe5 100644 --- a/javascript/src/utils/stream.utils.ts +++ b/javascript/src/utils/stream.utils.ts @@ -138,10 +138,12 @@ export class ContentDeltaAccumulator { ...(delta.part.transcript && { transcript: delta.part.transcript }), }; } - default: + default: { + const exhaustiveCheck: never = delta.part; throw new Error( - `unexpected part ${(delta.part as { type: string }).type} at index ${String(delta.index)}`, + `unexpected part ${String(exhaustiveCheck)} at index ${String(delta.index)}`, ); + } } }); } From 55957a97dc74ee4ead36afcad9dbdecb131ccfe3 Mon Sep 17 00:00:00 2001 From: Hoang Vo Date: Sat, 7 Dec 2024 04:49:04 +0700 Subject: [PATCH 3/5] chore: add build script --- javascript/generate.js | 19 + javascript/package.json | 19 +- javascript/schema.json | 638 ++++++++++++++++++++ javascript/src/mistral/mistral.ts | 19 +- javascript/src/openai/openai.ts | 26 +- javascript/src/openai/types.ts | 6 +- javascript/src/schema/schema.json | 638 ++++++++++++++++++++ package-lock.json | 962 +++++++++++++++++------------- package.json | 20 +- 9 files changed, 1881 insertions(+), 466 deletions(-) create mode 100644 javascript/generate.js create mode 100644 javascript/schema.json create mode 100644 javascript/src/schema/schema.json diff --git a/javascript/generate.js b/javascript/generate.js new file mode 100644 index 0000000..b8f60a2 --- /dev/null +++ b/javascript/generate.js @@ -0,0 +1,19 @@ +import { copyFile, writeFile } from "fs/promises"; +import { compileFromFile } from "json-schema-to-typescript"; +import { join } from "path"; + +const __dirname = import.meta.dirname; + +const originalSchemaPath = join(__dirname, "..", "schema", "schema.json"); + +await copyFile( + originalSchemaPath, + join(__dirname, "src", "schema", "schema.json"), +); + +// Generate typescript +const ts = await compileFromFile(originalSchemaPath, { + bannerComment: false, + unreachableDefinitions: true, +}); +await writeFile(join(__dirname, "src", "schema", "schema.ts"), ts); diff --git a/javascript/package.json b/javascript/package.json index 2a4b503..4d250fd 100644 --- a/javascript/package.json +++ b/javascript/package.json @@ -4,8 +4,8 @@ "version": "0.1.6", "description": "A unified LLM SDK", "scripts": { - "generate": "json2ts --bannerComment=false --unreachableDefinitions=true -i ../schema/schema.json -o src/schema/schema.ts", - "build": "tshy", + "generate": "node generate.js", + "build": "tshy && cp src/schema/schema.json dist/esm/schema/schema.json && cp src/schema/schema.json dist/commonjs/schema/schema.json", "lint": "eslint src", "test": "tsx --test --experimental-test-coverage --env-file=../.env \"**/*.test.ts\"" }, @@ -83,7 +83,17 @@ "default": "./dist/commonjs/utils/index.js" } }, - "./package.json": "./package.json" + "./package.json": "./package.json", + "./schema/schema.json": { + "import": { + "types": "./dist/esm/schema/schema.json", + "default": "./dist/esm/schema/schema.json" + }, + "require": { + "types": "./dist/commonjs/schema/schema.json", + "default": "./dist/commonjs/schema/schema.json" + } + } }, "main": "./dist/commonjs/index.js", "types": "./dist/commonjs/index.d.ts", @@ -108,7 +118,8 @@ "./cohere": "./src/cohere/index.ts", "./mistral": "./src/mistral/index.ts", "./utils": "./src/utils/index.ts", - "./package.json": "./package.json" + "./package.json": "./package.json", + "./schema/schema.json": "./src/schema/schema.json" }, "project": "tsconfig.build.json" }, diff --git a/javascript/schema.json b/javascript/schema.json new file mode 100644 index 0000000..5585526 --- /dev/null +++ b/javascript/schema.json @@ -0,0 +1,638 @@ +{ + "title": "llm-sdk", + "$schema": "http://json-schema.org/draft-07/schema#", + "definitions": { + "TextPart": { + "type": "object", + "description": "A part of the message that contains text.", + "properties": { + "type": { + "type": "string", + "const": "text" + }, + "text": { + "type": "string" + } + }, + "required": ["type", "text"], + "additionalProperties": false + }, + "ImagePart": { + "type": "object", + "description": "A part of the message that contains an image.", + "properties": { + "type": { + "type": "string", + "const": "image" + }, + "mimeType": { + "type": "string", + "description": "The MIME type of the image. E.g. \"image/jpeg\", \"image/png\"." + }, + "imageData": { + "type": "string", + "description": "The base64-encoded image data." + }, + "width": { + "type": "integer", + "description": "The width of the image in pixels." + }, + "height": { + "type": "integer", + "description": "The height of the image in pixels." + } + }, + "required": ["type", "mimeType", "imageData"], + "additionalProperties": false + }, + "AudioEncoding": { + "type": "string", + "enum": ["linear16", "flac", "mulaw", "alaw", "aac", "mp3", "opus"], + "description": "The encoding of the audio." + }, + "AudioContainer": { + "type": "string", + "enum": ["wav", "ogg", "flac", "webm"], + "description": "The container format of the audio." + }, + "AudioPart": { + "type": "object", + "description": "A part of the message that contains an audio.", + "properties": { + "type": { + "type": "string", + "const": "audio" + }, + "container": { + "$ref": "#/definitions/AudioContainer" + }, + "audioData": { + "type": "string", + "description": "The base64-encoded audio data." + }, + "encoding": { + "$ref": "#/definitions/AudioEncoding" + }, + "sampleRate": { + "type": "integer", + "description": "The sample rate of the audio. E.g. 44100, 48000." + }, + "channels": { + "type": "integer", + "description": "The number of channels of the audio. E.g. 1, 2." + }, + "transcript": { + "type": "string", + "description": "The transcript of the audio." + } + }, + "required": ["type", "audioData"], + "additionalProperties": false + }, + "ToolCallPart": { + "type": "object", + "description": "A part of the message that represents a call to a tool the model wants to use.", + "properties": { + "type": { + "type": "string", + "const": "tool-call" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call, used to match the tool result with the tool call." + }, + "toolName": { + "type": "string", + "description": "The name of the tool to call." + }, + "args": { + "oneOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "description": "The arguments to pass to the tool." + } + }, + "required": ["type", "toolCallId", "toolName", "args"], + "additionalProperties": false + }, + "ToolResultPart": { + "type": "object", + "description": "A part of the message that represents the result of a tool call.", + "properties": { + "type": { + "type": "string", + "const": "tool-result" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call from previous assistant message." + }, + "toolName": { + "type": "string", + "description": "The name of the tool that was called." + }, + "result": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "array" + } + ], + "description": "The result of the tool call." + }, + "isError": { + "type": "boolean", + "description": "Marks the tool result as an error." + } + }, + "required": ["type", "toolCallId", "toolName", "result"], + "additionalProperties": false + }, + "Part": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ImagePart" + }, + { + "$ref": "#/definitions/AudioPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/ToolResultPart" + } + ] + }, + "UserMessage": { + "type": "object", + "description": "Represents a message sent by the user.", + "properties": { + "role": { + "type": "string", + "const": "user" + }, + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ImagePart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "AssistantMessage": { + "type": "object", + "description": "Represents a message generated by the model.", + "properties": { + "role": { + "type": "string", + "const": "assistant" + }, + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "TextPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "text" + }, + "text": { + "type": "string" + } + }, + "required": ["type", "text"], + "additionalProperties": false + }, + "ToolCallPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "tool-call" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call, used to match the tool result with the tool call." + }, + "toolName": { + "type": "string", + "description": "The name of the tool to call." + }, + "args": { + "type": "string", + "description": "The partial JSON string of the arguments to pass to the tool." + } + }, + "required": ["type"], + "additionalProperties": false + }, + "AudioPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "audio" + }, + "audioData": { + "type": "string", + "description": "The base64-encoded audio data." + }, + "container": { + "$ref": "#/definitions/AudioContainer" + }, + "encoding": { + "$ref": "#/definitions/AudioEncoding" + }, + "sampleRate": { + "type": "integer", + "description": "The sample rate of the audio. E.g. 44100, 48000." + }, + "channels": { + "type": "integer", + "description": "The number of channels of the audio. E.g. 1, 2." + }, + "transcript": { + "type": "string", + "description": "The transcript of the audio." + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ContentDelta": { + "type": "object", + "properties": { + "index": { + "type": "integer" + }, + "part": { + "oneOf": [ + { + "$ref": "#/definitions/TextPartDelta" + }, + { + "$ref": "#/definitions/ToolCallPartDelta" + }, + { + "$ref": "#/definitions/AudioPartDelta" + } + ] + } + }, + "required": ["index", "part"], + "additionalProperties": false + }, + "JSONSchema": { + "type": "object", + "description": "Represents a JSON schema." + }, + "Tool": { + "type": "object", + "description": "Represents a tool that can be used by the model.", + "properties": { + "name": { + "type": "string", + "description": "The name of the tool." + }, + "description": { + "type": "string", + "description": "A description of the tool." + }, + "parameters": { + "description": "The JSON schema of the parameters that the tool accepts. The type must be \"object\".", + "oneOf": [ + { + "$ref": "#/definitions/JSONSchema" + }, + { + "type": "null" + } + ] + } + }, + "required": ["name", "description", "parameters"], + "additionalProperties": false + }, + "ToolMessage": { + "type": "object", + "description": "Represents tool result in the message history.", + "properties": { + "role": { + "type": "string", + "const": "tool" + }, + "content": { + "type": "array", + "items": { + "$ref": "#/definitions/ToolResultPart" + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "Message": { + "oneOf": [ + { + "$ref": "#/definitions/UserMessage" + }, + { + "$ref": "#/definitions/AssistantMessage" + }, + { + "$ref": "#/definitions/ToolMessage" + } + ] + }, + "ModelTokensDetail": { + "type": "object", + "description": "Represents the token usage of the model.", + "properties": { + "textTokens": { + "type": "integer" + }, + "audioTokens": { + "type": "integer" + }, + "imageTokens": { + "type": "integer" + } + }, + "additionalProperties": false + }, + "ModelUsage": { + "type": "object", + "description": "Represents the token usage of the model.", + "properties": { + "inputTokens": { + "type": "integer" + }, + "outputTokens": { + "type": "integer" + }, + "inputTokensDetail": { + "$ref": "#/definitions/ModelTokensDetail" + }, + "outputTokensDetail": { + "$ref": "#/definitions/ModelTokensDetail" + } + }, + "required": ["inputTokens", "outputTokens"], + "additionalProperties": false + }, + "ModelResponse": { + "type": "object", + "description": "Represents the response generated by the model.", + "properties": { + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + }, + "usage": { + "$ref": "#/definitions/ModelUsage" + }, + "cost": { + "type": "number", + "description": "The cost of the response." + } + }, + "required": ["content"], + "additionalProperties": false + }, + "PartialModelResponse": { + "type": "object", + "properties": { + "delta": { + "$ref": "#/definitions/ContentDelta" + } + }, + "required": ["delta"], + "additionalProperties": false + }, + "ToolChoiceAuto": { + "type": "object", + "description": "The model will automatically choose the tool to use or not use any tools.", + "properties": { + "type": { + "type": "string", + "const": "auto" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceNone": { + "type": "object", + "description": "The model will not use any tools.", + "properties": { + "type": { + "type": "string", + "const": "none" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceRequired": { + "type": "object", + "description": "The model will be forced to use a tool.", + "properties": { + "type": { + "type": "string", + "const": "required" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceTool": { + "type": "object", + "description": "The model will use the specified tool.", + "properties": { + "type": { + "type": "string", + "const": "tool" + }, + "toolName": { + "type": "string" + } + }, + "required": ["type", "toolName"], + "additionalProperties": false + }, + "ResponseFormatText": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "text" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ResponseFormatJson": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "json" + }, + "schema": { + "$ref": "#/definitions/JSONSchema" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "Modality": { + "type": "string", + "enum": ["text", "audio"] + }, + "LanguageModelInput": { + "type": "object", + "properties": { + "systemPrompt": { + "type": "string", + "description": "A system prompt is a way of providing context and instructions to the model" + }, + "messages": { + "type": "array", + "items": { + "$ref": "#/definitions/Message" + }, + "description": "A list of messages comprising the conversation so far." + }, + "tools": { + "type": "array", + "items": { + "$ref": "#/definitions/Tool" + }, + "description": "Definitions of tools that the model may use." + }, + "toolChoice": { + "oneOf": [ + { + "$ref": "#/definitions/ToolChoiceAuto" + }, + { + "$ref": "#/definitions/ToolChoiceNone" + }, + { + "$ref": "#/definitions/ToolChoiceRequired" + }, + { + "$ref": "#/definitions/ToolChoiceTool" + } + ], + "description": "Determines how the model should choose which tool to use. \"auto\" - The model will automatically choose the tool to use or not use any tools. \"none\" - The model will not use any tools. \"required\" - The model will be forced to use a tool. { type: \"tool\", toolName: \"toolName\" } - The model will use the specified tool." + }, + "responseFormat": { + "oneOf": [ + { + "$ref": "#/definitions/ResponseFormatJson" + }, + { + "$ref": "#/definitions/ResponseFormatText" + } + ], + "description": "The format that the model must output" + }, + "maxTokens": { + "type": "integer", + "description": "The maximum number of tokens that can be generated in the chat completion." + }, + "temperature": { + "type": "number", + "description": "Amount of randomness injected into the response. Ranges from 0.0 to 1.0" + }, + "topP": { + "type": "number", + "description": "An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0" + }, + "topK": { + "type": "number", + "description": "Only sample from the top K options for each subsequent token. Used to remove \"long tail\" low probability responses. Ranges from 0.0 to 1.0" + }, + "presencePenalty": { + "type": "number", + "description": "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics." + }, + "frequencyPenalty": { + "type": "number", + "description": "Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim." + }, + "seed": { + "type": "integer", + "description": "The seed (integer), if set and supported by the model, to enable deterministic results." + }, + "modalities": { + "type": "array", + "items": { + "$ref": "#/definitions/Modality" + }, + "description": "The modalities that the model should support." + }, + "extra": { + "type": "object", + "description": "Extra options that the model may support." + } + }, + "required": ["messages"], + "additionalProperties": false + } + } +} diff --git a/javascript/src/mistral/mistral.ts b/javascript/src/mistral/mistral.ts index d49cbbc..eff60b5 100644 --- a/javascript/src/mistral/mistral.ts +++ b/javascript/src/mistral/mistral.ts @@ -164,20 +164,23 @@ export function convertToMistralMessages( messages.forEach((message) => { switch (message.role) { case "assistant": { - const mistralMessageParam: MistralComponents.AssistantMessage = { + const mistralMessageParam: Omit< + MistralComponents.AssistantMessage, + "content" + > & { + content: MistralComponents.ContentChunk[] | null; + } = { role: "assistant", content: null, }; message.content.forEach((part) => { switch (part.type) { case "text": { - mistralMessageParam.content = [ - ...(mistralMessageParam.content || []), - { - type: "text", - text: part.text, - }, - ] as Array; + mistralMessageParam.content = mistralMessageParam.content || []; + mistralMessageParam.content.push({ + type: "text", + text: part.text, + }); break; } case "tool-call": { diff --git a/javascript/src/openai/openai.ts b/javascript/src/openai/openai.ts index ce88ec1..aca81a9 100644 --- a/javascript/src/openai/openai.ts +++ b/javascript/src/openai/openai.ts @@ -202,21 +202,23 @@ export function convertToOpenAIMessages( messages.forEach((message) => { switch (message.role) { case "assistant": { - const openaiMessageParam: OpenAI.Chat.ChatCompletionAssistantMessageParam = - { - role: "assistant", - content: null, - }; + const openaiMessageParam: Omit< + OpenAI.Chat.ChatCompletionAssistantMessageParam, + "content" + > & { + content: Array | null; + } = { + role: "assistant", + content: null, + }; message.content.forEach((part) => { switch (part.type) { case "text": { - openaiMessageParam.content = [ - ...(openaiMessageParam.content || []), - { - type: "text", - text: part.text, - }, - ] as Array; + openaiMessageParam.content = openaiMessageParam.content || []; + openaiMessageParam.content.push({ + type: "text", + text: part.text, + }); break; } case "tool-call": { diff --git a/javascript/src/openai/types.ts b/javascript/src/openai/types.ts index 1766436..e9899a3 100644 --- a/javascript/src/openai/types.ts +++ b/javascript/src/openai/types.ts @@ -31,7 +31,7 @@ export type OpenAIPatchedPromptTokensDetails = { // documented type is wrong export type OpenAIPatchedCompletionTokenDetails = { - reasoning_tokens: 0; - text_tokens: 63; - audio_tokens: 286; + reasoning_tokens: number; + text_tokens: number; + audio_tokens: number; }; diff --git a/javascript/src/schema/schema.json b/javascript/src/schema/schema.json new file mode 100644 index 0000000..5585526 --- /dev/null +++ b/javascript/src/schema/schema.json @@ -0,0 +1,638 @@ +{ + "title": "llm-sdk", + "$schema": "http://json-schema.org/draft-07/schema#", + "definitions": { + "TextPart": { + "type": "object", + "description": "A part of the message that contains text.", + "properties": { + "type": { + "type": "string", + "const": "text" + }, + "text": { + "type": "string" + } + }, + "required": ["type", "text"], + "additionalProperties": false + }, + "ImagePart": { + "type": "object", + "description": "A part of the message that contains an image.", + "properties": { + "type": { + "type": "string", + "const": "image" + }, + "mimeType": { + "type": "string", + "description": "The MIME type of the image. E.g. \"image/jpeg\", \"image/png\"." + }, + "imageData": { + "type": "string", + "description": "The base64-encoded image data." + }, + "width": { + "type": "integer", + "description": "The width of the image in pixels." + }, + "height": { + "type": "integer", + "description": "The height of the image in pixels." + } + }, + "required": ["type", "mimeType", "imageData"], + "additionalProperties": false + }, + "AudioEncoding": { + "type": "string", + "enum": ["linear16", "flac", "mulaw", "alaw", "aac", "mp3", "opus"], + "description": "The encoding of the audio." + }, + "AudioContainer": { + "type": "string", + "enum": ["wav", "ogg", "flac", "webm"], + "description": "The container format of the audio." + }, + "AudioPart": { + "type": "object", + "description": "A part of the message that contains an audio.", + "properties": { + "type": { + "type": "string", + "const": "audio" + }, + "container": { + "$ref": "#/definitions/AudioContainer" + }, + "audioData": { + "type": "string", + "description": "The base64-encoded audio data." + }, + "encoding": { + "$ref": "#/definitions/AudioEncoding" + }, + "sampleRate": { + "type": "integer", + "description": "The sample rate of the audio. E.g. 44100, 48000." + }, + "channels": { + "type": "integer", + "description": "The number of channels of the audio. E.g. 1, 2." + }, + "transcript": { + "type": "string", + "description": "The transcript of the audio." + } + }, + "required": ["type", "audioData"], + "additionalProperties": false + }, + "ToolCallPart": { + "type": "object", + "description": "A part of the message that represents a call to a tool the model wants to use.", + "properties": { + "type": { + "type": "string", + "const": "tool-call" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call, used to match the tool result with the tool call." + }, + "toolName": { + "type": "string", + "description": "The name of the tool to call." + }, + "args": { + "oneOf": [ + { + "type": "object" + }, + { + "type": "null" + } + ], + "description": "The arguments to pass to the tool." + } + }, + "required": ["type", "toolCallId", "toolName", "args"], + "additionalProperties": false + }, + "ToolResultPart": { + "type": "object", + "description": "A part of the message that represents the result of a tool call.", + "properties": { + "type": { + "type": "string", + "const": "tool-result" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call from previous assistant message." + }, + "toolName": { + "type": "string", + "description": "The name of the tool that was called." + }, + "result": { + "anyOf": [ + { + "type": "object" + }, + { + "type": "array" + } + ], + "description": "The result of the tool call." + }, + "isError": { + "type": "boolean", + "description": "Marks the tool result as an error." + } + }, + "required": ["type", "toolCallId", "toolName", "result"], + "additionalProperties": false + }, + "Part": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ImagePart" + }, + { + "$ref": "#/definitions/AudioPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/ToolResultPart" + } + ] + }, + "UserMessage": { + "type": "object", + "description": "Represents a message sent by the user.", + "properties": { + "role": { + "type": "string", + "const": "user" + }, + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ImagePart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "AssistantMessage": { + "type": "object", + "description": "Represents a message generated by the model.", + "properties": { + "role": { + "type": "string", + "const": "assistant" + }, + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "TextPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "text" + }, + "text": { + "type": "string" + } + }, + "required": ["type", "text"], + "additionalProperties": false + }, + "ToolCallPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "tool-call" + }, + "toolCallId": { + "type": "string", + "description": "The ID of the tool call, used to match the tool result with the tool call." + }, + "toolName": { + "type": "string", + "description": "The name of the tool to call." + }, + "args": { + "type": "string", + "description": "The partial JSON string of the arguments to pass to the tool." + } + }, + "required": ["type"], + "additionalProperties": false + }, + "AudioPartDelta": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "audio" + }, + "audioData": { + "type": "string", + "description": "The base64-encoded audio data." + }, + "container": { + "$ref": "#/definitions/AudioContainer" + }, + "encoding": { + "$ref": "#/definitions/AudioEncoding" + }, + "sampleRate": { + "type": "integer", + "description": "The sample rate of the audio. E.g. 44100, 48000." + }, + "channels": { + "type": "integer", + "description": "The number of channels of the audio. E.g. 1, 2." + }, + "transcript": { + "type": "string", + "description": "The transcript of the audio." + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ContentDelta": { + "type": "object", + "properties": { + "index": { + "type": "integer" + }, + "part": { + "oneOf": [ + { + "$ref": "#/definitions/TextPartDelta" + }, + { + "$ref": "#/definitions/ToolCallPartDelta" + }, + { + "$ref": "#/definitions/AudioPartDelta" + } + ] + } + }, + "required": ["index", "part"], + "additionalProperties": false + }, + "JSONSchema": { + "type": "object", + "description": "Represents a JSON schema." + }, + "Tool": { + "type": "object", + "description": "Represents a tool that can be used by the model.", + "properties": { + "name": { + "type": "string", + "description": "The name of the tool." + }, + "description": { + "type": "string", + "description": "A description of the tool." + }, + "parameters": { + "description": "The JSON schema of the parameters that the tool accepts. The type must be \"object\".", + "oneOf": [ + { + "$ref": "#/definitions/JSONSchema" + }, + { + "type": "null" + } + ] + } + }, + "required": ["name", "description", "parameters"], + "additionalProperties": false + }, + "ToolMessage": { + "type": "object", + "description": "Represents tool result in the message history.", + "properties": { + "role": { + "type": "string", + "const": "tool" + }, + "content": { + "type": "array", + "items": { + "$ref": "#/definitions/ToolResultPart" + } + } + }, + "required": ["role", "content"], + "additionalProperties": false + }, + "Message": { + "oneOf": [ + { + "$ref": "#/definitions/UserMessage" + }, + { + "$ref": "#/definitions/AssistantMessage" + }, + { + "$ref": "#/definitions/ToolMessage" + } + ] + }, + "ModelTokensDetail": { + "type": "object", + "description": "Represents the token usage of the model.", + "properties": { + "textTokens": { + "type": "integer" + }, + "audioTokens": { + "type": "integer" + }, + "imageTokens": { + "type": "integer" + } + }, + "additionalProperties": false + }, + "ModelUsage": { + "type": "object", + "description": "Represents the token usage of the model.", + "properties": { + "inputTokens": { + "type": "integer" + }, + "outputTokens": { + "type": "integer" + }, + "inputTokensDetail": { + "$ref": "#/definitions/ModelTokensDetail" + }, + "outputTokensDetail": { + "$ref": "#/definitions/ModelTokensDetail" + } + }, + "required": ["inputTokens", "outputTokens"], + "additionalProperties": false + }, + "ModelResponse": { + "type": "object", + "description": "Represents the response generated by the model.", + "properties": { + "content": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/TextPart" + }, + { + "$ref": "#/definitions/ToolCallPart" + }, + { + "$ref": "#/definitions/AudioPart" + } + ] + } + }, + "usage": { + "$ref": "#/definitions/ModelUsage" + }, + "cost": { + "type": "number", + "description": "The cost of the response." + } + }, + "required": ["content"], + "additionalProperties": false + }, + "PartialModelResponse": { + "type": "object", + "properties": { + "delta": { + "$ref": "#/definitions/ContentDelta" + } + }, + "required": ["delta"], + "additionalProperties": false + }, + "ToolChoiceAuto": { + "type": "object", + "description": "The model will automatically choose the tool to use or not use any tools.", + "properties": { + "type": { + "type": "string", + "const": "auto" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceNone": { + "type": "object", + "description": "The model will not use any tools.", + "properties": { + "type": { + "type": "string", + "const": "none" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceRequired": { + "type": "object", + "description": "The model will be forced to use a tool.", + "properties": { + "type": { + "type": "string", + "const": "required" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ToolChoiceTool": { + "type": "object", + "description": "The model will use the specified tool.", + "properties": { + "type": { + "type": "string", + "const": "tool" + }, + "toolName": { + "type": "string" + } + }, + "required": ["type", "toolName"], + "additionalProperties": false + }, + "ResponseFormatText": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "text" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "ResponseFormatJson": { + "type": "object", + "properties": { + "type": { + "type": "string", + "const": "json" + }, + "schema": { + "$ref": "#/definitions/JSONSchema" + } + }, + "required": ["type"], + "additionalProperties": false + }, + "Modality": { + "type": "string", + "enum": ["text", "audio"] + }, + "LanguageModelInput": { + "type": "object", + "properties": { + "systemPrompt": { + "type": "string", + "description": "A system prompt is a way of providing context and instructions to the model" + }, + "messages": { + "type": "array", + "items": { + "$ref": "#/definitions/Message" + }, + "description": "A list of messages comprising the conversation so far." + }, + "tools": { + "type": "array", + "items": { + "$ref": "#/definitions/Tool" + }, + "description": "Definitions of tools that the model may use." + }, + "toolChoice": { + "oneOf": [ + { + "$ref": "#/definitions/ToolChoiceAuto" + }, + { + "$ref": "#/definitions/ToolChoiceNone" + }, + { + "$ref": "#/definitions/ToolChoiceRequired" + }, + { + "$ref": "#/definitions/ToolChoiceTool" + } + ], + "description": "Determines how the model should choose which tool to use. \"auto\" - The model will automatically choose the tool to use or not use any tools. \"none\" - The model will not use any tools. \"required\" - The model will be forced to use a tool. { type: \"tool\", toolName: \"toolName\" } - The model will use the specified tool." + }, + "responseFormat": { + "oneOf": [ + { + "$ref": "#/definitions/ResponseFormatJson" + }, + { + "$ref": "#/definitions/ResponseFormatText" + } + ], + "description": "The format that the model must output" + }, + "maxTokens": { + "type": "integer", + "description": "The maximum number of tokens that can be generated in the chat completion." + }, + "temperature": { + "type": "number", + "description": "Amount of randomness injected into the response. Ranges from 0.0 to 1.0" + }, + "topP": { + "type": "number", + "description": "An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass Ranges from 0.0 to 1.0" + }, + "topK": { + "type": "number", + "description": "Only sample from the top K options for each subsequent token. Used to remove \"long tail\" low probability responses. Ranges from 0.0 to 1.0" + }, + "presencePenalty": { + "type": "number", + "description": "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics." + }, + "frequencyPenalty": { + "type": "number", + "description": "Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim." + }, + "seed": { + "type": "integer", + "description": "The seed (integer), if set and supported by the model, to enable deterministic results." + }, + "modalities": { + "type": "array", + "items": { + "$ref": "#/definitions/Modality" + }, + "description": "The modalities that the model should support." + }, + "extra": { + "type": "object", + "description": "Extra options that the model may support." + } + }, + "required": ["messages"], + "additionalProperties": false + } + } +} diff --git a/package-lock.json b/package-lock.json index 9579256..7147a66 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,29 +11,29 @@ "dependencies": { "@anthropic-ai/sdk": "^0.32.1", "@google/generative-ai": "^0.21.0", - "@mistralai/mistralai": "^1.3.0", + "@mistralai/mistralai": "^1.3.5", "audio-context": "^1.0.3", "audio-decode": "^2.2.2", "audio-play": "^2.3.1", - "cohere-ai": "^7.14.0", - "openai": "^4.71.1" + "cohere-ai": "^7.15.0", + "openai": "^4.76.0" }, "devDependencies": { - "@eslint/js": "^9.14.0", + "@eslint/js": "^9.16.0", "@types/audio-context": "^1.0.3", "@types/audio-play": "^2.3.2", - "@types/node": "^22.9.0", - "eslint": "^8.57.1", + "@types/node": "^22.10.1", + "eslint": "^9.16.0", "eslint-config-prettier": "^9.1.0", "eslint-plugin-prettier": "^5.2.1", - "globals": "^15.12.0", + "globals": "^15.13.0", "json-schema-to-typescript": "^15.0.3", "patch-package": "^8.0.0", - "prettier": "^3.3.3", + "prettier": "^3.4.2", "tshy": "^3.0.2", "tsx": "^4.19.2", - "typescript": "^5.6.3", - "typescript-eslint": "^8.13.0" + "typescript": "^5.7.2", + "typescript-eslint": "^8.17.0" }, "optionalDependencies": { "speaker": "^0.5.5" @@ -1457,25 +1457,51 @@ } }, "node_modules/@eslint-community/regexpp": { - "version": "4.11.1", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.11.1.tgz", - "integrity": "sha512-m4DVN9ZqskZoLU5GlWZadwDnYo3vAEydiUayB9widCl9ffWx2IvPnp6n3on5rJmziJSw9Bv+Z3ChDVdMwXCY8Q==", + "version": "4.12.1", + "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.12.1.tgz", + "integrity": "sha512-CCZCDJuduB9OUkFkY2IgppNZMi2lBQgD2qzwXkEia16cge2pijY/aXi96CJMquDMn3nJdlPV1A5KrJEXwfLNzQ==", "dev": true, + "license": "MIT", "engines": { "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, + "node_modules/@eslint/config-array": { + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.19.0.tgz", + "integrity": "sha512-zdHg2FPIFNKPdcHWtiNT+jEFCHYVplAXRDlQDyqy0zGx/q2parwh7brGJSiTxRk/TSMkbM//zt/f5CHgyTyaSQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@eslint/object-schema": "^2.1.4", + "debug": "^4.3.1", + "minimatch": "^3.1.2" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + } + }, + "node_modules/@eslint/core": { + "version": "0.9.0", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.9.0.tgz", + "integrity": "sha512-7ATR9F0e4W85D/0w7cU0SNj7qkAexMG+bAHEZOjo9akvGuhHE2m7umzWzfnpa0XAg5Kxc1BWmtPMV67jJ+9VUg==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + } + }, "node_modules/@eslint/eslintrc": { - "version": "2.1.4", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.4.tgz", - "integrity": "sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-3.2.0.tgz", + "integrity": "sha512-grOjVNN8P3hjJn/eIETF1wwd12DdnwFDoyceUJLYYdkpbwq3nLi+4fqrTAONx7XDALqlL220wC/RHSC/QTI/0w==", "dev": true, "license": "MIT", "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", - "espree": "^9.6.0", - "globals": "^13.19.0", + "espree": "^10.0.1", + "globals": "^14.0.0", "ignore": "^5.2.0", "import-fresh": "^3.2.1", "js-yaml": "^4.1.0", @@ -1483,38 +1509,58 @@ "strip-json-comments": "^3.1.1" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "url": "https://opencollective.com/eslint" } }, "node_modules/@eslint/eslintrc/node_modules/globals": { - "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", + "version": "14.0.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz", + "integrity": "sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==", "dev": true, "license": "MIT", - "dependencies": { - "type-fest": "^0.20.2" - }, "engines": { - "node": ">=8" + "node": ">=18" }, "funding": { "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/@eslint/js": { - "version": "9.14.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.14.0.tgz", - "integrity": "sha512-pFoEtFWCPyDOl+C6Ift+wC7Ro89otjigCf5vcuWqWgqNSQbRrpjSvdeE6ofLz4dHmyxD5f7gIdGT4+p36L6Twg==", + "version": "9.16.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.16.0.tgz", + "integrity": "sha512-tw2HxzQkrbeuvyj1tG2Yqq+0H9wGoI2IMk4EOsQeX+vmd75FtJAzf+gTA69WF+baUKRYQ3x2kbLE08js5OsTVg==", "dev": true, "license": "MIT", "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, + "node_modules/@eslint/object-schema": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.4.tgz", + "integrity": "sha512-BsWiH1yFGjXXS2yvrf5LyuoSIIbPrGUWob917o+BTKuZ7qJdxX8aJLRxs1fS9n6r7vESrq1OUqb68dANcFXuQQ==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + } + }, + "node_modules/@eslint/plugin-kit": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.2.3.tgz", + "integrity": "sha512-2b/g5hRmpbb1o4GnTZax9N9m0FXzz9OV42ZzI4rDDMDuHUqigAiQCEWChBWCY4ztAGVRjoWT19v0yMmc5/L5kA==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "levn": "^0.4.1" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + } + }, "node_modules/@google/generative-ai": { "version": "0.21.0", "resolved": "https://registry.npmjs.org/@google/generative-ai/-/generative-ai-0.21.0.tgz", @@ -1527,20 +1573,42 @@ "resolved": "javascript", "link": true }, - "node_modules/@humanwhocodes/config-array": { - "version": "0.13.0", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.13.0.tgz", - "integrity": "sha512-DZLEEqFWQFiyK6h5YIeynKx7JlvCYWL0cImfSRXZ9l4Sg2efkFGTuFf6vzXjK1cq6IYkU+Eg/JizXw+TD2vRNw==", - "deprecated": "Use @eslint/config-array instead", + "node_modules/@humanfs/core": { + "version": "0.19.1", + "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.1.tgz", + "integrity": "sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=18.18.0" + } + }, + "node_modules/@humanfs/node": { + "version": "0.16.6", + "resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.6.tgz", + "integrity": "sha512-YuI2ZHQL78Q5HbhDiBA1X4LmYdXCKCMQIfw0pw7piHJwyREFebJUvrQN4cMssyES6x+vfUbx1CIpaQUKYdQZOw==", "dev": true, "license": "Apache-2.0", "dependencies": { - "@humanwhocodes/object-schema": "^2.0.3", - "debug": "^4.3.1", - "minimatch": "^3.0.5" + "@humanfs/core": "^0.19.1", + "@humanwhocodes/retry": "^0.3.0" }, "engines": { - "node": ">=10.10.0" + "node": ">=18.18.0" + } + }, + "node_modules/@humanfs/node/node_modules/@humanwhocodes/retry": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.3.1.tgz", + "integrity": "sha512-JBxkERygn7Bv/GbN5Rv8Ul6LVknS+5Bp6RgDC/O8gEBU/yeH5Ui5C/OlWrTb6qct7LjjfT6Re2NxB0ln0yYybA==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=18.18" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" } }, "node_modules/@humanwhocodes/module-importer": { @@ -1557,13 +1625,19 @@ "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/@humanwhocodes/object-schema": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-2.0.3.tgz", - "integrity": "sha512-93zYdMES/c1D69yZiKDBj0V24vqNzB/koF26KPaagAfd3P/4gUlh3Dys5ogAK+Exi9QyzlD8x/08Zt7wIKcDcA==", - "deprecated": "Use @eslint/object-schema instead", + "node_modules/@humanwhocodes/retry": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.4.1.tgz", + "integrity": "sha512-c7hNEllBlenFTHBky65mhq8WD2kbN9Q6gk0bTk8lSBvc554jpXSkST1iePudpt7+A/AQvuHs9EMqjHDXMY1lrA==", "dev": true, - "license": "BSD-3-Clause" + "license": "Apache-2.0", + "engines": { + "node": ">=18.18" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/nzakas" + } }, "node_modules/@isaacs/cliui": { "version": "8.0.2", @@ -1669,10 +1743,12 @@ "license": "MIT" }, "node_modules/@mistralai/mistralai": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/@mistralai/mistralai/-/mistralai-1.3.0.tgz", - "integrity": "sha512-G5DPCSC8sEhG3LUEZDYLD7qEZWDuZXgaX3IcoC3a/ydm9jFuh2pRZtknsgMx2sU8d7kxRuxblY3fPH5C38wnhQ==", + "version": "1.3.5", + "resolved": "https://registry.npmjs.org/@mistralai/mistralai/-/mistralai-1.3.5.tgz", + "integrity": "sha512-yC91oJ5ScEPqbXmv3mJTwTFgu/ZtsYoOPOhaVXSsy6x4zXTqTI57yEC1flC9uiA8GpG/yhpn2BBUXF95+U9Blw==", "peerDependencies": { + "react": "^18 || ^19", + "react-dom": "^18 || ^19", "zod": ">= 3" } }, @@ -2391,6 +2467,13 @@ "integrity": "sha512-tGQbApfao04cIIiN6GtAJFjnJsdiN1L3zL90a8BKqsTycO0XxlQ8BR436MoZIlR2fBdP0IUJdTVbDweiHLVPnQ==", "dev": true }, + "node_modules/@types/estree": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.6.tgz", + "integrity": "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==", + "dev": true, + "license": "MIT" + }, "node_modules/@types/json-schema": { "version": "7.0.15", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", @@ -2405,12 +2488,12 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "22.9.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.9.0.tgz", - "integrity": "sha512-vuyHg81vvWA1Z1ELfvLko2c8f34gyA0zaic0+Rllc5lbCnbSyuvb2Oxpm6TAUAC/2xZN3QGqxBNggD1nNR2AfQ==", + "version": "22.10.1", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.1.tgz", + "integrity": "sha512-qKgsUwfHZV2WCWLAnVP1JqnpE6Im6h3Y0+fYgMTasNQ7V++CBX5OT1as0g0f+OyubbFqhf6XVNIsmN4IIhEgGQ==", "license": "MIT", "dependencies": { - "undici-types": "~6.19.8" + "undici-types": "~6.20.0" } }, "node_modules/@types/node-fetch": { @@ -2428,12 +2511,242 @@ "integrity": "sha512-jg+97EGIcY9AGHJJRaaPVgetKDsrTgbRjQ5Msgjh/DQKEFl0DtyRr/VCOyD1T2R1MNeWPK/u7JoGhlDZnKBAfA==", "license": "MIT" }, - "node_modules/@ungap/structured-clone": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", - "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", + "node_modules/@typescript-eslint/eslint-plugin": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.17.0.tgz", + "integrity": "sha512-HU1KAdW3Tt8zQkdvNoIijfWDMvdSweFYm4hWh+KwhPstv+sCmWb89hCIP8msFm9N1R/ooh9honpSuvqKWlYy3w==", "dev": true, - "license": "ISC" + "license": "MIT", + "dependencies": { + "@eslint-community/regexpp": "^4.10.0", + "@typescript-eslint/scope-manager": "8.17.0", + "@typescript-eslint/type-utils": "8.17.0", + "@typescript-eslint/utils": "8.17.0", + "@typescript-eslint/visitor-keys": "8.17.0", + "graphemer": "^1.4.0", + "ignore": "^5.3.1", + "natural-compare": "^1.4.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "@typescript-eslint/parser": "^8.0.0 || ^8.0.0-alpha.0", + "eslint": "^8.57.0 || ^9.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/parser": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.17.0.tgz", + "integrity": "sha512-Drp39TXuUlD49F7ilHHCG7TTg8IkA+hxCuULdmzWYICxGXvDXmDmWEjJYZQYgf6l/TFfYNE167m7isnc3xlIEg==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "@typescript-eslint/scope-manager": "8.17.0", + "@typescript-eslint/types": "8.17.0", + "@typescript-eslint/typescript-estree": "8.17.0", + "@typescript-eslint/visitor-keys": "8.17.0", + "debug": "^4.3.4" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.57.0 || ^9.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/scope-manager": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.17.0.tgz", + "integrity": "sha512-/ewp4XjvnxaREtqsZjF4Mfn078RD/9GmiEAtTeLQ7yFdKnqwTOgRMSvFz4et9U5RiJQ15WTGXPLj89zGusvxBg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.17.0", + "@typescript-eslint/visitor-keys": "8.17.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/type-utils": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.17.0.tgz", + "integrity": "sha512-q38llWJYPd63rRnJ6wY/ZQqIzPrBCkPdpIsaCfkR3Q4t3p6sb422zougfad4TFW9+ElIFLVDzWGiGAfbb/v2qw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/typescript-estree": "8.17.0", + "@typescript-eslint/utils": "8.17.0", + "debug": "^4.3.4", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.57.0 || ^9.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/types": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.17.0.tgz", + "integrity": "sha512-gY2TVzeve3z6crqh2Ic7Cr+CAv6pfb0Egee7J5UAVWCpVvDI/F71wNfolIim4FE6hT15EbpZFVUj9j5i38jYXA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/typescript-estree": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.17.0.tgz", + "integrity": "sha512-JqkOopc1nRKZpX+opvKqnM3XUlM7LpFMD0lYxTqOTKQfCWAmxw45e3qlOCsEqEB2yuacujivudOFpCnqkBDNMw==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "@typescript-eslint/types": "8.17.0", + "@typescript-eslint/visitor-keys": "8.17.0", + "debug": "^4.3.4", + "fast-glob": "^3.3.2", + "is-glob": "^4.0.3", + "minimatch": "^9.0.4", + "semver": "^7.6.0", + "ts-api-utils": "^1.3.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/brace-expansion": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", + "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch": { + "version": "9.0.5", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", + "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/@typescript-eslint/utils": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.17.0.tgz", + "integrity": "sha512-bQC8BnEkxqG8HBGKwG9wXlZqg37RKSMY7v/X8VEWD8JG2JuTHuNK0VFvMPMUKQcbk6B+tf05k+4AShAEtCtJ/w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@eslint-community/eslint-utils": "^4.4.0", + "@typescript-eslint/scope-manager": "8.17.0", + "@typescript-eslint/types": "8.17.0", + "@typescript-eslint/typescript-estree": "8.17.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^8.57.0 || ^9.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/visitor-keys": { + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.17.0.tgz", + "integrity": "sha512-1Hm7THLpO6ww5QU6H/Qp+AusUUl+z/CAm3cNZZ0jQvon9yicgO7Rwd+/WWRpMKLYV6p2UvdbR27c86rzCPpreg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "8.17.0", + "eslint-visitor-keys": "^4.2.0" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/visitor-keys/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } }, "node_modules/@wasm-audio-decoders/common": { "version": "9.0.5", @@ -3103,14 +3416,15 @@ "integrity": "sha512-Ru9t80fV8B0ZiixQl8xhMTLru+dzuis/KQld32/x5T/+3LwZb0/YvQdSKytX9JqCnRdiupvAvyYJINKrXieziQ==" }, "node_modules/cohere-ai": { - "version": "7.14.0", - "resolved": "https://registry.npmjs.org/cohere-ai/-/cohere-ai-7.14.0.tgz", - "integrity": "sha512-hSo2/tFV29whjFFtVtdS7kHmtUsjfMO1sgwE/d5bhOE4O7Vkj5G1R9lLIqkIprp/+rrvCq3HGvEaOgry7xRcDA==", + "version": "7.15.0", + "resolved": "https://registry.npmjs.org/cohere-ai/-/cohere-ai-7.15.0.tgz", + "integrity": "sha512-yhyoUdLXKePmGMxJVOtmvJCKt8WdVAK/fdzgk/IHQJTDOYCRyFeulGxayFY5xUv7MkRRLVsVKDU5sx2NLcG+qA==", "dependencies": { "@aws-sdk/client-sagemaker": "^3.583.0", "@aws-sdk/credential-providers": "^3.583.0", "@aws-sdk/protocol-http": "^3.374.0", "@aws-sdk/signature-v4": "^3.374.0", + "convict": "^6.2.4", "form-data": "^4.0.0", "form-data-encoder": "^4.0.2", "formdata-node": "^6.0.3", @@ -3177,10 +3491,23 @@ "dev": true, "license": "MIT" }, + "node_modules/convict": { + "version": "6.2.4", + "resolved": "https://registry.npmjs.org/convict/-/convict-6.2.4.tgz", + "integrity": "sha512-qN60BAwdMVdofckX7AlohVJ2x9UvjTNoKVXCL2LxFk1l7757EJqf1nySdMkPQer0bt8kQ5lQiyZ9/2NvrFBuwQ==", + "license": "Apache-2.0", + "dependencies": { + "lodash.clonedeep": "^4.5.0", + "yargs-parser": "^20.2.7" + }, + "engines": { + "node": ">=6" + } + }, "node_modules/cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", "dev": true, "license": "MIT", "dependencies": { @@ -3249,19 +3576,6 @@ "node": ">=0.4.0" } }, - "node_modules/doctrine": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", - "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "esutils": "^2.0.2" - }, - "engines": { - "node": ">=6.0.0" - } - }, "node_modules/eastasianwidth": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", @@ -3346,60 +3660,63 @@ } }, "node_modules/eslint": { - "version": "8.57.1", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.57.1.tgz", - "integrity": "sha512-ypowyDxpVSYpkXr9WPv2PAZCtNip1Mv5KTW0SCurXv/9iOpcrH9PaqUElksqEB6pChqHGDRCFTyrZlGhnLNGiA==", - "deprecated": "This version is no longer supported. Please see https://eslint.org/version-support for other options.", + "version": "9.16.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.16.0.tgz", + "integrity": "sha512-whp8mSQI4C8VXd+fLgSM0lh3UlmcFtVwUQjyKCFfsp+2ItAIYhlq/hqGahGqHE6cv9unM41VlqKk2VtKYR2TaA==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.2.0", - "@eslint-community/regexpp": "^4.6.1", - "@eslint/eslintrc": "^2.1.4", - "@eslint/js": "8.57.1", - "@humanwhocodes/config-array": "^0.13.0", + "@eslint-community/regexpp": "^4.12.1", + "@eslint/config-array": "^0.19.0", + "@eslint/core": "^0.9.0", + "@eslint/eslintrc": "^3.2.0", + "@eslint/js": "9.16.0", + "@eslint/plugin-kit": "^0.2.3", + "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", - "@nodelib/fs.walk": "^1.2.8", - "@ungap/structured-clone": "^1.2.0", + "@humanwhocodes/retry": "^0.4.1", + "@types/estree": "^1.0.6", + "@types/json-schema": "^7.0.15", "ajv": "^6.12.4", "chalk": "^4.0.0", - "cross-spawn": "^7.0.2", + "cross-spawn": "^7.0.5", "debug": "^4.3.2", - "doctrine": "^3.0.0", "escape-string-regexp": "^4.0.0", - "eslint-scope": "^7.2.2", - "eslint-visitor-keys": "^3.4.3", - "espree": "^9.6.1", - "esquery": "^1.4.2", + "eslint-scope": "^8.2.0", + "eslint-visitor-keys": "^4.2.0", + "espree": "^10.3.0", + "esquery": "^1.5.0", "esutils": "^2.0.2", "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^6.0.1", + "file-entry-cache": "^8.0.0", "find-up": "^5.0.0", "glob-parent": "^6.0.2", - "globals": "^13.19.0", - "graphemer": "^1.4.0", "ignore": "^5.2.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", - "is-path-inside": "^3.0.3", - "js-yaml": "^4.1.0", "json-stable-stringify-without-jsonify": "^1.0.1", - "levn": "^0.4.1", "lodash.merge": "^4.6.2", "minimatch": "^3.1.2", "natural-compare": "^1.4.0", - "optionator": "^0.9.3", - "strip-ansi": "^6.0.1", - "text-table": "^0.2.0" + "optionator": "^0.9.3" }, "bin": { "eslint": "bin/eslint.js" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { - "url": "https://opencollective.com/eslint" + "url": "https://eslint.org/donate" + }, + "peerDependencies": { + "jiti": "*" + }, + "peerDependenciesMeta": { + "jiti": { + "optional": true + } } }, "node_modules/eslint-config-prettier": { @@ -3447,9 +3764,9 @@ } }, "node_modules/eslint-scope": { - "version": "7.2.2", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", - "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==", + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-8.2.0.tgz", + "integrity": "sha512-PHlWUfG6lvPc3yvP5A4PNyBL1W8fkDUccmI21JUu/+GKZBoH/W5u6usENXUrWFRsyoW5ACUjFGgAFQp5gUlb/A==", "dev": true, "license": "BSD-2-Clause", "dependencies": { @@ -3457,7 +3774,7 @@ "estraverse": "^5.2.0" }, "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "url": "https://opencollective.com/eslint" @@ -3476,45 +3793,45 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/eslint/node_modules/@eslint/js": { - "version": "8.57.1", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.57.1.tgz", - "integrity": "sha512-d9zaMRSTIKDLhctzH12MtXvJKSSUhaHcjV+2Z+GK+EEY7XKpP5yR4x+N3TAcHTcu963nIr+TMcCb4DBCYX1z6Q==", + "node_modules/eslint/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", "dev": true, - "license": "MIT", + "license": "Apache-2.0", "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, - "node_modules/eslint/node_modules/globals": { - "version": "13.24.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", - "integrity": "sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==", + "node_modules/espree": { + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/espree/-/espree-10.3.0.tgz", + "integrity": "sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==", "dev": true, - "license": "MIT", + "license": "BSD-2-Clause", "dependencies": { - "type-fest": "^0.20.2" + "acorn": "^8.14.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^4.2.0" }, "engines": { - "node": ">=8" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { - "url": "https://github.com/sponsors/sindresorhus" + "url": "https://opencollective.com/eslint" } }, - "node_modules/espree": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz", - "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==", + "node_modules/espree/node_modules/eslint-visitor-keys": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz", + "integrity": "sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==", "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "acorn": "^8.9.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^3.4.1" - }, + "license": "Apache-2.0", "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" }, "funding": { "url": "https://opencollective.com/eslint" @@ -3674,16 +3991,16 @@ } }, "node_modules/file-entry-cache": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", - "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz", + "integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==", "dev": true, "license": "MIT", "dependencies": { - "flat-cache": "^3.0.4" + "flat-cache": "^4.0.0" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": ">=16.0.0" } }, "node_modules/file-uri-to-path": { @@ -3733,24 +4050,23 @@ } }, "node_modules/flat-cache": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.2.0.tgz", - "integrity": "sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz", + "integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==", "dev": true, "license": "MIT", "dependencies": { "flatted": "^3.2.9", - "keyv": "^4.5.3", - "rimraf": "^3.0.2" + "keyv": "^4.5.4" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": ">=16" } }, "node_modules/flatted": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.1.tgz", - "integrity": "sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==", + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.2.tgz", + "integrity": "sha512-AiwGJM8YcNOaobumgtng+6NHuOqC3A7MixFeDafM3X9cIUM+xUXoS5Vfgf+OihAYe20fxqNM9yPBXJzRtZ/4eA==", "dev": true, "license": "ISC" }, @@ -3917,9 +4233,9 @@ } }, "node_modules/globals": { - "version": "15.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-15.12.0.tgz", - "integrity": "sha512-1+gLErljJFhbOVyaetcwJiJ4+eLe45S2E7P5UiZ9xGfeq3ATQf5DOv9G7MH3gGbKQLkzmNh2DxfZwLdw+j6oTQ==", + "version": "15.13.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-15.13.0.tgz", + "integrity": "sha512-49TewVEz0UxZjr1WYYsWpPrhyC/B/pA8Bq0fUmet2n+eR7yn0IvNzNaoBwnK6mdkzcN+se7Ez9zUgULTz2QH4g==", "dev": true, "license": "MIT", "engines": { @@ -4207,16 +4523,6 @@ "node": ">=0.12.0" } }, - "node_modules/is-path-inside": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/is-plain-obj": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-1.1.0.tgz", @@ -4437,6 +4743,12 @@ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "dev": true }, + "node_modules/lodash.clonedeep": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz", + "integrity": "sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==", + "license": "MIT" + }, "node_modules/lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", @@ -4683,9 +4995,9 @@ } }, "node_modules/openai": { - "version": "4.71.1", - "resolved": "https://registry.npmjs.org/openai/-/openai-4.71.1.tgz", - "integrity": "sha512-C6JNMaQ1eijM0lrjiRUL3MgThVP5RdwNAghpbJFdW0t11LzmyqON8Eh8MuUuEZ+CeD6bgYl2Fkn2BoptVxv9Ug==", + "version": "4.76.0", + "resolved": "https://registry.npmjs.org/openai/-/openai-4.76.0.tgz", + "integrity": "sha512-QBGIetjX1C9xDp5XGa/3mPnfKI9BgAe2xHQX6PmO98wuW9qQaurBaumcYptQWc9LHZZq7cH/Y1Rjnsr6uUDdVw==", "license": "Apache-2.0", "dependencies": { "@types/node": "^18.11.18", @@ -5004,10 +5316,11 @@ } }, "node_modules/prettier": { - "version": "3.3.3", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.3.3.tgz", - "integrity": "sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==", + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.4.2.tgz", + "integrity": "sha512-e9MewbtFo+Fevyuxn/4rrcDAaq0IYxPGLvObpQjiZBMAzB9IGmzlnG9RZy3FFas+eBMu2vA0CszMeduow5dIuQ==", "dev": true, + "license": "MIT", "bin": { "prettier": "bin/prettier.cjs" }, @@ -5099,6 +5412,29 @@ ], "license": "MIT" }, + "node_modules/react": { + "version": "19.0.0", + "resolved": "https://registry.npmjs.org/react/-/react-19.0.0.tgz", + "integrity": "sha512-V8AVnmPIICiWpGfm6GLzCR/W5FXLchHop40W4nXBmdlEceh16rCN8O8LNWm5bh5XUX91fh7KpA+W0TgMKmgTpQ==", + "license": "MIT", + "peer": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-dom": { + "version": "19.0.0", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.0.0.tgz", + "integrity": "sha512-4GV5sHFG0e/0AD4X+ySy6UJd3jVl1iNsNHdpad0qhABJ11twS3TTBnseqsKurKcsNqCEFeGL3uLpVChpIO3QfQ==", + "license": "MIT", + "peer": true, + "dependencies": { + "scheduler": "^0.25.0" + }, + "peerDependencies": { + "react": "^19.0.0" + } + }, "node_modules/readable-stream": { "version": "4.5.2", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-4.5.2.tgz", @@ -5229,23 +5565,6 @@ "node": ">=0.10.0" } }, - "node_modules/rimraf": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", - "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", - "deprecated": "Rimraf versions prior to v4 are no longer supported", - "dev": true, - "license": "ISC", - "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -5295,6 +5614,13 @@ "resolved": "https://registry.npmjs.org/sample-rate/-/sample-rate-2.0.1.tgz", "integrity": "sha512-AIK0vVBiAEObmpJOxQu/WCyklnWGqzTSDII4O7nBo+SJHmfgBUiYhgV/Y3Ohz76gfSlU6R5CIAKggj+nAOLSvg==" }, + "node_modules/scheduler": { + "version": "0.25.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.25.0.tgz", + "integrity": "sha512-xFVuu11jh+xcO7JOAGJNOXld8/TcEHK/4CituBUeUb5hqxJLj9YuemAEuvm9gQ/+pgXYfbQuqAkiYu+u7YEsNA==", + "license": "MIT", + "peer": true + }, "node_modules/semver": { "version": "7.6.2", "resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz", @@ -5644,13 +5970,6 @@ "url": "https://opencollective.com/unts" } }, - "node_modules/text-table": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", - "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", - "dev": true, - "license": "MIT" - }, "node_modules/tinyglobby": { "version": "0.2.10", "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.10.tgz", @@ -5740,9 +6059,9 @@ "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" }, "node_modules/ts-api-utils": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-1.4.0.tgz", - "integrity": "sha512-032cPxaEKwM+GT3vA5JXNzIaizx388rhsSW79vGRNGXfRRAdEAn2mvk36PvK5HnOchyWZ7afLEXqYCvPCrzuzQ==", + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/ts-api-utils/-/ts-api-utils-1.4.3.tgz", + "integrity": "sha512-i3eMG77UTMD0hZhgRS562pv83RC6ukSAC2GMNWc+9dieh/+jDM5u5YG+NHX6VNDRHQcHwmsTHctP9LhbC3WxVw==", "dev": true, "license": "MIT", "engines": { @@ -5917,29 +6236,17 @@ "node": ">= 0.8.0" } }, - "node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true, - "license": "(MIT OR CC0-1.0)", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/typedarray-methods": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/typedarray-methods/-/typedarray-methods-1.0.1.tgz", "integrity": "sha512-fstWAa225OZ856/4npMqgJP6U1U3vTWnqkn9wokZXzME9pORW9dV8u/v1VRGpo584udKMvCIYlNXzKoIb+UUGg==" }, "node_modules/typescript": { - "version": "5.6.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.6.3.tgz", - "integrity": "sha512-hjcS1mhfuyi4WW8IWtjP7brDrG2cuDZukyrYrSauoXGNgx0S7zceP07adYkJycEr56BOUTNPzbInooiN3fn1qw==", + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.7.2.tgz", + "integrity": "sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg==", "dev": true, + "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -5949,75 +6256,15 @@ } }, "node_modules/typescript-eslint": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.13.0.tgz", - "integrity": "sha512-vIMpDRJrQd70au2G8w34mPps0ezFSPMEX4pXkTzUkrNbRX+36ais2ksGWN0esZL+ZMaFJEneOBHzCgSqle7DHw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/eslint-plugin": "8.13.0", - "@typescript-eslint/parser": "8.13.0", - "@typescript-eslint/utils": "8.13.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.13.0.tgz", - "integrity": "sha512-nQtBLiZYMUPkclSeC3id+x4uVd1SGtHuElTxL++SfP47jR0zfkZBJHc+gL4qPsgTuypz0k8Y2GheaDYn6Gy3rg==", + "version": "8.17.0", + "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.17.0.tgz", + "integrity": "sha512-409VXvFd/f1br1DCbuKNFqQpXICoTB+V51afcwG1pn1a3Cp92MqAUges3YjwEdQ0cMUoCIodjVDAYzyD8h3SYA==", "dev": true, "license": "MIT", "dependencies": { - "@eslint-community/regexpp": "^4.10.0", - "@typescript-eslint/scope-manager": "8.13.0", - "@typescript-eslint/type-utils": "8.13.0", - "@typescript-eslint/utils": "8.13.0", - "@typescript-eslint/visitor-keys": "8.13.0", - "graphemer": "^1.4.0", - "ignore": "^5.3.1", - "natural-compare": "^1.4.0", - "ts-api-utils": "^1.3.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "@typescript-eslint/parser": "^8.0.0 || ^8.0.0-alpha.0", - "eslint": "^8.57.0 || ^9.0.0" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/parser": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.13.0.tgz", - "integrity": "sha512-w0xp+xGg8u/nONcGw1UXAr6cjCPU1w0XVyBs6Zqaj5eLmxkKQAByTdV/uGgNN5tVvN/kKpoQlP2cL7R+ajZZIQ==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "@typescript-eslint/scope-manager": "8.13.0", - "@typescript-eslint/types": "8.13.0", - "@typescript-eslint/typescript-estree": "8.13.0", - "@typescript-eslint/visitor-keys": "8.13.0", - "debug": "^4.3.4" + "@typescript-eslint/eslint-plugin": "8.17.0", + "@typescript-eslint/parser": "8.17.0", + "@typescript-eslint/utils": "8.17.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -6035,163 +6282,11 @@ } } }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/scope-manager": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.13.0.tgz", - "integrity": "sha512-XsGWww0odcUT0gJoBZ1DeulY1+jkaHUciUq4jKNv4cpInbvvrtDoyBH9rE/n2V29wQJPk8iCH1wipra9BhmiMA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/types": "8.13.0", - "@typescript-eslint/visitor-keys": "8.13.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/type-utils": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.13.0.tgz", - "integrity": "sha512-Rqnn6xXTR316fP4D2pohZenJnp+NwQ1mo7/JM+J1LWZENSLkJI8ID8QNtlvFeb0HnFSK94D6q0cnMX6SbE5/vA==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/typescript-estree": "8.13.0", - "@typescript-eslint/utils": "8.13.0", - "debug": "^4.3.4", - "ts-api-utils": "^1.3.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/types": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.13.0.tgz", - "integrity": "sha512-4cyFErJetFLckcThRUFdReWJjVsPCqyBlJTi6IDEpc1GWCIIZRFxVppjWLIMcQhNGhdWJJRYFHpHoDWvMlDzng==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/typescript-estree": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.13.0.tgz", - "integrity": "sha512-v7SCIGmVsRK2Cy/LTLGN22uea6SaUIlpBcO/gnMGT/7zPtxp90bphcGf4fyrCQl3ZtiBKqVTG32hb668oIYy1g==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "@typescript-eslint/types": "8.13.0", - "@typescript-eslint/visitor-keys": "8.13.0", - "debug": "^4.3.4", - "fast-glob": "^3.3.2", - "is-glob": "^4.0.3", - "minimatch": "^9.0.4", - "semver": "^7.6.0", - "ts-api-utils": "^1.3.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependenciesMeta": { - "typescript": { - "optional": true - } - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/utils": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.13.0.tgz", - "integrity": "sha512-A1EeYOND6Uv250nybnLZapeXpYMl8tkzYUxqmoKAWnI4sei3ihf2XdZVd+vVOmHGcp3t+P7yRrNsyyiXTvShFQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.4.0", - "@typescript-eslint/scope-manager": "8.13.0", - "@typescript-eslint/types": "8.13.0", - "@typescript-eslint/typescript-estree": "8.13.0" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - }, - "peerDependencies": { - "eslint": "^8.57.0 || ^9.0.0" - } - }, - "node_modules/typescript-eslint/node_modules/@typescript-eslint/visitor-keys": { - "version": "8.13.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.13.0.tgz", - "integrity": "sha512-7N/+lztJqH4Mrf0lb10R/CbI1EaAMMGyF5y0oJvFoAhafwgiRA7TXyd8TFn8FC8k5y2dTsYogg238qavRGNnlw==", - "dev": true, - "license": "MIT", - "dependencies": { - "@typescript-eslint/types": "8.13.0", - "eslint-visitor-keys": "^3.4.3" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/typescript-eslint" - } - }, - "node_modules/typescript-eslint/node_modules/brace-expansion": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", - "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^1.0.0" - } - }, - "node_modules/typescript-eslint/node_modules/minimatch": { - "version": "9.0.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", - "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.1" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/undici-types": { - "version": "6.19.8", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz", - "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==" + "version": "6.20.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", + "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", + "license": "MIT" }, "node_modules/universalify": { "version": "2.0.1", @@ -6377,6 +6472,15 @@ "node": ">= 14" } }, + "node_modules/yargs-parser": { + "version": "20.2.9", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.9.tgz", + "integrity": "sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w==", + "license": "ISC", + "engines": { + "node": ">=10" + } + }, "node_modules/yocto-queue": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", diff --git a/package.json b/package.json index 4e848a8..f2d2843 100644 --- a/package.json +++ b/package.json @@ -8,31 +8,31 @@ "postinstall": "patch-package" }, "devDependencies": { - "@eslint/js": "^9.14.0", + "@eslint/js": "^9.16.0", "@types/audio-context": "^1.0.3", "@types/audio-play": "^2.3.2", - "@types/node": "^22.9.0", - "eslint": "^8.57.1", + "@types/node": "^22.10.1", + "eslint": "^9.16.0", "eslint-config-prettier": "^9.1.0", "eslint-plugin-prettier": "^5.2.1", - "globals": "^15.12.0", + "globals": "^15.13.0", "json-schema-to-typescript": "^15.0.3", "patch-package": "^8.0.0", - "prettier": "^3.3.3", + "prettier": "^3.4.2", "tshy": "^3.0.2", "tsx": "^4.19.2", - "typescript": "^5.6.3", - "typescript-eslint": "^8.13.0" + "typescript": "^5.7.2", + "typescript-eslint": "^8.17.0" }, "dependencies": { "@anthropic-ai/sdk": "^0.32.1", "@google/generative-ai": "^0.21.0", - "@mistralai/mistralai": "^1.3.0", + "@mistralai/mistralai": "^1.3.5", "audio-context": "^1.0.3", "audio-decode": "^2.2.2", "audio-play": "^2.3.1", - "cohere-ai": "^7.14.0", - "openai": "^4.71.1" + "cohere-ai": "^7.15.0", + "openai": "^4.76.0" }, "optionalDependencies": { "speaker": "^0.5.5" From 97e7780e7b4b21a0514a7696bf4bb27b627f5306 Mon Sep 17 00:00:00 2001 From: Hoang Vo Date: Sat, 7 Dec 2024 05:09:21 +0700 Subject: [PATCH 4/5] feat(openai): support audio part id --- javascript/src/openai/openai.ts | 18 ++++++--- javascript/src/schema/schema.json | 28 ++++++++++++++ javascript/src/schema/schema.ts | 28 ++++++++++++++ javascript/src/utils/stream.utils.ts | 7 ++++ javascript/test/openai.test.ts | 58 ++++++++++++++++++++++++++++ schema/schema.json | 28 ++++++++++++++ 6 files changed, 162 insertions(+), 5 deletions(-) diff --git a/javascript/src/openai/openai.ts b/javascript/src/openai/openai.ts index aca81a9..def1eb2 100644 --- a/javascript/src/openai/openai.ts +++ b/javascript/src/openai/openai.ts @@ -235,10 +235,13 @@ export function convertToOpenAIMessages( break; } case "audio": { - throw new Error( - "Audio parts are not supported in assistant messages. Use options.convertAudioPartsToTextParts" + - " to convert audio parts to text parts.", - ); + if (!part.id) { + throw new Error("audio part must have an id"); + } + openaiMessageParam.audio = { + id: part.id, + }; + break; } default: { const exhaustiveCheck: never = part; @@ -517,6 +520,7 @@ export function mapOpenAIMessage( if (message.audio) { content.push({ type: "audio", + id: message.audio.id, ...mapOpenAIAudioFormat(options?.audio?.format || "pcm16"), ...(options?.audio?.format === "pcm16" && { sampleRate: OPENAI_AUDIO_SAMPLE_RATE, @@ -556,7 +560,10 @@ export function mapOpenAIDelta( const contentDeltas: ContentDelta[] = []; if (delta.content) { - const part: TextPartDelta = { type: "text", text: delta.content }; + const part: TextPartDelta = { + type: "text", + text: delta.content, + }; contentDeltas.push({ index: guessDeltaIndex(part, [ ...existingContentDeltas, @@ -568,6 +575,7 @@ export function mapOpenAIDelta( if (delta.audio) { const part: AudioPartDelta = { type: "audio", + ...(delta.audio.id && { id: delta.audio.id }), ...(delta.audio.data && { audioData: delta.audio.data, ...mapOpenAIAudioFormat(options.audio?.format || "pcm16"), diff --git a/javascript/src/schema/schema.json b/javascript/src/schema/schema.json index 5585526..a8a854e 100644 --- a/javascript/src/schema/schema.json +++ b/javascript/src/schema/schema.json @@ -12,6 +12,10 @@ }, "text": { "type": "string" + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "text"], @@ -40,6 +44,10 @@ "height": { "type": "integer", "description": "The height of the image in pixels." + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "mimeType", "imageData"], @@ -84,6 +92,10 @@ "transcript": { "type": "string", "description": "The transcript of the audio." + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "audioData"], @@ -115,6 +127,10 @@ } ], "description": "The arguments to pass to the tool." + }, + "id": { + "type": "string", + "description": "The optional ID of the part. This might not be the same as the toolCallId." } }, "required": ["type", "toolCallId", "toolName", "args"], @@ -239,6 +255,10 @@ }, "text": { "type": "string" + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "text"], @@ -262,6 +282,10 @@ "args": { "type": "string", "description": "The partial JSON string of the arguments to pass to the tool." + }, + "id": { + "type": "string", + "description": "The optional ID of the part. This might not be the same as the toolCallId." } }, "required": ["type"], @@ -295,6 +319,10 @@ "transcript": { "type": "string", "description": "The transcript of the audio." + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type"], diff --git a/javascript/src/schema/schema.ts b/javascript/src/schema/schema.ts index 83db0ea..3ecb50b 100644 --- a/javascript/src/schema/schema.ts +++ b/javascript/src/schema/schema.ts @@ -52,6 +52,10 @@ export interface LlmSdk { export interface TextPart { type: "text"; text: string; + /** + * The optional ID of the part. + */ + id?: string; } /** * A part of the message that contains an image. @@ -77,6 +81,10 @@ export interface ImagePart { * The height of the image in pixels. */ height?: number; + /** + * The optional ID of the part. + */ + id?: string; } /** * A part of the message that contains an audio. @@ -104,6 +112,10 @@ export interface AudioPart { * The transcript of the audio. */ transcript?: string; + /** + * The optional ID of the part. + */ + id?: string; } /** * A part of the message that represents a call to a tool the model wants to use. @@ -127,6 +139,10 @@ export interface ToolCallPart { args: { [k: string]: unknown; } | null; + /** + * The optional ID of the part. This might not be the same as the toolCallId. + */ + id?: string; } /** * A part of the message that represents the result of a tool call. @@ -184,6 +200,10 @@ export interface AssistantMessage { export interface TextPartDelta { type: "text"; text: string; + /** + * The optional ID of the part. + */ + id?: string; } /** * This interface was referenced by `LlmSdk`'s JSON-Schema @@ -203,6 +223,10 @@ export interface ToolCallPartDelta { * The partial JSON string of the arguments to pass to the tool. */ args?: string; + /** + * The optional ID of the part. This might not be the same as the toolCallId. + */ + id?: string; } /** * This interface was referenced by `LlmSdk`'s JSON-Schema @@ -228,6 +252,10 @@ export interface AudioPartDelta { * The transcript of the audio. */ transcript?: string; + /** + * The optional ID of the part. + */ + id?: string; } /** * This interface was referenced by `LlmSdk`'s JSON-Schema diff --git a/javascript/src/utils/stream.utils.ts b/javascript/src/utils/stream.utils.ts index 934abe5..3f47f5b 100644 --- a/javascript/src/utils/stream.utils.ts +++ b/javascript/src/utils/stream.utils.ts @@ -31,6 +31,10 @@ export class ContentDeltaAccumulator { ); if (existingDelta) { + if (incomingDelta.part.id) { + existingDelta.part.id = incomingDelta.part.id; + } + if ( existingDelta.part.type === "text" && incomingDelta.part.type === "text" @@ -104,6 +108,7 @@ export class ContentDeltaAccumulator { switch (delta.part.type) { case "text": return { + ...(delta.part.id && { id: delta.part.id }), type: "text", text: delta.part.text, }; @@ -115,6 +120,7 @@ export class ContentDeltaAccumulator { } return { type: "tool-call", + ...(delta.part.id && { id: delta.part.id }), toolCallId: delta.part.toolCallId, args: delta.part.args ? (JSON.parse(delta.part.args) as Record) @@ -130,6 +136,7 @@ export class ContentDeltaAccumulator { const concatenatedAudioData = mergeInt16Arrays(delta.part.audioData); return { type: "audio", + ...(delta.part.id && { id: delta.part.id }), audioData: arrayBufferToBase64(concatenatedAudioData), encoding: delta.part.encoding, ...(delta.part.container && { container: delta.part.container }), diff --git a/javascript/test/openai.test.ts b/javascript/test/openai.test.ts index 4ae77bc..b866eff 100644 --- a/javascript/test/openai.test.ts +++ b/javascript/test/openai.test.ts @@ -108,6 +108,7 @@ suite("OpenAIModel", () => { t.assert.equal(audioPart!.audioData.length > 0, true); t.assert.equal(audioPart!.encoding!.length > 0, true); t.assert.equal(audioPart!.transcript!.length > 0, true); + t.assert.equal(!!audioPart?.id, true); }); test("stream audio", async (t) => { @@ -149,5 +150,62 @@ suite("OpenAIModel", () => { t.assert.equal(audioPart!.audioData.length > 0, true); t.assert.equal(audioPart!.encoding!.length > 0, true); t.assert.equal(audioPart!.transcript!.length > 0, true); + t.assert.equal(!!audioPart?.id, true); + }); + + test("generate with assistant audio part", async (t) => { + const response = await audioModel.generate({ + modalities: ["text", "audio"], + messages: [ + { + role: "user", + content: [ + { + type: "text", + text: "Hello", + }, + ], + }, + ], + extra: { + audio: { + voice: "alloy", + format: "mp3", + }, + }, + }); + + const audioPart = response.content.find((part) => part.type === "audio"); + t.assert.equal(!!audioPart?.id, true); + + const response2 = await audioModel.generate({ + modalities: ["text", "audio"], + messages: [ + { + role: "user", + content: [ + { + type: "text", + text: "Hello", + }, + ], + }, + { + role: "assistant", + content: response.content, + }, + ], + extra: { + audio: { + voice: "alloy", + format: "mp3", + }, + }, + }); + + log(response2); + + const audioPart2 = response2.content.find((part) => part.type === "audio"); + t.assert.equal(!!audioPart2, true); }); }); diff --git a/schema/schema.json b/schema/schema.json index 5585526..a8a854e 100644 --- a/schema/schema.json +++ b/schema/schema.json @@ -12,6 +12,10 @@ }, "text": { "type": "string" + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "text"], @@ -40,6 +44,10 @@ "height": { "type": "integer", "description": "The height of the image in pixels." + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "mimeType", "imageData"], @@ -84,6 +92,10 @@ "transcript": { "type": "string", "description": "The transcript of the audio." + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "audioData"], @@ -115,6 +127,10 @@ } ], "description": "The arguments to pass to the tool." + }, + "id": { + "type": "string", + "description": "The optional ID of the part. This might not be the same as the toolCallId." } }, "required": ["type", "toolCallId", "toolName", "args"], @@ -239,6 +255,10 @@ }, "text": { "type": "string" + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type", "text"], @@ -262,6 +282,10 @@ "args": { "type": "string", "description": "The partial JSON string of the arguments to pass to the tool." + }, + "id": { + "type": "string", + "description": "The optional ID of the part. This might not be the same as the toolCallId." } }, "required": ["type"], @@ -295,6 +319,10 @@ "transcript": { "type": "string", "description": "The transcript of the audio." + }, + "id": { + "type": "string", + "description": "The optional ID of the part." } }, "required": ["type"], From 681e7e8c7c596e465ba8e1530daacfbae3051829 Mon Sep 17 00:00:00 2001 From: Hoang Vo Date: Sat, 7 Dec 2024 05:51:20 +0700 Subject: [PATCH 5/5] version: 0.1.7 --- .../examples/generate-audio-multiturn.ts | 80 +++++++++++++++++++ javascript/package.json | 2 +- javascript/src/cohere/cohere.ts | 4 - package-lock.json | 2 +- 4 files changed, 82 insertions(+), 6 deletions(-) create mode 100644 javascript/examples/generate-audio-multiturn.ts diff --git a/javascript/examples/generate-audio-multiturn.ts b/javascript/examples/generate-audio-multiturn.ts new file mode 100644 index 0000000..7c18035 --- /dev/null +++ b/javascript/examples/generate-audio-multiturn.ts @@ -0,0 +1,80 @@ +import audioContext from "audio-context"; +import decodeAudio from "audio-decode"; +import play from "audio-play"; +import { openaiAudioModel } from "./model.js"; + +const response = await openaiAudioModel.generate({ + extra: { + audio: { + voice: "alloy", + format: "mp3", + }, + }, + modalities: ["text", "audio"], + messages: [ + { + role: "user", + content: [ + { + type: "text", + text: "Is a golden retriever a good family dog?", + }, + ], + }, + ], +}); + +console.dir(response, { depth: null }); + +const response2 = await openaiAudioModel.generate({ + extra: { + audio: { + voice: "alloy", + format: "mp3", + }, + }, + modalities: ["text", "audio"], + messages: [ + { + role: "user", + content: [ + { + type: "text", + text: "Is a golden retriever a good family dog?", + }, + ], + }, + { + role: "assistant", + content: response.content, + }, + { + role: "user", + content: [ + { + type: "text", + text: "What about a labrador?", + }, + ], + }, + ], +}); + +console.dir(response2, { depth: null }); + +const audioPart2 = response2.content.find((part) => part.type === "audio"); + +if (audioPart2) { + const audioBuffer2 = await decodeAudio( + Buffer.from(audioPart2.audioData, "base64"), + ); + const playback2 = play( + audioBuffer2, + { + // @ts-expect-error: it works ok? + context: audioContext, + }, + () => {}, + ); + playback2.play(); +} diff --git a/javascript/package.json b/javascript/package.json index 4d250fd..7552bb3 100644 --- a/javascript/package.json +++ b/javascript/package.json @@ -1,7 +1,7 @@ { "type": "module", "name": "@hoangvvo/llm-sdk", - "version": "0.1.6", + "version": "0.1.7", "description": "A unified LLM SDK", "scripts": { "generate": "node generate.js", diff --git a/javascript/src/cohere/cohere.ts b/javascript/src/cohere/cohere.ts index ee0020b..545a3af 100644 --- a/javascript/src/cohere/cohere.ts +++ b/javascript/src/cohere/cohere.ts @@ -52,10 +52,6 @@ export class CohereModel implements LanguageModel { convertToCohereParams(input, this.options), ); - if (!response.message) { - throw new Error("Response is missing message"); - } - const usage = response.usage ? mapCohereUsage(response.usage) : undefined; return { diff --git a/package-lock.json b/package-lock.json index 7147a66..1caa6a1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -41,7 +41,7 @@ }, "javascript": { "name": "@hoangvvo/llm-sdk", - "version": "0.1.6", + "version": "0.1.7", "license": "MIT" }, "node_modules/@anthropic-ai/sdk": {