codacus commited on
Commit
99cbde5
·
2 Parent(s): ed6433e 7158ad6

Merge branch 'main' into terminal-error-detection

Browse files
.github/workflows/commit.yaml CHANGED
@@ -20,9 +20,17 @@ jobs:
20
  - name: Get the latest commit hash
21
  run: echo "COMMIT_HASH=$(git rev-parse HEAD)" >> $GITHUB_ENV
22
 
 
 
 
 
 
 
 
23
  - name: Update commit file
24
  run: |
25
- echo "{ \"commit\": \"$COMMIT_HASH\" }" > app/commit.json
 
26
 
27
  - name: Commit and push the update
28
  run: |
 
20
  - name: Get the latest commit hash
21
  run: echo "COMMIT_HASH=$(git rev-parse HEAD)" >> $GITHUB_ENV
22
 
23
+
24
+ - name: Setup Node.js
25
+ uses: actions/setup-node@v4
26
+ with:
27
+ node-version: '20'
28
+
29
+
30
  - name: Update commit file
31
  run: |
32
+ echo "CURRENT_VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_ENV
33
+ echo "{ \"commit\": \"$COMMIT_HASH\" , \"version\": \"$CURRENT_VERSION\" }" > app/commit.json
34
 
35
  - name: Commit and push the update
36
  run: |
.github/workflows/update-stable.yml CHANGED
@@ -9,30 +9,7 @@ permissions:
9
  contents: write
10
 
11
  jobs:
12
- update-commit:
13
- if: contains(github.event.head_commit.message, '#release')
14
- runs-on: ubuntu-latest
15
-
16
- steps:
17
- - name: Checkout the code
18
- uses: actions/checkout@v3
19
-
20
- - name: Get the latest commit hash
21
- run: echo "COMMIT_HASH=$(git rev-parse HEAD)" >> $GITHUB_ENV
22
-
23
- - name: Update commit file
24
- run: |
25
- echo "{ \"commit\": \"$COMMIT_HASH\" }" > app/commit.json
26
-
27
- - name: Commit and push the update
28
- run: |
29
- git config --global user.name "github-actions[bot]"
30
- git config --global user.email "github-actions[bot]@users.noreply.github.com"
31
- git add app/commit.json
32
- git commit -m "chore: update commit hash to $COMMIT_HASH"
33
- git push
34
  prepare-release:
35
- needs: update-commit
36
  if: contains(github.event.head_commit.message, '#release')
37
  runs-on: ubuntu-latest
38
 
@@ -183,8 +160,11 @@ jobs:
183
 
184
  - name: Commit and Tag Release
185
  run: |
 
 
186
  git pull
187
- git add package.json pnpm-lock.yaml changelog.md
 
188
  git commit -m "chore: release version ${{ steps.bump_version.outputs.new_version }}"
189
  git tag "v${{ steps.bump_version.outputs.new_version }}"
190
  git push
 
9
  contents: write
10
 
11
  jobs:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
12
  prepare-release:
 
13
  if: contains(github.event.head_commit.message, '#release')
14
  runs-on: ubuntu-latest
15
 
 
160
 
161
  - name: Commit and Tag Release
162
  run: |
163
+ echo "COMMIT_HASH=$(git rev-parse HEAD)" >> $GITHUB_ENV
164
+ echo "CURRENT_VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_ENV
165
  git pull
166
+ echo "{ \"commit\": \"$COMMIT_HASH\" , \"version\": \"$CURRENT_VERSION\" }" > app/commit.json
167
+ git add package.json pnpm-lock.yaml changelog.md app/commit.json
168
  git commit -m "chore: release version ${{ steps.bump_version.outputs.new_version }}"
169
  git tag "v${{ steps.bump_version.outputs.new_version }}"
170
  git push
app/commit.json CHANGED
@@ -1 +1 @@
1
- { "commit": "87a90718d31bd8ec501cb32f863efd26156fb1e2" }
 
1
+ { "commit": "eb1d5417e77e699e0489f09814e87fb5afed9dd5" , "version": "" }
app/components/chat/AssistantMessage.tsx CHANGED
@@ -1,13 +1,30 @@
1
  import { memo } from 'react';
2
  import { Markdown } from './Markdown';
 
3
 
4
  interface AssistantMessageProps {
5
  content: string;
 
6
  }
7
 
