diff --git a/binary/package-lock.json b/binary/package-lock.json index d1c773550..51ea6b1f1 100644 --- a/binary/package-lock.json +++ b/binary/package-lock.json @@ -44,11 +44,11 @@ "version": "1.1.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/client-bedrock-runtime": "^3.758.0", - "@aws-sdk/client-sagemaker-runtime": "^3.758.0", - "@aws-sdk/credential-providers": "^3.758.0", + "@aws-sdk/client-bedrock-runtime": "^3.779.0", + "@aws-sdk/client-sagemaker-runtime": "^3.777.0", + "@aws-sdk/credential-providers": "^3.778.0", "@continuedev/config-types": "^1.0.13", - "@continuedev/config-yaml": "^1.0.67", + "@continuedev/config-yaml": "^1.0.71", "@continuedev/fetch": "^1.0.4", "@continuedev/llm-info": "^1.0.8", "@continuedev/openai-adapters": "^1.0.18", @@ -67,6 +67,7 @@ "diff": "^7.0.0", "dotenv": "^16.4.5", "fastest-levenshtein": "^1.0.16", + "filtrex": "^3.1.0", "follow-redirects": "^1.15.5", "google-auth-library": "^9.14.2", "handlebars": "^4.7.8", diff --git a/core/autocomplete/context/root-path-context/RootPathContextService.ts b/core/autocomplete/context/root-path-context/RootPathContextService.ts index 79b598f1e..7a29f8a8f 100644 --- a/core/autocomplete/context/root-path-context/RootPathContextService.ts +++ b/core/autocomplete/context/root-path-context/RootPathContextService.ts @@ -88,7 +88,6 @@ export class RootPathContextService { default: // const type = node.type; // console.log(getSyntaxTreeString(node)); - // debugger; query = await getQueryForFile( filepath, @@ -165,7 +164,6 @@ export class RootPathContextService { )) { const key = RootPathContextService.keyFromNode(parentKey, astNode); // const type = astNode.type; - // debugger; const foundInCache = this.cache.get(key); const newSnippets = diff --git a/core/config/yaml/loadYaml.ts b/core/config/yaml/loadYaml.ts index 022ca8b53..c1e3d4167 100644 --- a/core/config/yaml/loadYaml.ts +++ b/core/config/yaml/loadYaml.ts @@ -235,15 +235,15 @@ async function configYamlToContinueConfig( for (const model of config.models ?? []) { model.roles = model.roles ?? modelsArrayRoles; // Default to all 4 chat-esque roles if not specified try { - const llms = await llmsFromModelConfig( + const llms = await llmsFromModelConfig({ model, ide, uniqueId, ideSettings, writeLog, platformConfigMetadata, - continueConfig.systemMessage, - ); + config: continueConfig, + }); if (modelsArrayRoles.some((role) => model.roles?.includes(role))) { continueConfig.models.push(...llms); diff --git a/core/config/yaml/models.ts b/core/config/yaml/models.ts index e9d5bd55c..6eabfd040 100644 --- a/core/config/yaml/models.ts +++ b/core/config/yaml/models.ts @@ -1,6 +1,6 @@ import { ModelConfig } from "@continuedev/config-yaml"; -import { IDE, IdeSettings, LLMOptions } from "../.."; +import { ContinueConfig, IDE, IdeSettings, LLMOptions } from "../.."; import { BaseLLM } from "../../llm"; import { LLMClasses } from "../../llm/llms"; import { PlatformConfigMetadata } from "../profile/PlatformProfileLoader"; @@ -13,22 +13,29 @@ function getModelClass( return LLMClasses.find((llm) => llm.providerName === model.provider); } -function getContinueProxyModelName( - ownerSlug: string, - packageSlug: string, - model: ModelConfig, -): string { - return `${ownerSlug}/${packageSlug}/${model.provider}/${model.model}`; -} +// function getContinueProxyModelName( +// ownerSlug: string, +// packageSlug: string, +// model: ModelConfig, +// ): string { +// return `${ownerSlug}/${packageSlug}/${model.provider}/${model.model}`; +// } -async function modelConfigToBaseLLM( - model: ModelConfig, - uniqueId: string, - ideSettings: IdeSettings, - writeLog: (log: string) => Promise, - platformConfigMetadata: PlatformConfigMetadata | undefined, - systemMessage: string | undefined, -): Promise { +async function modelConfigToBaseLLM({ + model, + uniqueId, + ideSettings, + writeLog, + platformConfigMetadata, + config, +}: { + model: ModelConfig; + uniqueId: string; + ideSettings: IdeSettings; + writeLog: (log: string) => Promise; + platformConfigMetadata: PlatformConfigMetadata | undefined; + config: ContinueConfig; +}): Promise { const cls = getModelClass(model); if (!cls) { @@ -50,7 +57,8 @@ async function modelConfigToBaseLLM( writeLog, uniqueId, title: model.name, - systemMessage, + systemMessage: config.systemMessage, + rules: config.rules, promptTemplates: model.promptTemplates, capabilities: { tools: model.capabilities?.includes("tool_use"), @@ -127,16 +135,25 @@ async function modelConfigToBaseLLM( return llm; } -async function autodetectModels( - llm: BaseLLM, - model: ModelConfig, - ide: IDE, - uniqueId: string, - ideSettings: IdeSettings, - writeLog: (log: string) => Promise, - platformConfigMetadata: PlatformConfigMetadata | undefined, - systemMessage: string | undefined, -): Promise { +async function autodetectModels({ + llm, + model, + ide, + uniqueId, + ideSettings, + writeLog, + platformConfigMetadata, + config, +}: { + llm: BaseLLM; + model: ModelConfig; + ide: IDE; + uniqueId: string; + ideSettings: IdeSettings; + writeLog: (log: string) => Promise; + platformConfigMetadata: PlatformConfigMetadata | undefined; + config: ContinueConfig; +}): Promise { try { const modelNames = await llm.listModels(); const detectedModels = await Promise.all( @@ -146,8 +163,8 @@ async function autodetectModels( return undefined; } - return await modelConfigToBaseLLM( - { + return await modelConfigToBaseLLM({ + model: { ...model, model: modelName, name: modelName, @@ -156,8 +173,8 @@ async function autodetectModels( ideSettings, writeLog, platformConfigMetadata, - systemMessage, - ); + config, + }); }), ); return detectedModels.filter((x) => typeof x !== "undefined") as BaseLLM[]; @@ -167,38 +184,46 @@ async function autodetectModels( } } -export async function llmsFromModelConfig( - model: ModelConfig, - ide: IDE, - uniqueId: string, - ideSettings: IdeSettings, - writeLog: (log: string) => Promise, - platformConfigMetadata: PlatformConfigMetadata | undefined, - systemMessage: string | undefined, -): Promise { - const baseLlm = await modelConfigToBaseLLM( +export async function llmsFromModelConfig({ + model, + ide, + uniqueId, + ideSettings, + writeLog, + platformConfigMetadata, + config, +}: { + model: ModelConfig; + ide: IDE; + uniqueId: string; + ideSettings: IdeSettings; + writeLog: (log: string) => Promise; + platformConfigMetadata: PlatformConfigMetadata | undefined; + config: ContinueConfig; +}): Promise { + const baseLlm = await modelConfigToBaseLLM({ model, uniqueId, ideSettings, writeLog, platformConfigMetadata, - systemMessage, - ); + config, + }); if (!baseLlm) { return []; } if (model.model === AUTODETECT) { - const models = await autodetectModels( - baseLlm, + const models = await autodetectModels({ + llm: baseLlm, model, ide, uniqueId, ideSettings, writeLog, platformConfigMetadata, - systemMessage, - ); + config, + }); return models; } else { return [baseLlm]; diff --git a/core/context/allRerankers.ts b/core/context/allRerankers.ts index 944a77dbc..e87cd06e3 100644 --- a/core/context/allRerankers.ts +++ b/core/context/allRerankers.ts @@ -3,6 +3,7 @@ import Cohere from "../llm/llms/Cohere"; import FreeTrial from "../llm/llms/FreeTrial"; import HuggingFaceTEI from "../llm/llms/HuggingFaceTEI"; import { LLMReranker } from "../llm/llms/llm"; +import SiliconFlow from "../llm/llms/SiliconFlow"; import ContinueProxy from "../llm/llms/stubs/ContinueProxy"; import Voyage from "../llm/llms/Voyage"; import WatsonX from "../llm/llms/WatsonX"; @@ -16,4 +17,5 @@ export const AllRerankers: { [key: string]: any } = { "free-trial": FreeTrial, "huggingface-tei": HuggingFaceTEI, "continue-proxy": ContinueProxy, + siliconflow: SiliconFlow, }; diff --git a/core/context/providers/FolderContextProvider.ts b/core/context/providers/FolderContextProvider.ts index 42df6ab34..b4d2e0e09 100644 --- a/core/context/providers/FolderContextProvider.ts +++ b/core/context/providers/FolderContextProvider.ts @@ -35,7 +35,7 @@ class FolderContextProvider extends BaseContextProvider { const folders = await walkDirs( args.ide, { - onlyDirs: true, + include: "dirs", source: "load submenu items - folder", }, workspaceDirs, diff --git a/core/context/providers/RepoMapContextProvider.ts b/core/context/providers/RepoMapContextProvider.ts index 6a2db46fa..575e7af4b 100644 --- a/core/context/providers/RepoMapContextProvider.ts +++ b/core/context/providers/RepoMapContextProvider.ts @@ -54,7 +54,7 @@ class RepoMapContextProvider extends BaseContextProvider { const folders = await walkDirs( args.ide, { - onlyDirs: true, + include: "dirs", source: "load submenu items - repo map", }, workspaceDirs, diff --git a/core/index.d.ts b/core/index.d.ts index ba97377d3..9a6a40c21 100644 --- a/core/index.d.ts +++ b/core/index.d.ts @@ -1,4 +1,4 @@ -import { DataDestination, ModelRole } from "@continuedev/config-yaml"; +import { DataDestination, ModelRole, Rule } from "@continuedev/config-yaml"; import Parser from "web-tree-sitter"; import { GetGhTokenArgs } from "./protocol/ide"; declare global { @@ -497,6 +497,7 @@ export interface LLMOptions { templateMessages?: (messages: ChatMessage[]) => string; writeLog?: (str: string) => Promise; llmRequestHook?: (model: string, prompt: string) => any; + rules?: Rule[]; apiKey?: string; // continueProperties @@ -1312,7 +1313,7 @@ export interface ContinueConfig { docs?: SiteIndexingConfig[]; tools: Tool[]; mcpServerStatuses: MCPServerStatus[]; - rules?: string[]; + rules?: Rule[]; modelsByRole: Record; selectedModelByRole: Record; data?: DataDestination[]; @@ -1335,7 +1336,7 @@ export interface BrowserSerializedContinueConfig { docs?: SiteIndexingConfig[]; tools: Tool[]; mcpServerStatuses: MCPServerStatus[]; - rules?: string[]; + rules?: Rule[]; usePlatform: boolean; tabAutocompleteOptions?: Partial; modelsByRole: Record; diff --git a/core/indexing/walkDir.test.ts b/core/indexing/walkDir.test.ts index 399a24875..50acba4ed 100644 --- a/core/indexing/walkDir.test.ts +++ b/core/indexing/walkDir.test.ts @@ -97,7 +97,7 @@ describe("walkDir functions", () => { ); }); - it("should handle onlyDirs option", async () => { + it("should handle include option", async () => { addToTestDir([ "src/", ["src/file1.ts", "content1"], @@ -109,7 +109,7 @@ describe("walkDir functions", () => { (await testIde.getWorkspaceDirs())[0], testIde, { - onlyDirs: true, + include: "dirs", }, ); diff --git a/core/indexing/walkDir.ts b/core/indexing/walkDir.ts index 2c70006a8..04e45a3ca 100644 --- a/core/indexing/walkDir.ts +++ b/core/indexing/walkDir.ts @@ -10,10 +10,11 @@ import { } from "./ignore"; export interface WalkerOptions { - onlyDirs?: boolean; + include?: "dirs" | "files" | "both"; returnRelativeUrisPaths?: boolean; source?: string; overrideDefaultIgnores?: Ignore; + recursive?: boolean; } type Entry = [string, FileType]; @@ -195,7 +196,7 @@ class DFSWalker { if (this.entryIsDirectory(entry)) { relPath = `${relPath}/`; } else { - if (this.options.onlyDirs) { + if (this.options.include === "dirs") { continue; } } @@ -221,19 +222,22 @@ class DFSWalker { } if (this.entryIsDirectory(entry)) { - stack.push({ - walkableEntry, - ignoreContexts, - }); - if (this.options.onlyDirs) { - // when onlyDirs is enabled the walker will only return directory names + if (this.options.recursive) { + stack.push({ + walkableEntry, + ignoreContexts, + }); + } + if (this.options.include !== "files") { + // if yielding dirs or both, walker includes relative paths + const trailingSlash = this.options.include === "dirs" ? "" : "/"; if (this.options.returnRelativeUrisPaths) { - yield walkableEntry.relativeUriPath; + yield walkableEntry.relativeUriPath + trailingSlash; } else { - yield walkableEntry.uri; + yield walkableEntry.uri + trailingSlash; } } - } else { + } else if (this.options.include !== "dirs") { if (this.options.returnRelativeUrisPaths) { yield walkableEntry.relativeUriPath; } else { @@ -257,8 +261,9 @@ class DFSWalker { } const defaultOptions: WalkerOptions = { - onlyDirs: false, + include: "files", returnRelativeUrisPaths: false, + recursive: true, }; export async function* walkDirAsync( diff --git a/core/llm/constants.ts b/core/llm/constants.ts index 7e8b8e9f5..333c79e70 100644 --- a/core/llm/constants.ts +++ b/core/llm/constants.ts @@ -1,5 +1,5 @@ const DEFAULT_MAX_TOKENS = 4096; -const DEFAULT_CONTEXT_LENGTH = 8096; +const DEFAULT_CONTEXT_LENGTH = 8192; const DEFAULT_TEMPERATURE = 0.5; const DEFAULT_ARGS = { diff --git a/core/llm/countTokens.test.ts b/core/llm/countTokens.test.ts index 6895e9269..92f9d92c5 100644 --- a/core/llm/countTokens.test.ts +++ b/core/llm/countTokens.test.ts @@ -1,3 +1,4 @@ +// @ts-nocheck // Generated by continue import { ChatMessage, MessagePart } from "../index.js"; import { diff --git a/core/llm/countTokens.ts b/core/llm/countTokens.ts index 16ac82100..2fc01f9b8 100644 --- a/core/llm/countTokens.ts +++ b/core/llm/countTokens.ts @@ -1,7 +1,13 @@ import { Tiktoken, encodingForModel as _encodingForModel } from "js-tiktoken"; -import { ChatMessage, MessageContent, MessagePart } from "../index.js"; +import { + ChatMessage, + MessageContent, + MessagePart, + UserChatMessage, +} from "../index.js"; +import { Rule } from "@continuedev/config-yaml"; import { renderChatMessage } from "../util/messageContent.js"; import { AsyncEncoder, @@ -11,6 +17,8 @@ import { import { autodetectTemplateType } from "./autodetect.js"; import { TOKEN_BUFFER_FOR_SAFETY } from "./constants.js"; import llamaTokenizer from "./llamaTokenizer.js"; +import { isRuleActive } from "./rules/isRuleActive.js"; +import { extractPathsFromCodeBlocks } from "./utils/extractPathsFromCodeBlocks.js"; interface Encoding { encode: Tiktoken["encode"]; decode: Tiktoken["decode"]; @@ -251,16 +259,35 @@ function pruneChatHistory( }, 0); // 0. Prune any messages that take up more than 1/3 of the context length - const longestMessages = [...chatHistory]; - longestMessages.sort((a, b) => b.content.length - a.content.length); + const zippedMessagesAndTokens: [ChatMessage, number][] = []; - const longerThanOneThird = longestMessages.filter( - (message: ChatMessage) => - countTokens(message.content, modelName) > contextLength / 3, + // Zipped ChatMessage with its token counts + chatHistory.forEach((message) => { + const zippedItem: [ChatMessage, number] = [ + message, + countTokens(message.content, modelName), + ]; + zippedMessagesAndTokens.push(zippedItem); + }); + + const zippedLongerThanOneThird = zippedMessagesAndTokens.filter( + ([_message, tokens]: [ChatMessage, number]) => tokens > contextLength / 3, ); - const distanceFromThird = longerThanOneThird.map( - (message: ChatMessage) => - countTokens(message.content, modelName) - contextLength / 3, + + zippedLongerThanOneThird.sort( + ( + [_messageA, tokensA]: [ChatMessage, number], + [_messageB, tokensB]: [ChatMessage, number], + ) => { + return tokensB - tokensA; + }, + ); + + const longerThanOneThird = zippedLongerThanOneThird.map( + ([message, _token]: [ChatMessage, number]) => message, + ); + const distanceFromThird = zippedLongerThanOneThird.map( + ([_message, token]: [ChatMessage, number]) => token - contextLength / 3, ); for (let i = 0; i < longerThanOneThird.length; i++) { @@ -280,7 +307,7 @@ function pruneChatHistory( // 1. Replace beyond last 5 messages with summary let i = 0; while (totalTokens > contextLength && i < chatHistory.length - 5) { - const message = chatHistory[0]; + const message = chatHistory[i]; totalTokens -= countTokens(message.content, modelName); totalTokens += countTokens(summarize(message), modelName); message.content = summarize(message); @@ -288,11 +315,7 @@ function pruneChatHistory( } // 2. Remove entire messages until the last 5 - while ( - chatHistory.length > 5 && - totalTokens > contextLength && - chatHistory.length > 0 - ) { + while (chatHistory.length > 5 && totalTokens > contextLength) { const message = chatHistory.shift()!; totalTokens -= countTokens(message.content, modelName); } @@ -384,16 +407,127 @@ function chatMessageIsEmpty(message: ChatMessage): boolean { } } -function compileChatMessages( - modelName: string, - msgs: ChatMessage[] | undefined, - contextLength: number, - maxTokens: number, - supportsImages: boolean, - prompt: string | undefined = undefined, - functions: any[] | undefined = undefined, - systemMessage: string | undefined = undefined, -): ChatMessage[] { +function addSystemMessage({ + messages, + systemMessage, + originalMessages, +}: { + messages: ChatMessage[]; + systemMessage: string | undefined; + originalMessages: ChatMessage[] | undefined; +}): ChatMessage[] { + if ( + !(systemMessage && systemMessage.trim() !== "") && + originalMessages?.[0]?.role !== "system" + ) { + return messages; + } + + let content = ""; + if (originalMessages?.[0]?.role === "system") { + content = renderChatMessage(originalMessages[0]); + } + if (systemMessage && systemMessage.trim() !== "") { + const shouldAddNewLines = content !== ""; + if (shouldAddNewLines) { + content += "\n\n"; + } + content += systemMessage; + } + + const systemChatMsg: ChatMessage = { + role: "system", + content, + }; + // Insert as second to last + messages.splice(-1, 0, systemChatMsg); + return messages; +} + +function getMessageStringContent(message?: UserChatMessage): string { + if (!message) { + return ""; + } + + if (typeof message.content === "string") { + return message.content; + } + + // Handle MessagePart array + return message.content + .map((part) => { + if (part.type === "text") { + return part.text; + } + + return ""; + }) + .join("\n"); +} + +const getSystemMessage = ({ + userMessage, + rules, + currentModel, +}: { + userMessage?: UserChatMessage; + rules: Rule[]; + currentModel: string; +}) => { + const messageStringContent = getMessageStringContent(userMessage); + const filePathsFromMessage = extractPathsFromCodeBlocks(messageStringContent); + + return rules + .filter((rule) => { + return isRuleActive({ + rule, + activePaths: filePathsFromMessage, + currentModel, + }); + }) + .map((rule) => { + if (typeof rule === "string") { + return rule; + } + return rule.rule; + }) + .join("\n"); +}; + +function getLastUserMessage( + messages: ChatMessage[], +): UserChatMessage | undefined { + // Iterate backwards through messages to find the last user message + for (let i = messages.length - 1; i >= 0; i--) { + if (messages[i].role === "user") { + return messages[i] as UserChatMessage; + } + } + + return undefined; +} + +function compileChatMessages({ + modelName, + msgs, + contextLength, + maxTokens, + supportsImages, + prompt, + functions, + systemMessage, + rules, +}: { + modelName: string; + msgs: ChatMessage[] | undefined; + contextLength: number; + maxTokens: number; + supportsImages: boolean; + prompt: string | undefined; + functions: any[] | undefined; + systemMessage: string | undefined; + rules: Rule[]; +}): ChatMessage[] { let msgsCopy = msgs ? msgs .map((msg) => ({ ...msg })) @@ -410,29 +544,19 @@ function compileChatMessages( msgsCopy.push(promptMsg); } - if ( - (systemMessage && systemMessage.trim() !== "") || - msgs?.[0]?.role === "system" - ) { - let content = ""; - if (msgs?.[0]?.role === "system") { - content = renderChatMessage(msgs?.[0]); - } - if (systemMessage && systemMessage.trim() !== "") { - const shouldAddNewLines = content !== ""; - if (shouldAddNewLines) { - content += "\n\n"; - } - content += systemMessage; - } - const systemChatMsg: ChatMessage = { - role: "system", - content, - }; - // Insert as second to last - // Later moved to top, but want second-priority to last user message - msgsCopy.splice(-1, 0, systemChatMsg); - } + const lastUserMessage = getLastUserMessage(msgsCopy); + + msgsCopy = addSystemMessage({ + messages: msgsCopy, + systemMessage: + systemMessage ?? + getSystemMessage({ + userMessage: lastUserMessage, + rules, + currentModel: modelName, + }), + originalMessages: msgs, + }); let functionTokens = 0; if (functions) { diff --git a/core/llm/index.ts b/core/llm/index.ts index 028bc42c3..cc7d7123c 100644 --- a/core/llm/index.ts +++ b/core/llm/index.ts @@ -1,4 +1,4 @@ -import { ModelRole } from "@continuedev/config-yaml"; +import { ModelRole, Rule } from "@continuedev/config-yaml"; import { fetchwithRequestOptions } from "@continuedev/fetch"; import { findLlmInfo } from "@continuedev/llm-info"; import { @@ -143,6 +143,7 @@ export abstract class BaseLLM implements ILLM { cacheBehavior?: CacheBehavior; capabilities?: ModelCapability; roles?: ModelRole[]; + rules?: Rule[]; deployment?: string; apiVersion?: string; @@ -242,6 +243,7 @@ export abstract class BaseLLM implements ILLM { this.accountId = options.accountId; this.capabilities = options.capabilities; this.roles = options.roles; + this.rules = options.rules; this.deployment = options.deployment; this.apiVersion = options.apiVersion; @@ -286,21 +288,17 @@ export abstract class BaseLLM implements ILLM { CONTEXT_LENGTH_FOR_MODEL[options.model] || DEFAULT_CONTEXT_LENGTH; } - return compileChatMessages( - options.model, - messages, + return compileChatMessages({ + modelName: options.model, + msgs: messages, contextLength, - options.maxTokens ?? DEFAULT_MAX_TOKENS, - this.supportsImages(), - undefined, + maxTokens: options.maxTokens ?? DEFAULT_MAX_TOKENS, + supportsImages: this.supportsImages(), + prompt: undefined, functions, - this.systemMessage, - ); - } - - private _getSystemMessage(): string | undefined { - // TODO: Merge with config system message - return this.systemMessage; + systemMessage: this.systemMessage, + rules: this.rules ?? [], + }); } private _templatePromptLikeMessages(prompt: string): string { @@ -310,7 +308,7 @@ export abstract class BaseLLM implements ILLM { const msgs: ChatMessage[] = [{ role: "user", content: prompt }]; - const systemMessage = this._getSystemMessage(); + const systemMessage = this.systemMessage; if (systemMessage) { msgs.unshift({ role: "system", content: systemMessage }); } diff --git a/core/llm/llms/Bedrock.ts b/core/llm/llms/Bedrock.ts index c6abbeb97..7fefbd329 100644 --- a/core/llm/llms/Bedrock.ts +++ b/core/llm/llms/Bedrock.ts @@ -2,8 +2,9 @@ import { BedrockRuntimeClient, ContentBlock, ConverseStreamCommand, + ConverseStreamCommandOutput, InvokeModelCommand, - Message + Message, } from "@aws-sdk/client-bedrock-runtime"; import { fromNodeProviderChain } from "@aws-sdk/credential-providers"; @@ -11,7 +12,7 @@ import { ChatMessage, Chunk, CompletionOptions, - LLMOptions + LLMOptions, } from "../../index.js"; import { renderChatMessage } from "../../util/messageContent.js"; import { BaseLLM } from "../index.js"; @@ -31,6 +32,14 @@ interface ToolUseState { input: string; } +/** + * Interface for prompt caching metrics + */ +interface PromptCachingMetrics { + cacheReadInputTokens: number; + cacheWriteInputTokens: number; +} + class Bedrock extends BaseLLM { static providerName = "bedrock"; static defaultOptions: Partial = { @@ -41,8 +50,16 @@ class Bedrock extends BaseLLM { }; private _currentToolResponse: Partial | null = null; + private _promptCachingMetrics: PromptCachingMetrics = { + cacheReadInputTokens: 0, + cacheWriteInputTokens: 0, + }; - public requestOptions: { region?: string; credentials?: any; headers?: Record }; + public requestOptions: { + region?: string; + credentials?: any; + headers?: Record; + }; constructor(options: LLMOptions) { super(options); @@ -108,12 +125,17 @@ class Bedrock extends BaseLLM { }, ); - const input = this._generateConverseInput(messages, { ...options, stream: true }); + const input = this._generateConverseInput(messages, { + ...options, + stream: true, + }); const command = new ConverseStreamCommand(input); - let response; + let response: ConverseStreamCommandOutput; try { - response = await client.send(command, { abortSignal: signal }); + response = (await client.send(command, { + abortSignal: signal, + })) as ConverseStreamCommandOutput; } catch (error: unknown) { console.error(error); const message = error instanceof Error ? error.message : "Unknown error"; @@ -124,51 +146,82 @@ class Bedrock extends BaseLLM { throw new Error("No stream received from Bedrock API"); } + // Reset cache metrics for new request + this._promptCachingMetrics = { + cacheReadInputTokens: 0, + cacheWriteInputTokens: 0, + }; + try { for await (const chunk of response.stream) { + if (chunk.metadata?.usage) { + console.log(`${JSON.stringify(chunk.metadata.usage)}`); + } if (chunk.contentBlockDelta?.delta) { - - const delta: any = chunk.contentBlockDelta.delta + const delta: any = chunk.contentBlockDelta.delta; // Handle text content if (chunk.contentBlockDelta.delta.text) { - yield { role: "assistant", content: chunk.contentBlockDelta.delta.text }; + yield { + role: "assistant", + content: chunk.contentBlockDelta.delta.text, + }; continue; } // Handle text content if ((chunk.contentBlockDelta.delta as any).reasoningContent?.text) { - yield { role: "thinking", content: (chunk.contentBlockDelta.delta as any).reasoningContent.text }; + yield { + role: "thinking", + content: (chunk.contentBlockDelta.delta as any).reasoningContent + .text, + }; continue; } // Handle signature for thinking if (delta.reasoningContent?.signature) { - yield { role: "thinking", content: "", signature: delta.reasoningContent.signature }; + yield { + role: "thinking", + content: "", + signature: delta.reasoningContent.signature, + }; continue; } // Handle redacted thinking if (delta.redactedReasoning?.data) { - yield { role: "thinking", content: "", redactedThinking: delta.redactedReasoning.data }; + yield { + role: "thinking", + content: "", + redactedThinking: delta.redactedReasoning.data, + }; continue; } - if (chunk.contentBlockDelta.delta.toolUse?.input && this._currentToolResponse) { + if ( + chunk.contentBlockDelta.delta.toolUse?.input && + this._currentToolResponse + ) { // Append the new input to the existing string if (this._currentToolResponse.input === undefined) { this._currentToolResponse.input = ""; } - this._currentToolResponse.input += chunk.contentBlockDelta.delta.toolUse.input; + this._currentToolResponse.input += + chunk.contentBlockDelta.delta.toolUse.input; continue; } } if (chunk.contentBlockStart?.start) { - const start: any = chunk.contentBlockStart.start + const start: any = chunk.contentBlockStart.start; if (start.redactedReasoning) { - yield { role: "thinking", content: "", redactedThinking: start.redactedReasoning.data }; + yield { + role: "thinking", + content: "", + redactedThinking: start.redactedReasoning.data, + }; continue; } @@ -177,7 +230,7 @@ class Bedrock extends BaseLLM { this._currentToolResponse = { toolUseId: toolUse.toolUseId, name: toolUse.name, - input: "" + input: "", }; } continue; @@ -188,14 +241,16 @@ class Bedrock extends BaseLLM { yield { role: "assistant", content: "", - toolCalls: [{ - id: this._currentToolResponse.toolUseId, - type: "function", - function: { - name: this._currentToolResponse.name, - arguments: this._currentToolResponse.input - } - }], + toolCalls: [ + { + id: this._currentToolResponse.toolUseId, + type: "function", + function: { + name: this._currentToolResponse.name, + arguments: this._currentToolResponse.input, + }, + }, + ], }; this._currentToolResponse = null; } @@ -207,13 +262,16 @@ class Bedrock extends BaseLLM { if (error instanceof Error) { if ("code" in error) { // AWS SDK specific errors - throw new Error(`AWS Bedrock stream error (${(error as any).code}): ${error.message}`); + throw new Error( + `AWS Bedrock stream error (${(error as any).code}): ${error.message}`, + ); } throw new Error(`Error processing Bedrock stream: ${error.message}`); } - throw new Error("Error processing Bedrock stream: Unknown error occurred"); + throw new Error( + "Error processing Bedrock stream: Unknown error occurred", + ); } - } /** @@ -228,22 +286,43 @@ class Bedrock extends BaseLLM { ): any { const convertedMessages = this._convertMessages(messages); - const supportsTools = PROVIDER_TOOL_SUPPORT.bedrock?.(options.model || "") ?? false; + const shouldCacheSystemMessage = + !!this.systemMessage && this.cacheBehavior?.cacheSystemMessage; + const enablePromptCaching = + shouldCacheSystemMessage || this.cacheBehavior?.cacheConversation; + + // Add header for prompt caching + if (enablePromptCaching) { + this.requestOptions.headers = { + ...this.requestOptions.headers, + "x-amzn-bedrock-enablepromptcaching": "true", + }; + } + + const supportsTools = + PROVIDER_TOOL_SUPPORT.bedrock?.(options.model || "") ?? false; return { modelId: options.model, messages: convertedMessages, - system: this.systemMessage ? [{ text: this.systemMessage }] : undefined, - toolConfig: supportsTools && options.tools ? { - tools: options.tools.map(tool => ({ - toolSpec: { - name: tool.function.name, - description: tool.function.description, - inputSchema: { - json: tool.function.parameters + system: this.systemMessage + ? shouldCacheSystemMessage + ? [{ text: this.systemMessage }, { cachePoint: { type: "default" } }] + : [{ text: this.systemMessage }] + : undefined, + toolConfig: + supportsTools && options.tools + ? { + tools: options.tools.map((tool) => ({ + toolSpec: { + name: tool.function.name, + description: tool.function.description, + inputSchema: { + json: tool.function.parameters, + }, + }, + })), } - } - })) - } : undefined, + : undefined, inferenceConfig: { maxTokens: options.maxTokens, temperature: options.temperature, @@ -261,20 +340,29 @@ class Bedrock extends BaseLLM { .slice(0, 4), }, additionalModelRequestFields: { - "thinking": options.reasoning ? { - "type": "enabled", - "budget_tokens": options.reasoningBudgetTokens - } : undefined, - } + thinking: options.reasoning + ? { + type: "enabled", + budget_tokens: options.reasoningBudgetTokens, + } + : undefined, + }, }; } - private _convertMessage(message: ChatMessage): Message | null { + private _convertMessage( + message: ChatMessage, + addCaching: boolean = false, + ): Message | null { // Handle system messages explicitly if (message.role === "system") { return null; } + const cachePoint = addCaching + ? { cachePoint: { type: "default" } } + : undefined; + // Tool response handling if (message.role === "tool") { return { @@ -285,12 +373,12 @@ class Bedrock extends BaseLLM { toolUseId: message.toolCallId, content: [ { - text: message.content || "" - } - ] - } - } - ] + text: message.content || "", + }, + ], + }, + }, + ], }; } @@ -303,8 +391,8 @@ class Bedrock extends BaseLLM { toolUseId: toolCall.id, name: toolCall.function?.name, input: JSON.parse(toolCall.function?.arguments || "{}"), - } - })) + }, + })), }; } @@ -312,84 +400,111 @@ class Bedrock extends BaseLLM { if (message.redactedThinking) { const content: ContentBlock.ReasoningContentMember = { reasoningContent: { - redactedContent: new Uint8Array(Buffer.from(message.redactedThinking)) - } + redactedContent: new Uint8Array( + Buffer.from(message.redactedThinking), + ), + }, }; return { role: "assistant", - content: [content] + content: [content], }; } else { const content: ContentBlock.ReasoningContentMember = { reasoningContent: { reasoningText: { text: (message.content as string) || "", - signature: message.signature - } - - } + signature: message.signature, + }, + }, }; return { role: "assistant", - content: [content] + content: [content], }; } } // Standard text message if (typeof message.content === "string") { + const content: any[] = [{ text: message.content }]; + if (addCaching) { + content.push({ cachePoint: { type: "default" } }); + } return { role: message.role, - content: [{ text: message.content }] + content, }; } // Improved multimodal content handling if (Array.isArray(message.content)) { + const content: any[] = []; + + // Process all parts first + message.content.forEach((part) => { + if (part.type === "text") { + content.push({ text: part.text }); + } else if (part.type === "imageUrl" && part.imageUrl) { + try { + const [mimeType, base64Data] = part.imageUrl.url.split(","); + const format = mimeType.split("/")[1]?.split(";")[0] || "jpeg"; + content.push({ + image: { + format, + source: { + bytes: Buffer.from(base64Data, "base64"), + }, + }, + }); + } catch (error) { + console.warn(`Failed to process image: ${error}`); + } + } + }); + + // Add cache point as a separate block at the end if needed + if (addCaching && content.length > 0) { + content.push({ cachePoint: { type: "default" } }); + } + return { role: message.role, - content: message.content.map(part => { - if (part.type === "text") { - return { text: part.text }; - } - if (part.type === "imageUrl" && part.imageUrl) { - try { - const [mimeType, base64Data] = part.imageUrl.url.split(","); - const format = mimeType.split("/")[1]?.split(";")[0] || "jpeg"; - return { - image: { - format, - source: { - bytes: Buffer.from(base64Data, "base64") - } - } - }; - } catch (error) { - console.warn(`Failed to process image: ${error}`); - return null; - } - } - return null; - }).filter(Boolean) + content, } as Message; } return null; } private _convertMessages(messages: ChatMessage[]): any[] { + const filteredmessages = messages.filter( + (m) => m.role !== "system" && !!m.content, + ); + const lastTwoUserMsgIndices = filteredmessages + .map((msg, index) => (msg.role === "user" ? index : -1)) + .filter((index) => index !== -1) + .slice(-2); + + const converted = filteredmessages + .map((message, filteredMsgIdx) => { + // Add cache_control parameter to the last two user messages + // The second-to-last because it retrieves potentially already cached contents, + // The last one because we want it cached for later retrieval. + // See: https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-caching.html + const addCaching = + this.cacheBehavior?.cacheConversation && + lastTwoUserMsgIndices.includes(filteredMsgIdx); - const converted = messages - .map((message) => { try { - return this._convertMessage(message); + return this._convertMessage(message, addCaching); } catch (error) { console.error(`Failed to convert message: ${error}`); return null; } }) .filter(Boolean); - return converted; + return converted; } private async _getCredentials() { @@ -453,7 +568,6 @@ class Bedrock extends BaseLLM { return modelConfig.extractEmbeddings(responseBody); } - private _getModelConfig() { const modelConfigs: { [key: string]: ModelConfig } = { cohere: { @@ -491,7 +605,11 @@ class Bedrock extends BaseLLM { const credentials = await this._getCredentials(); const client = new BedrockRuntimeClient({ region: this.region, - credentials, + credentials: { + accessKeyId: credentials.accessKeyId, + secretAccessKey: credentials.secretAccessKey, + sessionToken: credentials.sessionToken || "", + }, }); // Base payload for both models @@ -530,11 +648,15 @@ class Bedrock extends BaseLLM { if (error instanceof Error) { if ("code" in error) { // AWS SDK specific errors - throw new Error(`AWS Bedrock rerank error (${(error as any).code}): ${error.message}`); + throw new Error( + `AWS Bedrock rerank error (${(error as any).code}): ${error.message}`, + ); } throw new Error(`Error in BedrockReranker.rerank: ${error.message}`); } - throw new Error("Error in BedrockReranker.rerank: Unknown error occurred"); + throw new Error( + "Error in BedrockReranker.rerank: Unknown error occurred", + ); } } } diff --git a/core/llm/llms/Docker.ts b/core/llm/llms/Docker.ts new file mode 100644 index 000000000..229cfac17 --- /dev/null +++ b/core/llm/llms/Docker.ts @@ -0,0 +1,133 @@ +import { spawn } from "child_process"; +import { LLMOptions, ModelInstaller } from "../../index.js"; +import OpenAI from "./OpenAI.js"; + +/** + * Docker Model Runner provider + * + * Integrates with Docker Desktop's Model Runner feature (currently in beta) + * that allows running local AI models through Docker. + * + * Docker Model Runner provides an OpenAI-compatible API endpoint, making it + * easy to integrate with existing OpenAI-compatible code. + * + * More information at: https://docs.docker.com/desktop/features/model-runner/ + */ +class Docker extends OpenAI implements ModelInstaller { + static providerName = "docker"; + static defaultOptions: Partial = { + apiBase: "http://model-runner.docker.internal/v1/", + model: "gemma3-4B-F4", // Default model + }; + + private modelMap: Record = { + // Map of "continue model name" to Docker model name + // Models can be pulled using: docker model pull + "llama3.3-70b": "ai/llama3.3:70B-Q4_K_M", + "smollm2-360M-F4": "ai/smollm2:360M-Q4_K_M", + "smollm2-360M-F16": "ai/ai/smollm2:360M-F16", + "qwen2.5-7B-F16": "ai/qwen2.5:7B-F16", + "qwen2.5-7B-F4": "ai/qwen2.5:7B-Q4_K_M", + "phi4-14B-F16": "ai/phi4:14B-F16", + "phi4-14B-F4": "ai/phi4:14B-Q4_K_M", + "mistral-7B-F16": "ai/mistral:7B-F16", + "mistral-7B-F4": "ai/mistral:7B-Q4_K_M", + "mistral-nemo-12B": "ai/mistral-nemo:12B-Q4_K_M", + "gemma3-4B-F16": "ai/gemma3:4B-F16", + "gemma3-4B-F4": "ai/gemma3:4B-Q4_K_M", + "llama3.2-3B-F16": "ai/llama3.2:3B-F16", + "llama3.2-3B-F4": "ai/llama3.2:3B-Q4_K_M", + "llama3.2-1B-F16": "ai/llama3.2:1B-F16", + "llama3.2-1B-F8": "ai/llama3.2:1B-Q8_0", + "qwq-32B-F16": "ai/qwq:32B-F16", + "qwq-32B-F4": "ai/qwq:32B-Q4_K_M", + "deepseek-r1-distill-llama-70B-F4": "ai/deepseek-r1-distill-llama:70B-Q4_K_M", + "deepseek-r1-distill-llama-8B-F16": "ai/deepseek-r1-distill-llama:8B-F16", + "deepseek-r1-distill-llama-8B-Q4": "ai/deepseek-r1-distill-llama:8B-Q4_K_M" + }; + + constructor(options: LLMOptions) { + super(options); + + // Handle model name mapping + if (this.model && this.modelMap[this.model]) { + this.model = this.modelMap[this.model]; + } + } + + private async executeDockerCommand( + args: string[], + signal?: AbortSignal + ): Promise<{ stdout: string; stderr: string }> { + return new Promise((resolve, reject) => { + const proc = spawn('docker', args, { shell: true }); + + let stdout = ''; + let stderr = ''; + + proc.stdout.on('data', (data) => { + stdout += data.toString(); + }); + + proc.stderr.on('data', (data) => { + stderr += data.toString(); + }); + + proc.on('close', (code) => { + if (code === 0) { + resolve({ stdout, stderr }); + } else { + reject(new Error(`Docker command failed with code ${code}: ${stderr}`)); + } + }); + + if (signal) { + signal.addEventListener('abort', () => { + proc.kill(); + reject(new Error('Docker command was aborted')); + }); + } + }); + } + + async listModels(): Promise { + try { + // Execute docker model ls and parse the output + const { stdout } = await this.executeDockerCommand(['model', 'ls', '--format', '{{.Repository}}/{{.Tag}}']); + return stdout.split('\n') + .map(line => line.trim()) + .filter(Boolean); + } catch (error) { + console.error("Failed to list Docker models:", error); + return Object.values(this.modelMap); + } + } + + async installModel( + modelName: string, + signal: AbortSignal, + progressReporter?: (task: string, increment: number, total: number) => void + ): Promise { + const targetModel = this.modelMap[modelName] || modelName; + + try { + // Report starting the installation + progressReporter?.(`Installing Docker model ${targetModel}`, 0, 100); + + // Pull the model + const { stdout, stderr } = await this.executeDockerCommand(['model', 'pull', targetModel], signal); + + // Report completion + progressReporter?.(`Docker model ${targetModel} installed successfully`, 100, 100); + + return { success: true, stdout, stderr }; + } catch (error) { + console.error(`Failed to install Docker model ${targetModel}:`, error); + // Fix: Type check the error before accessing message property + const errorMessage = error instanceof Error ? error.message : String(error); + throw new Error(`Failed to install Docker model ${targetModel}: ${errorMessage}`); + } + } +} + +export default Docker; diff --git a/core/llm/llms/Inception.ts b/core/llm/llms/Inception.ts new file mode 100644 index 000000000..ef204fec1 --- /dev/null +++ b/core/llm/llms/Inception.ts @@ -0,0 +1,70 @@ +import { CompletionOptions, LLMOptions } from "../../index.js"; +import { streamSse } from "../stream.js"; + +import OpenAI from "./OpenAI.js"; + +/** + * Inception Labs provider + * + * Integrates with Inception Labs' OpenAI-compatible API endpoints. + * Provides access to Mercury models for autocomplete and other tasks. + * + * Different models use different API endpoints: + * - mercury-editor-mini-experimental: zaragoza.api.inceptionlabs.ai + * - mercury-editor-small-experimental: copenhagen.api.inceptionlabs.ai + * + * More information at: https://docs.inceptionlabs.ai/ + */ +class Inception extends OpenAI { + static providerName = "inception"; + static defaultOptions: Partial = { + apiBase: "https://copenhagen.api.inceptionlabs.ai/v1/", + model: "mercury-editor-small-experimental", + completionOptions: { + temperature: 0.0, + maxTokens: 150, + presencePenalty: 1.5, + stop: ["\n\n", "\n \n", "<|endoftext|>"], + model: "mercury-editor-small-experimental", // Added model to fix TypeScript error + }, + }; + + supportsFim(): boolean { + return true; + } + + async *_streamFim( + prefix: string, + suffix: string, + signal: AbortSignal, + options: CompletionOptions, + ): AsyncGenerator { + const endpoint = new URL("completions", this.apiBase); + const resp = await this.fetch(endpoint, { + method: "POST", + body: JSON.stringify({ + model: options.model, + prompt: prefix, + suffix, + max_tokens: options.maxTokens, + temperature: options.temperature, + top_p: options.topP, + frequency_penalty: options.frequencyPenalty, + presence_penalty: options.presencePenalty, + stop: options.stop, + stream: true, + }), + headers: { + "Content-Type": "application/json", + Accept: "application/json", + Authorization: `Bearer ${this.apiKey}`, + }, + signal, + }); + for await (const chunk of streamSse(resp)) { + yield chunk.choices[0].text; + } + } +} + +export default Inception; diff --git a/core/llm/llms/SiliconFlow.ts b/core/llm/llms/SiliconFlow.ts index 6f522f920..cddb22b0d 100644 --- a/core/llm/llms/SiliconFlow.ts +++ b/core/llm/llms/SiliconFlow.ts @@ -1,4 +1,4 @@ -import { CompletionOptions, LLMOptions } from "../../index.js"; +import { Chunk, CompletionOptions, LLMOptions } from "../../index.js"; import { streamSse } from "../stream.js"; import { osModelsEditPrompt } from "../templates/edit.js"; @@ -52,6 +52,41 @@ class SiliconFlow extends OpenAI { yield chunk.choices[0].text; } } + + async rerank(query: string, chunks: Chunk[]): Promise { + if (!query || query.trim() === "") { + console.warn("[SiliconFlow] rerank: query is empty"); + return []; + } + + if (!chunks || chunks.length === 0) { + console.warn("[SiliconFlow] rerank: chunks is empty"); + return []; + } + + const endpoint = new URL("rerank", this.apiBase); + const resp = await this.fetch(endpoint, { + method: "POST", + headers: { + "Content-Type": "application/json", + Accept: "application/json", + Authorization: `Bearer ${this.apiKey}`, + }, + body: JSON.stringify({ + model: this.model, + query, + documents: chunks.map((chunk) => chunk.content), + }), + }); + + if (!resp.ok) { + throw new Error(await resp.text()); + } + + const data = (await resp.json()) as any; + const results = data.results.sort((a: any, b: any) => a.index - b.index); + return results.map((result: any) => result.relevance_score); + } } export default SiliconFlow; diff --git a/core/llm/llms/index.ts b/core/llm/llms/index.ts index e6a33a9a8..8e3f68b2e 100644 --- a/core/llm/llms/index.ts +++ b/core/llm/llms/index.ts @@ -18,6 +18,7 @@ import Cloudflare from "./Cloudflare"; import Cohere from "./Cohere"; import DeepInfra from "./DeepInfra"; import Deepseek from "./Deepseek"; +import Docker from "./Docker"; import Fireworks from "./Fireworks"; import Flowise from "./Flowise"; import FreeTrial from "./FreeTrial"; @@ -26,6 +27,7 @@ import Gemini from "./Gemini"; import Groq from "./Groq"; import HuggingFaceInferenceAPI from "./HuggingFaceInferenceAPI"; import HuggingFaceTGI from "./HuggingFaceTGI"; +import Inception from "./Inception"; import Kindo from "./Kindo"; import LlamaCpp from "./LlamaCpp"; import Llamafile from "./Llamafile"; @@ -87,6 +89,7 @@ export const LLMClasses = [ ContinueProxy, Cloudflare, Deepseek, + Docker, Msty, Azure, WatsonX, @@ -104,6 +107,7 @@ export const LLMClasses = [ SiliconFlow, Scaleway, Relace, + Inception, ]; export async function llmFromDescription( diff --git a/core/llm/rules/isRuleActive.test.ts b/core/llm/rules/isRuleActive.test.ts new file mode 100644 index 000000000..f50b9972a --- /dev/null +++ b/core/llm/rules/isRuleActive.test.ts @@ -0,0 +1,59 @@ +import { isRuleActive } from "./isRuleActive"; + +describe("isRuleActive", () => { + const rule = { + name: "My Rule", + rule: "Do no harm", + if: '${{ contains(current.model.model, "claude-3-7-sonnet") and glob("*.tsx") }}', + }; + + it("should return false when activePaths is empty", () => { + expect( + isRuleActive({ + rule, + activePaths: [], + currentModel: "claude-3-7-sonnet", + }), + ).toBe(false); + }); + + it("should return false when no matching paths exist", () => { + expect( + isRuleActive({ + rule, + activePaths: ["test.py", "main.js"], + currentModel: "claude-3-7-sonnet", + }), + ).toBe(false); + }); + + it("should return true when both conditions are met", () => { + expect( + isRuleActive({ + rule, + activePaths: ["Component.tsx", "main.js"], + currentModel: "claude-3-7-sonnet", + }), + ).toBe(true); + }); + + it("should return false when only glob matches but model doesn't", () => { + expect( + isRuleActive({ + rule, + activePaths: ["Component.tsx"], + currentModel: "gpt-4", + }), + ).toBe(false); + }); + + it("should return false when model matches but glob doesn't", () => { + expect( + isRuleActive({ + rule, + activePaths: ["Component.ts"], + currentModel: "claude-3-7-sonnet", + }), + ).toBe(false); + }); +}); diff --git a/core/llm/rules/isRuleActive.ts b/core/llm/rules/isRuleActive.ts new file mode 100644 index 000000000..47125c644 --- /dev/null +++ b/core/llm/rules/isRuleActive.ts @@ -0,0 +1,68 @@ +import { Rule } from "@continuedev/config-yaml"; +import { compileExpression } from "filtrex"; +import { minimatch } from "minimatch"; + +const TEMPLATE_VAR_REGEX = /^\$\{\{(\s*.*?\s*)\}\}$/; + +const createGlobFunction = (activePaths: string[]) => { + return (pattern: string) => { + const result = activePaths.some((path) => minimatch(path, pattern)); + return result; + }; +}; + +const contains = (str: string, searchStr: string): boolean => { + return str.includes(searchStr); +}; + +const evaluateIf = ({ + condition, + activePaths, + currentModel, +}: { + condition: string; + activePaths: string[]; + currentModel: string; +}) => { + const expression = condition.match(TEMPLATE_VAR_REGEX)?.[1]?.trim(); + if (!expression) { + return true; + } + + try { + const evaluate = compileExpression(expression, { + extraFunctions: { + glob: createGlobFunction(activePaths), + contains, + }, + constants: { + "current.model.model": currentModel, + }, + }); + + return evaluate({}); + } catch (error) { + console.error("Error evaluating rule condition:", error); + return false; + } +}; + +export const isRuleActive = ({ + rule, + activePaths, + currentModel, +}: { + rule: Rule; + activePaths: string[]; + currentModel: string; +}): boolean => { + if (typeof rule === "string") { + return true; + } + + if (rule.if) { + return evaluateIf({ condition: rule.if, activePaths, currentModel }); + } + + return true; +}; diff --git a/core/llm/utils/extractPathsFromCodeBlocks.ts b/core/llm/utils/extractPathsFromCodeBlocks.ts new file mode 100644 index 000000000..7573a1f6f --- /dev/null +++ b/core/llm/utils/extractPathsFromCodeBlocks.ts @@ -0,0 +1,22 @@ +/** + * Extracts file paths from markdown code blocks + */ +export function extractPathsFromCodeBlocks(content: string): string[] { + // Match: + // 1. Starting ``` + // 2. Optional language identifier + // 3. Required whitespace + // 4. File path (captured) that must contain a dot and extension + const codeBlockRegex = /```(?:[\w-+#]+)?\s+([^\s\n()]+\.[a-zA-Z0-9]+)/g; + const paths: string[] = []; + let match; + + while ((match = codeBlockRegex.exec(content)) !== null) { + const path = match[1]; + if (path && !path.startsWith("```")) { + paths.push(path); + } + } + + return paths; +} diff --git a/core/package-lock.json b/core/package-lock.json index 043f6b2bd..7ee0b3de0 100644 --- a/core/package-lock.json +++ b/core/package-lock.json @@ -9,9 +9,9 @@ "version": "1.1.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/client-bedrock-runtime": "^3.758.0", - "@aws-sdk/client-sagemaker-runtime": "^3.758.0", - "@aws-sdk/credential-providers": "^3.758.0", + "@aws-sdk/client-bedrock-runtime": "^3.779.0", + "@aws-sdk/client-sagemaker-runtime": "^3.777.0", + "@aws-sdk/credential-providers": "^3.778.0", "@continuedev/config-types": "^1.0.13", "@continuedev/config-yaml": "^1.0.75", "@continuedev/fetch": "^1.0.4", @@ -32,6 +32,7 @@ "diff": "^7.0.0", "dotenv": "^16.4.5", "fastest-levenshtein": "^1.0.16", + "filtrex": "^3.1.0", "follow-redirects": "^1.15.5", "google-auth-library": "^9.14.2", "handlebars": "^4.7.8", @@ -289,51 +290,51 @@ } }, "node_modules/@aws-sdk/client-bedrock-runtime": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-bedrock-runtime/-/client-bedrock-runtime-3.758.0.tgz", - "integrity": "sha512-T7s+fULUxN3AcJP+lgoUKLawzVEtyCTi+5Ga+wrHnqEPwAsM/wg7VctsZfow1fCgARLT/lzmP2LTCi8ycRnQWg==", + "version": "3.779.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-bedrock-runtime/-/client-bedrock-runtime-3.779.0.tgz", + "integrity": "sha512-MyzZks8XxWwdsA4VlyPW4IekUjpgDI91VwMvEtOITHD8w+9nTGJtD32HcCKNQQCHWYfSoOj7yIoHRisVatR8yw==", "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/credential-provider-node": "3.758.0", - "@aws-sdk/middleware-host-header": "3.734.0", - "@aws-sdk/middleware-logger": "3.734.0", - "@aws-sdk/middleware-recursion-detection": "3.734.0", - "@aws-sdk/middleware-user-agent": "3.758.0", - "@aws-sdk/region-config-resolver": "3.734.0", - "@aws-sdk/types": "3.734.0", - "@aws-sdk/util-endpoints": "3.743.0", - "@aws-sdk/util-user-agent-browser": "3.734.0", - "@aws-sdk/util-user-agent-node": "3.758.0", - "@smithy/config-resolver": "^4.0.1", - "@smithy/core": "^3.1.5", - "@smithy/eventstream-serde-browser": "^4.0.1", - "@smithy/eventstream-serde-config-resolver": "^4.0.1", - "@smithy/eventstream-serde-node": "^4.0.1", - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/hash-node": "^4.0.1", - "@smithy/invalid-dependency": "^4.0.1", - "@smithy/middleware-content-length": "^4.0.1", - "@smithy/middleware-endpoint": "^4.0.6", - "@smithy/middleware-retry": "^4.0.7", - "@smithy/middleware-serde": "^4.0.2", - "@smithy/middleware-stack": "^4.0.1", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/protocol-http": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/credential-provider-node": "3.777.0", + "@aws-sdk/middleware-host-header": "3.775.0", + "@aws-sdk/middleware-logger": "3.775.0", + "@aws-sdk/middleware-recursion-detection": "3.775.0", + "@aws-sdk/middleware-user-agent": "3.775.0", + "@aws-sdk/region-config-resolver": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@aws-sdk/util-endpoints": "3.775.0", + "@aws-sdk/util-user-agent-browser": "3.775.0", + "@aws-sdk/util-user-agent-node": "3.775.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/core": "^3.2.0", + "@smithy/eventstream-serde-browser": "^4.0.2", + "@smithy/eventstream-serde-config-resolver": "^4.1.0", + "@smithy/eventstream-serde-node": "^4.0.2", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/hash-node": "^4.0.2", + "@smithy/invalid-dependency": "^4.0.2", + "@smithy/middleware-content-length": "^4.0.2", + "@smithy/middleware-endpoint": "^4.1.0", + "@smithy/middleware-retry": "^4.1.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/middleware-stack": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/protocol-http": "^5.1.0", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", "@smithy/util-base64": "^4.0.0", "@smithy/util-body-length-browser": "^4.0.0", "@smithy/util-body-length-node": "^4.0.0", - "@smithy/util-defaults-mode-browser": "^4.0.7", - "@smithy/util-defaults-mode-node": "^4.0.7", - "@smithy/util-endpoints": "^3.0.1", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-retry": "^4.0.1", - "@smithy/util-stream": "^4.1.2", + "@smithy/util-defaults-mode-browser": "^4.0.8", + "@smithy/util-defaults-mode-node": "^4.0.8", + "@smithy/util-endpoints": "^3.0.2", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-retry": "^4.0.2", + "@smithy/util-stream": "^4.2.0", "@smithy/util-utf8": "^4.0.0", "@types/uuid": "^9.0.1", "tslib": "^2.6.2", @@ -344,47 +345,47 @@ } }, "node_modules/@aws-sdk/client-cognito-identity": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-cognito-identity/-/client-cognito-identity-3.758.0.tgz", - "integrity": "sha512-8bOXVYtf/0OUN0jXTIHLv3V0TAS6kvvCRAy7nmiL/fDde0O+ChW1WZU7CVPAOtFEpFCdKskDcxFspM7m1k6qyg==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-cognito-identity/-/client-cognito-identity-3.777.0.tgz", + "integrity": "sha512-VGtFI3SH+jKfPln+9CM16F9zKieIqSxUSZNzQ6WZahPDVC79VmlG6QkXCqgm9Y4qZf4ebcdMhO23+FkR4s9vhA==", "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/credential-provider-node": "3.758.0", - "@aws-sdk/middleware-host-header": "3.734.0", - "@aws-sdk/middleware-logger": "3.734.0", - "@aws-sdk/middleware-recursion-detection": "3.734.0", - "@aws-sdk/middleware-user-agent": "3.758.0", - "@aws-sdk/region-config-resolver": "3.734.0", - "@aws-sdk/types": "3.734.0", - "@aws-sdk/util-endpoints": "3.743.0", - "@aws-sdk/util-user-agent-browser": "3.734.0", - "@aws-sdk/util-user-agent-node": "3.758.0", - "@smithy/config-resolver": "^4.0.1", - "@smithy/core": "^3.1.5", - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/hash-node": "^4.0.1", - "@smithy/invalid-dependency": "^4.0.1", - "@smithy/middleware-content-length": "^4.0.1", - "@smithy/middleware-endpoint": "^4.0.6", - "@smithy/middleware-retry": "^4.0.7", - "@smithy/middleware-serde": "^4.0.2", - "@smithy/middleware-stack": "^4.0.1", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/protocol-http": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/credential-provider-node": "3.777.0", + "@aws-sdk/middleware-host-header": "3.775.0", + "@aws-sdk/middleware-logger": "3.775.0", + "@aws-sdk/middleware-recursion-detection": "3.775.0", + "@aws-sdk/middleware-user-agent": "3.775.0", + "@aws-sdk/region-config-resolver": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@aws-sdk/util-endpoints": "3.775.0", + "@aws-sdk/util-user-agent-browser": "3.775.0", + "@aws-sdk/util-user-agent-node": "3.775.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/core": "^3.2.0", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/hash-node": "^4.0.2", + "@smithy/invalid-dependency": "^4.0.2", + "@smithy/middleware-content-length": "^4.0.2", + "@smithy/middleware-endpoint": "^4.1.0", + "@smithy/middleware-retry": "^4.1.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/middleware-stack": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/protocol-http": "^5.1.0", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", "@smithy/util-base64": "^4.0.0", "@smithy/util-body-length-browser": "^4.0.0", "@smithy/util-body-length-node": "^4.0.0", - "@smithy/util-defaults-mode-browser": "^4.0.7", - "@smithy/util-defaults-mode-node": "^4.0.7", - "@smithy/util-endpoints": "^3.0.1", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-retry": "^4.0.1", + "@smithy/util-defaults-mode-browser": "^4.0.8", + "@smithy/util-defaults-mode-node": "^4.0.8", + "@smithy/util-endpoints": "^3.0.2", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-retry": "^4.0.2", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" }, @@ -393,51 +394,51 @@ } }, "node_modules/@aws-sdk/client-sagemaker-runtime": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sagemaker-runtime/-/client-sagemaker-runtime-3.758.0.tgz", - "integrity": "sha512-6pZdZT+Xol56UKcpUDzOlRwLgmVIgv4I2bvCsvq4YI0TnSNhO6/Ob2I8l0GzUTU2qoO2XBkrhO1t+zLuc681ig==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-sagemaker-runtime/-/client-sagemaker-runtime-3.777.0.tgz", + "integrity": "sha512-b5IE89QOt7pvaImtDiOmUlKVGK7pcb3rW7nIKEqY65pJboIT/RNkehfA/XrlfgDjgGhVebojpUm/paqG+2xlDg==", "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/credential-provider-node": "3.758.0", - "@aws-sdk/middleware-host-header": "3.734.0", - "@aws-sdk/middleware-logger": "3.734.0", - "@aws-sdk/middleware-recursion-detection": "3.734.0", - "@aws-sdk/middleware-user-agent": "3.758.0", - "@aws-sdk/region-config-resolver": "3.734.0", - "@aws-sdk/types": "3.734.0", - "@aws-sdk/util-endpoints": "3.743.0", - "@aws-sdk/util-user-agent-browser": "3.734.0", - "@aws-sdk/util-user-agent-node": "3.758.0", - "@smithy/config-resolver": "^4.0.1", - "@smithy/core": "^3.1.5", - "@smithy/eventstream-serde-browser": "^4.0.1", - "@smithy/eventstream-serde-config-resolver": "^4.0.1", - "@smithy/eventstream-serde-node": "^4.0.1", - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/hash-node": "^4.0.1", - "@smithy/invalid-dependency": "^4.0.1", - "@smithy/middleware-content-length": "^4.0.1", - "@smithy/middleware-endpoint": "^4.0.6", - "@smithy/middleware-retry": "^4.0.7", - "@smithy/middleware-serde": "^4.0.2", - "@smithy/middleware-stack": "^4.0.1", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/protocol-http": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/credential-provider-node": "3.777.0", + "@aws-sdk/middleware-host-header": "3.775.0", + "@aws-sdk/middleware-logger": "3.775.0", + "@aws-sdk/middleware-recursion-detection": "3.775.0", + "@aws-sdk/middleware-user-agent": "3.775.0", + "@aws-sdk/region-config-resolver": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@aws-sdk/util-endpoints": "3.775.0", + "@aws-sdk/util-user-agent-browser": "3.775.0", + "@aws-sdk/util-user-agent-node": "3.775.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/core": "^3.2.0", + "@smithy/eventstream-serde-browser": "^4.0.2", + "@smithy/eventstream-serde-config-resolver": "^4.1.0", + "@smithy/eventstream-serde-node": "^4.0.2", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/hash-node": "^4.0.2", + "@smithy/invalid-dependency": "^4.0.2", + "@smithy/middleware-content-length": "^4.0.2", + "@smithy/middleware-endpoint": "^4.1.0", + "@smithy/middleware-retry": "^4.1.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/middleware-stack": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/protocol-http": "^5.1.0", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", "@smithy/util-base64": "^4.0.0", "@smithy/util-body-length-browser": "^4.0.0", "@smithy/util-body-length-node": "^4.0.0", - "@smithy/util-defaults-mode-browser": "^4.0.7", - "@smithy/util-defaults-mode-node": "^4.0.7", - "@smithy/util-endpoints": "^3.0.1", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-retry": "^4.0.1", - "@smithy/util-stream": "^4.1.2", + "@smithy/util-defaults-mode-browser": "^4.0.8", + "@smithy/util-defaults-mode-node": "^4.0.8", + "@smithy/util-endpoints": "^3.0.2", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-retry": "^4.0.2", + "@smithy/util-stream": "^4.2.0", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" }, @@ -446,46 +447,46 @@ } }, "node_modules/@aws-sdk/client-sso": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso/-/client-sso-3.758.0.tgz", - "integrity": "sha512-BoGO6IIWrLyLxQG6txJw6RT2urmbtlwfggapNCrNPyYjlXpzTSJhBYjndg7TpDATFd0SXL0zm8y/tXsUXNkdYQ==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/client-sso/-/client-sso-3.777.0.tgz", + "integrity": "sha512-0+z6CiAYIQa7s6FJ+dpBYPi9zr9yY5jBg/4/FGcwYbmqWPXwL9Thdtr0FearYRZgKl7bhL3m3dILCCfWqr3teQ==", "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/middleware-host-header": "3.734.0", - "@aws-sdk/middleware-logger": "3.734.0", - "@aws-sdk/middleware-recursion-detection": "3.734.0", - "@aws-sdk/middleware-user-agent": "3.758.0", - "@aws-sdk/region-config-resolver": "3.734.0", - "@aws-sdk/types": "3.734.0", - "@aws-sdk/util-endpoints": "3.743.0", - "@aws-sdk/util-user-agent-browser": "3.734.0", - "@aws-sdk/util-user-agent-node": "3.758.0", - "@smithy/config-resolver": "^4.0.1", - "@smithy/core": "^3.1.5", - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/hash-node": "^4.0.1", - "@smithy/invalid-dependency": "^4.0.1", - "@smithy/middleware-content-length": "^4.0.1", - "@smithy/middleware-endpoint": "^4.0.6", - "@smithy/middleware-retry": "^4.0.7", - "@smithy/middleware-serde": "^4.0.2", - "@smithy/middleware-stack": "^4.0.1", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/protocol-http": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/middleware-host-header": "3.775.0", + "@aws-sdk/middleware-logger": "3.775.0", + "@aws-sdk/middleware-recursion-detection": "3.775.0", + "@aws-sdk/middleware-user-agent": "3.775.0", + "@aws-sdk/region-config-resolver": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@aws-sdk/util-endpoints": "3.775.0", + "@aws-sdk/util-user-agent-browser": "3.775.0", + "@aws-sdk/util-user-agent-node": "3.775.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/core": "^3.2.0", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/hash-node": "^4.0.2", + "@smithy/invalid-dependency": "^4.0.2", + "@smithy/middleware-content-length": "^4.0.2", + "@smithy/middleware-endpoint": "^4.1.0", + "@smithy/middleware-retry": "^4.1.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/middleware-stack": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/protocol-http": "^5.1.0", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", "@smithy/util-base64": "^4.0.0", "@smithy/util-body-length-browser": "^4.0.0", "@smithy/util-body-length-node": "^4.0.0", - "@smithy/util-defaults-mode-browser": "^4.0.7", - "@smithy/util-defaults-mode-node": "^4.0.7", - "@smithy/util-endpoints": "^3.0.1", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-retry": "^4.0.1", + "@smithy/util-defaults-mode-browser": "^4.0.8", + "@smithy/util-defaults-mode-node": "^4.0.8", + "@smithy/util-endpoints": "^3.0.2", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-retry": "^4.0.2", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" }, @@ -494,19 +495,19 @@ } }, "node_modules/@aws-sdk/core": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.758.0.tgz", - "integrity": "sha512-0RswbdR9jt/XKemaLNuxi2gGr4xGlHyGxkTdhSQzCyUe9A9OPCoLl3rIESRguQEech+oJnbHk/wuiwHqTuP9sg==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/core/-/core-3.775.0.tgz", + "integrity": "sha512-8vpW4WihVfz0DX+7WnnLGm3GuQER++b0IwQG35JlQMlgqnc44M//KbJPsIHA0aJUJVwJAEShgfr5dUbY8WUzaA==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/core": "^3.1.5", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/property-provider": "^4.0.1", - "@smithy/protocol-http": "^5.0.1", - "@smithy/signature-v4": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/util-middleware": "^4.0.1", + "@aws-sdk/types": "3.775.0", + "@smithy/core": "^3.2.0", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/property-provider": "^4.0.2", + "@smithy/protocol-http": "^5.1.0", + "@smithy/signature-v4": "^5.0.2", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/util-middleware": "^4.0.2", "fast-xml-parser": "4.4.1", "tslib": "^2.6.2" }, @@ -515,14 +516,14 @@ } }, "node_modules/@aws-sdk/credential-provider-cognito-identity": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-cognito-identity/-/credential-provider-cognito-identity-3.758.0.tgz", - "integrity": "sha512-y/rHZqyChlEkNRr59gn4hv0gjhJwGmdCdW0JI1K9p3P9p7EurWGjr2M6+goTn3ilOlcAwrl5oFKR5jLt27TkOA==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-cognito-identity/-/credential-provider-cognito-identity-3.777.0.tgz", + "integrity": "sha512-lNvz3v94TvEcBvQqVUyg+c/aL3Max+8wUMXvehWoQPv9y9cJAHciZqvA/G+yFo/JB+1Y4IBpMu09W2lfpT6Euw==", "dependencies": { - "@aws-sdk/client-cognito-identity": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/property-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/client-cognito-identity": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -530,14 +531,14 @@ } }, "node_modules/@aws-sdk/credential-provider-env": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.758.0.tgz", - "integrity": "sha512-N27eFoRrO6MeUNumtNHDW9WOiwfd59LPXPqDrIa3kWL/s+fOKFHb9xIcF++bAwtcZnAxKkgpDCUP+INNZskE+w==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-env/-/credential-provider-env-3.775.0.tgz", + "integrity": "sha512-6ESVxwCbGm7WZ17kY1fjmxQud43vzJFoLd4bmlR+idQSWdqlzGDYdcfzpjDKTcivdtNrVYmFvcH1JBUwCRAZhw==", "dependencies": { - "@aws-sdk/core": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/property-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -545,19 +546,19 @@ } }, "node_modules/@aws-sdk/credential-provider-http": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.758.0.tgz", - "integrity": "sha512-Xt9/U8qUCiw1hihztWkNeIR+arg6P+yda10OuCHX6kFVx3auTlU7+hCqs3UxqniGU4dguHuftf3mRpi5/GJ33Q==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-http/-/credential-provider-http-3.775.0.tgz", + "integrity": "sha512-PjDQeDH/J1S0yWV32wCj2k5liRo0ssXMseCBEkCsD3SqsU8o5cU82b0hMX4sAib/RkglCSZqGO0xMiN0/7ndww==", "dependencies": { - "@aws-sdk/core": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/property-provider": "^4.0.1", - "@smithy/protocol-http": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/util-stream": "^4.1.2", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/property-provider": "^4.0.2", + "@smithy/protocol-http": "^5.1.0", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/util-stream": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -565,22 +566,22 @@ } }, "node_modules/@aws-sdk/credential-provider-ini": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.758.0.tgz", - "integrity": "sha512-cymSKMcP5d+OsgetoIZ5QCe1wnp2Q/tq+uIxVdh9MbfdBBEnl9Ecq6dH6VlYS89sp4QKuxHxkWXVnbXU3Q19Aw==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.777.0.tgz", + "integrity": "sha512-1X9mCuM9JSQPmQ+D2TODt4THy6aJWCNiURkmKmTIPRdno7EIKgAqrr/LLN++K5mBf54DZVKpqcJutXU2jwo01A==", "dependencies": { - "@aws-sdk/core": "3.758.0", - "@aws-sdk/credential-provider-env": "3.758.0", - "@aws-sdk/credential-provider-http": "3.758.0", - "@aws-sdk/credential-provider-process": "3.758.0", - "@aws-sdk/credential-provider-sso": "3.758.0", - "@aws-sdk/credential-provider-web-identity": "3.758.0", - "@aws-sdk/nested-clients": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/credential-provider-imds": "^4.0.1", - "@smithy/property-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/credential-provider-env": "3.775.0", + "@aws-sdk/credential-provider-http": "3.775.0", + "@aws-sdk/credential-provider-process": "3.775.0", + "@aws-sdk/credential-provider-sso": "3.777.0", + "@aws-sdk/credential-provider-web-identity": "3.777.0", + "@aws-sdk/nested-clients": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/credential-provider-imds": "^4.0.2", + "@smithy/property-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -588,21 +589,21 @@ } }, "node_modules/@aws-sdk/credential-provider-node": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.758.0.tgz", - "integrity": "sha512-+DaMv63wiq7pJrhIQzZYMn4hSarKiizDoJRvyR7WGhnn0oQ/getX9Z0VNCV3i7lIFoLNTb7WMmQ9k7+z/uD5EQ==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-node/-/credential-provider-node-3.777.0.tgz", + "integrity": "sha512-ZD66ywx1Q0KyUSuBXZIQzBe3Q7MzX8lNwsrCU43H3Fww+Y+HB3Ncws9grhSdNhKQNeGmZ+MgKybuZYaaeLwJEQ==", "dependencies": { - "@aws-sdk/credential-provider-env": "3.758.0", - "@aws-sdk/credential-provider-http": "3.758.0", - "@aws-sdk/credential-provider-ini": "3.758.0", - "@aws-sdk/credential-provider-process": "3.758.0", - "@aws-sdk/credential-provider-sso": "3.758.0", - "@aws-sdk/credential-provider-web-identity": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/credential-provider-imds": "^4.0.1", - "@smithy/property-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/credential-provider-env": "3.775.0", + "@aws-sdk/credential-provider-http": "3.775.0", + "@aws-sdk/credential-provider-ini": "3.777.0", + "@aws-sdk/credential-provider-process": "3.775.0", + "@aws-sdk/credential-provider-sso": "3.777.0", + "@aws-sdk/credential-provider-web-identity": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/credential-provider-imds": "^4.0.2", + "@smithy/property-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -610,15 +611,15 @@ } }, "node_modules/@aws-sdk/credential-provider-process": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.758.0.tgz", - "integrity": "sha512-AzcY74QTPqcbXWVgjpPZ3HOmxQZYPROIBz2YINF0OQk0MhezDWV/O7Xec+K1+MPGQO3qS6EDrUUlnPLjsqieHA==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-process/-/credential-provider-process-3.775.0.tgz", + "integrity": "sha512-A6k68H9rQp+2+7P7SGO90Csw6nrUEm0Qfjpn9Etc4EboZhhCLs9b66umUsTsSBHus4FDIe5JQxfCUyt1wgNogg==", "dependencies": { - "@aws-sdk/core": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/property-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -626,17 +627,17 @@ } }, "node_modules/@aws-sdk/credential-provider-sso": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.758.0.tgz", - "integrity": "sha512-x0FYJqcOLUCv8GLLFDYMXRAQKGjoM+L0BG4BiHYZRDf24yQWFCAZsCQAYKo6XZYh2qznbsW6f//qpyJ5b0QVKQ==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.777.0.tgz", + "integrity": "sha512-9mPz7vk9uE4PBVprfINv4tlTkyq1OonNevx2DiXC1LY4mCUCNN3RdBwAY0BTLzj0uyc3k5KxFFNbn3/8ZDQP7w==", "dependencies": { - "@aws-sdk/client-sso": "3.758.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/token-providers": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/property-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/client-sso": "3.777.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/token-providers": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -644,15 +645,15 @@ } }, "node_modules/@aws-sdk/credential-provider-web-identity": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.758.0.tgz", - "integrity": "sha512-XGguXhBqiCXMXRxcfCAVPlMbm3VyJTou79r/3mxWddHWF0XbhaQiBIbUz6vobVTD25YQRbWSmSch7VA8kI5Lrw==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.777.0.tgz", + "integrity": "sha512-uGCqr47fnthkqwq5luNl2dksgcpHHjSXz2jUra7TXtFOpqvnhOW8qXjoa1ivlkq8qhqlaZwCzPdbcN0lXpmLzQ==", "dependencies": { - "@aws-sdk/core": "3.758.0", - "@aws-sdk/nested-clients": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/property-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/nested-clients": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -660,26 +661,28 @@ } }, "node_modules/@aws-sdk/credential-providers": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/credential-providers/-/credential-providers-3.758.0.tgz", - "integrity": "sha512-BaGVBdm9ynsErIc/mLuUwJ1OQcL/pkhCuAm24jpsif3evZ5wgyZnEAZB2yRin+mQnQaQT3L+KvTbdKGfjL8+fQ==", + "version": "3.778.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/credential-providers/-/credential-providers-3.778.0.tgz", + "integrity": "sha512-Yy1RSBvoDp/iqGDpmgy5/YnSP2ac9NxTv3wdAjKlqVVStlKWU9nG8MPHZRfy01oPNJ5YWZL9stxHjNKC9hg9eg==", "dependencies": { - "@aws-sdk/client-cognito-identity": "3.758.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/credential-provider-cognito-identity": "3.758.0", - "@aws-sdk/credential-provider-env": "3.758.0", - "@aws-sdk/credential-provider-http": "3.758.0", - "@aws-sdk/credential-provider-ini": "3.758.0", - "@aws-sdk/credential-provider-node": "3.758.0", - "@aws-sdk/credential-provider-process": "3.758.0", - "@aws-sdk/credential-provider-sso": "3.758.0", - "@aws-sdk/credential-provider-web-identity": "3.758.0", - "@aws-sdk/nested-clients": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/core": "^3.1.5", - "@smithy/credential-provider-imds": "^4.0.1", - "@smithy/property-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/client-cognito-identity": "3.777.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/credential-provider-cognito-identity": "3.777.0", + "@aws-sdk/credential-provider-env": "3.775.0", + "@aws-sdk/credential-provider-http": "3.775.0", + "@aws-sdk/credential-provider-ini": "3.777.0", + "@aws-sdk/credential-provider-node": "3.777.0", + "@aws-sdk/credential-provider-process": "3.775.0", + "@aws-sdk/credential-provider-sso": "3.777.0", + "@aws-sdk/credential-provider-web-identity": "3.777.0", + "@aws-sdk/nested-clients": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/core": "^3.2.0", + "@smithy/credential-provider-imds": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/property-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -687,13 +690,13 @@ } }, "node_modules/@aws-sdk/middleware-host-header": { - "version": "3.734.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-host-header/-/middleware-host-header-3.734.0.tgz", - "integrity": "sha512-LW7RRgSOHHBzWZnigNsDIzu3AiwtjeI2X66v+Wn1P1u+eXssy1+up4ZY/h+t2sU4LU36UvEf+jrZti9c6vRnFw==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-host-header/-/middleware-host-header-3.775.0.tgz", + "integrity": "sha512-tkSegM0Z6WMXpLB8oPys/d+umYIocvO298mGvcMCncpRl77L9XkvSLJIFzaHes+o7djAgIduYw8wKIMStFss2w==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/types": "3.775.0", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -701,12 +704,12 @@ } }, "node_modules/@aws-sdk/middleware-logger": { - "version": "3.734.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-logger/-/middleware-logger-3.734.0.tgz", - "integrity": "sha512-mUMFITpJUW3LcKvFok176eI5zXAUomVtahb9IQBwLzkqFYOrMJvWAvoV4yuxrJ8TlQBG8gyEnkb9SnhZvjg67w==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-logger/-/middleware-logger-3.775.0.tgz", + "integrity": "sha512-FaxO1xom4MAoUJsldmR92nT1G6uZxTdNYOFYtdHfd6N2wcNaTuxgjIvqzg5y7QIH9kn58XX/dzf1iTjgqUStZw==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/types": "^4.1.0", + "@aws-sdk/types": "3.775.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -714,13 +717,13 @@ } }, "node_modules/@aws-sdk/middleware-recursion-detection": { - "version": "3.734.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-recursion-detection/-/middleware-recursion-detection-3.734.0.tgz", - "integrity": "sha512-CUat2d9ITsFc2XsmeiRQO96iWpxSKYFjxvj27Hc7vo87YUHRnfMfnc8jw1EpxEwMcvBD7LsRa6vDNky6AjcrFA==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-recursion-detection/-/middleware-recursion-detection-3.775.0.tgz", + "integrity": "sha512-GLCzC8D0A0YDG5u3F5U03Vb9j5tcOEFhr8oc6PDk0k0vm5VwtZOE6LvK7hcCSoAB4HXyOUM0sQuXrbaAh9OwXA==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/types": "3.775.0", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -728,16 +731,16 @@ } }, "node_modules/@aws-sdk/middleware-user-agent": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-user-agent/-/middleware-user-agent-3.758.0.tgz", - "integrity": "sha512-iNyehQXtQlj69JCgfaOssgZD4HeYGOwxcaKeG6F+40cwBjTAi0+Ph1yfDwqk2qiBPIRWJ/9l2LodZbxiBqgrwg==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/middleware-user-agent/-/middleware-user-agent-3.775.0.tgz", + "integrity": "sha512-7Lffpr1ptOEDE1ZYH1T78pheEY1YmeXWBfFt/amZ6AGsKSLG+JPXvof3ltporTGR2bhH/eJPo7UHCglIuXfzYg==", "dependencies": { - "@aws-sdk/core": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@aws-sdk/util-endpoints": "3.743.0", - "@smithy/core": "^3.1.5", - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@aws-sdk/util-endpoints": "3.775.0", + "@smithy/core": "^3.2.0", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -745,46 +748,46 @@ } }, "node_modules/@aws-sdk/nested-clients": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/nested-clients/-/nested-clients-3.758.0.tgz", - "integrity": "sha512-YZ5s7PSvyF3Mt2h1EQulCG93uybprNGbBkPmVuy/HMMfbFTt4iL3SbKjxqvOZelm86epFfj7pvK7FliI2WOEcg==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/nested-clients/-/nested-clients-3.777.0.tgz", + "integrity": "sha512-bmmVRsCjuYlStYPt06hr+f8iEyWg7+AklKCA8ZLDEJujXhXIowgUIqXmqpTkXwkVvDQ9tzU7hxaONjyaQCGybA==", "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", - "@aws-sdk/core": "3.758.0", - "@aws-sdk/middleware-host-header": "3.734.0", - "@aws-sdk/middleware-logger": "3.734.0", - "@aws-sdk/middleware-recursion-detection": "3.734.0", - "@aws-sdk/middleware-user-agent": "3.758.0", - "@aws-sdk/region-config-resolver": "3.734.0", - "@aws-sdk/types": "3.734.0", - "@aws-sdk/util-endpoints": "3.743.0", - "@aws-sdk/util-user-agent-browser": "3.734.0", - "@aws-sdk/util-user-agent-node": "3.758.0", - "@smithy/config-resolver": "^4.0.1", - "@smithy/core": "^3.1.5", - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/hash-node": "^4.0.1", - "@smithy/invalid-dependency": "^4.0.1", - "@smithy/middleware-content-length": "^4.0.1", - "@smithy/middleware-endpoint": "^4.0.6", - "@smithy/middleware-retry": "^4.0.7", - "@smithy/middleware-serde": "^4.0.2", - "@smithy/middleware-stack": "^4.0.1", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/protocol-http": "^5.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", + "@aws-sdk/core": "3.775.0", + "@aws-sdk/middleware-host-header": "3.775.0", + "@aws-sdk/middleware-logger": "3.775.0", + "@aws-sdk/middleware-recursion-detection": "3.775.0", + "@aws-sdk/middleware-user-agent": "3.775.0", + "@aws-sdk/region-config-resolver": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@aws-sdk/util-endpoints": "3.775.0", + "@aws-sdk/util-user-agent-browser": "3.775.0", + "@aws-sdk/util-user-agent-node": "3.775.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/core": "^3.2.0", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/hash-node": "^4.0.2", + "@smithy/invalid-dependency": "^4.0.2", + "@smithy/middleware-content-length": "^4.0.2", + "@smithy/middleware-endpoint": "^4.1.0", + "@smithy/middleware-retry": "^4.1.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/middleware-stack": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/protocol-http": "^5.1.0", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", "@smithy/util-base64": "^4.0.0", "@smithy/util-body-length-browser": "^4.0.0", "@smithy/util-body-length-node": "^4.0.0", - "@smithy/util-defaults-mode-browser": "^4.0.7", - "@smithy/util-defaults-mode-node": "^4.0.7", - "@smithy/util-endpoints": "^3.0.1", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-retry": "^4.0.1", + "@smithy/util-defaults-mode-browser": "^4.0.8", + "@smithy/util-defaults-mode-node": "^4.0.8", + "@smithy/util-endpoints": "^3.0.2", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-retry": "^4.0.2", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" }, @@ -793,15 +796,15 @@ } }, "node_modules/@aws-sdk/region-config-resolver": { - "version": "3.734.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/region-config-resolver/-/region-config-resolver-3.734.0.tgz", - "integrity": "sha512-Lvj1kPRC5IuJBr9DyJ9T9/plkh+EfKLy+12s/mykOy1JaKHDpvj+XGy2YO6YgYVOb8JFtaqloid+5COtje4JTQ==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/region-config-resolver/-/region-config-resolver-3.775.0.tgz", + "integrity": "sha512-40iH3LJjrQS3LKUJAl7Wj0bln7RFPEvUYKFxtP8a+oKFDO0F65F52xZxIJbPn6sHkxWDAnZlGgdjZXM3p2g5wQ==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/types": "3.775.0", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "@smithy/util-config-provider": "^4.0.0", - "@smithy/util-middleware": "^4.0.1", + "@smithy/util-middleware": "^4.0.2", "tslib": "^2.6.2" }, "engines": { @@ -809,15 +812,15 @@ } }, "node_modules/@aws-sdk/token-providers": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.758.0.tgz", - "integrity": "sha512-ckptN1tNrIfQUaGWm/ayW1ddG+imbKN7HHhjFdS4VfItsP0QQOB0+Ov+tpgb4MoNR4JaUghMIVStjIeHN2ks1w==", + "version": "3.777.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/token-providers/-/token-providers-3.777.0.tgz", + "integrity": "sha512-Yc2cDONsHOa4dTSGOev6Ng2QgTKQUEjaUnsyKd13pc/nLLz/WLqHiQ/o7PcnKERJxXGs1g1C6l3sNXiX+kbnFQ==", "dependencies": { - "@aws-sdk/nested-clients": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/property-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/nested-clients": "3.777.0", + "@aws-sdk/types": "3.775.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -825,11 +828,11 @@ } }, "node_modules/@aws-sdk/types": { - "version": "3.734.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.734.0.tgz", - "integrity": "sha512-o11tSPTT70nAkGV1fN9wm/hAIiLPyWX6SuGf+9JyTp7S/rC2cFWhR26MvA69nplcjNaXVzB0f+QFrLXXjOqCrg==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/types/-/types-3.775.0.tgz", + "integrity": "sha512-ZoGKwa4C9fC9Av6bdfqcW6Ix5ot05F/S4VxWR2nHuMv7hzfmAjTOcUiWT7UR4hM/U0whf84VhDtXN/DWAk52KA==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -837,13 +840,13 @@ } }, "node_modules/@aws-sdk/util-endpoints": { - "version": "3.743.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-endpoints/-/util-endpoints-3.743.0.tgz", - "integrity": "sha512-sN1l559zrixeh5x+pttrnd0A3+r34r0tmPkJ/eaaMaAzXqsmKU/xYre9K3FNnsSS1J1k4PEfk/nHDTVUgFYjnw==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-endpoints/-/util-endpoints-3.775.0.tgz", + "integrity": "sha512-yjWmUgZC9tUxAo8Uaplqmq0eUh0zrbZJdwxGRKdYxfm4RG6fMw1tj52+KkatH7o+mNZvg1GDcVp/INktxonJLw==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/types": "^4.1.0", - "@smithy/util-endpoints": "^3.0.1", + "@aws-sdk/types": "3.775.0", + "@smithy/types": "^4.2.0", + "@smithy/util-endpoints": "^3.0.2", "tslib": "^2.6.2" }, "engines": { @@ -862,25 +865,25 @@ } }, "node_modules/@aws-sdk/util-user-agent-browser": { - "version": "3.734.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-browser/-/util-user-agent-browser-3.734.0.tgz", - "integrity": "sha512-xQTCus6Q9LwUuALW+S76OL0jcWtMOVu14q+GoLnWPUM7QeUw963oQcLhF7oq0CtaLLKyl4GOUfcwc773Zmwwng==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-browser/-/util-user-agent-browser-3.775.0.tgz", + "integrity": "sha512-txw2wkiJmZKVdDbscK7VBK+u+TJnRtlUjRTLei+elZg2ADhpQxfVAQl436FUeIv6AhB/oRHW6/K/EAGXUSWi0A==", "dependencies": { - "@aws-sdk/types": "3.734.0", - "@smithy/types": "^4.1.0", + "@aws-sdk/types": "3.775.0", + "@smithy/types": "^4.2.0", "bowser": "^2.11.0", "tslib": "^2.6.2" } }, "node_modules/@aws-sdk/util-user-agent-node": { - "version": "3.758.0", - "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-node/-/util-user-agent-node-3.758.0.tgz", - "integrity": "sha512-A5EZw85V6WhoKMV2hbuFRvb9NPlxEErb4HPO6/SPXYY4QrjprIzScHxikqcWv1w4J3apB1wto9LPU3IMsYtfrw==", + "version": "3.775.0", + "resolved": "https://registry.npmjs.org/@aws-sdk/util-user-agent-node/-/util-user-agent-node-3.775.0.tgz", + "integrity": "sha512-N9yhTevbizTOMo3drH7Eoy6OkJ3iVPxhV7dwb6CMAObbLneS36CSfA6xQXupmHWcRvZPTz8rd1JGG3HzFOau+g==", "dependencies": { - "@aws-sdk/middleware-user-agent": "3.758.0", - "@aws-sdk/types": "3.734.0", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@aws-sdk/middleware-user-agent": "3.775.0", + "@aws-sdk/types": "3.775.0", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4533,11 +4536,11 @@ } }, "node_modules/@smithy/abort-controller": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-4.0.1.tgz", - "integrity": "sha512-fiUIYgIgRjMWznk6iLJz35K2YxSLHzLBA/RC6lBrKfQ8fHbPfvk7Pk9UvpKoHgJjI18MnbPuEju53zcVy6KF1g==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/abort-controller/-/abort-controller-4.0.2.tgz", + "integrity": "sha512-Sl/78VDtgqKxN2+1qduaVE140XF+Xg+TafkncspwM4jFP/LHr76ZHmIY/y3V1M0mMLNk+Je6IGbzxy23RSToMw==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4545,14 +4548,14 @@ } }, "node_modules/@smithy/config-resolver": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/config-resolver/-/config-resolver-4.0.1.tgz", - "integrity": "sha512-Igfg8lKu3dRVkTSEm98QpZUvKEOa71jDX4vKRcvJVyRc3UgN3j7vFMf0s7xLQhYmKa8kyJGQgUJDOV5V3neVlQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@smithy/config-resolver/-/config-resolver-4.1.0.tgz", + "integrity": "sha512-8smPlwhga22pwl23fM5ew4T9vfLUCeFXlcqNOCD5M5h8VmNPNUE9j6bQSuRXpDSV11L/E/SwEBQuW8hr6+nS1A==", "dependencies": { - "@smithy/node-config-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "@smithy/util-config-provider": "^4.0.0", - "@smithy/util-middleware": "^4.0.1", + "@smithy/util-middleware": "^4.0.2", "tslib": "^2.6.2" }, "engines": { @@ -4560,16 +4563,16 @@ } }, "node_modules/@smithy/core": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/@smithy/core/-/core-3.1.5.tgz", - "integrity": "sha512-HLclGWPkCsekQgsyzxLhCQLa8THWXtB5PxyYN+2O6nkyLt550KQKTlbV2D1/j5dNIQapAZM1+qFnpBFxZQkgCA==", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@smithy/core/-/core-3.2.0.tgz", + "integrity": "sha512-k17bgQhVZ7YmUvA8at4af1TDpl0NDMBuBKJl8Yg0nrefwmValU+CnA5l/AriVdQNthU/33H3nK71HrLgqOPr1Q==", "dependencies": { - "@smithy/middleware-serde": "^4.0.2", - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", "@smithy/util-body-length-browser": "^4.0.0", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-stream": "^4.1.2", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-stream": "^4.2.0", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" }, @@ -4578,14 +4581,14 @@ } }, "node_modules/@smithy/credential-provider-imds": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/credential-provider-imds/-/credential-provider-imds-4.0.1.tgz", - "integrity": "sha512-l/qdInaDq1Zpznpmev/+52QomsJNZ3JkTl5yrTl02V6NBgJOQ4LY0SFw/8zsMwj3tLe8vqiIuwF6nxaEwgf6mg==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/credential-provider-imds/-/credential-provider-imds-4.0.2.tgz", + "integrity": "sha512-32lVig6jCaWBHnY+OEQ6e6Vnt5vDHaLiydGrwYMW9tPqO688hPGTYRamYJ1EptxEC2rAwJrHWmPoKRBl4iTa8w==", "dependencies": { - "@smithy/node-config-provider": "^4.0.1", - "@smithy/property-provider": "^4.0.1", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/property-provider": "^4.0.2", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", "tslib": "^2.6.2" }, "engines": { @@ -4593,12 +4596,12 @@ } }, "node_modules/@smithy/eventstream-codec": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-codec/-/eventstream-codec-4.0.1.tgz", - "integrity": "sha512-Q2bCAAR6zXNVtJgifsU16ZjKGqdw/DyecKNgIgi7dlqw04fqDu0mnq+JmGphqheypVc64CYq3azSuCpAdFk2+A==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/eventstream-codec/-/eventstream-codec-4.0.2.tgz", + "integrity": "sha512-p+f2kLSK7ZrXVfskU/f5dzksKTewZk8pJLPvER3aFHPt76C2MxD9vNatSfLzzQSQB4FNO96RK4PSXfhD1TTeMQ==", "dependencies": { "@aws-crypto/crc32": "5.2.0", - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "@smithy/util-hex-encoding": "^4.0.0", "tslib": "^2.6.2" }, @@ -4607,12 +4610,12 @@ } }, "node_modules/@smithy/eventstream-serde-browser": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-browser/-/eventstream-serde-browser-4.0.1.tgz", - "integrity": "sha512-HbIybmz5rhNg+zxKiyVAnvdM3vkzjE6ccrJ620iPL8IXcJEntd3hnBl+ktMwIy12Te/kyrSbUb8UCdnUT4QEdA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-browser/-/eventstream-serde-browser-4.0.2.tgz", + "integrity": "sha512-CepZCDs2xgVUtH7ZZ7oDdZFH8e6Y2zOv8iiX6RhndH69nlojCALSKK+OXwZUgOtUZEUaZ5e1hULVCHYbCn7pug==", "dependencies": { - "@smithy/eventstream-serde-universal": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/eventstream-serde-universal": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4620,11 +4623,11 @@ } }, "node_modules/@smithy/eventstream-serde-config-resolver": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-config-resolver/-/eventstream-serde-config-resolver-4.0.1.tgz", - "integrity": "sha512-lSipaiq3rmHguHa3QFF4YcCM3VJOrY9oq2sow3qlhFY+nBSTF/nrO82MUQRPrxHQXA58J5G1UnU2WuJfi465BA==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-config-resolver/-/eventstream-serde-config-resolver-4.1.0.tgz", + "integrity": "sha512-1PI+WPZ5TWXrfj3CIoKyUycYynYJgZjuQo8U+sphneOtjsgrttYybdqESFReQrdWJ+LKt6NEdbYzmmfDBmjX2A==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4632,12 +4635,12 @@ } }, "node_modules/@smithy/eventstream-serde-node": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-node/-/eventstream-serde-node-4.0.1.tgz", - "integrity": "sha512-o4CoOI6oYGYJ4zXo34U8X9szDe3oGjmHgsMGiZM0j4vtNoT+h80TLnkUcrLZR3+E6HIxqW+G+9WHAVfl0GXK0Q==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-node/-/eventstream-serde-node-4.0.2.tgz", + "integrity": "sha512-C5bJ/C6x9ENPMx2cFOirspnF9ZsBVnBMtP6BdPl/qYSuUawdGQ34Lq0dMcf42QTjUZgWGbUIZnz6+zLxJlb9aw==", "dependencies": { - "@smithy/eventstream-serde-universal": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/eventstream-serde-universal": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4645,12 +4648,12 @@ } }, "node_modules/@smithy/eventstream-serde-universal": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-universal/-/eventstream-serde-universal-4.0.1.tgz", - "integrity": "sha512-Z94uZp0tGJuxds3iEAZBqGU2QiaBHP4YytLUjwZWx+oUeohCsLyUm33yp4MMBmhkuPqSbQCXq5hDet6JGUgHWA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/eventstream-serde-universal/-/eventstream-serde-universal-4.0.2.tgz", + "integrity": "sha512-St8h9JqzvnbB52FtckiHPN4U/cnXcarMniXRXTKn0r4b4XesZOGiAyUdj1aXbqqn1icSqBlzzUsCl6nPB018ng==", "dependencies": { - "@smithy/eventstream-codec": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/eventstream-codec": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4658,13 +4661,13 @@ } }, "node_modules/@smithy/fetch-http-handler": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-5.0.1.tgz", - "integrity": "sha512-3aS+fP28urrMW2KTjb6z9iFow6jO8n3MFfineGbndvzGZit3taZhKWtTorf+Gp5RpFDDafeHlhfsGlDCXvUnJA==", + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/@smithy/fetch-http-handler/-/fetch-http-handler-5.0.2.tgz", + "integrity": "sha512-+9Dz8sakS9pe7f2cBocpJXdeVjMopUDLgZs1yWeu7h++WqSbjUYv/JAJwKwXw1HV6gq1jyWjxuyn24E2GhoEcQ==", "dependencies": { - "@smithy/protocol-http": "^5.0.1", - "@smithy/querystring-builder": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/protocol-http": "^5.1.0", + "@smithy/querystring-builder": "^4.0.2", + "@smithy/types": "^4.2.0", "@smithy/util-base64": "^4.0.0", "tslib": "^2.6.2" }, @@ -4673,11 +4676,11 @@ } }, "node_modules/@smithy/hash-node": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/hash-node/-/hash-node-4.0.1.tgz", - "integrity": "sha512-TJ6oZS+3r2Xu4emVse1YPB3Dq3d8RkZDKcPr71Nj/lJsdAP1c7oFzYqEn1IBc915TsgLl2xIJNuxCz+gLbLE0w==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/hash-node/-/hash-node-4.0.2.tgz", + "integrity": "sha512-VnTpYPnRUE7yVhWozFdlxcYknv9UN7CeOqSrMH+V877v4oqtVYuoqhIhtSjmGPvYrYnAkaM61sLMKHvxL138yg==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "@smithy/util-buffer-from": "^4.0.0", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" @@ -4687,11 +4690,11 @@ } }, "node_modules/@smithy/invalid-dependency": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/invalid-dependency/-/invalid-dependency-4.0.1.tgz", - "integrity": "sha512-gdudFPf4QRQ5pzj7HEnu6FhKRi61BfH/Gk5Yf6O0KiSbr1LlVhgjThcvjdu658VE6Nve8vaIWB8/fodmS1rBPQ==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/invalid-dependency/-/invalid-dependency-4.0.2.tgz", + "integrity": "sha512-GatB4+2DTpgWPday+mnUkoumP54u/MDM/5u44KF9hIu8jF0uafZtQLcdfIKkIcUNuF/fBojpLEHZS/56JqPeXQ==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4710,12 +4713,12 @@ } }, "node_modules/@smithy/middleware-content-length": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/middleware-content-length/-/middleware-content-length-4.0.1.tgz", - "integrity": "sha512-OGXo7w5EkB5pPiac7KNzVtfCW2vKBTZNuCctn++TTSOMpe6RZO/n6WEC1AxJINn3+vWLKW49uad3lo/u0WJ9oQ==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/middleware-content-length/-/middleware-content-length-4.0.2.tgz", + "integrity": "sha512-hAfEXm1zU+ELvucxqQ7I8SszwQ4znWMbNv6PLMndN83JJN41EPuS93AIyh2N+gJ6x8QFhzSO6b7q2e6oClDI8A==", "dependencies": { - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4723,17 +4726,17 @@ } }, "node_modules/@smithy/middleware-endpoint": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-4.0.6.tgz", - "integrity": "sha512-ftpmkTHIFqgaFugcjzLZv3kzPEFsBFSnq1JsIkr2mwFzCraZVhQk2gqN51OOeRxqhbPTkRFj39Qd2V91E/mQxg==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@smithy/middleware-endpoint/-/middleware-endpoint-4.1.0.tgz", + "integrity": "sha512-xhLimgNCbCzsUppRTGXWkZywksuTThxaIB0HwbpsVLY5sceac4e1TZ/WKYqufQLaUy+gUSJGNdwD2jo3cXL0iA==", "dependencies": { - "@smithy/core": "^3.1.5", - "@smithy/middleware-serde": "^4.0.2", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", - "@smithy/url-parser": "^4.0.1", - "@smithy/util-middleware": "^4.0.1", + "@smithy/core": "^3.2.0", + "@smithy/middleware-serde": "^4.0.3", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", + "@smithy/url-parser": "^4.0.2", + "@smithy/util-middleware": "^4.0.2", "tslib": "^2.6.2" }, "engines": { @@ -4741,17 +4744,17 @@ } }, "node_modules/@smithy/middleware-retry": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/@smithy/middleware-retry/-/middleware-retry-4.0.7.tgz", - "integrity": "sha512-58j9XbUPLkqAcV1kHzVX/kAR16GT+j7DUZJqwzsxh1jtz7G82caZiGyyFgUvogVfNTg3TeAOIJepGc8TXF4AVQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@smithy/middleware-retry/-/middleware-retry-4.1.0.tgz", + "integrity": "sha512-2zAagd1s6hAaI/ap6SXi5T3dDwBOczOMCSkkYzktqN1+tzbk1GAsHNAdo/1uzxz3Ky02jvZQwbi/vmDA6z4Oyg==", "dependencies": { - "@smithy/node-config-provider": "^4.0.1", - "@smithy/protocol-http": "^5.0.1", - "@smithy/service-error-classification": "^4.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", - "@smithy/util-middleware": "^4.0.1", - "@smithy/util-retry": "^4.0.1", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/protocol-http": "^5.1.0", + "@smithy/service-error-classification": "^4.0.2", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", + "@smithy/util-middleware": "^4.0.2", + "@smithy/util-retry": "^4.0.2", "tslib": "^2.6.2", "uuid": "^9.0.1" }, @@ -4760,11 +4763,11 @@ } }, "node_modules/@smithy/middleware-serde": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-4.0.2.tgz", - "integrity": "sha512-Sdr5lOagCn5tt+zKsaW+U2/iwr6bI9p08wOkCp6/eL6iMbgdtc2R5Ety66rf87PeohR0ExI84Txz9GYv5ou3iQ==", + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/@smithy/middleware-serde/-/middleware-serde-4.0.3.tgz", + "integrity": "sha512-rfgDVrgLEVMmMn0BI8O+8OVr6vXzjV7HZj57l0QxslhzbvVfikZbVfBVthjLHqib4BW44QhcIgJpvebHlRaC9A==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4772,11 +4775,11 @@ } }, "node_modules/@smithy/middleware-stack": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-4.0.1.tgz", - "integrity": "sha512-dHwDmrtR/ln8UTHpaIavRSzeIk5+YZTBtLnKwDW3G2t6nAupCiQUvNzNoHBpik63fwUaJPtlnMzXbQrNFWssIA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/middleware-stack/-/middleware-stack-4.0.2.tgz", + "integrity": "sha512-eSPVcuJJGVYrFYu2hEq8g8WWdJav3sdrI4o2c6z/rjnYDd3xH9j9E7deZQCzFn4QvGPouLngH3dQ+QVTxv5bOQ==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4784,13 +4787,13 @@ } }, "node_modules/@smithy/node-config-provider": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-4.0.1.tgz", - "integrity": "sha512-8mRTjvCtVET8+rxvmzRNRR0hH2JjV0DFOmwXPrISmTIJEfnCBugpYYGAsCj8t41qd+RB5gbheSQ/6aKZCQvFLQ==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/node-config-provider/-/node-config-provider-4.0.2.tgz", + "integrity": "sha512-WgCkILRZfJwJ4Da92a6t3ozN/zcvYyJGUTmfGbgS/FkCcoCjl7G4FJaCDN1ySdvLvemnQeo25FdkyMSTSwulsw==", "dependencies": { - "@smithy/property-provider": "^4.0.1", - "@smithy/shared-ini-file-loader": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/shared-ini-file-loader": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4798,14 +4801,14 @@ } }, "node_modules/@smithy/node-http-handler": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-4.0.3.tgz", - "integrity": "sha512-dYCLeINNbYdvmMLtW0VdhW1biXt+PPCGazzT5ZjKw46mOtdgToQEwjqZSS9/EN8+tNs/RO0cEWG044+YZs97aA==", + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/@smithy/node-http-handler/-/node-http-handler-4.0.4.tgz", + "integrity": "sha512-/mdqabuAT3o/ihBGjL94PUbTSPSRJ0eeVTdgADzow0wRJ0rN4A27EOrtlK56MYiO1fDvlO3jVTCxQtQmK9dZ1g==", "dependencies": { - "@smithy/abort-controller": "^4.0.1", - "@smithy/protocol-http": "^5.0.1", - "@smithy/querystring-builder": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/abort-controller": "^4.0.2", + "@smithy/protocol-http": "^5.1.0", + "@smithy/querystring-builder": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4813,11 +4816,11 @@ } }, "node_modules/@smithy/property-provider": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-4.0.1.tgz", - "integrity": "sha512-o+VRiwC2cgmk/WFV0jaETGOtX16VNPp2bSQEzu0whbReqE1BMqsP2ami2Vi3cbGVdKu1kq9gQkDAGKbt0WOHAQ==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/property-provider/-/property-provider-4.0.2.tgz", + "integrity": "sha512-wNRoQC1uISOuNc2s4hkOYwYllmiyrvVXWMtq+TysNRVQaHm4yoafYQyjN/goYZS+QbYlPIbb/QRjaUZMuzwQ7A==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4825,11 +4828,11 @@ } }, "node_modules/@smithy/protocol-http": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-5.0.1.tgz", - "integrity": "sha512-TE4cpj49jJNB/oHyh/cRVEgNZaoPaxd4vteJNB0yGidOCVR0jCw/hjPVsT8Q8FRmj8Bd3bFZt8Dh7xGCT+xMBQ==", + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@smithy/protocol-http/-/protocol-http-5.1.0.tgz", + "integrity": "sha512-KxAOL1nUNw2JTYrtviRRjEnykIDhxc84qMBzxvu1MUfQfHTuBlCG7PA6EdVwqpJjH7glw7FqQoFxUJSyBQgu7g==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4837,11 +4840,11 @@ } }, "node_modules/@smithy/querystring-builder": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-4.0.1.tgz", - "integrity": "sha512-wU87iWZoCbcqrwszsOewEIuq+SU2mSoBE2CcsLwE0I19m0B2gOJr1MVjxWcDQYOzHbR1xCk7AcOBbGFUYOKvdg==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/querystring-builder/-/querystring-builder-4.0.2.tgz", + "integrity": "sha512-NTOs0FwHw1vimmQM4ebh+wFQvOwkEf/kQL6bSM1Lock+Bv4I89B3hGYoUEPkmvYPkDKyp5UdXJYu+PoTQ3T31Q==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "@smithy/util-uri-escape": "^4.0.0", "tslib": "^2.6.2" }, @@ -4850,11 +4853,11 @@ } }, "node_modules/@smithy/querystring-parser": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-4.0.1.tgz", - "integrity": "sha512-Ma2XC7VS9aV77+clSFylVUnPZRindhB7BbmYiNOdr+CHt/kZNJoPP0cd3QxCnCFyPXC4eybmyE98phEHkqZ5Jw==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/querystring-parser/-/querystring-parser-4.0.2.tgz", + "integrity": "sha512-v6w8wnmZcVXjfVLjxw8qF7OwESD9wnpjp0Dqry/Pod0/5vcEA3qxCr+BhbOHlxS8O+29eLpT3aagxXGwIoEk7Q==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4862,22 +4865,22 @@ } }, "node_modules/@smithy/service-error-classification": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/service-error-classification/-/service-error-classification-4.0.1.tgz", - "integrity": "sha512-3JNjBfOWpj/mYfjXJHB4Txc/7E4LVq32bwzE7m28GN79+M1f76XHflUaSUkhOriprPDzev9cX/M+dEB80DNDKA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/service-error-classification/-/service-error-classification-4.0.2.tgz", + "integrity": "sha512-LA86xeFpTKn270Hbkixqs5n73S+LVM0/VZco8dqd+JT75Dyx3Lcw/MraL7ybjmz786+160K8rPOmhsq0SocoJQ==", "dependencies": { - "@smithy/types": "^4.1.0" + "@smithy/types": "^4.2.0" }, "engines": { "node": ">=18.0.0" } }, "node_modules/@smithy/shared-ini-file-loader": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-4.0.1.tgz", - "integrity": "sha512-hC8F6qTBbuHRI/uqDgqqi6J0R4GtEZcgrZPhFQnMhfJs3MnUTGSnR1NSJCJs5VWlMydu0kJz15M640fJlRsIOw==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-4.0.2.tgz", + "integrity": "sha512-J9/gTWBGVuFZ01oVA6vdb4DAjf1XbDhK6sLsu3OS9qmLrS6KB5ygpeHiM3miIbj1qgSJ96GYszXFWv6ErJ8QEw==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4885,15 +4888,15 @@ } }, "node_modules/@smithy/signature-v4": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-5.0.1.tgz", - "integrity": "sha512-nCe6fQ+ppm1bQuw5iKoeJ0MJfz2os7Ic3GBjOkLOPtavbD1ONoyE3ygjBfz2ythFWm4YnRm6OxW+8p/m9uCoIA==", + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/@smithy/signature-v4/-/signature-v4-5.0.2.tgz", + "integrity": "sha512-Mz+mc7okA73Lyz8zQKJNyr7lIcHLiPYp0+oiqiMNc/t7/Kf2BENs5d63pEj7oPqdjaum6g0Fc8wC78dY1TgtXw==", "dependencies": { "@smithy/is-array-buffer": "^4.0.0", - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", "@smithy/util-hex-encoding": "^4.0.0", - "@smithy/util-middleware": "^4.0.1", + "@smithy/util-middleware": "^4.0.2", "@smithy/util-uri-escape": "^4.0.0", "@smithy/util-utf8": "^4.0.0", "tslib": "^2.6.2" @@ -4903,16 +4906,16 @@ } }, "node_modules/@smithy/smithy-client": { - "version": "4.1.6", - "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-4.1.6.tgz", - "integrity": "sha512-UYDolNg6h2O0L+cJjtgSyKKvEKCOa/8FHYJnBobyeoeWDmNpXjwOAtw16ezyeu1ETuuLEOZbrynK0ZY1Lx9Jbw==", + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@smithy/smithy-client/-/smithy-client-4.2.0.tgz", + "integrity": "sha512-Qs65/w30pWV7LSFAez9DKy0Koaoh3iHhpcpCCJ4waj/iqwsuSzJna2+vYwq46yBaqO5ZbP9TjUsATUNxrKeBdw==", "dependencies": { - "@smithy/core": "^3.1.5", - "@smithy/middleware-endpoint": "^4.0.6", - "@smithy/middleware-stack": "^4.0.1", - "@smithy/protocol-http": "^5.0.1", - "@smithy/types": "^4.1.0", - "@smithy/util-stream": "^4.1.2", + "@smithy/core": "^3.2.0", + "@smithy/middleware-endpoint": "^4.1.0", + "@smithy/middleware-stack": "^4.0.2", + "@smithy/protocol-http": "^5.1.0", + "@smithy/types": "^4.2.0", + "@smithy/util-stream": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -4920,9 +4923,9 @@ } }, "node_modules/@smithy/types": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/@smithy/types/-/types-4.1.0.tgz", - "integrity": "sha512-enhjdwp4D7CXmwLtD6zbcDMbo6/T6WtuuKCY49Xxc6OMOmUWlBEBDREsxxgV2LIdeQPW756+f97GzcgAwp3iLw==", + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@smithy/types/-/types-4.2.0.tgz", + "integrity": "sha512-7eMk09zQKCO+E/ivsjQv+fDlOupcFUCSC/L2YUPgwhvowVGWbPQHjEFcmjt7QQ4ra5lyowS92SV53Zc6XD4+fg==", "dependencies": { "tslib": "^2.6.2" }, @@ -4931,12 +4934,12 @@ } }, "node_modules/@smithy/url-parser": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-4.0.1.tgz", - "integrity": "sha512-gPXcIEUtw7VlK8f/QcruNXm7q+T5hhvGu9tl63LsJPZ27exB6dtNwvh2HIi0v7JcXJ5emBxB+CJxwaLEdJfA+g==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/url-parser/-/url-parser-4.0.2.tgz", + "integrity": "sha512-Bm8n3j2ScqnT+kJaClSVCMeiSenK6jVAzZCNewsYWuZtnBehEz4r2qP0riZySZVfzB+03XZHJeqfmJDkeeSLiQ==", "dependencies": { - "@smithy/querystring-parser": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/querystring-parser": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -5002,13 +5005,13 @@ } }, "node_modules/@smithy/util-defaults-mode-browser": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-browser/-/util-defaults-mode-browser-4.0.7.tgz", - "integrity": "sha512-CZgDDrYHLv0RUElOsmZtAnp1pIjwDVCSuZWOPhIOBvG36RDfX1Q9+6lS61xBf+qqvHoqRjHxgINeQz47cYFC2Q==", + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-browser/-/util-defaults-mode-browser-4.0.8.tgz", + "integrity": "sha512-ZTypzBra+lI/LfTYZeop9UjoJhhGRTg3pxrNpfSTQLd3AJ37r2z4AXTKpq1rFXiiUIJsYyFgNJdjWRGP/cbBaQ==", "dependencies": { - "@smithy/property-provider": "^4.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", + "@smithy/property-provider": "^4.0.2", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", "bowser": "^2.11.0", "tslib": "^2.6.2" }, @@ -5017,16 +5020,16 @@ } }, "node_modules/@smithy/util-defaults-mode-node": { - "version": "4.0.7", - "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-node/-/util-defaults-mode-node-4.0.7.tgz", - "integrity": "sha512-79fQW3hnfCdrfIi1soPbK3zmooRFnLpSx3Vxi6nUlqaaQeC5dm8plt4OTNDNqEEEDkvKghZSaoti684dQFVrGQ==", + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/@smithy/util-defaults-mode-node/-/util-defaults-mode-node-4.0.8.tgz", + "integrity": "sha512-Rgk0Jc/UDfRTzVthye/k2dDsz5Xxs9LZaKCNPgJTRyoyBoeiNCnHsYGOyu1PKN+sDyPnJzMOz22JbwxzBp9NNA==", "dependencies": { - "@smithy/config-resolver": "^4.0.1", - "@smithy/credential-provider-imds": "^4.0.1", - "@smithy/node-config-provider": "^4.0.1", - "@smithy/property-provider": "^4.0.1", - "@smithy/smithy-client": "^4.1.6", - "@smithy/types": "^4.1.0", + "@smithy/config-resolver": "^4.1.0", + "@smithy/credential-provider-imds": "^4.0.2", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/property-provider": "^4.0.2", + "@smithy/smithy-client": "^4.2.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -5034,12 +5037,12 @@ } }, "node_modules/@smithy/util-endpoints": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@smithy/util-endpoints/-/util-endpoints-3.0.1.tgz", - "integrity": "sha512-zVdUENQpdtn9jbpD9SCFK4+aSiavRb9BxEtw9ZGUR1TYo6bBHbIoi7VkrFQ0/RwZlzx0wRBaRmPclj8iAoJCLA==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/@smithy/util-endpoints/-/util-endpoints-3.0.2.tgz", + "integrity": "sha512-6QSutU5ZyrpNbnd51zRTL7goojlcnuOB55+F9VBD+j8JpRY50IGamsjlycrmpn8PQkmJucFW8A0LSfXj7jjtLQ==", "dependencies": { - "@smithy/node-config-provider": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/node-config-provider": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -5058,11 +5061,11 @@ } }, "node_modules/@smithy/util-middleware": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-4.0.1.tgz", - "integrity": "sha512-HiLAvlcqhbzhuiOa0Lyct5IIlyIz0PQO5dnMlmQ/ubYM46dPInB+3yQGkfxsk6Q24Y0n3/JmcA1v5iEhmOF5mA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/util-middleware/-/util-middleware-4.0.2.tgz", + "integrity": "sha512-6GDamTGLuBQVAEuQ4yDQ+ti/YINf/MEmIegrEeg7DdB/sld8BX1lqt9RRuIcABOhAGTA50bRbPzErez7SlDtDQ==", "dependencies": { - "@smithy/types": "^4.1.0", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -5070,12 +5073,12 @@ } }, "node_modules/@smithy/util-retry": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/@smithy/util-retry/-/util-retry-4.0.1.tgz", - "integrity": "sha512-WmRHqNVwn3kI3rKk1LsKcVgPBG6iLTBGC1iYOV3GQegwJ3E8yjzHytPt26VNzOWr1qu0xE03nK0Ug8S7T7oufw==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@smithy/util-retry/-/util-retry-4.0.2.tgz", + "integrity": "sha512-Qryc+QG+7BCpvjloFLQrmlSd0RsVRHejRXd78jNO3+oREueCjwG1CCEH1vduw/ZkM1U9TztwIKVIi3+8MJScGg==", "dependencies": { - "@smithy/service-error-classification": "^4.0.1", - "@smithy/types": "^4.1.0", + "@smithy/service-error-classification": "^4.0.2", + "@smithy/types": "^4.2.0", "tslib": "^2.6.2" }, "engines": { @@ -5083,13 +5086,13 @@ } }, "node_modules/@smithy/util-stream": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-4.1.2.tgz", - "integrity": "sha512-44PKEqQ303d3rlQuiDpcCcu//hV8sn+u2JBo84dWCE0rvgeiVl0IlLMagbU++o0jCWhYCsHaAt9wZuZqNe05Hw==", + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/@smithy/util-stream/-/util-stream-4.2.0.tgz", + "integrity": "sha512-Vj1TtwWnuWqdgQI6YTUF5hQ/0jmFiOYsc51CSMgj7QfyO+RF4EnT2HNjoviNlOOmgzgvf3f5yno+EiC4vrnaWQ==", "dependencies": { - "@smithy/fetch-http-handler": "^5.0.1", - "@smithy/node-http-handler": "^4.0.3", - "@smithy/types": "^4.1.0", + "@smithy/fetch-http-handler": "^5.0.2", + "@smithy/node-http-handler": "^4.0.4", + "@smithy/types": "^4.2.0", "@smithy/util-base64": "^4.0.0", "@smithy/util-buffer-from": "^4.0.0", "@smithy/util-hex-encoding": "^4.0.0", @@ -8585,6 +8588,11 @@ "node": ">=8" } }, + "node_modules/filtrex": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/filtrex/-/filtrex-3.1.0.tgz", + "integrity": "sha512-mHzZ2wUISETF1OaEcNRiGz1ljuIV8c/C9td9qyAZ+wTwigkAk5RO9YrCxQKk5H9v7joDRFIBik9U5RTK9eXZ/A==" + }, "node_modules/find-replace": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/find-replace/-/find-replace-3.0.0.tgz", diff --git a/core/package.json b/core/package.json index d8995be86..6ca032c69 100644 --- a/core/package.json +++ b/core/package.json @@ -43,9 +43,9 @@ "typescript": "^5.6.3" }, "dependencies": { - "@aws-sdk/client-bedrock-runtime": "^3.758.0", - "@aws-sdk/client-sagemaker-runtime": "^3.758.0", - "@aws-sdk/credential-providers": "^3.758.0", + "@aws-sdk/client-bedrock-runtime": "^3.779.0", + "@aws-sdk/client-sagemaker-runtime": "^3.777.0", + "@aws-sdk/credential-providers": "^3.778.0", "@continuedev/config-types": "^1.0.13", "@continuedev/config-yaml": "^1.0.75", "@continuedev/fetch": "^1.0.4", @@ -66,6 +66,7 @@ "diff": "^7.0.0", "dotenv": "^16.4.5", "fastest-levenshtein": "^1.0.16", + "filtrex": "^3.1.0", "follow-redirects": "^1.15.5", "google-auth-library": "^9.14.2", "handlebars": "^4.7.8", diff --git a/core/tools/builtIn.ts b/core/tools/builtIn.ts index 268cbb9a8..fa76358c9 100644 --- a/core/tools/builtIn.ts +++ b/core/tools/builtIn.ts @@ -3,10 +3,14 @@ export enum BuiltInToolNames { ReadCurrentlyOpenFile = "builtin_read_currently_open_file", CreateNewFile = "builtin_create_new_file", RunTerminalCommand = "builtin_run_terminal_command", - ViewSubdirectory = "builtin_view_subdirectory", - ViewRepoMap = "builtin_view_repo_map", ExactSearch = "builtin_exact_search", SearchWeb = "builtin_search_web", ViewDiff = "builtin_view_diff", + LSTool = "builtin_ls", + + // excluded from allTools for now + ViewRepoMap = "builtin_view_repo_map", + ViewSubdirectory = "builtin_view_subdirectory", } + export const BUILT_IN_GROUP_NAME = "Built-In"; diff --git a/core/tools/callTool.ts b/core/tools/callTool.ts index 8d4b1f1b3..25c56507c 100644 --- a/core/tools/callTool.ts +++ b/core/tools/callTool.ts @@ -5,13 +5,12 @@ import { BuiltInToolNames } from "./builtIn"; import { createNewFileImpl } from "./implementations/createNewFile"; import { exactSearchImpl } from "./implementations/exactSearch"; +import { lsToolImpl } from "./implementations/lsTool"; import { readCurrentlyOpenFileImpl } from "./implementations/readCurrentlyOpenFile"; import { readFileImpl } from "./implementations/readFile"; import { runTerminalCommandImpl } from "./implementations/runTerminalCommand"; import { searchWebImpl } from "./implementations/searchWeb"; import { viewDiffImpl } from "./implementations/viewDiff"; -import { viewRepoMapImpl } from "./implementations/viewRepoMap"; -import { viewSubdirectoryImpl } from "./implementations/viewSubdirectory"; async function callHttpTool( url: string, @@ -149,12 +148,14 @@ export async function callTool( return await searchWebImpl(args, extras); case BuiltInToolNames.ViewDiff: return await viewDiffImpl(args, extras); - case BuiltInToolNames.ViewRepoMap: - return await viewRepoMapImpl(args, extras); - case BuiltInToolNames.ViewSubdirectory: - return await viewSubdirectoryImpl(args, extras); + case BuiltInToolNames.LSTool: + return await lsToolImpl(args, extras); case BuiltInToolNames.ReadCurrentlyOpenFile: return await readCurrentlyOpenFileImpl(args, extras); + // case BuiltInToolNames.ViewRepoMap: + // return await viewRepoMapImpl(args, extras); + // case BuiltInToolNames.ViewSubdirectory: + // return await viewSubdirectoryImpl(args, extras); default: return await callToolFromUri(uri, args, extras); } diff --git a/core/tools/definitions/lsTool.ts b/core/tools/definitions/lsTool.ts new file mode 100644 index 000000000..6b6e96498 --- /dev/null +++ b/core/tools/definitions/lsTool.ts @@ -0,0 +1,33 @@ +import { Tool } from "../.."; + +import { BUILT_IN_GROUP_NAME, BuiltInToolNames } from "../builtIn"; + +export const lsTool: Tool = { + type: "function", + displayTitle: "LS Tool", + wouldLikeTo: "list files and folders in {{{ dirPath }}}", + isCurrently: "listing files and folders in {{{ dirPath }}}", + hasAlready: "listed files and folders in {{{ dirPath }}}", + readonly: true, + group: BUILT_IN_GROUP_NAME, + function: { + name: BuiltInToolNames.LSTool, + description: "List files and folders in a given directory", + parameters: { + type: "object", + required: ["dirPath", "recursive"], + properties: { + dirPath: { + type: "string", + description: + "The directory path relative to the root of the project. Always use forward slash paths like '/'. rather than e.g. '.'", + }, + recursive: { + type: "boolean", + description: + "If true, lists files and folders recursively. To prevent unexpected large results, use this sparingly", + }, + }, + }, + }, +}; diff --git a/core/tools/implementations/lsTool.ts b/core/tools/implementations/lsTool.ts new file mode 100644 index 000000000..4a7f8bcb5 --- /dev/null +++ b/core/tools/implementations/lsTool.ts @@ -0,0 +1,31 @@ +import { ToolImpl } from "."; +import { walkDir } from "../../indexing/walkDir"; +import { resolveRelativePathInDir } from "../../util/ideUtils"; + +export const lsToolImpl: ToolImpl = async (args, extras) => { + const uri = await resolveRelativePathInDir(args.dirPath, extras.ide); + if (!uri) { + throw new Error( + `Directory ${args.dirPath} not found. Make sure to use forward-slash paths. Do not use e.g. "."`, + ); + } + + const entries = await walkDir(uri, extras.ide, { + returnRelativeUrisPaths: true, + include: "both", + recursive: args.recursive ?? false, + }); + + const content = + entries.length > 0 + ? entries.join("\n") + : `No files/folders found in ${args.dirPath}`; + + return [ + { + name: "File/folder list", + description: `Files/folders in ${args.dirPath}`, + content, + }, + ]; +}; diff --git a/core/tools/index.ts b/core/tools/index.ts index c27860a6f..eea4ee79b 100644 --- a/core/tools/index.ts +++ b/core/tools/index.ts @@ -1,21 +1,24 @@ import { createNewFileTool } from "./definitions/createNewFile"; import { exactSearchTool } from "./definitions/exactSearch"; +import { lsTool } from "./definitions/lsTool"; import { readCurrentlyOpenFileTool } from "./definitions/readCurrentlyOpenFile"; import { readFileTool } from "./definitions/readFile"; import { runTerminalCommandTool } from "./definitions/runTerminalCommand"; import { searchWebTool } from "./definitions/searchWeb"; import { viewDiffTool } from "./definitions/viewDiff"; -import { viewRepoMapTool } from "./definitions/viewRepoMap"; -import { viewSubdirectoryTool } from "./definitions/viewSubdirectory"; export const allTools = [ readFileTool, createNewFileTool, runTerminalCommandTool, - viewSubdirectoryTool, - viewRepoMapTool, + exactSearchTool, searchWebTool, viewDiffTool, readCurrentlyOpenFileTool, + + lsTool, + // replacing with ls tool for now + // viewSubdirectoryTool, + // viewRepoMapTool, ]; diff --git a/docs/docs/customize/model-providers/top-level/openai.mdx b/docs/docs/customize/model-providers/top-level/openai.mdx index 8ed706213..7e3870720 100644 --- a/docs/docs/customize/model-providers/top-level/openai.mdx +++ b/docs/docs/customize/model-providers/top-level/openai.mdx @@ -21,7 +21,7 @@ We recommend configuring **GPT-4o** as your chat model. - name: GPT-4o provider: openai model: gpt-4o - apiKey: + apiKey: ``` @@ -32,7 +32,7 @@ We recommend configuring **GPT-4o** as your chat model. "title": "GPT-4o", "provider": "openai", "model": "gpt-4o", - "apiKey": "" + "apiKey": "" } ] } @@ -57,7 +57,7 @@ We recommend configuring **text-embedding-3-large** as your embeddings model. - name: OpenAI Embeddings provider: openai model: text-embedding-3-large - apiKey: + apiKey: roles: - embed ``` @@ -68,7 +68,7 @@ We recommend configuring **text-embedding-3-large** as your embeddings model. "embeddingsProvider": { "provider": "openai", "model": "text-embedding-3-large", - "apiKey": "" + "apiKey": "" } } ``` diff --git a/docs/docs/customize/overview.md b/docs/docs/customize/overview.md index 15ed68ec9..3cd6f2615 100644 --- a/docs/docs/customize/overview.md +++ b/docs/docs/customize/overview.md @@ -20,5 +20,5 @@ You can easily access your assistant configuration from the Continue Chat sideba ![configure an assistant](/img/configure-continue.png) -- See [Editing Hub Assistants](../hub/assistants/edit-an-assistant.md) for more details on managing your hug assistant +- See [Editing Hub Assistants](../hub/assistants/edit-an-assistant.md) for more details on managing your hub assistant - See the [Config Deep Dive](./deep-dives/configuration.md) for more details on configuring local assistants. diff --git a/docs/docs/reference.md b/docs/docs/reference.md index 69f301366..735c89be3 100644 --- a/docs/docs/reference.md +++ b/docs/docs/reference.md @@ -227,7 +227,7 @@ More information about usage/params for each context provider can be found [here ```yaml title="config.yaml" context: - - provider: files + - provider: file - provider: code - provider: codebase params: diff --git a/docs/package-lock.json b/docs/package-lock.json index abd1275c6..f9c2ca21c 100644 --- a/docs/package-lock.json +++ b/docs/package-lock.json @@ -9617,9 +9617,10 @@ "license": "ISC" }, "node_modules/image-size": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/image-size/-/image-size-1.2.0.tgz", - "integrity": "sha512-4S8fwbO6w3GeCVN6OPtA9I5IGKkcDMPcKndtUlpJuCwu7JLjtj7JZpwqLuyY2nrmQT3AWsCJLSKPsc2mPBSl3w==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/image-size/-/image-size-1.2.1.tgz", + "integrity": "sha512-rH+46sQJ2dlwfjfhCyNx5thzrv+dtmBIhPHk0zgRUukHzZ/kRueTJXoYYsclBaKcSMBWuGbOFXtioLpzTb5euw==", + "license": "MIT", "dependencies": { "queue": "6.0.2" }, diff --git a/extensions/intellij/gradle.properties b/extensions/intellij/gradle.properties index 957c112f3..506f6bf62 100644 --- a/extensions/intellij/gradle.properties +++ b/extensions/intellij/gradle.properties @@ -3,7 +3,7 @@ pluginGroup=com.github.continuedev.continueintellijextension pluginName=continue-intellij-extension pluginRepositoryUrl=https://github.com/continuedev/continue # SemVer format -> https://semver.org -pluginVersion=1.0.9 +pluginVersion=1.0.11 # Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html pluginSinceBuild=223 # IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html#configuration-intellij-extension diff --git a/extensions/vscode/config_schema.json b/extensions/vscode/config_schema.json index b8ae1d407..801bba5ea 100644 --- a/extensions/vscode/config_schema.json +++ b/extensions/vscode/config_schema.json @@ -956,7 +956,10 @@ "gemini-2.0-flash", "gemini-2.0-flash-thinking-exp-01-21", "gemini-2.0-pro-exp-02-05", - "gemini-2.0-flash-lite-preview-02-05" + "gemini-2.0-flash-lite-preview-02-05", + "gemini-2.0-flash-lite", + "gemini-2.0-flash-exp-image-generation", + "gemini-2.5-pro-exp-03-25" ] } } @@ -2886,7 +2889,8 @@ "watsonx", "llm", "free-trial", - "huggingface-tei" + "huggingface-tei", + "siliconflow" ] }, "params": { @@ -3053,6 +3057,40 @@ "required": ["truncation_direction"] } } + }, + { + "if": { + "properties": { + "name": { + "enum": ["siliconflow"] + } + }, + "required": ["name"] + }, + "then": { + "properties": { + "params": { + "type": "object", + "properties": { + "model": { + "enum": [ + "BAAI/bge-reranker-v2-m3", + "netease-youdao/bce-reranker-base_v1", + "Pro/BAAI/bge-reranker-v2-m3" + ], + "default": "BAAI/bge-reranker-v2-m3" + }, + "apiBase": { + "type": "string" + }, + "apiKey": { + "type": "string" + } + }, + "required": ["apiKey"] + } + } + } } ] }, diff --git a/extensions/vscode/package-lock.json b/extensions/vscode/package-lock.json index 3b3f05ad0..bef92c30c 100644 --- a/extensions/vscode/package-lock.json +++ b/extensions/vscode/package-lock.json @@ -102,11 +102,11 @@ "version": "1.1.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/client-bedrock-runtime": "^3.758.0", - "@aws-sdk/client-sagemaker-runtime": "^3.758.0", - "@aws-sdk/credential-providers": "^3.758.0", + "@aws-sdk/client-bedrock-runtime": "^3.779.0", + "@aws-sdk/client-sagemaker-runtime": "^3.777.0", + "@aws-sdk/credential-providers": "^3.778.0", "@continuedev/config-types": "^1.0.13", - "@continuedev/config-yaml": "^1.0.67", + "@continuedev/config-yaml": "^1.0.71", "@continuedev/fetch": "^1.0.4", "@continuedev/llm-info": "^1.0.8", "@continuedev/openai-adapters": "^1.0.18", @@ -125,6 +125,7 @@ "diff": "^7.0.0", "dotenv": "^16.4.5", "fastest-levenshtein": "^1.0.16", + "filtrex": "^3.1.0", "follow-redirects": "^1.15.5", "google-auth-library": "^9.14.2", "handlebars": "^4.7.8", @@ -12293,9 +12294,10 @@ } }, "node_modules/tar-fs": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.1.tgz", - "integrity": "sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==", + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.2.tgz", + "integrity": "sha512-EsaAXwxmx8UB7FRKqeozqEPop69DXcmYwTQwXvyAPF352HJsPdkVhvTaDPYqfNgruveJIJy3TA2l+2zj8LJIJA==", + "license": "MIT", "dependencies": { "chownr": "^1.1.1", "mkdirp-classic": "^0.5.2", @@ -12392,10 +12394,11 @@ } }, "node_modules/targz/node_modules/tar-fs": { - "version": "1.16.3", - "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-1.16.3.tgz", - "integrity": "sha512-NvCeXpYx7OsmOh8zIOP/ebG55zZmxLE0etfWRbWok+q2Qo8x/vOR/IJT1taADXPe+jsiu9axDb3X4B+iIgNlKw==", + "version": "1.16.4", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-1.16.4.tgz", + "integrity": "sha512-u3XczWoYAIVXe5GOKK6+VeWaHjtc47W7hyuTo3+4cNakcCcuDmlkYiiHEsECwTkcI3h1VUgtwBQ54+RvY6cM4w==", "dev": true, + "license": "MIT", "dependencies": { "chownr": "^1.0.1", "mkdirp": "^0.5.1", diff --git a/extensions/vscode/package.json b/extensions/vscode/package.json index 5dec30f35..15599a1c0 100644 --- a/extensions/vscode/package.json +++ b/extensions/vscode/package.json @@ -2,7 +2,7 @@ "name": "continue", "icon": "media/icon.png", "author": "Continue Dev, Inc", - "version": "1.1.18", + "version": "1.1.20", "repository": { "type": "git", "url": "https://github.com/continuedev/continue" diff --git a/extensions/vscode/src/commands.ts b/extensions/vscode/src/commands.ts index 6a1e35424..836360e51 100644 --- a/extensions/vscode/src/commands.ts +++ b/extensions/vscode/src/commands.ts @@ -634,16 +634,6 @@ const getCommandsMap: ( editDecorationManager.clear(); void sidebar.webviewProtocol?.request("exitEditMode", undefined); }, - // "continue.quickEdit": async (args: QuickEditShowParams) => { - // let linesOfCode = undefined; - // if (args.range) { - // linesOfCode = args.range.end.line - args.range.start.line; - // } - // captureCommandTelemetry("quickEdit", { - // linesOfCode, - // }); - // quickEdit.show(args); - // }, "continue.writeCommentsForCode": async () => { captureCommandTelemetry("writeCommentsForCode"); @@ -708,37 +698,6 @@ const getCommandsMap: ( vscode.commands.executeCommand("continue.continueGUIView.focus"); sidebar.webviewProtocol?.request("addModel", undefined); }, - "continue.sendMainUserInput": (text: string) => { - sidebar.webviewProtocol?.request("userInput", { - input: text, - }); - }, - "continue.selectRange": (startLine: number, endLine: number) => { - if (!vscode.window.activeTextEditor) { - return; - } - vscode.window.activeTextEditor.selection = new vscode.Selection( - startLine, - 0, - endLine, - 0, - ); - }, - "continue.foldAndUnfold": ( - foldSelectionLines: number[], - unfoldSelectionLines: number[], - ) => { - vscode.commands.executeCommand("editor.unfold", { - selectionLines: unfoldSelectionLines, - }); - vscode.commands.executeCommand("editor.fold", { - selectionLines: foldSelectionLines, - }); - }, - "continue.sendToTerminal": (text: string) => { - captureCommandTelemetry("sendToTerminal"); - ide.runCommand(text); - }, "continue.newSession": () => { sidebar.webviewProtocol?.request("newSession", undefined); }, diff --git a/extensions/vscode/tsconfig.json b/extensions/vscode/tsconfig.json index b35899669..a7a58f894 100644 --- a/extensions/vscode/tsconfig.json +++ b/extensions/vscode/tsconfig.json @@ -9,6 +9,7 @@ "strict": true, "esModuleInterop": true, "resolveJsonModule": true, + "skipLibCheck": true, "types": ["mocha"] // This solves conflict between jest and mocha: https://github.com/cypress-io/cypress/issues/7435#issuecomment-631695007 }, "include": ["src/**/*", "../../core/**/*.ts", "../../core/**/*.d.ts"], diff --git a/gui/package-lock.json b/gui/package-lock.json index a1a71af32..2d9b4a2fa 100644 --- a/gui/package-lock.json +++ b/gui/package-lock.json @@ -107,9 +107,9 @@ "version": "1.1.0", "license": "Apache-2.0", "dependencies": { - "@aws-sdk/client-bedrock-runtime": "^3.758.0", - "@aws-sdk/client-sagemaker-runtime": "^3.758.0", - "@aws-sdk/credential-providers": "^3.758.0", + "@aws-sdk/client-bedrock-runtime": "^3.779.0", + "@aws-sdk/client-sagemaker-runtime": "^3.777.0", + "@aws-sdk/credential-providers": "^3.778.0", "@continuedev/config-types": "^1.0.13", "@continuedev/config-yaml": "1.0.67", "@continuedev/fetch": "^1.0.4", @@ -130,6 +130,7 @@ "diff": "^7.0.0", "dotenv": "^16.4.5", "fastest-levenshtein": "^1.0.16", + "filtrex": "^3.1.0", "follow-redirects": "^1.15.5", "google-auth-library": "^9.14.2", "handlebars": "^4.7.8", diff --git a/gui/public/logos/docker.png b/gui/public/logos/docker.png new file mode 100644 index 000000000..600476cfe Binary files /dev/null and b/gui/public/logos/docker.png differ diff --git a/gui/public/logos/inception.png b/gui/public/logos/inception.png new file mode 100644 index 000000000..4ef5ad6a0 Binary files /dev/null and b/gui/public/logos/inception.png differ diff --git a/gui/src/App.tsx b/gui/src/App.tsx index deb1e376f..8f7725db9 100644 --- a/gui/src/App.tsx +++ b/gui/src/App.tsx @@ -3,7 +3,6 @@ import Layout from "./components/Layout"; import { SubmenuContextProvidersProvider } from "./context/SubmenuContextProviders"; import { VscThemeProvider } from "./context/VscTheme"; import useSetup from "./hooks/useSetup"; -import { AddNewModel, ConfigureProvider } from "./pages/AddNewModel"; import ConfigPage from "./pages/config"; import ConfigErrorPage from "./pages/config-error"; import ErrorPage from "./pages/error"; @@ -34,14 +33,6 @@ const router = createMemoryRouter([ path: "/stats", element: , }, - { - path: "/addModel", - element: , - }, - { - path: "/addModel/provider/:providerName", - element: , - }, { path: ROUTES.CONFIG_ERROR, element: , diff --git a/gui/src/components/Layout.tsx b/gui/src/components/Layout.tsx index d2d91f1ea..5b70f2e62 100644 --- a/gui/src/components/Layout.tsx +++ b/gui/src/components/Layout.tsx @@ -6,7 +6,6 @@ import { AuthProvider } from "../context/Auth"; import { LocalStorageProvider } from "../context/LocalStorage"; import { useWebviewListener } from "../hooks/useWebviewListener"; import { useAppDispatch, useAppSelector } from "../redux/hooks"; -import { selectUseHub } from "../redux/selectors"; import { focusEdit, setEditStatus } from "../redux/slices/editModeState"; import { addCodeToEdit, @@ -250,21 +249,6 @@ const Layout = () => { } }, [location]); - const useHub = useAppSelector(selectUseHub); - - // Existing users that have already seen the onboarding card - // should be shown an intro card for hub.continue.dev - // useEffect(() => { - // if (useHub !== true) { - // return; - // } - // const seenHubIntro = getLocalStorage("seenHubIntro"); - // if (!onboardingCard.show && !seenHubIntro) { - // onboardingCard.setActiveTab("ExistingUserHubIntro"); - // } - // setLocalStorage("seenHubIntro", true); - // }, [onboardingCard.show, useHub]); - return ( diff --git a/gui/src/components/mainInput/ContinueInputBox.tsx b/gui/src/components/mainInput/ContinueInputBox.tsx index 2b91b707b..cf2b4cf46 100644 --- a/gui/src/components/mainInput/ContinueInputBox.tsx +++ b/gui/src/components/mainInput/ContinueInputBox.tsx @@ -1,6 +1,6 @@ import { Editor, JSONContent } from "@tiptap/react"; import { ContextItemWithId, InputModifiers } from "core"; -import { useMemo, useState } from "react"; +import { useMemo } from "react"; import styled, { keyframes } from "styled-components"; import { defaultBorderRadius, vscBackground } from ".."; import { useAppSelector } from "../../redux/hooks"; @@ -113,12 +113,10 @@ function ContinueInputBox(props: ContinueInputBoxProps) { } : {}; - const [lumpOpen, setLumpOpen] = useState(true); - return (
- {props.isMainInput && } + {props.isMainInput && } diff --git a/gui/src/components/mainInput/InputToolbar.tsx b/gui/src/components/mainInput/InputToolbar.tsx index de2c410f7..3d0a38cec 100644 --- a/gui/src/components/mainInput/InputToolbar.tsx +++ b/gui/src/components/mainInput/InputToolbar.tsx @@ -31,7 +31,7 @@ import { ToolTip } from "../gui/Tooltip"; import ModelSelect from "../modelSelection/ModelSelect"; import ModeSelect from "../modelSelection/ModeSelect"; import { useFontSize } from "../ui/font"; -import HoverItem from "./InputToolbar/bottom/HoverItem"; +import HoverItem from "./InputToolbar/HoverItem"; const StyledDiv = styled.div<{ isHidden?: boolean }>` padding-top: 4px; @@ -87,8 +87,6 @@ interface InputToolbarProps { toolbarOptions?: ToolbarOptions; disabled?: boolean; isMainInput?: boolean; - lumpOpen: boolean; - setLumpOpen: (open: boolean) => void; } function InputToolbar(props: InputToolbarProps) { diff --git a/gui/src/components/mainInput/InputToolbar/bottom/HoverItem.tsx b/gui/src/components/mainInput/InputToolbar/HoverItem.tsx similarity index 100% rename from gui/src/components/mainInput/InputToolbar/bottom/HoverItem.tsx rename to gui/src/components/mainInput/InputToolbar/HoverItem.tsx diff --git a/gui/src/components/mainInput/InputToolbar/top/TopInputToolbar.tsx b/gui/src/components/mainInput/InputToolbar/top/TopInputToolbar.tsx deleted file mode 100644 index f82ea9860..000000000 --- a/gui/src/components/mainInput/InputToolbar/top/TopInputToolbar.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { EllipsisHorizontalIcon } from "@heroicons/react/24/outline"; -import { ToolbarOptions } from "../../InputToolbar"; -import HoverItem from "../bottom/HoverItem"; - -interface TopInputToolbarProps { - toolbarOptions?: ToolbarOptions; - onAddContextItem?: () => void; - lumpOpen: boolean; - setLumpOpen: (open: boolean) => void; -} -export function TopInputToolbar(props: TopInputToolbarProps) { - return ( -
- props.setLumpOpen(!props.lumpOpen)} - className="ml-auto" - > - - -
- ); -} diff --git a/gui/src/components/mainInput/Lump/BlockSettingsTopToolbar.tsx b/gui/src/components/mainInput/Lump/BlockSettingsTopToolbar.tsx index edde8cd5d..ebef0251b 100644 --- a/gui/src/components/mainInput/Lump/BlockSettingsTopToolbar.tsx +++ b/gui/src/components/mainInput/Lump/BlockSettingsTopToolbar.tsx @@ -13,7 +13,7 @@ import { useAppDispatch, useAppSelector } from "../../../redux/hooks"; import { toggleBlockSettingsToolbar } from "../../../redux/slices/uiSlice"; import { fontSize } from "../../../util"; import AssistantSelect from "../../modelSelection/platform/AssistantSelect"; -import HoverItem from "../InputToolbar/bottom/HoverItem"; +import HoverItem from "../InputToolbar/HoverItem"; interface BlockSettingsToolbarIcon { tooltip: string; @@ -129,7 +129,7 @@ export function BlockSettingsTopToolbar(props: BlockSettingsTopToolbarProps) {
-
+
diff --git a/gui/src/components/mainInput/Lump/LumpToolbar.tsx b/gui/src/components/mainInput/Lump/LumpToolbar.tsx index e93746726..6abe4525e 100644 --- a/gui/src/components/mainInput/Lump/LumpToolbar.tsx +++ b/gui/src/components/mainInput/Lump/LumpToolbar.tsx @@ -1,5 +1,6 @@ import { useContext } from "react"; import styled from "styled-components"; +import { AnimatedEllipsis } from "../.."; import { IdeMessengerContext } from "../../../context/IdeMessenger"; import { useAppDispatch, useAppSelector } from "../../../redux/hooks"; import { cancelStream } from "../../../redux/thunks/cancelStream"; @@ -8,7 +9,8 @@ import { BlockSettingsTopToolbar } from "./BlockSettingsTopToolbar"; const Container = styled.div` display: flex; - justify-content: flex-end; + justify-content: space-between; + align-items: center; width: 100%; `; @@ -24,6 +26,15 @@ interface TopToolbarProps { setSelectedSection: (value: string | null) => void; } +function GeneratingIndicator() { + return ( +
+ Generating + +
+ ); +} + export function LumpToolbar(props: TopToolbarProps) { const dispatch = useAppDispatch(); const ideMessenger = useContext(IdeMessengerContext); @@ -33,6 +44,7 @@ export function LumpToolbar(props: TopToolbarProps) { if (ttsActive) { return ( + { @@ -48,6 +60,7 @@ export function LumpToolbar(props: TopToolbarProps) { if (isStreaming) { return ( + { diff --git a/gui/src/components/mainInput/Lump/index.tsx b/gui/src/components/mainInput/Lump/index.tsx index a642136b4..57276ad56 100644 --- a/gui/src/components/mainInput/Lump/index.tsx +++ b/gui/src/components/mainInput/Lump/index.tsx @@ -9,12 +9,7 @@ import { useAppSelector } from "../../../redux/hooks"; import { LumpToolbar } from "./LumpToolbar"; import { SelectedSection } from "./sections/SelectedSection"; -interface LumpProps { - open: boolean; - setOpen: (open: boolean) => void; -} - -const LumpDiv = styled.div<{ open: boolean }>` +const LumpDiv = styled.div` background-color: ${vscInputBackground}; margin-left: 4px; margin-right: 4px; @@ -35,33 +30,50 @@ const ContentDiv = styled.div<{ hasSection: boolean; isVisible: boolean }>` overflow-y: auto; `; -export function Lump(props: LumpProps) { - const { open, setOpen } = props; +export function Lump() { const [selectedSection, setSelectedSection] = useState(null); const [displayedSection, setDisplayedSection] = useState(null); const [isVisible, setIsVisible] = useState(false); const isStreaming = useAppSelector((state) => state.session.isStreaming); + useEffect(() => { + if (!selectedSection) { + return; + } + const handleKeyDown = (event: KeyboardEvent) => { + if (event.key === "Escape") { + setSelectedSection(null); + } + }; + document.addEventListener("keydown", handleKeyDown); + return () => { + document.removeEventListener("keydown", handleKeyDown); + }; + }, [selectedSection]); + + useEffect(() => { + if (isStreaming) { + setSelectedSection(null); + } + }, [isStreaming]); + useEffect(() => { if (selectedSection) { setDisplayedSection(selectedSection); setIsVisible(true); } else { setIsVisible(false); - // Delay clearing the displayed section until after the fade-out const timeout = setTimeout(() => { setDisplayedSection(null); - }, 300); // Match the transition duration - return () => clearTimeout(timeout); + }, 300); + return () => { + clearTimeout(timeout); + }; } }, [selectedSection]); - if (!open) { - return null; - } - return ( - +
- {!isStreaming && ( - - )} +
diff --git a/gui/src/components/mainInput/Lump/sections/RulesSection.tsx b/gui/src/components/mainInput/Lump/sections/RulesSection.tsx index 4cb7b0051..6bb3d1637 100644 --- a/gui/src/components/mainInput/Lump/sections/RulesSection.tsx +++ b/gui/src/components/mainInput/Lump/sections/RulesSection.tsx @@ -1,4 +1,4 @@ -import { parseConfigYaml } from "@continuedev/config-yaml"; +import { parseConfigYaml, Rule } from "@continuedev/config-yaml"; import { ArrowsPointingOutIcon, PencilIcon } from "@heroicons/react/24/outline"; import { useContext, useMemo } from "react"; import { useSelector } from "react-redux"; @@ -17,7 +17,7 @@ import { ExploreBlocksButton } from "./ExploreBlocksButton"; interface RuleCardProps { index: number; - rule: string; + rule: Rule; onClick: () => void; title: string; } @@ -31,12 +31,32 @@ const RuleCard: React.FC = ({ index, rule, onClick, title }) => { setDialogMessage(

{title}

-
{rule}
+
+            {/** TODO: Render the rule in a more readable way */}
+            {JSON.stringify(rule)}
+          
, ), ); } + const renderRuleContent = () => { + if (typeof rule === "string") { + return
{rule}
; + } + + if (rule.rule) { + return ( +
+
{rule.rule}
+ {rule.if &&
if: {rule.if}
} +
+ ); + } + + return
{JSON.stringify(rule)}
; + }; + return (
= ({ index, rule, onClick, title }) => { }} className="line-clamp-3 text-gray-400" > - {rule} + {renderRuleContent()}
@@ -137,27 +157,25 @@ export function RulesSection() { ); } - if (!rule.ruleFromYaml?.uses) { - return null; + if ("uses" in rule.ruleFromYaml) { + const ruleSlug = rule.ruleFromYaml?.uses; + + return ( + openUrl(`${ruleSlug}/new-version`)} + title={ruleSlug} + /> + ); } - const ruleSlug = rule.ruleFromYaml?.uses; - - return ( - openUrl(`${ruleSlug}/new-version`)} - title={ruleSlug} - /> - ); + // TODO: Handle rules as object with 'if' + return null; })}
); } -function useTypedDispatch() { - throw new Error("Function not implemented."); -} diff --git a/gui/src/components/mainInput/Lump/sections/SelectedSection.tsx b/gui/src/components/mainInput/Lump/sections/SelectedSection.tsx index 28dc37c28..4b133e77d 100644 --- a/gui/src/components/mainInput/Lump/sections/SelectedSection.tsx +++ b/gui/src/components/mainInput/Lump/sections/SelectedSection.tsx @@ -4,7 +4,7 @@ import { MCPSection } from "./MCPSection"; import { ModelsSection } from "./ModelsSection"; import { PromptsSection } from "./PromptsSection"; import { RulesSection } from "./RulesSection"; -import { ToolsSection } from "./ToolsSection"; +import { ToolPoliciesSection } from "./tool-policies/ToolPoliciesSection"; interface SelectedSectionProps { selectedSection: string | null; @@ -23,7 +23,7 @@ export function SelectedSection(props: SelectedSectionProps) { case "context": return ; case "tools": - return ; + return ; case "mcp": return ; default: diff --git a/gui/src/components/mainInput/Lump/sections/ToolsSection.tsx b/gui/src/components/mainInput/Lump/sections/ToolsSection.tsx deleted file mode 100644 index af03f7220..000000000 --- a/gui/src/components/mainInput/Lump/sections/ToolsSection.tsx +++ /dev/null @@ -1,7 +0,0 @@ -import { ToolPermissionsDialog } from "../../InputToolbar/bottom/ToolPermissionsDialog"; - -interface ToolsSectionProps {} - -export function ToolsSection({}: ToolsSectionProps) { - return ; -} diff --git a/gui/src/components/mainInput/InputToolbar/bottom/ToolPermissionsDialog.tsx b/gui/src/components/mainInput/Lump/sections/tool-policies/ToolPoliciesSection.tsx similarity index 85% rename from gui/src/components/mainInput/InputToolbar/bottom/ToolPermissionsDialog.tsx rename to gui/src/components/mainInput/Lump/sections/tool-policies/ToolPoliciesSection.tsx index 5ab7bfa45..7ad61abd0 100644 --- a/gui/src/components/mainInput/InputToolbar/bottom/ToolPermissionsDialog.tsx +++ b/gui/src/components/mainInput/Lump/sections/tool-policies/ToolPoliciesSection.tsx @@ -1,12 +1,12 @@ import { Tool } from "core"; import { useMemo } from "react"; -import { useAppDispatch, useAppSelector } from "../../../../redux/hooks"; -import { toggleToolGroupSetting } from "../../../../redux/slices/uiSlice"; -import { fontSize } from "../../../../util"; -import ToggleSwitch from "../../../gui/Switch"; -import ToolDropdownItem from "./ToolDropdownItem"; +import { useAppDispatch, useAppSelector } from "../../../../../redux/hooks"; +import { toggleToolGroupSetting } from "../../../../../redux/slices/uiSlice"; +import { fontSize } from "../../../../../util"; +import ToggleSwitch from "../../../../gui/Switch"; +import ToolPolicyItem from "./ToolPolicyItem"; -export const ToolPermissionsDialog = () => { +export const ToolPoliciesSection = () => { const availableTools = useAppSelector((state) => state.config.config.tools); const toolGroupSettings = useAppSelector( (store) => store.ui.toolGroupSettings, @@ -61,7 +61,7 @@ export const ToolPermissionsDialog = () => {
{tools.map((tool) => ( - state.ui.toolSettings[props.tool.function.name], ); useEffect(() => { - if (!settings) { + if (!policy) { dispatch(addTool(props.tool)); } - }, [props.tool.function.name, settings]); + }, [props.tool.function.name, policy]); - if (!settings) { + if (!policy) { return null; } @@ -81,13 +84,13 @@ function ToolDropdownItem(props: ToolDropdownItemProps) { Excluded ) : (
- {(settings === "allowedWithPermission" || settings === undefined) && ( + {(policy === "allowedWithPermission" || policy === undefined) && ( Ask First )} - {settings === "allowedWithoutPermission" && ( + {policy === "allowedWithoutPermission" && ( Automatic )} - {settings === "disabled" && ( + {policy === "disabled" && ( Excluded )}
@@ -96,4 +99,4 @@ function ToolDropdownItem(props: ToolDropdownItemProps) { ); } -export default ToolDropdownItem; +export default ToolPolicyItem; diff --git a/gui/src/components/mainInput/tiptap/TipTapEditor.tsx b/gui/src/components/mainInput/tiptap/TipTapEditor.tsx index 47323e4ee..7a287660d 100644 --- a/gui/src/components/mainInput/tiptap/TipTapEditor.tsx +++ b/gui/src/components/mainInput/tiptap/TipTapEditor.tsx @@ -32,8 +32,6 @@ export interface TipTapEditorProps { ) => void; editorState?: JSONContent; toolbarOptions?: ToolbarOptions; - lumpOpen: boolean; - setLumpOpen: (open: boolean) => void; placeholder?: string; historyKey: string; inputId: string; @@ -262,8 +260,6 @@ function TipTapEditor(props: TipTapEditorProps) { activeKey={activeKey} hidden={shouldHideToolbar && !props.isMainInput} onAddContextItem={() => insertCharacterWithWhitespace("@")} - lumpOpen={props.lumpOpen} - setLumpOpen={props.setLumpOpen} onEnter={onEnterRef.current} onImageFileSelected={(file) => { handleImageFile(ideMessenger, file).then((result) => { diff --git a/gui/src/components/modelSelection/platform/AssistantSelect.tsx b/gui/src/components/modelSelection/platform/AssistantSelect.tsx index 151277c9a..36495145d 100644 --- a/gui/src/components/modelSelection/platform/AssistantSelect.tsx +++ b/gui/src/components/modelSelection/platform/AssistantSelect.tsx @@ -1,12 +1,13 @@ import { ArrowTopRightOnSquareIcon, BuildingOfficeIcon, + CheckIcon, ChevronDownIcon, Cog6ToothIcon, ExclamationTriangleIcon, PlusIcon, } from "@heroicons/react/24/outline"; -import { useContext, useEffect, useMemo, useRef, useState } from "react"; +import { useContext, useEffect, useMemo, useRef } from "react"; import { useAuth } from "../../../context/Auth"; import { IdeMessengerContext } from "../../../context/IdeMessenger"; import { cycleProfile, selectProfileThunk } from "../../../redux"; @@ -35,14 +36,16 @@ import AssistantIcon from "./AssistantIcon"; interface AssistantSelectOptionProps { profile: ProfileDescription; + selected: boolean; onClick: () => void; } + const AssistantSelectOption = ({ profile, + selected, onClick, }: AssistantSelectOptionProps) => { const navigate = useNavigate(); - const [hovered, setHovered] = useState(false); const hasFatalErrors = useMemo(() => { return !!profile.errors?.find((error) => error.fatal); @@ -72,8 +75,6 @@ const AssistantSelectOption = ({ return ( setHovered(true)} - onMouseLeave={() => setHovered(false)} value={profile.id} disabled={hasFatalErrors} onClick={!hasFatalErrors ? handleOptionClick : undefined} @@ -81,20 +82,22 @@ const AssistantSelectOption = ({ >
-
+
- {profile.title} + + {profile.title} +
-
+
+
{selected ? : null}
{!profile.errors?.length ? ( isLocalProfile(profile) ? ( { e.stopPropagation(); e.preventDefault(); @@ -103,9 +106,6 @@ const AssistantSelectOption = ({ /> ) : ( { e.stopPropagation(); @@ -215,7 +215,7 @@ export default function AssistantSelect() { return ( -
+
); })} diff --git a/gui/src/components/ui/Listbox.tsx b/gui/src/components/ui/Listbox.tsx index 5bb235563..ed2e077bf 100644 --- a/gui/src/components/ui/Listbox.tsx +++ b/gui/src/components/ui/Listbox.tsx @@ -46,7 +46,7 @@ const ListboxOptions = React.forwardRef( anchor={"bottom start"} {...props} className={cn( - "bg-vsc-input-background flex flex-col overflow-auto px-0 shadow-md", + "bg-vsc-input-background flex w-max min-w-[160px] max-w-[400px] flex-col overflow-auto px-0 shadow-md", props.className, )} style={{ diff --git a/gui/src/pages/AddNewModel/AddNewModel.tsx b/gui/src/pages/AddNewModel/AddNewModel.tsx deleted file mode 100644 index e2fa104ea..000000000 --- a/gui/src/pages/AddNewModel/AddNewModel.tsx +++ /dev/null @@ -1,238 +0,0 @@ -import { ArrowLeftIcon, Cog6ToothIcon } from "@heroicons/react/24/outline"; -import _ from "lodash"; -import React, { useContext } from "react"; -import { useDispatch } from "react-redux"; -import { Link, useNavigate } from "react-router-dom"; -import styled from "styled-components"; -import { - defaultBorderRadius, - lightGray, - vscBackground, -} from "../../components"; -import ModelCard from "../../components/modelSelection/ModelCard"; -import Toggle from "../../components/modelSelection/Toggle"; -import { IdeMessengerContext } from "../../context/IdeMessenger"; -import { useNavigationListener } from "../../hooks/useNavigationListener"; -import { setDefaultModel } from "../../redux/slices/configSlice"; -import { ModelPackage, models } from "./configs/models"; -import { providers } from "./configs/providers"; -import { CustomModelButton } from "./ConfigureProvider"; - -const IntroDiv = styled.div` - padding: 8px 12px; - border-radius: ${defaultBorderRadius}; - border: 1px solid ${lightGray}; - margin-top: 1rem; - margin-bottom: 1rem; -`; - -const GridDiv = styled.div` - display: grid; - grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); - grid-gap: 1.25rem; - justify-items: center; - align-items: center; -`; - -/** - * Used to display groupings in the Models tab - */ -const modelsByProvider: Record = { - "Open AI": [models.gpt4turbo, models.gpt4o, models.gpt35turbo], - Anthropic: [models.claude3Opus, models.claude3Sonnet, models.claude35Haiku], - Mistral: [ - models.codestral, - models.mistral7b, - models.mistral8x7b, - models.mistral8x22b, - models.mistralSmall, - models.mistralLarge, - ], - Cohere: [models.commandR, models.commandRPlus], - DeepSeek: [ - models.deepseekCoderApi, - models.deepseekChatApi, - models.deepseekReasonerApi, - ], - Gemini: [models.geminiPro, models.gemini15Pro, models.gemini15Flash], - "Open Source": [models.llama3Chat, models.mistralOs, models.deepseek], -}; - -function AddNewModel() { - const navigate = useNavigate(); - const dispatch = useDispatch(); - useNavigationListener(); - const ideMessenger = useContext(IdeMessengerContext); - - const [providersSelected, setProvidersSelected] = React.useState(true); - - return ( -
-
- navigate("/")} - className="ml-4 inline-block cursor-pointer" - /> -

Add a new model

-
-
-
- - To add a new model you can either: -
    -
  • - Start by selecting and configuring a provider, then choosing your - model -
  • -
  • Select a specific model directly
  • -
- - Visit our setup overview docs - {" "} - to learn more. -
- -
- { - setProvidersSelected((prev) => !prev); - }} - > -
- - {providersSelected ? ( - <> -
-

Providers

-

- Select a provider below, or configure your own in{" "} - config.json -

-
- - - {Object.entries(providers).map(([providerName, modelInfo], i) => - modelInfo ? ( - { - console.log(`/addModel/provider/${providerName}`); - navigate(`/addModel/provider/${providerName}`); - }} - /> - ) : null, - )} - - - ) : ( - <> -
-

Models

-

- Select a model from the most popular options below, or configure - your own in config.json -

-
- - {Object.entries(modelsByProvider).map( - ([providerTitle, modelConfigsByProviderTitle]) => ( -
-
-

{providerTitle}

-
-
- - - {modelConfigsByProviderTitle.map((config) => ( - { - if (!selectedProvider) { - return; - } - const model = { - ...config.params, - ..._.merge( - {}, - ...(config.dimensions?.map((dimension, i) => { - if (!dimensionChoices?.[i]) return {}; - return { - ...dimension.options[dimensionChoices[i]], - }; - }) || []), - ), - provider: providers[selectedProvider]?.provider, - }; - ideMessenger.post("config/addModel", { model }); - dispatch( - setDefaultModel({ - title: model.title, - force: true, - }), - ); - navigate("/"); - }} - /> - ))} - -
- ), - )} - - )} - - { - ideMessenger.post("config/openProfile", { - profileId: undefined, - }); - }} - > -

- - Open Assistant configuration -

-
-
-
- ); -} - -export default AddNewModel; diff --git a/gui/src/pages/AddNewModel/ConfigureProvider.tsx b/gui/src/pages/AddNewModel/ConfigureProvider.tsx deleted file mode 100644 index 33a3366d6..000000000 --- a/gui/src/pages/AddNewModel/ConfigureProvider.tsx +++ /dev/null @@ -1,245 +0,0 @@ -import { ArrowLeftIcon } from "@heroicons/react/24/outline"; -import _ from "lodash"; -import { useCallback, useContext, useEffect, useState } from "react"; -import { FormProvider, useForm } from "react-hook-form"; -import { useDispatch } from "react-redux"; -import { useNavigate, useParams } from "react-router-dom"; -import styled from "styled-components"; -import { - Input, - defaultBorderRadius, - lightGray, - vscBackground, -} from "../../components"; -import StyledMarkdownPreview from "../../components/markdown/StyledMarkdownPreview"; -import ModelCard from "../../components/modelSelection/ModelCard"; -import { ModelProviderTag } from "../../components/modelSelection/ModelProviderTag"; -import { IdeMessengerContext } from "../../context/IdeMessenger"; -import { useNavigationListener } from "../../hooks/useNavigationListener"; -import { updatedObj } from "../../util"; -import type { ProviderInfo } from "./configs/providers"; -import { providers } from "./configs/providers"; -import { setDefaultModel } from "../../redux/slices/configSlice"; - -const GridDiv = styled.div` - display: grid; - grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); - grid-gap: 2rem; - padding: 1rem; - justify-items: center; - align-items: center; -`; - -export const CustomModelButton = styled.div<{ disabled: boolean }>` - border: 1px solid ${lightGray}; - border-radius: ${defaultBorderRadius}; - padding: 4px 8px; - display: flex; - justify-content: center; - align-items: center; - transition: all 0.5s; - - ${(props) => - props.disabled - ? ` - opacity: 0.5; - ` - : ` - &:hover { - border: 1px solid #be1b55; - background-color: #be1b5522; - cursor: pointer; - } - `} -`; - -function ConfigureProvider() { - useNavigationListener(); - const formMethods = useForm(); - const { providerName } = useParams(); - const ideMessenger = useContext(IdeMessengerContext); - const dispatch = useDispatch(); - const navigate = useNavigate(); - const [modelInfo, setModelInfo] = useState( - undefined, - ); - - useEffect(() => { - if (providerName) { - setModelInfo(providers[providerName]); - } - }, [providerName]); - - const disableModelCards = useCallback(() => { - return ( - modelInfo?.collectInputFor?.some((d) => { - if (!d.required) return false; - const val = formMethods.watch(d.key); - return ( - typeof val === "undefined" || (typeof val === "string" && val === "") - ); - }) || false - ); - }, [modelInfo, formMethods]); - - return ( - -
-
- navigate("/addModel")} - className="ml-4 inline-block cursor-pointer" - /> -

- Configure provider -

-
- -
-
- {window.vscMediaUrl && modelInfo?.icon && ( - - )} -

{modelInfo?.title}

-
- - {modelInfo?.tags?.map((tag, i) => ( - - ))} - - -
- - {(modelInfo?.collectInputFor?.filter((d) => d.required).length || 0) > - 0 && ( - <> -

Enter required parameters

- - {modelInfo?.collectInputFor - ?.filter((d) => d.required) - .map((d, idx) => ( -
- - -
- ))} - - )} - - {(modelInfo?.collectInputFor?.filter((d) => !d.required).length || - 0) > 0 && ( -
- - Advanced (optional) - - - {modelInfo?.collectInputFor?.map((d, idx) => { - if (d.required) return null; - return ( -
- - -
- ); - })} -
- )} - -

Select a model preset

-
- - {modelInfo?.packages.map((pkg, idx) => { - return ( - { - if (disableModelCards()) return; - let formParams: any = {}; - for (const d of modelInfo.collectInputFor || []) { - const val = formMethods.watch(d.key); - if (val === "" || val === undefined || val === null) { - continue; - } - formParams = updatedObj(formParams, { - [d.key]: d.inputType === "text" ? val : parseFloat(val), - }); - } - - const model = { - ...pkg.params, - ...modelInfo.params, - ..._.merge( - {}, - ...(pkg.dimensions?.map((dimension, i) => { - if (!dimensionChoices?.[i]) return {}; - return { - ...dimension.options[dimensionChoices[i]], - }; - }) || []), - ), - ...formParams, - provider: modelInfo.provider, - }; - ideMessenger.post("config/addModel", { model }); - dispatch( - setDefaultModel({ title: model.title, force: true }), - ); - navigate("/"); - }} - /> - ); - })} - -
-
- ); -} - -export default ConfigureProvider; diff --git a/gui/src/pages/AddNewModel/configs/models.ts b/gui/src/pages/AddNewModel/configs/models.ts index fafdc53b7..d21a7d66f 100644 --- a/gui/src/pages/AddNewModel/configs/models.ts +++ b/gui/src/pages/AddNewModel/configs/models.ts @@ -887,6 +887,48 @@ export const models: { [key: string]: ModelPackage } = { providerOptions: ["gemini"], isOpenSource: false, }, + gemini20FlashLite: { + title: "Gemini 2.0 Flash Lite", + description: + "A more efficient version of Gemini 2.0 Flash optimized for faster responses and lower resource usage.", + params: { + title: "Gemini 2.0 Flash Lite", + model: "gemini-2.0-flash-lite", + contextLength: 1_048_576, + apiKey: "", + }, + icon: "gemini.png", + providerOptions: ["gemini"], + isOpenSource: false, + }, + gemini20FlashImageGeneration: { + title: "Gemini 2.0 Flash Image Generation", + description: + "A version of Gemini 2.0 Flash optimized for image generation capabilities.", + params: { + title: "Gemini 2.0 Flash Image Generation", + model: "gemini-2.0-flash-exp-image-generation", + contextLength: 32_768, + apiKey: "", + }, + icon: "gemini.png", + providerOptions: ["gemini"], + isOpenSource: false, + }, + gemini25ProExp: { + title: "Gemini 2.5 Pro Experimental", + description: + "Experimental version of Gemini 2.5 Pro with enhanced capabilities and larger output limits.", + params: { + title: "Gemini 2.5 Pro Experimental", + model: "gemini-2.5-pro-exp-03-25", + contextLength: 1_048_576, + apiKey: "", + }, + icon: "gemini.png", + providerOptions: ["gemini"], + isOpenSource: false, + }, commandR: { title: "Command R", description: diff --git a/gui/src/pages/AddNewModel/configs/providers.ts b/gui/src/pages/AddNewModel/configs/providers.ts index 089ba74f9..43a3bbe4c 100644 --- a/gui/src/pages/AddNewModel/configs/providers.ts +++ b/gui/src/pages/AddNewModel/configs/providers.ts @@ -495,6 +495,9 @@ Select the \`GPT-4o\` model below to complete your provider configuration, but n ], packages: [ models.gemini20Flash, + models.gemini20FlashLite, + models.gemini20FlashImageGeneration, + models.gemini25ProExp, models.gemini15Pro, models.geminiPro, models.gemini15Flash, diff --git a/gui/src/pages/AddNewModel/index.ts b/gui/src/pages/AddNewModel/index.ts deleted file mode 100644 index fa5775f14..000000000 --- a/gui/src/pages/AddNewModel/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default as AddNewModel } from "./AddNewModel"; -export { default as ConfigureProvider } from "./ConfigureProvider"; diff --git a/gui/src/pages/config/UserSettingsForm.tsx b/gui/src/pages/config/UserSettingsForm.tsx index d9efc4c49..d9a5cfd27 100644 --- a/gui/src/pages/config/UserSettingsForm.tsx +++ b/gui/src/pages/config/UserSettingsForm.tsx @@ -101,55 +101,69 @@ export function UserSettingsForm() { }, [ideMessenger]); return ( -
+
+ {/* {selectedProfile && isLocalProfile(selectedProfile) ? ( +
+ { + ideMessenger.post("config/openProfile", { + profileId: selectedProfile.id, + }); + }} + > + Open + Config + File + +
+ ) : null} */} {!controlServerBetaEnabled || hubEnabled ? ( -
-
-
-
-

User settings

-
+
+
+

User settings

+
-
- - handleUpdate({ - showSessionTabs: !showSessionTabs, - }) - } - text="Show Session Tabs" - /> - - handleUpdate({ - codeWrap: !codeWrap, - }) - } - text="Wrap Codeblocks" - /> +
+ + handleUpdate({ + showSessionTabs: !showSessionTabs, + }) + } + text="Show Session Tabs" + /> + + handleUpdate({ + codeWrap: !codeWrap, + }) + } + text="Wrap Codeblocks" + /> - - handleUpdate({ - showChatScrollbar: !showChatScrollbar, - }) - } - text="Show Chat Scrollbar" - /> - - handleUpdate({ - readResponseTTS: !readResponseTTS, - }) - } - text="Text-to-Speech Output" - /> + + handleUpdate({ + showChatScrollbar: !showChatScrollbar, + }) + } + text="Show Chat Scrollbar" + /> + + handleUpdate({ + readResponseTTS: !readResponseTTS, + }) + } + text="Text-to-Speech Output" + /> - {/* handleUpdate({ @@ -158,46 +172,46 @@ export function UserSettingsForm() { } text="Use Chromium for Docs Crawling" /> */} - - handleUpdate({ - disableSessionTitles: !disableSessionTitles, - }) - } - text="Enable Session Titles" - /> - - handleUpdate({ - displayRawMarkdown: !displayRawMarkdown, - }) - } - text="Format Markdown" - /> + + handleUpdate({ + disableSessionTitles: !disableSessionTitles, + }) + } + text="Enable Session Titles" + /> + + handleUpdate({ + displayRawMarkdown: !displayRawMarkdown, + }) + } + text="Format Markdown" + /> - - handleUpdate({ - allowAnonymousTelemetry: !allowAnonymousTelemetry, - }) - } - text="Allow Anonymous Telemetry" - /> + + handleUpdate({ + allowAnonymousTelemetry: !allowAnonymousTelemetry, + }) + } + text="Allow Anonymous Telemetry" + /> - - handleUpdate({ - disableIndexing: !disableIndexing, - }) - } - text="Enable Indexing" - /> + + handleUpdate({ + disableIndexing: !disableIndexing, + }) + } + text="Enable Indexing" + /> - {/* handleUpdate({ @@ -207,89 +221,86 @@ export function UserSettingsForm() { text="Use Autocomplete Cache" /> */} -
) : null} diff --git a/gui/src/pages/gui/ToolCallDiv/ToolCall.tsx b/gui/src/pages/gui/ToolCallDiv/ToolCall.tsx index 24a131440..3fc0fb206 100644 --- a/gui/src/pages/gui/ToolCallDiv/ToolCall.tsx +++ b/gui/src/pages/gui/ToolCallDiv/ToolCall.tsx @@ -130,7 +130,7 @@ export function ToolCallDisplay(props: ToolCallDisplayProps) { {args.map(([key, value]) => (
{key}: - {value} + {value.toString()}
))}
diff --git a/gui/src/redux/slices/uiSlice.ts b/gui/src/redux/slices/uiSlice.ts index 7bb7fb3fd..9ebf8969f 100644 --- a/gui/src/redux/slices/uiSlice.ts +++ b/gui/src/redux/slices/uiSlice.ts @@ -52,6 +52,7 @@ export const uiSlice = createSlice({ [BuiltInToolNames.ExactSearch]: "allowedWithoutPermission", [BuiltInToolNames.SearchWeb]: "allowedWithoutPermission", [BuiltInToolNames.ViewDiff]: "allowedWithoutPermission", + [BuiltInToolNames.LSTool]: "allowedWithoutPermission", }, toolGroupSettings: { BUILT_IN_GROUP_NAME: "include", diff --git a/gui/src/util/localStorage.ts b/gui/src/util/localStorage.ts index 28d63b847..918618723 100644 --- a/gui/src/util/localStorage.ts +++ b/gui/src/util/localStorage.ts @@ -15,8 +15,6 @@ type LocalStorageTypes = { showTutorialCard: boolean; shownProfilesIntroduction: boolean; disableIndexing: boolean; - /** Indicates whether the user has seen any kind of onboarding card since hub.continue.dev */ - seenHubIntro: boolean; }; export enum LocalStorageKey { diff --git a/package-lock.json b/package-lock.json index 6a0a55705..cdfb21273 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,7 +8,8 @@ "@typescript-eslint/parser": "^7.8.0", "eslint-plugin-import": "^2.29.1", "prettier": "^3.3.3", - "prettier-plugin-tailwindcss": "^0.6.8" + "prettier-plugin-tailwindcss": "^0.6.8", + "typescript": "^5.6.3" } }, "node_modules/@eslint-community/eslint-utils": { @@ -2976,7 +2977,6 @@ "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.6.3.tgz", "integrity": "sha512-hjcS1mhfuyi4WW8IWtjP7brDrG2cuDZukyrYrSauoXGNgx0S7zceP07adYkJycEr56BOUTNPzbInooiN3fn1qw==", "dev": true, - "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" diff --git a/packages/config-yaml/package.json b/packages/config-yaml/package.json index 7069105af..1165210fb 100644 --- a/packages/config-yaml/package.json +++ b/packages/config-yaml/package.json @@ -1,6 +1,6 @@ { "name": "@continuedev/config-yaml", - "version": "1.0.75", + "version": "1.0.76", "description": "", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/packages/config-yaml/src/README.md b/packages/config-yaml/src/README.md index 4ef80cb49..c68cd8fdc 100644 --- a/packages/config-yaml/src/README.md +++ b/packages/config-yaml/src/README.md @@ -15,3 +15,14 @@ This happens on the server, unless using local mode. ## Client rendering The unrolled config.yaml is then rendered on the client. This is done by replacing all user secret template variables with their values and replacing all other secrets with secret locations. + +## Publishing + +Make sure you are logged into the npm registry with `npm login`. + +Then, bump the version in `package.json` and then run: + +```bash +npm run build +npm publish --access public +``` diff --git a/packages/config-yaml/src/load/unroll.ts b/packages/config-yaml/src/load/unroll.ts index b3e7ff1ee..50b1d072a 100644 --- a/packages/config-yaml/src/load/unroll.ts +++ b/packages/config-yaml/src/load/unroll.ts @@ -17,6 +17,7 @@ import { blockSchema, ConfigYaml, configYamlSchema, + Rule, } from "../schemas/index.js"; import { useProxyForUnrenderedSecrets } from "./clientRender.js"; @@ -62,7 +63,7 @@ export function parseBlock(configYaml: string): Block { } } -const TEMPLATE_VAR_REGEX = /\${{[\s]*([^}\s]+)[\s]*}}/g; +export const TEMPLATE_VAR_REGEX = /\${{[\s]*([^}\s]+)[\s]*}}/g; export function getTemplateVariables(templatedYaml: string): string[] { const variables = new Set(); @@ -145,6 +146,7 @@ function extractFQSNMap( async function extractRenderedSecretsMap( rawContent: string, platformClient: PlatformClient, + alwaysUseProxy: boolean = false, ): Promise> { // Get all template variables const templateVars = getTemplateVariables(rawContent); @@ -164,7 +166,7 @@ async function extractRenderedSecretsMap( } // User secrets are rendered - if ("value" in secretResult) { + if ("value" in secretResult && !alwaysUseProxy) { map[encodeFQSN(secretResult.fqsn)] = secretResult.value; } else { // Other secrets are rendered as secret locations and then converted to proxy types later @@ -186,6 +188,7 @@ export interface RenderSecretsUnrollAssistantOptions { currentUserSlug: string; platformClient: PlatformClient; onPremProxyUrl: string | null; + alwaysUseProxy?: boolean; } export type UnrollAssistantOptions = @@ -255,6 +258,7 @@ export async function unrollAssistantFromContent( const secrets = await extractRenderedSecretsMap( templatedYaml, options.platformClient, + options.alwaysUseProxy, ); const renderedYaml = renderTemplateData(templatedYaml, { secrets, @@ -320,13 +324,13 @@ export async function unrollBlocks( } } - // Rules are a bit different because they're just strings, so handle separately + // Rules are a bit different because they can be strings, so hanlde separately if (assistant.rules) { - const rules: Array = []; + const rules: (Rule | null)[] = []; for (const rule of assistant.rules) { - if (typeof rule === "string") { + if (typeof rule === "string" || !("uses" in rule)) { rules.push(rule); - } else { + } else if ("uses" in rule) { try { const blockConfigYaml = await resolveBlock( decodeFullSlug(rule.uses), diff --git a/packages/config-yaml/src/schemas/index.ts b/packages/config-yaml/src/schemas/index.ts index ba6aa5e79..fdfdcc170 100644 --- a/packages/config-yaml/src/schemas/index.ts +++ b/packages/config-yaml/src/schemas/index.ts @@ -28,6 +28,16 @@ const docSchema = z.object({ faviconUrl: z.string().optional(), }); +const ruleObjectSchema = z.object({ + name: z.string(), + rule: z.string(), + if: z.string().optional(), +}); + +const ruleSchema = z.union([z.string(), ruleObjectSchema]); + +export type Rule = z.infer; + export const blockItemWrapperSchema = (schema: T) => z.object({ uses: z.string(), @@ -63,7 +73,7 @@ export const configYamlSchema = baseConfigYamlSchema.extend({ rules: z .array( z.union([ - z.string(), + ruleSchema, z.object({ uses: z.string(), with: z.record(z.string()).optional(), @@ -94,7 +104,7 @@ export const assistantUnrolledSchemaNonNullable = baseConfigYamlSchema.extend({ context: z.array(contextSchema).optional(), data: z.array(dataSchema).optional(), mcpServers: z.array(mcpServerSchema).optional(), - rules: z.array(z.string()).optional(), + rules: z.array(ruleSchema).optional(), prompts: z.array(promptSchema).optional(), docs: z.array(docSchema).optional(), }); @@ -120,7 +130,9 @@ export const blockSchema = baseConfigYamlSchema.and( z.object({ context: z.array(contextSchema).length(1) }), z.object({ data: z.array(dataSchema).length(1) }), z.object({ mcpServers: z.array(mcpServerSchema).length(1) }), - z.object({ rules: z.array(z.string()).length(1) }), + z.object({ + rules: z.array(ruleSchema).length(1), + }), z.object({ prompts: z.array(promptSchema).length(1) }), z.object({ docs: z.array(docSchema).length(1) }), ]), diff --git a/packages/fetch/package.json b/packages/fetch/package.json index 6a7097284..e0a924706 100644 --- a/packages/fetch/package.json +++ b/packages/fetch/package.json @@ -1,6 +1,6 @@ { "name": "@continuedev/fetch", - "version": "1.0.4", + "version": "1.0.5", "description": "", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/packages/fetch/src/fetch.ts b/packages/fetch/src/fetch.ts index 01fc631db..d4e8145d0 100644 --- a/packages/fetch/src/fetch.ts +++ b/packages/fetch/src/fetch.ts @@ -15,9 +15,9 @@ export function fetchwithRequestOptions( init?: RequestInit, requestOptions?: RequestOptions, ): Promise { - let url = url_; - if (typeof url === "string") { - url = new URL(url); + const url = typeof url_ === "string" ? new URL(url_) : url_; + if (url.host === "localhost") { + url.host = "127.0.0.1"; } const TIMEOUT = 7200; // 7200 seconds = 2 hours diff --git a/packages/fetch/src/stream.ts b/packages/fetch/src/stream.ts index d0e8e4633..7f33e377d 100644 --- a/packages/fetch/src/stream.ts +++ b/packages/fetch/src/stream.ts @@ -2,6 +2,7 @@ export async function* toAsyncIterable( nodeReadable: NodeJS.ReadableStream, ): AsyncGenerator { for await (const chunk of nodeReadable) { + // @ts-expect-error yield chunk as Uint8Array; } } diff --git a/packages/llm-info/src/providers/gemini.ts b/packages/llm-info/src/providers/gemini.ts index 2ef76b63a..b8c30610c 100644 --- a/packages/llm-info/src/providers/gemini.ts +++ b/packages/llm-info/src/providers/gemini.ts @@ -11,6 +11,33 @@ export const Gemini: ModelProvider = { regex: /gemini-2\.0-flash/i, recommendedFor: ["chat"] }, + { + model: "gemini-2.0-flash-lite", + displayName: "Gemini 2.0 Flash Lite", + contextLength: 1048576, + maxCompletionTokens: 8192, + mediaTypes: AllMediaTypes, + regex: /gemini-2\.0-flash-lite/i, + recommendedFor: ["chat"] + }, + { + model: "gemini-2.0-flash-exp-image-generation", + displayName: "Gemini 2.0 Flash Image Generation", + contextLength: 32768, + maxCompletionTokens: 8192, + mediaTypes: AllMediaTypes, + regex: /gemini-2\.0-flash-exp-image-generation/i, + recommendedFor: ["chat"] + }, + { + model: "gemini-2.5-pro-exp-03-25", + displayName: "Gemini 2.5 Pro Exp", + contextLength: 1048576, + maxCompletionTokens: 65536, + mediaTypes: AllMediaTypes, + regex: /gemini-2\.5-pro-exp-03-25/i, + recommendedFor: ["chat"] + }, { model: "gemini-1.5-flash", displayName: "Gemini 1.5 Flash", diff --git a/packages/llm-info/src/providers/vertexai.ts b/packages/llm-info/src/providers/vertexai.ts index 99faaf844..db147146b 100644 --- a/packages/llm-info/src/providers/vertexai.ts +++ b/packages/llm-info/src/providers/vertexai.ts @@ -11,6 +11,33 @@ export const Gemini: ModelProvider = { regex: /gemini-2\.0-flash/i, recommendedFor: ["chat"] }, + { + model: "gemini-2.0-flash-lite", + displayName: "Gemini 2.0 Flash Lite", + contextLength: 1048576, + maxCompletionTokens: 8192, + mediaTypes: AllMediaTypes, + regex: /gemini-2\.0-flash-lite/i, + recommendedFor: ["chat"] + }, + { + model: "gemini-2.0-flash-exp-image-generation", + displayName: "Gemini 2.0 Flash Image Generation", + contextLength: 32768, + maxCompletionTokens: 8192, + mediaTypes: AllMediaTypes, + regex: /gemini-2\.0-flash-exp-image-generation/i, + recommendedFor: ["chat"] + }, + { + model: "gemini-2.5-pro-exp-03-25", + displayName: "Gemini 2.5 Pro Exp", + contextLength: 1048576, + maxCompletionTokens: 65536, + mediaTypes: AllMediaTypes, + regex: /gemini-2\.5-pro-exp-03-25/i, + recommendedFor: ["chat"] + }, { model: "gemini-1.5-flash", displayName: "Gemini 1.5 Flash", diff --git a/packages/openai-adapters/package-lock.json b/packages/openai-adapters/package-lock.json index e21663eef..1fa921da5 100644 --- a/packages/openai-adapters/package-lock.json +++ b/packages/openai-adapters/package-lock.json @@ -1,22 +1,22 @@ { "name": "@continuedev/openai-adapters", - "version": "1.0.12", + "version": "1.0.18", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@continuedev/openai-adapters", - "version": "1.0.12", + "version": "1.0.18", "license": "Apache-2.0", "dependencies": { "@azure/openai": "^1.0.0-beta.12", "@continuedev/config-types": "^1.0.5", - "@continuedev/config-yaml": "^1.0.31", + "@continuedev/config-yaml": "^1.0.51", "@continuedev/fetch": "^1.0.3", "json-schema": "^0.4.0", "node-fetch": "^3.3.2", "openai": "^4.76.0", - "zod": "^3.23.8" + "zod": "^3.24.2" }, "devDependencies": { "@types/follow-redirects": "^1.14.4", @@ -712,13 +712,14 @@ } }, "node_modules/@continuedev/config-yaml": { - "version": "1.0.31", - "resolved": "https://registry.npmjs.org/@continuedev/config-yaml/-/config-yaml-1.0.31.tgz", - "integrity": "sha512-HNj+z7UTTARgsJTI0A1buM09fS4HoWVnn6Hbl6kJ2tZmOOm1OgogbcKP68AzHb4fy5H18MWnKS7XuseZpHFzHQ==", + "version": "1.0.68", + "resolved": "https://registry.npmjs.org/@continuedev/config-yaml/-/config-yaml-1.0.68.tgz", + "integrity": "sha512-rCegSGkv7Ws7LLnYVVGwXsoVZFpNFJnG6b1dVrj/u+2ZsFdA2leQUNtFGoeE/ixyfhUfBpMlgjEyPrmmy7gLjw==", + "license": "Apache-2.0", "dependencies": { "@continuedev/config-types": "^1.0.14", "yaml": "^2.6.1", - "zod": "^3.23.8" + "zod": "^3.24.2" } }, "node_modules/@continuedev/fetch": { @@ -4541,9 +4542,10 @@ } }, "node_modules/zod": { - "version": "3.23.8", - "resolved": "https://registry.npmjs.org/zod/-/zod-3.23.8.tgz", - "integrity": "sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==", + "version": "3.24.2", + "resolved": "https://registry.npmjs.org/zod/-/zod-3.24.2.tgz", + "integrity": "sha512-lY7CDW43ECgW9u1TcT3IoXHflywfVqDYze4waEz812jR/bZ8FHDsl7pFQoSZTz5N+2NqRXs8GBwnAwo3ZNxqhQ==", + "license": "MIT", "funding": { "url": "https://github.com/sponsors/colinhacks" } diff --git a/packages/openai-adapters/src/apis/OpenAI.ts b/packages/openai-adapters/src/apis/OpenAI.ts index 358f52dca..ab72a85b1 100644 --- a/packages/openai-adapters/src/apis/OpenAI.ts +++ b/packages/openai-adapters/src/apis/OpenAI.ts @@ -1,5 +1,4 @@ import { streamSse } from "@continuedev/fetch"; -import fetch from "node-fetch"; import { OpenAI } from "openai/index"; import { ChatCompletion, @@ -14,7 +13,7 @@ import { } from "openai/resources/index"; import { z } from "zod"; import { OpenAIConfigSchema } from "../types.js"; -import { customFetch, maybeCustomFetch } from "../util.js"; +import { customFetch } from "../util.js"; import { BaseLlmApi, CreateRerankResponse, @@ -36,8 +35,9 @@ export class OpenAIApi implements BaseLlmApi { } modifyChatBody(body: T): T { - // o-series models - if (body.model.startsWith("o")) { + // o-series models - only apply for official OpenAI API + const isOfficialOpenAIAPI = this.apiBase === "https://api.openai.com/v1/"; + if (isOfficialOpenAIAPI && body.model.startsWith("o")) { // a) use max_completion_tokens instead of max_tokens body.max_completion_tokens = body.max_tokens; body.max_tokens = undefined;