-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
💸 feat: Balance Tab in Settings Dialog #6537
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I'd have another idea: ProblemIf you tell people: "you have x$ per day" this is what they expect:
While I find the logic @rubentalstra implemented very good (much better than nightly automatic refill), it seems to be not very intuitive for most users. Solution 1: Education (not sufficient)Naturally education is the first pick. I get asked very often about that, and explain how it is supposed to work. I don't understand why, but many users find it difficult to understand. They just want to know how much they can spend and when they will get more credits. Solution 2: Dynamic Balance ViewThe core question for all users is: How much can I spend currently. So let's answer it: Instead of this:
We could do this:Case 1: next refill date is in the future That way everything is communicated, no open questions. For details about when your next refill will be, you can still look into the detailed panel in settings. What do you think about that? |
I created a suggestion how that could look like: #7330 |
When selecting equations and using copy paste, uses the correct latex code. Co-authored-by: Ruben Talstra <[email protected]>
* 🚀 feat: Add @marsidev/react-turnstile dependency to package.json and package-lock.json * 🚀 feat: Integrate Cloudflare Turnstile configuration support in AppService and add schema validation * 🚀 feat: Implemented Cloudflare Turnstile integration in Login and Registration forms * 🚀 feat: Enhance AppService tests with additional mocks and configuration setups * 🚀 feat: Comment out outdated config version warning tests in AppService.spec.js * 🚀 feat: Remove outdated warning tests and add new checks for environment variables and API health * 🔧 test: Update AppService.spec.js to use expect.anything() for paths validation * 🔧 test: Refactor AppService.spec.js to streamline mocks and enhance clarity * 🔧 chore: removed not needed test * Potential fix for code scanning alert no. 5638: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5629: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5642: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Update turnstile.js * Potential fix for code scanning alert no. 5634: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5646: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5647: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
…ly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
…ly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
* ✨ feat: Enhance Spinner component with customizable properties and improved animation * 🔧 fix: Replace Loader with Spinner in RunCode component and update FilePreview to use Spinner for progress indication * ✨ feat: Refactor icons in CodeProgress and CancelledIcon components; enhance animation and styling in ExecuteCode and ProgressText components * ✨ feat: Refactor attachment handling in ExecuteCode component; replace individual attachment rendering with AttachmentGroup for improved structure * ✨ feat: Refactor dialog components for improved accessibility and styling; integrate Skeleton loading state in Image component * ✨ feat: Refactor ToolCall component to use ToolCallInfo for better structure; replace ToolPopover with AttachmentGroup; enhance ProgressText with error handling and improved UI elements * 🔧 fix: Remove unnecessary whitespace in ProgressText * 🔧 fix: Remove unnecessary margin from AgentFooter and AgentPanel components; clean up SidePanel imports * ✨ feat: Enhance ToolCall and ToolCallInfo components with improved styling; update translations and add warning text color to Tailwind config * 🔧 fix: Update import statement for useLocalize in ToolCallInfo component; fix: chatform transition * ✨ feat: Refactor ToolCall and ToolCallInfo components for improved structure and styling; add optimized code block for better output display * ✨ feat: Implement OpenAI image generation component; add progress tracking and localization for user feedback * 🔧 fix: Adjust base duration values for image generation; optimize timing for quality settings * chore: remove unnecessary space * ✨ feat: Enhance OpenAI image generation with editing capabilities; update localization for progress feedback * ✨ feat: Add download functionality to images; enhance DialogImage component with download button * ✨ feat: Enhance image resizing functionality; support custom percentage and pixel dimensions in resizeImageBuffer
🚨 Unused NPM Packages DetectedThe following unused dependencies were found: 📂 API
|
Hi @rubentalstra there is just eslint issues from what I can see |
I will fix that as we speak. |
8efa774
to
c79ee32
Compare
* chore: bump langchain dependencies * chore: bump @librechat/agents to v2.4.36 * chore: bump @librechat/agents to v2.4.37 * refactor: simplify remark plugins in Markdown component with no conditional usage
* 🔧 chore: Update CONFIG_VERSION to 1.2.6 * 🔧 chore: Update librechat-data-provider version to 0.7.85
* feat: Enhance agent update functionality to track user updates - Updated `updateAgent` function to accept an `updatingUserId` parameter for tracking who made changes. - Modified agent versioning to include `updatedBy` field for better audit trails. - Adjusted related functions and tests to ensure proper handling of user updates and version history. - Enhanced tests to verify correct tracking of `updatedBy` during agent updates and restorations. * fix: Refactor import tests for improved readability and consistency - Adjusted formatting in `importChatGptConvo` test to enhance clarity. - Updated expected output string in `processAssistantMessage` test to use double quotes for consistency. - Modified processing time expectation in `processAssistantMessage` test to allow for CI environment variability.
…#7530) * 🔧 chore: Add missing optional `scraperTimeout` to webSearchSchema * chore: Add missing optional `scraperTimeout` to web search authentication result * chore: linting * feat: Integrate attachment handling and citation processing in message components - Added `useAttachments` hook to manage message attachments and search results. - Updated `MessageParts`, `ContentParts`, and `ContentRender` components to utilize the new hook for improved attachment handling. - Enhanced `useCopyToClipboard` to format citations correctly, including support for composite citations and deduplication. - Introduced utility functions for citation processing and cleanup. - Added tests for the new `useCopyToClipboard` functionality to ensure proper citation formatting and handling. * feat: Add configuration for LibreChat Code Interpreter API and Web Search variables * fix: Update searchResults type to use SearchResultData for better type safety * feat: Add web search configuration validation and logging - Introduced `checkWebSearchConfig` function to validate web search configuration values, ensuring they are environment variable references. - Added logging for proper configuration and warnings for incorrect values. - Created unit tests for `checkWebSearchConfig` to cover various scenarios, including valid and invalid configurations. * docs: Update README to include Web Search feature details - Added a section for the Web Search feature, highlighting its capabilities to search the internet and enhance AI context. - Included links for further information on the Web Search functionality. * ci: Add mock for checkWebSearchConfig in AppService tests * chore: linting * feat: Enhance Shared Messages with Web Search UI by adding searchResults prop to SearchContent and MinimalHoverButtons components * chore: linting * refactor: remove Meilisearch index sync from importConversations function * feat: update safeSearch implementation to use SafeSearchTypes enum * refactor: remove commented-out code in loadTools function * fix: ensure responseMessageId handles latestMessage ID correctly * feat: enhance Vite configuration for improved chunking and caching - Added additional globIgnores for map files in Workbox configuration. - Implemented high-impact chunking for various large libraries to optimize performance. - Increased chunkSizeWarningLimit from 1200 to 1500 for better handling of larger chunks. * refactor: move health check hook to Root, fix bad setState for Temporary state - Enhanced the `useHealthCheck` hook to initiate health checks only when the user is authenticated. - Added logic for managing health check intervals and handling window focus events. - Introduced a new test suite for `useHealthCheck` to cover various scenarios including authentication state changes and error handling. - Removed the health check invocation from `ChatRoute` and added it to `Root` for global health monitoring. * fix: update font alias in Vite configuration for correct path resolution
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
- Updated dependencies to include @langchain/core and @types/winston in both package-lock.json and data-provider package.json.
* 🔧 chore: Update react-resizable-panels dependency to version 3.0.2 in package.json and package-lock.json * fix: Simplify order assignment in SidePanel component based on hasArtifacts condition, fixed frontend crash when artifacts are closed * refactor: Change throttledSaveLayout to use useMemo for improved performance in SidePanelGroup component * refactor: Update dependencies in SidePanel component's useEffect hooks for improved responsiveness
…ts (#7543) * fix: add necessary dep., remove unnecessary dep from useMentions memoization * fix: Migrate deprecated chatGptLabel to modelLabel in cleanupPreset and simplify getPresetTitle logic * fix: Enhance cleanupPreset to remove empty chatGptLabel and add comprehensive tests for label migration and preset handling * chore: Update endpointType prop in PopoverButtons to allow null values for better flexibility * refactor: Replace Dialog with OGDialog in EditPresetDialog for improved UI consistency and structure * style: Update EditPresetDialog layout and styling for improved responsiveness and consistency
* ⚡ refactor: Add Additional Chunking to Vite Config * chore: Integrate rollup-plugin-visualizer for bundle analysis in Vite config & add @codemirror chunks
…uth (#7559) * fix: Add default random state parameter to OpenID auth request for providers that require it; ensure passport strategy uses it * ⌚ refactor: debounce setUserContext to avoid race condition * refactor: Update OpenID authentication to use randomState from openid-client * chore: linting in presetSettings type definition * chore: import order in ModelPanel * refactor: remove `isLegacyOutput` property from AnthropicClient since only used where defined, add latest models to non-legacy patterns, and remove from client cleanup * refactor: adjust grid layout in Parameters component for improved responsiveness * refactor: adjust grid layout in ModelPanel for improved display of model parameters * test: add cases for maxOutputTokens handling in Claude 4 Sonnet and Opus models * ci: mock loadCustomConfig in server tests and refactor OpenID route for improved authentication handling
@danny-avila ESLint issue has been fixed and as well the merge conflict. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces auto-refill settings to the balance feature by enhancing both backend and frontend components. The key changes include:
- Backend: Updated the balance controller and types to include auto-refill settings.
- Frontend: Added new Balance, AutoRefillSettings, and TokenCreditsItem components with updated configuration and localization.
- Data Provider: Updated enum definitions and query types to support the new balance response.
Reviewed Changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
packages/data-provider/src/types.ts | Added new TBalanceResponse type with auto-refill fields. |
packages/data-provider/src/data-service.ts | Updated getUserBalance to return TBalanceResponse. |
packages/data-provider/src/config.ts | Added BALANCE enum value for the settings tab. |
client/src/locales/en/translation.json | Added localization strings for balance auto-refill. |
client/src/data-provider/Misc/queries.ts | Updated useGetUserBalance query typing. |
client/src/components/Nav/SettingsTabs/index.ts | Imported and exported the new Balance tab. |
client/src/components/Nav/SettingsTabs/Balance/TokenCreditsItem.tsx | Introduced a component for displaying token credits. |
client/src/components/Nav/SettingsTabs/Balance/Balance.tsx | Created a new component to integrate token credits and auto-refill display. |
client/src/components/Nav/SettingsTabs/Balance/AutoRefillSettings.tsx | Implemented the UI for displaying auto-refill details. |
client/src/components/Nav/Settings.tsx | Integrated the Balance tab into the main settings interface. |
client/src/components/Nav/AccountSettings.tsx | Updated balance display logic to use tokenCredits from the new response shape. |
client/src/components/Auth/LoginForm.tsx | Removed extraneous whitespace. |
api/server/controllers/Balance.js | Enhanced the balance endpoint to return structured balance data with auto-refill settings. |
{balanceData?.autoRefillEnabled ? ( | ||
<> | ||
<AutoRefillSettings | ||
lastRefill={balanceData.lastRefill!} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using non-null assertions on auto-refill properties (lastRefill, refillAmount, refillIntervalUnit, refillIntervalValue) can lead to runtime errors if any of these fields are unexpectedly undefined. Consider adding explicit runtime checks or providing default values before rendering the AutoRefillSettings component.
Copilot uses AI. Check for mistakes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR implements an Auto-Refill feature in the Balance SettingsTab by extending the backend to return refill settings and updating the frontend to display and manage those settings.
- Backend: Enhance
getUserBalance
controller to include auto-refill fields and handle missing balances. - Data provider: Define
TBalanceResponse
, update service and React query to consume the new response shape. - Frontend UI: Add
Balance
,TokenCreditsItem
, andAutoRefillSettings
components; wire up Balance tab and localization.
Reviewed Changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
packages/data-provider/src/types.ts | Define TBalanceResponse with token credits and refill data |
packages/data-provider/src/data-service.ts | Change getUserBalance to return full balance object |
packages/data-provider/src/config.ts | Add BALANCE to SettingsTabValues enum |
client/src/data-provider/Misc/queries.ts | Update useGetUserBalance to use TBalanceResponse |
client/src/components/Nav/SettingsTabs/Balance/TokenCreditsItem.tsx | New component to show formatted token credits |
client/src/components/Nav/SettingsTabs/Balance/Balance.tsx | New parent component combining credits and refill settings |
client/src/components/Nav/SettingsTabs/Balance/AutoRefillSettings.tsx | New component for auto-refill display |
client/src/locales/en/translation.json | Add localization keys for balance & auto-refill |
client/src/components/Nav/Settings.tsx | Wire Balance tab into main settings UI |
client/src/components/Nav/AccountSettings.tsx | Update account menu to show token credits |
api/server/controllers/Balance.js | Return JSON with auto-refill fields, 404 on missing balance |
Comments suppressed due to low confidence (3)
client/src/components/Nav/SettingsTabs/Balance/AutoRefillSettings.tsx:2
- The
TranslationKeys
import isn’t used in this file. Removing it will clean up the imports.
import { TranslationKeys, useLocalize } from '~/hooks';
client/src/components/Nav/SettingsTabs/Balance/AutoRefillSettings.tsx:1
- No unit tests cover
AutoRefillSettings
. Consider adding tests for scenarios with valid settings, missing fields, and disabled refill.
import React from 'react';
client/src/components/Nav/SettingsTabs/Balance/TokenCreditsItem.tsx:1
- No unit tests cover
TokenCreditsItem
. Add tests to verifytokenCredits.toFixed(2)
formatting and the'0.00'
fallback.
import React from 'react';
autoRefillEnabled: boolean; | ||
refillIntervalValue?: number; | ||
refillIntervalUnit?: 'seconds' | 'minutes' | 'hours' | 'days' | 'weeks' | 'months'; | ||
lastRefill?: Date; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The API returns ISO date strings for lastRefill
, but the type is Date
. This mismatch can cause runtime errors—either change the type to string
or parse the date after fetching.
lastRefill?: Date; | |
lastRefill?: string; |
Copilot uses AI. Check for mistakes.
{/* Left Section: Label */} | ||
<div className="flex items-center space-x-2"> | ||
<Label className="font-light">{localize('com_nav_balance')}</Label> | ||
<HoverCardSettings side="bottom" text="com_nav_info_user_name_display" /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The translation key com_nav_info_user_name_display
appears unrelated to token credits. Update it to a balance-related key (e.g., com_nav_balance_info
).
<HoverCardSettings side="bottom" text="com_nav_info_user_name_display" /> | |
<HoverCardSettings side="bottom" text="com_nav_balance_info" /> |
Copilot uses AI. Check for mistakes.
* 🚀 feat: Implement Auto-Refill Settings for Balance * 🎨 feat: add `copy-tex` to improve copying KaTeX (danny-avila#7308) When selecting equations and using copy paste, uses the correct latex code. Co-authored-by: Ruben Talstra <[email protected]> * 🔃 refactor: `AgentFooter` to conditionally render buttons based on `activePanel` (danny-avila#7306) * 🚀 feat: Add `Cloudflare Turnstile` support (danny-avila#5987) * 🚀 feat: Add @marsidev/react-turnstile dependency to package.json and package-lock.json * 🚀 feat: Integrate Cloudflare Turnstile configuration support in AppService and add schema validation * 🚀 feat: Implemented Cloudflare Turnstile integration in Login and Registration forms * 🚀 feat: Enhance AppService tests with additional mocks and configuration setups * 🚀 feat: Comment out outdated config version warning tests in AppService.spec.js * 🚀 feat: Remove outdated warning tests and add new checks for environment variables and API health * 🔧 test: Update AppService.spec.js to use expect.anything() for paths validation * 🔧 test: Refactor AppService.spec.js to streamline mocks and enhance clarity * 🔧 chore: removed not needed test * Potential fix for code scanning alert no. 5638: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5629: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5642: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Update turnstile.js * Potential fix for code scanning alert no. 5634: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5646: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5647: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5764: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5765: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * 🖼️ feat: Tool Call and Loading UI Refresh, Image Resize Config (danny-avila#7086) * ✨ feat: Enhance Spinner component with customizable properties and improved animation * 🔧 fix: Replace Loader with Spinner in RunCode component and update FilePreview to use Spinner for progress indication * ✨ feat: Refactor icons in CodeProgress and CancelledIcon components; enhance animation and styling in ExecuteCode and ProgressText components * ✨ feat: Refactor attachment handling in ExecuteCode component; replace individual attachment rendering with AttachmentGroup for improved structure * ✨ feat: Refactor dialog components for improved accessibility and styling; integrate Skeleton loading state in Image component * ✨ feat: Refactor ToolCall component to use ToolCallInfo for better structure; replace ToolPopover with AttachmentGroup; enhance ProgressText with error handling and improved UI elements * 🔧 fix: Remove unnecessary whitespace in ProgressText * 🔧 fix: Remove unnecessary margin from AgentFooter and AgentPanel components; clean up SidePanel imports * ✨ feat: Enhance ToolCall and ToolCallInfo components with improved styling; update translations and add warning text color to Tailwind config * 🔧 fix: Update import statement for useLocalize in ToolCallInfo component; fix: chatform transition * ✨ feat: Refactor ToolCall and ToolCallInfo components for improved structure and styling; add optimized code block for better output display * ✨ feat: Implement OpenAI image generation component; add progress tracking and localization for user feedback * 🔧 fix: Adjust base duration values for image generation; optimize timing for quality settings * chore: remove unnecessary space * ✨ feat: Enhance OpenAI image generation with editing capabilities; update localization for progress feedback * ✨ feat: Add download functionality to images; enhance DialogImage component with download button * ✨ feat: Enhance image resizing functionality; support custom percentage and pixel dimensions in resizeImageBuffer * 📊 feat: Improve Helm Chart (danny-avila#3638) * Replaced Helm Charts with Blue Atlas Charts * Fix Workflow * improve docs * update gitignore * Update docs * change values order, add hpa * change tls example domain * Default: Enable liveness and readiness * chore: bump base chart * apply requested changes * add Release fix * add: error handling * chore: cleanup and testing * fix: adjust Chart.yaml --------- Co-authored-by: hofq <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 📜 docs: Unreleased Changelog (danny-avila#7434) * action: update Unreleased changelog * Update CHANGELOG.md --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> * 🛡️ chore: `multer` v2.0.0 for CVE-2025-47935 and CVE-2025-47944 (danny-avila#7454) * chore: bump multer to v2.0.0 to resolve CVE-2025-47935 and CVE-2025-47944 * chore: temp. remove helmet dependency to appease unused NPM package workflow * 🎚️ feat: Custom Parameters (danny-avila#7342) * # * - refactor: simplified getCustomConfig func * # * - feature: persist values for parameters with optionType of custom * # * - refactor: moved `Parameters/settings.ts` into `data-provider` so that both frontend and backend code can use it. * - feature: loadCustomConfig can now parse and validate customParams property for `endpoints.custom` in `librechat.yaml` * # fixed linter * # removed .strict() in config.ts * change: added packages/data-provider/src to SOURCE_DIRS for i18n check * # removed unnecessary lodash imports * # addressed PR comments # fixed lint for updated files * # better import for lodash (w/o relying on tree-shaking) * 📃 fix: Ensure MCP Resources Pass Name and Description Fields to LLM (danny-avila#7442) * 🔗 feat: Support Environment Variables in MCP URL Config (danny-avila#7424) * 🦙 chore: Add `llama-4` to Vision Models List (danny-avila#7433) * 🔧 fix: File Deletion for Azure Assistants API (danny-avila#7466) * 🔬 fix: File Search Request Format (Azure Assistants API) (danny-avila#7404) * fix: The request format for file analysis with Azure OpenAI assistants The request format for file analysis with Azure OpenAI assistants differs from that of OpenAI. This fix updates the API to use attachments instead of file_ids. danny-avila#7379 * chore: ESLint Error --------- Co-authored-by: Danny Avila <[email protected]> * 🖼️ chore: Linting & Transition Styling in UI Components (danny-avila#7467) * chore: linting * 🔧 fix: Correctly parse dimensions for image width and height in OpenAIImageGen component * style: overlay class for DialogImage component to improve visibility * style: Update transition timing function for PixelCard component to rely on style props * ✅ fix: Emojis rendering in `SplitText` Animation (danny-avila#7460) * 📂 refactor: Improve `FileAttachment` & File Form Deletion (danny-avila#7471) * refactor: optional attachment properties for `FileAttachment` * refactor: update ActionButton to use localized text * chore: localize text in DataTableFile, add missing translation, imports order, and linting * chore: linting in DataTable * fix: integrate Recoil state management for file deletion in DataTableFile * fix: integrate Recoil state management for file deletion in DataTable * fix: add temp_file_id to BatchFile type and update deleteFiles logic to properly remove files that are mapped to temp_file_id * 🌍 i18n: Update translation.json with latest translations (danny-avila#7468) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🦾 feat: Claude-4 Support (danny-avila#7509) * refactor: Update AnthropicClient to support Claude model naming changes * Renamed `isClaude3` to `isClaudeLatest` to accommodate newer Claude models. * Updated logic to determine if the model is part of the Claude family. * Adjusted `useMessages` property to reflect the new model naming convention. * Cleaned up client properties during disposal to match the updated naming. * feat: Claude-4 Support * feat: Add Thinking and Prompt caching support for Claude 4 * chore: Update ANTHROPIC_MODELS in .env.example for latest model versions * 📊 chore: Remove Old Helm Chart (danny-avila#7512) Co-authored-by: hofq <[email protected]> * 🪨 feat: Bedrock Support for Claude-4 Reasoning (danny-avila#7517) * 🗑️ chore: Update .gitignore to reflect AI-related files * chore: linting in Bedrock options.js * 🪨 feat: Bedrock Claude-4 Reasoning * 🪖 chore: bump helm app version to v0.7.8 (danny-avila#7524) - bump helm app version to match the latest release version * ⌛ feat: Agent Version History and Management (danny-avila#7455) * ✨ feat: Enhance agent update functionality to save current state in versions array - Updated the `updateAgent` function to push the current agent's state into a new `versions` array when an agent is updated. - Modified the agent schema to include a `versions` field for storing historical states of agents. * ✨ feat: Add comprehensive CRUD operations for agents in tests - Introduced a new test suite for CRUD operations on agents, including create, read, update, and delete functionalities. - Implemented tests for listing agents by author and updating agent projects. - Enhanced the agent model to support version history tracking during updates. - Ensured proper environment variable management during tests. * ✨ feat: Introduce version tracking for agents and enhance UI components - Added a `version` property to the agent model to track the number of versions. - Updated the `getAgentHandler` to include the agent's version in the response. - Introduced a new `VersionButton` component for navigating to the version panel. - Created a `VersionPanel` component for displaying version-related information. - Updated the UI to conditionally render the version button and panel based on the active state. - Added localization for the new version-related UI elements. * ✨ i18n: Add "version" translation key across multiple languages - Introduced the "com_ui_agent_version" translation key in various language files to support version tracking for agents. - Updated Arabic, Czech, German, English, Spanish, Estonian, Persian, Finnish, French, Hebrew, Hungarian, Indonesian, Italian, Japanese, Korean, Dutch, Polish, Portuguese (Brazil and Portugal), Russian, Swedish, Thai, Turkish, Vietnamese, and Chinese (Simplified and Traditional) translations. * ✨ feat: Update AgentFooter to conditionally render AdminSettings - Modified the logic for displaying buttons in the AgentFooter component to only show them when the active panel is the builder. - Ensured that AdminSettings is displayed only when the user has an admin role and the buttons are visible. * ✨ feat: Enhance AgentPanelSwitch and VersionPanel for improved agent capabilities - Updated AgentPanelSwitch to include a new VersionPanel for displaying version-related information. - Enhanced agentsConfig logic to properly handle agent capabilities. - Modified VersionPanel to improve structure and localization support. - Integrated createAgent mutation for future agent creation functionality. * ✨ feat: Enhance VersionPanel to display agent version history and loading states - Integrated version fetching logic in VersionPanel to retrieve and display agent version history. - Added loading and error handling states to improve user experience. - Updated agent schema to use mixed types for versions, allowing for more flexible version data structures. - Introduced localization support for version-related UI elements. * ✨ feat: Update VersionPanel and AgentPanelSwitch to enhance agent selection and version display - Modified AgentPanelSwitch to pass selectedAgentId to VersionPanel for improved agent context. - Enhanced VersionPanel to handle multiple timestamp formats and display appropriate messages when no agent is selected. - Improved structure and readability of the VersionPanel component by adding a helper function for timestamp retrieval. * ✨ feat: Refactor VersionPanel to utilize localization and improve timestamp handling - Replaced hardcoded text constants with localization support for various UI elements in VersionPanel. - Enhanced the timestamp retrieval function to handle errors gracefully and utilize localized messages for unknown dates. - Improved user feedback by displaying localized messages for agent selection, version errors, and empty states. * ✨ refactor: Clean up VersionPanel by removing unused code and improving timestamp handling * ✨ feat: Implement agent version reverting functionality - Added `revertAgentVersion` method in the Agent model to allow reverting to a previous version of an agent. - Introduced `revertAgentVersionHandler` in the agents controller to handle requests for reverting agent versions. - Updated API routes to include a new endpoint for reverting agent versions. - Enhanced the VersionPanel component to support version restoration with user confirmation and feedback. - Added localization support for success and error messages related to version restoration. * ✨ i18n: Add localization for agent version restoration messages * Simplify VersionPanel by removing unused parameters and enhancing agent ID handling * Refactor Agent model and VersionPanel component to streamline version data handling * Update version handling in Agent model and VersionPanel - Enhanced the Agent model to include an `updatedAt` timestamp when pushing new versions. - Improved the VersionPanel component to sort versions by the `updatedAt` timestamp for better display order. - Added a new localization entry for indicating the active version of an agent. * ✨ i18n: Add localization for active agent version across multiple languages * ✨ feat: Introduce version management components for agent history - Added `isActiveVersion` utility to determine the active version of an agent based on various criteria. - Implemented `VersionContent` and `VersionItem` components to display agent version history, including loading and error states. - Enhanced `VersionPanel` to integrate new components and manage version context effectively. - Added comprehensive tests for version management functionalities to ensure reliability and correctness. * Add unit tests for AgentFooter component * cleanup * Enhance agent version update handling and add unit tests for update operators - Updated the `updateAgent` function to properly handle various update operators ($push, $pull, $addToSet) while maintaining version history. - Modified unit tests to validate the correct behavior of agent updates, including versioning and tool management. * Enhance version comparison logic and update tests for artifacts handling - Modified the `isActiveVersion` utility to include artifacts in the version comparison criteria. - Updated the `VersionPanel` component to support artifacts in the agent state. - Added new unit tests to validate artifacts matching scenarios and edge cases in the `isActiveVersion` function. * Implement duplicate version detection in agent updates and enhance error handling - Added `isDuplicateVersion` function to check for identical versions during agent updates, excluding certain fields. - Updated `updateAgent` function to throw an error if a duplicate version is detected, with detailed error information. - Enhanced the `updateAgentHandler` to return appropriate responses for duplicate version errors. - Modified client-side error handling to display user-friendly messages for duplicate version scenarios. - Added comprehensive unit tests to validate duplicate version detection and error handling across various update scenarios. * Update version title localization to include version number across multiple languages - Modified the `com_ui_agent_version_title` translation key to include a placeholder for the version number in various language files. - Enhanced the `VersionItem` component to utilize the updated localization for displaying version titles dynamically. * Enhance agent version handling and add revert functionality - Updated the `isDuplicateVersion` function to improve version comparison logic, including special handling for `projectIds` and arrays of objects. - Modified the `updateAgent` function to streamline version updates and removed unnecessary checks for test environments. - Introduced a new `revertAgentVersion` function to allow reverting agents to specific versions, with detailed documentation. - Enhanced unit tests to validate duplicate version detection and revert functionality, ensuring robust error handling and version management. * fix CI issues * cleanup * Revert all non-English translations * clean up tests * *️⃣ feat: Reuse OpenID Auth Tokens (danny-avila#7397) * feat: integrate OpenID Connect support with token reuse - Added `jwks-rsa` and `new-openid-client` dependencies for OpenID Connect functionality. - Implemented OpenID token refresh logic in `AuthController`. - Enhanced `LogoutController` to handle OpenID logout and session termination. - Updated JWT authentication middleware to support OpenID token provider. - Modified OAuth routes to accommodate OpenID authentication and token management. - Created `setOpenIDAuthTokens` function to manage OpenID tokens in cookies. - Upgraded OpenID strategy with user info fetching and token exchange protocol. - Introduced `openIdJwtLogin` strategy for handling OpenID JWT tokens. - Added caching mechanism for exchanged OpenID tokens. - Updated configuration to include OpenID exchanged tokens cache key. - updated .env.example to include the new env variables needed for the feature. * fix: update return type in downloadImage documentation for clarity and fixed openIdJwtLogin env variables * fix: update Jest configuration and tests for OpenID strategy integration * fix: update OpenID strategy to include callback URL in setup * fix: fix optionalJwtAuth middleware to support OpenID token reuse and improve currentUrl method in CustomOpenIDStrategy to override the dynamic host issue related to proxy (e.g. cloudfront) * fix: fixed code formatting * Fix: Add mocks for openid-client and passport strategy in Jest configuration to fix unit tests * fix eslint errors: Format mock file openid-client. * ✨ feat: Add PKCE support for OpenID and default handling in strategy setup --------- Co-authored-by: Atef Bellaaj <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 🔎 feat: Native Web Search with Citation References (danny-avila#7516) * WIP: search tool integration * WIP: Add web search capabilities and API key management to agent actions * WIP: web search capability to agent configuration and selection * WIP: Add web search capability to backend agent configuration * WIP: add web search option to default agent form values * WIP: add attachments for web search * feat: add plugin for processing web search citations * WIP: first pass, Citation UI * chore: remove console.log * feat: Add AnimatedTabs component for tabbed UI functionality * refactor: AnimatedTabs component with CSS animations and stable ID generation * WIP example content * feat: SearchContext for managing search results apart from MessageContext * feat: Enhance AnimatedTabs with underline animation and state management * WIP: first pass, Implement dynamic tab functionality in Sources component with search results integration * fix: Update class names for improved styling in Sources and AnimatedTabs components * feat: Improve styling and layout in Sources component with enhanced button and item designs * feat: Refactor Sources component to integrate OGDialog for source display and improve layout * style: Update background color in SourceItem and SourcesGroup components for improved visibility * refactor: Sources component to enhance SourceItem structure and improve favicon handling * style: Adjust font size of domain text in SourceItem for better readability * feat: Add localization for citation source and details in CompositeCitation component * style: add theming to Citation components * feat: Enhance SourceItem component with dialog support and improved hovercard functionality * feat: Add localization for sources tab and image alt text in Sources component * style: Replace divs with spans for better semantic structure in CompositeCitation and Citation components * refactor: Sources component to use useMemo for tab generation and improve performance * chore: bump @librechat/agents to v2.4.318 * chore: update search result types * fix: search results retrieval in ContentParts component, re-render attachments when expected * feat: update sources style/types to use latest search result structure * style: enhance Dialog (expanded) SourceItem component with link wrapping and improved styling * style: update ImageItem component styling for improved title visibility * refactor: remove SourceItemBase component and adjust SourceItem layout for improved styling * chore: linting twcss order * fix: prevent FileAttachment from rendering search attachments * fix: append underscore to responseMessageId for unique identification to prevent mapping of previous latest message's attachments * chore: remove unused parameter 'useSpecs' from loadTools function * chore: twcss order * WIP: WebSearch Tool UI * refactor: add limit parameter to StackedFavicons for customizable source display * refactor: optimize search results memoization by making more granular and separate conerns * refactor: integrated StackedFavicons to WebSearch mid-run * chore: bump @librechat/agents to expose handleToolCallChunks * chore: use typedefs from dedicated file instead of defining them in AgentClient module * WIP: first pass, search progress results * refactor: move createOnSearchResults function to a dedicated search module * chore: bump @librechat/agents to v2.4.320 * WIP: first pass, search results processed UX * refactor: consolidate context variables in createOnSearchResults function * chore: bump @librechat/agents to v2.4.321 * feat: add guidelines for web search tool response formatting in loadTools function * feat: add isLast prop to Part component and update WebSearch logic for improved state handling * style: update Hovercard styles for improved UI consistency * feat: export FaviconImage component for improved accessibility in other modules * refactor: export getCleanDomain function and use FaviconImage in Citation component for improved source representation * refactor: implement SourceHovercard component for consistency and DRY compliance * fix: replace <p> with <span> for snippet and title in SourceItem and SourceHovercard for consistency * style: `not-prose` * style: remove 'not-prose' class for consistency in SourceItem, Citation, and SourceHovercard components, adjust style classes * refactor: `imageUrl` on hover and prevent duplicate sources * refactor: enhance SourcesGroup dialog layout and improve source item presentation * refactor: reorganize Web Components, save in same directory * feat: add 'news' refType to refTypeMap for citation sources * style: adjust Hovercard width for improved layout * refactor: update tool usage guidelines for improved clarity and execution * chore: linting * feat: add Web Search badge with initial permissions and local storage logic * feat: add webSearch support to interface and permissions schemas * feat: implement Web Search API key management and localization updates * feat: refactor Web Search API key handling and integrate new search API key form * fix: remove unnecessary visibility state from FileAttachment component * feat: update WebSearch component to use Globe icon and localized search label * feat: enhance ApiKeyDialog with dropdown for reranker selection and update translations * feat: implement dropdown menus for engine, scraper, and reranker selection in ApiKeyDialog * chore: linting and add unknown instead of `any` type * feat: refactor ApiKeyDialog and useAuthSearchTool for improved API key management * refactor: update ocrSchema to use template literals for default apiKey and baseURL * feat: add web search configuration and utility functions for environment variable extraction * fix: ensure filepath is defined before checking its prefix in useAttachmentHandler * feat: enhance web search functionality with improved configuration and environment variable extraction for authFields * fix: update auth type in TPluginAction and TUpdateUserPlugins to use Partial<Record<string, string>> * feat: implement web search authentication verification and enhance webSearchAuth structure * feat: enhance ephemeral agent handling with new web search capability and type definition * feat: enhance isEphemeralAgent function to include web search selection * feat: refactor verifyWebSearchAuth to improve key handling and authentication checks * feat: implement loadWebSearchAuth function for improved web search authentication handling * feat: enhance web search authentication with new configuration options and refactor related types * refactor: rename search engine to search provider and update related localization keys * feat: update verifyWebSearchAuth to handle multiple authentication types and improve error handling * feat: update ApiKeyDialog to accept authTypes prop and remove isUserProvided check * feat: add tests for extractWebSearchEnvVars and loadWebSearchAuth functions * feat: enhance loadWebSearchAuth to support specific service checks for providers, scrapers, and rerankers * fix: update web search configuration key and adjust auth result handling in loadTools function * feat: add new progress key for repeated web searching and update localization * chore: bump @librechat/agents to 2.4.322 * feat: enhance loadTools function to include ISO time and improve search tool logging * feat: update StackedFavicons to handle negative start index and improve citation attribution styling and text * chore: update .gitignore to categorize AI-related files * fix: mobile responsiveness of sources/citations hovercards * feat: enhance source display with improved line clamping for better readability * chore: bump @librechat/agents to v2.4.33 * feat: add handling for image sources in references mapping * chore: bump librechat-data-provider version to 0.7.84 * chore: bump @librechat/agents version to 2.4.34 * fix: update auth handling to support multiple auth types in tools and allow key configuration in agent panel * chore: remove redundant agent attribution text from search form * fix: web search auth uninstall * refactor: convert CheckboxButton to a forwardRef component and update setValue callback signature * feat: add triggerRef prop to ApiKeyDialog components for improved dialog control * feat: integrate triggerRef in CodeInterpreter and WebSearch components for enhanced dialog management * feat: enhance ApiKeyDialog with additional links for Firecrawl and Jina API key guidance * feat: implement web search configuration handling in ApiKeyDialog and add tests for dropdown visibility * fix: update webSearchConfig reference in config route for correct payload assignment * feat: update ApiKeyDialog to conditionally render sections based on authTypes and modify loadWebSearchAuth to correctly categorize authentication types * feat: refactor ApiKeyDialog and related tests to use SearchCategories and RerankerTypes enums and remove nested ternaries * refactor: move ThinkingButton rendering to improve layout consistency in ContentParts * feat: integrate search context into Markdown component to conditionally include unicodeCitation plugin * chore: bump @librechat/agents to v2.4.35 * chore: remove unused 18n key * ci: add WEB_SEARCH permission testing and update AppService tests for new webSearch configuration * ci: add more comprehensive tests for loadWebSearchAuth to validate authentication handling and authTypes structure * chore: remove debugging console log from web.spec.ts to clean up test output * 🧹 chore: Bump Agents Dependencies (danny-avila#7525) * chore: bump langchain dependencies * chore: bump @librechat/agents to v2.4.36 * chore: bump @librechat/agents to v2.4.37 * refactor: simplify remark plugins in Markdown component with no conditional usage * 🔧 refactor: Progress Text Localization for Running Tools (danny-avila#7526) * 🔧 chore: Bump Data Provider and Custom Config Versions (danny-avila#7527) * 🔧 chore: Update CONFIG_VERSION to 1.2.6 * 🔧 chore: Update librechat-data-provider version to 0.7.85 * 👤 feat: Enhance Agent Versioning to Track User Updates (danny-avila#7523) * feat: Enhance agent update functionality to track user updates - Updated `updateAgent` function to accept an `updatingUserId` parameter for tracking who made changes. - Modified agent versioning to include `updatedBy` field for better audit trails. - Adjusted related functions and tests to ensure proper handling of user updates and version history. - Enhanced tests to verify correct tracking of `updatedBy` during agent updates and restorations. * fix: Refactor import tests for improved readability and consistency - Adjusted formatting in `importChatGptConvo` test to enhance clarity. - Updated expected output string in `processAssistantMessage` test to use double quotes for consistency. - Modified processing time expectation in `processAssistantMessage` test to allow for CI environment variability. * 🧩 feat: Web Search Config Validations & Clipboard Citation Processing (danny-avila#7530) * 🔧 chore: Add missing optional `scraperTimeout` to webSearchSchema * chore: Add missing optional `scraperTimeout` to web search authentication result * chore: linting * feat: Integrate attachment handling and citation processing in message components - Added `useAttachments` hook to manage message attachments and search results. - Updated `MessageParts`, `ContentParts`, and `ContentRender` components to utilize the new hook for improved attachment handling. - Enhanced `useCopyToClipboard` to format citations correctly, including support for composite citations and deduplication. - Introduced utility functions for citation processing and cleanup. - Added tests for the new `useCopyToClipboard` functionality to ensure proper citation formatting and handling. * feat: Add configuration for LibreChat Code Interpreter API and Web Search variables * fix: Update searchResults type to use SearchResultData for better type safety * feat: Add web search configuration validation and logging - Introduced `checkWebSearchConfig` function to validate web search configuration values, ensuring they are environment variable references. - Added logging for proper configuration and warnings for incorrect values. - Created unit tests for `checkWebSearchConfig` to cover various scenarios, including valid and invalid configurations. * docs: Update README to include Web Search feature details - Added a section for the Web Search feature, highlighting its capabilities to search the internet and enhance AI context. - Included links for further information on the Web Search functionality. * ci: Add mock for checkWebSearchConfig in AppService tests * chore: linting * feat: Enhance Shared Messages with Web Search UI by adding searchResults prop to SearchContent and MinimalHoverButtons components * chore: linting * refactor: remove Meilisearch index sync from importConversations function * feat: update safeSearch implementation to use SafeSearchTypes enum * refactor: remove commented-out code in loadTools function * fix: ensure responseMessageId handles latestMessage ID correctly * feat: enhance Vite configuration for improved chunking and caching - Added additional globIgnores for map files in Workbox configuration. - Implemented high-impact chunking for various large libraries to optimize performance. - Increased chunkSizeWarningLimit from 1200 to 1500 for better handling of larger chunks. * refactor: move health check hook to Root, fix bad setState for Temporary state - Enhanced the `useHealthCheck` hook to initiate health checks only when the user is authenticated. - Added logic for managing health check intervals and handling window focus events. - Introduced a new test suite for `useHealthCheck` to cover various scenarios including authentication state changes and error handling. - Removed the health check invocation from `ChatRoute` and added it to `Root` for global health monitoring. * fix: update font alias in Vite configuration for correct path resolution * 🌍 i18n: Update translation.json with latest translations (danny-avila#7532) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🔧 chore: Update data-provider dependencies for typing (danny-avila#7533) - Updated dependencies to include @langchain/core and @types/winston in both package-lock.json and data-provider package.json. * 🔧 fix: Artifacts Display Crash on Close and Max Width (danny-avila#7540) * 🔧 chore: Update react-resizable-panels dependency to version 3.0.2 in package.json and package-lock.json * fix: Simplify order assignment in SidePanel component based on hasArtifacts condition, fixed frontend crash when artifacts are closed * refactor: Change throttledSaveLayout to use useMemo for improved performance in SidePanelGroup component * refactor: Update dependencies in SidePanel component's useEffect hooks for improved responsiveness * 🏷️ refactor: EditPresetDialog UI and Remove `chatGptLabel` from Presets (danny-avila#7543) * fix: add necessary dep., remove unnecessary dep from useMentions memoization * fix: Migrate deprecated chatGptLabel to modelLabel in cleanupPreset and simplify getPresetTitle logic * fix: Enhance cleanupPreset to remove empty chatGptLabel and add comprehensive tests for label migration and preset handling * chore: Update endpointType prop in PopoverButtons to allow null values for better flexibility * refactor: Replace Dialog with OGDialog in EditPresetDialog for improved UI consistency and structure * style: Update EditPresetDialog layout and styling for improved responsiveness and consistency * 📦 refactor: Add Additional Chunking to Vite Config (danny-avila#7544) * ⚡ refactor: Add Additional Chunking to Vite Config * chore: Integrate rollup-plugin-visualizer for bundle analysis in Vite config & add @codemirror chunks * ⌚ fix: Debounce `setUserContext` and Default State Param for OpenID Auth (danny-avila#7559) * fix: Add default random state parameter to OpenID auth request for providers that require it; ensure passport strategy uses it * ⌚ refactor: debounce setUserContext to avoid race condition * refactor: Update OpenID authentication to use randomState from openid-client * chore: linting in presetSettings type definition * chore: import order in ModelPanel * refactor: remove `isLegacyOutput` property from AnthropicClient since only used where defined, add latest models to non-legacy patterns, and remove from client cleanup * refactor: adjust grid layout in Parameters component for improved responsiveness * refactor: adjust grid layout in ModelPanel for improved display of model parameters * test: add cases for maxOutputTokens handling in Claude 4 Sonnet and Opus models * ci: mock loadCustomConfig in server tests and refactor OpenID route for improved authentication handling * 🚀 feat: Implement Auto-Refill Settings for Balance * fix: ESLint * ✨ feat: Enhance Auto-Refill Settings with Validation and Localization --------- Co-authored-by: andresgit <[email protected]> Co-authored-by: matt burnett <[email protected]> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> Co-authored-by: Marco Beretta <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Theo N. Truong <[email protected]> Co-authored-by: René Honig <[email protected]> Co-authored-by: Ben Verhees <[email protected]> Co-authored-by: Amgad Hasan <[email protected]> Co-authored-by: arthurolivierfortin <[email protected]> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Sebastien Bruel <[email protected]> Co-authored-by: Austin Barrington <[email protected]> Co-authored-by: Peter <[email protected]> Co-authored-by: Atef Bellaaj <[email protected]>
* 🚀 feat: Implement Auto-Refill Settings for Balance * 🎨 feat: add `copy-tex` to improve copying KaTeX (danny-avila#7308) When selecting equations and using copy paste, uses the correct latex code. Co-authored-by: Ruben Talstra <[email protected]> * 🔃 refactor: `AgentFooter` to conditionally render buttons based on `activePanel` (danny-avila#7306) * 🚀 feat: Add `Cloudflare Turnstile` support (danny-avila#5987) * 🚀 feat: Add @marsidev/react-turnstile dependency to package.json and package-lock.json * 🚀 feat: Integrate Cloudflare Turnstile configuration support in AppService and add schema validation * 🚀 feat: Implemented Cloudflare Turnstile integration in Login and Registration forms * 🚀 feat: Enhance AppService tests with additional mocks and configuration setups * 🚀 feat: Comment out outdated config version warning tests in AppService.spec.js * 🚀 feat: Remove outdated warning tests and add new checks for environment variables and API health * 🔧 test: Update AppService.spec.js to use expect.anything() for paths validation * 🔧 test: Refactor AppService.spec.js to streamline mocks and enhance clarity * 🔧 chore: removed not needed test * Potential fix for code scanning alert no. 5638: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5629: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5642: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Update turnstile.js * Potential fix for code scanning alert no. 5634: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5646: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5647: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5764: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5765: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * 🖼️ feat: Tool Call and Loading UI Refresh, Image Resize Config (danny-avila#7086) * ✨ feat: Enhance Spinner component with customizable properties and improved animation * 🔧 fix: Replace Loader with Spinner in RunCode component and update FilePreview to use Spinner for progress indication * ✨ feat: Refactor icons in CodeProgress and CancelledIcon components; enhance animation and styling in ExecuteCode and ProgressText components * ✨ feat: Refactor attachment handling in ExecuteCode component; replace individual attachment rendering with AttachmentGroup for improved structure * ✨ feat: Refactor dialog components for improved accessibility and styling; integrate Skeleton loading state in Image component * ✨ feat: Refactor ToolCall component to use ToolCallInfo for better structure; replace ToolPopover with AttachmentGroup; enhance ProgressText with error handling and improved UI elements * 🔧 fix: Remove unnecessary whitespace in ProgressText * 🔧 fix: Remove unnecessary margin from AgentFooter and AgentPanel components; clean up SidePanel imports * ✨ feat: Enhance ToolCall and ToolCallInfo components with improved styling; update translations and add warning text color to Tailwind config * 🔧 fix: Update import statement for useLocalize in ToolCallInfo component; fix: chatform transition * ✨ feat: Refactor ToolCall and ToolCallInfo components for improved structure and styling; add optimized code block for better output display * ✨ feat: Implement OpenAI image generation component; add progress tracking and localization for user feedback * 🔧 fix: Adjust base duration values for image generation; optimize timing for quality settings * chore: remove unnecessary space * ✨ feat: Enhance OpenAI image generation with editing capabilities; update localization for progress feedback * ✨ feat: Add download functionality to images; enhance DialogImage component with download button * ✨ feat: Enhance image resizing functionality; support custom percentage and pixel dimensions in resizeImageBuffer * 📊 feat: Improve Helm Chart (danny-avila#3638) * Replaced Helm Charts with Blue Atlas Charts * Fix Workflow * improve docs * update gitignore * Update docs * change values order, add hpa * change tls example domain * Default: Enable liveness and readiness * chore: bump base chart * apply requested changes * add Release fix * add: error handling * chore: cleanup and testing * fix: adjust Chart.yaml --------- Co-authored-by: hofq <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 📜 docs: Unreleased Changelog (danny-avila#7434) * action: update Unreleased changelog * Update CHANGELOG.md --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> * 🛡️ chore: `multer` v2.0.0 for CVE-2025-47935 and CVE-2025-47944 (danny-avila#7454) * chore: bump multer to v2.0.0 to resolve CVE-2025-47935 and CVE-2025-47944 * chore: temp. remove helmet dependency to appease unused NPM package workflow * 🎚️ feat: Custom Parameters (danny-avila#7342) * # * - refactor: simplified getCustomConfig func * # * - feature: persist values for parameters with optionType of custom * # * - refactor: moved `Parameters/settings.ts` into `data-provider` so that both frontend and backend code can use it. * - feature: loadCustomConfig can now parse and validate customParams property for `endpoints.custom` in `librechat.yaml` * # fixed linter * # removed .strict() in config.ts * change: added packages/data-provider/src to SOURCE_DIRS for i18n check * # removed unnecessary lodash imports * # addressed PR comments * # better import for lodash (w/o relying on tree-shaking) * 📃 fix: Ensure MCP Resources Pass Name and Description Fields to LLM (danny-avila#7442) * 🔗 feat: Support Environment Variables in MCP URL Config (danny-avila#7424) * 🦙 chore: Add `llama-4` to Vision Models List (danny-avila#7433) * 🔧 fix: File Deletion for Azure Assistants API (danny-avila#7466) * 🔬 fix: File Search Request Format (Azure Assistants API) (danny-avila#7404) * fix: The request format for file analysis with Azure OpenAI assistants The request format for file analysis with Azure OpenAI assistants differs from that of OpenAI. This fix updates the API to use attachments instead of file_ids. danny-avila#7379 * chore: ESLint Error --------- Co-authored-by: Danny Avila <[email protected]> * 🖼️ chore: Linting & Transition Styling in UI Components (danny-avila#7467) * chore: linting * 🔧 fix: Correctly parse dimensions for image width and height in OpenAIImageGen component * style: overlay class for DialogImage component to improve visibility * style: Update transition timing function for PixelCard component to rely on style props * ✅ fix: Emojis rendering in `SplitText` Animation (danny-avila#7460) * 📂 refactor: Improve `FileAttachment` & File Form Deletion (danny-avila#7471) * refactor: optional attachment properties for `FileAttachment` * refactor: update ActionButton to use localized text * chore: localize text in DataTableFile, add missing translation, imports order, and linting * chore: linting in DataTable * fix: integrate Recoil state management for file deletion in DataTableFile * fix: integrate Recoil state management for file deletion in DataTable * fix: add temp_file_id to BatchFile type and update deleteFiles logic to properly remove files that are mapped to temp_file_id * 🌍 i18n: Update translation.json with latest translations (danny-avila#7468) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🦾 feat: Claude-4 Support (danny-avila#7509) * refactor: Update AnthropicClient to support Claude model naming changes * Renamed `isClaude3` to `isClaudeLatest` to accommodate newer Claude models. * Updated logic to determine if the model is part of the Claude family. * Adjusted `useMessages` property to reflect the new model naming convention. * Cleaned up client properties during disposal to match the updated naming. * feat: Claude-4 Support * feat: Add Thinking and Prompt caching support for Claude 4 * chore: Update ANTHROPIC_MODELS in .env.example for latest model versions * 📊 chore: Remove Old Helm Chart (danny-avila#7512) Co-authored-by: hofq <[email protected]> * 🪨 feat: Bedrock Support for Claude-4 Reasoning (danny-avila#7517) * 🗑️ chore: Update .gitignore to reflect AI-related files * chore: linting in Bedrock options.js * 🪨 feat: Bedrock Claude-4 Reasoning * 🪖 chore: bump helm app version to v0.7.8 (danny-avila#7524) - bump helm app version to match the latest release version * ⌛ feat: Agent Version History and Management (danny-avila#7455) * ✨ feat: Enhance agent update functionality to save current state in versions array - Updated the `updateAgent` function to push the current agent's state into a new `versions` array when an agent is updated. - Modified the agent schema to include a `versions` field for storing historical states of agents. * ✨ feat: Add comprehensive CRUD operations for agents in tests - Introduced a new test suite for CRUD operations on agents, including create, read, update, and delete functionalities. - Implemented tests for listing agents by author and updating agent projects. - Enhanced the agent model to support version history tracking during updates. - Ensured proper environment variable management during tests. * ✨ feat: Introduce version tracking for agents and enhance UI components - Added a `version` property to the agent model to track the number of versions. - Updated the `getAgentHandler` to include the agent's version in the response. - Introduced a new `VersionButton` component for navigating to the version panel. - Created a `VersionPanel` component for displaying version-related information. - Updated the UI to conditionally render the version button and panel based on the active state. - Added localization for the new version-related UI elements. * ✨ i18n: Add "version" translation key across multiple languages - Introduced the "com_ui_agent_version" translation key in various language files to support version tracking for agents. - Updated Arabic, Czech, German, English, Spanish, Estonian, Persian, Finnish, French, Hebrew, Hungarian, Indonesian, Italian, Japanese, Korean, Dutch, Polish, Portuguese (Brazil and Portugal), Russian, Swedish, Thai, Turkish, Vietnamese, and Chinese (Simplified and Traditional) translations. * ✨ feat: Update AgentFooter to conditionally render AdminSettings - Modified the logic for displaying buttons in the AgentFooter component to only show them when the active panel is the builder. - Ensured that AdminSettings is displayed only when the user has an admin role and the buttons are visible. * ✨ feat: Enhance AgentPanelSwitch and VersionPanel for improved agent capabilities - Updated AgentPanelSwitch to include a new VersionPanel for displaying version-related information. - Enhanced agentsConfig logic to properly handle agent capabilities. - Modified VersionPanel to improve structure and localization support. - Integrated createAgent mutation for future agent creation functionality. * ✨ feat: Enhance VersionPanel to display agent version history and loading states - Integrated version fetching logic in VersionPanel to retrieve and display agent version history. - Added loading and error handling states to improve user experience. - Updated agent schema to use mixed types for versions, allowing for more flexible version data structures. - Introduced localization support for version-related UI elements. * ✨ feat: Update VersionPanel and AgentPanelSwitch to enhance agent selection and version display - Modified AgentPanelSwitch to pass selectedAgentId to VersionPanel for improved agent context. - Enhanced VersionPanel to handle multiple timestamp formats and display appropriate messages when no agent is selected. - Improved structure and readability of the VersionPanel component by adding a helper function for timestamp retrieval. * ✨ feat: Refactor VersionPanel to utilize localization and improve timestamp handling - Replaced hardcoded text constants with localization support for various UI elements in VersionPanel. - Enhanced the timestamp retrieval function to handle errors gracefully and utilize localized messages for unknown dates. - Improved user feedback by displaying localized messages for agent selection, version errors, and empty states. * ✨ refactor: Clean up VersionPanel by removing unused code and improving timestamp handling * ✨ feat: Implement agent version reverting functionality - Added `revertAgentVersion` method in the Agent model to allow reverting to a previous version of an agent. - Introduced `revertAgentVersionHandler` in the agents controller to handle requests for reverting agent versions. - Updated API routes to include a new endpoint for reverting agent versions. - Enhanced the VersionPanel component to support version restoration with user confirmation and feedback. - Added localization support for success and error messages related to version restoration. * ✨ i18n: Add localization for agent version restoration messages * Simplify VersionPanel by removing unused parameters and enhancing agent ID handling * Refactor Agent model and VersionPanel component to streamline version data handling * Update version handling in Agent model and VersionPanel - Enhanced the Agent model to include an `updatedAt` timestamp when pushing new versions. - Improved the VersionPanel component to sort versions by the `updatedAt` timestamp for better display order. - Added a new localization entry for indicating the active version of an agent. * ✨ i18n: Add localization for active agent version across multiple languages * ✨ feat: Introduce version management components for agent history - Added `isActiveVersion` utility to determine the active version of an agent based on various criteria. - Implemented `VersionContent` and `VersionItem` components to display agent version history, including loading and error states. - Enhanced `VersionPanel` to integrate new components and manage version context effectively. - Added comprehensive tests for version management functionalities to ensure reliability and correctness. * Add unit tests for AgentFooter component * cleanup * Enhance agent version update handling and add unit tests for update operators - Updated the `updateAgent` function to properly handle various update operators ($push, $pull, $addToSet) while maintaining version history. - Modified unit tests to validate the correct behavior of agent updates, including versioning and tool management. * Enhance version comparison logic and update tests for artifacts handling - Modified the `isActiveVersion` utility to include artifacts in the version comparison criteria. - Updated the `VersionPanel` component to support artifacts in the agent state. - Added new unit tests to validate artifacts matching scenarios and edge cases in the `isActiveVersion` function. * Implement duplicate version detection in agent updates and enhance error handling - Added `isDuplicateVersion` function to check for identical versions during agent updates, excluding certain fields. - Updated `updateAgent` function to throw an error if a duplicate version is detected, with detailed error information. - Enhanced the `updateAgentHandler` to return appropriate responses for duplicate version errors. - Modified client-side error handling to display user-friendly messages for duplicate version scenarios. - Added comprehensive unit tests to validate duplicate version detection and error handling across various update scenarios. * Update version title localization to include version number across multiple languages - Modified the `com_ui_agent_version_title` translation key to include a placeholder for the version number in various language files. - Enhanced the `VersionItem` component to utilize the updated localization for displaying version titles dynamically. * Enhance agent version handling and add revert functionality - Updated the `isDuplicateVersion` function to improve version comparison logic, including special handling for `projectIds` and arrays of objects. - Modified the `updateAgent` function to streamline version updates and removed unnecessary checks for test environments. - Introduced a new `revertAgentVersion` function to allow reverting agents to specific versions, with detailed documentation. - Enhanced unit tests to validate duplicate version detection and revert functionality, ensuring robust error handling and version management. * fix CI issues * cleanup * Revert all non-English translations * clean up tests * *️⃣ feat: Reuse OpenID Auth Tokens (danny-avila#7397) * feat: integrate OpenID Connect support with token reuse - Added `jwks-rsa` and `new-openid-client` dependencies for OpenID Connect functionality. - Implemented OpenID token refresh logic in `AuthController`. - Enhanced `LogoutController` to handle OpenID logout and session termination. - Updated JWT authentication middleware to support OpenID token provider. - Modified OAuth routes to accommodate OpenID authentication and token management. - Created `setOpenIDAuthTokens` function to manage OpenID tokens in cookies. - Upgraded OpenID strategy with user info fetching and token exchange protocol. - Introduced `openIdJwtLogin` strategy for handling OpenID JWT tokens. - Added caching mechanism for exchanged OpenID tokens. - Updated configuration to include OpenID exchanged tokens cache key. - updated .env.example to include the new env variables needed for the feature. * fix: update return type in downloadImage documentation for clarity and fixed openIdJwtLogin env variables * fix: update Jest configuration and tests for OpenID strategy integration * fix: update OpenID strategy to include callback URL in setup * fix: fix optionalJwtAuth middleware to support OpenID token reuse and improve currentUrl method in CustomOpenIDStrategy to override the dynamic host issue related to proxy (e.g. cloudfront) * fix: fixed code formatting * Fix: Add mocks for openid-client and passport strategy in Jest configuration to fix unit tests * fix eslint errors: Format mock file openid-client. * ✨ feat: Add PKCE support for OpenID and default handling in strategy setup --------- Co-authored-by: Atef Bellaaj <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 🔎 feat: Native Web Search with Citation References (danny-avila#7516) * WIP: search tool integration * WIP: Add web search capabilities and API key management to agent actions * WIP: web search capability to agent configuration and selection * WIP: Add web search capability to backend agent configuration * WIP: add web search option to default agent form values * WIP: add attachments for web search * feat: add plugin for processing web search citations * WIP: first pass, Citation UI * chore: remove console.log * feat: Add AnimatedTabs component for tabbed UI functionality * refactor: AnimatedTabs component with CSS animations and stable ID generation * WIP example content * feat: SearchContext for managing search results apart from MessageContext * feat: Enhance AnimatedTabs with underline animation and state management * WIP: first pass, Implement dynamic tab functionality in Sources component with search results integration * fix: Update class names for improved styling in Sources and AnimatedTabs components * feat: Improve styling and layout in Sources component with enhanced button and item designs * feat: Refactor Sources component to integrate OGDialog for source display and improve layout * style: Update background color in SourceItem and SourcesGroup components for improved visibility * refactor: Sources component to enhance SourceItem structure and improve favicon handling * style: Adjust font size of domain text in SourceItem for better readability * feat: Add localization for citation source and details in CompositeCitation component * style: add theming to Citation components * feat: Enhance SourceItem component with dialog support and improved hovercard functionality * feat: Add localization for sources tab and image alt text in Sources component * style: Replace divs with spans for better semantic structure in CompositeCitation and Citation components * refactor: Sources component to use useMemo for tab generation and improve performance * chore: bump @librechat/agents to v2.4.318 * chore: update search result types * fix: search results retrieval in ContentParts component, re-render attachments when expected * feat: update sources style/types to use latest search result structure * style: enhance Dialog (expanded) SourceItem component with link wrapping and improved styling * style: update ImageItem component styling for improved title visibility * refactor: remove SourceItemBase component and adjust SourceItem layout for improved styling * chore: linting twcss order * fix: prevent FileAttachment from rendering search attachments * fix: append underscore to responseMessageId for unique identification to prevent mapping of previous latest message's attachments * chore: remove unused parameter 'useSpecs' from loadTools function * chore: twcss order * WIP: WebSearch Tool UI * refactor: add limit parameter to StackedFavicons for customizable source display * refactor: optimize search results memoization by making more granular and separate conerns * refactor: integrated StackedFavicons to WebSearch mid-run * chore: bump @librechat/agents to expose handleToolCallChunks * chore: use typedefs from dedicated file instead of defining them in AgentClient module * WIP: first pass, search progress results * refactor: move createOnSearchResults function to a dedicated search module * chore: bump @librechat/agents to v2.4.320 * WIP: first pass, search results processed UX * refactor: consolidate context variables in createOnSearchResults function * chore: bump @librechat/agents to v2.4.321 * feat: add guidelines for web search tool response formatting in loadTools function * feat: add isLast prop to Part component and update WebSearch logic for improved state handling * style: update Hovercard styles for improved UI consistency * feat: export FaviconImage component for improved accessibility in other modules * refactor: export getCleanDomain function and use FaviconImage in Citation component for improved source representation * refactor: implement SourceHovercard component for consistency and DRY compliance * fix: replace <p> with <span> for snippet and title in SourceItem and SourceHovercard for consistency * style: `not-prose` * style: remove 'not-prose' class for consistency in SourceItem, Citation, and SourceHovercard components, adjust style classes * refactor: `imageUrl` on hover and prevent duplicate sources * refactor: enhance SourcesGroup dialog layout and improve source item presentation * refactor: reorganize Web Components, save in same directory * feat: add 'news' refType to refTypeMap for citation sources * style: adjust Hovercard width for improved layout * refactor: update tool usage guidelines for improved clarity and execution * chore: linting * feat: add Web Search badge with initial permissions and local storage logic * feat: add webSearch support to interface and permissions schemas * feat: implement Web Search API key management and localization updates * feat: refactor Web Search API key handling and integrate new search API key form * fix: remove unnecessary visibility state from FileAttachment component * feat: update WebSearch component to use Globe icon and localized search label * feat: enhance ApiKeyDialog with dropdown for reranker selection and update translations * feat: implement dropdown menus for engine, scraper, and reranker selection in ApiKeyDialog * chore: linting and add unknown instead of `any` type * feat: refactor ApiKeyDialog and useAuthSearchTool for improved API key management * refactor: update ocrSchema to use template literals for default apiKey and baseURL * feat: add web search configuration and utility functions for environment variable extraction * fix: ensure filepath is defined before checking its prefix in useAttachmentHandler * feat: enhance web search functionality with improved configuration and environment variable extraction for authFields * fix: update auth type in TPluginAction and TUpdateUserPlugins to use Partial<Record<string, string>> * feat: implement web search authentication verification and enhance webSearchAuth structure * feat: enhance ephemeral agent handling with new web search capability and type definition * feat: enhance isEphemeralAgent function to include web search selection * feat: refactor verifyWebSearchAuth to improve key handling and authentication checks * feat: implement loadWebSearchAuth function for improved web search authentication handling * feat: enhance web search authentication with new configuration options and refactor related types * refactor: rename search engine to search provider and update related localization keys * feat: update verifyWebSearchAuth to handle multiple authentication types and improve error handling * feat: update ApiKeyDialog to accept authTypes prop and remove isUserProvided check * feat: add tests for extractWebSearchEnvVars and loadWebSearchAuth functions * feat: enhance loadWebSearchAuth to support specific service checks for providers, scrapers, and rerankers * fix: update web search configuration key and adjust auth result handling in loadTools function * feat: add new progress key for repeated web searching and update localization * chore: bump @librechat/agents to 2.4.322 * feat: enhance loadTools function to include ISO time and improve search tool logging * feat: update StackedFavicons to handle negative start index and improve citation attribution styling and text * chore: update .gitignore to categorize AI-related files * fix: mobile responsiveness of sources/citations hovercards * feat: enhance source display with improved line clamping for better readability * chore: bump @librechat/agents to v2.4.33 * feat: add handling for image sources in references mapping * chore: bump librechat-data-provider version to 0.7.84 * chore: bump @librechat/agents version to 2.4.34 * fix: update auth handling to support multiple auth types in tools and allow key configuration in agent panel * chore: remove redundant agent attribution text from search form * fix: web search auth uninstall * refactor: convert CheckboxButton to a forwardRef component and update setValue callback signature * feat: add triggerRef prop to ApiKeyDialog components for improved dialog control * feat: integrate triggerRef in CodeInterpreter and WebSearch components for enhanced dialog management * feat: enhance ApiKeyDialog with additional links for Firecrawl and Jina API key guidance * feat: implement web search configuration handling in ApiKeyDialog and add tests for dropdown visibility * fix: update webSearchConfig reference in config route for correct payload assignment * feat: update ApiKeyDialog to conditionally render sections based on authTypes and modify loadWebSearchAuth to correctly categorize authentication types * feat: refactor ApiKeyDialog and related tests to use SearchCategories and RerankerTypes enums and remove nested ternaries * refactor: move ThinkingButton rendering to improve layout consistency in ContentParts * feat: integrate search context into Markdown component to conditionally include unicodeCitation plugin * chore: bump @librechat/agents to v2.4.35 * chore: remove unused 18n key * ci: add WEB_SEARCH permission testing and update AppService tests for new webSearch configuration * ci: add more comprehensive tests for loadWebSearchAuth to validate authentication handling and authTypes structure * chore: remove debugging console log from web.spec.ts to clean up test output * 🧹 chore: Bump Agents Dependencies (danny-avila#7525) * chore: bump langchain dependencies * chore: bump @librechat/agents to v2.4.36 * chore: bump @librechat/agents to v2.4.37 * refactor: simplify remark plugins in Markdown component with no conditional usage * 🔧 refactor: Progress Text Localization for Running Tools (danny-avila#7526) * 🔧 chore: Bump Data Provider and Custom Config Versions (danny-avila#7527) * 🔧 chore: Update CONFIG_VERSION to 1.2.6 * 🔧 chore: Update librechat-data-provider version to 0.7.85 * 👤 feat: Enhance Agent Versioning to Track User Updates (danny-avila#7523) * feat: Enhance agent update functionality to track user updates - Updated `updateAgent` function to accept an `updatingUserId` parameter for tracking who made changes. - Modified agent versioning to include `updatedBy` field for better audit trails. - Adjusted related functions and tests to ensure proper handling of user updates and version history. - Enhanced tests to verify correct tracking of `updatedBy` during agent updates and restorations. * fix: Refactor import tests for improved readability and consistency - Adjusted formatting in `importChatGptConvo` test to enhance clarity. - Updated expected output string in `processAssistantMessage` test to use double quotes for consistency. - Modified processing time expectation in `processAssistantMessage` test to allow for CI environment variability. * 🧩 feat: Web Search Config Validations & Clipboard Citation Processing (danny-avila#7530) * 🔧 chore: Add missing optional `scraperTimeout` to webSearchSchema * chore: Add missing optional `scraperTimeout` to web search authentication result * chore: linting * feat: Integrate attachment handling and citation processing in message components - Added `useAttachments` hook to manage message attachments and search results. - Updated `MessageParts`, `ContentParts`, and `ContentRender` components to utilize the new hook for improved attachment handling. - Enhanced `useCopyToClipboard` to format citations correctly, including support for composite citations and deduplication. - Introduced utility functions for citation processing and cleanup. - Added tests for the new `useCopyToClipboard` functionality to ensure proper citation formatting and handling. * feat: Add configuration for LibreChat Code Interpreter API and Web Search variables * fix: Update searchResults type to use SearchResultData for better type safety * feat: Add web search configuration validation and logging - Introduced `checkWebSearchConfig` function to validate web search configuration values, ensuring they are environment variable references. - Added logging for proper configuration and warnings for incorrect values. - Created unit tests for `checkWebSearchConfig` to cover various scenarios, including valid and invalid configurations. * docs: Update README to include Web Search feature details - Added a section for the Web Search feature, highlighting its capabilities to search the internet and enhance AI context. - Included links for further information on the Web Search functionality. * ci: Add mock for checkWebSearchConfig in AppService tests * chore: linting * feat: Enhance Shared Messages with Web Search UI by adding searchResults prop to SearchContent and MinimalHoverButtons components * chore: linting * refactor: remove Meilisearch index sync from importConversations function * feat: update safeSearch implementation to use SafeSearchTypes enum * refactor: remove commented-out code in loadTools function * fix: ensure responseMessageId handles latestMessage ID correctly * feat: enhance Vite configuration for improved chunking and caching - Added additional globIgnores for map files in Workbox configuration. - Implemented high-impact chunking for various large libraries to optimize performance. - Increased chunkSizeWarningLimit from 1200 to 1500 for better handling of larger chunks. * refactor: move health check hook to Root, fix bad setState for Temporary state - Enhanced the `useHealthCheck` hook to initiate health checks only when the user is authenticated. - Added logic for managing health check intervals and handling window focus events. - Introduced a new test suite for `useHealthCheck` to cover various scenarios including authentication state changes and error handling. - Removed the health check invocation from `ChatRoute` and added it to `Root` for global health monitoring. * fix: update font alias in Vite configuration for correct path resolution * 🌍 i18n: Update translation.json with latest translations (danny-avila#7532) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🔧 chore: Update data-provider dependencies for typing (danny-avila#7533) - Updated dependencies to include @langchain/core and @types/winston in both package-lock.json and data-provider package.json. * 🔧 fix: Artifacts Display Crash on Close and Max Width (danny-avila#7540) * 🔧 chore: Update react-resizable-panels dependency to version 3.0.2 in package.json and package-lock.json * fix: Simplify order assignment in SidePanel component based on hasArtifacts condition, fixed frontend crash when artifacts are closed * refactor: Change throttledSaveLayout to use useMemo for improved performance in SidePanelGroup component * refactor: Update dependencies in SidePanel component's useEffect hooks for improved responsiveness * 🏷️ refactor: EditPresetDialog UI and Remove `chatGptLabel` from Presets (danny-avila#7543) * fix: add necessary dep., remove unnecessary dep from useMentions memoization * fix: Migrate deprecated chatGptLabel to modelLabel in cleanupPreset and simplify getPresetTitle logic * fix: Enhance cleanupPreset to remove empty chatGptLabel and add comprehensive tests for label migration and preset handling * chore: Update endpointType prop in PopoverButtons to allow null values for better flexibility * refactor: Replace Dialog with OGDialog in EditPresetDialog for improved UI consistency and structure * style: Update EditPresetDialog layout and styling for improved responsiveness and consistency * 📦 refactor: Add Additional Chunking to Vite Config (danny-avila#7544) * ⚡ refactor: Add Additional Chunking to Vite Config * chore: Integrate rollup-plugin-visualizer for bundle analysis in Vite config & add @codemirror chunks * ⌚ fix: Debounce `setUserContext` and Default State Param for OpenID Auth (danny-avila#7559) * fix: Add default random state parameter to OpenID auth request for providers that require it; ensure passport strategy uses it * ⌚ refactor: debounce setUserContext to avoid race condition * refactor: Update OpenID authentication to use randomState from openid-client * chore: linting in presetSettings type definition * chore: import order in ModelPanel * refactor: remove `isLegacyOutput` property from AnthropicClient since only used where defined, add latest models to non-legacy patterns, and remove from client cleanup * refactor: adjust grid layout in Parameters component for improved responsiveness * refactor: adjust grid layout in ModelPanel for improved display of model parameters * test: add cases for maxOutputTokens handling in Claude 4 Sonnet and Opus models * ci: mock loadCustomConfig in server tests and refactor OpenID route for improved authentication handling * 🚀 feat: Implement Auto-Refill Settings for Balance * fix: ESLint * ✨ feat: Enhance Auto-Refill Settings with Validation and Localization --------- Co-authored-by: andresgit <[email protected]> Co-authored-by: matt burnett <[email protected]> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> Co-authored-by: Marco Beretta <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Theo N. Truong <[email protected]> Co-authored-by: René Honig <[email protected]> Co-authored-by: Ben Verhees <[email protected]> Co-authored-by: Amgad Hasan <[email protected]> Co-authored-by: arthurolivierfortin <[email protected]> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Sebastien Bruel <[email protected]> Co-authored-by: Austin Barrington <[email protected]> Co-authored-by: Peter <[email protected]> Co-authored-by: Atef Bellaaj <[email protected]>
was a mechanism like this proposition #7330 added? |
* 🚀 feat: Implement Auto-Refill Settings for Balance * 🎨 feat: add `copy-tex` to improve copying KaTeX (danny-avila#7308) When selecting equations and using copy paste, uses the correct latex code. Co-authored-by: Ruben Talstra <[email protected]> * 🔃 refactor: `AgentFooter` to conditionally render buttons based on `activePanel` (danny-avila#7306) * 🚀 feat: Add `Cloudflare Turnstile` support (danny-avila#5987) * 🚀 feat: Add @marsidev/react-turnstile dependency to package.json and package-lock.json * 🚀 feat: Integrate Cloudflare Turnstile configuration support in AppService and add schema validation * 🚀 feat: Implemented Cloudflare Turnstile integration in Login and Registration forms * 🚀 feat: Enhance AppService tests with additional mocks and configuration setups * 🚀 feat: Comment out outdated config version warning tests in AppService.spec.js * 🚀 feat: Remove outdated warning tests and add new checks for environment variables and API health * 🔧 test: Update AppService.spec.js to use expect.anything() for paths validation * 🔧 test: Refactor AppService.spec.js to streamline mocks and enhance clarity * 🔧 chore: removed not needed test * Potential fix for code scanning alert no. 5638: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5629: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5642: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Update turnstile.js * Potential fix for code scanning alert no. 5634: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5646: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5647: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5764: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5765: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * 🖼️ feat: Tool Call and Loading UI Refresh, Image Resize Config (danny-avila#7086) * ✨ feat: Enhance Spinner component with customizable properties and improved animation * 🔧 fix: Replace Loader with Spinner in RunCode component and update FilePreview to use Spinner for progress indication * ✨ feat: Refactor icons in CodeProgress and CancelledIcon components; enhance animation and styling in ExecuteCode and ProgressText components * ✨ feat: Refactor attachment handling in ExecuteCode component; replace individual attachment rendering with AttachmentGroup for improved structure * ✨ feat: Refactor dialog components for improved accessibility and styling; integrate Skeleton loading state in Image component * ✨ feat: Refactor ToolCall component to use ToolCallInfo for better structure; replace ToolPopover with AttachmentGroup; enhance ProgressText with error handling and improved UI elements * 🔧 fix: Remove unnecessary whitespace in ProgressText * 🔧 fix: Remove unnecessary margin from AgentFooter and AgentPanel components; clean up SidePanel imports * ✨ feat: Enhance ToolCall and ToolCallInfo components with improved styling; update translations and add warning text color to Tailwind config * 🔧 fix: Update import statement for useLocalize in ToolCallInfo component; fix: chatform transition * ✨ feat: Refactor ToolCall and ToolCallInfo components for improved structure and styling; add optimized code block for better output display * ✨ feat: Implement OpenAI image generation component; add progress tracking and localization for user feedback * 🔧 fix: Adjust base duration values for image generation; optimize timing for quality settings * chore: remove unnecessary space * ✨ feat: Enhance OpenAI image generation with editing capabilities; update localization for progress feedback * ✨ feat: Add download functionality to images; enhance DialogImage component with download button * ✨ feat: Enhance image resizing functionality; support custom percentage and pixel dimensions in resizeImageBuffer * 📊 feat: Improve Helm Chart (danny-avila#3638) * Replaced Helm Charts with Blue Atlas Charts * Fix Workflow * improve docs * update gitignore * Update docs * change values order, add hpa * change tls example domain * Default: Enable liveness and readiness * chore: bump base chart * apply requested changes * add Release fix * add: error handling * chore: cleanup and testing * fix: adjust Chart.yaml --------- Co-authored-by: hofq <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 📜 docs: Unreleased Changelog (danny-avila#7434) * action: update Unreleased changelog * Update CHANGELOG.md --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> * 🛡️ chore: `multer` v2.0.0 for CVE-2025-47935 and CVE-2025-47944 (danny-avila#7454) * chore: bump multer to v2.0.0 to resolve CVE-2025-47935 and CVE-2025-47944 * chore: temp. remove helmet dependency to appease unused NPM package workflow * 🎚️ feat: Custom Parameters (danny-avila#7342) * # * - refactor: simplified getCustomConfig func * # * - feature: persist values for parameters with optionType of custom * # * - refactor: moved `Parameters/settings.ts` into `data-provider` so that both frontend and backend code can use it. * - feature: loadCustomConfig can now parse and validate customParams property for `endpoints.custom` in `librechat.yaml` * # fixed linter * # removed .strict() in config.ts * change: added packages/data-provider/src to SOURCE_DIRS for i18n check * # removed unnecessary lodash imports * # addressed PR comments # fixed lint for updated files * # better import for lodash (w/o relying on tree-shaking) * 📃 fix: Ensure MCP Resources Pass Name and Description Fields to LLM (danny-avila#7442) * 🔗 feat: Support Environment Variables in MCP URL Config (danny-avila#7424) * 🦙 chore: Add `llama-4` to Vision Models List (danny-avila#7433) * 🔧 fix: File Deletion for Azure Assistants API (danny-avila#7466) * 🔬 fix: File Search Request Format (Azure Assistants API) (danny-avila#7404) * fix: The request format for file analysis with Azure OpenAI assistants The request format for file analysis with Azure OpenAI assistants differs from that of OpenAI. This fix updates the API to use attachments instead of file_ids. danny-avila#7379 * chore: ESLint Error --------- Co-authored-by: Danny Avila <[email protected]> * 🖼️ chore: Linting & Transition Styling in UI Components (danny-avila#7467) * chore: linting * 🔧 fix: Correctly parse dimensions for image width and height in OpenAIImageGen component * style: overlay class for DialogImage component to improve visibility * style: Update transition timing function for PixelCard component to rely on style props * ✅ fix: Emojis rendering in `SplitText` Animation (danny-avila#7460) * 📂 refactor: Improve `FileAttachment` & File Form Deletion (danny-avila#7471) * refactor: optional attachment properties for `FileAttachment` * refactor: update ActionButton to use localized text * chore: localize text in DataTableFile, add missing translation, imports order, and linting * chore: linting in DataTable * fix: integrate Recoil state management for file deletion in DataTableFile * fix: integrate Recoil state management for file deletion in DataTable * fix: add temp_file_id to BatchFile type and update deleteFiles logic to properly remove files that are mapped to temp_file_id * 🌍 i18n: Update translation.json with latest translations (danny-avila#7468) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🦾 feat: Claude-4 Support (danny-avila#7509) * refactor: Update AnthropicClient to support Claude model naming changes * Renamed `isClaude3` to `isClaudeLatest` to accommodate newer Claude models. * Updated logic to determine if the model is part of the Claude family. * Adjusted `useMessages` property to reflect the new model naming convention. * Cleaned up client properties during disposal to match the updated naming. * feat: Claude-4 Support * feat: Add Thinking and Prompt caching support for Claude 4 * chore: Update ANTHROPIC_MODELS in .env.example for latest model versions * 📊 chore: Remove Old Helm Chart (danny-avila#7512) Co-authored-by: hofq <[email protected]> * 🪨 feat: Bedrock Support for Claude-4 Reasoning (danny-avila#7517) * 🗑️ chore: Update .gitignore to reflect AI-related files * chore: linting in Bedrock options.js * 🪨 feat: Bedrock Claude-4 Reasoning * 🪖 chore: bump helm app version to v0.7.8 (danny-avila#7524) - bump helm app version to match the latest release version * ⌛ feat: Agent Version History and Management (danny-avila#7455) * ✨ feat: Enhance agent update functionality to save current state in versions array - Updated the `updateAgent` function to push the current agent's state into a new `versions` array when an agent is updated. - Modified the agent schema to include a `versions` field for storing historical states of agents. * ✨ feat: Add comprehensive CRUD operations for agents in tests - Introduced a new test suite for CRUD operations on agents, including create, read, update, and delete functionalities. - Implemented tests for listing agents by author and updating agent projects. - Enhanced the agent model to support version history tracking during updates. - Ensured proper environment variable management during tests. * ✨ feat: Introduce version tracking for agents and enhance UI components - Added a `version` property to the agent model to track the number of versions. - Updated the `getAgentHandler` to include the agent's version in the response. - Introduced a new `VersionButton` component for navigating to the version panel. - Created a `VersionPanel` component for displaying version-related information. - Updated the UI to conditionally render the version button and panel based on the active state. - Added localization for the new version-related UI elements. * ✨ i18n: Add "version" translation key across multiple languages - Introduced the "com_ui_agent_version" translation key in various language files to support version tracking for agents. - Updated Arabic, Czech, German, English, Spanish, Estonian, Persian, Finnish, French, Hebrew, Hungarian, Indonesian, Italian, Japanese, Korean, Dutch, Polish, Portuguese (Brazil and Portugal), Russian, Swedish, Thai, Turkish, Vietnamese, and Chinese (Simplified and Traditional) translations. * ✨ feat: Update AgentFooter to conditionally render AdminSettings - Modified the logic for displaying buttons in the AgentFooter component to only show them when the active panel is the builder. - Ensured that AdminSettings is displayed only when the user has an admin role and the buttons are visible. * ✨ feat: Enhance AgentPanelSwitch and VersionPanel for improved agent capabilities - Updated AgentPanelSwitch to include a new VersionPanel for displaying version-related information. - Enhanced agentsConfig logic to properly handle agent capabilities. - Modified VersionPanel to improve structure and localization support. - Integrated createAgent mutation for future agent creation functionality. * ✨ feat: Enhance VersionPanel to display agent version history and loading states - Integrated version fetching logic in VersionPanel to retrieve and display agent version history. - Added loading and error handling states to improve user experience. - Updated agent schema to use mixed types for versions, allowing for more flexible version data structures. - Introduced localization support for version-related UI elements. * ✨ feat: Update VersionPanel and AgentPanelSwitch to enhance agent selection and version display - Modified AgentPanelSwitch to pass selectedAgentId to VersionPanel for improved agent context. - Enhanced VersionPanel to handle multiple timestamp formats and display appropriate messages when no agent is selected. - Improved structure and readability of the VersionPanel component by adding a helper function for timestamp retrieval. * ✨ feat: Refactor VersionPanel to utilize localization and improve timestamp handling - Replaced hardcoded text constants with localization support for various UI elements in VersionPanel. - Enhanced the timestamp retrieval function to handle errors gracefully and utilize localized messages for unknown dates. - Improved user feedback by displaying localized messages for agent selection, version errors, and empty states. * ✨ refactor: Clean up VersionPanel by removing unused code and improving timestamp handling * ✨ feat: Implement agent version reverting functionality - Added `revertAgentVersion` method in the Agent model to allow reverting to a previous version of an agent. - Introduced `revertAgentVersionHandler` in the agents controller to handle requests for reverting agent versions. - Updated API routes to include a new endpoint for reverting agent versions. - Enhanced the VersionPanel component to support version restoration with user confirmation and feedback. - Added localization support for success and error messages related to version restoration. * ✨ i18n: Add localization for agent version restoration messages * Simplify VersionPanel by removing unused parameters and enhancing agent ID handling * Refactor Agent model and VersionPanel component to streamline version data handling * Update version handling in Agent model and VersionPanel - Enhanced the Agent model to include an `updatedAt` timestamp when pushing new versions. - Improved the VersionPanel component to sort versions by the `updatedAt` timestamp for better display order. - Added a new localization entry for indicating the active version of an agent. * ✨ i18n: Add localization for active agent version across multiple languages * ✨ feat: Introduce version management components for agent history - Added `isActiveVersion` utility to determine the active version of an agent based on various criteria. - Implemented `VersionContent` and `VersionItem` components to display agent version history, including loading and error states. - Enhanced `VersionPanel` to integrate new components and manage version context effectively. - Added comprehensive tests for version management functionalities to ensure reliability and correctness. * Add unit tests for AgentFooter component * cleanup * Enhance agent version update handling and add unit tests for update operators - Updated the `updateAgent` function to properly handle various update operators ($push, $pull, $addToSet) while maintaining version history. - Modified unit tests to validate the correct behavior of agent updates, including versioning and tool management. * Enhance version comparison logic and update tests for artifacts handling - Modified the `isActiveVersion` utility to include artifacts in the version comparison criteria. - Updated the `VersionPanel` component to support artifacts in the agent state. - Added new unit tests to validate artifacts matching scenarios and edge cases in the `isActiveVersion` function. * Implement duplicate version detection in agent updates and enhance error handling - Added `isDuplicateVersion` function to check for identical versions during agent updates, excluding certain fields. - Updated `updateAgent` function to throw an error if a duplicate version is detected, with detailed error information. - Enhanced the `updateAgentHandler` to return appropriate responses for duplicate version errors. - Modified client-side error handling to display user-friendly messages for duplicate version scenarios. - Added comprehensive unit tests to validate duplicate version detection and error handling across various update scenarios. * Update version title localization to include version number across multiple languages - Modified the `com_ui_agent_version_title` translation key to include a placeholder for the version number in various language files. - Enhanced the `VersionItem` component to utilize the updated localization for displaying version titles dynamically. * Enhance agent version handling and add revert functionality - Updated the `isDuplicateVersion` function to improve version comparison logic, including special handling for `projectIds` and arrays of objects. - Modified the `updateAgent` function to streamline version updates and removed unnecessary checks for test environments. - Introduced a new `revertAgentVersion` function to allow reverting agents to specific versions, with detailed documentation. - Enhanced unit tests to validate duplicate version detection and revert functionality, ensuring robust error handling and version management. * fix CI issues * cleanup * Revert all non-English translations * clean up tests * *️⃣ feat: Reuse OpenID Auth Tokens (danny-avila#7397) * feat: integrate OpenID Connect support with token reuse - Added `jwks-rsa` and `new-openid-client` dependencies for OpenID Connect functionality. - Implemented OpenID token refresh logic in `AuthController`. - Enhanced `LogoutController` to handle OpenID logout and session termination. - Updated JWT authentication middleware to support OpenID token provider. - Modified OAuth routes to accommodate OpenID authentication and token management. - Created `setOpenIDAuthTokens` function to manage OpenID tokens in cookies. - Upgraded OpenID strategy with user info fetching and token exchange protocol. - Introduced `openIdJwtLogin` strategy for handling OpenID JWT tokens. - Added caching mechanism for exchanged OpenID tokens. - Updated configuration to include OpenID exchanged tokens cache key. - updated .env.example to include the new env variables needed for the feature. * fix: update return type in downloadImage documentation for clarity and fixed openIdJwtLogin env variables * fix: update Jest configuration and tests for OpenID strategy integration * fix: update OpenID strategy to include callback URL in setup * fix: fix optionalJwtAuth middleware to support OpenID token reuse and improve currentUrl method in CustomOpenIDStrategy to override the dynamic host issue related to proxy (e.g. cloudfront) * fix: fixed code formatting * Fix: Add mocks for openid-client and passport strategy in Jest configuration to fix unit tests * fix eslint errors: Format mock file openid-client. * ✨ feat: Add PKCE support for OpenID and default handling in strategy setup --------- Co-authored-by: Atef Bellaaj <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 🔎 feat: Native Web Search with Citation References (danny-avila#7516) * WIP: search tool integration * WIP: Add web search capabilities and API key management to agent actions * WIP: web search capability to agent configuration and selection * WIP: Add web search capability to backend agent configuration * WIP: add web search option to default agent form values * WIP: add attachments for web search * feat: add plugin for processing web search citations * WIP: first pass, Citation UI * chore: remove console.log * feat: Add AnimatedTabs component for tabbed UI functionality * refactor: AnimatedTabs component with CSS animations and stable ID generation * WIP example content * feat: SearchContext for managing search results apart from MessageContext * feat: Enhance AnimatedTabs with underline animation and state management * WIP: first pass, Implement dynamic tab functionality in Sources component with search results integration * fix: Update class names for improved styling in Sources and AnimatedTabs components * feat: Improve styling and layout in Sources component with enhanced button and item designs * feat: Refactor Sources component to integrate OGDialog for source display and improve layout * style: Update background color in SourceItem and SourcesGroup components for improved visibility * refactor: Sources component to enhance SourceItem structure and improve favicon handling * style: Adjust font size of domain text in SourceItem for better readability * feat: Add localization for citation source and details in CompositeCitation component * style: add theming to Citation components * feat: Enhance SourceItem component with dialog support and improved hovercard functionality * feat: Add localization for sources tab and image alt text in Sources component * style: Replace divs with spans for better semantic structure in CompositeCitation and Citation components * refactor: Sources component to use useMemo for tab generation and improve performance * chore: bump @librechat/agents to v2.4.318 * chore: update search result types * fix: search results retrieval in ContentParts component, re-render attachments when expected * feat: update sources style/types to use latest search result structure * style: enhance Dialog (expanded) SourceItem component with link wrapping and improved styling * style: update ImageItem component styling for improved title visibility * refactor: remove SourceItemBase component and adjust SourceItem layout for improved styling * chore: linting twcss order * fix: prevent FileAttachment from rendering search attachments * fix: append underscore to responseMessageId for unique identification to prevent mapping of previous latest message's attachments * chore: remove unused parameter 'useSpecs' from loadTools function * chore: twcss order * WIP: WebSearch Tool UI * refactor: add limit parameter to StackedFavicons for customizable source display * refactor: optimize search results memoization by making more granular and separate conerns * refactor: integrated StackedFavicons to WebSearch mid-run * chore: bump @librechat/agents to expose handleToolCallChunks * chore: use typedefs from dedicated file instead of defining them in AgentClient module * WIP: first pass, search progress results * refactor: move createOnSearchResults function to a dedicated search module * chore: bump @librechat/agents to v2.4.320 * WIP: first pass, search results processed UX * refactor: consolidate context variables in createOnSearchResults function * chore: bump @librechat/agents to v2.4.321 * feat: add guidelines for web search tool response formatting in loadTools function * feat: add isLast prop to Part component and update WebSearch logic for improved state handling * style: update Hovercard styles for improved UI consistency * feat: export FaviconImage component for improved accessibility in other modules * refactor: export getCleanDomain function and use FaviconImage in Citation component for improved source representation * refactor: implement SourceHovercard component for consistency and DRY compliance * fix: replace <p> with <span> for snippet and title in SourceItem and SourceHovercard for consistency * style: `not-prose` * style: remove 'not-prose' class for consistency in SourceItem, Citation, and SourceHovercard components, adjust style classes * refactor: `imageUrl` on hover and prevent duplicate sources * refactor: enhance SourcesGroup dialog layout and improve source item presentation * refactor: reorganize Web Components, save in same directory * feat: add 'news' refType to refTypeMap for citation sources * style: adjust Hovercard width for improved layout * refactor: update tool usage guidelines for improved clarity and execution * chore: linting * feat: add Web Search badge with initial permissions and local storage logic * feat: add webSearch support to interface and permissions schemas * feat: implement Web Search API key management and localization updates * feat: refactor Web Search API key handling and integrate new search API key form * fix: remove unnecessary visibility state from FileAttachment component * feat: update WebSearch component to use Globe icon and localized search label * feat: enhance ApiKeyDialog with dropdown for reranker selection and update translations * feat: implement dropdown menus for engine, scraper, and reranker selection in ApiKeyDialog * chore: linting and add unknown instead of `any` type * feat: refactor ApiKeyDialog and useAuthSearchTool for improved API key management * refactor: update ocrSchema to use template literals for default apiKey and baseURL * feat: add web search configuration and utility functions for environment variable extraction * fix: ensure filepath is defined before checking its prefix in useAttachmentHandler * feat: enhance web search functionality with improved configuration and environment variable extraction for authFields * fix: update auth type in TPluginAction and TUpdateUserPlugins to use Partial<Record<string, string>> * feat: implement web search authentication verification and enhance webSearchAuth structure * feat: enhance ephemeral agent handling with new web search capability and type definition * feat: enhance isEphemeralAgent function to include web search selection * feat: refactor verifyWebSearchAuth to improve key handling and authentication checks * feat: implement loadWebSearchAuth function for improved web search authentication handling * feat: enhance web search authentication with new configuration options and refactor related types * refactor: rename search engine to search provider and update related localization keys * feat: update verifyWebSearchAuth to handle multiple authentication types and improve error handling * feat: update ApiKeyDialog to accept authTypes prop and remove isUserProvided check * feat: add tests for extractWebSearchEnvVars and loadWebSearchAuth functions * feat: enhance loadWebSearchAuth to support specific service checks for providers, scrapers, and rerankers * fix: update web search configuration key and adjust auth result handling in loadTools function * feat: add new progress key for repeated web searching and update localization * chore: bump @librechat/agents to 2.4.322 * feat: enhance loadTools function to include ISO time and improve search tool logging * feat: update StackedFavicons to handle negative start index and improve citation attribution styling and text * chore: update .gitignore to categorize AI-related files * fix: mobile responsiveness of sources/citations hovercards * feat: enhance source display with improved line clamping for better readability * chore: bump @librechat/agents to v2.4.33 * feat: add handling for image sources in references mapping * chore: bump librechat-data-provider version to 0.7.84 * chore: bump @librechat/agents version to 2.4.34 * fix: update auth handling to support multiple auth types in tools and allow key configuration in agent panel * chore: remove redundant agent attribution text from search form * fix: web search auth uninstall * refactor: convert CheckboxButton to a forwardRef component and update setValue callback signature * feat: add triggerRef prop to ApiKeyDialog components for improved dialog control * feat: integrate triggerRef in CodeInterpreter and WebSearch components for enhanced dialog management * feat: enhance ApiKeyDialog with additional links for Firecrawl and Jina API key guidance * feat: implement web search configuration handling in ApiKeyDialog and add tests for dropdown visibility * fix: update webSearchConfig reference in config route for correct payload assignment * feat: update ApiKeyDialog to conditionally render sections based on authTypes and modify loadWebSearchAuth to correctly categorize authentication types * feat: refactor ApiKeyDialog and related tests to use SearchCategories and RerankerTypes enums and remove nested ternaries * refactor: move ThinkingButton rendering to improve layout consistency in ContentParts * feat: integrate search context into Markdown component to conditionally include unicodeCitation plugin * chore: bump @librechat/agents to v2.4.35 * chore: remove unused 18n key * ci: add WEB_SEARCH permission testing and update AppService tests for new webSearch configuration * ci: add more comprehensive tests for loadWebSearchAuth to validate authentication handling and authTypes structure * chore: remove debugging console log from web.spec.ts to clean up test output * 🧹 chore: Bump Agents Dependencies (danny-avila#7525) * chore: bump langchain dependencies * chore: bump @librechat/agents to v2.4.36 * chore: bump @librechat/agents to v2.4.37 * refactor: simplify remark plugins in Markdown component with no conditional usage * 🔧 refactor: Progress Text Localization for Running Tools (danny-avila#7526) * 🔧 chore: Bump Data Provider and Custom Config Versions (danny-avila#7527) * 🔧 chore: Update CONFIG_VERSION to 1.2.6 * 🔧 chore: Update librechat-data-provider version to 0.7.85 * 👤 feat: Enhance Agent Versioning to Track User Updates (danny-avila#7523) * feat: Enhance agent update functionality to track user updates - Updated `updateAgent` function to accept an `updatingUserId` parameter for tracking who made changes. - Modified agent versioning to include `updatedBy` field for better audit trails. - Adjusted related functions and tests to ensure proper handling of user updates and version history. - Enhanced tests to verify correct tracking of `updatedBy` during agent updates and restorations. * fix: Refactor import tests for improved readability and consistency - Adjusted formatting in `importChatGptConvo` test to enhance clarity. - Updated expected output string in `processAssistantMessage` test to use double quotes for consistency. - Modified processing time expectation in `processAssistantMessage` test to allow for CI environment variability. * 🧩 feat: Web Search Config Validations & Clipboard Citation Processing (danny-avila#7530) * 🔧 chore: Add missing optional `scraperTimeout` to webSearchSchema * chore: Add missing optional `scraperTimeout` to web search authentication result * chore: linting * feat: Integrate attachment handling and citation processing in message components - Added `useAttachments` hook to manage message attachments and search results. - Updated `MessageParts`, `ContentParts`, and `ContentRender` components to utilize the new hook for improved attachment handling. - Enhanced `useCopyToClipboard` to format citations correctly, including support for composite citations and deduplication. - Introduced utility functions for citation processing and cleanup. - Added tests for the new `useCopyToClipboard` functionality to ensure proper citation formatting and handling. * feat: Add configuration for LibreChat Code Interpreter API and Web Search variables * fix: Update searchResults type to use SearchResultData for better type safety * feat: Add web search configuration validation and logging - Introduced `checkWebSearchConfig` function to validate web search configuration values, ensuring they are environment variable references. - Added logging for proper configuration and warnings for incorrect values. - Created unit tests for `checkWebSearchConfig` to cover various scenarios, including valid and invalid configurations. * docs: Update README to include Web Search feature details - Added a section for the Web Search feature, highlighting its capabilities to search the internet and enhance AI context. - Included links for further information on the Web Search functionality. * ci: Add mock for checkWebSearchConfig in AppService tests * chore: linting * feat: Enhance Shared Messages with Web Search UI by adding searchResults prop to SearchContent and MinimalHoverButtons components * chore: linting * refactor: remove Meilisearch index sync from importConversations function * feat: update safeSearch implementation to use SafeSearchTypes enum * refactor: remove commented-out code in loadTools function * fix: ensure responseMessageId handles latestMessage ID correctly * feat: enhance Vite configuration for improved chunking and caching - Added additional globIgnores for map files in Workbox configuration. - Implemented high-impact chunking for various large libraries to optimize performance. - Increased chunkSizeWarningLimit from 1200 to 1500 for better handling of larger chunks. * refactor: move health check hook to Root, fix bad setState for Temporary state - Enhanced the `useHealthCheck` hook to initiate health checks only when the user is authenticated. - Added logic for managing health check intervals and handling window focus events. - Introduced a new test suite for `useHealthCheck` to cover various scenarios including authentication state changes and error handling. - Removed the health check invocation from `ChatRoute` and added it to `Root` for global health monitoring. * fix: update font alias in Vite configuration for correct path resolution * 🌍 i18n: Update translation.json with latest translations (danny-avila#7532) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🔧 chore: Update data-provider dependencies for typing (danny-avila#7533) - Updated dependencies to include @langchain/core and @types/winston in both package-lock.json and data-provider package.json. * 🔧 fix: Artifacts Display Crash on Close and Max Width (danny-avila#7540) * 🔧 chore: Update react-resizable-panels dependency to version 3.0.2 in package.json and package-lock.json * fix: Simplify order assignment in SidePanel component based on hasArtifacts condition, fixed frontend crash when artifacts are closed * refactor: Change throttledSaveLayout to use useMemo for improved performance in SidePanelGroup component * refactor: Update dependencies in SidePanel component's useEffect hooks for improved responsiveness * 🏷️ refactor: EditPresetDialog UI and Remove `chatGptLabel` from Presets (danny-avila#7543) * fix: add necessary dep., remove unnecessary dep from useMentions memoization * fix: Migrate deprecated chatGptLabel to modelLabel in cleanupPreset and simplify getPresetTitle logic * fix: Enhance cleanupPreset to remove empty chatGptLabel and add comprehensive tests for label migration and preset handling * chore: Update endpointType prop in PopoverButtons to allow null values for better flexibility * refactor: Replace Dialog with OGDialog in EditPresetDialog for improved UI consistency and structure * style: Update EditPresetDialog layout and styling for improved responsiveness and consistency * 📦 refactor: Add Additional Chunking to Vite Config (danny-avila#7544) * ⚡ refactor: Add Additional Chunking to Vite Config * chore: Integrate rollup-plugin-visualizer for bundle analysis in Vite config & add @codemirror chunks * ⌚ fix: Debounce `setUserContext` and Default State Param for OpenID Auth (danny-avila#7559) * fix: Add default random state parameter to OpenID auth request for providers that require it; ensure passport strategy uses it * ⌚ refactor: debounce setUserContext to avoid race condition * refactor: Update OpenID authentication to use randomState from openid-client * chore: linting in presetSettings type definition * chore: import order in ModelPanel * refactor: remove `isLegacyOutput` property from AnthropicClient since only used where defined, add latest models to non-legacy patterns, and remove from client cleanup * refactor: adjust grid layout in Parameters component for improved responsiveness * refactor: adjust grid layout in ModelPanel for improved display of model parameters * test: add cases for maxOutputTokens handling in Claude 4 Sonnet and Opus models * ci: mock loadCustomConfig in server tests and refactor OpenID route for improved authentication handling * 🚀 feat: Implement Auto-Refill Settings for Balance * fix: ESLint * ✨ feat: Enhance Auto-Refill Settings with Validation and Localization --------- Co-authored-by: andresgit <[email protected]> Co-authored-by: matt burnett <[email protected]> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> Co-authored-by: Marco Beretta <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Theo N. Truong <[email protected]> Co-authored-by: René Honig <[email protected]> Co-authored-by: Ben Verhees <[email protected]> Co-authored-by: Amgad Hasan <[email protected]> Co-authored-by: arthurolivierfortin <[email protected]> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Sebastien Bruel <[email protected]> Co-authored-by: Austin Barrington <[email protected]> Co-authored-by: Peter <[email protected]> Co-authored-by: Atef Bellaaj <[email protected]>
@rubentalstra Could you clarify if you are planning to include my proposition? |
* 🚀 feat: Implement Auto-Refill Settings for Balance * 🎨 feat: add `copy-tex` to improve copying KaTeX (danny-avila#7308) When selecting equations and using copy paste, uses the correct latex code. Co-authored-by: Ruben Talstra <[email protected]> * 🔃 refactor: `AgentFooter` to conditionally render buttons based on `activePanel` (danny-avila#7306) * 🚀 feat: Add `Cloudflare Turnstile` support (danny-avila#5987) * 🚀 feat: Add @marsidev/react-turnstile dependency to package.json and package-lock.json * 🚀 feat: Integrate Cloudflare Turnstile configuration support in AppService and add schema validation * 🚀 feat: Implemented Cloudflare Turnstile integration in Login and Registration forms * 🚀 feat: Enhance AppService tests with additional mocks and configuration setups * 🚀 feat: Comment out outdated config version warning tests in AppService.spec.js * 🚀 feat: Remove outdated warning tests and add new checks for environment variables and API health * 🔧 test: Update AppService.spec.js to use expect.anything() for paths validation * 🔧 test: Refactor AppService.spec.js to streamline mocks and enhance clarity * 🔧 chore: removed not needed test * Potential fix for code scanning alert no. 5638: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5629: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5642: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Update turnstile.js * Potential fix for code scanning alert no. 5634: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5646: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5647: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5764: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Potential fix for code scanning alert no. 5765: Ensure code is properly formatted, use insertion, deletion, or replacement to obtain desired formatting. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * 🖼️ feat: Tool Call and Loading UI Refresh, Image Resize Config (danny-avila#7086) * ✨ feat: Enhance Spinner component with customizable properties and improved animation * 🔧 fix: Replace Loader with Spinner in RunCode component and update FilePreview to use Spinner for progress indication * ✨ feat: Refactor icons in CodeProgress and CancelledIcon components; enhance animation and styling in ExecuteCode and ProgressText components * ✨ feat: Refactor attachment handling in ExecuteCode component; replace individual attachment rendering with AttachmentGroup for improved structure * ✨ feat: Refactor dialog components for improved accessibility and styling; integrate Skeleton loading state in Image component * ✨ feat: Refactor ToolCall component to use ToolCallInfo for better structure; replace ToolPopover with AttachmentGroup; enhance ProgressText with error handling and improved UI elements * 🔧 fix: Remove unnecessary whitespace in ProgressText * 🔧 fix: Remove unnecessary margin from AgentFooter and AgentPanel components; clean up SidePanel imports * ✨ feat: Enhance ToolCall and ToolCallInfo components with improved styling; update translations and add warning text color to Tailwind config * 🔧 fix: Update import statement for useLocalize in ToolCallInfo component; fix: chatform transition * ✨ feat: Refactor ToolCall and ToolCallInfo components for improved structure and styling; add optimized code block for better output display * ✨ feat: Implement OpenAI image generation component; add progress tracking and localization for user feedback * 🔧 fix: Adjust base duration values for image generation; optimize timing for quality settings * chore: remove unnecessary space * ✨ feat: Enhance OpenAI image generation with editing capabilities; update localization for progress feedback * ✨ feat: Add download functionality to images; enhance DialogImage component with download button * ✨ feat: Enhance image resizing functionality; support custom percentage and pixel dimensions in resizeImageBuffer * 📊 feat: Improve Helm Chart (danny-avila#3638) * Replaced Helm Charts with Blue Atlas Charts * Fix Workflow * improve docs * update gitignore * Update docs * change values order, add hpa * change tls example domain * Default: Enable liveness and readiness * chore: bump base chart * apply requested changes * add Release fix * add: error handling * chore: cleanup and testing * fix: adjust Chart.yaml --------- Co-authored-by: hofq <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 📜 docs: Unreleased Changelog (danny-avila#7434) * action: update Unreleased changelog * Update CHANGELOG.md --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> * 🛡️ chore: `multer` v2.0.0 for CVE-2025-47935 and CVE-2025-47944 (danny-avila#7454) * chore: bump multer to v2.0.0 to resolve CVE-2025-47935 and CVE-2025-47944 * chore: temp. remove helmet dependency to appease unused NPM package workflow * 🎚️ feat: Custom Parameters (danny-avila#7342) * # * - refactor: simplified getCustomConfig func * # * - feature: persist values for parameters with optionType of custom * # * - refactor: moved `Parameters/settings.ts` into `data-provider` so that both frontend and backend code can use it. * - feature: loadCustomConfig can now parse and validate customParams property for `endpoints.custom` in `librechat.yaml` * # fixed linter * # removed .strict() in config.ts * change: added packages/data-provider/src to SOURCE_DIRS for i18n check * # removed unnecessary lodash imports * # addressed PR comments # fixed lint for updated files * # better import for lodash (w/o relying on tree-shaking) * 📃 fix: Ensure MCP Resources Pass Name and Description Fields to LLM (danny-avila#7442) * 🔗 feat: Support Environment Variables in MCP URL Config (danny-avila#7424) * 🦙 chore: Add `llama-4` to Vision Models List (danny-avila#7433) * 🔧 fix: File Deletion for Azure Assistants API (danny-avila#7466) * 🔬 fix: File Search Request Format (Azure Assistants API) (danny-avila#7404) * fix: The request format for file analysis with Azure OpenAI assistants The request format for file analysis with Azure OpenAI assistants differs from that of OpenAI. This fix updates the API to use attachments instead of file_ids. danny-avila#7379 * chore: ESLint Error --------- Co-authored-by: Danny Avila <[email protected]> * 🖼️ chore: Linting & Transition Styling in UI Components (danny-avila#7467) * chore: linting * 🔧 fix: Correctly parse dimensions for image width and height in OpenAIImageGen component * style: overlay class for DialogImage component to improve visibility * style: Update transition timing function for PixelCard component to rely on style props * ✅ fix: Emojis rendering in `SplitText` Animation (danny-avila#7460) * 📂 refactor: Improve `FileAttachment` & File Form Deletion (danny-avila#7471) * refactor: optional attachment properties for `FileAttachment` * refactor: update ActionButton to use localized text * chore: localize text in DataTableFile, add missing translation, imports order, and linting * chore: linting in DataTable * fix: integrate Recoil state management for file deletion in DataTableFile * fix: integrate Recoil state management for file deletion in DataTable * fix: add temp_file_id to BatchFile type and update deleteFiles logic to properly remove files that are mapped to temp_file_id * 🌍 i18n: Update translation.json with latest translations (danny-avila#7468) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🦾 feat: Claude-4 Support (danny-avila#7509) * refactor: Update AnthropicClient to support Claude model naming changes * Renamed `isClaude3` to `isClaudeLatest` to accommodate newer Claude models. * Updated logic to determine if the model is part of the Claude family. * Adjusted `useMessages` property to reflect the new model naming convention. * Cleaned up client properties during disposal to match the updated naming. * feat: Claude-4 Support * feat: Add Thinking and Prompt caching support for Claude 4 * chore: Update ANTHROPIC_MODELS in .env.example for latest model versions * 📊 chore: Remove Old Helm Chart (danny-avila#7512) Co-authored-by: hofq <[email protected]> * 🪨 feat: Bedrock Support for Claude-4 Reasoning (danny-avila#7517) * 🗑️ chore: Update .gitignore to reflect AI-related files * chore: linting in Bedrock options.js * 🪨 feat: Bedrock Claude-4 Reasoning * 🪖 chore: bump helm app version to v0.7.8 (danny-avila#7524) - bump helm app version to match the latest release version * ⌛ feat: Agent Version History and Management (danny-avila#7455) * ✨ feat: Enhance agent update functionality to save current state in versions array - Updated the `updateAgent` function to push the current agent's state into a new `versions` array when an agent is updated. - Modified the agent schema to include a `versions` field for storing historical states of agents. * ✨ feat: Add comprehensive CRUD operations for agents in tests - Introduced a new test suite for CRUD operations on agents, including create, read, update, and delete functionalities. - Implemented tests for listing agents by author and updating agent projects. - Enhanced the agent model to support version history tracking during updates. - Ensured proper environment variable management during tests. * ✨ feat: Introduce version tracking for agents and enhance UI components - Added a `version` property to the agent model to track the number of versions. - Updated the `getAgentHandler` to include the agent's version in the response. - Introduced a new `VersionButton` component for navigating to the version panel. - Created a `VersionPanel` component for displaying version-related information. - Updated the UI to conditionally render the version button and panel based on the active state. - Added localization for the new version-related UI elements. * ✨ i18n: Add "version" translation key across multiple languages - Introduced the "com_ui_agent_version" translation key in various language files to support version tracking for agents. - Updated Arabic, Czech, German, English, Spanish, Estonian, Persian, Finnish, French, Hebrew, Hungarian, Indonesian, Italian, Japanese, Korean, Dutch, Polish, Portuguese (Brazil and Portugal), Russian, Swedish, Thai, Turkish, Vietnamese, and Chinese (Simplified and Traditional) translations. * ✨ feat: Update AgentFooter to conditionally render AdminSettings - Modified the logic for displaying buttons in the AgentFooter component to only show them when the active panel is the builder. - Ensured that AdminSettings is displayed only when the user has an admin role and the buttons are visible. * ✨ feat: Enhance AgentPanelSwitch and VersionPanel for improved agent capabilities - Updated AgentPanelSwitch to include a new VersionPanel for displaying version-related information. - Enhanced agentsConfig logic to properly handle agent capabilities. - Modified VersionPanel to improve structure and localization support. - Integrated createAgent mutation for future agent creation functionality. * ✨ feat: Enhance VersionPanel to display agent version history and loading states - Integrated version fetching logic in VersionPanel to retrieve and display agent version history. - Added loading and error handling states to improve user experience. - Updated agent schema to use mixed types for versions, allowing for more flexible version data structures. - Introduced localization support for version-related UI elements. * ✨ feat: Update VersionPanel and AgentPanelSwitch to enhance agent selection and version display - Modified AgentPanelSwitch to pass selectedAgentId to VersionPanel for improved agent context. - Enhanced VersionPanel to handle multiple timestamp formats and display appropriate messages when no agent is selected. - Improved structure and readability of the VersionPanel component by adding a helper function for timestamp retrieval. * ✨ feat: Refactor VersionPanel to utilize localization and improve timestamp handling - Replaced hardcoded text constants with localization support for various UI elements in VersionPanel. - Enhanced the timestamp retrieval function to handle errors gracefully and utilize localized messages for unknown dates. - Improved user feedback by displaying localized messages for agent selection, version errors, and empty states. * ✨ refactor: Clean up VersionPanel by removing unused code and improving timestamp handling * ✨ feat: Implement agent version reverting functionality - Added `revertAgentVersion` method in the Agent model to allow reverting to a previous version of an agent. - Introduced `revertAgentVersionHandler` in the agents controller to handle requests for reverting agent versions. - Updated API routes to include a new endpoint for reverting agent versions. - Enhanced the VersionPanel component to support version restoration with user confirmation and feedback. - Added localization support for success and error messages related to version restoration. * ✨ i18n: Add localization for agent version restoration messages * Simplify VersionPanel by removing unused parameters and enhancing agent ID handling * Refactor Agent model and VersionPanel component to streamline version data handling * Update version handling in Agent model and VersionPanel - Enhanced the Agent model to include an `updatedAt` timestamp when pushing new versions. - Improved the VersionPanel component to sort versions by the `updatedAt` timestamp for better display order. - Added a new localization entry for indicating the active version of an agent. * ✨ i18n: Add localization for active agent version across multiple languages * ✨ feat: Introduce version management components for agent history - Added `isActiveVersion` utility to determine the active version of an agent based on various criteria. - Implemented `VersionContent` and `VersionItem` components to display agent version history, including loading and error states. - Enhanced `VersionPanel` to integrate new components and manage version context effectively. - Added comprehensive tests for version management functionalities to ensure reliability and correctness. * Add unit tests for AgentFooter component * cleanup * Enhance agent version update handling and add unit tests for update operators - Updated the `updateAgent` function to properly handle various update operators ($push, $pull, $addToSet) while maintaining version history. - Modified unit tests to validate the correct behavior of agent updates, including versioning and tool management. * Enhance version comparison logic and update tests for artifacts handling - Modified the `isActiveVersion` utility to include artifacts in the version comparison criteria. - Updated the `VersionPanel` component to support artifacts in the agent state. - Added new unit tests to validate artifacts matching scenarios and edge cases in the `isActiveVersion` function. * Implement duplicate version detection in agent updates and enhance error handling - Added `isDuplicateVersion` function to check for identical versions during agent updates, excluding certain fields. - Updated `updateAgent` function to throw an error if a duplicate version is detected, with detailed error information. - Enhanced the `updateAgentHandler` to return appropriate responses for duplicate version errors. - Modified client-side error handling to display user-friendly messages for duplicate version scenarios. - Added comprehensive unit tests to validate duplicate version detection and error handling across various update scenarios. * Update version title localization to include version number across multiple languages - Modified the `com_ui_agent_version_title` translation key to include a placeholder for the version number in various language files. - Enhanced the `VersionItem` component to utilize the updated localization for displaying version titles dynamically. * Enhance agent version handling and add revert functionality - Updated the `isDuplicateVersion` function to improve version comparison logic, including special handling for `projectIds` and arrays of objects. - Modified the `updateAgent` function to streamline version updates and removed unnecessary checks for test environments. - Introduced a new `revertAgentVersion` function to allow reverting agents to specific versions, with detailed documentation. - Enhanced unit tests to validate duplicate version detection and revert functionality, ensuring robust error handling and version management. * fix CI issues * cleanup * Revert all non-English translations * clean up tests * *️⃣ feat: Reuse OpenID Auth Tokens (danny-avila#7397) * feat: integrate OpenID Connect support with token reuse - Added `jwks-rsa` and `new-openid-client` dependencies for OpenID Connect functionality. - Implemented OpenID token refresh logic in `AuthController`. - Enhanced `LogoutController` to handle OpenID logout and session termination. - Updated JWT authentication middleware to support OpenID token provider. - Modified OAuth routes to accommodate OpenID authentication and token management. - Created `setOpenIDAuthTokens` function to manage OpenID tokens in cookies. - Upgraded OpenID strategy with user info fetching and token exchange protocol. - Introduced `openIdJwtLogin` strategy for handling OpenID JWT tokens. - Added caching mechanism for exchanged OpenID tokens. - Updated configuration to include OpenID exchanged tokens cache key. - updated .env.example to include the new env variables needed for the feature. * fix: update return type in downloadImage documentation for clarity and fixed openIdJwtLogin env variables * fix: update Jest configuration and tests for OpenID strategy integration * fix: update OpenID strategy to include callback URL in setup * fix: fix optionalJwtAuth middleware to support OpenID token reuse and improve currentUrl method in CustomOpenIDStrategy to override the dynamic host issue related to proxy (e.g. cloudfront) * fix: fixed code formatting * Fix: Add mocks for openid-client and passport strategy in Jest configuration to fix unit tests * fix eslint errors: Format mock file openid-client. * ✨ feat: Add PKCE support for OpenID and default handling in strategy setup --------- Co-authored-by: Atef Bellaaj <[email protected]> Co-authored-by: Ruben Talstra <[email protected]> * 🔎 feat: Native Web Search with Citation References (danny-avila#7516) * WIP: search tool integration * WIP: Add web search capabilities and API key management to agent actions * WIP: web search capability to agent configuration and selection * WIP: Add web search capability to backend agent configuration * WIP: add web search option to default agent form values * WIP: add attachments for web search * feat: add plugin for processing web search citations * WIP: first pass, Citation UI * chore: remove console.log * feat: Add AnimatedTabs component for tabbed UI functionality * refactor: AnimatedTabs component with CSS animations and stable ID generation * WIP example content * feat: SearchContext for managing search results apart from MessageContext * feat: Enhance AnimatedTabs with underline animation and state management * WIP: first pass, Implement dynamic tab functionality in Sources component with search results integration * fix: Update class names for improved styling in Sources and AnimatedTabs components * feat: Improve styling and layout in Sources component with enhanced button and item designs * feat: Refactor Sources component to integrate OGDialog for source display and improve layout * style: Update background color in SourceItem and SourcesGroup components for improved visibility * refactor: Sources component to enhance SourceItem structure and improve favicon handling * style: Adjust font size of domain text in SourceItem for better readability * feat: Add localization for citation source and details in CompositeCitation component * style: add theming to Citation components * feat: Enhance SourceItem component with dialog support and improved hovercard functionality * feat: Add localization for sources tab and image alt text in Sources component * style: Replace divs with spans for better semantic structure in CompositeCitation and Citation components * refactor: Sources component to use useMemo for tab generation and improve performance * chore: bump @librechat/agents to v2.4.318 * chore: update search result types * fix: search results retrieval in ContentParts component, re-render attachments when expected * feat: update sources style/types to use latest search result structure * style: enhance Dialog (expanded) SourceItem component with link wrapping and improved styling * style: update ImageItem component styling for improved title visibility * refactor: remove SourceItemBase component and adjust SourceItem layout for improved styling * chore: linting twcss order * fix: prevent FileAttachment from rendering search attachments * fix: append underscore to responseMessageId for unique identification to prevent mapping of previous latest message's attachments * chore: remove unused parameter 'useSpecs' from loadTools function * chore: twcss order * WIP: WebSearch Tool UI * refactor: add limit parameter to StackedFavicons for customizable source display * refactor: optimize search results memoization by making more granular and separate conerns * refactor: integrated StackedFavicons to WebSearch mid-run * chore: bump @librechat/agents to expose handleToolCallChunks * chore: use typedefs from dedicated file instead of defining them in AgentClient module * WIP: first pass, search progress results * refactor: move createOnSearchResults function to a dedicated search module * chore: bump @librechat/agents to v2.4.320 * WIP: first pass, search results processed UX * refactor: consolidate context variables in createOnSearchResults function * chore: bump @librechat/agents to v2.4.321 * feat: add guidelines for web search tool response formatting in loadTools function * feat: add isLast prop to Part component and update WebSearch logic for improved state handling * style: update Hovercard styles for improved UI consistency * feat: export FaviconImage component for improved accessibility in other modules * refactor: export getCleanDomain function and use FaviconImage in Citation component for improved source representation * refactor: implement SourceHovercard component for consistency and DRY compliance * fix: replace <p> with <span> for snippet and title in SourceItem and SourceHovercard for consistency * style: `not-prose` * style: remove 'not-prose' class for consistency in SourceItem, Citation, and SourceHovercard components, adjust style classes * refactor: `imageUrl` on hover and prevent duplicate sources * refactor: enhance SourcesGroup dialog layout and improve source item presentation * refactor: reorganize Web Components, save in same directory * feat: add 'news' refType to refTypeMap for citation sources * style: adjust Hovercard width for improved layout * refactor: update tool usage guidelines for improved clarity and execution * chore: linting * feat: add Web Search badge with initial permissions and local storage logic * feat: add webSearch support to interface and permissions schemas * feat: implement Web Search API key management and localization updates * feat: refactor Web Search API key handling and integrate new search API key form * fix: remove unnecessary visibility state from FileAttachment component * feat: update WebSearch component to use Globe icon and localized search label * feat: enhance ApiKeyDialog with dropdown for reranker selection and update translations * feat: implement dropdown menus for engine, scraper, and reranker selection in ApiKeyDialog * chore: linting and add unknown instead of `any` type * feat: refactor ApiKeyDialog and useAuthSearchTool for improved API key management * refactor: update ocrSchema to use template literals for default apiKey and baseURL * feat: add web search configuration and utility functions for environment variable extraction * fix: ensure filepath is defined before checking its prefix in useAttachmentHandler * feat: enhance web search functionality with improved configuration and environment variable extraction for authFields * fix: update auth type in TPluginAction and TUpdateUserPlugins to use Partial<Record<string, string>> * feat: implement web search authentication verification and enhance webSearchAuth structure * feat: enhance ephemeral agent handling with new web search capability and type definition * feat: enhance isEphemeralAgent function to include web search selection * feat: refactor verifyWebSearchAuth to improve key handling and authentication checks * feat: implement loadWebSearchAuth function for improved web search authentication handling * feat: enhance web search authentication with new configuration options and refactor related types * refactor: rename search engine to search provider and update related localization keys * feat: update verifyWebSearchAuth to handle multiple authentication types and improve error handling * feat: update ApiKeyDialog to accept authTypes prop and remove isUserProvided check * feat: add tests for extractWebSearchEnvVars and loadWebSearchAuth functions * feat: enhance loadWebSearchAuth to support specific service checks for providers, scrapers, and rerankers * fix: update web search configuration key and adjust auth result handling in loadTools function * feat: add new progress key for repeated web searching and update localization * chore: bump @librechat/agents to 2.4.322 * feat: enhance loadTools function to include ISO time and improve search tool logging * feat: update StackedFavicons to handle negative start index and improve citation attribution styling and text * chore: update .gitignore to categorize AI-related files * fix: mobile responsiveness of sources/citations hovercards * feat: enhance source display with improved line clamping for better readability * chore: bump @librechat/agents to v2.4.33 * feat: add handling for image sources in references mapping * chore: bump librechat-data-provider version to 0.7.84 * chore: bump @librechat/agents version to 2.4.34 * fix: update auth handling to support multiple auth types in tools and allow key configuration in agent panel * chore: remove redundant agent attribution text from search form * fix: web search auth uninstall * refactor: convert CheckboxButton to a forwardRef component and update setValue callback signature * feat: add triggerRef prop to ApiKeyDialog components for improved dialog control * feat: integrate triggerRef in CodeInterpreter and WebSearch components for enhanced dialog management * feat: enhance ApiKeyDialog with additional links for Firecrawl and Jina API key guidance * feat: implement web search configuration handling in ApiKeyDialog and add tests for dropdown visibility * fix: update webSearchConfig reference in config route for correct payload assignment * feat: update ApiKeyDialog to conditionally render sections based on authTypes and modify loadWebSearchAuth to correctly categorize authentication types * feat: refactor ApiKeyDialog and related tests to use SearchCategories and RerankerTypes enums and remove nested ternaries * refactor: move ThinkingButton rendering to improve layout consistency in ContentParts * feat: integrate search context into Markdown component to conditionally include unicodeCitation plugin * chore: bump @librechat/agents to v2.4.35 * chore: remove unused 18n key * ci: add WEB_SEARCH permission testing and update AppService tests for new webSearch configuration * ci: add more comprehensive tests for loadWebSearchAuth to validate authentication handling and authTypes structure * chore: remove debugging console log from web.spec.ts to clean up test output * 🧹 chore: Bump Agents Dependencies (danny-avila#7525) * chore: bump langchain dependencies * chore: bump @librechat/agents to v2.4.36 * chore: bump @librechat/agents to v2.4.37 * refactor: simplify remark plugins in Markdown component with no conditional usage * 🔧 refactor: Progress Text Localization for Running Tools (danny-avila#7526) * 🔧 chore: Bump Data Provider and Custom Config Versions (danny-avila#7527) * 🔧 chore: Update CONFIG_VERSION to 1.2.6 * 🔧 chore: Update librechat-data-provider version to 0.7.85 * 👤 feat: Enhance Agent Versioning to Track User Updates (danny-avila#7523) * feat: Enhance agent update functionality to track user updates - Updated `updateAgent` function to accept an `updatingUserId` parameter for tracking who made changes. - Modified agent versioning to include `updatedBy` field for better audit trails. - Adjusted related functions and tests to ensure proper handling of user updates and version history. - Enhanced tests to verify correct tracking of `updatedBy` during agent updates and restorations. * fix: Refactor import tests for improved readability and consistency - Adjusted formatting in `importChatGptConvo` test to enhance clarity. - Updated expected output string in `processAssistantMessage` test to use double quotes for consistency. - Modified processing time expectation in `processAssistantMessage` test to allow for CI environment variability. * 🧩 feat: Web Search Config Validations & Clipboard Citation Processing (danny-avila#7530) * 🔧 chore: Add missing optional `scraperTimeout` to webSearchSchema * chore: Add missing optional `scraperTimeout` to web search authentication result * chore: linting * feat: Integrate attachment handling and citation processing in message components - Added `useAttachments` hook to manage message attachments and search results. - Updated `MessageParts`, `ContentParts`, and `ContentRender` components to utilize the new hook for improved attachment handling. - Enhanced `useCopyToClipboard` to format citations correctly, including support for composite citations and deduplication. - Introduced utility functions for citation processing and cleanup. - Added tests for the new `useCopyToClipboard` functionality to ensure proper citation formatting and handling. * feat: Add configuration for LibreChat Code Interpreter API and Web Search variables * fix: Update searchResults type to use SearchResultData for better type safety * feat: Add web search configuration validation and logging - Introduced `checkWebSearchConfig` function to validate web search configuration values, ensuring they are environment variable references. - Added logging for proper configuration and warnings for incorrect values. - Created unit tests for `checkWebSearchConfig` to cover various scenarios, including valid and invalid configurations. * docs: Update README to include Web Search feature details - Added a section for the Web Search feature, highlighting its capabilities to search the internet and enhance AI context. - Included links for further information on the Web Search functionality. * ci: Add mock for checkWebSearchConfig in AppService tests * chore: linting * feat: Enhance Shared Messages with Web Search UI by adding searchResults prop to SearchContent and MinimalHoverButtons components * chore: linting * refactor: remove Meilisearch index sync from importConversations function * feat: update safeSearch implementation to use SafeSearchTypes enum * refactor: remove commented-out code in loadTools function * fix: ensure responseMessageId handles latestMessage ID correctly * feat: enhance Vite configuration for improved chunking and caching - Added additional globIgnores for map files in Workbox configuration. - Implemented high-impact chunking for various large libraries to optimize performance. - Increased chunkSizeWarningLimit from 1200 to 1500 for better handling of larger chunks. * refactor: move health check hook to Root, fix bad setState for Temporary state - Enhanced the `useHealthCheck` hook to initiate health checks only when the user is authenticated. - Added logic for managing health check intervals and handling window focus events. - Introduced a new test suite for `useHealthCheck` to cover various scenarios including authentication state changes and error handling. - Removed the health check invocation from `ChatRoute` and added it to `Root` for global health monitoring. * fix: update font alias in Vite configuration for correct path resolution * 🌍 i18n: Update translation.json with latest translations (danny-avila#7532) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * 🔧 chore: Update data-provider dependencies for typing (danny-avila#7533) - Updated dependencies to include @langchain/core and @types/winston in both package-lock.json and data-provider package.json. * 🔧 fix: Artifacts Display Crash on Close and Max Width (danny-avila#7540) * 🔧 chore: Update react-resizable-panels dependency to version 3.0.2 in package.json and package-lock.json * fix: Simplify order assignment in SidePanel component based on hasArtifacts condition, fixed frontend crash when artifacts are closed * refactor: Change throttledSaveLayout to use useMemo for improved performance in SidePanelGroup component * refactor: Update dependencies in SidePanel component's useEffect hooks for improved responsiveness * 🏷️ refactor: EditPresetDialog UI and Remove `chatGptLabel` from Presets (danny-avila#7543) * fix: add necessary dep., remove unnecessary dep from useMentions memoization * fix: Migrate deprecated chatGptLabel to modelLabel in cleanupPreset and simplify getPresetTitle logic * fix: Enhance cleanupPreset to remove empty chatGptLabel and add comprehensive tests for label migration and preset handling * chore: Update endpointType prop in PopoverButtons to allow null values for better flexibility * refactor: Replace Dialog with OGDialog in EditPresetDialog for improved UI consistency and structure * style: Update EditPresetDialog layout and styling for improved responsiveness and consistency * 📦 refactor: Add Additional Chunking to Vite Config (danny-avila#7544) * ⚡ refactor: Add Additional Chunking to Vite Config * chore: Integrate rollup-plugin-visualizer for bundle analysis in Vite config & add @codemirror chunks * ⌚ fix: Debounce `setUserContext` and Default State Param for OpenID Auth (danny-avila#7559) * fix: Add default random state parameter to OpenID auth request for providers that require it; ensure passport strategy uses it * ⌚ refactor: debounce setUserContext to avoid race condition * refactor: Update OpenID authentication to use randomState from openid-client * chore: linting in presetSettings type definition * chore: import order in ModelPanel * refactor: remove `isLegacyOutput` property from AnthropicClient since only used where defined, add latest models to non-legacy patterns, and remove from client cleanup * refactor: adjust grid layout in Parameters component for improved responsiveness * refactor: adjust grid layout in ModelPanel for improved display of model parameters * test: add cases for maxOutputTokens handling in Claude 4 Sonnet and Opus models * ci: mock loadCustomConfig in server tests and refactor OpenID route for improved authentication handling * 🚀 feat: Implement Auto-Refill Settings for Balance * fix: ESLint * ✨ feat: Enhance Auto-Refill Settings with Validation and Localization --------- Co-authored-by: andresgit <[email protected]> Co-authored-by: matt burnett <[email protected]> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> Co-authored-by: Marco Beretta <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: hofq <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Theo N. Truong <[email protected]> Co-authored-by: René Honig <[email protected]> Co-authored-by: Ben Verhees <[email protected]> Co-authored-by: Amgad Hasan <[email protected]> Co-authored-by: arthurolivierfortin <[email protected]> Co-authored-by: Danny Avila <[email protected]> Co-authored-by: Sebastien Bruel <[email protected]> Co-authored-by: Austin Barrington <[email protected]> Co-authored-by: Peter <[email protected]> Co-authored-by: Atef Bellaaj <[email protected]>
Summary
This pull request introduces significant changes to the new balance SettingsTab, including the addition of auto-refill settings and updates to the user interface to accommodate these new features. The most important changes are summarized below:
Backend Changes:
api/server/controllers/Balance.js
: Enhanced the balance controller to include auto-refill related fields and handle cases where the balance is not found.Frontend Changes:
client/src/components/Nav/AccountSettings.tsx
: Updated balance display logic to show token credits with two decimal places.client/src/components/Nav/Settings.tsx
: Added a new balance tab and included logic to conditionally display it based on the startup configuration. [1] [2] [3] [4] [5]client/src/components/Nav/SettingsTabs/Balance/AutoRefillSettings.tsx
: Introduced a new component to display auto-refill settings.client/src/components/Nav/SettingsTabs/Balance/Balance.tsx
: Created a new balance component to display token credits and auto-refill settings.client/src/components/Nav/SettingsTabs/Balance/TokenCreditsItem.tsx
: Added a new component to display token credits.Localization:
client/src/locales/en/translation.json
: Added new localization strings for balance and auto-refill settings. [1] [2]Data Provider:
packages/data-provider/src/config.ts
: Added a new enum value for the balance settings tab.packages/data-provider/src/data-service.ts
: Updated thegetUserBalance
function to return a detailed balance response including auto-refill settings. [1] [2]packages/data-provider/src/types.ts
: Defined a new typeTBalanceResponse
to represent the balance response structure.When Balance is

enabled: false
:When

autoRefillEnabled
is enabled on the user balance object:When

autoRefillEnabled
is disabled on the user balance object:Change Type
Testing
Please describe your test process and include instructions so that we can reproduce your test. If there are any important variables for your testing configuration, list them here.
Test Configuration:
Checklist