mirror of
https://github.com/stackblitz-labs/bolt.diy
synced 2025-06-26 18:26:38 +00:00
commit
6accb5311c
1
.gitignore
vendored
1
.gitignore
vendored
@ -27,6 +27,7 @@ dist-ssr
|
|||||||
/build
|
/build
|
||||||
.env.local
|
.env.local
|
||||||
.env
|
.env
|
||||||
|
.dev.vars
|
||||||
*.vars
|
*.vars
|
||||||
.wrangler
|
.wrangler
|
||||||
_worker.bundle
|
_worker.bundle
|
||||||
|
@ -35,6 +35,7 @@ https://thinktank.ottomator.ai
|
|||||||
- ✅ Load local projects into the app (@wonderwhy-er)
|
- ✅ Load local projects into the app (@wonderwhy-er)
|
||||||
- ✅ Together Integration (@mouimet-infinisoft)
|
- ✅ Together Integration (@mouimet-infinisoft)
|
||||||
- ✅ Mobile friendly (@qwikode)
|
- ✅ Mobile friendly (@qwikode)
|
||||||
|
- ✅ Better prompt enhancing (@SujalXplores)
|
||||||
- ⬜ **HIGH PRIORITY** - ALMOST DONE - Attach images to prompts (@atrokhym)
|
- ⬜ **HIGH PRIORITY** - ALMOST DONE - Attach images to prompts (@atrokhym)
|
||||||
- ⬜ **HIGH PRIORITY** - Prevent Bolt from rewriting files as often (file locking and diffs)
|
- ⬜ **HIGH PRIORITY** - Prevent Bolt from rewriting files as often (file locking and diffs)
|
||||||
- ⬜ **HIGH PRIORITY** - Better prompting for smaller LLMs (code window sometimes doesn't start)
|
- ⬜ **HIGH PRIORITY** - Better prompting for smaller LLMs (code window sometimes doesn't start)
|
||||||
@ -43,7 +44,6 @@ https://thinktank.ottomator.ai
|
|||||||
- ⬜ Perplexity Integration
|
- ⬜ Perplexity Integration
|
||||||
- ⬜ Vertex AI Integration
|
- ⬜ Vertex AI Integration
|
||||||
- ⬜ Deploy directly to Vercel/Netlify/other similar platforms
|
- ⬜ Deploy directly to Vercel/Netlify/other similar platforms
|
||||||
- ⬜ Better prompt enhancing
|
|
||||||
- ⬜ Have LLM plan the project in a MD file for better results/transparency
|
- ⬜ Have LLM plan the project in a MD file for better results/transparency
|
||||||
- ⬜ VSCode Integration with git-like confirmations
|
- ⬜ VSCode Integration with git-like confirmations
|
||||||
- ⬜ Upload documents for knowledge - UI design templates, a code base to reference coding style, etc.
|
- ⬜ Upload documents for knowledge - UI design templates, a code base to reference coding style, etc.
|
||||||
|
@ -44,9 +44,25 @@ async function enhancerAction({ context, request }: ActionFunctionArgs) {
|
|||||||
content:
|
content:
|
||||||
`[Model: ${model}]\n\n[Provider: ${providerName}]\n\n` +
|
`[Model: ${model}]\n\n[Provider: ${providerName}]\n\n` +
|
||||||
stripIndents`
|
stripIndents`
|
||||||
|
You are a professional prompt engineer specializing in crafting precise, effective prompts.
|
||||||
|
Your task is to enhance prompts by making them more specific, actionable, and effective.
|
||||||
I want you to improve the user prompt that is wrapped in \`<original_prompt>\` tags.
|
I want you to improve the user prompt that is wrapped in \`<original_prompt>\` tags.
|
||||||
|
|
||||||
IMPORTANT: Only respond with the improved prompt and nothing else!
|
For valid prompts:
|
||||||
|
- Make instructions explicit and unambiguous
|
||||||
|
- Add relevant context and constraints
|
||||||
|
- Remove redundant information
|
||||||
|
- Maintain the core intent
|
||||||
|
- Ensure the prompt is self-contained
|
||||||
|
- Use professional language
|
||||||
|
For invalid or unclear prompts:
|
||||||
|
- Respond with a clear, professional guidance message
|
||||||
|
- Keep responses concise and actionable
|
||||||
|
- Maintain a helpful, constructive tone
|
||||||
|
- Focus on what the user should provide
|
||||||
|
- Use a standard template for consistency
|
||||||
|
IMPORTANT: Your response must ONLY contain the enhanced prompt text.
|
||||||
|
Do not include any explanations, metadata, or wrapper tags.
|
||||||
|
|
||||||
<original_prompt>
|
<original_prompt>
|
||||||
${message}
|
${message}
|
||||||
@ -79,7 +95,7 @@ async function enhancerAction({ context, request }: ActionFunctionArgs) {
|
|||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
const transformedStream = result.toAIStream().pipeThrough(transformStream);
|
const transformedStream = result.toDataStream().pipeThrough(transformStream);
|
||||||
|
|
||||||
return new StreamingTextResponse(transformedStream);
|
return new StreamingTextResponse(transformedStream);
|
||||||
} catch (error: unknown) {
|
} catch (error: unknown) {
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
|
@use '../z-index';
|
||||||
|
|
||||||
[data-resize-handle] {
|
[data-resize-handle] {
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
@ -8,7 +10,7 @@
|
|||||||
bottom: 0;
|
bottom: 0;
|
||||||
left: -6px;
|
left: -6px;
|
||||||
right: -5px;
|
right: -5px;
|
||||||
z-index: $zIndexMax;
|
z-index: z-index.$zIndexMax;
|
||||||
}
|
}
|
||||||
|
|
||||||
&[data-panel-group-direction='vertical']:after {
|
&[data-panel-group-direction='vertical']:after {
|
||||||
@ -18,7 +20,7 @@
|
|||||||
right: 0;
|
right: 0;
|
||||||
top: -5px;
|
top: -5px;
|
||||||
bottom: -6px;
|
bottom: -6px;
|
||||||
z-index: $zIndexMax;
|
z-index: z-index.$zIndexMax;
|
||||||
}
|
}
|
||||||
|
|
||||||
&[data-resize-handle-state='hover']:after,
|
&[data-resize-handle-state='hover']:after,
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
@import './variables.scss';
|
@use 'variables.scss';
|
||||||
@import './z-index.scss';
|
@use 'z-index.scss';
|
||||||
@import './animations.scss';
|
@use 'animations.scss';
|
||||||
@import './components/terminal.scss';
|
@use 'components/terminal.scss';
|
||||||
@import './components/resize-handle.scss';
|
@use 'components/resize-handle.scss';
|
||||||
@import './components/code.scss';
|
@use 'components/code.scss';
|
||||||
@import './components/editor.scss';
|
@use 'components/editor.scss';
|
||||||
@import './components/toast.scss';
|
@use 'components/toast.scss';
|
||||||
|
|
||||||
html,
|
html,
|
||||||
body {
|
body {
|
||||||
|
@ -4,7 +4,13 @@ import { getNamingConventionRule, tsFileExtensions } from '@blitz/eslint-plugin/
|
|||||||
|
|
||||||
export default [
|
export default [
|
||||||
{
|
{
|
||||||
ignores: ['**/dist', '**/node_modules', '**/.wrangler', '**/bolt/build', '**/.history'],
|
ignores: [
|
||||||
|
'**/dist',
|
||||||
|
'**/node_modules',
|
||||||
|
'**/.wrangler',
|
||||||
|
'**/bolt/build',
|
||||||
|
'**/.history',
|
||||||
|
],
|
||||||
},
|
},
|
||||||
...blitzPlugin.configs.recommended(),
|
...blitzPlugin.configs.recommended(),
|
||||||
{
|
{
|
||||||
@ -38,7 +44,7 @@ export default [
|
|||||||
patterns: [
|
patterns: [
|
||||||
{
|
{
|
||||||
group: ['../'],
|
group: ['../'],
|
||||||
message: `Relative imports are not allowed. Please use '~/' instead.`,
|
message: 'Relative imports are not allowed. Please use \'~/\' instead.',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
2
package-lock.json
generated
2
package-lock.json
generated
@ -77,9 +77,7 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@blitz/eslint-plugin": "0.1.0",
|
"@blitz/eslint-plugin": "0.1.0",
|
||||||
"@cloudflare/workers-types": "^4.20241127.0",
|
"@cloudflare/workers-types": "^4.20241127.0",
|
||||||
"@jridgewell/sourcemap-codec": "^1.5.0",
|
|
||||||
"@remix-run/dev": "^2.15.0",
|
"@remix-run/dev": "^2.15.0",
|
||||||
"@rollup/plugin-inject": "^5.0.5",
|
|
||||||
"@types/diff": "^5.2.3",
|
"@types/diff": "^5.2.3",
|
||||||
"@types/file-saver": "^2.0.7",
|
"@types/file-saver": "^2.0.7",
|
||||||
"@types/js-cookie": "^3.0.6",
|
"@types/js-cookie": "^3.0.6",
|
||||||
|
@ -99,9 +99,7 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@blitz/eslint-plugin": "0.1.0",
|
"@blitz/eslint-plugin": "0.1.0",
|
||||||
"@cloudflare/workers-types": "^4.20241127.0",
|
"@cloudflare/workers-types": "^4.20241127.0",
|
||||||
"@jridgewell/sourcemap-codec": "^1.5.0",
|
|
||||||
"@remix-run/dev": "^2.15.0",
|
"@remix-run/dev": "^2.15.0",
|
||||||
"@rollup/plugin-inject": "^5.0.5",
|
|
||||||
"@types/diff": "^5.2.3",
|
"@types/diff": "^5.2.3",
|
||||||
"@types/file-saver": "^2.0.7",
|
"@types/file-saver": "^2.0.7",
|
||||||
"@types/js-cookie": "^3.0.6",
|
"@types/js-cookie": "^3.0.6",
|
||||||
|
@ -216,15 +216,9 @@ importers:
|
|||||||
'@cloudflare/workers-types':
|
'@cloudflare/workers-types':
|
||||||
specifier: ^4.20241127.0
|
specifier: ^4.20241127.0
|
||||||
version: 4.20241127.0
|
version: 4.20241127.0
|
||||||
'@jridgewell/sourcemap-codec':
|
|
||||||
specifier: ^1.5.0
|
|
||||||
version: 1.5.0
|
|
||||||
'@remix-run/dev':
|
'@remix-run/dev':
|
||||||
specifier: ^2.15.0
|
specifier: ^2.15.0
|
||||||
version: 2.15.0(@remix-run/react@2.15.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.7.2))(@types/node@22.10.1)(sass-embedded@1.81.0)(sass@1.77.6)(typescript@5.7.2)(vite@5.4.11(@types/node@22.10.1)(sass-embedded@1.81.0)(sass@1.77.6))(wrangler@3.91.0(@cloudflare/workers-types@4.20241127.0))
|
version: 2.15.0(@remix-run/react@2.15.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.7.2))(@types/node@22.10.1)(sass-embedded@1.81.0)(sass@1.77.6)(typescript@5.7.2)(vite@5.4.11(@types/node@22.10.1)(sass-embedded@1.81.0)(sass@1.77.6))(wrangler@3.91.0(@cloudflare/workers-types@4.20241127.0))
|
||||||
'@rollup/plugin-inject':
|
|
||||||
specifier: ^5.0.5
|
|
||||||
version: 5.0.5(rollup@4.28.0)
|
|
||||||
'@types/diff':
|
'@types/diff':
|
||||||
specifier: ^5.2.3
|
specifier: ^5.2.3
|
||||||
version: 5.2.3
|
version: 5.2.3
|
||||||
|
Loading…
Reference in New Issue
Block a user