Commit Graph

40 Commits

Author SHA1 Message Date
Stijnus
b5d9055851 🔧 Fix Token Limits & Invalid JSON Response Errors (#1934)
ISSUES FIXED:
-  Invalid JSON response errors during streaming
-  Incorrect token limits causing API rejections
-  Outdated hardcoded model configurations
-  Poor error messages for API failures

SOLUTIONS IMPLEMENTED:

🎯 ACCURATE TOKEN LIMITS & CONTEXT SIZES
- OpenAI GPT-4o: 128k context (was 8k)
- OpenAI GPT-3.5-turbo: 16k context (was 8k)
- Anthropic Claude 3.5 Sonnet: 200k context (was 8k)
- Anthropic Claude 3 Haiku: 200k context (was 8k)
- Google Gemini 1.5 Pro: 2M context (was 8k)
- Google Gemini 1.5 Flash: 1M context (was 8k)
- Groq Llama models: 128k context (was 8k)
- Together models: Updated with accurate limits

�� DYNAMIC MODEL FETCHING ENHANCED
- Smart context detection from provider APIs
- Automatic fallback to known limits when API unavailable
- Safety caps to prevent token overflow (100k max)
- Intelligent model filtering and deduplication

🛡️ IMPROVED ERROR HANDLING
- Specific error messages for Invalid JSON responses
- Token limit exceeded warnings with solutions
- API key validation with clear guidance
- Rate limiting detection and user guidance
- Network timeout handling

 PERFORMANCE OPTIMIZATIONS
- Reduced static models from 40+ to 12 essential
- Enhanced streaming error detection
- Better API response validation
- Improved context window display (shows M/k units)

🔧 TECHNICAL IMPROVEMENTS
- Dynamic model context detection from APIs
- Enhanced streaming reliability
- Better token limit enforcement
- Comprehensive error categorization
- Smart model validation before API calls

IMPACT:
 Eliminates Invalid JSON response errors
 Prevents token limit API rejections
 Provides accurate model capabilities
 Improves user experience with clear errors
 Enables full utilization of modern LLM context windows
2025-08-29 20:53:57 +02:00
Roamin
2b40b8af52 fix(chat): rename processedMessage to processedMessages for clarity 2025-07-11 04:08:34 +00:00
xKevIsDev
26c46088bc feat: enhance error handling for LLM API calls
Add LLM error alert functionality to display specific error messages based on API responses. Introduce new LlmErrorAlertType interface for structured error alerts. Update chat components to manage and display LLM error alerts effectively, improving user feedback during error scenarios.
2025-07-10 18:54:12 +00:00
Roamin
5de162eec8 feat(mcp): add Model Context Protocol integration
Add  MCP integration including:
- New MCP settings tab with server configuration
- Tool invocation UI components
- API endpoints for MCP management
- Integration with chat system for tool execution
- Example configurations
2025-07-10 17:54:15 +00:00
KevIsDev
cd37599f3b feat(design): add design scheme support and UI improvements
- Implement design scheme system with palette, typography, and feature customization
- Add color scheme dialog for user customization
- Update chat UI components to use design scheme values
- Improve header actions with consolidated deploy and export buttons
- Adjust layout spacing and styling across multiple components (chat, workbench etc...)
- Add model and provider info to chat messages
- Refactor workbench and sidebar components for better responsiveness
2025-05-28 23:49:51 +01:00
KevIsDev
2e7b626b00 feat: add discuss mode and quick actions
- Implement discuss mode toggle and UI in chat box
- Add quick action buttons for file, message, implement and link actions
- Extend markdown parser to handle quick action elements
- Update message components to support discuss mode and quick actions
- Add discuss prompt for technical consulting responses
- Refactor chat components to support new functionality

The changes introduce a new discuss mode that allows users to switch between code implementation and technical discussion modes. Quick action buttons provide immediate interaction options like opening files, sending messages, or switching modes.
2025-05-26 16:05:51 +01:00
KevIsDev
bc7e2c5821 feat(supabase): add credentials handling for Supabase API keys and URL
This commit introduces the ability to fetch and store Supabase API keys and URL credentials when a project is selected. This enables the application to dynamically configure the Supabase connection environment variables, improving the integration with Supabase services. The changes include updates to the Supabase connection logic, new API endpoints, and modifications to the chat and prompt components to utilize the new credentials.
2025-03-20 11:17:27 +00:00
KevIsDev
02974089de feat: integrate Supabase for database operations and migrations
Add support for Supabase database operations, including migrations and queries. Implement new Supabase-related types, actions, and components to handle database interactions. Enhance the prompt system to include Supabase-specific instructions and constraints. Ensure data integrity and security by enforcing row-level security and proper migration practices.
2025-03-19 23:11:31 +00:00
Anirban Kar
7016111906 feat: enhanced Code Context and Project Summary Features (#1191)
* fix: docker prod env variable fix

* lint and typecheck

* removed hardcoded tag

* better summary generation

* improved  summary generation for context optimization

* remove think tags from the generation
2025-01-29 15:37:20 +05:30
Anirban Kar
df766c98d4 feat: added support for reasoning content (#1168) 2025-01-25 16:16:19 +05:30
Anirban Kar
3c56346e83 feat: enhance context handling by adding code context selection and implementing summary generation (#1091) #release
* feat: add context annotation types and enhance file handling in LLM processing

* feat: enhance context handling by adding chatId to annotations and implementing summary generation

* removed useless changes

* feat: updated token counts to include optimization requests

* prompt fix

* logging added

* useless logs removed
2025-01-22 22:48:13 +05:30
Anirban Kar
fad41973e2 fix: api-key manager cleanup and log error on llm call (#1077)
* fix: api-key manager cleanup and log error on llm call

* log improved
2025-01-13 04:21:29 +05:30
Anirban Kar
78eb3a5f34 fix: streaming issue fixed for build versions (#1006)
* fix: streaming issue fixed for build versions

* added keep-alive header
2025-01-06 19:18:52 +05:30
Anirban Kar
6494f5ac2e fix: updated logger and model caching minor bugfix #release (#895)
* fix: updated logger and model caching

* usage token stream issue fix

* minor changes

* updated starter template change to fix the app title

* starter template bigfix

* fixed hydretion errors and raw logs

* removed raw log

* made auto select template false by default

* more cleaner logs and updated logic to call dynamicModels only if not found in static models

* updated starter template instructions

* browser console log improved for firefox

* provider icons fix icons
2024-12-31 22:47:32 +05:30
Anirban Kar
3a36a4469a feat: redact file contents from chat and put latest files into system prompt (#904) 2024-12-29 15:36:31 +05:30
Anirban Kar
bb94180209 Merge remote-tracking branch 'origin/main' into system-prompt-variations-local 2024-12-16 20:52:01 +05:30
Anirban Kar
3b8d251a55 updated implementation 2024-12-16 19:47:18 +05:30
eduardruzga
225b553876 Another attempt to add toek usage info 2024-12-16 11:01:41 +02:00
Anirban Kar
70f88f981a feat: Experimental Prompt Library Added 2024-12-15 16:47:16 +05:30
eduardruzga
2e05270bab Merge 2024-12-14 19:48:37 +02:00
Anirban Kar
da37d9456f Merge branch 'main' into context-optimization 2024-12-12 02:44:36 +05:30
Anirban Kar
5d4b860c94 updated to adapth baseurl setup 2024-12-11 14:02:21 +05:30
eduardruzga
fcb61ba499 Refactor to use newver v4 version of Vercel AI package 2024-12-09 17:26:33 +02:00
Anirban Kar
ea5c6244a6 feat(context optimization):improved context management and redused chat overhead 2024-12-07 15:58:13 +05:30
Anirban Kar
7efad13284 list fix 2024-12-06 16:58:04 +05:30
Anirban Kar
5ead47992d Merge branch 'main' into together-ai-dynamic-model-list 2024-12-06 16:35:36 +05:30
Anirban Kar
1589d2a8f5 feat(Dynamic Models): together AI Dynamic Models 2024-12-03 02:13:33 +05:30
Andrew Trokhymenko
7cdb56a847 merge with upstream/main 2024-11-29 22:02:35 -05:00
Oliver Jägle
4589014bda Merge remote-tracking branch 'upstream/main' into linting 2024-11-22 20:38:58 +01:00
Andrew Trokhymenko
074161024d merge with upstream 2024-11-21 23:31:41 -05:00
Andrew Trokhymenko
df94e665d6 picking right model 2024-11-21 18:09:49 -05:00
Oliver Jägle
2327de3810 Lint-fix all files in app 2024-11-21 22:05:35 +01:00
Andrew Trokhymenko
937ba7e61b model pickup 2024-11-21 00:17:06 -05:00
Andrew Trokhymenko
fe3ea8005e changing based on PR review 2024-11-19 20:37:23 -05:00
Andrew Trokhymenko
e78a5b0a05 image-upload 2024-11-18 19:55:28 -05:00
eduardruzga
c575ee316b Use cookies instead of request body that is stale sometimes 2024-11-13 22:20:51 +02:00
ali00209
a544611a56 fix: working 2024-10-29 08:19:30 +05:00
Cole Medin
90a206f2d4 Added the ability to use practically any LLM you can dream of within Bolt.new 2024-10-13 13:53:43 -05:00
Sam Denty
2a29fbbe82 feat: remove authentication (#1) 2024-09-26 17:45:41 +01:00
Sam Denty
6fb59d2bc5 fix: remove monorepo 2024-09-25 19:54:09 +01:00