8
- export const AssistantMessage = memo(({ content }: AssistantMessageProps) => {
 
 
 
 
 
 
 
 
 
 
9
  return (
10
  <div className="overflow-hidden w-full">
 
 
 
 
 
11
  <Markdown html>{content}</Markdown>
12
  </div>
13
  );
 
1
  import { memo } from 'react';
2
  import { Markdown } from './Markdown';
3
+ import type { JSONValue } from 'ai';
4
 
5
  interface AssistantMessageProps {
6
  content: string;
7
+ annotations?: JSONValue[];
8
  }
9
 
10
+ export const AssistantMessage = memo(({ content, annotations }: AssistantMessageProps) => {
11
+ const filteredAnnotations = (annotations?.filter(
12
+ (annotation: JSONValue) => annotation && typeof annotation === 'object' && Object.keys(annotation).includes('type'),
13
+ ) || []) as { type: string; value: any }[];
14
+
15
+ const usage: {
16
+ completionTokens: number;
17
+ promptTokens: number;
18
+ totalTokens: number;
19
+ } = filteredAnnotations.find((annotation) => annotation.type === 'usage')?.value;
20
+
21
  return (
22
  <div className="overflow-hidden w-full">
23
+ {usage && (
24
+ <div className="text-sm text-bolt-elements-textSecondary mb-2">
25
+ Tokens: {usage.totalTokens} (prompt: {usage.promptTokens}, completion: {usage.completionTokens})
26
+ </div>
27
+ )}
28
  <Markdown html>{content}</Markdown>
29
  </div>
30
  );
app/components/chat/BaseChat.tsx CHANGED
@@ -77,7 +77,6 @@ export const BaseChat = React.forwardRef<HTMLDivElement, BaseChatProps>(
77
  input = '',
78
  enhancingPrompt,
79
  handleInputChange,
80
- promptEnhanced,
81
  enhancePrompt,
82
  sendMessage,
83
  handleStop,
@@ -490,10 +489,7 @@ export const BaseChat = React.forwardRef<HTMLDivElement, BaseChatProps>(
490
  <IconButton
491
  title="Enhance prompt"
492
  disabled={input.length === 0 || enhancingPrompt}
493
- className={classNames(
494
- 'transition-all',
495
- enhancingPrompt ? 'opacity-100' : '',
496
- )}
497
  onClick={() => {
498
  enhancePrompt?.();
499
  toast.success('Prompt enhanced!');
 
77
  input = '',
78
  enhancingPrompt,
79
  handleInputChange,
 
80
  enhancePrompt,
81
  sendMessage,
82
  handleStop,
 
489
  <IconButton
490
  title="Enhance prompt"
491
  disabled={input.length === 0 || enhancingPrompt}
492
+ className={classNames('transition-all', enhancingPrompt ? 'opacity-100' : '')}
 
 
 
493
  onClick={() => {
494
  enhancePrompt?.();
495
  toast.success('Prompt enhanced!');
app/components/chat/Chat.client.tsx CHANGED
@@ -116,13 +116,22 @@ export const ChatImpl = memo(
116
  apiKeys,
117
  files,
118
  },
 
119
  onError: (error) => {
120
  logger.error('Request failed\n\n', error);
121
  toast.error(
122
  'There was an error processing your request: ' + (error.message ? error.message : 'No details were returned'),
123
  );
124
  },
125
- onFinish: () => {
 
 
 
 
 
 
 
 
126
  logger.debug('Finished streaming');
127
  },
128
  initialMessages,
 
116
  apiKeys,
117
  files,
118
  },
119
+ sendExtraMessageFields: true,
120
  onError: (error) => {
121
  logger.error('Request failed\n\n', error);
122
  toast.error(
123
  'There was an error processing your request: ' + (error.message ? error.message : 'No details were returned'),
124
  );
125
  },
126
+ onFinish: (message, response) => {
127
+ const usage = response.usage;
128
+
129
+ if (usage) {
130
+ console.log('Token usage:', usage);
131
+
132
+ // You can now use the usage data as needed
133
+ }
134
+
135
  logger.debug('Finished streaming');
136
  },
137
  initialMessages,
app/components/chat/Messages.client.tsx CHANGED
@@ -65,12 +65,16 @@ export const Messages = React.forwardRef<HTMLDivElement, MessagesProps>((props:
65
  </div>
66
  )}
67
  <div className="grid grid-col-1 w-full">
68
- {isUserMessage ? <UserMessage content={content} /> : <AssistantMessage content={content} />}
 
 
 
 
69
  </div>
70
  {!isUserMessage && (
71
  <div className="flex gap-2 flex-col lg:flex-row">
72
- <WithTooltip tooltip="Revert to this message">
73
- {messageId && (
74
  <button
75
  onClick={() => handleRewind(messageId)}
76
  key="i-ph:arrow-u-up-left"
@@ -79,8 +83,8 @@ export const Messages = React.forwardRef<HTMLDivElement, MessagesProps>((props:
79
  'text-xl text-bolt-elements-textSecondary hover:text-bolt-elements-textPrimary transition-colors',
80
  )}
81
  />
82
- )}
83
- </WithTooltip>
84
 
85
  <WithTooltip tooltip="Fork chat from this message">
86
  <button
 
65
  </div>
66
  )}
67
  <div className="grid grid-col-1 w-full">
68
+ {isUserMessage ? (
69
+ <UserMessage content={content} />
70
+ ) : (
71
+ <AssistantMessage content={content} annotations={message.annotations} />
72
+ )}
73
  </div>
74
  {!isUserMessage && (
75
  <div className="flex gap-2 flex-col lg:flex-row">
76
+ {messageId && (
77
+ <WithTooltip tooltip="Revert to this message">
78
  <button
79
  onClick={() => handleRewind(messageId)}
80
  key="i-ph:arrow-u-up-left"
 
83
  'text-xl text-bolt-elements-textSecondary hover:text-bolt-elements-textPrimary transition-colors',
84
  )}
85
  />
86
+ </WithTooltip>
87
+ )}
88
 
89
  <WithTooltip tooltip="Fork chat from this message">
90
  <button
app/components/chat/UserMessage.tsx CHANGED
@@ -12,42 +12,36 @@ interface UserMessageProps {
12
  export function UserMessage({ content }: UserMessageProps) {
13
  if (Array.isArray(content)) {
14
  const textItem = content.find((item) => item.type === 'text');
15
- const textContent = sanitizeUserMessage(textItem?.text || '');
16
  const images = content.filter((item) => item.type === 'image' && item.image);
17
 
18
  return (
19
  <div className="overflow-hidden pt-[4px]">
20
- <div className="flex items-start gap-4">
21
- <div className="flex-1">
22
- <Markdown limitedMarkdown>{textContent}</Markdown>
23
- </div>
24
- {images.length > 0 && (
25
- <div className="flex-shrink-0 w-[160px]">
26
- {images.map((item, index) => (
27
- <div key={index} className="relative">
28
- <img
29
- src={item.image}
30
- alt={`Uploaded image ${index + 1}`}
31
- className="w-full h-[160px] rounded-lg object-cover border border-bolt-elements-borderColor"
32
- />
33
- </div>
34
- ))}
35
- </div>
36
- )}
37
  </div>
38
  </div>
39
  );
40
  }
41
 
42
- const textContent = sanitizeUserMessage(content);
43
 
44
  return (
45
  <div className="overflow-hidden pt-[4px]">
46
- <Markdown limitedMarkdown>{textContent}</Markdown>
47
  </div>
48
  );
49
  }
50
 
51
- function sanitizeUserMessage(content: string) {
52
  return content.replace(MODEL_REGEX, '').replace(PROVIDER_REGEX, '');
53
  }
 
12
  export function UserMessage({ content }: UserMessageProps) {
13
  if (Array.isArray(content)) {
14
  const textItem = content.find((item) => item.type === 'text');
15
+ const textContent = stripMetadata(textItem?.text || '');
16
  const images = content.filter((item) => item.type === 'image' && item.image);
17
 
18
  return (
19
  <div className="overflow-hidden pt-[4px]">
20
+ <div className="flex flex-col gap-4">
21
+ {textContent && <Markdown html>{textContent}</Markdown>}
22
+ {images.map((item, index) => (
23
+ <img
24
+ key={index}
25
+ src={item.image}
26
+ alt={`Image ${index + 1}`}
27
+ className="max-w-full h-auto rounded-lg"
28
+ style={{ maxHeight: '512px', objectFit: 'contain' }}
29
+ />
30
+ ))}
 
 
 
 
 
 
31
  </div>
32
  </div>
33
  );
34
  }
35
 
36
+ const textContent = stripMetadata(content);
37
 
38
  return (
39
  <div className="overflow-hidden pt-[4px]">
40
+ <Markdown html>{textContent}</Markdown>
41
  </div>
42
  );
43
  }
44
 
45
+ function stripMetadata(content: string) {
46
  return content.replace(MODEL_REGEX, '').replace(PROVIDER_REGEX, '');
47
  }
app/components/settings/chat-history/ChatHistoryTab.tsx CHANGED
@@ -22,7 +22,8 @@ export default function ChatHistoryTab() {
22
  };
23
 
24
  const handleDeleteAllChats = async () => {
25
- const confirmDelete = window.confirm("Are you sure you want to delete all chats? This action cannot be undone.");
 
26
  if (!confirmDelete) {
27
  return; // Exit if the user cancels
28
  }
@@ -31,11 +32,13 @@ export default function ChatHistoryTab() {
31
  const error = new Error('Database is not available');
32
  logStore.logError('Failed to delete chats - DB unavailable', error);
33
  toast.error('Database is not available');
 
34
  return;
35
  }
36
 
37
  try {
38
  setIsDeleting(true);
 
39
  const allChats = await getAll(db);
40
  await Promise.all(allChats.map((chat) => deleteById(db!, chat.id)));
41
  logStore.logSystem('All chats deleted successfully', { count: allChats.length });
@@ -55,6 +58,7 @@ export default function ChatHistoryTab() {
55
  const error = new Error('Database is not available');
56
  logStore.logError('Failed to export chats - DB unavailable', error);
57
  toast.error('Database is not available');
 
58
  return;
59
  }
60
 
 
22
  };
23
 
24
  const handleDeleteAllChats = async () => {
25
+ const confirmDelete = window.confirm('Are you sure you want to delete all chats? This action cannot be undone.');
26
+
27
  if (!confirmDelete) {
28
  return; // Exit if the user cancels
29
  }
 
32
  const error = new Error('Database is not available');
33
  logStore.logError('Failed to delete chats - DB unavailable', error);
34
  toast.error('Database is not available');
35
+
36
  return;
37
  }
38
 
39
  try {
40
  setIsDeleting(true);
41
+
42
  const allChats = await getAll(db);
43
  await Promise.all(allChats.map((chat) => deleteById(db!, chat.id)));
44
  logStore.logSystem('All chats deleted successfully', { count: allChats.length });
 
58
  const error = new Error('Database is not available');
59
  logStore.logError('Failed to export chats - DB unavailable', error);
60
  toast.error('Database is not available');
61
+
62
  return;
63
  }
64
 
app/components/settings/debug/DebugTab.tsx CHANGED
@@ -22,20 +22,37 @@ interface SystemInfo {
22
  timezone: string;
23
  memory: string;
24
  cores: number;
 
 
 
 
 
 
25
  }
26
 
27
  interface IProviderConfig {
28
  name: string;
29
  settings: {
30
  enabled: boolean;
 
31
  };
32
  }
33
 
 
 
 
 
 
 
 
34
  const LOCAL_PROVIDERS = ['Ollama', 'LMStudio', 'OpenAILike'];
35
- const versionHash = commit.commit;
 
36
  const GITHUB_URLS = {
37
  original: 'https://api.github.com/repos/stackblitz-labs/bolt.diy/commits/main',
38
  fork: 'https://api.github.com/repos/Stijnus/bolt.new-any-llm/commits/main',
 
 
39
  };
40
 
41
  function getSystemInfo(): SystemInfo {
@@ -51,14 +68,100 @@ function getSystemInfo(): SystemInfo {
51
  return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + ' ' + sizes[i];
52
  };
53
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
54
  return {
55
- os: navigator.platform,
56
- browser: navigator.userAgent.split(' ').slice(-1)[0],
57
  screen: `${window.screen.width}x${window.screen.height}`,
58
  language: navigator.language,
59
  timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
60
- memory: formatBytes(performance?.memory?.jsHeapSizeLimit || 0),
61
  cores: navigator.hardwareConcurrency || 0,
 
 
 
 
 
 
 
 
62
  };
63
  }
64
 
@@ -200,7 +303,7 @@ const checkProviderStatus = async (url: string | null, providerName: string): Pr
200
  };
201
 
202
  export default function DebugTab() {
203
- const { providers } = useSettings();
204
  const [activeProviders, setActiveProviders] = useState<ProviderStatus[]>([]);
205
  const [updateMessage, setUpdateMessage] = useState<string>('');
206
  const [systemInfo] = useState<SystemInfo>(getSystemInfo());
@@ -213,29 +316,31 @@ export default function DebugTab() {
213
 
214
  try {
215
  const entries = Object.entries(providers) as [string, IProviderConfig][];
216
- const statuses = entries
217
- .filter(([, provider]) => LOCAL_PROVIDERS.includes(provider.name))
218
- .map(async ([, provider]) => {
219
- const envVarName =
220
- provider.name.toLowerCase() === 'ollama'
221
- ? 'OLLAMA_API_BASE_URL'
222
- : provider.name.toLowerCase() === 'lmstudio'
223
- ? 'LMSTUDIO_API_BASE_URL'
224
- : `REACT_APP_${provider.name.toUpperCase()}_URL`;
225
-
226
- // Access environment variables through import.meta.env
227
- const url = import.meta.env[envVarName] || null;
228
- console.log(`[Debug] Using URL for ${provider.name}:`, url, `(from ${envVarName})`);
229
-
230
- const status = await checkProviderStatus(url, provider.name);
231
-
232
- return {
233
- ...status,
234
- enabled: provider.settings.enabled ?? false,
235
- };
236
- });
237
-
238
- Promise.all(statuses).then(setActiveProviders);
 
 
239
  } catch (error) {
240
  console.error('[Debug] Failed to update provider statuses:', error);
241
  }
@@ -258,32 +363,27 @@ export default function DebugTab() {
258
  setIsCheckingUpdate(true);
259
  setUpdateMessage('Checking for updates...');
260
 
261
- const [originalResponse, forkResponse] = await Promise.all([
262
- fetch(GITHUB_URLS.original),
263
- fetch(GITHUB_URLS.fork),
264
- ]);
265
 
266
- if (!originalResponse.ok || !forkResponse.ok) {
267
- throw new Error('Failed to fetch repository information');
268
- }
269
 
270
- const [originalData, forkData] = await Promise.all([
271
- originalResponse.json() as Promise<{ sha: string }>,
272
- forkResponse.json() as Promise<{ sha: string }>,
273
- ]);
274
 
275
- const originalCommitHash = originalData.sha;
276
- const forkCommitHash = forkData.sha;
277
- const isForked = versionHash === forkCommitHash && forkCommitHash !== originalCommitHash;
278
 
279
- if (originalCommitHash !== versionHash) {
280
  setUpdateMessage(
281
- `Update available from original repository!\n` +
282
- `Current: ${versionHash.slice(0, 7)}${isForked ? ' (forked)' : ''}\n` +
283
- `Latest: ${originalCommitHash.slice(0, 7)}`,
284
  );
285
  } else {
286
- setUpdateMessage('You are on the latest version from the original repository');
287
  }
288
  } catch (error) {
289
  setUpdateMessage('Failed to check for updates');
@@ -291,7 +391,7 @@ export default function DebugTab() {
291
  } finally {
292
  setIsCheckingUpdate(false);
293
  }
294
- }, [isCheckingUpdate]);
295
 
296
  const handleCopyToClipboard = useCallback(() => {
297
  const debugInfo = {
@@ -306,14 +406,17 @@ export default function DebugTab() {
306
  responseTime: provider.responseTime,
307
  url: provider.url,
308
  })),
309
- Version: versionHash,
 
 
 
310
  Timestamp: new Date().toISOString(),
311
  };
312
 
313
  navigator.clipboard.writeText(JSON.stringify(debugInfo, null, 2)).then(() => {
314
  toast.success('Debug information copied to clipboard!');
315
  });
316
- }, [activeProviders, systemInfo]);
317
 
318
  return (
319
  <div className="p-4 space-y-6">
@@ -373,10 +476,31 @@ export default function DebugTab() {
373
  <p className="text-xs text-bolt-elements-textSecondary">Operating System</p>
374
  <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.os}</p>
375
  </div>
 
 
 
 
376
  <div>
377
  <p className="text-xs text-bolt-elements-textSecondary">Browser</p>
378
  <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.browser}</p>
379
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
380
  <div>
381
  <p className="text-xs text-bolt-elements-textSecondary">Screen Resolution</p>
382
  <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.screen}</p>
@@ -399,7 +523,7 @@ export default function DebugTab() {
399
  <p className="text-sm font-medium text-bolt-elements-textPrimary font-mono">
400
  {versionHash.slice(0, 7)}
401
  <span className="ml-2 text-xs text-bolt-elements-textSecondary">
402
- ({new Date().toLocaleDateString()})
403
  </span>
404
  </p>
405
  </div>
 
22
  timezone: string;
23
  memory: string;
24
  cores: number;
25
+ deviceType: string;
26
+ colorDepth: string;
27
+ pixelRatio: number;
28
+ online: boolean;
29
+ cookiesEnabled: boolean;
30
+ doNotTrack: boolean;
31
  }
32
 
33
  interface IProviderConfig {
34
  name: string;
35
  settings: {
36
  enabled: boolean;
37
+ baseUrl?: string;
38
  };
39
  }
40
 
41
+ interface CommitData {
42
+ commit: string;
43
+ version?: string;
44
+ }
45
+
46
+ const connitJson: CommitData = commit;
47
+
48
  const LOCAL_PROVIDERS = ['Ollama', 'LMStudio', 'OpenAILike'];
49
+ const versionHash = connitJson.commit;
50
+ const versionTag = connitJson.version;
51
  const GITHUB_URLS = {
52
  original: 'https://api.github.com/repos/stackblitz-labs/bolt.diy/commits/main',
53
  fork: 'https://api.github.com/repos/Stijnus/bolt.new-any-llm/commits/main',
54
+ commitJson: (branch: string) =>
55
+ `https://raw.githubusercontent.com/stackblitz-labs/bolt.diy/${branch}/app/commit.json`,
56
  };
57
 
58
  function getSystemInfo(): SystemInfo {
 
68
  return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + ' ' + sizes[i];
69
  };
70
 
71
+ const getBrowserInfo = (): string => {
72
+ const ua = navigator.userAgent;
73
+ let browser = 'Unknown';
74
+
75
+ if (ua.includes('Firefox/')) {
76
+ browser = 'Firefox';
77
+ } else if (ua.includes('Chrome/')) {
78
+ if (ua.includes('Edg/')) {
79
+ browser = 'Edge';
80
+ } else if (ua.includes('OPR/')) {
81
+ browser = 'Opera';
82
+ } else {
83
+ browser = 'Chrome';
84
+ }
85
+ } else if (ua.includes('Safari/')) {
86
+ if (!ua.includes('Chrome')) {
87
+ browser = 'Safari';
88
+ }
89
+ }
90
+
91
+ // Extract version number
92
+ const match = ua.match(new RegExp(`${browser}\\/([\\d.]+)`));
93
+ const version = match ? ` ${match[1]}` : '';
94
+
95
+ return `${browser}${version}`;
96
+ };
97
+
98
+ const getOperatingSystem = (): string => {
99
+ const ua = navigator.userAgent;
100
+ const platform = navigator.platform;
101
+
102
+ if (ua.includes('Win')) {
103
+ return 'Windows';
104
+ }
105
+
106
+ if (ua.includes('Mac')) {
107
+ if (ua.includes('iPhone') || ua.includes('iPad')) {
108
+ return 'iOS';
109
+ }
110
+
111
+ return 'macOS';
112
+ }
113
+
114
+ if (ua.includes('Linux')) {
115
+ return 'Linux';
116
+ }
117
+
118
+ if (ua.includes('Android')) {
119
+ return 'Android';
120
+ }
121
+
122
+ return platform || 'Unknown';
123
+ };
124
+
125
+ const getDeviceType = (): string => {
126
+ const ua = navigator.userAgent;
127
+
128
+ if (ua.includes('Mobile')) {
129
+ return 'Mobile';
130
+ }
131
+
132
+ if (ua.includes('Tablet')) {
133
+ return 'Tablet';
134
+ }
135
+
136
+ return 'Desktop';
137
+ };
138
+
139
+ // Get more detailed memory info if available
140
+ const getMemoryInfo = (): string => {
141
+ if ('memory' in performance) {
142
+ const memory = (performance as any).memory;
143
+ return `${formatBytes(memory.jsHeapSizeLimit)} (Used: ${formatBytes(memory.usedJSHeapSize)})`;
144
+ }
145
+
146
+ return 'Not available';
147
+ };
148
+
149
  return {
150
+ os: getOperatingSystem(),
151
+ browser: getBrowserInfo(),
152
  screen: `${window.screen.width}x${window.screen.height}`,
153
  language: navigator.language,
154
  timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
155
+ memory: getMemoryInfo(),
156
  cores: navigator.hardwareConcurrency || 0,
157
+ deviceType: getDeviceType(),
158
+
159
+ // Add new fields
160
+ colorDepth: `${window.screen.colorDepth}-bit`,
161
+ pixelRatio: window.devicePixelRatio,
162
+ online: navigator.onLine,
163
+ cookiesEnabled: navigator.cookieEnabled,
164
+ doNotTrack: navigator.doNotTrack === '1',
165
  };
166
  }
167
 
 
303
  };
304
 
305
  export default function DebugTab() {
306
+ const { providers, latestBranch } = useSettings();
307
  const [activeProviders, setActiveProviders] = useState<ProviderStatus[]>([]);
308
  const [updateMessage, setUpdateMessage] = useState<string>('');
309
  const [systemInfo] = useState<SystemInfo>(getSystemInfo());
 
316
 
317
  try {
318
  const entries = Object.entries(providers) as [string, IProviderConfig][];
319
+ const statuses = await Promise.all(
320
+ entries
321
+ .filter(([, provider]) => LOCAL_PROVIDERS.includes(provider.name))
322
+ .map(async ([, provider]) => {
323
+ const envVarName =
324
+ provider.name.toLowerCase() === 'ollama'
325
+ ? 'OLLAMA_API_BASE_URL'
326
+ : provider.name.toLowerCase() === 'lmstudio'
327
+ ? 'LMSTUDIO_API_BASE_URL'
328
+ : `REACT_APP_${provider.name.toUpperCase()}_URL`;
329
+
330
+ // Access environment variables through import.meta.env
331
+ const url = import.meta.env[envVarName] || provider.settings.baseUrl || null; // Ensure baseUrl is used
332
+ console.log(`[Debug] Using URL for ${provider.name}:`, url, `(from ${envVarName})`);
333
+
334
+ const status = await checkProviderStatus(url, provider.name);
335
+
336
+ return {
337
+ ...status,
338
+ enabled: provider.settings.enabled ?? false,
339
+ };
340
+ }),
341
+ );
342
+
343
+ setActiveProviders(statuses);
344
  } catch (error) {
345
  console.error('[Debug] Failed to update provider statuses:', error);
346
  }
 
363
  setIsCheckingUpdate(true);
364
  setUpdateMessage('Checking for updates...');
365
 
366
+ const branchToCheck = latestBranch ? 'main' : 'stable';
367
+ console.log(`[Debug] Checking for updates against ${branchToCheck} branch`);
 
 
368
 
369
+ const localCommitResponse = await fetch(GITHUB_URLS.commitJson(branchToCheck));
 
 
370
 
371
+ if (!localCommitResponse.ok) {
372
+ throw new Error('Failed to fetch local commit info');
373
+ }
 
374
 
375
+ const localCommitData = (await localCommitResponse.json()) as CommitData;
376
+ const remoteCommitHash = localCommitData.commit;
377
+ const currentCommitHash = versionHash;
378
 
379
+ if (remoteCommitHash !== currentCommitHash) {
380
  setUpdateMessage(
381
+ `Update available from ${branchToCheck} branch!\n` +
382
+ `Current: ${currentCommitHash.slice(0, 7)}\n` +
383
+ `Latest: ${remoteCommitHash.slice(0, 7)}`,
384
  );
385
  } else {
386
+ setUpdateMessage(`You are on the latest version from the ${branchToCheck} branch`);
387
  }
388
  } catch (error) {
389
  setUpdateMessage('Failed to check for updates');
 
391
  } finally {
392
  setIsCheckingUpdate(false);
393
  }
394
+ }, [isCheckingUpdate, latestBranch]);
395
 
396
  const handleCopyToClipboard = useCallback(() => {
397
  const debugInfo = {
 
406
  responseTime: provider.responseTime,
407
  url: provider.url,
408
  })),
409
+ Version: {
410
+ hash: versionHash.slice(0, 7),
411
+ branch: latestBranch ? 'main' : 'stable',
412
+ },
413
  Timestamp: new Date().toISOString(),
414
  };
415
 
416
  navigator.clipboard.writeText(JSON.stringify(debugInfo, null, 2)).then(() => {
417
  toast.success('Debug information copied to clipboard!');
418
  });
419
+ }, [activeProviders, systemInfo, latestBranch]);
420
 
421
  return (
422
  <div className="p-4 space-y-6">
 
476
  <p className="text-xs text-bolt-elements-textSecondary">Operating System</p>
477
  <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.os}</p>
478
  </div>
479
+ <div>
480
+ <p className="text-xs text-bolt-elements-textSecondary">Device Type</p>
481
+ <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.deviceType}</p>
482
+ </div>
483
  <div>
484
  <p className="text-xs text-bolt-elements-textSecondary">Browser</p>
485
  <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.browser}</p>
486
  </div>
487
+ <div>
488
+ <p className="text-xs text-bolt-elements-textSecondary">Display</p>
489
+ <p className="text-sm font-medium text-bolt-elements-textPrimary">
490
+ {systemInfo.screen} ({systemInfo.colorDepth}) @{systemInfo.pixelRatio}x
491
+ </p>
492
+ </div>
493
+ <div>
494
+ <p className="text-xs text-bolt-elements-textSecondary">Connection</p>
495
+ <p className="text-sm font-medium flex items-center gap-2">
496
+ <span
497
+ className={`inline-block w-2 h-2 rounded-full ${systemInfo.online ? 'bg-green-500' : 'bg-red-500'}`}
498
+ />
499
+ <span className={`${systemInfo.online ? 'text-green-600' : 'text-red-600'}`}>
500
+ {systemInfo.online ? 'Online' : 'Offline'}
501
+ </span>
502
+ </p>
503
+ </div>
504
  <div>
505
  <p className="text-xs text-bolt-elements-textSecondary">Screen Resolution</p>
506
  <p className="text-sm font-medium text-bolt-elements-textPrimary">{systemInfo.screen}</p>
 
523
  <p className="text-sm font-medium text-bolt-elements-textPrimary font-mono">
524
  {versionHash.slice(0, 7)}
525
  <span className="ml-2 text-xs text-bolt-elements-textSecondary">
526
+ (v{versionTag || '0.0.1'}) - {latestBranch ? 'nightly' : 'stable'}
527
  </span>
528
  </p>
529
  </div>
app/components/settings/features/FeaturesTab.tsx CHANGED
@@ -3,7 +3,8 @@ import { Switch } from '~/components/ui/Switch';
3
  import { useSettings } from '~/lib/hooks/useSettings';
4
 
