From 90a206f2d4310680855a717bda27ffad8deed791 Mon Sep 17 00:00:00 2001 From: Cole Medin <47287758+coleam00@users.noreply.github.com> Date: Sun, 13 Oct 2024 13:53:43 -0500 Subject: [PATCH 1/4] Added the ability to use practically any LLM you can dream of within Bolt.new --- .env.example | 19 ++ .gitignore | 3 +- README.md | 88 ++++-- app/components/chat/BaseChat.tsx | 43 ++- app/components/chat/Chat.client.tsx | 10 +- app/components/chat/UserMessage.tsx | 5 +- app/lib/.server/llm/api-key.ts | 15 +- app/lib/.server/llm/model.ts | 45 ++- app/lib/.server/llm/stream-text.ts | 45 ++- app/routes/api.chat.ts | 2 + app/utils/constants.ts | 29 ++ package.json | 4 +- pnpm-lock.yaml | 456 +++++++++++++++++++++++----- worker-configuration.d.ts | 2 + 14 files changed, 641 insertions(+), 125 deletions(-) create mode 100644 .env.example diff --git a/.env.example b/.env.example new file mode 100644 index 000000000..e411dcee0 --- /dev/null +++ b/.env.example @@ -0,0 +1,19 @@ +# Rename this file to .env.local once you have filled in the below environment variables! + +# Get your GROQ API Key here - +# https://console.groq.com/keys +# You only need this environment variable set if you want to use Groq models +GROQ_API_KEY= + +# Get your Open AI API Key by following these instructions - +# https://help.openai.com/en/articles/4936850-where-do-i-find-my-openai-api-key +# You only need this environment variable set if you want to use GPT models +OPENAI_API_KEY= + +# Get your Anthropic API Key in your account settings - +# https://console.anthropic.com/settings/keys +# You only need this environment variable set if you want to use Claude models +ANTHROPIC_API_KEY= + +# Include this environment variable if you want more logging for debugging locally +VITE_LOG_LEVEL=debug \ No newline at end of file diff --git a/.gitignore b/.gitignore index 965ef504a..20f5d1506 100644 --- a/.gitignore +++ b/.gitignore @@ -24,7 +24,8 @@ dist-ssr /.cache /build -.env* +.env.local +.env *.vars .wrangler _worker.bundle diff --git a/README.md b/README.md index f4ca2f743..d3bb8b684 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ [![Bolt.new: AI-Powered Full-Stack Web Development in the Browser](./public/social_preview_index.jpg)](https://bolt.new) +# Bolt.new Fork by Cole Medin + +This fork of bolt.new allows you to choose the LLM that you use for each prompt! Currently you can use OpenAI, Anthropic, Ollama, or Groq models - and it is easily extended to use any other model supported by the Vercel AI SDK! See instructions below for running this locally and extending to include more models. + # Bolt.new: AI-Powered Full-Stack Web Development in the Browser Bolt.new is an AI-powered web development agent that allows you to prompt, run, edit, and deploy full-stack applications directly from your browser—no local setup required. If you're here to build your own AI-powered web dev agent using the Bolt open source codebase, [click here to get started!](./CONTRIBUTING.md) @@ -21,34 +25,80 @@ Whether you’re an experienced developer, a PM or designer, Bolt.new allows you For developers interested in building their own AI-powered development tools with WebContainers, check out the open-source Bolt codebase in this repo! -## Tips and Tricks +## Prerequisites -Here are some tips to get the most out of Bolt.new: +Before you begin, ensure you have the following installed: -- **Be specific about your stack**: If you want to use specific frameworks or libraries (like Astro, Tailwind, ShadCN, or any other popular JavaScript framework), mention them in your initial prompt to ensure Bolt scaffolds the project accordingly. +- Node.js (v20.15.1) +- pnpm (v9.4.0) -- **Use the enhance prompt icon**: Before sending your prompt, try clicking the 'enhance' icon to have the AI model help you refine your prompt, then edit the results before submitting. +## Setup -- **Scaffold the basics first, then add features**: Make sure the basic structure of your application is in place before diving into more advanced functionality. This helps Bolt understand the foundation of your project and ensure everything is wired up right before building out more advanced functionality. +1. Clone the repository (if you haven't already): -- **Batch simple instructions**: Save time by combining simple instructions into one message. For example, you can ask Bolt to change the color scheme, add mobile responsiveness, and restart the dev server, all in one go saving you time and reducing API credit consumption significantly. +```bash +git clone https://github.com/coleam00/bolt.new-any-llm.git +``` + +2. Install dependencies: + +```bash +pnpm install +``` + +3. Rename `.env.example` to .env.local and add your LLM API keys (you only have to set the ones you want to use and Ollama doesn't need an API key because it runs locally on your computer): + +``` +GROQ_API_KEY=XXX +OPENAI_API_KEY=XXX +ANTHROPIC_API_KEY=XXX +``` + +Optionally, you can set the debug level: + +``` +VITE_LOG_LEVEL=debug +``` + +**Important**: Never commit your `.env.local` file to version control. It's already included in .gitignore. -## FAQs +## Adding New LLMs: -**Where do I sign up for a paid plan?** -Bolt.new is free to get started. If you need more AI tokens or want private projects, you can purchase a paid subscription in your [Bolt.new](https://bolt.new) settings, in the lower-left hand corner of the application. +To make new LLMs available to use in this version of Bolt.new, head on over to `app/utils/constants.ts` and find the constant MODEL_LIST. Each element in this array is an object that has the model ID for the name (get this from the provider's API documentation), a lable for the frontend model dropdown, and the provider. -**What happens if I hit the free usage limit?** -Once your free daily token limit is reached, AI interactions are paused until the next day or until you upgrade your plan. +By default, Anthropic, OpenAI, Groq, and Ollama are implemented as providers, but the YouTube video for this repo covers how to extend this to work with more providers if you wish! -**Is Bolt in beta?** -Yes, Bolt.new is in beta, and we are actively improving it based on feedback. +When you add a new model to the MODEL_LIST array, it will immediately be available to use when you run the app locally or reload it. For Ollama models, make sure you have the model installed already before trying to use it here! -**How can I report Bolt.new issues?** -Check out the [Issues section](https://github.com/bolt.new/issues) to report an issue or request a new feature. Please use the search feature to check if someone else has already submitted the same issue/request. +## Available Scripts -**What frameworks/libraries currently work on Bolt?** -Bolt.new supports most popular JavaScript frameworks and libraries. If it runs on StackBlitz, it will run on Bolt.new as well. +- `pnpm run dev`: Starts the development server. +- `pnpm run build`: Builds the project. +- `pnpm run start`: Runs the built application locally using Wrangler Pages. This script uses `bindings.sh` to set up necessary bindings so you don't have to duplicate environment variables. +- `pnpm run preview`: Builds the project and then starts it locally, useful for testing the production build. Note, HTTP streaming currently doesn't work as expected with `wrangler pages dev`. +- `pnpm test`: Runs the test suite using Vitest. +- `pnpm run typecheck`: Runs TypeScript type checking. +- `pnpm run typegen`: Generates TypeScript types using Wrangler. +- `pnpm run deploy`: Builds the project and deploys it to Cloudflare Pages. -**How can I add make sure my framework/project works well in bolt?** -We are excited to work with the JavaScript ecosystem to improve functionality in Bolt. Reach out to us via [hello@stackblitz.com](mailto:hello@stackblitz.com) to discuss how we can partner! +## Development + +To start the development server: + +```bash +pnpm run dev +``` + +This will start the Remix Vite development server. You will need Google Chrome Canary to run this locally! It's a very easy install and a good browser for web development anyway. + +## Tips and Tricks + +Here are some tips to get the most out of Bolt.new: + +- **Be specific about your stack**: If you want to use specific frameworks or libraries (like Astro, Tailwind, ShadCN, or any other popular JavaScript framework), mention them in your initial prompt to ensure Bolt scaffolds the project accordingly. + +- **Use the enhance prompt icon**: Before sending your prompt, try clicking the 'enhance' icon to have the AI model help you refine your prompt, then edit the results before submitting. + +- **Scaffold the basics first, then add features**: Make sure the basic structure of your application is in place before diving into more advanced functionality. This helps Bolt understand the foundation of your project and ensure everything is wired up right before building out more advanced functionality. + +- **Batch simple instructions**: Save time by combining simple instructions into one message. For example, you can ask Bolt to change the color scheme, add mobile responsiveness, and restart the dev server, all in one go saving you time and reducing API credit consumption significantly. diff --git a/app/components/chat/BaseChat.tsx b/app/components/chat/BaseChat.tsx index b3820e167..e3c7f5fd0 100644 --- a/app/components/chat/BaseChat.tsx +++ b/app/components/chat/BaseChat.tsx @@ -1,3 +1,5 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. import type { Message } from 'ai'; import React, { type RefCallback } from 'react'; import { ClientOnly } from 'remix-utils/client-only'; @@ -5,11 +7,22 @@ import { Menu } from '~/components/sidebar/Menu.client'; import { IconButton } from '~/components/ui/IconButton'; import { Workbench } from '~/components/workbench/Workbench.client'; import { classNames } from '~/utils/classNames'; +import { MODEL_LIST } from '~/utils/constants'; import { Messages } from './Messages.client'; import { SendButton } from './SendButton.client'; import styles from './BaseChat.module.scss'; +const EXAMPLE_PROMPTS = [ + { text: 'Build a todo app in React using Tailwind' }, + { text: 'Build a simple blog using Astro' }, + { text: 'Create a cookie consent form using Material UI' }, + { text: 'Make a space invaders game' }, + { text: 'How do I center a div?' }, +]; + +const TEXTAREA_MIN_HEIGHT = 76; + interface BaseChatProps { textareaRef?: React.RefObject | undefined; messageRef?: RefCallback | undefined; @@ -21,22 +34,14 @@ interface BaseChatProps { enhancingPrompt?: boolean; promptEnhanced?: boolean; input?: string; + model: string; + setModel: (model: string) => void; handleStop?: () => void; sendMessage?: (event: React.UIEvent, messageInput?: string) => void; handleInputChange?: (event: React.ChangeEvent) => void; enhancePrompt?: () => void; } -const EXAMPLE_PROMPTS = [ - { text: 'Build a todo app in React using Tailwind' }, - { text: 'Build a simple blog using Astro' }, - { text: 'Create a cookie consent form using Material UI' }, - { text: 'Make a space invaders game' }, - { text: 'How do I center a div?' }, -]; - -const TEXTAREA_MIN_HEIGHT = 76; - export const BaseChat = React.forwardRef( ( { @@ -50,6 +55,8 @@ export const BaseChat = React.forwardRef( promptEnhanced = false, messages, input = '', + model, + setModel, sendMessage, handleInputChange, enhancePrompt, @@ -103,6 +110,20 @@ export const BaseChat = React.forwardRef( 'sticky bottom-0': chatStarted, })} > + {/* Model selection dropdown */} +
+ +
(
); }, -); +); \ No newline at end of file diff --git a/app/components/chat/Chat.client.tsx b/app/components/chat/Chat.client.tsx index dff7598e4..458bd8364 100644 --- a/app/components/chat/Chat.client.tsx +++ b/app/components/chat/Chat.client.tsx @@ -1,3 +1,5 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. import { useStore } from '@nanostores/react'; import type { Message } from 'ai'; import { useChat } from 'ai/react'; @@ -9,6 +11,7 @@ import { useChatHistory } from '~/lib/persistence'; import { chatStore } from '~/lib/stores/chat'; import { workbenchStore } from '~/lib/stores/workbench'; import { fileModificationsToHTML } from '~/utils/diff'; +import { DEFAULT_MODEL } from '~/utils/constants'; import { cubicEasingFn } from '~/utils/easings'; import { createScopedLogger, renderLogger } from '~/utils/logger'; import { BaseChat } from './BaseChat'; @@ -70,6 +73,7 @@ export const ChatImpl = memo(({ initialMessages, storeMessageHistory }: ChatProp const textareaRef = useRef(null); const [chatStarted, setChatStarted] = useState(initialMessages.length > 0); + const [model, setModel] = useState(DEFAULT_MODEL); const { showChat } = useStore(chatStore); @@ -178,7 +182,7 @@ export const ChatImpl = memo(({ initialMessages, storeMessageHistory }: ChatProp * manually reset the input and we'd have to manually pass in file attachments. However, those * aren't relevant here. */ - append({ role: 'user', content: `${diff}\n\n${_input}` }); + append({ role: 'user', content: `[Model: ${model}]\n\n${diff}\n\n${_input}` }); /** * After sending a new message we reset all modifications since the model @@ -186,7 +190,7 @@ export const ChatImpl = memo(({ initialMessages, storeMessageHistory }: ChatProp */ workbenchStore.resetAllFileModifications(); } else { - append({ role: 'user', content: _input }); + append({ role: 'user', content: `[Model: ${model}]\n\n${_input}` }); } setInput(''); @@ -209,6 +213,8 @@ export const ChatImpl = memo(({ initialMessages, storeMessageHistory }: ChatProp enhancingPrompt={enhancingPrompt} promptEnhanced={promptEnhanced} sendMessage={sendMessage} + model={model} + setModel={setModel} messageRef={messageRef} scrollRef={scrollRef} handleInputChange={handleInputChange} diff --git a/app/components/chat/UserMessage.tsx b/app/components/chat/UserMessage.tsx index 2f4e1d52d..62e054b21 100644 --- a/app/components/chat/UserMessage.tsx +++ b/app/components/chat/UserMessage.tsx @@ -1,4 +1,7 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. import { modificationsRegex } from '~/utils/diff'; +import { MODEL_REGEX } from '~/utils/constants'; import { Markdown } from './Markdown'; interface UserMessageProps { @@ -14,5 +17,5 @@ export function UserMessage({ content }: UserMessageProps) { } function sanitizeUserMessage(content: string) { - return content.replace(modificationsRegex, '').trim(); + return content.replace(modificationsRegex, '').replace(MODEL_REGEX, '').trim(); } diff --git a/app/lib/.server/llm/api-key.ts b/app/lib/.server/llm/api-key.ts index 863f76367..8bc76856e 100644 --- a/app/lib/.server/llm/api-key.ts +++ b/app/lib/.server/llm/api-key.ts @@ -1,9 +1,20 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. import { env } from 'node:process'; -export function getAPIKey(cloudflareEnv: Env) { +export function getAPIKey(cloudflareEnv: Env, provider: string) { /** * The `cloudflareEnv` is only used when deployed or when previewing locally. * In development the environment variables are available through `env`. */ - return env.ANTHROPIC_API_KEY || cloudflareEnv.ANTHROPIC_API_KEY; + switch (provider) { + case 'Anthropic': + return env.ANTHROPIC_API_KEY || cloudflareEnv.ANTHROPIC_API_KEY; + case 'OpenAI': + return env.OPENAI_API_KEY || cloudflareEnv.OPENAI_API_KEY; + case 'Groq': + return env.GROQ_API_KEY || cloudflareEnv.GROQ_API_KEY; + default: + return ""; + } } diff --git a/app/lib/.server/llm/model.ts b/app/lib/.server/llm/model.ts index f0d695c47..0aaa37dc1 100644 --- a/app/lib/.server/llm/model.ts +++ b/app/lib/.server/llm/model.ts @@ -1,9 +1,50 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. +import { getAPIKey } from '~/lib/.server/llm/api-key'; import { createAnthropic } from '@ai-sdk/anthropic'; +import { createOpenAI } from '@ai-sdk/openai'; +import { ollama } from 'ollama-ai-provider'; -export function getAnthropicModel(apiKey: string) { +export function getAnthropicModel(apiKey: string, model: string) { const anthropic = createAnthropic({ apiKey, }); - return anthropic('claude-3-5-sonnet-20240620'); + return anthropic(model); +} + +export function getOpenAIModel(apiKey: string, model: string) { + const openai = createOpenAI({ + apiKey, + }); + + return openai(model); +} + +export function getGroqModel(apiKey: string, model: string) { + const openai = createOpenAI({ + baseURL: 'https://api.groq.com/openai/v1', + apiKey, + }); + + return openai(model); +} + +export function getOllamaModel(model: string) { + return ollama(model); +} + +export function getModel(provider: string, model: string, env: Env) { + const apiKey = getAPIKey(env, provider); + + switch (provider) { + case 'Anthropic': + return getAnthropicModel(apiKey, model); + case 'OpenAI': + return getOpenAIModel(apiKey, model); + case 'Groq': + return getGroqModel(apiKey, model); + default: + return getOllamaModel(model); + } } diff --git a/app/lib/.server/llm/stream-text.ts b/app/lib/.server/llm/stream-text.ts index cf937fd00..de3d5bfa8 100644 --- a/app/lib/.server/llm/stream-text.ts +++ b/app/lib/.server/llm/stream-text.ts @@ -1,8 +1,10 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. import { streamText as _streamText, convertToCoreMessages } from 'ai'; -import { getAPIKey } from '~/lib/.server/llm/api-key'; -import { getAnthropicModel } from '~/lib/.server/llm/model'; +import { getModel } from '~/lib/.server/llm/model'; import { MAX_TOKENS } from './constants'; import { getSystemPrompt } from './prompts'; +import { MODEL_LIST, DEFAULT_MODEL, DEFAULT_PROVIDER } from '~/utils/constants'; interface ToolResult { toolCallId: string; @@ -15,21 +17,50 @@ interface Message { role: 'user' | 'assistant'; content: string; toolInvocations?: ToolResult[]; + model?: string; } export type Messages = Message[]; export type StreamingOptions = Omit[0], 'model'>; +function extractModelFromMessage(message: Message): { model: string; content: string } { + const modelRegex = /^\[Model: (.*?)\]\n\n/; + const match = message.content.match(modelRegex); + + if (match) { + const model = match[1]; + const content = message.content.replace(modelRegex, ''); + return { model, content }; + } + + // Default model if not specified + return { model: DEFAULT_MODEL, content: message.content }; +} + export function streamText(messages: Messages, env: Env, options?: StreamingOptions) { + let currentModel = DEFAULT_MODEL; + const processedMessages = messages.map((message) => { + if (message.role === 'user') { + const { model, content } = extractModelFromMessage(message); + if (model && MODEL_LIST.find((m) => m.name === model)) { + currentModel = model; // Update the current model + } + return { ...message, content }; + } + return message; + }); + + const provider = MODEL_LIST.find((model) => model.name === currentModel)?.provider || DEFAULT_PROVIDER; + return _streamText({ - model: getAnthropicModel(getAPIKey(env)), + model: getModel(provider, currentModel, env), system: getSystemPrompt(), maxTokens: MAX_TOKENS, - headers: { - 'anthropic-beta': 'max-tokens-3-5-sonnet-2024-07-15', - }, - messages: convertToCoreMessages(messages), + // headers: { + // 'anthropic-beta': 'max-tokens-3-5-sonnet-2024-07-15', + // }, + messages: convertToCoreMessages(processedMessages), ...options, }); } diff --git a/app/routes/api.chat.ts b/app/routes/api.chat.ts index b685ac853..c455c193d 100644 --- a/app/routes/api.chat.ts +++ b/app/routes/api.chat.ts @@ -1,3 +1,5 @@ +// @ts-nocheck +// Preventing TS checks with files presented in the video for a better presentation. import { type ActionFunctionArgs } from '@remix-run/cloudflare'; import { MAX_RESPONSE_SEGMENTS, MAX_TOKENS } from '~/lib/.server/llm/constants'; import { CONTINUE_PROMPT } from '~/lib/.server/llm/prompts'; diff --git a/app/utils/constants.ts b/app/utils/constants.ts index 842ca5425..fbbe32678 100644 --- a/app/utils/constants.ts +++ b/app/utils/constants.ts @@ -1,3 +1,32 @@ export const WORK_DIR_NAME = 'project'; export const WORK_DIR = `/home/${WORK_DIR_NAME}`; export const MODIFICATIONS_TAG_NAME = 'bolt_file_modifications'; +export const MODEL_REGEX = /^\[Model: (.*?)\]\n\n/; +export const DEFAULT_MODEL = "claude-3-5-sonnet-20240620"; +export const DEFAULT_PROVIDER = "Anthropic"; +export const MODEL_LIST = [ + { name: 'claude-3-5-sonnet-20240620', label: 'Claude 3.5 Sonnet', provider: 'Anthropic' }, + { name: 'gpt-4o', label: 'GPT-4o', provider: 'OpenAI' }, + { name: 'qwen2.5-coder:7b', label: 'Qwen 2.5 Coder 7b', provider: 'Ollama' }, + { name: 'qwen2.5-coder:1.5b', label: 'Qwen 2.5 Coder 1.5b', provider: 'Ollama' }, + { name: 'deepseek-coder-v2:236b', label: 'DeepSeek-Coder-V2 236b', provider: 'Ollama' }, + { name: 'deepseek-coder-v2:16b', label: 'DeepSeek-Coder-V2 16b', provider: 'Ollama' }, + { name: 'codebooga', label: 'Codebooga 34b', provider: 'Ollama' }, + { name: 'phind-codellama', label: 'Phind CodeLlama 34b', provider: 'Ollama' }, + { name: 'codellama:70b', label: 'Code Llama 70b', provider: 'Ollama' }, + { name: 'codellama:34b', label: 'Code Llama 34b', provider: 'Ollama' }, + { name: 'codellama:13b', label: 'Code Llama 13b', provider: 'Ollama' }, + { name: 'codellama:7b', label: 'Code Llama 7b', provider: 'Ollama' }, + { name: 'llama-3.1-70b-versatile', label: 'Llama 3.1 70b (Groq)', provider: 'Groq' }, + { name: 'llama-3.1-8b-instant', label: 'Llama 3.1 8b (Groq)', provider: 'Groq' }, + { name: 'llama-3.2-11b-vision-preview', label: 'Llama 3.2 11b (Groq)', provider: 'Groq' }, + { name: 'llama-3.2-3b-preview', label: 'Llama 3.2 3b (Groq)', provider: 'Groq' }, + { name: 'llama-3.2-1b-preview', label: 'Llama 3.2 1b (Groq)', provider: 'Groq' }, + { name: 'claude-3-opus-20240229', label: 'Claude 3 Opus', provider: 'Anthropic' }, + { name: 'claude-3-sonnet-20240229', label: 'Claude 3 Sonnet', provider: 'Anthropic' }, + { name: 'claude-3-haiku-20240307', label: 'Claude 3 Haiku', provider: 'Anthropic' }, + { name: 'gpt-4o-mini', label: 'GPT-4o Mini', provider: 'OpenAI' }, + { name: 'gpt-4-turbo', label: 'GPT-4 Turbo', provider: 'OpenAI' }, + { name: 'gpt-4', label: 'GPT-4', provider: 'OpenAI' }, + { name: 'gpt-3.5-turbo', label: 'GPT-3.5 Turbo', provider: 'OpenAI' }, +]; \ No newline at end of file diff --git a/package.json b/package.json index 558345560..cb712276b 100644 --- a/package.json +++ b/package.json @@ -24,6 +24,7 @@ }, "dependencies": { "@ai-sdk/anthropic": "^0.0.39", + "@ai-sdk/openai": "^0.0.66", "@codemirror/autocomplete": "^6.17.0", "@codemirror/commands": "^6.6.0", "@codemirror/lang-cpp": "^6.0.2", @@ -54,7 +55,7 @@ "@xterm/addon-fit": "^0.10.0", "@xterm/addon-web-links": "^0.11.0", "@xterm/xterm": "^5.5.0", - "ai": "^3.3.4", + "ai": "^3.4.9", "date-fns": "^3.6.0", "diff": "^5.2.0", "framer-motion": "^11.2.12", @@ -62,6 +63,7 @@ "istextorbinary": "^9.5.0", "jose": "^5.6.3", "nanostores": "^0.10.3", + "ollama-ai-provider": "^0.15.2", "react": "^18.2.0", "react-dom": "^18.2.0", "react-hotkeys-hook": "^4.5.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0896b714b..a7aea68a3 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -14,6 +14,9 @@ importers: '@ai-sdk/anthropic': specifier: ^0.0.39 version: 0.0.39(zod@3.23.8) + '@ai-sdk/openai': + specifier: ^0.0.66 + version: 0.0.66(zod@3.23.8) '@codemirror/autocomplete': specifier: ^6.17.0 version: 6.17.0(@codemirror/language@6.10.2)(@codemirror/state@6.4.1)(@codemirror/view@6.28.4)(@lezer/common@1.2.1) @@ -105,8 +108,8 @@ importers: specifier: ^5.5.0 version: 5.5.0 ai: - specifier: ^3.3.4 - version: 3.3.4(react@18.3.1)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.30(typescript@5.5.2))(zod@3.23.8) + specifier: ^3.4.9 + version: 3.4.9(react@18.3.1)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.30(typescript@5.5.2))(zod@3.23.8) date-fns: specifier: ^3.6.0 version: 3.6.0 @@ -128,6 +131,9 @@ importers: nanostores: specifier: ^0.10.3 version: 0.10.3 + ollama-ai-provider: + specifier: ^0.15.2 + version: 0.15.2(zod@3.23.8) react: specifier: ^18.2.0 version: 18.3.1 @@ -237,6 +243,21 @@ packages: peerDependencies: zod: ^3.0.0 + '@ai-sdk/openai@0.0.66': + resolution: {integrity: sha512-V4XeDnlNl5/AY3GB3ozJUjqnBLU5pK3DacKTbCNH3zH8/MggJoH6B8wRGdLUPVFMcsMz60mtvh4DC9JsIVFrKw==} + engines: {node: '>=18'} + peerDependencies: + zod: ^3.0.0 + + '@ai-sdk/provider-utils@1.0.20': + resolution: {integrity: sha512-ngg/RGpnA00eNOWEtXHenpX1MsM2QshQh4QJFjUfwcqHpM5kTfG7je7Rc3HcEDP+OkRVv2GF+X4fC1Vfcnl8Ow==} + engines: {node: '>=18'} + peerDependencies: + zod: ^3.0.0 + peerDependenciesMeta: + zod: + optional: true + '@ai-sdk/provider-utils@1.0.9': resolution: {integrity: sha512-yfdanjUiCJbtGoRGXrcrmXn0pTyDfRIeY6ozDG96D66f2wupZaZvAgKptUa3zDYXtUCQQvcNJ+tipBBfQD/UYA==} engines: {node: '>=18'} @@ -250,8 +271,12 @@ packages: resolution: {integrity: sha512-f9j+P5yYRkqKFHxvWae5FI0j6nqROPCoPnMkpc2hc2vC7vKjqzrxBJucD8rpSaUjqiBnY/QuRJ0QeV717Uz5tg==} engines: {node: '>=18'} - '@ai-sdk/react@0.0.40': - resolution: {integrity: sha512-irljzw5m9q2kz3g4Y59fbeHI7o29DFmPTPIKQNK+XrHcvYH1sDuj4rlOnQUQl6vpahnrU7fLO6FzVIYdwZv+0w==} + '@ai-sdk/provider@0.0.24': + resolution: {integrity: sha512-XMsNGJdGO+L0cxhhegtqZ8+T6nn4EoShS819OvCgI2kLbYTIvk0GWFGD0AXJmxkxs3DrpsJxKAFukFR7bvTkgQ==} + engines: {node: '>=18'} + + '@ai-sdk/react@0.0.62': + resolution: {integrity: sha512-1asDpxgmeHWL0/EZPCLENxfOHT+0jce0z/zasRhascodm2S6f6/KZn5doLG9jdmarcb+GjMjFmmwyOVXz3W1xg==} engines: {node: '>=18'} peerDependencies: react: ^18 || ^19 @@ -262,8 +287,8 @@ packages: zod: optional: true - '@ai-sdk/solid@0.0.31': - resolution: {integrity: sha512-VYsrTCuNqAe8DzgPCyCqJl6MNdItnjjGMioxi2Pimns/3qet1bOw2LA0yUe5tTAoSpYaCAjGZZB4x8WC762asA==} + '@ai-sdk/solid@0.0.49': + resolution: {integrity: sha512-KnfWTt640cS1hM2fFIba8KHSPLpOIWXtEm28pNCHTvqasVKlh2y/zMQANTwE18pF2nuXL9P9F5/dKWaPsaEzQw==} engines: {node: '>=18'} peerDependencies: solid-js: ^1.7.7 @@ -271,8 +296,8 @@ packages: solid-js: optional: true - '@ai-sdk/svelte@0.0.33': - resolution: {integrity: sha512-/QksvqVEv9fcq39nJfu4QqqeXeFX19pqkGUlVXBNhMQ6QQXhYsUasfJodIWy1DBsKDDV6dROJM0fHku5v+hrdw==} + '@ai-sdk/svelte@0.0.51': + resolution: {integrity: sha512-aIZJaIds+KpCt19yUDCRDWebzF/17GCY7gN9KkcA2QM6IKRO5UmMcqEYja0ZmwFQPm1kBZkF2njhr8VXis2mAw==} engines: {node: '>=18'} peerDependencies: svelte: ^3.0.0 || ^4.0.0 @@ -280,8 +305,8 @@ packages: svelte: optional: true - '@ai-sdk/ui-utils@0.0.28': - resolution: {integrity: sha512-yc+0EgC/Gz36ltoHsiBmuEv7iPjV85ihuj8W1vSqYe3+CblGYHG9h8MC5RdIl51GtrOtnH9aqnDjkX5Qy6Q9KQ==} + '@ai-sdk/ui-utils@0.0.46': + resolution: {integrity: sha512-ZG/wneyJG+6w5Nm/hy1AKMuRgjPQToAxBsTk61c9sVPUTaxo+NNjM2MhXQMtmsja2N5evs8NmHie+ExEgpL3cA==} engines: {node: '>=18'} peerDependencies: zod: ^3.0.0 @@ -289,8 +314,8 @@ packages: zod: optional: true - '@ai-sdk/vue@0.0.32': - resolution: {integrity: sha512-wEiH6J6VbuGcliA44UkQJM/JuSP1IwuFiovzPQ/bS0Gb/nJKuDQ8K2ru1JvdU7pEQFqmpTm7z+2R0Sduz0eKpA==} + '@ai-sdk/vue@0.0.54': + resolution: {integrity: sha512-Ltu6gbuii8Qlp3gg7zdwdnHdS4M8nqKDij2VVO1223VOtIFwORFJzKqpfx44U11FW8z2TPVBYN+FjkyVIcN2hg==} engines: {node: '>=18'} peerDependencies: vue: ^3.3.4 @@ -394,10 +419,18 @@ packages: resolution: {integrity: sha512-7MbVt6xrwFQbunH2DNQsAP5sTGxfqQtErvBIvIMi6EQnbgUOuVYanvREcmFrOPhoXBrTtjhhP+lW+o5UfK+tDg==} engines: {node: '>=6.9.0'} + '@babel/helper-string-parser@7.25.7': + resolution: {integrity: sha512-CbkjYdsJNHFk8uqpEkpCvRs3YRp9tY6FmFY7wLMSYuGYkrdUi7r2lc4/wqsvlHoMznX3WJ9IP8giGPq68T/Y6g==} + engines: {node: '>=6.9.0'} + '@babel/helper-validator-identifier@7.24.7': resolution: {integrity: sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==} engines: {node: '>=6.9.0'} + '@babel/helper-validator-identifier@7.25.7': + resolution: {integrity: sha512-AM6TzwYqGChO45oiuPqwL2t20/HdMC1rTPAesnBCgPCSF1x3oN9MVUwQV2iyz4xqWrctwK5RNC8LV22kaQCNYg==} + engines: {node: '>=6.9.0'} + '@babel/helper-validator-option@7.24.7': resolution: {integrity: sha512-yy1/KvjhV/ZCL+SM7hBrvnZJ3ZuT9OuZgIJAGpPEToANvc3iM6iDvBnRjtElWibHU6n8/LPR/EjX9EtIEYO3pw==} engines: {node: '>=6.9.0'} @@ -415,6 +448,11 @@ packages: engines: {node: '>=6.0.0'} hasBin: true + '@babel/parser@7.25.8': + resolution: {integrity: sha512-HcttkxzdPucv3nNFmfOOMfFf64KgdJVqm1KaCm25dPGMLElo9nsLvXeJECQg8UzPuBGLyTSA0ZzqCtDSzKTEoQ==} + engines: {node: '>=6.0.0'} + hasBin: true + '@babel/plugin-syntax-decorators@7.24.7': resolution: {integrity: sha512-Ui4uLJJrRV1lb38zg1yYTmRKmiZLiftDEvZN2iq3kd9kUFU+PttmzTbAFC2ucRk/XJmtek6G23gPsuZbhrT8fQ==} engines: {node: '>=6.9.0'} @@ -467,6 +505,10 @@ packages: resolution: {integrity: sha512-XEFXSlxiG5td2EJRe8vOmRbaXVgfcBlszKujvVmWIK/UpywWljQCfzAv3RQCGujWQ1RD4YYWEAqDXfuJiy8f5Q==} engines: {node: '>=6.9.0'} + '@babel/types@7.25.8': + resolution: {integrity: sha512-JWtuCu8VQsMladxVz/P4HzHUGCAwpuqacmowgXFs5XjxIgKuNjnLokQzuVjlTvIzODaDmpjT3oxcC48vyk9EWg==} + engines: {node: '>=6.9.0'} + '@blitz/eslint-plugin@0.1.0': resolution: {integrity: sha512-mGEAFWCI5AQ4nrePhjp2WzvRen+UWR+SF4MvH70icIBClR08Gm3dT9MRa2jszOpfY00NyIYfm7/1CFZ37GvW4g==} engines: {node: ^18.0.0 || ^20.0.0} @@ -1071,6 +1113,9 @@ packages: '@jridgewell/sourcemap-codec@1.4.15': resolution: {integrity: sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==} + '@jridgewell/sourcemap-codec@1.5.0': + resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} + '@jridgewell/trace-mapping@0.3.25': resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} @@ -1702,6 +1747,9 @@ packages: '@types/estree@1.0.5': resolution: {integrity: sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==} + '@types/estree@1.0.6': + resolution: {integrity: sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==} + '@types/hast@2.3.10': resolution: {integrity: sha512-McWspRw8xx8J9HurkVBfYj0xKoE25tOFlHGdx4MJ5xORQrMGZNqJhVQWaIbm6Oyla5kYOXtDiopzKRJzEOkwJw==} @@ -2000,12 +2048,17 @@ packages: engines: {node: '>=0.4.0'} hasBin: true + acorn@8.12.1: + resolution: {integrity: sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==} + engines: {node: '>=0.4.0'} + hasBin: true + aggregate-error@3.1.0: resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==} engines: {node: '>=8'} - ai@3.3.4: - resolution: {integrity: sha512-yb9ONWAnTq77J+O/fLtd+yvcTgasdN79k+U0IhBDJ6ssEc+HZeFldjqkSgr1jtKSc8rLZOu0GiVitwyAtwofNQ==} + ai@3.4.9: + resolution: {integrity: sha512-wmVzpIHNGjCEjIJ/3945a/DIkz+gwObjC767ZRgO8AmtIZMO5KqvqNr7n2KF+gQrCPCMC8fM1ICQFXSvBZnBlA==} engines: {node: '>=18'} peerDependencies: openai: ^4.42.0 @@ -2066,8 +2119,9 @@ packages: resolution: {integrity: sha512-y+CcFFwelSXpLZk/7fMB2mUbGtX9lKycf1MWJ7CaTIERyitVlyQx6C+sxcROU2BAJ24OiZyK+8wj2i8AlBoS3A==} engines: {node: '>=10'} - aria-query@5.3.0: - resolution: {integrity: sha512-b0P0sZPKtyu8HkeRAfCq0IfURZK+SuwMjY1UXGBU27wpAiTwQAIlq56IbIO+ytk/JjS1fMR14ee5WBBfKi5J6A==} + aria-query@5.3.2: + resolution: {integrity: sha512-COROpnaoap1E2F000S62r6A60uHZnmlvomhfyT2DlTcrY1OrBKn2UhH7qn5wTC9zMvD0AY7csdPSNwKP+7WiQw==} + engines: {node: '>= 0.4'} array-flatten@1.1.1: resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==} @@ -2097,8 +2151,9 @@ packages: resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==} engines: {node: '>= 0.4'} - axobject-query@4.0.0: - resolution: {integrity: sha512-+60uv1hiVFhHZeO+Lz0RYzsVHy5Wr1ayX0mwda9KPDVLNJgZ1T9Ny7VmFbLDzxsH0D87I86vgj3gFrjTJUYznw==} + axobject-query@4.1.0: + resolution: {integrity: sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ==} + engines: {node: '>= 0.4'} bail@2.0.2: resolution: {integrity: sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw==} @@ -2137,6 +2192,10 @@ packages: resolution: {integrity: sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==} engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} + body-parser@1.20.3: + resolution: {integrity: sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==} + engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} + brace-expansion@1.1.11: resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} @@ -2374,6 +2433,10 @@ packages: resolution: {integrity: sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==} engines: {node: '>= 0.6'} + cookie@0.7.1: + resolution: {integrity: sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w==} + engines: {node: '>= 0.6'} + core-util-is@1.0.3: resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} @@ -2567,6 +2630,10 @@ packages: resolution: {integrity: sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==} engines: {node: '>= 0.8'} + encodeurl@2.0.0: + resolution: {integrity: sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==} + engines: {node: '>= 0.8'} + end-of-stream@1.4.4: resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} @@ -2774,6 +2841,10 @@ packages: resolution: {integrity: sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==} engines: {node: '>= 0.10.0'} + express@4.21.1: + resolution: {integrity: sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==} + engines: {node: '>= 0.10.0'} + extend@3.0.2: resolution: {integrity: sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==} @@ -2815,6 +2886,10 @@ packages: resolution: {integrity: sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==} engines: {node: '>= 0.8'} + finalhandler@1.3.1: + resolution: {integrity: sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==} + engines: {node: '>= 0.8'} + find-up@5.0.0: resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} engines: {node: '>=10'} @@ -3084,8 +3159,8 @@ packages: resolution: {integrity: sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==} engines: {node: '>= 4'} - immutable@4.3.6: - resolution: {integrity: sha512-Ju0+lEMyzMVZarkTn/gqRpdqd5dOPaz1mCZ0SH3JV6iFw81PldE/PEB1hWVEA288HPt4WXW8O7AWxB10M+03QQ==} + immutable@4.3.7: + resolution: {integrity: sha512-1hqclzwYwjRDFLjcFxOM5AYkkG0rpFPpr1RLPMEuGczoS7YA8gLhy8SWXYRAA/XwfEHpfo3cw5JGioS32fnMRw==} import-fresh@3.3.0: resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==} @@ -3375,6 +3450,9 @@ packages: magic-string@0.30.10: resolution: {integrity: sha512-iIRwTIf0QKV3UAnYK4PU8uiEc4SRh5jX0mwpIwETPpHdhVM4f53RSwS/vXvN1JhGX+Cs7B8qIq3d6AH49O5fAQ==} + magic-string@0.30.12: + resolution: {integrity: sha512-Ea8I3sQMVXr8JhN4z+H/d8zwo+tYDgHE9+5G4Wnrwhs0gaK9fXTKx0Tw5Xwsd/bCPTTZNRAdpyzvoeORe9LYpw==} + markdown-extensions@1.1.1: resolution: {integrity: sha512-WWC0ZuMzCyDHYCasEGs4IPvLyTGftYwh6wIEOULOF0HXcqZlhwRzrK0w2VUlxWA98xnvb/jszw4ZSkJ6ADpM6Q==} engines: {node: '>=0.10.0'} @@ -3476,6 +3554,9 @@ packages: merge-descriptors@1.0.1: resolution: {integrity: sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==} + merge-descriptors@1.0.3: + resolution: {integrity: sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==} + merge-stream@2.0.0: resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} @@ -3670,6 +3751,10 @@ packages: resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} engines: {node: '>= 0.6'} + mime-db@1.53.0: + resolution: {integrity: sha512-oHlN/w+3MQ3rba9rqFr6V/ypF10LSkdwUysQL7GkXoTgIWeV+tcXGA852TBxH+gsh8UWoyhR1hKcoMJTuWflpg==} + engines: {node: '>= 0.6'} + mime-types@2.1.35: resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} engines: {node: '>= 0.6'} @@ -3883,6 +3968,15 @@ packages: ofetch@1.3.4: resolution: {integrity: sha512-KLIET85ik3vhEfS+3fDlc/BAZiAp+43QEC/yCo5zkNoY2YaKvNkOaFr/6wCFgFH1kuYQM5pMNi0Tg8koiIemtw==} + ollama-ai-provider@0.15.2: + resolution: {integrity: sha512-bMDUlYmohulD87Xrv6meuftQdmFTygtrQywy6/gqdf1bTsJFP1VCx3MrisLFBzb4mMOj02NER7yZhiGIlAx30w==} + engines: {node: '>=18'} + peerDependencies: + zod: ^3.0.0 + peerDependenciesMeta: + zod: + optional: true + on-finished@2.3.0: resolution: {integrity: sha512-ikqdkGAAyf/X/gPhXGvfgAytDZtDbr+bkNUJ0N9h5MI/dmdgCs3l6hoHrcUv41sRKew3jIwrp4qQDXiK99Utww==} engines: {node: '>= 0.8'} @@ -3963,6 +4057,9 @@ packages: resolution: {integrity: sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==} engines: {node: '>= 0.8'} + partial-json@0.1.7: + resolution: {integrity: sha512-Njv/59hHaokb/hRUjce3Hdv12wd60MtM9Z5Olmn+nehe0QDAsRtRbJPvJ0Z91TusF0SuZRIvnM+S4l6EIP8leA==} + path-browserify@1.0.1: resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} @@ -3985,6 +4082,9 @@ packages: resolution: {integrity: sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==} engines: {node: '>=16 || 14 >=14.18'} + path-to-regexp@0.1.10: + resolution: {integrity: sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==} + path-to-regexp@0.1.7: resolution: {integrity: sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==} @@ -4182,6 +4282,10 @@ packages: resolution: {integrity: sha512-AWJm14H1vVaO/iNZ4/hO+HyaTehuy9nRqVdkTqlJt0HWvBiBIEXFmb4C0DGeYo3Xes9rrEW+TxHsaigCbN5ICQ==} engines: {node: '>=0.6'} + qs@6.13.0: + resolution: {integrity: sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==} + engines: {node: '>=0.6'} + querystring-es3@0.2.1: resolution: {integrity: sha512-773xhDQnZBMFobEiztv8LIl70ch5MSF/jUQVlhwFyBILqq96anmoctVIYz+ZRp0qbCKATTn6ev02M3r7Ga5vqA==} engines: {node: '>=0.4.x'} @@ -4467,10 +4571,18 @@ packages: resolution: {integrity: sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==} engines: {node: '>= 0.8.0'} + send@0.19.0: + resolution: {integrity: sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==} + engines: {node: '>= 0.8.0'} + serve-static@1.15.0: resolution: {integrity: sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==} engines: {node: '>= 0.8.0'} + serve-static@1.16.2: + resolution: {integrity: sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==} + engines: {node: '>= 0.8.0'} + set-cookie-parser@2.6.0: resolution: {integrity: sha512-RVnVQxTXuerk653XfuliOxBP81Sf0+qfQE73LIYKcyMYHG94AuH0kgrQpRDuTZnSmjpysHmzxJXKNfa6PjFhyQ==} @@ -4525,6 +4637,10 @@ packages: resolution: {integrity: sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==} engines: {node: '>=0.10.0'} + source-map-js@1.2.1: + resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} + engines: {node: '>=0.10.0'} + source-map-support@0.5.21: resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} @@ -4802,6 +4918,9 @@ packages: ufo@1.5.3: resolution: {integrity: sha512-Y7HYmWaFwPUmkoQCUIAYpKqkOf+SbVj/2fJJZ4RJMCfZp0rTGwRbzQD+HghfnhKOjL9E01okqz+ncJskGYfBNw==} + ufo@1.5.4: + resolution: {integrity: sha512-UsUk3byDzKd04EyoZ7U4DOlxQaD14JUKQl6/P7wiX4FNvUfm3XL246n9W5AmqwW5RSFJ27NAuM0iLscAOYUiGQ==} + unconfig@0.3.13: resolution: {integrity: sha512-N9Ph5NC4+sqtcOjPfHrRcHekBCadCXWTBzp2VYYbySOHW0PfD9XLCeXshTXjkPYwLrBr9AtSeU0CZmkYECJhng==} @@ -4816,6 +4935,10 @@ packages: resolution: {integrity: sha512-i3uaEUwNdkRq2qtTRRJb13moW5HWqviu7Vl7oYRYz++uPtGHJj+x7TGjcEuwS5Mt2P4nA0U9dhIX3DdB6JGY0g==} engines: {node: '>=18.17'} + undici@6.20.0: + resolution: {integrity: sha512-AITZfPuxubm31Sx0vr8bteSalEbs9wQb/BOBi9FPlD9Qpd6HxZ4Q0+hI742jBhkPb4RT2v5MQzaW5VhRVyj+9A==} + engines: {node: '>=18.17'} + unenv-nightly@1.10.0-1717606461.a117952: resolution: {integrity: sha512-u3TfBX02WzbHTpaEfWEKwDijDSFAHcgXkayUZ+MVDrjhLFvgAJzFGTSTmwlEhwWi2exyRQey23ah9wELMM6etg==} @@ -5183,10 +5306,10 @@ packages: youch@3.3.3: resolution: {integrity: sha512-qSFXUk3UZBLfggAW3dJKg0BMblG5biqSF8M34E06o5CSsZtH92u9Hqmj2RzGiHDi64fhe83+4tENFP2DB6t6ZA==} - zod-to-json-schema@3.22.5: - resolution: {integrity: sha512-+akaPo6a0zpVCCseDed504KBJUQpEW5QZw7RMneNmKw+fGaML1Z9tUNLnHHAC8x6dzVRO1eB2oEMyZRnuBZg7Q==} + zod-to-json-schema@3.23.2: + resolution: {integrity: sha512-uSt90Gzc/tUfyNqxnjlfBs8W6WSGpNBv0rVsNxP/BVSMHMKGdthPYff4xtCHYloJGM0CFxFsb3NbC0eqPhfImw==} peerDependencies: - zod: ^3.22.4 + zod: ^3.23.3 zod@3.23.8: resolution: {integrity: sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==} @@ -5202,6 +5325,21 @@ snapshots: '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) zod: 3.23.8 + '@ai-sdk/openai@0.0.66(zod@3.23.8)': + dependencies: + '@ai-sdk/provider': 0.0.24 + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + zod: 3.23.8 + + '@ai-sdk/provider-utils@1.0.20(zod@3.23.8)': + dependencies: + '@ai-sdk/provider': 0.0.24 + eventsource-parser: 1.1.2 + nanoid: 3.3.6 + secure-json-parse: 2.7.0 + optionalDependencies: + zod: 3.23.8 + '@ai-sdk/provider-utils@1.0.9(zod@3.23.8)': dependencies: '@ai-sdk/provider': 0.0.17 @@ -5215,44 +5353,50 @@ snapshots: dependencies: json-schema: 0.4.0 - '@ai-sdk/react@0.0.40(react@18.3.1)(zod@3.23.8)': + '@ai-sdk/provider@0.0.24': dependencies: - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.28(zod@3.23.8) + json-schema: 0.4.0 + + '@ai-sdk/react@0.0.62(react@18.3.1)(zod@3.23.8)': + dependencies: + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.46(zod@3.23.8) swr: 2.2.5(react@18.3.1) optionalDependencies: react: 18.3.1 zod: 3.23.8 - '@ai-sdk/solid@0.0.31(zod@3.23.8)': + '@ai-sdk/solid@0.0.49(zod@3.23.8)': dependencies: - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.28(zod@3.23.8) + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.46(zod@3.23.8) transitivePeerDependencies: - zod - '@ai-sdk/svelte@0.0.33(svelte@4.2.18)(zod@3.23.8)': + '@ai-sdk/svelte@0.0.51(svelte@4.2.18)(zod@3.23.8)': dependencies: - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.28(zod@3.23.8) + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.46(zod@3.23.8) sswr: 2.1.0(svelte@4.2.18) optionalDependencies: svelte: 4.2.18 transitivePeerDependencies: - zod - '@ai-sdk/ui-utils@0.0.28(zod@3.23.8)': + '@ai-sdk/ui-utils@0.0.46(zod@3.23.8)': dependencies: - '@ai-sdk/provider': 0.0.17 - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) + '@ai-sdk/provider': 0.0.24 + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + json-schema: 0.4.0 secure-json-parse: 2.7.0 + zod-to-json-schema: 3.23.2(zod@3.23.8) optionalDependencies: zod: 3.23.8 - '@ai-sdk/vue@0.0.32(vue@3.4.30(typescript@5.5.2))(zod@3.23.8)': + '@ai-sdk/vue@0.0.54(vue@3.4.30(typescript@5.5.2))(zod@3.23.8)': dependencies: - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.28(zod@3.23.8) + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.46(zod@3.23.8) swrv: 1.0.4(vue@3.4.30(typescript@5.5.2)) optionalDependencies: vue: 3.4.30(typescript@5.5.2) @@ -5405,8 +5549,12 @@ snapshots: '@babel/helper-string-parser@7.24.7': {} + '@babel/helper-string-parser@7.25.7': {} + '@babel/helper-validator-identifier@7.24.7': {} + '@babel/helper-validator-identifier@7.25.7': {} + '@babel/helper-validator-option@7.24.7': {} '@babel/helpers@7.24.7': @@ -5425,6 +5573,10 @@ snapshots: dependencies: '@babel/types': 7.24.7 + '@babel/parser@7.25.8': + dependencies: + '@babel/types': 7.25.8 + '@babel/plugin-syntax-decorators@7.24.7(@babel/core@7.24.7)': dependencies: '@babel/core': 7.24.7 @@ -5501,6 +5653,12 @@ snapshots: '@babel/helper-validator-identifier': 7.24.7 to-fast-properties: 2.0.0 + '@babel/types@7.25.8': + dependencies: + '@babel/helper-string-parser': 7.25.7 + '@babel/helper-validator-identifier': 7.25.7 + to-fast-properties: 2.0.0 + '@blitz/eslint-plugin@0.1.0(@types/eslint@8.56.10)(prettier@3.3.2)(typescript@5.5.2)': dependencies: '@stylistic/eslint-plugin-ts': 2.3.0(eslint@9.5.0)(typescript@5.5.2) @@ -5987,6 +6145,8 @@ snapshots: '@jridgewell/sourcemap-codec@1.4.15': {} + '@jridgewell/sourcemap-codec@1.5.0': {} + '@jridgewell/trace-mapping@0.3.25': dependencies: '@jridgewell/resolve-uri': 3.1.2 @@ -6482,10 +6642,10 @@ snapshots: - ts-node - utf-8-validate - '@remix-run/express@2.10.0(express@4.19.2)(typescript@5.5.2)': + '@remix-run/express@2.10.0(express@4.21.1)(typescript@5.5.2)': dependencies: '@remix-run/node': 2.10.0(typescript@5.5.2) - express: 4.19.2 + express: 4.21.1 optionalDependencies: typescript: 5.5.2 optional: true @@ -6510,7 +6670,7 @@ snapshots: cookie-signature: 1.2.1 source-map-support: 0.5.21 stream-slice: 0.1.2 - undici: 6.19.4 + undici: 6.20.0 optionalDependencies: typescript: 5.5.2 optional: true @@ -6533,11 +6693,11 @@ snapshots: '@remix-run/serve@2.10.0(typescript@5.5.2)': dependencies: - '@remix-run/express': 2.10.0(express@4.19.2)(typescript@5.5.2) + '@remix-run/express': 2.10.0(express@4.21.1)(typescript@5.5.2) '@remix-run/node': 2.10.0(typescript@5.5.2) chokidar: 3.6.0 compression: 1.7.4 - express: 4.19.2 + express: 4.21.1 get-port: 5.1.1 morgan: 1.10.0 source-map-support: 0.5.21 @@ -6709,6 +6869,8 @@ snapshots: '@types/estree@1.0.5': {} + '@types/estree@1.0.6': {} + '@types/hast@2.3.10': dependencies: '@types/unist': 2.0.10 @@ -7032,7 +7194,7 @@ snapshots: '@babel/plugin-syntax-typescript': 7.24.7(@babel/core@7.24.7) '@vanilla-extract/babel-plugin-debug-ids': 1.0.6 '@vanilla-extract/css': 1.15.3 - esbuild: 0.17.19 + esbuild: 0.17.6 eval: 0.1.8 find-up: 5.0.0 javascript-stringify: 2.1.0 @@ -7084,11 +7246,11 @@ snapshots: '@vue/compiler-core@3.4.30': dependencies: - '@babel/parser': 7.24.7 + '@babel/parser': 7.25.8 '@vue/shared': 3.4.30 entities: 4.5.0 estree-walker: 2.0.2 - source-map-js: 1.2.0 + source-map-js: 1.2.1 '@vue/compiler-dom@3.4.30': dependencies: @@ -7097,15 +7259,15 @@ snapshots: '@vue/compiler-sfc@3.4.30': dependencies: - '@babel/parser': 7.24.7 + '@babel/parser': 7.25.8 '@vue/compiler-core': 3.4.30 '@vue/compiler-dom': 3.4.30 '@vue/compiler-ssr': 3.4.30 '@vue/shared': 3.4.30 estree-walker: 2.0.2 - magic-string: 0.30.10 + magic-string: 0.30.12 postcss: 8.4.38 - source-map-js: 1.2.0 + source-map-js: 1.2.1 '@vue/compiler-ssr@3.4.30': dependencies: @@ -7172,27 +7334,29 @@ snapshots: acorn@8.12.0: {} + acorn@8.12.1: {} + aggregate-error@3.1.0: dependencies: clean-stack: 2.2.0 indent-string: 4.0.0 - ai@3.3.4(react@18.3.1)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.30(typescript@5.5.2))(zod@3.23.8): + ai@3.4.9(react@18.3.1)(sswr@2.1.0(svelte@4.2.18))(svelte@4.2.18)(vue@3.4.30(typescript@5.5.2))(zod@3.23.8): dependencies: - '@ai-sdk/provider': 0.0.17 - '@ai-sdk/provider-utils': 1.0.9(zod@3.23.8) - '@ai-sdk/react': 0.0.40(react@18.3.1)(zod@3.23.8) - '@ai-sdk/solid': 0.0.31(zod@3.23.8) - '@ai-sdk/svelte': 0.0.33(svelte@4.2.18)(zod@3.23.8) - '@ai-sdk/ui-utils': 0.0.28(zod@3.23.8) - '@ai-sdk/vue': 0.0.32(vue@3.4.30(typescript@5.5.2))(zod@3.23.8) + '@ai-sdk/provider': 0.0.24 + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + '@ai-sdk/react': 0.0.62(react@18.3.1)(zod@3.23.8) + '@ai-sdk/solid': 0.0.49(zod@3.23.8) + '@ai-sdk/svelte': 0.0.51(svelte@4.2.18)(zod@3.23.8) + '@ai-sdk/ui-utils': 0.0.46(zod@3.23.8) + '@ai-sdk/vue': 0.0.54(vue@3.4.30(typescript@5.5.2))(zod@3.23.8) '@opentelemetry/api': 1.9.0 eventsource-parser: 1.1.2 json-schema: 0.4.0 jsondiffpatch: 0.6.0 nanoid: 3.3.6 secure-json-parse: 2.7.0 - zod-to-json-schema: 3.22.5(zod@3.23.8) + zod-to-json-schema: 3.23.2(zod@3.23.8) optionalDependencies: react: 18.3.1 sswr: 2.1.0(svelte@4.2.18) @@ -7238,9 +7402,7 @@ snapshots: dependencies: tslib: 2.6.3 - aria-query@5.3.0: - dependencies: - dequal: 2.0.3 + aria-query@5.3.2: {} array-flatten@1.1.1: {} @@ -7272,9 +7434,7 @@ snapshots: dependencies: possible-typed-array-names: 1.0.0 - axobject-query@4.0.0: - dependencies: - dequal: 2.0.3 + axobject-query@4.1.0: {} bail@2.0.2: {} @@ -7322,6 +7482,24 @@ snapshots: transitivePeerDependencies: - supports-color + body-parser@1.20.3: + dependencies: + bytes: 3.1.2 + content-type: 1.0.5 + debug: 2.6.9 + depd: 2.0.0 + destroy: 1.2.0 + http-errors: 2.0.0 + iconv-lite: 0.4.24 + on-finished: 2.4.1 + qs: 6.13.0 + raw-body: 2.5.2 + type-is: 1.6.18 + unpipe: 1.0.0 + transitivePeerDependencies: + - supports-color + optional: true + brace-expansion@1.1.11: dependencies: balanced-match: 1.0.2 @@ -7520,9 +7698,9 @@ snapshots: code-red@1.0.4: dependencies: - '@jridgewell/sourcemap-codec': 1.4.15 - '@types/estree': 1.0.5 - acorn: 8.12.0 + '@jridgewell/sourcemap-codec': 1.5.0 + '@types/estree': 1.0.6 + acorn: 8.12.1 estree-walker: 3.0.3 periscopic: 3.1.0 @@ -7546,7 +7724,7 @@ snapshots: compressible@2.0.18: dependencies: - mime-db: 1.52.0 + mime-db: 1.53.0 optional: true compression@1.7.4: @@ -7588,6 +7766,9 @@ snapshots: cookie@0.6.0: {} + cookie@0.7.1: + optional: true + core-util-is@1.0.3: {} create-ecdh@4.0.4: @@ -7769,6 +7950,9 @@ snapshots: encodeurl@1.0.2: {} + encodeurl@2.0.0: + optional: true + end-of-stream@1.4.4: dependencies: once: 1.4.0 @@ -8099,6 +8283,43 @@ snapshots: transitivePeerDependencies: - supports-color + express@4.21.1: + dependencies: + accepts: 1.3.8 + array-flatten: 1.1.1 + body-parser: 1.20.3 + content-disposition: 0.5.4 + content-type: 1.0.5 + cookie: 0.7.1 + cookie-signature: 1.0.6 + debug: 2.6.9 + depd: 2.0.0 + encodeurl: 2.0.0 + escape-html: 1.0.3 + etag: 1.8.1 + finalhandler: 1.3.1 + fresh: 0.5.2 + http-errors: 2.0.0 + merge-descriptors: 1.0.3 + methods: 1.1.2 + on-finished: 2.4.1 + parseurl: 1.3.3 + path-to-regexp: 0.1.10 + proxy-addr: 2.0.7 + qs: 6.13.0 + range-parser: 1.2.1 + safe-buffer: 5.2.1 + send: 0.19.0 + serve-static: 1.16.2 + setprototypeof: 1.2.0 + statuses: 2.0.1 + type-is: 1.6.18 + utils-merge: 1.0.1 + vary: 1.1.2 + transitivePeerDependencies: + - supports-color + optional: true + extend@3.0.2: {} fast-deep-equal@3.1.3: {} @@ -8150,6 +8371,19 @@ snapshots: transitivePeerDependencies: - supports-color + finalhandler@1.3.1: + dependencies: + debug: 2.6.9 + encodeurl: 2.0.0 + escape-html: 1.0.3 + on-finished: 2.4.1 + parseurl: 1.3.3 + statuses: 2.0.1 + unpipe: 1.0.0 + transitivePeerDependencies: + - supports-color + optional: true + find-up@5.0.0: dependencies: locate-path: 6.0.0 @@ -8472,7 +8706,7 @@ snapshots: ignore@5.3.1: {} - immutable@4.3.6: + immutable@4.3.7: optional: true import-fresh@3.3.0: @@ -8707,6 +8941,10 @@ snapshots: dependencies: '@jridgewell/sourcemap-codec': 1.4.15 + magic-string@0.30.12: + dependencies: + '@jridgewell/sourcemap-codec': 1.5.0 + markdown-extensions@1.1.1: {} markdown-table@3.0.3: {} @@ -8987,6 +9225,9 @@ snapshots: merge-descriptors@1.0.1: {} + merge-descriptors@1.0.3: + optional: true + merge-stream@2.0.0: {} merge2@1.4.1: {} @@ -9409,6 +9650,9 @@ snapshots: mime-db@1.52.0: {} + mime-db@1.53.0: + optional: true + mime-types@2.1.35: dependencies: mime-db: 1.52.0 @@ -9632,6 +9876,14 @@ snapshots: node-fetch-native: 1.6.4 ufo: 1.5.3 + ollama-ai-provider@0.15.2(zod@3.23.8): + dependencies: + '@ai-sdk/provider': 0.0.24 + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + partial-json: 0.1.7 + optionalDependencies: + zod: 3.23.8 + on-finished@2.3.0: dependencies: ee-first: 1.1.1 @@ -9731,6 +9983,8 @@ snapshots: parseurl@1.3.3: {} + partial-json@0.1.7: {} + path-browserify@1.0.1: {} path-exists@4.0.0: {} @@ -9746,6 +10000,9 @@ snapshots: lru-cache: 10.2.2 minipass: 7.1.2 + path-to-regexp@0.1.10: + optional: true + path-to-regexp@0.1.7: {} path-to-regexp@6.2.2: {} @@ -9932,6 +10189,11 @@ snapshots: dependencies: side-channel: 1.0.6 + qs@6.13.0: + dependencies: + side-channel: 1.0.6 + optional: true + querystring-es3@0.2.1: {} queue-microtask@1.2.3: {} @@ -10241,8 +10503,8 @@ snapshots: sass@1.77.6: dependencies: chokidar: 3.6.0 - immutable: 4.3.6 - source-map-js: 1.2.0 + immutable: 4.3.7 + source-map-js: 1.2.1 optional: true scheduler@0.23.2: @@ -10278,6 +10540,25 @@ snapshots: transitivePeerDependencies: - supports-color + send@0.19.0: + dependencies: + debug: 2.6.9 + depd: 2.0.0 + destroy: 1.2.0 + encodeurl: 1.0.2 + escape-html: 1.0.3 + etag: 1.8.1 + fresh: 0.5.2 + http-errors: 2.0.0 + mime: 1.6.0 + ms: 2.1.3 + on-finished: 2.4.1 + range-parser: 1.2.1 + statuses: 2.0.1 + transitivePeerDependencies: + - supports-color + optional: true + serve-static@1.15.0: dependencies: encodeurl: 1.0.2 @@ -10287,6 +10568,16 @@ snapshots: transitivePeerDependencies: - supports-color + serve-static@1.16.2: + dependencies: + encodeurl: 2.0.0 + escape-html: 1.0.3 + parseurl: 1.3.3 + send: 0.19.0 + transitivePeerDependencies: + - supports-color + optional: true + set-cookie-parser@2.6.0: {} set-function-length@1.2.2: @@ -10340,6 +10631,8 @@ snapshots: source-map-js@1.2.0: {} + source-map-js@1.2.1: {} + source-map-support@0.5.21: dependencies: buffer-from: 1.1.2 @@ -10471,18 +10764,18 @@ snapshots: svelte@4.2.18: dependencies: '@ampproject/remapping': 2.3.0 - '@jridgewell/sourcemap-codec': 1.4.15 + '@jridgewell/sourcemap-codec': 1.5.0 '@jridgewell/trace-mapping': 0.3.25 - '@types/estree': 1.0.5 - acorn: 8.12.0 - aria-query: 5.3.0 - axobject-query: 4.0.0 + '@types/estree': 1.0.6 + acorn: 8.12.1 + aria-query: 5.3.2 + axobject-query: 4.1.0 code-red: 1.0.4 css-tree: 2.3.1 estree-walker: 3.0.3 is-reference: 3.0.2 locate-character: 3.0.0 - magic-string: 0.30.10 + magic-string: 0.30.12 periscopic: 3.1.0 swr@2.2.5(react@18.3.1): @@ -10613,6 +10906,8 @@ snapshots: ufo@1.5.3: {} + ufo@1.5.4: {} + unconfig@0.3.13: dependencies: '@antfu/utils': 0.7.10 @@ -10627,6 +10922,9 @@ snapshots: undici@6.19.4: {} + undici@6.20.0: + optional: true + unenv-nightly@1.10.0-1717606461.a117952: dependencies: consola: 3.2.3 @@ -10634,7 +10932,7 @@ snapshots: mime: 3.0.0 node-fetch-native: 1.6.4 pathe: 1.1.2 - ufo: 1.5.3 + ufo: 1.5.4 unified@10.1.2: dependencies: @@ -11070,7 +11368,7 @@ snapshots: mustache: 4.2.0 stacktracey: 2.1.8 - zod-to-json-schema@3.22.5(zod@3.23.8): + zod-to-json-schema@3.23.2(zod@3.23.8): dependencies: zod: 3.23.8 diff --git a/worker-configuration.d.ts b/worker-configuration.d.ts index 606a4e521..28877fd95 100644 --- a/worker-configuration.d.ts +++ b/worker-configuration.d.ts @@ -1,3 +1,5 @@ interface Env { ANTHROPIC_API_KEY: string; + OPENAI_API_KEY: string; + GROQ_API_KEY: string; } From 4f7a06f56a0090131e24e8305f785032ea8afe1f Mon Sep 17 00:00:00 2001 From: Cole Medin <47287758+coleam00@users.noreply.github.com> Date: Mon, 14 Oct 2024 19:40:21 -0500 Subject: [PATCH 2/4] Added the OpenRouter provider and a few models from OpenRouter (easily extendable to include more!) --- .env.example | 5 ++++ app/lib/.server/llm/api-key.ts | 2 ++ app/lib/.server/llm/model.ts | 11 +++++++++ app/utils/constants.ts | 6 +++++ package.json | 1 + pnpm-lock.yaml | 45 ++++++++++++++++++++++++++++++++-- worker-configuration.d.ts | 1 + 7 files changed, 69 insertions(+), 2 deletions(-) diff --git a/.env.example b/.env.example index e411dcee0..22bdcc185 100644 --- a/.env.example +++ b/.env.example @@ -15,5 +15,10 @@ OPENAI_API_KEY= # You only need this environment variable set if you want to use Claude models ANTHROPIC_API_KEY= +# Get your OpenRouter API Key in your account settings - +# https://openrouter.ai/settings/keys +# You only need this environment variable set if you want to use OpenRouter models +OPEN_ROUTER_API_KEY= + # Include this environment variable if you want more logging for debugging locally VITE_LOG_LEVEL=debug \ No newline at end of file diff --git a/app/lib/.server/llm/api-key.ts b/app/lib/.server/llm/api-key.ts index 8bc76856e..1f656cfaa 100644 --- a/app/lib/.server/llm/api-key.ts +++ b/app/lib/.server/llm/api-key.ts @@ -14,6 +14,8 @@ export function getAPIKey(cloudflareEnv: Env, provider: string) { return env.OPENAI_API_KEY || cloudflareEnv.OPENAI_API_KEY; case 'Groq': return env.GROQ_API_KEY || cloudflareEnv.GROQ_API_KEY; + case 'OpenRouter': + return env.OPEN_ROUTER_API_KEY || cloudflareEnv.OPEN_ROUTER_API_KEY; default: return ""; } diff --git a/app/lib/.server/llm/model.ts b/app/lib/.server/llm/model.ts index 0aaa37dc1..9b56a6dda 100644 --- a/app/lib/.server/llm/model.ts +++ b/app/lib/.server/llm/model.ts @@ -4,6 +4,7 @@ import { getAPIKey } from '~/lib/.server/llm/api-key'; import { createAnthropic } from '@ai-sdk/anthropic'; import { createOpenAI } from '@ai-sdk/openai'; import { ollama } from 'ollama-ai-provider'; +import { createOpenRouter } from "@openrouter/ai-sdk-provider"; export function getAnthropicModel(apiKey: string, model: string) { const anthropic = createAnthropic({ @@ -34,6 +35,14 @@ export function getOllamaModel(model: string) { return ollama(model); } +export function getOpenRouterModel(apiKey: string, model: string) { + const openRouter = createOpenRouter({ + apiKey + }); + + return openRouter.chat(model); +} + export function getModel(provider: string, model: string, env: Env) { const apiKey = getAPIKey(env, provider); @@ -44,6 +53,8 @@ export function getModel(provider: string, model: string, env: Env) { return getOpenAIModel(apiKey, model); case 'Groq': return getGroqModel(apiKey, model); + case 'OpenRouter': + return getOpenRouterModel(apiKey, model); default: return getOllamaModel(model); } diff --git a/app/utils/constants.ts b/app/utils/constants.ts index fbbe32678..4ff6a46f4 100644 --- a/app/utils/constants.ts +++ b/app/utils/constants.ts @@ -17,6 +17,12 @@ export const MODEL_LIST = [ { name: 'codellama:34b', label: 'Code Llama 34b', provider: 'Ollama' }, { name: 'codellama:13b', label: 'Code Llama 13b', provider: 'Ollama' }, { name: 'codellama:7b', label: 'Code Llama 7b', provider: 'Ollama' }, + { name: 'deepseek/deepseek-coder', label: 'Deepseek-Coder V2 236B (OpenRouter)', provider: 'OpenRouter' }, + { name: 'google/gemini-flash-1.5', label: 'Google Gemini Flash 1.5 (OpenRouter)', provider: 'OpenRouter' }, + { name: 'google/gemini-pro-1.5', label: 'Google Gemini Pro 1.5 (OpenRouter)', provider: 'OpenRouter' }, + { name: 'mistralai/mistral-nemo', label: 'OpenRouter Mistral Nemo (OpenRouter)', provider: 'OpenRouter' }, + { name: 'qwen/qwen-110b-chat', label: 'OpenRouter Qwen 110b Chat (OpenRouter)', provider: 'OpenRouter' }, + { name: 'cohere/command', label: 'Cohere Command (OpenRouter)', provider: 'OpenRouter' }, { name: 'llama-3.1-70b-versatile', label: 'Llama 3.1 70b (Groq)', provider: 'Groq' }, { name: 'llama-3.1-8b-instant', label: 'Llama 3.1 8b (Groq)', provider: 'Groq' }, { name: 'llama-3.2-11b-vision-preview', label: 'Llama 3.2 11b (Groq)', provider: 'Groq' }, diff --git a/package.json b/package.json index cb712276b..6cc49c7e1 100644 --- a/package.json +++ b/package.json @@ -44,6 +44,7 @@ "@iconify-json/svg-spinners": "^1.1.2", "@lezer/highlight": "^1.2.0", "@nanostores/react": "^0.7.2", + "@openrouter/ai-sdk-provider": "^0.0.5", "@radix-ui/react-dialog": "^1.1.1", "@radix-ui/react-dropdown-menu": "^2.1.1", "@remix-run/cloudflare": "^2.10.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a7aea68a3..75f0b99cc 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -74,6 +74,9 @@ importers: '@nanostores/react': specifier: ^0.7.2 version: 0.7.2(nanostores@0.10.3)(react@18.3.1) + '@openrouter/ai-sdk-provider': + specifier: ^0.0.5 + version: 0.0.5(zod@3.23.8) '@radix-ui/react-dialog': specifier: ^1.1.1 version: 1.1.1(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -249,6 +252,15 @@ packages: peerDependencies: zod: ^3.0.0 + '@ai-sdk/provider-utils@1.0.2': + resolution: {integrity: sha512-57f6O4OFVNEpI8Z8o+K40tIB3YQiTw+VCql/qrAO9Utq7Ti1o6+X9tvm177DlZJL7ft0Rwzvgy48S9YhrEKgmA==} + engines: {node: '>=18'} + peerDependencies: + zod: ^3.0.0 + peerDependenciesMeta: + zod: + optional: true + '@ai-sdk/provider-utils@1.0.20': resolution: {integrity: sha512-ngg/RGpnA00eNOWEtXHenpX1MsM2QshQh4QJFjUfwcqHpM5kTfG7je7Rc3HcEDP+OkRVv2GF+X4fC1Vfcnl8Ow==} engines: {node: '>=18'} @@ -267,6 +279,10 @@ packages: zod: optional: true + '@ai-sdk/provider@0.0.12': + resolution: {integrity: sha512-oOwPQD8i2Ynpn22cur4sk26FW3mSy6t6/X/K1Ay2yGBKYiSpRyLfObhOrZEGsXDx+3euKy4nEZ193R36NM+tpQ==} + engines: {node: '>=18'} + '@ai-sdk/provider@0.0.17': resolution: {integrity: sha512-f9j+P5yYRkqKFHxvWae5FI0j6nqROPCoPnMkpc2hc2vC7vKjqzrxBJucD8rpSaUjqiBnY/QuRJ0QeV717Uz5tg==} engines: {node: '>=18'} @@ -1196,6 +1212,12 @@ packages: resolution: {integrity: sha512-gGq0NJkIGSwdbUt4yhdF8ZrmkGKVz9vAdVzpOfnom+V8PLSmSOVhZwbNvZZS1EYcJN5hzzKBxmmVVAInM6HQLg==} engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + '@openrouter/ai-sdk-provider@0.0.5': + resolution: {integrity: sha512-AfxXQhISpxQSeUjU/4jo9waM5GRNX6eIkfTFS9l7vHkD1TKDP81Y/dXrE0ttJeN/Kap3tPF3Jwh49me0gWwjSw==} + engines: {node: '>=18'} + peerDependencies: + zod: ^3.0.0 + '@opentelemetry/api@1.9.0': resolution: {integrity: sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg==} engines: {node: '>=8.0.0'} @@ -5331,6 +5353,15 @@ snapshots: '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) zod: 3.23.8 + '@ai-sdk/provider-utils@1.0.2(zod@3.23.8)': + dependencies: + '@ai-sdk/provider': 0.0.12 + eventsource-parser: 1.1.2 + nanoid: 3.3.6 + secure-json-parse: 2.7.0 + optionalDependencies: + zod: 3.23.8 + '@ai-sdk/provider-utils@1.0.20(zod@3.23.8)': dependencies: '@ai-sdk/provider': 0.0.24 @@ -5349,6 +5380,10 @@ snapshots: optionalDependencies: zod: 3.23.8 + '@ai-sdk/provider@0.0.12': + dependencies: + json-schema: 0.4.0 + '@ai-sdk/provider@0.0.17': dependencies: json-schema: 0.4.0 @@ -6288,6 +6323,12 @@ snapshots: dependencies: which: 3.0.1 + '@openrouter/ai-sdk-provider@0.0.5(zod@3.23.8)': + dependencies: + '@ai-sdk/provider': 0.0.12 + '@ai-sdk/provider-utils': 1.0.2(zod@3.23.8) + zod: 3.23.8 + '@opentelemetry/api@1.9.0': {} '@pkgjs/parseargs@0.11.0': @@ -7194,7 +7235,7 @@ snapshots: '@babel/plugin-syntax-typescript': 7.24.7(@babel/core@7.24.7) '@vanilla-extract/babel-plugin-debug-ids': 1.0.6 '@vanilla-extract/css': 1.15.3 - esbuild: 0.17.6 + esbuild: 0.17.19 eval: 0.1.8 find-up: 5.0.0 javascript-stringify: 2.1.0 @@ -9734,7 +9775,7 @@ snapshots: acorn: 8.12.0 pathe: 1.1.2 pkg-types: 1.1.1 - ufo: 1.5.3 + ufo: 1.5.4 modern-ahocorasick@1.0.1: {} diff --git a/worker-configuration.d.ts b/worker-configuration.d.ts index 28877fd95..41af21448 100644 --- a/worker-configuration.d.ts +++ b/worker-configuration.d.ts @@ -2,4 +2,5 @@ interface Env { ANTHROPIC_API_KEY: string; OPENAI_API_KEY: string; GROQ_API_KEY: string; + OPEN_ROUTER_API_KEY: string; } From d86eaa420e35696728f3b098b712d59cb6f9ac0a Mon Sep 17 00:00:00 2001 From: Maki Date: Thu, 17 Oct 2024 20:46:17 +0900 Subject: [PATCH 3/4] =?UTF-8?q?=F0=9F=9A=80=20[feat]=20Integrate=20Amazon?= =?UTF-8?q?=20Bedrock=20support?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add support for Amazon Bedrock models, including: - Implement AWS credentials retrieval for Bedrock - Add Bedrock model initialization and handling - Include Claude 3 models (Opus, Sonnet, Haiku) for Bedrock - Adjust token limits for Bedrock models - Update chat action to support model selection - Add @ai-sdk/amazon-bedrock dependency Key changes: - app/lib/.server/llm/api-key.ts: Add getAWSCredentials function - app/lib/.server/llm/constants.ts: Define MAX_TOKENS_BEDROCK - app/lib/.server/llm/model.ts: Implement getBedrockModel function - app/lib/.server/llm/stream-text.ts: Use Bedrock-specific token limit - app/routes/api.chat.ts: Update to support model selection - app/utils/constants.ts: Add Bedrock model options - package.json: Add @ai-sdk/amazon-bedrock dependency - pnpm-lock.yaml: Update with new dependencies --- app/lib/.server/llm/api-key.ts | 9 + app/lib/.server/llm/constants.ts | 1 + app/lib/.server/llm/model.ts | 18 +- app/lib/.server/llm/stream-text.ts | 8 +- app/routes/api.chat.ts | 4 +- app/utils/constants.ts | 6 +- package.json | 1 + pnpm-lock.yaml | 1042 ++++++++++++++++++++++++++++ 8 files changed, 1080 insertions(+), 9 deletions(-) diff --git a/app/lib/.server/llm/api-key.ts b/app/lib/.server/llm/api-key.ts index 1f656cfaa..c6228cc58 100644 --- a/app/lib/.server/llm/api-key.ts +++ b/app/lib/.server/llm/api-key.ts @@ -16,7 +16,16 @@ export function getAPIKey(cloudflareEnv: Env, provider: string) { return env.GROQ_API_KEY || cloudflareEnv.GROQ_API_KEY; case 'OpenRouter': return env.OPEN_ROUTER_API_KEY || cloudflareEnv.OPEN_ROUTER_API_KEY; + // Bedrock用のAWSクレデンシャルは別途取得 default: return ""; } } + +export function getAWSCredentials(cloudflareEnv: Env) { + return { + accessKeyId: env.AWS_ACCESS_KEY_ID || cloudflareEnv.AWS_ACCESS_KEY_ID, + secretAccessKey: env.AWS_SECRET_ACCESS_KEY || cloudflareEnv.AWS_SECRET_ACCESS_KEY, + region: env.AWS_REGION || cloudflareEnv.AWS_REGION || 'us-east-1', // デフォルトリージョン + }; +} diff --git a/app/lib/.server/llm/constants.ts b/app/lib/.server/llm/constants.ts index b24acdf27..53f9b124b 100644 --- a/app/lib/.server/llm/constants.ts +++ b/app/lib/.server/llm/constants.ts @@ -1,5 +1,6 @@ // see https://docs.anthropic.com/en/docs/about-claude/models export const MAX_TOKENS = 8192; +export const MAX_TOKENS_BEDROCK = 4096; // limits the number of model responses that can be returned in a single request export const MAX_RESPONSE_SEGMENTS = 2; diff --git a/app/lib/.server/llm/model.ts b/app/lib/.server/llm/model.ts index 9b56a6dda..74795927d 100644 --- a/app/lib/.server/llm/model.ts +++ b/app/lib/.server/llm/model.ts @@ -1,8 +1,9 @@ // @ts-nocheck // Preventing TS checks with files presented in the video for a better presentation. -import { getAPIKey } from '~/lib/.server/llm/api-key'; +import { getAPIKey, getAWSCredentials } from '~/lib/.server/llm/api-key'; import { createAnthropic } from '@ai-sdk/anthropic'; import { createOpenAI } from '@ai-sdk/openai'; +import { createAmazonBedrock } from '@ai-sdk/amazon-bedrock'; import { ollama } from 'ollama-ai-provider'; import { createOpenRouter } from "@openrouter/ai-sdk-provider"; @@ -43,7 +44,22 @@ export function getOpenRouterModel(apiKey: string, model: string) { return openRouter.chat(model); } +export function getBedrockModel(modelId: string, credentials: any) { + const bedrock = createAmazonBedrock({ + region: credentials.region, + accessKeyId: credentials.accessKeyId, + secretAccessKey: credentials.secretAccessKey, + }); + + return bedrock(modelId); +} + export function getModel(provider: string, model: string, env: Env) { + if (provider === 'Bedrock') { + const credentials = getAWSCredentials(env); + return getBedrockModel(model, credentials); + } + const apiKey = getAPIKey(env, provider); switch (provider) { diff --git a/app/lib/.server/llm/stream-text.ts b/app/lib/.server/llm/stream-text.ts index de3d5bfa8..2c3909818 100644 --- a/app/lib/.server/llm/stream-text.ts +++ b/app/lib/.server/llm/stream-text.ts @@ -2,7 +2,7 @@ // Preventing TS checks with files presented in the video for a better presentation. import { streamText as _streamText, convertToCoreMessages } from 'ai'; import { getModel } from '~/lib/.server/llm/model'; -import { MAX_TOKENS } from './constants'; +import { MAX_TOKENS, MAX_TOKENS_BEDROCK } from './constants'; import { getSystemPrompt } from './prompts'; import { MODEL_LIST, DEFAULT_MODEL, DEFAULT_PROVIDER } from '~/utils/constants'; @@ -52,14 +52,12 @@ export function streamText(messages: Messages, env: Env, options?: StreamingOpti }); const provider = MODEL_LIST.find((model) => model.name === currentModel)?.provider || DEFAULT_PROVIDER; + const maxTokens = provider === 'Bedrock' ? MAX_TOKENS_BEDROCK : MAX_TOKENS; return _streamText({ model: getModel(provider, currentModel, env), system: getSystemPrompt(), - maxTokens: MAX_TOKENS, - // headers: { - // 'anthropic-beta': 'max-tokens-3-5-sonnet-2024-07-15', - // }, + maxTokens, messages: convertToCoreMessages(processedMessages), ...options, }); diff --git a/app/routes/api.chat.ts b/app/routes/api.chat.ts index c455c193d..292c84692 100644 --- a/app/routes/api.chat.ts +++ b/app/routes/api.chat.ts @@ -11,7 +11,7 @@ export async function action(args: ActionFunctionArgs) { } async function chatAction({ context, request }: ActionFunctionArgs) { - const { messages } = await request.json<{ messages: Messages }>(); + const { messages, selectedModel } = await request.json<{ messages: Messages; selectedModel?: string }>(); const stream = new SwitchableStream(); @@ -47,7 +47,7 @@ async function chatAction({ context, request }: ActionFunctionArgs) { return new Response(stream.readable, { status: 200, headers: { - contentType: 'text/plain; charset=utf-8', + 'Content-Type': 'text/plain; charset=utf-8', }, }); } catch (error) { diff --git a/app/utils/constants.ts b/app/utils/constants.ts index 4ff6a46f4..45e4071f7 100644 --- a/app/utils/constants.ts +++ b/app/utils/constants.ts @@ -35,4 +35,8 @@ export const MODEL_LIST = [ { name: 'gpt-4-turbo', label: 'GPT-4 Turbo', provider: 'OpenAI' }, { name: 'gpt-4', label: 'GPT-4', provider: 'OpenAI' }, { name: 'gpt-3.5-turbo', label: 'GPT-3.5 Turbo', provider: 'OpenAI' }, -]; \ No newline at end of file + { name: 'anthropic.claude-3-5-sonnet-20240620-v1:0', label: 'Claude 3.5 Sonnet (Bedrock)', provider: 'Bedrock' }, + { name: 'anthropic.claude-3-opus-20240229-v1:0', label: 'Claude 3 Opus (Bedrock)', provider: 'Bedrock' }, + { name: 'anthropic.claude-3-sonnet-20240229-v1:0', label: 'Claude 3 Sonnet (Bedrock)', provider: 'Bedrock' }, + { name: 'anthropic.claude-3-haiku-20240307-v1:0', label: 'Claude 3 Haiku (Bedrock)', provider: 'Bedrock' }, +]; diff --git a/package.json b/package.json index 6cc49c7e1..3d79aae48 100644 --- a/package.json +++ b/package.json @@ -23,6 +23,7 @@ "node": ">=18.18.0" }, "dependencies": { + "@ai-sdk/amazon-bedrock": "^0.0.30", "@ai-sdk/anthropic": "^0.0.39", "@ai-sdk/openai": "^0.0.66", "@codemirror/autocomplete": "^6.17.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 75f0b99cc..5ecbcc74e 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -11,6 +11,9 @@ importers: .: dependencies: + '@ai-sdk/amazon-bedrock': + specifier: ^0.0.30 + version: 0.0.30(zod@3.23.8) '@ai-sdk/anthropic': specifier: ^0.0.39 version: 0.0.39(zod@3.23.8) @@ -240,6 +243,12 @@ importers: packages: + '@ai-sdk/amazon-bedrock@0.0.30': + resolution: {integrity: sha512-LFo9hJBQXkOVYIxjWG0BFAbesURdTIfaCFD0k/JnhhguvhoDbTdceIPSl2ckL47nwErgNevDVHfgJI9kbvICKA==} + engines: {node: '>=18'} + peerDependencies: + zod: ^3.0.0 + '@ai-sdk/anthropic@0.0.39': resolution: {integrity: sha512-Ouku41O9ebyRi0EUW7pB8+lk4sI74SfJKydzK7FjynhNmCSvi42+U4WPlEjP64NluXUzpkYLvBa6BAd36VY4/g==} engines: {node: '>=18'} @@ -349,6 +358,127 @@ packages: '@antfu/utils@0.7.10': resolution: {integrity: sha512-+562v9k4aI80m1+VuMHehNJWLOFjBnXn3tdOitzD0il5b7smkSBal4+a3oKiQTbrwMmN/TBUMDvbdoWDehgOww==} + '@aws-crypto/crc32@5.2.0': + resolution: {integrity: sha512-nLbCWqQNgUiwwtFsen1AdzAtvuLRsQS8rYgMuxCrdKf9kOssamGLuPwyTY9wyYblNr9+1XM8v6zoDTPPSIeANg==} + engines: {node: '>=16.0.0'} + + '@aws-crypto/sha256-browser@5.2.0': + resolution: {integrity: sha512-AXfN/lGotSQwu6HNcEsIASo7kWXZ5HYWvfOmSNKDsEqC4OashTp8alTmaz+F7TC2L083SFv5RdB+qU3Vs1kZqw==} + + '@aws-crypto/sha256-js@5.2.0': + resolution: {integrity: sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA==} + engines: {node: '>=16.0.0'} + + '@aws-crypto/supports-web-crypto@5.2.0': + resolution: {integrity: sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg==} + + '@aws-crypto/util@5.2.0': + resolution: {integrity: sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ==} + + '@aws-sdk/client-bedrock-runtime@3.670.0': + resolution: {integrity: sha512-kDtXgyypCWc2cV8LJC0UXxlDWPBcs42b+NB1HiUn1U/jmPtDjPnIxnneRTnfJKZ03M3K2Ew20BOcpgXUXSZiiw==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/client-sso-oidc@3.670.0': + resolution: {integrity: sha512-4qDK2L36Q4J1lfemaHHd9ZxqKRaos3STp44qPAHf/8QyX6Uk5sXgZNVO2yWM7SIEtVKwwBh/fZAsdBkGPBfZcw==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sts': ^3.670.0 + + '@aws-sdk/client-sso@3.670.0': + resolution: {integrity: sha512-J+oz6uSsDvk4pimMDnKJb1wsV216zTrejvMTIL4RhUD1QPIVVOpteTdUShcjZUIZnkcJZGI+cym/SFK0kuzTpg==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/client-sts@3.670.0': + resolution: {integrity: sha512-bExrNo8ZVWorS3cjMZKQnA2HWqDmAzcZoSN/cPVoPFNkHwdl1lzPxvcLzmhpIr48JHgKfybBjrbluDZfIYeEog==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/core@3.667.0': + resolution: {integrity: sha512-pMcDVI7Tmdsc8R3sDv0Omj/4iRParGY+uJtAfF669WnZfDfaBQaix2Mq7+Mu08vdjqO9K3gicFvjk9S1VLmOKA==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/credential-provider-env@3.667.0': + resolution: {integrity: sha512-zZbrkkaPc54WXm+QAnpuv0LPNfsts0HPPd+oCECGs7IQRaFsGj187cwvPg9RMWDFZqpm64MdBDoA8OQHsqzYCw==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/credential-provider-http@3.667.0': + resolution: {integrity: sha512-sjtybFfERZWiqTY7fswBxKQLvUkiCucOWyqh3IaPo/4nE1PXRnaZCVG0+kRBPrYIxWqiVwytvZzMJy8sVZcG0A==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/credential-provider-ini@3.670.0': + resolution: {integrity: sha512-TB1gacUj75leaTt2JsCTzygDSIk4ksv9uZoR7VenlgFPRktyOeT+fapwIVBeB2Qg7b9uxAY2K5XkKstDZyBEEw==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sts': ^3.670.0 + + '@aws-sdk/credential-provider-node@3.670.0': + resolution: {integrity: sha512-zwNrRYzubk4CaZ7zebeDhxsm8QtNWkbGKopZPOaZSnd5uqUGRcmx4ccVRngWUK68XDP44aEUWC8iU5Pc7btpHQ==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/credential-provider-process@3.667.0': + resolution: {integrity: sha512-HZHnvop32fKgsNHkdhVaul7UzQ25sEc0j9yqA4bjhtbk0ECl42kj3f1pJ+ZU/YD9ut8lMJs/vVqiOdNThVdeBw==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/credential-provider-sso@3.670.0': + resolution: {integrity: sha512-5PkA8BOy4q57Vhe9AESoHKZ7vjRbElNPKjXA4qC01xY+DitClRFz4O3B9sMzFp0PHlz9nDVSXXKgq0yzF/nAag==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/credential-provider-web-identity@3.667.0': + resolution: {integrity: sha512-t8CFlZMD/1p/8Cli3rvRiTJpjr/8BO64gw166AHgFZYSN2h95L2l1tcW0jpsc3PprA32nLg1iQVKYt4WGM4ugw==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sts': ^3.667.0 + + '@aws-sdk/middleware-host-header@3.667.0': + resolution: {integrity: sha512-Z7fIAMQnPegs7JjAQvlOeWXwpMRfegh5eCoIP6VLJIeR6DLfYKbP35JBtt98R6DXslrN2RsbTogjbxPEDQfw1w==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/middleware-logger@3.667.0': + resolution: {integrity: sha512-PtTRNpNm/5c746jRgZCNg4X9xEJIwggkGJrF0GP9AB1ANg4pc/sF2Fvn1NtqPe9wtQ2stunJprnm5WkCHN7QiA==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/middleware-recursion-detection@3.667.0': + resolution: {integrity: sha512-U5glWD3ehFohzpUpopLtmqAlDurGWo2wRGPNgi4SwhWU7UDt6LS7E/UvJjqC0CUrjlzOw+my2A+Ncf+fisMhxQ==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/middleware-user-agent@3.669.0': + resolution: {integrity: sha512-K8ScPi45zjJrj5Y2gRqVsvKKQCQbvQBfYGcBw9ZOx9TTavH80bOCBjWg/GFnvs4f37tqVc1wMN2oGvcTF6HveQ==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/region-config-resolver@3.667.0': + resolution: {integrity: sha512-iNr+JhhA902JMKHG9IwT9YdaEx6KGl6vjAL5BRNeOjfj4cZYMog6Lz/IlfOAltMtT0w88DAHDEFrBd2uO0l2eg==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/token-providers@3.667.0': + resolution: {integrity: sha512-ZecJlG8p6D4UTYlBHwOWX6nknVtw/OBJ3yPXTSajBjhUlj9lE2xvejI8gl4rqkyLXk7z3bki+KR4tATbMaM9yg==} + engines: {node: '>=16.0.0'} + peerDependencies: + '@aws-sdk/client-sso-oidc': ^3.667.0 + + '@aws-sdk/types@3.667.0': + resolution: {integrity: sha512-gYq0xCsqFfQaSL/yT1Gl1vIUjtsg7d7RhnUfsXaHt8xTxOKRTdH9GjbesBjXOzgOvB0W0vfssfreSNGFlOOMJg==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/util-endpoints@3.667.0': + resolution: {integrity: sha512-X22SYDAuQJWnkF1/q17pkX3nGw5XMD9YEUbmt87vUnRq7iyJ3JOpl6UKOBeUBaL838wA5yzdbinmCITJ/VZ1QA==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/util-locate-window@3.568.0': + resolution: {integrity: sha512-3nh4TINkXYr+H41QaPelCceEB2FXP3fxp93YZXB/kqJvX0U9j0N0Uk45gvsjmEPzG8XxkPEeLIfT2I1M7A6Lig==} + engines: {node: '>=16.0.0'} + + '@aws-sdk/util-user-agent-browser@3.670.0': + resolution: {integrity: sha512-iRynWWazqEcCKwGMcQcywKTDLdLvqts1Yx474U64I9OKQXXwhOwhXbF5CAPSRta86lkVNAVYJa/0Bsv45pNn1A==} + + '@aws-sdk/util-user-agent-node@3.669.0': + resolution: {integrity: sha512-9jxCYrgggy2xd44ZASqI7AMiRVaSiFp+06Kg8BQSU0ijKpBJlwcsqIS8pDT/n6LxuOw2eV5ipvM2C0r1iKzrGA==} + engines: {node: '>=16.0.0'} + peerDependencies: + aws-crt: '>=1.0.0' + peerDependenciesMeta: + aws-crt: + optional: true + '@babel/code-frame@7.24.7': resolution: {integrity: sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA==} engines: {node: '>=6.9.0'} @@ -1733,6 +1863,189 @@ packages: '@sinclair/typebox@0.27.8': resolution: {integrity: sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==} + '@smithy/abort-controller@3.1.5': + resolution: {integrity: sha512-DhNPnqTqPoG8aZ5dWkFOgsuY+i0GQ3CI6hMmvCoduNsnU9gUZWZBwGfDQsTTB7NvFPkom1df7jMIJWU90kuXXg==} + engines: {node: '>=16.0.0'} + + '@smithy/config-resolver@3.0.9': + resolution: {integrity: sha512-5d9oBf40qC7n2xUoHmntKLdqsyTMMo/r49+eqSIjJ73eDfEtljAxEhzIQ3bkgXJtR3xiv7YzMT/3FF3ORkjWdg==} + engines: {node: '>=16.0.0'} + + '@smithy/core@2.4.8': + resolution: {integrity: sha512-x4qWk7p/a4dcf7Vxb2MODIf4OIcqNbK182WxRvZ/3oKPrf/6Fdic5sSElhO1UtXpWKBazWfqg0ZEK9xN1DsuHA==} + engines: {node: '>=16.0.0'} + + '@smithy/credential-provider-imds@3.2.4': + resolution: {integrity: sha512-S9bb0EIokfYEuar4kEbLta+ivlKCWOCFsLZuilkNy9i0uEUEHSi47IFLPaxqqCl+0ftKmcOTHayY5nQhAuq7+w==} + engines: {node: '>=16.0.0'} + + '@smithy/eventstream-codec@3.1.6': + resolution: {integrity: sha512-SBiOYPBH+5wOyPS7lfI150ePfGLhnp/eTu5RnV9xvhGvRiKfnl6HzRK9wehBph+il8FxS9KTeadx7Rcmf1GLPQ==} + + '@smithy/eventstream-serde-browser@3.0.10': + resolution: {integrity: sha512-1i9aMY6Pl/SmA6NjvidxnfBLHMPzhKu2BP148pEt5VwhMdmXn36PE2kWKGa9Hj8b0XGtCTRucpCncylevCtI7g==} + engines: {node: '>=16.0.0'} + + '@smithy/eventstream-serde-config-resolver@3.0.7': + resolution: {integrity: sha512-eVzhGQBPEqXXYHvIUku0jMTxd4gDvenRzUQPTmKVWdRvp9JUCKrbAXGQRYiGxUYq9+cqQckRm0wq3kTWnNtDhw==} + engines: {node: '>=16.0.0'} + + '@smithy/eventstream-serde-node@3.0.9': + resolution: {integrity: sha512-JE0Guqvt0xsmfQ5y1EI342/qtJqznBv8cJqkHZV10PwC8GWGU5KNgFbQnsVCcX+xF+qIqwwfRmeWoJCjuOLmng==} + engines: {node: '>=16.0.0'} + + '@smithy/eventstream-serde-universal@3.0.9': + resolution: {integrity: sha512-bydfgSisfepCufw9kCEnWRxqxJFzX/o8ysXWv+W9F2FIyiaEwZ/D8bBKINbh4ONz3i05QJ1xE7A5OKYvgJsXaw==} + engines: {node: '>=16.0.0'} + + '@smithy/fetch-http-handler@3.2.9': + resolution: {integrity: sha512-hYNVQOqhFQ6vOpenifFME546f0GfJn2OiQ3M0FDmuUu8V/Uiwy2wej7ZXxFBNqdx0R5DZAqWM1l6VRhGz8oE6A==} + + '@smithy/hash-node@3.0.7': + resolution: {integrity: sha512-SAGHN+QkrwcHFjfWzs/czX94ZEjPJ0CrWJS3M43WswDXVEuP4AVy9gJ3+AF6JQHZD13bojmuf/Ap/ItDeZ+Qfw==} + engines: {node: '>=16.0.0'} + + '@smithy/invalid-dependency@3.0.7': + resolution: {integrity: sha512-Bq00GsAhHeYSuZX8Kpu4sbI9agH2BNYnqUmmbTGWOhki9NVsWn2jFr896vvoTMH8KAjNX/ErC/8t5QHuEXG+IA==} + + '@smithy/is-array-buffer@2.2.0': + resolution: {integrity: sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA==} + engines: {node: '>=14.0.0'} + + '@smithy/is-array-buffer@3.0.0': + resolution: {integrity: sha512-+Fsu6Q6C4RSJiy81Y8eApjEB5gVtM+oFKTffg+jSuwtvomJJrhUJBu2zS8wjXSgH/g1MKEWrzyChTBe6clb5FQ==} + engines: {node: '>=16.0.0'} + + '@smithy/middleware-content-length@3.0.9': + resolution: {integrity: sha512-t97PidoGElF9hTtLCrof32wfWMqC5g2SEJNxaVH3NjlatuNGsdxXRYO/t+RPnxA15RpYiS0f+zG7FuE2DeGgjA==} + engines: {node: '>=16.0.0'} + + '@smithy/middleware-endpoint@3.1.4': + resolution: {integrity: sha512-/ChcVHekAyzUbyPRI8CzPPLj6y8QRAfJngWcLMgsWxKVzw/RzBV69mSOzJYDD3pRwushA1+5tHtPF8fjmzBnrQ==} + engines: {node: '>=16.0.0'} + + '@smithy/middleware-retry@3.0.23': + resolution: {integrity: sha512-x9PbGXxkcXIpm6L26qRSCC+eaYcHwybRmqU8LO/WM2RRlW0g8lz6FIiKbKgGvHuoK3dLZRiQVSQJveiCzwnA5A==} + engines: {node: '>=16.0.0'} + + '@smithy/middleware-serde@3.0.7': + resolution: {integrity: sha512-VytaagsQqtH2OugzVTq4qvjkLNbWehHfGcGr0JLJmlDRrNCeZoWkWsSOw1nhS/4hyUUWF/TLGGml4X/OnEep5g==} + engines: {node: '>=16.0.0'} + + '@smithy/middleware-stack@3.0.7': + resolution: {integrity: sha512-EyTbMCdqS1DoeQsO4gI7z2Gzq1MoRFAeS8GkFYIwbedB7Lp5zlLHJdg+56tllIIG5Hnf9ZWX48YKSHlsKvugGA==} + engines: {node: '>=16.0.0'} + + '@smithy/node-config-provider@3.1.8': + resolution: {integrity: sha512-E0rU0DglpeJn5ge64mk8wTGEXcQwmpUTY5Zr7IzTpDLmHKiIamINERNZYrPQjg58Ck236sEKSwRSHA4CwshU6Q==} + engines: {node: '>=16.0.0'} + + '@smithy/node-http-handler@3.2.4': + resolution: {integrity: sha512-49reY3+JgLMFNm7uTAKBWiKCA6XSvkNp9FqhVmusm2jpVnHORYFeFZ704LShtqWfjZW/nhX+7Iexyb6zQfXYIQ==} + engines: {node: '>=16.0.0'} + + '@smithy/property-provider@3.1.7': + resolution: {integrity: sha512-QfzLi1GPMisY7bAM5hOUqBdGYnY5S2JAlr201pghksrQv139f8iiiMalXtjczIP5f6owxFn3MINLNUNvUkgtPw==} + engines: {node: '>=16.0.0'} + + '@smithy/protocol-http@4.1.4': + resolution: {integrity: sha512-MlWK8eqj0JlpZBnWmjQLqmFp71Ug00P+m72/1xQB3YByXD4zZ+y9N4hYrR0EDmrUCZIkyATWHOXFgtavwGDTzQ==} + engines: {node: '>=16.0.0'} + + '@smithy/querystring-builder@3.0.7': + resolution: {integrity: sha512-65RXGZZ20rzqqxTsChdqSpbhA6tdt5IFNgG6o7e1lnPVLCe6TNWQq4rTl4N87hTDD8mV4IxJJnvyE7brbnRkQw==} + engines: {node: '>=16.0.0'} + + '@smithy/querystring-parser@3.0.7': + resolution: {integrity: sha512-Fouw4KJVWqqUVIu1gZW8BH2HakwLz6dvdrAhXeXfeymOBrZw+hcqaWs+cS1AZPVp4nlbeIujYrKA921ZW2WMPA==} + engines: {node: '>=16.0.0'} + + '@smithy/service-error-classification@3.0.7': + resolution: {integrity: sha512-91PRkTfiBf9hxkIchhRKJfl1rsplRDyBnmyFca3y0Z3x/q0JJN480S83LBd8R6sBCkm2bBbqw2FHp0Mbh+ecSA==} + engines: {node: '>=16.0.0'} + + '@smithy/shared-ini-file-loader@3.1.8': + resolution: {integrity: sha512-0NHdQiSkeGl0ICQKcJQ2lCOKH23Nb0EaAa7RDRId6ZqwXkw4LJyIyZ0t3iusD4bnKYDPLGy2/5e2rfUhrt0Acw==} + engines: {node: '>=16.0.0'} + + '@smithy/signature-v4@4.2.0': + resolution: {integrity: sha512-LafbclHNKnsorMgUkKm7Tk7oJ7xizsZ1VwqhGKqoCIrXh4fqDDp73fK99HOEEgcsQbtemmeY/BPv0vTVYYUNEQ==} + engines: {node: '>=16.0.0'} + + '@smithy/smithy-client@3.4.0': + resolution: {integrity: sha512-nOfJ1nVQsxiP6srKt43r2My0Gp5PLWCW2ASqUioxIiGmu6d32v4Nekidiv5qOmmtzIrmaD+ADX5SKHUuhReeBQ==} + engines: {node: '>=16.0.0'} + + '@smithy/types@3.5.0': + resolution: {integrity: sha512-QN0twHNfe8mNJdH9unwsCK13GURU7oEAZqkBI+rsvpv1jrmserO+WnLE7jidR9W/1dxwZ0u/CB01mV2Gms/K2Q==} + engines: {node: '>=16.0.0'} + + '@smithy/url-parser@3.0.7': + resolution: {integrity: sha512-70UbSSR8J97c1rHZOWhl+VKiZDqHWxs/iW8ZHrHp5fCCPLSBE7GcUlUvKSle3Ca+J9LLbYCj/A79BxztBvAfpA==} + + '@smithy/util-base64@3.0.0': + resolution: {integrity: sha512-Kxvoh5Qtt0CDsfajiZOCpJxgtPHXOKwmM+Zy4waD43UoEMA+qPxxa98aE/7ZhdnBFZFXMOiBR5xbcaMhLtznQQ==} + engines: {node: '>=16.0.0'} + + '@smithy/util-body-length-browser@3.0.0': + resolution: {integrity: sha512-cbjJs2A1mLYmqmyVl80uoLTJhAcfzMOyPgjwAYusWKMdLeNtzmMz9YxNl3/jRLoxSS3wkqkf0jwNdtXWtyEBaQ==} + + '@smithy/util-body-length-node@3.0.0': + resolution: {integrity: sha512-Tj7pZ4bUloNUP6PzwhN7K386tmSmEET9QtQg0TgdNOnxhZvCssHji+oZTUIuzxECRfG8rdm2PMw2WCFs6eIYkA==} + engines: {node: '>=16.0.0'} + + '@smithy/util-buffer-from@2.2.0': + resolution: {integrity: sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA==} + engines: {node: '>=14.0.0'} + + '@smithy/util-buffer-from@3.0.0': + resolution: {integrity: sha512-aEOHCgq5RWFbP+UDPvPot26EJHjOC+bRgse5A8V3FSShqd5E5UN4qc7zkwsvJPPAVsf73QwYcHN1/gt/rtLwQA==} + engines: {node: '>=16.0.0'} + + '@smithy/util-config-provider@3.0.0': + resolution: {integrity: sha512-pbjk4s0fwq3Di/ANL+rCvJMKM5bzAQdE5S/6RL5NXgMExFAi6UgQMPOm5yPaIWPpr+EOXKXRonJ3FoxKf4mCJQ==} + engines: {node: '>=16.0.0'} + + '@smithy/util-defaults-mode-browser@3.0.23': + resolution: {integrity: sha512-Y07qslyRtXDP/C5aWKqxTPBl4YxplEELG3xRrz2dnAQ6Lq/FgNrcKWmV561nNaZmFH+EzeGOX3ZRMbU8p1T6Nw==} + engines: {node: '>= 10.0.0'} + + '@smithy/util-defaults-mode-node@3.0.23': + resolution: {integrity: sha512-9Y4WH7f0vnDGuHUa4lGX9e2p+sMwODibsceSV6rfkZOvMC+BY3StB2LdO1NHafpsyHJLpwAgChxQ38tFyd6vkg==} + engines: {node: '>= 10.0.0'} + + '@smithy/util-endpoints@2.1.3': + resolution: {integrity: sha512-34eACeKov6jZdHqS5hxBMJ4KyWKztTMulhuQ2UdOoP6vVxMLrOKUqIXAwJe/wiWMhXhydLW664B02CNpQBQ4Aw==} + engines: {node: '>=16.0.0'} + + '@smithy/util-hex-encoding@3.0.0': + resolution: {integrity: sha512-eFndh1WEK5YMUYvy3lPlVmYY/fZcQE1D8oSf41Id2vCeIkKJXPcYDCZD+4+xViI6b1XSd7tE+s5AmXzz5ilabQ==} + engines: {node: '>=16.0.0'} + + '@smithy/util-middleware@3.0.7': + resolution: {integrity: sha512-OVA6fv/3o7TMJTpTgOi1H5OTwnuUa8hzRzhSFDtZyNxi6OZ70L/FHattSmhE212I7b6WSOJAAmbYnvcjTHOJCA==} + engines: {node: '>=16.0.0'} + + '@smithy/util-retry@3.0.7': + resolution: {integrity: sha512-nh1ZO1vTeo2YX1plFPSe/OXaHkLAHza5jpokNiiKX2M5YpNUv6RxGJZhpfmiR4jSvVHCjIDmILjrxKmP+/Ghug==} + engines: {node: '>=16.0.0'} + + '@smithy/util-stream@3.1.9': + resolution: {integrity: sha512-7YAR0Ub3MwTMjDfjnup4qa6W8gygZMxikBhFMPESi6ASsl/rZJhwLpF/0k9TuezScCojsM0FryGdz4LZtjKPPQ==} + engines: {node: '>=16.0.0'} + + '@smithy/util-uri-escape@3.0.0': + resolution: {integrity: sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==} + engines: {node: '>=16.0.0'} + + '@smithy/util-utf8@2.3.0': + resolution: {integrity: sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A==} + engines: {node: '>=14.0.0'} + + '@smithy/util-utf8@3.0.0': + resolution: {integrity: sha512-rUeT12bxFnplYDe815GXbq/oixEGHfRFFtcTF3YdDi/JaENIM6aSYYLJydG83UNzLXeRI5K8abYd/8Sp/QM0kA==} + engines: {node: '>=16.0.0'} + '@stylistic/eslint-plugin-js@2.3.0': resolution: {integrity: sha512-lQwoiYb0Fs6Yc5QS3uT8+T9CPKK2Eoxc3H8EnYJgM26v/DgtW+1lvy2WNgyBflU+ThShZaHm3a6CdD9QeKx23w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} @@ -2218,6 +2531,9 @@ packages: resolution: {integrity: sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==} engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} + bowser@2.11.0: + resolution: {integrity: sha512-AlcaJBi/pqqJBIQ8U9Mcpc9i8Aqxn88Skv5d+xBX006BY5u8N3mGLHa5Lgppa7L/HfwgwLgZ6NYs+Ag6uUmJRA==} + brace-expansion@1.1.11: resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} @@ -2886,6 +3202,10 @@ packages: fast-levenshtein@2.0.6: resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} + fast-xml-parser@4.4.1: + resolution: {integrity: sha512-xkjOecfnKGkSsOwtZ5Pz7Us/T6mrbPQrq0nh+aCO5V9nk5NLWmasAHumTKjiPJPWANe+kAZ84Jc8ooJkzZ88Sw==} + hasBin: true + fastq@1.17.1: resolution: {integrity: sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==} @@ -4775,6 +5095,9 @@ packages: resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} engines: {node: '>=8'} + strnum@1.0.5: + resolution: {integrity: sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==} + style-mod@4.1.2: resolution: {integrity: sha512-wnD1HyVqpJUI2+eKZ+eo1UwghftP6yuFheBqqe+bWCotBjC2K1YnteJILRMs3SM4V/0dLEW1SC27MWP5y+mwmw==} @@ -5087,6 +5410,10 @@ packages: resolution: {integrity: sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==} engines: {node: '>= 0.4.0'} + uuid@9.0.1: + resolution: {integrity: sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==} + hasBin: true + uvu@0.5.6: resolution: {integrity: sha512-+g8ENReyr8YsOc6fv/NVJs2vFdHBnBNdfE49rshrTzDWOlUx4Gq7KOS2GD8eqhy2j+Ejq29+SbKH8yjkAqXqoA==} engines: {node: '>=8'} @@ -5341,6 +5668,15 @@ packages: snapshots: + '@ai-sdk/amazon-bedrock@0.0.30(zod@3.23.8)': + dependencies: + '@ai-sdk/provider': 0.0.24 + '@ai-sdk/provider-utils': 1.0.20(zod@3.23.8) + '@aws-sdk/client-bedrock-runtime': 3.670.0 + zod: 3.23.8 + transitivePeerDependencies: + - aws-crt + '@ai-sdk/anthropic@0.0.39(zod@3.23.8)': dependencies: '@ai-sdk/provider': 0.0.17 @@ -5450,6 +5786,405 @@ snapshots: '@antfu/utils@0.7.10': {} + '@aws-crypto/crc32@5.2.0': + dependencies: + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.667.0 + tslib: 2.6.3 + + '@aws-crypto/sha256-browser@5.2.0': + dependencies: + '@aws-crypto/sha256-js': 5.2.0 + '@aws-crypto/supports-web-crypto': 5.2.0 + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-locate-window': 3.568.0 + '@smithy/util-utf8': 2.3.0 + tslib: 2.6.3 + + '@aws-crypto/sha256-js@5.2.0': + dependencies: + '@aws-crypto/util': 5.2.0 + '@aws-sdk/types': 3.667.0 + tslib: 2.6.3 + + '@aws-crypto/supports-web-crypto@5.2.0': + dependencies: + tslib: 2.6.3 + + '@aws-crypto/util@5.2.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/util-utf8': 2.3.0 + tslib: 2.6.3 + + '@aws-sdk/client-bedrock-runtime@3.670.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/client-sso-oidc': 3.670.0(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/client-sts': 3.670.0 + '@aws-sdk/core': 3.667.0 + '@aws-sdk/credential-provider-node': 3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.669.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.670.0 + '@aws-sdk/util-user-agent-node': 3.669.0 + '@smithy/config-resolver': 3.0.9 + '@smithy/core': 2.4.8 + '@smithy/eventstream-serde-browser': 3.0.10 + '@smithy/eventstream-serde-config-resolver': 3.0.7 + '@smithy/eventstream-serde-node': 3.0.9 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.7 + '@smithy/invalid-dependency': 3.0.7 + '@smithy/middleware-content-length': 3.0.9 + '@smithy/middleware-endpoint': 3.1.4 + '@smithy/middleware-retry': 3.0.23 + '@smithy/middleware-serde': 3.0.7 + '@smithy/middleware-stack': 3.0.7 + '@smithy/node-config-provider': 3.1.8 + '@smithy/node-http-handler': 3.2.4 + '@smithy/protocol-http': 4.1.4 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/url-parser': 3.0.7 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.23 + '@smithy/util-defaults-mode-node': 3.0.23 + '@smithy/util-endpoints': 2.1.3 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-retry': 3.0.7 + '@smithy/util-stream': 3.1.9 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0)': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/client-sts': 3.670.0 + '@aws-sdk/core': 3.667.0 + '@aws-sdk/credential-provider-node': 3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.669.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.670.0 + '@aws-sdk/util-user-agent-node': 3.669.0 + '@smithy/config-resolver': 3.0.9 + '@smithy/core': 2.4.8 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.7 + '@smithy/invalid-dependency': 3.0.7 + '@smithy/middleware-content-length': 3.0.9 + '@smithy/middleware-endpoint': 3.1.4 + '@smithy/middleware-retry': 3.0.23 + '@smithy/middleware-serde': 3.0.7 + '@smithy/middleware-stack': 3.0.7 + '@smithy/node-config-provider': 3.1.8 + '@smithy/node-http-handler': 3.2.4 + '@smithy/protocol-http': 4.1.4 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/url-parser': 3.0.7 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.23 + '@smithy/util-defaults-mode-node': 3.0.23 + '@smithy/util-endpoints': 2.1.3 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-retry': 3.0.7 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/client-sso@3.670.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/core': 3.667.0 + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.669.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.670.0 + '@aws-sdk/util-user-agent-node': 3.669.0 + '@smithy/config-resolver': 3.0.9 + '@smithy/core': 2.4.8 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.7 + '@smithy/invalid-dependency': 3.0.7 + '@smithy/middleware-content-length': 3.0.9 + '@smithy/middleware-endpoint': 3.1.4 + '@smithy/middleware-retry': 3.0.23 + '@smithy/middleware-serde': 3.0.7 + '@smithy/middleware-stack': 3.0.7 + '@smithy/node-config-provider': 3.1.8 + '@smithy/node-http-handler': 3.2.4 + '@smithy/protocol-http': 4.1.4 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/url-parser': 3.0.7 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.23 + '@smithy/util-defaults-mode-node': 3.0.23 + '@smithy/util-endpoints': 2.1.3 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-retry': 3.0.7 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/client-sts@3.670.0': + dependencies: + '@aws-crypto/sha256-browser': 5.2.0 + '@aws-crypto/sha256-js': 5.2.0 + '@aws-sdk/client-sso-oidc': 3.670.0(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/core': 3.667.0 + '@aws-sdk/credential-provider-node': 3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/middleware-host-header': 3.667.0 + '@aws-sdk/middleware-logger': 3.667.0 + '@aws-sdk/middleware-recursion-detection': 3.667.0 + '@aws-sdk/middleware-user-agent': 3.669.0 + '@aws-sdk/region-config-resolver': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@aws-sdk/util-user-agent-browser': 3.670.0 + '@aws-sdk/util-user-agent-node': 3.669.0 + '@smithy/config-resolver': 3.0.9 + '@smithy/core': 2.4.8 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/hash-node': 3.0.7 + '@smithy/invalid-dependency': 3.0.7 + '@smithy/middleware-content-length': 3.0.9 + '@smithy/middleware-endpoint': 3.1.4 + '@smithy/middleware-retry': 3.0.23 + '@smithy/middleware-serde': 3.0.7 + '@smithy/middleware-stack': 3.0.7 + '@smithy/node-config-provider': 3.1.8 + '@smithy/node-http-handler': 3.2.4 + '@smithy/protocol-http': 4.1.4 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/url-parser': 3.0.7 + '@smithy/util-base64': 3.0.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-body-length-node': 3.0.0 + '@smithy/util-defaults-mode-browser': 3.0.23 + '@smithy/util-defaults-mode-node': 3.0.23 + '@smithy/util-endpoints': 2.1.3 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-retry': 3.0.7 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + transitivePeerDependencies: + - aws-crt + + '@aws-sdk/core@3.667.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/core': 2.4.8 + '@smithy/node-config-provider': 3.1.8 + '@smithy/property-provider': 3.1.7 + '@smithy/protocol-http': 4.1.4 + '@smithy/signature-v4': 4.2.0 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/util-middleware': 3.0.7 + fast-xml-parser: 4.4.1 + tslib: 2.6.3 + + '@aws-sdk/credential-provider-env@3.667.0': + dependencies: + '@aws-sdk/core': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.7 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/credential-provider-http@3.667.0': + dependencies: + '@aws-sdk/core': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/node-http-handler': 3.2.4 + '@smithy/property-provider': 3.1.7 + '@smithy/protocol-http': 4.1.4 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/util-stream': 3.1.9 + tslib: 2.6.3 + + '@aws-sdk/credential-provider-ini@3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))(@aws-sdk/client-sts@3.670.0)': + dependencies: + '@aws-sdk/client-sts': 3.670.0 + '@aws-sdk/core': 3.667.0 + '@aws-sdk/credential-provider-env': 3.667.0 + '@aws-sdk/credential-provider-http': 3.667.0 + '@aws-sdk/credential-provider-process': 3.667.0 + '@aws-sdk/credential-provider-sso': 3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0)) + '@aws-sdk/credential-provider-web-identity': 3.667.0(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/types': 3.667.0 + '@smithy/credential-provider-imds': 3.2.4 + '@smithy/property-provider': 3.1.7 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + transitivePeerDependencies: + - '@aws-sdk/client-sso-oidc' + - aws-crt + + '@aws-sdk/credential-provider-node@3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))(@aws-sdk/client-sts@3.670.0)': + dependencies: + '@aws-sdk/credential-provider-env': 3.667.0 + '@aws-sdk/credential-provider-http': 3.667.0 + '@aws-sdk/credential-provider-ini': 3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/credential-provider-process': 3.667.0 + '@aws-sdk/credential-provider-sso': 3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0)) + '@aws-sdk/credential-provider-web-identity': 3.667.0(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/types': 3.667.0 + '@smithy/credential-provider-imds': 3.2.4 + '@smithy/property-provider': 3.1.7 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + transitivePeerDependencies: + - '@aws-sdk/client-sso-oidc' + - '@aws-sdk/client-sts' + - aws-crt + + '@aws-sdk/credential-provider-process@3.667.0': + dependencies: + '@aws-sdk/core': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.7 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/credential-provider-sso@3.670.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))': + dependencies: + '@aws-sdk/client-sso': 3.670.0 + '@aws-sdk/core': 3.667.0 + '@aws-sdk/token-providers': 3.667.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0)) + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.7 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + transitivePeerDependencies: + - '@aws-sdk/client-sso-oidc' + - aws-crt + + '@aws-sdk/credential-provider-web-identity@3.667.0(@aws-sdk/client-sts@3.670.0)': + dependencies: + '@aws-sdk/client-sts': 3.670.0 + '@aws-sdk/core': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.7 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/middleware-host-header@3.667.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/protocol-http': 4.1.4 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/middleware-logger@3.667.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/middleware-recursion-detection@3.667.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/protocol-http': 4.1.4 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/middleware-user-agent@3.669.0': + dependencies: + '@aws-sdk/core': 3.667.0 + '@aws-sdk/types': 3.667.0 + '@aws-sdk/util-endpoints': 3.667.0 + '@smithy/core': 2.4.8 + '@smithy/protocol-http': 4.1.4 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/region-config-resolver@3.667.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/node-config-provider': 3.1.8 + '@smithy/types': 3.5.0 + '@smithy/util-config-provider': 3.0.0 + '@smithy/util-middleware': 3.0.7 + tslib: 2.6.3 + + '@aws-sdk/token-providers@3.667.0(@aws-sdk/client-sso-oidc@3.670.0(@aws-sdk/client-sts@3.670.0))': + dependencies: + '@aws-sdk/client-sso-oidc': 3.670.0(@aws-sdk/client-sts@3.670.0) + '@aws-sdk/types': 3.667.0 + '@smithy/property-provider': 3.1.7 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/types@3.667.0': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@aws-sdk/util-endpoints@3.667.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/types': 3.5.0 + '@smithy/util-endpoints': 2.1.3 + tslib: 2.6.3 + + '@aws-sdk/util-locate-window@3.568.0': + dependencies: + tslib: 2.6.3 + + '@aws-sdk/util-user-agent-browser@3.670.0': + dependencies: + '@aws-sdk/types': 3.667.0 + '@smithy/types': 3.5.0 + bowser: 2.11.0 + tslib: 2.6.3 + + '@aws-sdk/util-user-agent-node@3.669.0': + dependencies: + '@aws-sdk/middleware-user-agent': 3.669.0 + '@aws-sdk/types': 3.667.0 + '@smithy/node-config-provider': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + '@babel/code-frame@7.24.7': dependencies: '@babel/highlight': 7.24.7 @@ -6867,6 +7602,303 @@ snapshots: '@sinclair/typebox@0.27.8': {} + '@smithy/abort-controller@3.1.5': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/config-resolver@3.0.9': + dependencies: + '@smithy/node-config-provider': 3.1.8 + '@smithy/types': 3.5.0 + '@smithy/util-config-provider': 3.0.0 + '@smithy/util-middleware': 3.0.7 + tslib: 2.6.3 + + '@smithy/core@2.4.8': + dependencies: + '@smithy/middleware-endpoint': 3.1.4 + '@smithy/middleware-retry': 3.0.23 + '@smithy/middleware-serde': 3.0.7 + '@smithy/protocol-http': 4.1.4 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + + '@smithy/credential-provider-imds@3.2.4': + dependencies: + '@smithy/node-config-provider': 3.1.8 + '@smithy/property-provider': 3.1.7 + '@smithy/types': 3.5.0 + '@smithy/url-parser': 3.0.7 + tslib: 2.6.3 + + '@smithy/eventstream-codec@3.1.6': + dependencies: + '@aws-crypto/crc32': 5.2.0 + '@smithy/types': 3.5.0 + '@smithy/util-hex-encoding': 3.0.0 + tslib: 2.6.3 + + '@smithy/eventstream-serde-browser@3.0.10': + dependencies: + '@smithy/eventstream-serde-universal': 3.0.9 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/eventstream-serde-config-resolver@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/eventstream-serde-node@3.0.9': + dependencies: + '@smithy/eventstream-serde-universal': 3.0.9 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/eventstream-serde-universal@3.0.9': + dependencies: + '@smithy/eventstream-codec': 3.1.6 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/fetch-http-handler@3.2.9': + dependencies: + '@smithy/protocol-http': 4.1.4 + '@smithy/querystring-builder': 3.0.7 + '@smithy/types': 3.5.0 + '@smithy/util-base64': 3.0.0 + tslib: 2.6.3 + + '@smithy/hash-node@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + + '@smithy/invalid-dependency@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/is-array-buffer@2.2.0': + dependencies: + tslib: 2.6.3 + + '@smithy/is-array-buffer@3.0.0': + dependencies: + tslib: 2.6.3 + + '@smithy/middleware-content-length@3.0.9': + dependencies: + '@smithy/protocol-http': 4.1.4 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/middleware-endpoint@3.1.4': + dependencies: + '@smithy/middleware-serde': 3.0.7 + '@smithy/node-config-provider': 3.1.8 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + '@smithy/url-parser': 3.0.7 + '@smithy/util-middleware': 3.0.7 + tslib: 2.6.3 + + '@smithy/middleware-retry@3.0.23': + dependencies: + '@smithy/node-config-provider': 3.1.8 + '@smithy/protocol-http': 4.1.4 + '@smithy/service-error-classification': 3.0.7 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-retry': 3.0.7 + tslib: 2.6.3 + uuid: 9.0.1 + + '@smithy/middleware-serde@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/middleware-stack@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/node-config-provider@3.1.8': + dependencies: + '@smithy/property-provider': 3.1.7 + '@smithy/shared-ini-file-loader': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/node-http-handler@3.2.4': + dependencies: + '@smithy/abort-controller': 3.1.5 + '@smithy/protocol-http': 4.1.4 + '@smithy/querystring-builder': 3.0.7 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/property-provider@3.1.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/protocol-http@4.1.4': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/querystring-builder@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + '@smithy/util-uri-escape': 3.0.0 + tslib: 2.6.3 + + '@smithy/querystring-parser@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/service-error-classification@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + + '@smithy/shared-ini-file-loader@3.1.8': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/signature-v4@4.2.0': + dependencies: + '@smithy/is-array-buffer': 3.0.0 + '@smithy/protocol-http': 4.1.4 + '@smithy/types': 3.5.0 + '@smithy/util-hex-encoding': 3.0.0 + '@smithy/util-middleware': 3.0.7 + '@smithy/util-uri-escape': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + + '@smithy/smithy-client@3.4.0': + dependencies: + '@smithy/middleware-endpoint': 3.1.4 + '@smithy/middleware-stack': 3.0.7 + '@smithy/protocol-http': 4.1.4 + '@smithy/types': 3.5.0 + '@smithy/util-stream': 3.1.9 + tslib: 2.6.3 + + '@smithy/types@3.5.0': + dependencies: + tslib: 2.6.3 + + '@smithy/url-parser@3.0.7': + dependencies: + '@smithy/querystring-parser': 3.0.7 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/util-base64@3.0.0': + dependencies: + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + + '@smithy/util-body-length-browser@3.0.0': + dependencies: + tslib: 2.6.3 + + '@smithy/util-body-length-node@3.0.0': + dependencies: + tslib: 2.6.3 + + '@smithy/util-buffer-from@2.2.0': + dependencies: + '@smithy/is-array-buffer': 2.2.0 + tslib: 2.6.3 + + '@smithy/util-buffer-from@3.0.0': + dependencies: + '@smithy/is-array-buffer': 3.0.0 + tslib: 2.6.3 + + '@smithy/util-config-provider@3.0.0': + dependencies: + tslib: 2.6.3 + + '@smithy/util-defaults-mode-browser@3.0.23': + dependencies: + '@smithy/property-provider': 3.1.7 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + bowser: 2.11.0 + tslib: 2.6.3 + + '@smithy/util-defaults-mode-node@3.0.23': + dependencies: + '@smithy/config-resolver': 3.0.9 + '@smithy/credential-provider-imds': 3.2.4 + '@smithy/node-config-provider': 3.1.8 + '@smithy/property-provider': 3.1.7 + '@smithy/smithy-client': 3.4.0 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/util-endpoints@2.1.3': + dependencies: + '@smithy/node-config-provider': 3.1.8 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/util-hex-encoding@3.0.0': + dependencies: + tslib: 2.6.3 + + '@smithy/util-middleware@3.0.7': + dependencies: + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/util-retry@3.0.7': + dependencies: + '@smithy/service-error-classification': 3.0.7 + '@smithy/types': 3.5.0 + tslib: 2.6.3 + + '@smithy/util-stream@3.1.9': + dependencies: + '@smithy/fetch-http-handler': 3.2.9 + '@smithy/node-http-handler': 3.2.4 + '@smithy/types': 3.5.0 + '@smithy/util-base64': 3.0.0 + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-hex-encoding': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.6.3 + + '@smithy/util-uri-escape@3.0.0': + dependencies: + tslib: 2.6.3 + + '@smithy/util-utf8@2.3.0': + dependencies: + '@smithy/util-buffer-from': 2.2.0 + tslib: 2.6.3 + + '@smithy/util-utf8@3.0.0': + dependencies: + '@smithy/util-buffer-from': 3.0.0 + tslib: 2.6.3 + '@stylistic/eslint-plugin-js@2.3.0(eslint@9.5.0)': dependencies: '@types/eslint': 8.56.10 @@ -7541,6 +8573,8 @@ snapshots: - supports-color optional: true + bowser@2.11.0: {} + brace-expansion@1.1.11: dependencies: balanced-match: 1.0.2 @@ -8379,6 +9413,10 @@ snapshots: fast-levenshtein@2.0.6: {} + fast-xml-parser@4.4.1: + dependencies: + strnum: 1.0.5 + fastq@1.17.1: dependencies: reusify: 1.0.4 @@ -10782,6 +11820,8 @@ snapshots: strip-json-comments@3.1.1: {} + strnum@1.0.5: {} + style-mod@4.1.2: {} style-to-object@0.4.4: @@ -11144,6 +12184,8 @@ snapshots: utils-merge@1.0.1: {} + uuid@9.0.1: {} + uvu@0.5.6: dependencies: dequal: 2.0.3 From 24708066966acddc03bfe496146c08b0f3244c8e Mon Sep 17 00:00:00 2001 From: Maki Date: Thu, 17 Oct 2024 21:02:14 +0900 Subject: [PATCH 4/4] =?UTF-8?q?=F0=9F=94=91=20[refactor]=20Improve=20API?= =?UTF-8?q?=20key=20and=20AWS=20credentials=20management?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Translate comments to English for consistency - Add explanatory comment for AWS credentials function - Refactor default region assignment with inline comment --- app/lib/.server/llm/api-key.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/lib/.server/llm/api-key.ts b/app/lib/.server/llm/api-key.ts index c6228cc58..8d0b82efc 100644 --- a/app/lib/.server/llm/api-key.ts +++ b/app/lib/.server/llm/api-key.ts @@ -16,16 +16,17 @@ export function getAPIKey(cloudflareEnv: Env, provider: string) { return env.GROQ_API_KEY || cloudflareEnv.GROQ_API_KEY; case 'OpenRouter': return env.OPEN_ROUTER_API_KEY || cloudflareEnv.OPEN_ROUTER_API_KEY; - // Bedrock用のAWSクレデンシャルは別途取得 + // AWS credentials for Bedrock are obtained separately default: return ""; } } +// This function retrieves AWS credentials from environment variables export function getAWSCredentials(cloudflareEnv: Env) { return { accessKeyId: env.AWS_ACCESS_KEY_ID || cloudflareEnv.AWS_ACCESS_KEY_ID, secretAccessKey: env.AWS_SECRET_ACCESS_KEY || cloudflareEnv.AWS_SECRET_ACCESS_KEY, - region: env.AWS_REGION || cloudflareEnv.AWS_REGION || 'us-east-1', // デフォルトリージョン + region: env.AWS_REGION || cloudflareEnv.AWS_REGION || 'us-east-1', // Default region }; }