Conversation
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Explore these optional code suggestions:
|
||||||||||||||||||||||
…ny-avila#10258) * refactor: Default Model Spec Retrieval Logic, allowing last selected spec on new chat if last selection was a spec * chore: Replace hardcoded 'new' conversation ID with Constants.NEW_CONVO for consistency * chore: remove redundant condition for model spec preset selection in useNewConvo hook
* filter out unavailable servers * bump render time * Fix import path for useGetStartupConfig * refactor: Change configuredServers to use Set for improved filtering of available MCPs --------- Co-authored-by: Danny Avila <danny@librechat.ai>
… pagination support (danny-avila#10199)
…#10259) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* refactor: remove `useChatContext` from `useSelectMention`, explicitly pass `conversation` object * feat: ephemeral agents via model specs * refactor: Sync Jotai state with ephemeral agent state, also when Ephemeral Agent has no MCP servers selected * refactor: move `useUpdateEphemeralAgent` to store and clean up imports * refactor: reorder imports and invalidate queries for mcpConnectionStatus in event handler * refactor: replace useApplyModelSpecEffects with useApplyModelSpecAgents and update event handlers to use new agent template logic * ci: update useMCPSelect test to verify mcpValues sync with empty ephemeralAgent.mcp
* chore: add i18n localization comment for AlwaysMakeProd component * feat: enhance accessibility by adding aria-label and aria-labelledby to Switch component * feat: add aria-labels for accessibility in Agent and Assistant avatar buttons * fix: add switch aria-labels for accessibility in various components * feat: add aria-labels and localization keys for accessibility in DataTable, DataTableColumnHeader, and OGDialogTemplate components * chore: refactor out nested ternary * feat: add aria-label to DataTable filter button for My Files modal * feat: add aria-labels for Buttons and localization strings * feat: add aria-labels to Checkboxes in Agent Builder * feat: enhance accessibility by adding aria-label and aria-labelledby to Checkbox component * feat: add aria-label to FileSearchCheckbox in Agent Builder * feat: add aria-label to Prompts text input area * feat: enhance accessibility by adding aria-label and aria-labelledby to TextAreaAutosize component * feat: remove improper role: "list" prop from List in Conversations.tsx to enhance accessibility and stop aria rules conflicting within react-virtualized component * feat: enhance accessibility by allowing tab navigation and adding ring highlights for conversation title editing accept/reject buttons * feat: add aria-label to Copy Link button in the conversation share modal * feat: add title to QR code svg in conversation share modal to describe the image content * feat: enhance accessibility by making Agent Avatar upload keyboard navigable and round out highlight border on focus * feat: enhance accessibility by adding aria attributes around alerting users with screen readers to invalid email address inputs in the Agent Builder * feat: add aria-labels to buttons in Advanced panel of Agent Builder * feat: enhance accessibility by making FileUpload and Clear All buttons in PresetItems keyboard navigable * feat: enchance accessiblity by indexing view and delete button aria-labels in shared links management modal to their specific chat titles * feat: add border highlighting on focus for AnimatedSearchInput * feat: add category description to aria-labels for prompts in ListCard * feat: add proper scoping to rows and columns in table headers * feat: add localized aria-labelling to EditTextPart's TextAreaAutosize component and base dynamic paramters panel components and their supporting translation keys * feat: add localized aria-labels and aria-labelledBy to Checkbox components without them * feat: add localized aria-labeledBy for endpoint settings Sliders * feat: add localized aria-labels for TextareaAutosize components * chore: remove unused i18n string * feat: add localized aria-label for BookmarkForm Checkbox * fix: add stopPropagation onKeyDown for Preview and Edit menu items in prompts that was causing the prompts to inadvertently be sent when triggered with keyboard navigation when Auto-send Prompts was toggled on * fix: switch TableCell to TableHead for title cells according to harvard issue danny-avila#789 * fix: add more descriptive localization key for file filter button in DataTable * chore: remove self-explanatory code comment from RenameForm * fix: remove stray bg-yellow highlight that was left in during debugging * fix: add aria-label to model configurator panel back button * fix: undo incorrect hoist of tool name split for aria-label and span in MCPInput --------- Co-authored-by: Danny Avila <danny@librechat.ai>
…anny-avila#10245) * Possibility to add extra env values to the deployment * Fix: Custom environment variables should be placed after the predefined environment variables
…#10274) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…ery Data Usage (danny-avila#10281) * chore: correct startupConfig usage in ImportConversations component * refactor: properly process configured speechToText and textToSpeech settings in getCustomConfigSpeech * refactor: proxy configuration by utilizing HttpsProxyAgent for OpenAI Image Edits
* 📦 feat: `@librechat/agents` v2.4.87 for LangFuse Support * 📦 chore: update @librechat/agents to v2.4.88 in package.json and package-lock.json * 📦 chore: update @librechat/agents to v2.4.89 * feat: Add runName configuration to AgentClient and Memory agent for improved tracing
…#10282) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…anny-avila#10285) * fix: Sanitize LLM titles by stripping <think> tags and fix modal overflow * chore: linting * chore: Simplify title sanitization by removing unnecessary variable assignment and import order --------- Co-authored-by: Danny Avila <danny@librechat.ai>
* 📫 refactor: Enhance OpenID email Fallback * Updated email retrieval logic to use preferred_username or upn if email is not available. * Adjusted logging and user data assignment to reflect the new email handling approach. * Ensured email domain validation checks the correct email source. * 🔄 refactor: Update Email Domain Validation Logic * Modified `isEmailDomainAllowed` function to return true for falsy emails and missing domain restrictions. * Added new test cases to cover scenarios with and without domain restrictions. * Ensured proper validation when domain restrictions are present.
…10299) * Refactored the logic for determining max output tokens in the agent initialization process. * Changed variable names for clarity, updating from `maxTokens` to `maxOutputTokens` to better reflect their purpose. * Adjusted calculations for `maxContextTokens` to use the new `maxOutputTokens` variable.
…#10298) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* 🦙 fix: Ollama Custom Headers * chore: Correct import order for resolveHeaders in OllamaClient.js * fix: Improve error logging for Ollama API model fetch failure * ci: update Ollama model fetch tests * ci: Add unit test for passing headers and user object to Ollama fetchModels
Co-authored-by: Sean McGrath <sean.mcgrath@holmesgroup.com>
…avila#10289) * fix: response api works with azure base url configured * add unit test --------- Co-authored-by: Peter Rothlaender <peter.rothlaender@ginkgo.com>
…#10315) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* ✨ v0.8.1-rc1 * chore: Update CONFIG_VERSION to 1.3.1
…rdination (danny-avila#10189) * 🔧 refactor: Move GLOBAL_PREFIX_SEPARATOR to cacheConfig for consistency * 👑 feat: Implement distributed leader election using Redis
* add user id to mcp tools cache key * tests * clean up redundant tests * remove unused imports
…ndling (danny-avila#10278) * ✨ feat: Refactor error handling and improve loading states in MessageContent component * ✨ feat: Enhance Thinking and ContentParts components with improved hover functionality and clipboard support * fix: Adjust padding in Thinking and ContentParts components for consistent layout * ✨ feat: Add response label and improve message editing UI with contextual indicators * ✨ feat: Add isEditing prop to Feedback and Fork components for improved editing state handling * refactor: Remove isEditing prop from Feedback and Fork components for cleaner state management * refactor: Migrate state management from Recoil to Jotai for font size and show thinking features * refactor: Separate ToggleSwitch into RecoilToggle and JotaiToggle components for improved clarity and state management * refactor: Remove unnecessary comments in ToggleSwitch and MessageContent components for cleaner code * chore: reorder import statements in Thinking.tsx * chore: reorder import statement in EditTextPart.tsx * chore: reorder import statement * chore: Reorganize imports in ToggleSwitch.tsx --------- Co-authored-by: Danny Avila <danny@librechat.ai>
* fix: filter dropdown now closable with escape, doesn't close whole modal * refactor: simplify escapekeydown handler logic for tooltips and dropdown menus * refactor: more specific conditions for preventDefault
…#10995) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* feat: do not open login footer links in new tab * feat: underline login links on hover for better accessibility * feat: nicer visuals for links on hover and focus
danny-avila#11000) * refactor: Implement getLogDir function to set log directory based on environment variables and execution context (Docker or local) * fix: Adjust Dockerfile to create the correct log directory path for consistency
…ch (danny-avila#11002) The refreshController was not updating user openidId when found by email with a different openidId already set. This caused an infinite loop where: 1. JWT auth failed (openidId mismatch) 2. Refresh found user by email but didn't update openidId 3. Next JWT auth failed again → loop Now updates openidId when either migration is needed OR when the stored openidId doesn't match the token's sub claim. Added debug logging for visibility into auth state during refresh.
…#10908) * fix: add support for uploading code files preventing "Unable to determine file type errors" on widely used file extensions for developers * fix: update MIME types for YAML file extensions in codeTypeMapping --------- Co-authored-by: Gerald Moreno <gerald.moreno@spesys-services.fr> Co-authored-by: Danny Avila <danny@librechat.ai>
danny-avila#10975, danny-avila#10952, danny-avila#11008) (danny-avila#11023) * fix: tooltips appear over z-index 100 * fix: tooltips and dropdowns now have xpected behavior again with escape * fix: query document, not on ref, in case of portaled content, and allows escape to close dialog properly for my files modal * fix: console warning about improperly passing props
* fix: focus returns to manage files button on modal close * refactor: remove atoms and re-use components instead * refactor: FilesView to MyFilesModal * chore: import styling * chore: delete file that was meant to be renamed * feat: add trigger ref for settings button as well
…ny-avila#11013) * 🔒 feat: Add MCP server domain restrictions for remote transports * 🔒 feat: Implement comprehensive MCP error handling and domain validation - Added `handleMCPError` function to centralize error responses for domain restrictions and inspection failures. - Introduced custom error classes: `MCPDomainNotAllowedError` and `MCPInspectionFailedError` for better error management. - Updated MCP server controllers to utilize the new error handling mechanism. - Enhanced domain validation logic in `createMCPTools` and `createMCPTool` functions to prevent operations on disallowed domains. - Added tests for runtime domain validation scenarios to ensure correct behavior. * chore: import order * 🔒 feat: Enhance domain validation in MCP tools with user role-based restrictions - Integrated `getAppConfig` to fetch allowed domains based on user roles in `createMCPTools` and `createMCPTool` functions. - Removed the deprecated `getAllowedDomains` method from `MCPServersRegistry`. - Updated tests to verify domain restrictions are applied correctly based on user roles. - Ensured that domain validation logic is consistent and efficient across tool creation processes. * 🔒 test: Refactor MCP tests to utilize configurable app settings - Introduced a mock for `getAppConfig` to enhance test flexibility. - Removed redundant mock definition to streamline test setup. - Ensured tests are aligned with the latest domain validation logic. --------- Co-authored-by: Atef Bellaaj <slalom.bellaaj@external.daimlertruck.com> Co-authored-by: Danny Avila <danny@librechat.ai>
…nny-avila#11030) Co-authored-by: Atef Bellaaj <slalom.bellaaj@external.daimlertruck.com>
- Added `TWELVE_HOURS` constant to `Time` enum for better time management. - Updated `getCachedTools` function to set a default TTL of 12 hours if not specified in options.
…#11034) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…arch Indexing (danny-avila#10872) Temporary chat data should not show up when searching. Now we check whether a TTL has been set on a conversation/message before indexing it in meilisearch. If there is a TTL, we skip it.
…#11051) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…g/2025/12/23 # Conflicts: # .gitignore # Dockerfile.multi # README.md # api/app/clients/tools/util/handleTools.js # api/models/Conversation.js # client/src/components/Conversations/Conversations.tsx # client/src/components/Conversations/Convo.tsx # client/src/components/Conversations/ConvoOptions/ConvoOptions.tsx # client/src/routes/Root.tsx # package-lock.json # packages/data-provider/src/api-endpoints.ts # packages/data-provider/src/data-service.ts
# Conflicts: # client/src/components/Conversations/Conversations.tsx # client/src/components/Conversations/ConvoOptions/ConvoOptions.tsx # client/src/components/Nav/Nav.tsx # package-lock.json
Tracking/2025/12/23
2e32ccb to
0a8419e
Compare
Sync workflow files from upstream to resolve sync conflicts: - backend-review.yml: Add NODE_OPTIONS to increase memory limit for tests - cache-integration-tests.yml: Add stream path to trigger conditions - frontend-review.yml: Add NODE_OPTIONS to Ubuntu and Windows test jobs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
User description
Update dev branch with changes from main.
PR Type
Enhancement, Tests
Description
• Major architectural enhancements: Added comprehensive MCP (Model Context Protocol) manager with OAuth 2.0 support, connection pooling, and token management
• New memory management system: Implemented AI agent memory management with token limits, validation, and artifact handling
• MeiliSearch integration: Added MongoDB-MeiliSearch synchronization plugin with batch processing and search capabilities
• Web search functionality: Added comprehensive web search type definitions and authentication handling for multiple providers
• Extensive test coverage: Added 1570+ lines of Mistral OCR tests, comprehensive share methods tests, web search authentication tests, and agent resources test suites
• LaTeX processing improvements: Enhanced LaTeX preprocessing with currency detection and mhchem command handling
• File operations: Added Mistral file operations and comprehensive OCR service testing
• Code cleanup: Removed legacy MCP package files and migrated functionality to new architecture
Changes walkthrough 📝
9 files
crud.spec.ts
Add comprehensive test suite for Mistral OCR CRUD operationspackages/api/src/files/mistral/crud.spec.ts
• Added comprehensive test suite for Mistral OCR service with 1570+
lines of tests
• Implemented mock setup for fs, form-data, axios, and
data-schemas modules
• Created tests for document upload, signed URL
retrieval, OCR processing, and Azure Mistral OCR
• Added extensive
test coverage for configuration handling, OAuth flows, and error
scenarios
share.test.ts
Add comprehensive test suite for share methods functionalitypackages/data-schemas/src/methods/share.test.ts
• Added comprehensive test suite for share methods with 1043 lines of
tests
• Implemented tests for creating, retrieving, updating, and
deleting shared links
• Added test coverage for message anonymization,
pagination, and access control
• Included edge cases, error handling,
and concurrent operation testing
web.spec.ts
Add comprehensive web search authentication test suitepackages/data-provider/specs/web.spec.ts
• Added comprehensive test suite for web search authentication
functionality
• Tests cover
extractWebSearchEnvVars,loadWebSearchAuth, andwebSearchAuthfunctions• Includes tests for
environment variable extraction, authentication validation, and
service configuration
• Tests handle various scenarios including OCR
capabilities, user vs system authentication, and error handling
resources.test.ts
Add comprehensive agent resources test suitepackages/api/src/agents/resources.test.ts
• Added extensive test suite for the
primeResourcesfunction in agentresources
• Tests cover OCR file handling, attachment processing, and
tool resource management
• Includes tests for file categorization,
duplicate prevention, and error handling
• Tests various scenarios
with different file types and authentication states
mcp.spec.ts
Extend MCP test suite with schema validation and environmentprocessingpackages/data-provider/specs/mcp.spec.ts
• Extended MCP (Model Context Protocol) test suite with new schema
validation tests
• Added comprehensive tests for
StreamableHTTPOptionsSchemavalidation• Added extensive tests for
processMCPEnvfunction covering environment variable processing•
Tests include user field processing, custom variables, and complex
placeholder scenarios
bedrock.spec.ts
Add Bedrock input parser test suitepackages/data-provider/specs/bedrock.spec.ts
• Added test suite for Bedrock input parser functionality
• Tests
focus on model matching for reasoning configuration
• Covers various
Claude model variants and their thinking/reasoning capabilities
•
Tests explicit configuration overrides and custom thinking budgets
latex.spec.ts
Refactor and expand LaTeX preprocessing test suiteclient/src/utils/latex.spec.ts
• Refactors test suite to focus on
preprocessLaTeXfunction instead ofprocessLaTeX• Adds comprehensive test cases for currency detection
and escaping
• Includes tests for mhchem command handling and complex
mixed content scenarios
• Expands coverage for edge cases like code
blocks and malformed expressions
useQueryParams.spec.ts
Add comprehensive test suite for query parameters hookclient/src/hooks/Input/useQueryParams.spec.ts
• Creates comprehensive test suite for URL query parameter processing
hook
• Tests auto-submission functionality with various parameter
combinations
• Includes timeout handling and settings application
scenarios
• Covers edge cases like empty parameters and mixed content
types
zod.spec.ts
Expand Zod schema conversion tests with new optionspackages/data-provider/src/zod.spec.ts
• Adds test coverage for new
dropFieldsoption in JSON schemaconversion
• Implements tests for
transformOneOfAnyOfoption withunion type handling
• Includes comprehensive test cases for nested
schema transformations
• Tests interaction between multiple conversion
options
6 files
manager.ts
Implement MCP Manager for Model Context Protocol connectionspackages/api/src/mcp/manager.ts
• Added new MCPManager class for managing Model Context Protocol
connections
• Implemented singleton pattern with connection pooling
for app-level and user-specific connections
• Added OAuth handling,
token storage, and flow management capabilities
• Included idle
connection cleanup, tool mapping, and instruction formatting features
mongoMeili.ts
Add MeiliSearch-MongoDB synchronization pluginpackages/data-schemas/src/models/plugins/mongoMeili.ts
• Added complete MeiliSearch-MongoDB synchronization plugin
implementation
• Includes batch processing, streaming sync, and
cleanup functionality
• Provides search capabilities with population
and custom indexing
• Implements hooks for document lifecycle
management and error handling
handler.ts
Add MCP OAuth 2.0 authentication handler implementationpackages/api/src/mcp/oauth/handler.ts
• Implements comprehensive OAuth 2.0 handler for MCP (Model Context
Protocol) servers
• Supports both pre-configured OAuth settings and
auto-discovery of OAuth metadata
• Provides methods for initiating
OAuth flows, completing authorization, and refreshing tokens
•
Includes robust error handling and logging throughout the OAuth
process
connection.ts
Enhance MCP connection with OAuth and streamable HTTP supportpackages/api/src/mcp/connection.ts
• Adds OAuth token support and authentication error handling to MCP
connections
• Implements streamable HTTP transport support alongside
existing transports
• Enhances error handling with OAuth-specific
error detection and retry logic
• Improves connection management with
better timeout handling and debugging
web.ts
Add comprehensive web search type definitionspackages/data-provider/src/types/web.ts
• Defines comprehensive type definitions for web search functionality
• Includes types for multiple search providers (Serper, SearXNG) and
result formats
• Provides interfaces for search results, scraping, and
reranking operations
• Supports various search types including images,
videos, news, and places
memory.ts
Add AI agent memory management system implementationpackages/api/src/agents/memory.ts
• Implements comprehensive memory management system for AI agents
•
Provides tools for setting, deleting, and managing user-specific
memories
• Includes token limit enforcement and validation for memory
operations
• Features artifact handling and streaming response support
2 files
index.ts
Add index exports for memory componentsclient/src/components/SidePanel/Memories/index.ts
• Added index file to export
MemoryViewerandMemoryEditDialogcomponents
• Simple barrel export pattern for memory-related
components
index.ts
Add file operations export modulepackages/api/src/files/index.ts
• Creates simple export file for Mistral file operations
101 files