5
  export default function FeaturesTab() {
6
- const { debug, enableDebugMode, isLocalModel, enableLocalModels, eventLogs, enableEventLogs } = useSettings();
 
7
 
8
  const handleToggle = (enabled: boolean) => {
9
  enableDebugMode(enabled);
@@ -14,9 +15,20 @@ export default function FeaturesTab() {
14
  <div className="p-4 bg-bolt-elements-bg-depth-2 border border-bolt-elements-borderColor rounded-lg mb-4">
15
  <div className="mb-6">
16
  <h3 className="text-lg font-medium text-bolt-elements-textPrimary mb-4">Optional Features</h3>
17
- <div className="flex items-center justify-between mb-2">
18
- <span className="text-bolt-elements-textPrimary">Debug Features</span>
19
- <Switch className="ml-auto" checked={debug} onCheckedChange={handleToggle} />
 
 
 
 
 
 
 
 
 
 
 
20
  </div>
21
  </div>
22
 
 
3
  import { useSettings } from '~/lib/hooks/useSettings';
4
 
5
  export default function FeaturesTab() {
6
+ const { debug, enableDebugMode, isLocalModel, enableLocalModels, enableEventLogs, latestBranch, enableLatestBranch } =
7
+ useSettings();
8
 
9
  const handleToggle = (enabled: boolean) => {
10
  enableDebugMode(enabled);
 
15
  <div className="p-4 bg-bolt-elements-bg-depth-2 border border-bolt-elements-borderColor rounded-lg mb-4">
16
  <div className="mb-6">
17
  <h3 className="text-lg font-medium text-bolt-elements-textPrimary mb-4">Optional Features</h3>
18
+ <div className="space-y-4">
19
+ <div className="flex items-center justify-between">
20
+ <span className="text-bolt-elements-textPrimary">Debug Features</span>
21
+ <Switch className="ml-auto" checked={debug} onCheckedChange={handleToggle} />
22
+ </div>
23
+ <div className="flex items-center justify-between">
24
+ <div>
25
+ <span className="text-bolt-elements-textPrimary">Use Main Branch</span>
26
+ <p className="text-sm text-bolt-elements-textSecondary">
27
+ Check for updates against the main branch instead of stable
28
+ </p>
29
+ </div>
30
+ <Switch className="ml-auto" checked={latestBranch} onCheckedChange={enableLatestBranch} />
31
+ </div>
32
  </div>
33
  </div>
34
 
app/components/settings/providers/ProvidersTab.tsx CHANGED
@@ -6,7 +6,7 @@ import type { IProviderConfig } from '~/types/model';
6
  import { logStore } from '~/lib/stores/logs';
7
 
8
  // Import a default fallback icon
9
- import DefaultIcon from '/icons/Ollama.svg'; // Adjust the path as necessary
10
 
11
  export default function ProvidersTab() {
12
  const { providers, updateProviderSettings, isLocalModel } = useSettings();
@@ -56,7 +56,8 @@ export default function ProvidersTab() {
56
  <div className="flex items-center gap-2">
57
  <img
58
  src={`/icons/${provider.name}.svg`} // Attempt to load the specific icon
59
- onError={(e) => { // Fallback to default icon on error
 
60
  e.currentTarget.src = DefaultIcon;
61
  }}
62
  alt={`${provider.name} icon`}
 
6
  import { logStore } from '~/lib/stores/logs';
7
 
8
  // Import a default fallback icon
9
+ import DefaultIcon from '/icons/Default.svg'; // Adjust the path as necessary
10
 
11
  export default function ProvidersTab() {
12
  const { providers, updateProviderSettings, isLocalModel } = useSettings();
 
56
  <div className="flex items-center gap-2">
57
  <img
58
  src={`/icons/${provider.name}.svg`} // Attempt to load the specific icon
59
+ onError={(e) => {
60
+ // Fallback to default icon on error
61
  e.currentTarget.src = DefaultIcon;
62
  }}
63
  alt={`${provider.name} icon`}
app/components/ui/IconButton.tsx CHANGED
@@ -1,4 +1,4 @@
1
- import { memo } from 'react';
2
  import { classNames } from '~/utils/classNames';
3
 
4
  type IconSize = 'sm' | 'md' | 'lg' | 'xl' | 'xxl';
@@ -25,41 +25,48 @@ type IconButtonWithChildrenProps = {
25
 
26
  type IconButtonProps = IconButtonWithoutChildrenProps | IconButtonWithChildrenProps;
27
 
 
28
  export const IconButton = memo(
29
- ({
30
- icon,
31
- size = 'xl',
32
- className,
33
- iconClassName,
34
- disabledClassName,
35
- disabled = false,
36
- title,
37
- onClick,
38
- children,
39
- }: IconButtonProps) => {
40
- return (
41
- <button
42
- className={classNames(
43
- 'flex items-center text-bolt-elements-item-contentDefault bg-transparent enabled:hover:text-bolt-elements-item-contentActive rounded-md p-1 enabled:hover:bg-bolt-elements-item-backgroundActive disabled:cursor-not-allowed',
44
- {
45
- [classNames('opacity-30', disabledClassName)]: disabled,
46
- },
47
- className,
48
- )}
49
- title={title}
50
- disabled={disabled}
51
- onClick={(event) => {
52
- if (disabled) {
53
- return;
54
- }
 
 
 
 
 
55
 
56
- onClick?.(event);
57
- }}
58
- >
59
- {children ? children : <div className={classNames(icon, getIconSize(size), iconClassName)}></div>}
60
- </button>
61
- );
62
- },
 
63
  );
64
 
65
  function getIconSize(size: IconSize) {
 
1
+ import { memo, forwardRef, type ForwardedRef } from 'react';
2
  import { classNames } from '~/utils/classNames';
3
 
4
  type IconSize = 'sm' | 'md' | 'lg' | 'xl' | 'xxl';
 
25
 
26
  type IconButtonProps = IconButtonWithoutChildrenProps | IconButtonWithChildrenProps;
27
 
28
+ // Componente IconButton com suporte a refs
29
  export const IconButton = memo(
30
+ forwardRef(
31
+ (
32
+ {
33
+ icon,
34
+ size = 'xl',
35
+ className,
36
+ iconClassName,
37
+ disabledClassName,
38
+ disabled = false,
39
+ title,
40
+ onClick,
41
+ children,
42
+ }: IconButtonProps,
43
+ ref: ForwardedRef<HTMLButtonElement>,
44
+ ) => {
45
+ return (
46
+ <button
47
+ ref={ref}
48
+ className={classNames(
49
+ 'flex items-center text-bolt-elements-item-contentDefault bg-transparent enabled:hover:text-bolt-elements-item-contentActive rounded-md p-1 enabled:hover:bg-bolt-elements-item-backgroundActive disabled:cursor-not-allowed',
50
+ {
51
+ [classNames('opacity-30', disabledClassName)]: disabled,
52
+ },
53
+ className,
54
+ )}
55
+ title={title}
56
+ disabled={disabled}
57
+ onClick={(event) => {
58
+ if (disabled) {
59
+ return;
60
+ }
61
 
62
+ onClick?.(event);
63
+ }}
64
+ >
65
+ {children ? children : <div className={classNames(icon, getIconSize(size), iconClassName)}></div>}
66
+ </button>
67
+ );
68
+ },
69
+ ),
70
  );
71
 
72
  function getIconSize(size: IconSize) {
app/components/ui/Tooltip.tsx CHANGED
@@ -1,8 +1,9 @@
1
  import * as Tooltip from '@radix-ui/react-tooltip';
 
2
 
3
  interface TooltipProps {
4
  tooltip: React.ReactNode;
5
- children: React.ReactNode;
6
  sideOffset?: number;
7
  className?: string;
8
  arrowClassName?: string;
@@ -12,62 +13,67 @@ interface TooltipProps {
12
  delay?: number;
13
  }
14
 
15
- const WithTooltip = ({
16
- tooltip,
17
- children,
18
- sideOffset = 5,
19
- className = '',
20
- arrowClassName = '',
21
- tooltipStyle = {},
22
- position = 'top',
23
- maxWidth = 250,
24
- delay = 0,
25
- }: TooltipProps) => {
26
- return (
27
- <Tooltip.Root delayDuration={delay}>
28
- <Tooltip.Trigger asChild>{children}</Tooltip.Trigger>
29
- <Tooltip.Portal>
30
- <Tooltip.Content
31
- side={position}
32
- className={`
33
- z-[2000]
34
- px-2.5
35
- py-1.5
36
- max-h-[300px]
37
- select-none
38
- rounded-md
39
- bg-bolt-elements-background-depth-3
40
- text-bolt-elements-textPrimary
41
- text-sm
42
- leading-tight
43
- shadow-lg
44
- animate-in
45
- fade-in-0
46
- zoom-in-95
47
- data-[state=closed]:animate-out
48
- data-[state=closed]:fade-out-0
49
- data-[state=closed]:zoom-out-95
50
- ${className}
51
- `}
52
- sideOffset={sideOffset}
53
- style={{
54
- maxWidth,
55
- ...tooltipStyle,
56
- }}
57
- >
58
- <div className="break-words">{tooltip}</div>
59
- <Tooltip.Arrow
60
  className={`
61
- fill-bolt-elements-background-depth-3
62
- ${arrowClassName}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
63
  `}
64
- width={12}
65
- height={6}
66
- />
67
- </Tooltip.Content>
68
- </Tooltip.Portal>
69
- </Tooltip.Root>
70
- );
71
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
72
 
73
  export default WithTooltip;
 
1
  import * as Tooltip from '@radix-ui/react-tooltip';
2
+ import { forwardRef, type ForwardedRef, type ReactElement } from 'react';
3
 
4
  interface TooltipProps {
5
  tooltip: React.ReactNode;
6
+ children: ReactElement;
7
  sideOffset?: number;
8
  className?: string;
9
  arrowClassName?: string;
 
13
  delay?: number;
14
  }
15
 
16
+ const WithTooltip = forwardRef(
17
+ (
18
+ {
19
+ tooltip,
20
+ children,
21
+ sideOffset = 5,
22
+ className = '',
23
+ arrowClassName = '',
24
+ tooltipStyle = {},
25
+ position = 'top',
26
+ maxWidth = 250,
27
+ delay = 0,
28
+ }: TooltipProps,
29
+ _ref: ForwardedRef<HTMLElement>,
30
+ ) => {
31
+ return (
32
+ <Tooltip.Root delayDuration={delay}>
33
+ <Tooltip.Trigger asChild>{children}</Tooltip.Trigger>
34
+ <Tooltip.Portal>
35
+ <Tooltip.Content
36
+ side={position}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
37
  className={`
38
+ z-[2000]
39
+ px-2.5
40
+ py-1.5
41
+ max-h-[300px]
42
+ select-none
43
+ rounded-md
44
+ bg-bolt-elements-background-depth-3
45
+ text-bolt-elements-textPrimary
46
+ text-sm
47
+ leading-tight
48
+ shadow-lg
49
+ animate-in
50
+ fade-in-0
51
+ zoom-in-95
52
+ data-[state=closed]:animate-out
53
+ data-[state=closed]:fade-out-0
54
+ data-[state=closed]:zoom-out-95
55
+ ${className}
56
  `}
57
+ sideOffset={sideOffset}
58
+ style={{
59
+ maxWidth,
60
+ ...tooltipStyle,
61
+ }}
62
+ >
63
+ <div className="break-words">{tooltip}</div>
64
+ <Tooltip.Arrow
65
+ className={`
66
+ fill-bolt-elements-background-depth-3
67
+ ${arrowClassName}
68
+ `}
69
+ width={12}
70
+ height={6}
71
+ />
72
+ </Tooltip.Content>
73
+ </Tooltip.Portal>
74
+ </Tooltip.Root>
75
+ );
76
+ },
77
+ );
78
 
79
  export default WithTooltip;
app/lib/hooks/useSettings.tsx CHANGED
@@ -5,19 +5,50 @@ import {
5
  isLocalModelsEnabled,
6
  LOCAL_PROVIDERS,
7
  providersStore,
 
8
  } from '~/lib/stores/settings';
9
  import { useCallback, useEffect, useState } from 'react';
10
  import Cookies from 'js-cookie';
11
  import type { IProviderSetting, ProviderInfo } from '~/types/model';
12
  import { logStore } from '~/lib/stores/logs'; // assuming logStore is imported from this location
 
 
 
 
 
 
 
 
13
 
14
  export function useSettings() {
15
  const providers = useStore(providersStore);
16
  const debug = useStore(isDebugMode);
17
  const eventLogs = useStore(isEventLogsEnabled);
18
  const isLocalModel = useStore(isLocalModelsEnabled);
 
19
  const [activeProviders, setActiveProviders] = useState<ProviderInfo[]>([]);
20
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
21
  // reading values from cookies on mount
22
  useEffect(() => {
23
  const savedProviders = Cookies.get('providers');
@@ -60,6 +91,26 @@ export function useSettings() {
60
  if (savedLocalModels) {
61
  isLocalModelsEnabled.set(savedLocalModels === 'true');
62
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
63
  }, []);
64
 
65
  // writing values to cookies on change
@@ -111,6 +162,12 @@ export function useSettings() {
111
  Cookies.set('isLocalModelsEnabled', String(enabled));
112
  }, []);
113
 
 
 
 
 
 
 
114
  return {
115
  providers,
116
  activeProviders,
@@ -121,5 +178,7 @@ export function useSettings() {
121
  enableEventLogs,
122
  isLocalModel,
123
  enableLocalModels,
 
 
124
  };
125
  }
 
5
  isLocalModelsEnabled,
6
  LOCAL_PROVIDERS,
7
  providersStore,
8
+ latestBranchStore,
9
  } from '~/lib/stores/settings';
10
  import { useCallback, useEffect, useState } from 'react';
11
  import Cookies from 'js-cookie';
12
  import type { IProviderSetting, ProviderInfo } from '~/types/model';
13
  import { logStore } from '~/lib/stores/logs'; // assuming logStore is imported from this location
14
+ import commit from '~/commit.json';
15
+
16
+ interface CommitData {
17
+ commit: string;
18
+ version?: string;
19
+ }
20
+
21
+ const commitJson: CommitData = commit;
22
 
23
  export function useSettings() {
24
  const providers = useStore(providersStore);
25
  const debug = useStore(isDebugMode);
26
  const eventLogs = useStore(isEventLogsEnabled);
27
  const isLocalModel = useStore(isLocalModelsEnabled);
28
+ const latestBranch = useStore(latestBranchStore);
29
  const [activeProviders, setActiveProviders] = useState<ProviderInfo[]>([]);
30
 
31
+ // Function to check if we're on stable version
32
+ const checkIsStableVersion = async () => {
33
+ try {
34
+ const stableResponse = await fetch(
35
+ `https://raw.githubusercontent.com/stackblitz-labs/bolt.diy/refs/tags/v${commitJson.version}/app/commit.json`,
36
+ );
37
+
38
+ if (!stableResponse.ok) {
39
+ console.warn('Failed to fetch stable commit info');
40
+ return false;
41
+ }
42
+
43
+ const stableData = (await stableResponse.json()) as CommitData;
44
+
45
+ return commit.commit === stableData.commit;
46
+ } catch (error) {
47
+ console.warn('Error checking stable version:', error);
48
+ return false;
49
+ }
50
+ };
51
+
52
  // reading values from cookies on mount
53
  useEffect(() => {
54
  const savedProviders = Cookies.get('providers');
 
91
  if (savedLocalModels) {
92
  isLocalModelsEnabled.set(savedLocalModels === 'true');
93
  }
94
+
95
+ // load latest branch setting from cookies or determine based on version
96
+ const savedLatestBranch = Cookies.get('latestBranch');
97
+ let checkCommit = Cookies.get('commitHash');
98
+
99
+ if (checkCommit === undefined) {
100
+ checkCommit = commit.commit;
101
+ }
102
+
103
+ if (savedLatestBranch === undefined || checkCommit !== commit.commit) {
104
+ // If setting hasn't been set by user, check version
105
+ checkIsStableVersion().then((isStable) => {
106
+ const shouldUseLatest = !isStable;
107
+ latestBranchStore.set(shouldUseLatest);
108
+ Cookies.set('latestBranch', String(shouldUseLatest));
109
+ Cookies.set('commitHash', String(commit.commit));
110
+ });
111
+ } else {
112
+ latestBranchStore.set(savedLatestBranch === 'true');
113
+ }
114
  }, []);
115
 
116
  // writing values to cookies on change
 
162
  Cookies.set('isLocalModelsEnabled', String(enabled));
163
  }, []);
164
 
165
+ const enableLatestBranch = useCallback((enabled: boolean) => {
166
+ latestBranchStore.set(enabled);
167
+ logStore.logSystem(`Main branch updates ${enabled ? 'enabled' : 'disabled'}`);
168
+ Cookies.set('latestBranch', String(enabled));
169
+ }, []);
170
+
171
  return {
172
  providers,
173
  activeProviders,
 
178
  enableEventLogs,
179
  isLocalModel,
180
  enableLocalModels,
181
+ latestBranch,
182
+ enableLatestBranch,
183
  };
184
  }
app/lib/stores/settings.ts CHANGED
@@ -46,3 +46,5 @@ export const isDebugMode = atom(false);
46
  export const isEventLogsEnabled = atom(false);
47
 
48
  export const isLocalModelsEnabled = atom(true);
 
 
 
46
  export const isEventLogsEnabled = atom(false);
47
 
48
  export const isLocalModelsEnabled = atom(true);
49
+
50
+ export const latestBranchStore = atom(false);
app/routes/api.chat.ts CHANGED
@@ -1,4 +1,5 @@
1
  import { type ActionFunctionArgs } from '@remix-run/cloudflare';
 
2
  import { MAX_RESPONSE_SEGMENTS, MAX_TOKENS } from '~/lib/.server/llm/constants';
3
  import { CONTINUE_PROMPT } from '~/lib/.server/llm/prompts';
4
  import { streamText, type Messages, type StreamingOptions } from '~/lib/.server/llm/stream-text';
@@ -9,17 +10,15 @@ export async function action(args: ActionFunctionArgs) {
9
  return chatAction(args);
10
  }
11
 
12
- function parseCookies(cookieHeader: string) {
13
- const cookies: any = {};
14
 
15
- // Split the cookie string by semicolons and spaces
16
  const items = cookieHeader.split(';').map((cookie) => cookie.trim());
17
 
18
  items.forEach((item) => {
19
  const [name, ...rest] = item.split('=');
20
 
21
  if (name && rest) {
22
- // Decode the name and value, and join value parts in case it contains '='
23
  const decodedName = decodeURIComponent(name.trim());
24
  const decodedValue = decodeURIComponent(rest.join('=').trim());
25
  cookies[decodedName] = decodedValue;
@@ -36,8 +35,6 @@ async function chatAction({ context, request }: ActionFunctionArgs) {
36
  }>();
37
 
38
  const cookieHeader = request.headers.get('Cookie');
39
-
40
- // Parse the cookie's value (returns an object or null if no cookie exists)
41
  const apiKeys = JSON.parse(parseCookies(cookieHeader || '').apiKeys || '{}');
42
  const providerSettings: Record<string, IProviderSetting> = JSON.parse(
43
  parseCookies(cookieHeader || '').providers || '{}',
@@ -45,12 +42,42 @@ async function chatAction({ context, request }: ActionFunctionArgs) {
45
 
46
  const stream = new SwitchableStream();
47
 
 
 
 
 
 
 
48
  try {
49
  const options: StreamingOptions = {
50
  toolChoice: 'none',
51
- onFinish: async ({ text: content, finishReason }) => {
 
 
 
 
 
 
 
 
52
  if (finishReason !== 'length') {
53
- return stream.close();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
54
  }
55
 
56
  if (stream.switches >= MAX_RESPONSE_SEGMENTS) {
@@ -73,7 +100,7 @@ async function chatAction({ context, request }: ActionFunctionArgs) {
73
  providerSettings,
74
  });
75
 
76
- return stream.switchSource(result.toAIStream());
77
  },
78
  };
79
 
@@ -86,7 +113,7 @@ async function chatAction({ context, request }: ActionFunctionArgs) {
86
  providerSettings,
87
  });
88
 
89
- stream.switchSource(result.toAIStream());
90
 
91
  return new Response(stream.readable, {
92
  status: 200,
@@ -95,7 +122,7 @@ async function chatAction({ context, request }: ActionFunctionArgs) {
95
  },
96
  });
97
  } catch (error: any) {
98
- console.log(error);
99
 
100
  if (error.message?.includes('API key')) {
101
  throw new Response('Invalid or missing API key', {
 
1
  import { type ActionFunctionArgs } from '@remix-run/cloudflare';
2
+ import { createDataStream } from 'ai';
3
  import { MAX_RESPONSE_SEGMENTS, MAX_TOKENS } from '~/lib/.server/llm/constants';
4
  import { CONTINUE_PROMPT } from '~/lib/.server/llm/prompts';
5
  import { streamText, type Messages, type StreamingOptions } from '~/lib/.server/llm/stream-text';
 
10
  return chatAction(args);
11
  }
12
 
13
+ function parseCookies(cookieHeader: string): Record<string, string> {
14
+ const cookies: Record<string, string> = {};
15
 
 
16
  const items = cookieHeader.split(';').map((cookie) => cookie.trim());
17
 
18
  items.forEach((item) => {
19
  const [name, ...rest] = item.split('=');
20
 
21
  if (name && rest) {
 
22
  const decodedName = decodeURIComponent(name.trim());
23
  const decodedValue = decodeURIComponent(rest.join('=').trim());
24
  cookies[decodedName] = decodedValue;
 
35
  }>();
36
 
37
  const cookieHeader = request.headers.get('Cookie');
 
 
38
  const apiKeys = JSON.parse(parseCookies(cookieHeader || '').apiKeys || '{}');
39
  const providerSettings: Record<string, IProviderSetting> = JSON.parse(
40
  parseCookies(cookieHeader || '').providers || '{}',
 
42
 
43
  const stream = new SwitchableStream();
44
 
45
+ const cumulativeUsage = {
46
+ completionTokens: 0,
47
+ promptTokens: 0,
48
+ totalTokens: 0,
49
+ };
50
+
51
  try {
52
  const options: StreamingOptions = {
53
  toolChoice: 'none',
54
+ onFinish: async ({ text: content, finishReason, usage }) => {
55
+ console.log('usage', usage);
56
+
57
+ if (usage) {
58
+ cumulativeUsage.completionTokens += usage.completionTokens || 0;
59
+ cumulativeUsage.promptTokens += usage.promptTokens || 0;
60
+ cumulativeUsage.totalTokens += usage.totalTokens || 0;
61
+ }
62
+
63
  if (finishReason !== 'length') {
64
+ return stream
65
+ .switchSource(
66
+ createDataStream({
67
+ async execute(dataStream) {
68
+ dataStream.writeMessageAnnotation({
69
+ type: 'usage',
70
+ value: {
71
+ completionTokens: cumulativeUsage.completionTokens,
72
+ promptTokens: cumulativeUsage.promptTokens,
73
+ totalTokens: cumulativeUsage.totalTokens,
74
+ },
75
+ });
76
+ },
77
+ onError: (error: any) => `Custom error: ${error.message}`,
78
+ }),
79
+ )
80
+ .then(() => stream.close());
81
  }
82
 
83
  if (stream.switches >= MAX_RESPONSE_SEGMENTS) {
 
100
  providerSettings,
101
  });
102
 
103
+ return stream.switchSource(result.toDataStream());
104
  },
105
  };
106
 
 
113
  providerSettings,
114
  });
115
 
116
+ stream.switchSource(result.toDataStream());
117
 
118
  return new Response(stream.readable, {
119
  status: 200,
 
122
  },
123
  });
124
  } catch (error: any) {
125
+ console.error(error);
126
 
127
  if (error.message?.includes('API key')) {
128
  throw new Response('Invalid or missing API key', {
app/routes/api.enhancer.ts CHANGED
@@ -1,5 +1,6 @@
1
  import { type ActionFunctionArgs } from '@remix-run/cloudflare';
2
- import { StreamingTextResponse, parseStreamPart } from 'ai';
 
3
  import { streamText } from '~/lib/.server/llm/stream-text';
4
  import { stripIndents } from '~/utils/stripIndent';
5
  import type { IProviderSetting, ProviderInfo } from '~/types/model';
@@ -73,32 +74,32 @@ async function enhancerAction({ context, request }: ActionFunctionArgs) {
73
  `[Model: ${model}]\n\n[Provider: ${providerName}]\n\n` +
74
  stripIndents`
75
  You are a professional prompt engineer specializing in crafting precise, effective prompts.
76
- Your task is to enhance prompts by making them more specific, actionable, and effective.
77
-
78
- I want you to improve the user prompt that is wrapped in \`<original_prompt>\` tags.
79
-
80
- For valid prompts:
81
- - Make instructions explicit and unambiguous
82
- - Add relevant context and constraints
83
- - Remove redundant information
84
- - Maintain the core intent
85
- - Ensure the prompt is self-contained
86
- - Use professional language
87
-
88
- For invalid or unclear prompts:
89
- - Respond with a clear, professional guidance message
90
- - Keep responses concise and actionable
91
- - Maintain a helpful, constructive tone
92
- - Focus on what the user should provide
93
- - Use a standard template for consistency
94
-
95
- IMPORTANT: Your response must ONLY contain the enhanced prompt text.
96
- Do not include any explanations, metadata, or wrapper tags.
97
-
98
- <original_prompt>
99
- ${message}
100
- </original_prompt>
101
- `,
102
  },
103
  ],
104
  env: context.cloudflare.env,
@@ -113,7 +114,7 @@ async function enhancerAction({ context, request }: ActionFunctionArgs) {
113
 
114
  for (const line of lines) {
115
  try {
116
- const parsed = parseStreamPart(line);
117
 
118
  if (parsed.type === 'text') {
119
  controller.enqueue(encoder.encode(parsed.value));
@@ -128,7 +129,12 @@ async function enhancerAction({ context, request }: ActionFunctionArgs) {
128
 
129
  const transformedStream = result.toDataStream().pipeThrough(transformStream);
130
 
131
- return new StreamingTextResponse(transformedStream);
 
 
 
 
 
132
  } catch (error: unknown) {
133
  console.log(error);
134
 
 
1
  import { type ActionFunctionArgs } from '@remix-run/cloudflare';
2
+
3
+ //import { StreamingTextResponse, parseStreamPart } from 'ai';
4
  import { streamText } from '~/lib/.server/llm/stream-text';
5
  import { stripIndents } from '~/utils/stripIndent';
6
  import type { IProviderSetting, ProviderInfo } from '~/types/model';
 
74
  `[Model: ${model}]\n\n[Provider: ${providerName}]\n\n` +
75
  stripIndents`
76
  You are a professional prompt engineer specializing in crafting precise, effective prompts.
77
+ Your task is to enhance prompts by making them more specific, actionable, and effective.
78
+
79
+ I want you to improve the user prompt that is wrapped in \`<original_prompt>\` tags.
80
+
81
+ For valid prompts:
82
+ - Make instructions explicit and unambiguous
83
+ - Add relevant context and constraints
84
+ - Remove redundant information
85
+ - Maintain the core intent
86
+ - Ensure the prompt is self-contained
87
+ - Use professional language
88
+
89
+ For invalid or unclear prompts:
90
+ - Respond with clear, professional guidance
91
+ - Keep responses concise and actionable
92
+ - Maintain a helpful, constructive tone
93
+ - Focus on what the user should provide
94
+ - Use a standard template for consistency
95
+
96
+ IMPORTANT: Your response must ONLY contain the enhanced prompt text.
97
+ Do not include any explanations, metadata, or wrapper tags.
98
+
99
+ <original_prompt>
100
+ ${message}
101
+ </original_prompt>
102
+ `,
103
  },
104
  ],
105
  env: context.cloudflare.env,
 
114
 
115
  for (const line of lines) {
116
  try {
117
+ const parsed = JSON.parse(line);
118
 
119
  if (parsed.type === 'text') {
120
  controller.enqueue(encoder.encode(parsed.value));
 
129
 
130
  const transformedStream = result.toDataStream().pipeThrough(transformStream);
131
 
132
+ return new Response(transformedStream, {
133
+ status: 200,
134
+ headers: {
135
+ 'Content-Type': 'text/plain; charset=utf-8',
136
+ },
137
+ });
138
  } catch (error: unknown) {
139
  console.log(error);
140
 
app/utils/constants.ts CHANGED
@@ -141,7 +141,7 @@ const PROVIDER_LIST: ProviderInfo[] = [
141
  staticModels: [
142
  { name: 'llama-3.1-8b-instant', label: 'Llama 3.1 8b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
143
  { name: 'llama-3.2-11b-vision-preview', label: 'Llama 3.2 11b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
144
- { name: 'llama-3.2-90b-vision-preview', label: 'Llama 3.2 90b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
145
  { name: 'llama-3.2-3b-preview', label: 'Llama 3.2 3b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
146
  { name: 'llama-3.2-1b-preview', label: 'Llama 3.2 1b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
147
  { name: 'llama-3.3-70b-versatile', label: 'Llama 3.3 70b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
@@ -499,8 +499,6 @@ async function getLMStudioModels(_apiKeys?: Record<string, string>, settings?: I
499
  }));
500
  } catch (e: any) {
501
  logStore.logError('Failed to get LMStudio models', e, { baseUrl: settings?.baseUrl });
502
- logger.warn('Failed to get LMStudio models: ', e.message || '');
503
-
504
  return [];
505
  }
506
  }
 
141
  staticModels: [
142
  { name: 'llama-3.1-8b-instant', label: 'Llama 3.1 8b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
143
  { name: 'llama-3.2-11b-vision-preview', label: 'Llama 3.2 11b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
144
+ { name: 'llama-3.2-90b-vision-preview', label: 'Llama 3.2 90b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
145
  { name: 'llama-3.2-3b-preview', label: 'Llama 3.2 3b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
146
  { name: 'llama-3.2-1b-preview', label: 'Llama 3.2 1b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
147
  { name: 'llama-3.3-70b-versatile', label: 'Llama 3.3 70b (Groq)', provider: 'Groq', maxTokenAllowed: 8000 },
 
499
  }));
500
  } catch (e: any) {
501
  logStore.logError('Failed to get LMStudio models', e, { baseUrl: settings?.baseUrl });
 
 
502
  return [];
503
  }
504
  }
docs/docs/CONTRIBUTING.md CHANGED
@@ -1,11 +1,5 @@
1
  # Contribution Guidelines
2
 
3
- ## DEFAULT_NUM_CTX
4
-
5
- The `DEFAULT_NUM_CTX` environment variable can be used to limit the maximum number of context values used by the qwen2.5-coder model. For example, to limit the context to 24576 values (which uses 32GB of VRAM), set `DEFAULT_NUM_CTX=24576` in your `.env.local` file.
6
-
7
- First off, thank you for considering contributing to Bolt.diy! This fork aims to expand the capabilities of the original project by integrating multiple LLM providers and enhancing functionality. Every contribution helps make Bolt.diy a better tool for developers worldwide.
8
-
9
  ## 📋 Table of Contents
10
  - [Code of Conduct](#code-of-conduct)
11
  - [How Can I Contribute?](#how-can-i-contribute)
@@ -14,10 +8,14 @@ First off, thank you for considering contributing to Bolt.diy! This fork aims to
14
  - [Development Setup](#development-setup)
15
  - [Deploymnt with Docker](#docker-deployment-documentation)
16
 
 
 
17
  ## Code of Conduct
18
 
19
  This project and everyone participating in it is governed by our Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to the project maintainers.
20
 
 
 
21
  ## How Can I Contribute?
22
 
23
  ### 🐞 Reporting Bugs and Feature Requests
@@ -35,6 +33,8 @@ This project and everyone participating in it is governed by our Code of Conduct
35
  ### ✨ Becoming a Core Contributor
36
  We're looking for dedicated contributors to help maintain and grow this project. If you're interested in becoming a core contributor, please fill out our [Contributor Application Form](https://forms.gle/TBSteXSDCtBDwr5m7).
37
 
 
 
38
  ## Pull Request Guidelines
39
 
40
  ### 📝 PR Checklist
@@ -49,6 +49,8 @@ We're looking for dedicated contributors to help maintain and grow this project.
49
  3. Address all review comments
50
  4. Maintain clean commit history
51
 
 
 
52
  ## Coding Standards
53
 
54
  ### 💻 General Guidelines
@@ -57,6 +59,8 @@ We're looking for dedicated contributors to help maintain and grow this project.
57
  - Keep functions focused and small
58
  - Use meaningful variable names
59
 
 
 
60
  ## Development Setup
61
 
62
  ### 🔄 Initial Setup
@@ -106,6 +110,8 @@ pnpm run dev
106
 
107
  **Note**: You will need Google Chrome Canary to run this locally if you use Chrome! It's an easy install and a good browser for web development anyway.
108
 
 
 
109
  ## Testing
110
 
111
  Run the test suite with:
@@ -114,6 +120,8 @@ Run the test suite with:
114
  pnpm test
115
  ```
116
 
 
 
117
  ## Deployment
118
 
119
  To deploy the application to Cloudflare Pages:
@@ -124,6 +132,8 @@ pnpm run deploy
124
 
125
  Make sure you have the necessary permissions and Wrangler is correctly configured for your Cloudflare account.
126
 
 
 
127
  # Docker Deployment Documentation
128
 
129
  This guide outlines various methods for building and deploying the application using Docker.
@@ -166,6 +176,8 @@ docker-compose --profile development up
166
  docker-compose --profile production up
167
  ```
168
 
 
 
169
  ## Running the Application
170
 
171
  After building using any of the methods above, run the container with:
@@ -178,6 +190,8 @@ docker run -p 5173:5173 --env-file .env.local bolt-ai:development
178
  docker run -p 5173:5173 --env-file .env.local bolt-ai:production
179
  ```
180
 
 
 
181
  ## Deployment with Coolify
182
 
183
  [Coolify](https://github.com/coollabsio/coolify) provides a straightforward deployment process:
@@ -195,6 +209,8 @@ docker run -p 5173:5173 --env-file .env.local bolt-ai:production
195
  - Adjust other environment variables as needed
196
  7. Deploy the application
197
 
 
 
198
  ## VS Code Integration
199
 
200
  The `docker-compose.yaml` configuration is compatible with VS Code dev containers:
@@ -203,6 +219,8 @@ The `docker-compose.yaml` configuration is compatible with VS Code dev container
203
  2. Select the dev container configuration
204
  3. Choose the "development" profile from the context menu
205
 
 
 
206
  ## Environment Files
207
 
208
  Ensure you have the appropriate `.env.local` file configured before running the containers. This file should contain:
@@ -210,6 +228,16 @@ Ensure you have the appropriate `.env.local` file configured before running the
210
  - Environment-specific configurations
211
  - Other required environment variables
212
 
 
 
 
 
 
 
 
 
 
 
213
  ## Notes
214
 
215
  - Port 5173 is exposed and mapped for both development and production environments
 
1
  # Contribution Guidelines
2
 
 
 
 
 
 
 
3
  ## 📋 Table of Contents
4
  - [Code of Conduct](#code-of-conduct)
5
  - [How Can I Contribute?](#how-can-i-contribute)
 
8
  - [Development Setup](#development-setup)
9
  - [Deploymnt with Docker](#docker-deployment-documentation)
10
 
11
+ ---
12
+
13
  ## Code of Conduct
14
 
15
  This project and everyone participating in it is governed by our Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to the project maintainers.
16
 
17
+ ---
18
+
19
  ## How Can I Contribute?
20
 
21
  ### 🐞 Reporting Bugs and Feature Requests
 
33
  ### ✨ Becoming a Core Contributor
34
  We're looking for dedicated contributors to help maintain and grow this project. If you're interested in becoming a core contributor, please fill out our [Contributor Application Form](https://forms.gle/TBSteXSDCtBDwr5m7).
35
 
36
+ ---
37
+
38
  ## Pull Request Guidelines
39
 
40
  ### 📝 PR Checklist
 
49
  3. Address all review comments
50
  4. Maintain clean commit history
51
 
52
+ ---
53
+
54
  ## Coding Standards
55
 
56
  ### 💻 General Guidelines
 
59
  - Keep functions focused and small
60
  - Use meaningful variable names
61
 
62
+ ---
63
+
64
  ## Development Setup
65
 
66
  ### 🔄 Initial Setup
 
110
 
111
  **Note**: You will need Google Chrome Canary to run this locally if you use Chrome! It's an easy install and a good browser for web development anyway.
112
 
113
+ ---
114
+
115
  ## Testing
116
 
117
  Run the test suite with:
 
120
  pnpm test
121
  ```
122
 
123
+ ---
124
+
125
  ## Deployment
126
 
127
  To deploy the application to Cloudflare Pages:
 
132
 
133
  Make sure you have the necessary permissions and Wrangler is correctly configured for your Cloudflare account.
134
 
135
+ ---
136
+
137
  # Docker Deployment Documentation
138
 
139
  This guide outlines various methods for building and deploying the application using Docker.
 
176
  docker-compose --profile production up
177
  ```
178
 
179
+ ---
180
+
181
  ## Running the Application
182
 
183
  After building using any of the methods above, run the container with:
 
190
  docker run -p 5173:5173 --env-file .env.local bolt-ai:production
191
  ```
192
 
193
+ ---
194
+
195
  ## Deployment with Coolify
196
 
197
  [Coolify](https://github.com/coollabsio/coolify) provides a straightforward deployment process:
 
209
  - Adjust other environment variables as needed
210
  7. Deploy the application
211
 
212
+ ---
213
+
214
  ## VS Code Integration
215
 
216
  The `docker-compose.yaml` configuration is compatible with VS Code dev containers:
 
219
  2. Select the dev container configuration
220
  3. Choose the "development" profile from the context menu
221
 
222
+ ---
223
+
224
  ## Environment Files
225
 
226
  Ensure you have the appropriate `.env.local` file configured before running the containers. This file should contain:
 
228
  - Environment-specific configurations
229
  - Other required environment variables
230
 
231
+ ---
232
+
233
+ ## DEFAULT_NUM_CTX
234
+
235
+ The `DEFAULT_NUM_CTX` environment variable can be used to limit the maximum number of context values used by the qwen2.5-coder model. For example, to limit the context to 24576 values (which uses 32GB of VRAM), set `DEFAULT_NUM_CTX=24576` in your `.env.local` file.
236
+
237
+ First off, thank you for considering contributing to bolt.diy! This fork aims to expand the capabilities of the original project by integrating multiple LLM providers and enhancing functionality. Every contribution helps make bolt.diy a better tool for developers worldwide.
238
+
239
+ ---
240
+
241
  ## Notes
242
 
243
  - Port 5173 is exposed and mapped for both development and production environments
docs/docs/FAQ.md CHANGED
@@ -1,15 +1,15 @@
1
  # Frequently Asked Questions (FAQ)
2
 
3
- ## How do I get the best results with Bolt.diy?
4
 
5
  - **Be specific about your stack**:
6
- Mention the frameworks or libraries you want to use (e.g., Astro, Tailwind, ShadCN) in your initial prompt. This ensures that Bolt.diy scaffolds the project according to your preferences.
7
 
8
  - **Use the enhance prompt icon**:
9
  Before sending your prompt, click the *enhance* icon to let the AI refine your prompt. You can edit the suggested improvements before submitting.
10
 
11
  - **Scaffold the basics first, then add features**:
12
- Ensure the foundational structure of your application is in place before introducing advanced functionality. This helps Bolt.diy establish a solid base to build on.
13
 
14
  - **Batch simple instructions**:
15
  Combine simple tasks into a single prompt to save time and reduce API credit consumption. For example:
@@ -17,14 +17,13 @@
17
 
18
  ---
19
 
20
- ## How do I contribute to Bolt.diy?
21
 
22
  Check out our [Contribution Guide](CONTRIBUTING.md) for more details on how to get involved!
23
 
24
  ---
25
 
26
-
27
- ## What are the future plans for Bolt.diy?
28
 
29
  Visit our [Roadmap](https://roadmap.sh/r/ottodev-roadmap-2ovzo) for the latest updates.
30
  New features and improvements are on the way!
@@ -33,13 +32,13 @@ New features and improvements are on the way!
33
 
34
  ## Why are there so many open issues/pull requests?
35
 
36
- Bolt.diy began as a small showcase project on @ColeMedin's YouTube channel to explore editing open-source projects with local LLMs. However, it quickly grew into a massive community effort!
37
 
38
  We’re forming a team of maintainers to manage demand and streamline issue resolution. The maintainers are rockstars, and we’re also exploring partnerships to help the project thrive.
39
 
40
  ---
41
 
42
- ## How do local LLMs compare to larger models like Claude 3.5 Sonnet for Bolt.diy?
43
 
44
  While local LLMs are improving rapidly, larger models like GPT-4o, Claude 3.5 Sonnet, and DeepSeek Coder V2 236b still offer the best results for complex applications. Our ongoing focus is to improve prompts, agents, and the platform to better support smaller local LLMs.
45
 
@@ -73,4 +72,4 @@ Local LLMs like Qwen-2.5-Coder are powerful for small applications but still exp
73
 
74
  ---
75
 
76
- Got more questions? Feel free to reach out or open an issue in our GitHub repo!
 
1
  # Frequently Asked Questions (FAQ)
2
 
3
+ ## How do I get the best results with bolt.diy?
4
 
5
  - **Be specific about your stack**:
6
+ Mention the frameworks or libraries you want to use (e.g., Astro, Tailwind, ShadCN) in your initial prompt. This ensures that bolt.diy scaffolds the project according to your preferences.
7
 
8
  - **Use the enhance prompt icon**:
9
  Before sending your prompt, click the *enhance* icon to let the AI refine your prompt. You can edit the suggested improvements before submitting.
10
 
11
  - **Scaffold the basics first, then add features**:
12
+ Ensure the foundational structure of your application is in place before introducing advanced functionality. This helps bolt.diy establish a solid base to build on.
13
 
14
  - **Batch simple instructions**:
15
  Combine simple tasks into a single prompt to save time and reduce API credit consumption. For example:
 
17
 
18
  ---
19
 
20
+ ## How do I contribute to bolt.diy?
21
 
22
  Check out our [Contribution Guide](CONTRIBUTING.md) for more details on how to get involved!
23
 
24
  ---
25
 
26
+ ## What are the future plans for bolt.diy?
 
27
 
28
  Visit our [Roadmap](https://roadmap.sh/r/ottodev-roadmap-2ovzo) for the latest updates.
29
  New features and improvements are on the way!
 
32
 
33
  ## Why are there so many open issues/pull requests?
34
 
35
+ bolt.diy began as a small showcase project on @ColeMedin's YouTube channel to explore editing open-source projects with local LLMs. However, it quickly grew into a massive community effort!
36
 
37
  We’re forming a team of maintainers to manage demand and streamline issue resolution. The maintainers are rockstars, and we’re also exploring partnerships to help the project thrive.
38
 
39
  ---
40
 
41
+ ## How do local LLMs compare to larger models like Claude 3.5 Sonnet for bolt.diy?
42
 
43
  While local LLMs are improving rapidly, larger models like GPT-4o, Claude 3.5 Sonnet, and DeepSeek Coder V2 236b still offer the best results for complex applications. Our ongoing focus is to improve prompts, agents, and the platform to better support smaller local LLMs.
44
 
 
72
 
73
  ---
74
 
75
+ Got more questions? Feel free to reach out or open an issue in our GitHub repo!
docs/docs/index.md CHANGED
@@ -1,38 +1,46 @@
1
- # Welcome to Bolt DIY
2
- Bolt.diy allows you to choose the LLM that you use for each prompt! Currently, you can use OpenAI, Anthropic, Ollama, OpenRouter, Gemini, LMStudio, Mistral, xAI, HuggingFace, DeepSeek, or Groq models - and it is easily extended to use any other model supported by the Vercel AI SDK! See the instructions below for running this locally and extending it to include more models.
3
 
4
- Join the community!
5
 
6
- https://thinktank.ottomator.ai
7
 
8
- ## Whats Bolt.diy
9
 
10
- Bolt.diy 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)
11
 
12
- ## What Makes Bolt.diy Different
13
 
14
- Claude, v0, etc are incredible- but you can't install packages, run backends, or edit code. That’s where Bolt.diy stands out:
15
 
16
- - **Full-Stack in the Browser**: Bolt.diy integrates cutting-edge AI models with an in-browser development environment powered by **StackBlitz’s WebContainers**. This allows you to:
 
 
 
 
 
 
17
  - Install and run npm tools and libraries (like Vite, Next.js, and more)
18
  - Run Node.js servers
19
  - Interact with third-party APIs
20
  - Deploy to production from chat
21
  - Share your work via a URL
22
 
23
- - **AI with Environment Control**: Unlike traditional dev environments where the AI can only assist in code generation, Bolt.diy gives AI models **complete control** over the entire environment including the filesystem, node server, package manager, terminal, and browser console. This empowers AI agents to handle the whole app lifecycle—from creation to deployment.
24
 
25
- Whether you’re an experienced developer, a PM, or a designer, Bolt.diy allows you to easily build production-grade full-stack applications.
26
 
27
  For developers interested in building their own AI-powered development tools with WebContainers, check out the open-source Bolt codebase in this repo!
28
 
 
 
29
  ## Setup
30
 
31
  Many of you are new users to installing software from Github. If you have any installation troubles reach out and submit an "issue" using the links above, or feel free to enhance this documentation by forking, editing the instructions, and doing a pull request.
32
 
33
- 1. Install Git from https://git-scm.com/downloads
34
 
35
- 2. Install Node.js from https://nodejs.org/en/download/
36
 
37
  Pay attention to the installer notes after completion.
38
 
@@ -62,11 +70,11 @@ defaults write com.apple.finder AppleShowAllFiles YES
62
 
63
  **NOTE**: 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:
64
 
65
- Get your GROQ API Key here: https://console.groq.com/keys
66
 
67
- 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
68
 
69
- Get your Anthropic API Key in your account settings: https://console.anthropic.com/settings/keys
70
 
71
  ```
72
  GROQ_API_KEY=XXX
@@ -128,6 +136,8 @@ When you run the Docker Compose command with the development profile, any change
128
  make on your machine to the code will automatically be reflected in the site running
129
  on the container (i.e. hot reloading still applies!).
130
 
 
 
131
  ## Run Without Docker
132
 
133
  1. Install dependencies using Terminal (or CMD in Windows with admin permissions):
@@ -148,14 +158,18 @@ sudo npm install -g pnpm
148
  pnpm run dev
149
  ```
150
 
 
 
151
  ## Adding New LLMs:
152
 
153
- To make new LLMs available to use in this version of Bolt.diy, 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 label for the frontend model dropdown, and the provider.
154
 
155
  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!
156
 
157
  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!
158
 
 
 
159
  ## Available Scripts
160
 
161
  - `pnpm run dev`: Starts the development server.
@@ -167,6 +181,8 @@ When you add a new model to the MODEL_LIST array, it will immediately be availab
167
  - `pnpm run typegen`: Generates TypeScript types using Wrangler.
168
  - `pnpm run deploy`: Builds the project and deploys it to Cloudflare Pages.
169
 
 
 
170
  ## Development
171
 
172
  To start the development server:
@@ -177,9 +193,11 @@ pnpm run dev
177
 
178
  This will start the Remix Vite development server. You will need Google Chrome Canary to run this locally if you use Chrome! It's an easy install and a good browser for web development anyway.
179
 
 
 
180
  ## Tips and Tricks
181
 
182
- Here are some tips to get the most out of Bolt.diy:
183
 
184
  - **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.
185
 
 
1
+ # Welcome to bolt diy
2
+ bolt.diy allows you to choose the LLM that you use for each prompt! Currently, you can use OpenAI, Anthropic, Ollama, OpenRouter, Gemini, LMStudio, Mistral, xAI, HuggingFace, DeepSeek, or Groq models - and it is easily extended to use any other model supported by the Vercel AI SDK! See the instructions below for running this locally and extending it to include more models.
3
 
4
+ ---
5
 
6
+ ## Join the community!
7
 
8
+ [Join the community!](https://thinktank.ottomator.ai)
9
 
10
+ ---
11
 
12
+ ## Whats bolt.diy
13
 
14
+ bolt.diy 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)
15
 
16
+ ---
17
+
18
+ ## What Makes bolt.diy Different
19
+
20
+ Claude, v0, etc are incredible- but you can't install packages, run backends, or edit code. That’s where bolt.diy stands out:
21
+
22
+ - **Full-Stack in the Browser**: bolt.diy integrates cutting-edge AI models with an in-browser development environment powered by **StackBlitz’s WebContainers**. This allows you to:
23
  - Install and run npm tools and libraries (like Vite, Next.js, and more)
24
  - Run Node.js servers
25
  - Interact with third-party APIs
26
  - Deploy to production from chat
27
  - Share your work via a URL
28
 
29
+ - **AI with Environment Control**: Unlike traditional dev environments where the AI can only assist in code generation, bolt.diy gives AI models **complete control** over the entire environment including the filesystem, node server, package manager, terminal, and browser console. This empowers AI agents to handle the whole app lifecycle—from creation to deployment.
30
 
31
+ Whether you’re an experienced developer, a PM, or a designer, bolt.diy allows you to easily build production-grade full-stack applications.
32
 
33
  For developers interested in building their own AI-powered development tools with WebContainers, check out the open-source Bolt codebase in this repo!
34
 
35
+ ---
36
+
37
  ## Setup
38
 
39
  Many of you are new users to installing software from Github. If you have any installation troubles reach out and submit an "issue" using the links above, or feel free to enhance this documentation by forking, editing the instructions, and doing a pull request.
40
 
41
+ 1. [Install Git from](https://git-scm.com/downloads)
42
 
43
+ 2. [Install Node.js from](https://nodejs.org/en/download/)
44
 
45
  Pay attention to the installer notes after completion.
46
 
 
70
 
71
  **NOTE**: 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:
72
 
73
+ [Get your GROQ API Key here](https://console.groq.com/keys)
74
 
75
+ [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)
76
 
77
+ Get your Anthropic API Key in your [account settings](https://console.anthropic.com/settings/keys)
78
 
79
  ```
80
  GROQ_API_KEY=XXX
 
136
  make on your machine to the code will automatically be reflected in the site running
137
  on the container (i.e. hot reloading still applies!).
138
 
139
+ ---
140
+
141
  ## Run Without Docker
142
 
143
  1. Install dependencies using Terminal (or CMD in Windows with admin permissions):
 
158
  pnpm run dev
159
  ```
160
 
161
+ ---
162
+
163
  ## Adding New LLMs:
164
 
165
+ To make new LLMs available to use in this version of bolt.diy, 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 label for the frontend model dropdown, and the provider.
166
 
167
  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!
168
 
169
  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!
170
 
171
+ ---
172
+
173
  ## Available Scripts
174
 
175
  - `pnpm run dev`: Starts the development server.
 
181
  - `pnpm run typegen`: Generates TypeScript types using Wrangler.
182
  - `pnpm run deploy`: Builds the project and deploys it to Cloudflare Pages.
183
 
184
+ ---
185
+
186
  ## Development
187
 
188
  To start the development server:
 
193
 
194
  This will start the Remix Vite development server. You will need Google Chrome Canary to run this locally if you use Chrome! It's an easy install and a good browser for web development anyway.
195
 
196
+ ---
197
+
198
  ## Tips and Tricks
199
 
200
+ Here are some tips to get the most out of bolt.diy:
201
 
202
  - **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.
203
 
docs/mkdocs.yml CHANGED
@@ -1,4 +1,4 @@
1
- site_name: Bolt.diy Docs
2
  site_dir: ../site
3
  theme:
4
  name: material
@@ -31,7 +31,7 @@ theme:
31
  repo: fontawesome/brands/github
32
  # logo: assets/logo.png
33
  # favicon: assets/logo.png
34
- repo_name: Bolt.diy
35
  repo_url: https://github.com/stackblitz-labs/bolt.diy
36
  edit_uri: ""
37
 
@@ -40,16 +40,16 @@ extra:
40
  social:
41
  - icon: fontawesome/brands/github
42
  link: https://github.com/stackblitz-labs/bolt.diy
43
- name: Bolt.diy
44
  - icon: fontawesome/brands/discourse
45
  link: https://thinktank.ottomator.ai/
46
- name: Bolt.diy Discourse
47
  - icon: fontawesome/brands/x-twitter
48
  link: https://x.com/bolt_diy
49
- name: Bolt.diy on X
50
  - icon: fontawesome/brands/bluesky
51
  link: https://bsky.app/profile/bolt.diy
52
- name: Bolt.diy on Bluesky
53
 
54
 
55
 
 
1
+ site_name: bolt.diy Docs
2
  site_dir: ../site
3
  theme:
4
  name: material
 
31
  repo: fontawesome/brands/github
32
  # logo: assets/logo.png
33
  # favicon: assets/logo.png
34
+ repo_name: bolt.diy
35
  repo_url: https://github.com/stackblitz-labs/bolt.diy
36
  edit_uri: ""
37
 
 
40
  social:
41
  - icon: fontawesome/brands/github
42
  link: https://github.com/stackblitz-labs/bolt.diy
43
+ name: bolt.diy
44
  - icon: fontawesome/brands/discourse
45
  link: https://thinktank.ottomator.ai/
46
+ name: bolt.diy Discourse
47
  - icon: fontawesome/brands/x-twitter
48
  link: https://x.com/bolt_diy
49
+ name: bolt.diy on X
50
  - icon: fontawesome/brands/bluesky
51
  link: https://bsky.app/profile/bolt.diy
52
+ name: bolt.diy on Bluesky
53
 
54
 
55
 
package.json CHANGED
@@ -73,7 +73,7 @@
73
  "@xterm/addon-fit": "^0.10.0",
74
  "@xterm/addon-web-links": "^0.11.0",
75
  "@xterm/xterm": "^5.5.0",
76
- "ai": "^3.4.33",
77
  "date-fns": "^3.6.0",
78
  "diff": "^5.2.0",
79
  "file-saver": "^2.0.5",
 
73
  "@xterm/addon-fit": "^0.10.0",
74
  "@xterm/addon-web-links": "^0.11.0",
75
  "@xterm/xterm": "^5.5.0",
76
+ "ai": "^4.0.13",
77
  "date-fns": "^3.6.0",
78
  "diff": "^5.2.0",
79
  "file-saver": "^2.0.5",
pnpm-lock.yaml CHANGED
@@ -141,8 +141,8 @@ importers:
141
  specifier: ^5.5.0
142
  version: 5.5.0
143
  ai:
144
- specifier: ^3.4.33
145
146
  date-fns:
147
  specifier: ^3.6.0
148
  version: 3.6.0
@@ -351,8 +351,8 @@ packages:
351
  zod:
352
  optional: true
353
 
354
- '@ai-sdk/[email protected].22':
355
- resolution: {integrity: sha512-YHK2rpj++wnLVc9vPGzGFP3Pjeld2MwhKinetA0zKXOoHAT/Jit5O8kZsxcSlJPu9wvcGT1UGZEjZrtO7PfFOQ==}
356
  engines: {node: '>=18'}
357
  peerDependencies:
358
  zod: ^3.0.0
@@ -360,8 +360,8 @@ packages:
360
  zod:
361
  optional: true
362
 
363
- '@ai-sdk/provider-utils@1.0.9':
364
- resolution: {integrity: sha512-yfdanjUiCJbtGoRGXrcrmXn0pTyDfRIeY6ozDG96D66f2wupZaZvAgKptUa3zDYXtUCQQvcNJ+tipBBfQD/UYA==}
365
  engines: {node: '>=18'}
366
  peerDependencies:
367
  zod: ^3.0.0
@@ -369,8 +369,8 @@ packages:
369
  zod:
370
  optional: true
371
 
372
- '@ai-sdk/[email protected].2':
373
- resolution: {integrity: sha512-IAvhKhdlXqiSmvx/D4uNlFYCl8dWT+M9K+IuEcSgnE2Aj27GWu8sDIpAf4r4Voc+wOUkOECVKQhFo8g9pozdjA==}
374
  engines: {node: '>=18'}
375
  peerDependencies:
376
  zod: ^3.0.0
@@ -390,16 +390,16 @@ packages:
390
  resolution: {integrity: sha512-XMsNGJdGO+L0cxhhegtqZ8+T6nn4EoShS819OvCgI2kLbYTIvk0GWFGD0AXJmxkxs3DrpsJxKAFukFR7bvTkgQ==}
391
  engines: {node: '>=18'}
392
 
393
- '@ai-sdk/[email protected]':
394
- resolution: {integrity: sha512-dQkfBDs2lTYpKM8389oopPdQgIU007GQyCbuPPrV+K6MtSII3HBfE0stUIMXUb44L+LK1t6GXPP7wjSzjO6uKg==}
395
- engines: {node: '>=18'}
396
-
397
  '@ai-sdk/[email protected]':
398
  resolution: {integrity: sha512-mV+3iNDkzUsZ0pR2jG0sVzU6xtQY5DtSCBy3JFycLp6PwjyLw/iodfL3MwdmMCRJWgs3dadcHejRnMvF9nGTBg==}
399
  engines: {node: '>=18'}
400
 
401
- '@ai-sdk/react@0.0.70':
402
- resolution: {integrity: sha512-GnwbtjW4/4z7MleLiW+TOZC2M29eCg1tOUpuEiYFMmFNZK8mkrqM0PFZMo6UsYeUYMWqEOOcPOU9OQVJMJh7IQ==}
 
 
 
 
403
  engines: {node: '>=18'}
404
  peerDependencies:
405
  react: ^18 || ^19 || ^19.0.0-rc
@@ -410,26 +410,8 @@ packages:
410
  zod:
411
  optional: true
412
 
413
- '@ai-sdk/solid@0.0.54':
414
- resolution: {integrity: sha512-96KWTVK+opdFeRubqrgaJXoNiDP89gNxFRWUp0PJOotZW816AbhUf4EnDjBjXTLjXL1n0h8tGSE9sZsRkj9wQQ==}
415
- engines: {node: '>=18'}
416
- peerDependencies:
417
- solid-js: ^1.7.7
418
- peerDependenciesMeta:
419
- solid-js:
420
- optional: true
421
-
422
- '@ai-sdk/[email protected]':
423
- resolution: {integrity: sha512-SyF9ItIR9ALP9yDNAD+2/5Vl1IT6kchgyDH8xkmhysfJI6WrvJbtO1wdQ0nylvPLcsPoYu+cAlz1krU4lFHcYw==}
424
- engines: {node: '>=18'}
425
- peerDependencies:
426
- svelte: ^3.0.0 || ^4.0.0 || ^5.0.0
427
- peerDependenciesMeta:
428
- svelte:
429
- optional: true
430
-
431
- '@ai-sdk/[email protected]':
432
- resolution: {integrity: sha512-Z5QYJVW+5XpSaJ4jYCCAVG7zIAuKOOdikhgpksneNmKvx61ACFaf98pmOd+xnjahl0pIlc/QIe6O4yVaJ1sEaw==}
433
  engines: {node: '>=18'}
434
  peerDependencies:
435
  zod: ^3.0.0
@@ -437,15 +419,6 @@ packages:
437
  zod:
438
  optional: true
439
 
440
- '@ai-sdk/[email protected]':
441
- resolution: {integrity: sha512-+ofYlnqdc8c4F6tM0IKF0+7NagZRAiqBJpGDJ+6EYhDW8FHLUP/JFBgu32SjxSxC6IKFZxEnl68ZoP/Z38EMlw==}
442
- engines: {node: '>=18'}
443
- peerDependencies:
444
- vue: ^3.3.4
445
- peerDependenciesMeta:
446
- vue:
447
- optional: true
448
-
449
  '@ampproject/[email protected]':
450
  resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==}
451
  engines: {node: '>=6.0.0'}
@@ -2370,35 +2343,6 @@ packages:
2370
  '@vitest/[email protected]':
2371
  resolution: {integrity: sha512-dwSoui6djdwbfFmIgbIjX2ZhIoG7Ex/+xpxyiEgIGzjliY8xGkcpITKTlp6B4MgtGkF2ilvm97cPM96XZaAgcA==}
2372
 
2373
- '@vue/[email protected]':
2374
- resolution: {integrity: sha512-oOdAkwqUfW1WqpwSYJce06wvt6HljgY3fGeM9NcVA1HaYOij3mZG9Rkysn0OHuyUAGMbEbARIpsG+LPVlBJ5/Q==}
2375
-
2376
- '@vue/[email protected]':
2377
- resolution: {integrity: sha512-ZOJ46sMOKUjO3e94wPdCzQ6P1Lx/vhp2RSvfaab88Ajexs0AHeV0uasYhi99WPaogmBlRHNRuly8xV75cNTMDA==}
2378
-
2379
- '@vue/[email protected]':
2380
- resolution: {integrity: sha512-6VdaljMpD82w6c2749Zhf5T9u5uLBWKnVue6XWxprDobftnletJ8+oel7sexFfM3qIxNmVE7LSFGTpv6obNyaQ==}
2381
-
2382
- '@vue/[email protected]':
2383
- resolution: {integrity: sha512-wMH6vrYHxQl/IybKJagqbquvxpWCuVYpoUJfCqFZwa/JY1GdATAQ+TgVtgrwwMZ0D07QhA99rs/EAAWfvG6KpA==}
2384
-
2385
- '@vue/[email protected]':
2386
- resolution: {integrity: sha512-NaCwtw8o48B9I6L1zl2p41OHo/2Z4wqYGGIK1Khu5T7yxrn+ATOixn/Udn2m+6kZKB/J7cuT9DbWWhRxqixACg==}
2387
-
2388
- '@vue/[email protected]':
2389
- resolution: {integrity: sha512-Fj4YRQ3Az0WTZw1sFe+QDb0aXCerigEpw418pw1HBUKFtnQHWzwojaukAs2X/c9DQz4MQ4bsXTGlcpGxU/RCIw==}
2390
-
2391
- '@vue/[email protected]':
2392
- resolution: {integrity: sha512-dLaj94s93NYLqjLiyFzVs9X6dWhTdAlEAciC3Moq7gzAc13VJUdCnjjRurNM6uTLFATRHexHCTu/Xp3eW6yoog==}
2393
-
2394
- '@vue/[email protected]':
2395
- resolution: {integrity: sha512-wAi4IRJV/2SAW3htkTlB+dHeRmpTiVIK1OGLWV1yeStVSebSQQOwGwIq0D3ZIoBj2C2qpgz5+vX9iEBkTdk5YA==}
2396
- peerDependencies:
2397
- vue: 3.5.13
2398
-
2399
- '@vue/[email protected]':
2400
- resolution: {integrity: sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==}
2401
-
2402
  '@web3-storage/[email protected]':
2403
  resolution: {integrity: sha512-BEO6al7BYqcnfX15W2cnGR+Q566ACXAT9UQykORCWW80lmkpWsnEob6zJS1ZVBKsSJC8+7vJkHwlp+lXG1UCdw==}
2404
 
@@ -2434,11 +2378,6 @@ packages:
2434
  peerDependencies:
2435
  acorn: ^6.0.0 || ^7.0.0 || ^8.0.0
2436
 
2437
2438
- resolution: {integrity: sha512-xsc9Xv0xlVfwp2o7sQ+GCQ1PgbkdcpWdTzrwXxO3xDMTAywVS3oXVOcOHuRjAPkS4P9b+yc/qNF15460v+jp4Q==}
2439
- peerDependencies:
2440
- acorn: '>=8.9.0'
2441
-
2442
2443
  resolution: {integrity: sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==}
2444
  engines: {node: '>=0.4.0'}
@@ -2452,24 +2391,15 @@ packages:
2452
  resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==}
2453
  engines: {node: '>=8'}
2454
 
2455
- ai@3.4.33:
2456
- resolution: {integrity: sha512-plBlrVZKwPoRTmM8+D1sJac9Bq8eaa2jiZlHLZIWekKWI1yMWYZvCCEezY9ASPwRhULYDJB2VhKOBUUeg3S5JQ==}
2457
  engines: {node: '>=18'}
2458
  peerDependencies:
2459
- openai: ^4.42.0
2460
  react: ^18 || ^19 || ^19.0.0-rc
2461
- sswr: ^2.1.0
2462
- svelte: ^3.0.0 || ^4.0.0 || ^5.0.0
2463
  zod: ^3.0.0
2464
  peerDependenciesMeta:
2465
- openai:
2466
- optional: true
2467
  react:
2468
  optional: true
2469
- sswr:
2470
- optional: true
2471
- svelte:
2472
- optional: true
2473
  zod:
2474
  optional: true
2475
 
@@ -2506,10 +2436,6 @@ packages:
2506
  resolution: {integrity: sha512-y+CcFFwelSXpLZk/7fMB2mUbGtX9lKycf1MWJ7CaTIERyitVlyQx6C+sxcROU2BAJ24OiZyK+8wj2i8AlBoS3A==}
2507
  engines: {node: '>=10'}
2508
 
2509
2510
- resolution: {integrity: sha512-COROpnaoap1E2F000S62r6A60uHZnmlvomhfyT2DlTcrY1OrBKn2UhH7qn5wTC9zMvD0AY7csdPSNwKP+7WiQw==}
2511
- engines: {node: '>= 0.4'}
2512
-
2513
2514
  resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==}
2515
 
@@ -2537,10 +2463,6 @@ packages:
2537
  resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==}
2538
  engines: {node: '>= 0.4'}
2539
 
2540
2541
- resolution: {integrity: sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ==}
2542
- engines: {node: '>= 0.4'}
2543
-
2544
2545
  resolution: {integrity: sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw==}
2546
 
@@ -3149,9 +3071,6 @@ packages:
3149
  jiti:
3150
  optional: true
3151
 
3152
3153
- resolution: {integrity: sha512-U9JedYYjCnadUlXk7e1Kr+aENQhtUaoaV9+gZm1T8LC/YBAPJx3NSPIAurFOC0U5vrdSevnUJS2/wUVxGwPhng==}
3154
-
3155
3156
  resolution: {integrity: sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==}
3157
  engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -3164,9 +3083,6 @@ packages:
3164
  resolution: {integrity: sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==}
3165
  engines: {node: '>=0.10'}
3166
 
3167
3168
- resolution: {integrity: sha512-ZlQmCCK+n7SGoqo7DnfKaP1sJZa49P01/dXzmjCASSo04p72w8EksT2NMK8CEX8DhKsfJXANioIw8VyHNsBfvQ==}
3169
-
3170
3171
  resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==}
3172
  engines: {node: '>=4.0'}
@@ -3820,9 +3736,6 @@ packages:
3820
  resolution: {integrity: sha512-9rrA30MRRP3gBD3HTGnC6cDFpaE1kVDWxWgqWJUN0RvDNAo+Nz/9GxB+nHOH0ifbVFy0hSA1V6vFDvnx54lTEQ==}
3821
  engines: {node: '>=14'}
3822
 
3823
3824
- resolution: {integrity: sha512-SW13ws7BjaeJ6p7Q6CO2nchbYEc3X3J6WrmTTDto7yMPqVSZTUyY5Tjbid+Ab8gLnATtygYtiDIJGQRRn2ZOiA==}
3825
-
3826
3827
  resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==}
3828
  engines: {node: '>=10'}
@@ -5190,11 +5103,6 @@ packages:
5190
  resolution: {integrity: sha512-MGrFH9Z4NP9Iyhqn16sDtBpRRNJ0Y2hNa6D65h736fVSaPCHr4DM4sWUNvVaSuC+0OBGhwsrydQwmgfg5LncqQ==}
5191
  engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0}
5192
 
5193
5194
- resolution: {integrity: sha512-Cqc355SYlTAaUt8iDPaC/4DPPXK925PePLMxyBKuWd5kKc5mwsG3nT9+Mq2tyguL5s7b4Jg+IRMpTRsNTAfpSQ==}
5195
- peerDependencies:
5196
- svelte: ^4.0.0 || ^5.0.0-next.0
5197
-
5198
5199
  resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==}
5200
 
@@ -5285,23 +5193,11 @@ packages:
5285
  resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==}
5286
  engines: {node: '>= 0.4'}
5287
 
5288
5289
- resolution: {integrity: sha512-2I/mjD8cXDpKfdfUK+T6yo/OzugMXIm8lhyJUFM5F/gICMYnkl3C/+4cOSpia8TqpDsi6Qfm5+fdmBNMNmaf2g==}
5290
- engines: {node: '>=18'}
5291
-
5292
5293
  resolution: {integrity: sha512-QtxqyclFeAsxEUeZIYmsaQ0UjimSq1RZ9Un7I68/0ClKK/U3LoyQunwkQfJZr2fc22DfIXLNDc2wFyTEikCUpg==}
5294
  peerDependencies:
5295
  react: ^16.11.0 || ^17.0.0 || ^18.0.0
5296
 
5297
5298
- resolution: {integrity: sha512-LqVcOHSB4cPGgitD1riJ1Hh4vdmITOp+BkmfmXRh4hSF/t7EnS4iD+SOTmq7w5pPm/SiPeto4ADbKS6dHUDWFA==}
5299
-
5300
5301
- resolution: {integrity: sha512-zjEkcP8Ywmj+xOJW3lIT65ciY/4AL4e/Or7Gj0MzU3zBJNMdJiT8geVZhINavnlHRMMCcJLHhraLTAiDOTmQ9g==}
5302
- peerDependencies:
5303
- vue: '>=3.2.26 < 4'
5304
-
5305
5306
  resolution: {integrity: sha512-8lD+t2KrrScJ/7KXCSyfhT3/hRq78rC0wBFqNJXv3mZyn6hW2ypM05JmlSvtqRbeq6jqA94oHbxAr2vYsJ8vDA==}
5307
  engines: {node: '>=16.0.0'}
@@ -5721,14 +5617,6 @@ packages:
5721
5722
  resolution: {integrity: sha512-2ham8XPWTONajOR0ohOKOHXkm3+gaBmGut3SRuu75xLd/RRaY6vqgh8NBYYk7+RW3u5AtzPQZG8F10LHkl0lAQ==}
5723
 
5724
5725
- resolution: {integrity: sha512-wmeiSMxkZCSc+PM2w2VRsOYAZC8GdipNFRTsLSfodVqI9mbejKeXEGr8SckuLnrQPGe3oJN5c3K0vpoU9q/wCQ==}
5726
- peerDependencies:
5727
- typescript: '*'
5728
- peerDependenciesMeta:
5729
- typescript:
5730
- optional: true
5731
-
5732
5733
  resolution: {integrity: sha512-dpojBhNsCNN7T82Tm7k26A6G9ML3NkhDsnw9n/eoxSRlVBB4CEtIQ/KTCLI2Fwf3ataSXRhYFkQi3SlnFwPvPQ==}
5734
 
@@ -5843,9 +5731,6 @@ packages:
5843
5844
  resolution: {integrity: sha512-UeVBXie8cA35DS6+nBkls68xaBBXCye0CNznrhszZjTbRVnJKQuNsyLKBTTL4ln1o1rh2PKtv35twV7irj5SEg==}
5845
 
5846
5847
- resolution: {integrity: sha512-rAbqEGa8ovJy4pyBxZM70hg4pE6gDgaQ0Sl9M3enG3I0d6H4XSAM3GeNGLKnsBpuijUow064sf7ww1nutC5/3w==}
5848
-
5849
5850
  resolution: {integrity: sha512-5wlSS0bXfF/BrL4jPAbz9da5hDlDptdEppYfe+x4eIJ7jioqKG9uUxOwPzqof09u/XeVdrgFu29lZi+8XNDJtA==}
5851
  peerDependencies:
@@ -5908,15 +5793,6 @@ snapshots:
5908
  optionalDependencies:
5909
  zod: 3.23.8
5910
 
5911
5912
- dependencies:
5913
- '@ai-sdk/provider': 0.0.26
5914
- eventsource-parser: 1.1.2
5915
- nanoid: 3.3.8
5916
- secure-json-parse: 2.7.0
5917
- optionalDependencies:
5918
- zod: 3.23.8
5919
-
5920
5921
  dependencies:
5922
  '@ai-sdk/provider': 0.0.17
@@ -5935,6 +5811,15 @@ snapshots:
5935
  optionalDependencies:
5936
  zod: 3.23.8
5937
 
 
 
 
 
 
 
 
 
 
5938
  '@ai-sdk/[email protected]':
5939
  dependencies:
5940
  json-schema: 0.4.0
@@ -5947,61 +5832,32 @@ snapshots:
5947
  dependencies:
5948
  json-schema: 0.4.0
5949
 
5950
- '@ai-sdk/provider@0.0.26':
5951
  dependencies:
5952
  json-schema: 0.4.0
5953
 
5954
- '@ai-sdk/[email protected].1':
5955
  dependencies:
5956
  json-schema: 0.4.0
5957
 
5958
- '@ai-sdk/react@0.0.70([email protected])([email protected])':
5959
  dependencies:
5960
- '@ai-sdk/provider-utils': 1.0.22([email protected])
5961
- '@ai-sdk/ui-utils': 0.0.50([email protected])
5962
  swr: 2.2.5([email protected])
5963
  throttleit: 2.1.0
5964
  optionalDependencies:
5965
  react: 18.3.1
5966
  zod: 3.23.8
5967
 
5968
- '@ai-sdk/solid@0.0.54([email protected])':
5969
- dependencies:
5970
- '@ai-sdk/provider-utils': 1.0.22([email protected])
5971
- '@ai-sdk/ui-utils': 0.0.50([email protected])
5972
- transitivePeerDependencies:
5973
- - zod
5974
-
5975
5976
- dependencies:
5977
- '@ai-sdk/provider-utils': 1.0.22([email protected])
5978
- '@ai-sdk/ui-utils': 0.0.50([email protected])
5979
- sswr: 2.1.0([email protected])
5980
- optionalDependencies:
5981
- svelte: 5.4.0
5982
- transitivePeerDependencies:
5983
- - zod
5984
-
5985
5986
  dependencies:
5987
- '@ai-sdk/provider': 0.0.26
5988
- '@ai-sdk/provider-utils': 1.0.22([email protected])
5989
- json-schema: 0.4.0
5990
- secure-json-parse: 2.7.0
5991
  zod-to-json-schema: 3.23.5([email protected])
5992
  optionalDependencies:
5993
  zod: 3.23.8
5994
 
5995
5996
- dependencies:
5997
- '@ai-sdk/provider-utils': 1.0.22([email protected])
5998
- '@ai-sdk/ui-utils': 0.0.50([email protected])
5999
6000
- optionalDependencies:
6001
- vue: 3.5.13([email protected])
6002
- transitivePeerDependencies:
6003
- - zod
6004
-
6005
  '@ampproject/[email protected]':
6006
  dependencies:
6007
  '@jridgewell/gen-mapping': 0.3.5
@@ -8045,60 +7901,6 @@ snapshots:
8045
  loupe: 3.1.2
8046
  tinyrainbow: 1.2.0
8047
 
8048
- '@vue/[email protected]':
8049
- dependencies:
8050
- '@babel/parser': 7.26.2
8051
- '@vue/shared': 3.5.13
8052
- entities: 4.5.0
8053
- estree-walker: 2.0.2
8054
- source-map-js: 1.2.1
8055
-
8056
- '@vue/[email protected]':
8057
- dependencies:
8058
- '@vue/compiler-core': 3.5.13
8059
- '@vue/shared': 3.5.13
8060
-
8061
- '@vue/[email protected]':
8062
- dependencies:
8063
- '@babel/parser': 7.26.2
8064
- '@vue/compiler-core': 3.5.13
8065
- '@vue/compiler-dom': 3.5.13
8066
- '@vue/compiler-ssr': 3.5.13
8067
- '@vue/shared': 3.5.13
8068
- estree-walker: 2.0.2
8069
- magic-string: 0.30.14
8070
- postcss: 8.4.49
8071
- source-map-js: 1.2.1
8072
-
8073
- '@vue/[email protected]':
8074
- dependencies:
8075
- '@vue/compiler-dom': 3.5.13
8076
- '@vue/shared': 3.5.13
8077
-
8078
- '@vue/[email protected]':
8079
- dependencies:
8080
- '@vue/shared': 3.5.13
8081
-
8082
- '@vue/[email protected]':
8083
- dependencies:
8084
- '@vue/reactivity': 3.5.13
8085
- '@vue/shared': 3.5.13
8086
-
8087
- '@vue/[email protected]':
8088
- dependencies:
8089
- '@vue/reactivity': 3.5.13
8090
- '@vue/runtime-core': 3.5.13
8091
- '@vue/shared': 3.5.13
8092
- csstype: 3.1.3
8093
-
8094
8095
- dependencies:
8096
- '@vue/compiler-ssr': 3.5.13
8097
- '@vue/shared': 3.5.13
8098
- vue: 3.5.13([email protected])
8099
-
8100
- '@vue/[email protected]': {}
8101
-
8102
  '@web3-storage/[email protected]': {}
8103
 
8104
  '@webcontainer/[email protected]': {}
@@ -8129,10 +7931,6 @@ snapshots:
8129
  dependencies:
8130
  acorn: 8.14.0
8131
 
8132
8133
- dependencies:
8134
- acorn: 8.14.0
8135
-
8136
8137
  dependencies:
8138
  acorn: 8.14.0
@@ -8144,29 +7942,18 @@ snapshots:
8144
  clean-stack: 2.2.0
8145
  indent-string: 4.0.0
8146
 
8147
8148
  dependencies:
8149
- '@ai-sdk/provider': 0.0.26
8150
- '@ai-sdk/provider-utils': 1.0.22([email protected])
8151
- '@ai-sdk/react': 0.0.70([email protected])([email protected])
8152
- '@ai-sdk/solid': 0.0.54([email protected])
8153
- '@ai-sdk/svelte': 0.0.57([email protected])([email protected])
8154
- '@ai-sdk/ui-utils': 0.0.50([email protected])
8155
8156
  '@opentelemetry/api': 1.9.0
8157
- eventsource-parser: 1.1.2
8158
- json-schema: 0.4.0
8159
  jsondiffpatch: 0.6.0
8160
- secure-json-parse: 2.7.0
8161
  zod-to-json-schema: 3.23.5([email protected])
8162
  optionalDependencies:
8163
  react: 18.3.1
8164
- sswr: 2.1.0([email protected])
8165
- svelte: 5.4.0
8166
  zod: 3.23.8
8167
- transitivePeerDependencies:
8168
- - solid-js
8169
- - vue
8170
 
8171
8172
  dependencies:
@@ -8198,8 +7985,6 @@ snapshots:
8198
  dependencies:
8199
  tslib: 2.8.1
8200
 
8201
8202
-
8203
8204
 
8205
@@ -8230,8 +8015,6 @@ snapshots:
8230
  dependencies:
8231
  possible-typed-array-names: 1.0.0
8232
 
8233
8234
-
8235
8236
 
8237
@@ -8931,8 +8714,6 @@ snapshots:
8931
  transitivePeerDependencies:
8932
  - supports-color
8933
 
8934
8935
-
8936
8937
  dependencies:
8938
  acorn: 8.14.0
@@ -8949,11 +8730,6 @@ snapshots:
8949
  dependencies:
8950
  estraverse: 5.3.0
8951
 
8952
8953
- dependencies:
8954
- '@jridgewell/sourcemap-codec': 1.5.0
8955
- '@types/estree': 1.0.6
8956
-
8957
8958
  dependencies:
8959
  estraverse: 5.3.0
@@ -9680,8 +9456,6 @@ snapshots:
9680
  mlly: 1.7.3
9681
  pkg-types: 1.2.1
9682
 
9683
9684
-
9685
9686
  dependencies:
9687
  p-locate: 5.0.0
@@ -11492,11 +11266,6 @@ snapshots:
11492
  dependencies:
11493
  minipass: 7.1.2
11494
 
11495
11496
- dependencies:
11497
- svelte: 5.4.0
11498
- swrev: 4.0.0
11499
-
11500
11501
 
11502
@@ -11587,34 +11356,12 @@ snapshots:
11587
 
11588
11589
 
11590
11591
- dependencies:
11592
- '@ampproject/remapping': 2.3.0
11593
- '@jridgewell/sourcemap-codec': 1.5.0
11594
- '@types/estree': 1.0.6
11595
- acorn: 8.14.0
11596
- acorn-typescript: 1.4.13([email protected])
11597
- aria-query: 5.3.2
11598
- axobject-query: 4.1.0
11599
- esm-env: 1.2.1
11600
- esrap: 1.2.3
11601
- is-reference: 3.0.3
11602
- locate-character: 3.0.0
11603
- magic-string: 0.30.14
11604
- zimmerframe: 1.1.2
11605
-
11606
11607
  dependencies:
11608
  client-only: 0.0.1
11609
  react: 18.3.1
11610
  use-sync-external-store: 1.2.2([email protected])
11611
 
11612
11613
-
11614
11615
- dependencies:
11616
- vue: 3.5.13([email protected])
11617
-
11618
11619
  dependencies:
11620
  sync-message-port: 1.1.3
@@ -12092,16 +11839,6 @@ snapshots:
12092
 
12093
12094
 
12095
12096
- dependencies:
12097
- '@vue/compiler-dom': 3.5.13
12098
- '@vue/compiler-sfc': 3.5.13
12099
- '@vue/runtime-dom': 3.5.13
12100
- '@vue/server-renderer': 3.5.13([email protected]([email protected]))
12101
- '@vue/shared': 3.5.13
12102
- optionalDependencies:
12103
- typescript: 5.7.2
12104
-
12105
12106
 
12107
@@ -12214,8 +11951,6 @@ snapshots:
12214
  mustache: 4.2.0
12215
  stacktracey: 2.1.8
12216
 
12217
12218
-
12219
12220
  dependencies:
12221
  zod: 3.23.8
 
141
  specifier: ^5.5.0
142
  version: 5.5.0
143
  ai:
144
+ specifier: ^4.0.13
145
146
  date-fns:
147
  specifier: ^3.6.0
148
  version: 3.6.0
 
351
  zod:
352
  optional: true
353
 
354
+ '@ai-sdk/[email protected].9':
355
+ resolution: {integrity: sha512-yfdanjUiCJbtGoRGXrcrmXn0pTyDfRIeY6ozDG96D66f2wupZaZvAgKptUa3zDYXtUCQQvcNJ+tipBBfQD/UYA==}
356
  engines: {node: '>=18'}
357
  peerDependencies:
358
  zod: ^3.0.0
 
360
  zod:
361
  optional: true
362
 
363
+ '@ai-sdk/provider-utils@2.0.2':
364
+ resolution: {integrity: sha512-IAvhKhdlXqiSmvx/D4uNlFYCl8dWT+M9K+IuEcSgnE2Aj27GWu8sDIpAf4r4Voc+wOUkOECVKQhFo8g9pozdjA==}
365
  engines: {node: '>=18'}
366
  peerDependencies:
367
  zod: ^3.0.0
 
369
  zod:
370
  optional: true
371
 
372
+ '@ai-sdk/[email protected].4':
373
+ resolution: {integrity: sha512-GMhcQCZbwM6RoZCri0MWeEWXRt/T+uCxsmHEsTwNvEH3GDjNzchfX25C8ftry2MeEOOn6KfqCLSKomcgK6RoOg==}
374
  engines: {node: '>=18'}
375
  peerDependencies:
376
  zod: ^3.0.0
 
390
  resolution: {integrity: sha512-XMsNGJdGO+L0cxhhegtqZ8+T6nn4EoShS819OvCgI2kLbYTIvk0GWFGD0AXJmxkxs3DrpsJxKAFukFR7bvTkgQ==}
391
  engines: {node: '>=18'}
392
 
 
 
 
 
393
  '@ai-sdk/[email protected]':
394
  resolution: {integrity: sha512-mV+3iNDkzUsZ0pR2jG0sVzU6xtQY5DtSCBy3JFycLp6PwjyLw/iodfL3MwdmMCRJWgs3dadcHejRnMvF9nGTBg==}
395
  engines: {node: '>=18'}
396
 
397
+ '@ai-sdk/provider@1.0.2':
398
+ resolution: {integrity: sha512-YYtP6xWQyaAf5LiWLJ+ycGTOeBLWrED7LUrvc+SQIWhGaneylqbaGsyQL7VouQUeQ4JZ1qKYZuhmi3W56HADPA==}
399
+ engines: {node: '>=18'}
400
+
401
+ '@ai-sdk/[email protected]':
402
+ resolution: {integrity: sha512-8Hkserq0Ge6AEi7N4hlv2FkfglAGbkoAXEZ8YSp255c3PbnZz6+/5fppw+aROmZMOfNwallSRuy1i/iPa2rBpQ==}
403
  engines: {node: '>=18'}
404
  peerDependencies:
405
  react: ^18 || ^19 || ^19.0.0-rc
 
410
  zod:
411
  optional: true
412
 
413
+ '@ai-sdk/ui-utils@1.0.5':
414
+ resolution: {integrity: sha512-DGJSbDf+vJyWmFNexSPUsS1AAy7gtsmFmoSyNbNbJjwl9hRIf2dknfA1V0ahx6pg3NNklNYFm53L8Nphjovfvg==}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
415
  engines: {node: '>=18'}
416
  peerDependencies:
417
  zod: ^3.0.0
 
419
  zod:
420
  optional: true
421
 
 
 
 
 
 
 
 
 
 
422
  '@ampproject/[email protected]':
423
  resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==}
424
  engines: {node: '>=6.0.0'}
 
2343
  '@vitest/[email protected]':
2344
  resolution: {integrity: sha512-dwSoui6djdwbfFmIgbIjX2ZhIoG7Ex/+xpxyiEgIGzjliY8xGkcpITKTlp6B4MgtGkF2ilvm97cPM96XZaAgcA==}
2345
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2346
  '@web3-storage/[email protected]':
2347
  resolution: {integrity: sha512-BEO6al7BYqcnfX15W2cnGR+Q566ACXAT9UQykORCWW80lmkpWsnEob6zJS1ZVBKsSJC8+7vJkHwlp+lXG1UCdw==}
2348
 
 
2378
  peerDependencies:
2379
  acorn: ^6.0.0 || ^7.0.0 || ^8.0.0
2380
 
 
 
 
 
 
2381
2382
  resolution: {integrity: sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==}
2383
  engines: {node: '>=0.4.0'}
 
2391
  resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==}
2392
  engines: {node: '>=8'}
2393
 
2394
+ ai@4.0.18:
2395
+ resolution: {integrity: sha512-BTWzalLNE1LQphEka5xzJXDs5v4xXy1Uzr7dAVk+C/CnO3WNpuMBgrCymwUv0VrWaWc8xMQuh+OqsT7P7JyekQ==}
2396
  engines: {node: '>=18'}
2397
  peerDependencies:
 
2398
  react: ^18 || ^19 || ^19.0.0-rc
 
 
2399
  zod: ^3.0.0
2400
  peerDependenciesMeta:
 
 
2401
  react:
2402
  optional: true
 
 
 
 
2403
  zod:
2404
  optional: true
2405
 
 
2436
  resolution: {integrity: sha512-y+CcFFwelSXpLZk/7fMB2mUbGtX9lKycf1MWJ7CaTIERyitVlyQx6C+sxcROU2BAJ24OiZyK+8wj2i8AlBoS3A==}
2437
  engines: {node: '>=10'}
2438
 
 
 
 
 
2439
2440
  resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==}
2441
 
 
2463
  resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==}
2464
  engines: {node: '>= 0.4'}
2465
 
 
 
 
 
2466
2467
  resolution: {integrity: sha512-0xO6mYd7JB2YesxDKplafRpsiOzPt9V02ddPCLbY1xYGPOX24NTyN50qnUxgCPcSoYMhKpAuBTjQoRZCAkUDRw==}
2468
 
 
3071
  jiti:
3072
  optional: true
3073
 
 
 
 
3074
3075
  resolution: {integrity: sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==}
3076
  engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
 
3083
  resolution: {integrity: sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==}
3084
  engines: {node: '>=0.10'}
3085
 
 
 
 
3086
3087
  resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==}
3088
  engines: {node: '>=4.0'}
 
3736
  resolution: {integrity: sha512-9rrA30MRRP3gBD3HTGnC6cDFpaE1kVDWxWgqWJUN0RvDNAo+Nz/9GxB+nHOH0ifbVFy0hSA1V6vFDvnx54lTEQ==}
3737
  engines: {node: '>=14'}
3738
 
 
 
 
3739
3740
  resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==}
3741
  engines: {node: '>=10'}
 
5103
  resolution: {integrity: sha512-MGrFH9Z4NP9Iyhqn16sDtBpRRNJ0Y2hNa6D65h736fVSaPCHr4DM4sWUNvVaSuC+0OBGhwsrydQwmgfg5LncqQ==}
5104
  engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0}
5105
 
 
 
 
 
 
5106
5107
  resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==}
5108
 
 
5193
  resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==}
5194
  engines: {node: '>= 0.4'}
5195
 
 
 
 
 
5196
5197
  resolution: {integrity: sha512-QtxqyclFeAsxEUeZIYmsaQ0UjimSq1RZ9Un7I68/0ClKK/U3LoyQunwkQfJZr2fc22DfIXLNDc2wFyTEikCUpg==}
5198
  peerDependencies:
5199
  react: ^16.11.0 || ^17.0.0 || ^18.0.0
5200
 
 
 
 
 
 
 
 
 
5201
5202
  resolution: {integrity: sha512-8lD+t2KrrScJ/7KXCSyfhT3/hRq78rC0wBFqNJXv3mZyn6hW2ypM05JmlSvtqRbeq6jqA94oHbxAr2vYsJ8vDA==}
5203
  engines: {node: '>=16.0.0'}
 
5617
5618
  resolution: {integrity: sha512-2ham8XPWTONajOR0ohOKOHXkm3+gaBmGut3SRuu75xLd/RRaY6vqgh8NBYYk7+RW3u5AtzPQZG8F10LHkl0lAQ==}
5619
 
 
 
 
 
 
 
 
 
5620
5621
  resolution: {integrity: sha512-dpojBhNsCNN7T82Tm7k26A6G9ML3NkhDsnw9n/eoxSRlVBB4CEtIQ/KTCLI2Fwf3ataSXRhYFkQi3SlnFwPvPQ==}
5622
 
 
5731
5732
  resolution: {integrity: sha512-UeVBXie8cA35DS6+nBkls68xaBBXCye0CNznrhszZjTbRVnJKQuNsyLKBTTL4ln1o1rh2PKtv35twV7irj5SEg==}
5733
 
 
 
 
5734
5735
  resolution: {integrity: sha512-5wlSS0bXfF/BrL4jPAbz9da5hDlDptdEppYfe+x4eIJ7jioqKG9uUxOwPzqof09u/XeVdrgFu29lZi+8XNDJtA==}
5736
  peerDependencies:
 
5793
  optionalDependencies:
5794
  zod: 3.23.8
5795
 
 
 
 
 
 
 
 
 
 
5796
5797
  dependencies:
5798
  '@ai-sdk/provider': 0.0.17
 
5811
  optionalDependencies:
5812
  zod: 3.23.8
5813
 
5814
5815
+ dependencies:
5816
+ '@ai-sdk/provider': 1.0.2
5817
+ eventsource-parser: 3.0.0
5818
+ nanoid: 3.3.8
5819
+ secure-json-parse: 2.7.0
5820
+ optionalDependencies:
5821
+ zod: 3.23.8
5822
+
5823
  '@ai-sdk/[email protected]':
5824
  dependencies:
5825
  json-schema: 0.4.0
 
5832
  dependencies:
5833
  json-schema: 0.4.0
5834
 
5835
+ '@ai-sdk/provider@1.0.1':
5836
  dependencies:
5837
  json-schema: 0.4.0
5838
 
5839
+ '@ai-sdk/[email protected].2':
5840
  dependencies:
5841
  json-schema: 0.4.0
5842
 
5843
+ '@ai-sdk/react@1.0.6([email protected])([email protected])':
5844
  dependencies:
5845
+ '@ai-sdk/provider-utils': 2.0.4([email protected])
5846
+ '@ai-sdk/ui-utils': 1.0.5([email protected])
5847
  swr: 2.2.5([email protected])
5848
  throttleit: 2.1.0
5849
  optionalDependencies:
5850
  react: 18.3.1
5851
  zod: 3.23.8
5852
 
5853
+ '@ai-sdk/ui-utils@1.0.5([email protected])':
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5854
  dependencies:
5855
+ '@ai-sdk/provider': 1.0.2
5856
+ '@ai-sdk/provider-utils': 2.0.4([email protected])
 
 
5857
  zod-to-json-schema: 3.23.5([email protected])
5858
  optionalDependencies:
5859
  zod: 3.23.8
5860
 
 
 
 
 
 
 
 
 
 
 
5861
  '@ampproject/[email protected]':
5862
  dependencies:
5863
  '@jridgewell/gen-mapping': 0.3.5
 
7901
  loupe: 3.1.2
7902
  tinyrainbow: 1.2.0
7903
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7904
  '@web3-storage/[email protected]': {}
7905
 
7906
  '@webcontainer/[email protected]': {}
 
7931
  dependencies:
7932
  acorn: 8.14.0
7933
 
 
 
 
 
7934
7935
  dependencies:
7936
  acorn: 8.14.0
 
7942
  clean-stack: 2.2.0
7943
  indent-string: 4.0.0
7944
 
7945
7946
  dependencies:
7947
+ '@ai-sdk/provider': 1.0.2
7948
+ '@ai-sdk/provider-utils': 2.0.4([email protected])
7949
+ '@ai-sdk/react': 1.0.6([email protected])([email protected])
7950
+ '@ai-sdk/ui-utils': 1.0.5([email protected])
 
 
 
7951
  '@opentelemetry/api': 1.9.0
 
 
7952
  jsondiffpatch: 0.6.0
 
7953
  zod-to-json-schema: 3.23.5([email protected])
7954
  optionalDependencies:
7955
  react: 18.3.1
 
 
7956
  zod: 3.23.8
 
 
 
7957
 
7958
7959
  dependencies:
 
7985
  dependencies:
7986
  tslib: 2.8.1
7987
 
 
 
7988
7989
 
7990
 
8015
  dependencies:
8016
  possible-typed-array-names: 1.0.0
8017
 
 
 
8018
8019
 
8020
 
8714
  transitivePeerDependencies:
8715
  - supports-color
8716
 
 
 
8717
8718
  dependencies:
8719
  acorn: 8.14.0
 
8730
  dependencies:
8731
  estraverse: 5.3.0
8732
 
 
 
 
 
 
8733
8734
  dependencies:
8735
  estraverse: 5.3.0
 
9456
  mlly: 1.7.3
9457
  pkg-types: 1.2.1
9458
 
 
 
9459
9460
  dependencies:
9461
  p-locate: 5.0.0
 
11266
  dependencies:
11267
  minipass: 7.1.2
11268
 
 
 
 
 
 
11269
11270
 
11271
 
11356
 
11357
11358
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11359
11360
  dependencies:
11361
  client-only: 0.0.1
11362
  react: 18.3.1
11363
  use-sync-external-store: 1.2.2([email protected])
11364
 
 
 
 
 
 
 
11365
11366
  dependencies:
11367
  sync-message-port: 1.1.3
 
11839
 
11840
11841
 
 
 
 
 
 
 
 
 
 
 
11842
11843
 
11844
 
11951
  mustache: 4.2.0
11952
  stacktracey: 2.1.8
11953
 
 
 
11954
11955
  dependencies:
11956
  zod: 3.23.8
public/apple-touch-icon-precomposed.png ADDED
public/apple-touch-icon.png ADDED
public/favicon.ico ADDED
public/icons/Default.svg ADDED
vite.config.ts CHANGED
@@ -19,7 +19,8 @@ export default defineConfig((config) => {
19
  future: {
20
  v3_fetcherPersist: true,
21
  v3_relativeSplatPath: true,
22
- v3_throwAbortReason: true
 
23
  },
24
  }),
25
  UnoCSS(),
 
19
  future: {
20
  v3_fetcherPersist: true,
21
  v3_relativeSplatPath: true,
22
+ v3_throwAbortReason: true,
23
+ v3_lazyRouteDiscovery: true
24
  },
25
  }),
26
  UnoCSS(),