* refactor(MCPService, process): enhance registry URL handling and improve getBinaryPath function
- Updated MCPService to conditionally set the NPM_CONFIG_REGISTRY based on server name, improving flexibility for auto-install scenarios.
- Modified getBinaryPath function to handle optional name parameter, returning a default path when no name is provided, enhancing usability.
* refactor(MCPService, utils): add directory existence check for registry file
- Introduced makeSureDirExists utility function to ensure the specified directory exists, enhancing robustness.
- Updated MCPService to utilize this function when setting the registry URL for the mcp-auto-install server, improving error handling.
* feat:change MCP_REGISTRY_PATH
* refactor(MCPService): streamline environment variable setup for mcp-auto-install
- Updated MCPService to conditionally set NPM_CONFIG_REGISTRY and MCP_REGISTRY_PATH in a more concise manner.
- Enhanced readability by removing redundant code while maintaining functionality.
---------
Co-authored-by: lizhixuan <zhixuan.li@banosuperapp.com>
- Removed unnecessary validation rules from the args Form.Item in McpSettings for cleaner code.
- Updated McpSettingsNavbar to conditionally adjust padding based on the operating system.
close#4244
- Added active MCP server filtering in Inputbar for message sending.
- Updated MCPToolsButton to reflect availability of enabled MCPs.
- Refactored AssistantMCPSettings to streamline MCP server updates and adjusted UI styles for consistency.
* fix(MCPService): extend command support to include 'bun' and 'bunx', and improve environment variable handling
* fix(MCPService): enhance environment variable handling by incorporating default environment settings
* fix(hooks): simplify active MCP servers selection logic
* Updated BackupManager to use streams for writing data to temporary and backup files, enhancing efficiency and error handling.
* Replaced synchronous file writing with asynchronous stream operations to prevent blocking the event loop.
* Updated CustomCollapse to accept React nodes for labels, allowing for more flexible content.
* Replaced static labels with CollapseLabel component to display item counts.
* Introduced EmptyView component for consistent empty state representation across collapsible sections.
* Removed unnecessary styles and improved button click handling to prevent event propagation.
* Updated migration functions to include error handling for provider additions.
* Incremented the version number in the persisted reducer configuration.
* feat(McpSettings): add MCP tools section and fetch tools on server activation
* refactor(McpService): improve client management and connection handling
* feat(McpService): add server management functions for restart and stop
* feat(McpTool): add tools section with input schema and availability messages
* feat(McpService): add unique IDs to tools and update function name mapping
* feat(McpService): implement caching for tool listings and enhance tool structure
* feat(McpToolsButton): streamline active server handling and update dropdown rendering
* fix(mcp-tools): update tool lookup to use unique IDs and add warning for missing tools
- the reason is using display: table/table-row, which makes the selection behavior become table style.
- use display: flex/block to solve this problem, meanwhile the line number css also modified to fit the adjust
* feat: add configuration file management to MCPService
- Introduced methods to ensure the existence of a configuration file, load configurations from it, and save server configurations.
- Updated the MCPService class to handle server configurations more effectively, improving initialization and error handling.
- Added dependency on chokidar for file system watching.
* feat: enhance MCPService configuration handling
- Improved configuration management by adding compatibility for both old and new server formats.
- Updated methods to ensure configuration file existence, load configurations, and save server data more effectively.
- Refined server initialization logic to handle updates and notifications to Redux more efficiently.
- Removed unnecessary waiting for server data from Redux during initialization.
* feat: enhance MCPService default configuration handling
- Added logic to create a default configuration if none exists, improving the initialization process.
- Implemented migration of server configurations from Redux to file, ensuring data consistency.
- Updated methods to handle nested server structures and improved error handling during server updates.
* refactor: clean up MCPService by removing redundant console logs and unused updateServerInRedux method
- Eliminated unnecessary console log statements to improve code readability.
- Removed the unused updateServerInRedux method, streamlining the MCPService class.
- Maintained existing functionality while enhancing code clarity.
* optimize useMessageOperations
* chore: update dependencies and refactor React imports
- Added @ant-design/v5-patch-for-react-19 and rc-virtual-list to package.json.
- Updated React and ReactDOM types to version 19 in package.json and yarn.lock.
- Refactored ReactDOM usage to createRoot in main.tsx for better compatibility with React 18+.
- Changed useContext to use in SyntaxHighlighterProvider and ThemeProvider components.
- Adjusted flex-direction in Messages components to column for improved layout.
- Removed unused state in CodeBlock component.
* refactor(Messages): enhance scrolling behavior and introduce scroll utilities
- Added createScrollHandler and scrollToBottom utilities for improved scroll management.
- Updated Messages component to utilize new scroll utilities for better user experience.
- Refactored scroll handling logic to ensure smooth scrolling when new messages are added.
- Changed containerRef type to HTMLElement for better type safety.
* refactor(Messages): streamline message handling and introduce useTopicMessages hook
- Removed direct message selection from useMessageOperations and created a new useTopicMessages hook for better separation of concerns.
- Updated Messages component to utilize the new useTopicMessages hook for fetching messages.
- Enhanced message display logic with computeDisplayMessages function for improved message rendering.
- Refactored scrolling behavior to maintain a smooth user experience during message updates.
* refactor(Message Operations): introduce useTopicLoading hook for improved loading state management
- Removed loading state from useMessageOperations and created a new useTopicLoading hook for better separation of concerns.
- Updated components to utilize the new useTopicLoading hook for fetching loading states related to topics.
- Enhanced code organization and readability by streamlining message operations and loading state handling.
* refactor(Messages): replace updateMessage with updateMessageThunk for improved async handling
- Updated useMessageOperations and MessageAnchorLine components to utilize updateMessageThunk for message updates.
- Enhanced error handling and database synchronization in the new thunk implementation.
- Streamlined message update logic to improve code clarity and maintainability.
* refactor(SyntaxHighlighterProvider, MessageTools, AddMcpServerPopup): update styles and improve type safety
- Changed import statements to use TypeScript's type imports for better clarity and type safety.
- Updated MessageTools and AddMcpServerPopup components to replace bodyStyle with styles prop for consistent styling approach.
- Enhanced overall code organization and maintainability by adhering to TypeScript best practices.
* refactor(Messages): update layout and remove unnecessary prop
- Removed the hasChildren prop from the Messages component for cleaner code.
- Adjusted flex-direction in the mini chat Messages component to column-reverse for improved layout consistency.
* refactor: enhance type safety and component return types
- Updated functional components to return React.ReactElement instead of JSX.Element for better type consistency.
- Changed import statements to use TypeScript's type imports for improved clarity.
- Initialized useRef hooks with null for better type safety in various components.
- Adjusted props types to use HTMLAttributes for more accurate type definitions.
* chore: update package dependencies
- Removed outdated dependencies: @agentic/exa, @agentic/searxng, @agentic/tavily, and rc-virtual-list.
- Added back @ant-design/v5-patch-for-react-19 and rc-virtual-list with specified versions for improved compatibility.
* fix(useMessageOperations): ensure message retrieval from store when updating content
- Changed model ID from 'mixtral-8x7b-32768' to 'mistral-saba-24b' and updated its name to 'Mistral Saba 24B'.
- Updated model ID from 'gemma-7b-it' to 'gemma-9b-it' and changed its name to 'Gemma 9B'.
- Enhanced clarity and consistency in model naming conventions.
- Updated the FOOTNOTE_PROMPT to instruct the model to provide answers based on its knowledge when reference materials are irrelevant, ensuring responses are clearly structured and complete.
- Added chat history localization entries for English, Japanese, Russian, Simplified Chinese, Traditional Chinese, ensuring consistent user experience across languages.
- Removed redundant history entries from previous versions to streamline localization files.
- Updated the IPC handler for setting launch on boot to directly use the boolean parameter for openAtLogin.
- Cleaned up the WindowService logic to enhance readability and maintainability, including minor adjustments to the tray behavior on macOS.
- Updated the translation script to output machine-generated translations for Greek, Spanish, French, and Portuguese.
- Adjusted file paths for translation outputs and ensured proper formatting in the translation prompts.
- Added a README file to indicate that the translations are machine-generated and should not be edited.
- Reintroduced several dependencies in devDependencies that were previously removed from dependencies.
- Removed unused dependencies from both package.json and yarn.lock to streamline the project.
- Updated tslib version in yarn.lock to ensure compatibility.
- Added support for rerank models in ModelTags component.
- Updated localization keys for model types in various icon components.
- Modified SelectModelPopup to filter out rerank models appropriately.
- Improved model identification logic in models configuration.
- Enhanced UI elements to reflect updated model types and their respective tooltips.
- Changed provider configuration in dev-app-update.yml to use GitHub.
- Added SUPPORTED_REANK_PROVIDERS constant to filter available rerank models.
- Updated tooltip messages in localization files to indicate supported providers.
- Enhanced AddKnowledgePopup and KnowledgeSettingsPopup components to display supported providers in the UI.
- Changed import of MCPServer to type import for better clarity.
- Enhanced error handling in async operations to manage unknown error types.
- Updated Table component to use ellipsis for long text in description and npm link.
- Adjusted column width for actions and ensured consistent styling in the component.
* launch/tray feature enhance stashed
* feature: Issue #2754. launch on boot(win&mac, linux not supported now), min to tray when launch(not only boot), min to tray when close
bug-fix: Issue #2576. In Mac, if tray-on-close is set, MainWindow will not show on the dock when closed
bug-fix: MiniWindow will hide MainWindow when it shows first time and won't hide MainWindow later. The user will not open the MainWindow again if the tray is set to not show. The bug fixed by not hiding the MainWindow anytime the MiniWindow showed.
* migration version fix
* fix: enable universal shortcuts when launch to tray
* ✨ feat: add Model Context Protocol (MCP) support (#2809)
* ✨ feat: add Model Context Protocol (MCP) server configuration (main)
- Added `@modelcontextprotocol/sdk` dependency for MCP integration.
- Introduced MCP server configuration UI in settings with add, edit, delete, and activation functionalities.
- Created `useMCPServers` hook to manage MCP server state and actions.
- Added i18n support for MCP settings with translation keys.
- Integrated MCP settings into the application's settings navigation and routing.
- Implemented Redux state management for MCP servers.
- Updated `yarn.lock` with new dependencies and their resolutions.
* 🌟 feat: implement mcp service and integrate with ipc handlers
- Added `MCPService` class to manage Model Context Protocol servers.
- Implemented various handlers in `ipc.ts` for managing MCP servers including listing, adding, updating, deleting, and activating/deactivating servers.
- Integrated MCP related types into existing type declarations for consistency across the application.
- Updated `preload` to expose new MCP related APIs to the renderer process.
- Enhanced `MCPSettings` component to interact directly with the new MCP service for adding, updating, deleting servers and setting their active states.
- Introduced selectors in the MCP Redux slice for fetching active and all servers from the store.
- Moved MCP types to a centralized location in `@renderer/types` for reuse across different parts of the application.
* feat: enhance MCPService initialization to prevent recursive calls and improve error handling
* feat: enhance MCP integration by adding MCPTool type and updating related methods
* feat: implement streaming support for tool calls in OpenAIProvider and enhance message processing
* fix: finish_reason undefined
---------
Co-authored-by: LiuVaayne <10231735+vaayne@users.noreply.github.com>
Co-authored-by: kangfenmao <kangfenmao@qq.com>
- Introduced state management for tooltips related to regenerate and delete actions in the MessageMenubar component.
- Updated Tooltip components to control visibility based on user interactions.
- Moved MentionModelsButton to a new position within the Inputbar component for better user experience.
- Ensured consistent functionality while enhancing the layout of the input toolbar.
- Added 'webdav' to the list of plugins in electron.vite.config.ts.
- Upgraded 'webdav' package from version 4.11.4 to 5.8.0 in package.json and yarn.lock.
- Introduced a utility function for formatting file sizes in WebDavSettings component.
- Updated file size display logic to use the new formatting utility.
- Updated localization files for ja-jp, ru-ru, and zh-tw to include new strings for WebDAV backup and restore modals.
- Enhanced user experience with additional prompts and confirmation messages for backup and restore actions.
- Added 'local/**' to ESLint ignores
- Included 'socks-proxy-agent' package in dependencies
- Refactored download function to improve readability and maintainability
- Cleaned up unused code in messages state management
* feat: persist webdav state
* feat: schedule autosync by taking the last autosync time
* fix: correct scheduling behaviour with last error, improve messages
* refactor: delay setting lastSyncTime
---------
Co-authored-by: 亢奋猫 <kangfenmao@qq.com>
* Enhance update error logging and fix duplicate type import
- Improve error logging in AppUpdater with more detailed error information and timestamps
- Remove duplicate MCPServer type import in Inputbar component
* feat(constants): 添加 Fortran 源文件扩展名支持
* refactor: remove unused filterMCPTools function calls from providers
* fix: ensure enabledMCPs is checked for length before processing tools
* feat: implement caching for tools retrieved from MCP server
- Improve filterPropertieAttributes to handle nested object and array types, preserving their structure while filtering attributes.
- Make parameters optional when no properties exist. (Fix#3270)
- Modified the assistant deletion logic to check if the deleted assistant is the currently active one before updating the active assistant state. This prevents potential issues when the active assistant is removed.
- Added "advanced_settings" key to English, Japanese, Russian, Chinese, and Traditional Chinese localization files for better user experience.
- Corrected translations for "chunk_size" and "chunk_overlap" in Chinese and Traditional Chinese localization files to enhance clarity.
- Updated the file content extraction method to check for non-empty file arrays, enhancing the handling of messages with files.
- Replaced the previous check for `message.files` with a more robust check using `isEmpty` from lodash to ensure proper validation.
- Added 'chunk-4X6ZJEXY.js' to the optimizeDeps exclusion list in electron.vite.config.ts to improve build performance.
- Updated .vscode/settings.json to exclude '.yarn/releases/**' from search results for better project organization.
- Incremented the version of the persisted reducer from 80 to 81.
- Introduced a new constant `INITIAL_PROVIDERS` to define the initial state of LLM providers.
- Refactored migration functions to utilize `INITIAL_PROVIDERS` for adding providers to the state, improving maintainability and readability.
- Updated migration logic to ensure new providers are added correctly during state migrations.
* feat: support Github Copilot
* feat: finish i18n translate
* fix: add safeStorage
* clean code
* chore: remove vision model
* ✨ feat: add Model Context Protocol (MCP) support (#2809)
* ✨ feat: add Model Context Protocol (MCP) server configuration (main)
- Added `@modelcontextprotocol/sdk` dependency for MCP integration.
- Introduced MCP server configuration UI in settings with add, edit, delete, and activation functionalities.
- Created `useMCPServers` hook to manage MCP server state and actions.
- Added i18n support for MCP settings with translation keys.
- Integrated MCP settings into the application's settings navigation and routing.
- Implemented Redux state management for MCP servers.
- Updated `yarn.lock` with new dependencies and their resolutions.
* 🌟 feat: implement mcp service and integrate with ipc handlers
- Added `MCPService` class to manage Model Context Protocol servers.
- Implemented various handlers in `ipc.ts` for managing MCP servers including listing, adding, updating, deleting, and activating/deactivating servers.
- Integrated MCP related types into existing type declarations for consistency across the application.
- Updated `preload` to expose new MCP related APIs to the renderer process.
- Enhanced `MCPSettings` component to interact directly with the new MCP service for adding, updating, deleting servers and setting their active states.
- Introduced selectors in the MCP Redux slice for fetching active and all servers from the store.
- Moved MCP types to a centralized location in `@renderer/types` for reuse across different parts of the application.
* feat: enhance MCPService initialization to prevent recursive calls and improve error handling
* feat: enhance MCP integration by adding MCPTool type and updating related methods
* feat: implement streaming support for tool calls in OpenAIProvider and enhance message processing
* fix: finish_reason undefined
* fix migrate
* feat: add rate limit and warning
* feat: add delete copilot token file
feat: add login message
feat: add default headers and change getCopilotToken algorithm
* fix
* feat: add rate limit
* chore: change apihost
* fix: remove duplicate apikey
* fix: change api host
* chore: add vertify first tooltip
---------
Co-authored-by: 亢奋猫 <kangfenmao@qq.com>
Co-authored-by: LiuVaayne <10231735+vaayne@users.noreply.github.com>
* feat: Add search summary model and related functionality
- Introduce new search summary model configuration in settings
- Implement search summary prompt and model selection
- Add support for generating search keywords across providers
- Update localization files with new search summary model translations
- Enhance web search functionality with search summary generation
* refactor: Improve web search error handling and async flow
* fix: Update migration version for settings search summary prompt
* refactor(webSearch): Remove search summary model references from settings and localization files
- Deleted search summary model entries from English, Japanese, Russian, Chinese, and Traditional Chinese localization files.
- Refactored ModelSettings component to remove search summary model handling.
- Updated related services and settings to eliminate search summary model dependencies.
* refactor(llm): Remove search summary model from state and related hooks
- Replaced direct background color logic in Navbar and Sidebar components with useNavBackgroundColor hook for improved maintainability.
- Updated navbar background color variable in index.scss for consistency across components.
- Enhanced handling of background color based on window style and application state.
- Revised commercial licensing section to specify conditions requiring written authorization for modifications, enterprise services, hardware bundling, large-scale procurement, and public cloud services.
- Enhanced clarity in contributor agreement terms regarding license adjustments and commercial usage of contributed code.
- Updated language for better understanding and compliance with Apache License 2.0.
- Introduced isNameManuallyEdited property to the Topic type for better tracking of manual edits.
- Updated topic update logic to set isNameManuallyEdited based on user actions in the TopicsTab.
- Enhanced autoRenameTopic function to respect manual edits and prevent automatic renaming when applicable.
* feat: add support for citation preview
#3217
* feat(MessageContent): Add HTML entity encoding to enhance the security of quoted data
* fix(MessageContent): recognize citation format like `[[1]]`
- Introduced new translations for "Pasted Text" and "Pasted Image" in English, Japanese, Russian, Simplified Chinese, and Traditional Chinese.
- Updated FileManager to format file names based on their type, enhancing user experience when handling pasted content.
- Added theme context usage in MinApp for dynamic background styling based on the current theme.
- Updated Navbar component by removing the AssistantSettingsPopup and associated TitleText for a cleaner interface.
- Adjusted border radius in MessageHeader for a more consistent design across components.
- Removed box-shadow from container styles for a cleaner look.
- Adjusted color variables for better contrast and consistency across themes.
- Enhanced Sidebar component to utilize theme context for icon styling.
- Modified MessageHeader to change font size and apply a specific font family for better readability.
- Updated MCPService to use a dedicated method for setting server active status upon activation errors, improving code clarity.
- Added loading state management in MCPSettings to provide user feedback during server activation toggles, enhancing the user experience.
- Updated the installation scripts for bun and uv to log success messages upon successful completion.
- Enhanced error handling to maintain existing functionality while providing clearer feedback during installation.
- Removed the getLatestBunVersion and getLatestUvVersion functions to streamline version handling.
- Updated download functions to use temporary filenames and ensure proper cleanup of downloaded files.
- Enhanced directory management by ensuring the output directory is correctly referenced and cleaned up if empty.
- Refactored the install functions to directly use detected platform and architecture, improving readability and maintainability.
- Adjusted the font size of the PaperClipOutlined icon in the AttachmentButton for better visibility.
- Integrated the AttachmentButton into the Inputbar component, replacing the TranslateButton in one instance for improved functionality.
- Changed the default file type state to 'document' for better initial filtering.
- Introduced a temporary file sorting function to prioritize non-temporary files in the displayed list.
- Adjusted the file retrieval logic to apply sorting consistently for both 'all' and specific file types.
- Updated the MCPService's activate method to handle server arguments more efficiently by using a fallback to an empty array if no arguments are provided.
- This change improves the clarity and robustness of the argument management within the service.
- Refactored MCPService to streamline command handling for 'npx' and 'uvx', removing unnecessary installation checks and directly retrieving binary paths.
- Updated getBinaryPath and isBinaryExists functions to be asynchronous, enhancing their reliability in checking binary existence and paths.
- Cleaned up imports and removed unused dependencies for better code clarity.
- Moved the assistant icon settings to a new position within the DisplaySettings component for better user experience.
- Cleaned up the code by removing redundant sections and ensuring consistent structure in the settings layout.
- Updated various components and services to replace console.debug statements with console.log for better visibility in logs.
- This change enhances the logging approach across the application, ensuring that important messages are consistently logged.
- Added a debug log for MCP servers in MCPSettings.
- Refactored the MCPSettings component to streamline the server table rendering.
- Removed unnecessary styles from the NpxSearch component for cleaner layout.
- Removed the outdated @electron-toolkit/preload dependency and re-added it with the correct version.
- Added a new event listener in WindowService to set the preload script for webviews.
- Updated the openExternal method in preload to handle potential null values.
- Enabled node integration for webviews in the MinApp component for improved functionality.
- Updated iconfont CSS to include a new icon for Obsidian.
- Replaced the Obsidian image with the new icon in DataSettings for improved consistency.
- Adjusted layout styles in ListItem to center icons properly.
- Replaced "JSON Schema" and "Normal mode" with "Edit JSON" in localization files for English, Japanese, Russian, Simplified Chinese, and Traditional Chinese.
- Introduced a new EditMcpJsonPopup component for editing MCP server configurations in JSON format, enhancing user experience and modularity in MCPSettings.
- Added the `tar` package to handle extraction of `.tar.gz` files in the `install-uv.js` script.
- Implemented a new `downloadWithRedirects` function in both `install-bun.js` and `install-uv.js` for improved file downloading with redirect handling.
- Refactored the extraction process in both scripts to utilize Node.js file system methods and the `adm-zip` package for better file management and cleanup.
commit 97d251569690462763810270ad850ad6b0057ac9
Author: kangfenmao <kangfenmao@qq.com>
Date: Mon Mar 17 10:24:43 2025 +0800
feat: refactor IPC handlers for binary management and update localization strings
- Simplified IPC handlers for checking binary existence and retrieving binary paths by removing unnecessary await statements.
- Updated localization strings in English, Japanese, Russian, Simplified Chinese, and Traditional Chinese to change "Install Dependencies" to "Install".
- Removed the MCPSettings component, replacing it with a new InstallNpxUv component for better management of binary installations.
commit d0f6039c7659a0f4cc97555434999c731ea07f9f
Author: Vaayne <liu.vaayne@gmail.com>
Date: Sun Mar 16 23:52:18 2025 +0800
feat: enhance showAddModal to pre-fill form with server details
commit dde8253dc8bdffb482b9af19a07bc89886a19d3a
Author: Vaayne <liu.vaayne@gmail.com>
Date: Sun Mar 16 23:27:17 2025 +0800
feat: add binary management APIs and enhance MCP service for dependency installation
commit d8fda4b7b0e238097f1811850517bd56fe0de0df
Author: Vaayne <liu.vaayne@gmail.com>
Date: Sun Mar 16 21:57:34 2025 +0800
fix: improve error logging in MCPService and streamline tool call response handling in OpenAIProvider
commit e7af2085a66989d9be546701e4f5308e1008cb18
Author: Vaayne <liu.vaayne@gmail.com>
Date: Sun Mar 16 15:14:32 2025 +0800
fix: lint
commit 2ef7d16298a1270df26974158140015b8cbd91bc
Author: Vaayne <liu.vaayne@gmail.com>
Date: Sat Mar 15 21:11:26 2025 +0800
feat: implement uv binary installation script and integrate with MCP service
commit d318b4e5fc8b506e6d4b08490a9e7ceffe9add80
Author: Vaayne <liu.vaayne@gmail.com>
Date: Sat Mar 15 20:28:58 2025 +0800
feat: add uv binary installation script and enhance MCP service command handling
- Introduced a new AddMcpServerPopup component for adding and editing MCP servers, improving modularity and reusability.
- Created NpxSearch component to handle npm package searches, integrating with the existing MCPSettings for enhanced functionality.
- Updated MCPSettings to utilize the new components, streamlining the server management interface.
- Added localization support for new UI elements in multiple languages, enhancing user experience.
* feat: add npm scope search functionality in MCPSettings
- Integrated npx-scope-finder to enable searching for npm packages by scope.
- Added UI elements for inputting npm scope and displaying search results in a table format.
- Enhanced user feedback with loading indicators and messages for search results.
* feat: add key property to package formatting in MCPSettings
- Added a key property to the package formatting logic to ensure unique identification of each package in the results.
* feat: enhance MCPSettings with NPX package list localization
- Added localization support for NPX package list in English, Japanese, Russian, Simplified Chinese, and Traditional Chinese.
- Updated UI elements in MCPSettings to utilize localized strings for package list features, including title, description, and various labels.
- Improved user experience by integrating translations for package-related actions and placeholders.
- Implemented a new method to restart MCP servers, enhancing server management capabilities.
- Updated the existing server activation logic to include a restart option when necessary.
- Ensured that server state is properly managed during the restart process.
- Introduced activedMcpServers to filter and expose only active MCP servers in the useMCPServers hook.
- Updated MCPToolsButton to utilize activedMcpServers, rendering null if no active servers are present.
- Updated logging messages in MCPService for clarity and consistency.
- Removed unused dispatch and initial server loading logic from useMCPServers hook to streamline the code.
- Added useInitMCPServers hook to manage MCP server state and communication with the main process.
- Updated useAppInit to include useInitMCPServers for improved server management during app initialization.
* feat: enhance SelectModelPopup with menu item refs and layout effect
- Added useLayoutEffect to manage scrolling behavior for keyboard navigation.
- Introduced a mechanism to assign refs to menu items for improved accessibility.
- Refactored menu item processing to support recursive rendering with refs.
* feat: update SelectModelPopup to filter out pinned models when not in search mode
- Added logic to filter out pinned models when the popup is not in search state.
- Updated dependencies in useMemo to include pinnedModels for accurate filtering.
* refactor: update SelectModelPopup to clarify model selection logic
* refactor: enhance scrolling behavior in SelectModelPopup for keyboard navigation
- Added logic to scroll to the top of the container if the first model is selected.
- Updated dependencies in useLayoutEffect to include getVisibleModelItems for accurate scrolling behavior.
* refactor: improve scrolling logic in SelectModelPopup for better keyboard navigation
- Enhanced the scrolling behavior to account for group titles when navigating with the keyboard.
- Removed dependency on getVisibleModelItems in useLayoutEffect for a more streamlined effect.
- Added event emission for sending messages in the Inputbar component to enhance message handling.
- Removed redundant event emission from the messages slice to streamline the sendMessage function.
- Removed unused lodash dependency and optimized message resend logic in MessageMenubar.
- Streamlined Popconfirm component for message deletion.
- Updated NewTopicButton styling for improved layout.
- Enhanced messages slice to ensure better state management and error handling.
- Simplified the debounce implementation in the Inputbar component by removing an unnecessary wrapper.
- Updated the NewTopicButton to utilize theme context for dynamic styling based on the current theme.
- Introduced a NewTopicButton component to facilitate adding new topics.
- Updated translations for new topic functionality in English, Japanese, Russian, Simplified Chinese, and Traditional Chinese.
- Adjusted font size in TranslateButton for better UI consistency.
- Removed unused new topic shortcut from Inputbar component.
- Removed unnecessary database update in useMessageOperations during message editing.
- Improved user feedback for missing original user messages by integrating localized error messages in multiple languages.
- Simplified event listener for message sending in Messages component.
- Enhanced message resend logic in messages slice to ensure proper error handling and state updates.
* chore(pre-commit): add pre-commit hook to enforce code style
- Added husky for managing Git hooks and lint-staged for pre-commit checks.
- Updated prettier version to 3.5.3.
- Configured lint-staged to format and lint JavaScript and JSON files before commits.
* chore(workflows): add lint check to CI
* fix: version not correct
* chore(workflow): bump GitHub Actions dependencies to latest versions
- @actions/setup-node: v3 -> v4
- @actions/cache: v3 -> v4
- @actions/upload-artifact: v3 -> v4
---------
Co-authored-by: 亢奋猫 <kangfenmao@qq.com>
- Updated clearTopicMessagesAction to utilize TopicManager for clearing messages.
- Improved handling of topic IDs to ensure correct message clearing based on provided or default topic ID.
* refactor: Simplify message resend logic and enhance abort controller handling
- Updated MessageMenubar to streamline message resend functionality.
- Improved abort controller management in BaseProvider and related services.
- Adjusted sendMessage to handle both single and multiple assistant messages.
- Enhanced logging for better debugging and tracking of message flow.
* feat: Enhance message handling and queue management
- Updated Inputbar to include mentions in dispatched messages.
- Introduced appendMessage action to manage message insertion at specific positions in the state.
- Improved sendMessage logic to handle mentions and maintain message order.
- Refactored getTopicQueue to accept options for better queue configuration.
* refactor: Improve abort handling and message operations
- Refactored useMessageOperations to streamline message pausing logic.
- Enhanced abort controller in BaseProvider to handle abort events more effectively.
- Updated OpenAIProvider to utilize new abort handling mechanism.
- Adjusted fetchChatCompletion to set message status based on abort conditions.
- Improved message dispatching in sendMessage for better queue management.
* refactor: Enhance signal promise handling in BaseProvider and OpenAIProvider
- Updated signal handling in BaseProvider to use a structured signalPromise object for better clarity and management.
- Adjusted error handling in OpenAIProvider to correctly catch and throw errors from the signalPromise.
- Improved overall abort handling logic to ensure robust message operations.
* fix:lint
* feat(websearch): implement API key formatting and add WebSearchApiCheckPopup for multiple keys validation
- Introduced a new WebSearchApiCheckPopup component to validate multiple API keys.
- Added formatApiKeys function to standardize API key input.
- Updated WebSearchProviderSetting to utilize the new popup for checking multiple keys.
- Enhanced error handling and user feedback for API key validation.
* feat(settings): enhance API key validation for providers and web search
- Updated ApiCheckPopup to handle both provider and web search API key validation.
- Refactored key checking logic to differentiate between provider and web search types.
- Removed the obsolete WebSearchApiCheckPopup component and integrated its functionality into ApiCheckPopup.
- Adjusted WebSearchProviderSetting to utilize the updated ApiCheckPopup for checking multiple keys.
- Reformatted sections in README.md for better readability.
- Added new development documentation in docs/dev.md to guide setup and installation processes.
- Updated Japanese and Chinese README translations to reference the new development documentation.
- Reorganized scripts to include a new build check that runs tests, type checks, and i18n checks before publishing.
- Restored and structured type checking and linting scripts for better clarity and usability.
- Ensured post-installation dependencies are correctly handled.
- Modified Inputbar to include a new resizeTextArea function for better text area management.
- Adjusted MessageGroup and MessageStream components to remove unnecessary props and streamline message handling.
- Enhanced message dispatching logic in the messages store for improved state management.
- Cleaned up unused imports and code in Message components to enhance readability and maintainability.
* Enhance update error logging and fix duplicate type import
- Improve error logging in AppUpdater with more detailed error information and timestamps
- Remove duplicate MCPServer type import in Inputbar component
* refactor: optimize file loader with switch-case structure
- Added Gemma3 as a vision model.
- Improved functioncall model check logic.
- Introduced a new method to clean tool call arguments, ensuring proper formatting and extraction of parameters.
- Adjusted tool call handling in OpenAIProvider to accommodate new GLM-4-alltools model checks and argument processing.
Introduce isGemmaModel function to identify Gemma models and adjust system instruction handling in GeminiProvider based on model type. Ensure proper message formatting for Gemma models during chat initialization.
- Added NewContextButton component to manage new context creation with a dedicated button.
- Refactored Inputbar to utilize the new NewContextButton, improving code organization.
- Removed deprecated context shortcut handling from Inputbar.
- Enhanced MCPToolsButton visibility logic based on model type.
- Reordered parameters in completions methods across AiProvider, AnthropicProvider, GeminiProvider, and OpenAIProvider to improve consistency.
- Added detailed JSDoc comments for methods to clarify parameter usage and functionality.
- Ensured mcpTools parameter is consistently included in completions method signatures.
- Implemented a method to extract file content from messages, supporting text and document types.
- Updated message parameter handling to include file content when the model does not support files.
- Added detailed JSDoc comments for new methods and existing functionalities for better documentation.
- Implement token counting functionality in both AddAgentPopup and AssistantPromptSettings components.
- Display the token count dynamically as the user types in the prompt text area.
- Refactor text area components to include a styled token count indicator.
This commit enhances the chat navigation buttons with a more intelligent
visibility system that prevents interference with scrolling while maintaining
easy access to navigation controls.
Key improvements:
- Replace static trigger area with dynamic cursor position tracking to allow
unobstructed scrolling
- Show navigation buttons only when cursor is near the button area or when
actively interacting with them
- Add throttled mouse position detection (50ms) for better performance
- Use passive scroll event listeners for smoother scrolling
- Implement smarter auto-hide behavior with 1.5s timeout when cursor leaves
the button area
This change resolves the issue where navigation buttons would interfere with
scrolling when the cursor was in the detection area, creating a more seamless
user experience.
- Added result check after saving markdown files to ensure success messages are only shown when the save operation is successful.
- Standardized error message keys for consistency.
- Added loading state checks in MessageMenubar to prevent actions during loading.
- Updated useMessageOperations to await database updates for message operations.
- Improved error handling for message edits and resends to ensure proper state management.
- Add enhanced PATH generation for MCP service across different platforms
- Improve model filtering with new function calling model type
- Refactor MCP service type definitions and transport initialization
- Add platform-specific path handling for various development environments
- Add dynamic positioning for navigation trigger area and container
- Integrate with useSettings hook to determine navigation position
- Support right-side topic layout by calculating navigation offset
- Remove unused `selectStreamMessages` selector from store
- Update `pauseMessages` hook to directly access stream messages from store state
- Simplify dependencies in `pauseMessages` callback
- Add titleStyle prop to ListItem for custom text styling
- Reduce gap in ListItem and MenuList components
- Integrate icons for DataSettings menu items
- Add Notion icon to iconfont
- Improve visual hierarchy and spacing in settings navigation
- Update pauseMessage method to handle both askId and messageId
- Add loading state reset when pausing messages
- Enhance error handling in providers with abort error detection
- Modify ApiService to handle aborted requests gracefully
- Add comprehensive isAbortError utility function
- Remove useMemo for container element
- Dynamically retrieve container element in each method
- Simplify scroll and message finding logic
- Improve performance by avoiding unnecessary memoization
- Add `autoRenameTopic` function in useTopic hook
- Support automatic topic naming with or without AI summary
- Integrate with store and event system for dynamic topic renaming
- Remove local implementation of auto-rename in Messages component
* docs: fix style in README.zh.md
* docs: change language order in README.zh.md
* docs: fix style and link in README.ja.md
* docs: update the separators README.zh.md
* docs: update the separators in README.ja.md
* feat: Add message pause and resume functionality
- Implement pauseMessage and pauseMessages methods in useMessageOperations hook
- Update Inputbar to use new pauseMessages method for stopping message generation
- Remove deprecated pause-related code from ApiService and store
- Simplify message generation and pause logic across providers
- Enhance message state management with more granular control over streaming messages
* feat: Enhance topic management with sequence-based sorting and lazy loading
- Add sequence field to topics for better sorting
- Implement lazy loading mechanism for topic messages
- Modify Redux store to support per-topic loading states
- Update database schema to use sequence as an auto-incrementing primary key
- Optimize message initialization and retrieval process
* refactor(database): Enhance topic management with timestamps and upgrade logic
- Modify database schema to include createdAt and updatedAt for topics
- Add database hooks for automatic timestamp handling
- Refactor topic upgrade process to support new timestamp fields
- Remove redundant upgradesV6.ts file
- Update topic retrieval to use updatedAt for sorting
- Improve database consistency and tracking of topic modifications
* refactor: Streamline message state management and remove unused code
- Remove commented-out code in multiple components
- Delete initializeMessagesState thunk from messages store
- Simplify message sending and streaming logic
- Remove unnecessary console logs
- Optimize MessageStream component with memo
- Using loading to control message generation within a single session
- Lift the restriction on not being able to switch topics in message generation
* refactor(database): Remove version 6 database version and hooks
- Remove version 6 database schema definition
- Delete automatic timestamp hooks for topics
- Clean up unused database upgrade and hook code
* refactor(Messages): Optimize message state management and remove redundant code
- Remove duplicate imports and redundant code blocks
- Simplify message sending and streaming logic in messages store
- Enhance throttling mechanism for message updates
- Remove commented-out code and unused function parameters
- Improve error handling and loading state management
- Optimize message synchronization with database
* fix:console
- Update en-us, ja-jp, ru-ru, zh-cn, and zh-tw locale files
- Add 'toggleError' translation key for MCP server settings
- Improve error handling and user feedback for server toggle actions
- Split DataSettings into separate components for Markdown Export, Notion, WebDAV, and Yuque settings
- Implement dynamic menu navigation with ListItem component
- Improve code organization and readability
- Add state management for menu selection
- Enhance settings page layout and user experience
- Remove redundant calls to removeMiniAppIconsFromState in migration steps
- Consolidate MiniApp icon state removal in migration version 78
- Simplify migration configuration for state updates
- Add support for creating new topics from message branches
- Implement file reference count update when branching messages
- Enhance EventEmitter to handle NEW_BRANCH event
- Integrate database operations for topic and file management
- Move MCP tool utilities to a dedicated utils folder
- Update import paths for MCP tool functions across providers
- Add isEmpty check for tools in Anthropic provider
- Enhance message filtering in OpenAI provider with filterEmptyMessages
- Simplify tool and message preparation logic
- Introduce filterEmptyMessages function to remove empty messages
- Update AnthropicProvider to use filterEmptyMessages in message preparation
- Refactor stream processing with minor improvements and return statement fixes
- Simplify tool response and message handling logic
* refactor: Simplify message operations with new useMessageOperations hook
- Introduce useMessageOperations hook to centralize message-related actions
- Remove prop drilling for message deletion and management
- Refactor MessageMenubar, MessageGroup, and Messages components to use new hook
- Remove commented-out code and simplify message state management
- Improve type safety and reduce component complexity
* feat: Enhance topic management with sequence-based sorting and lazy loading
- Add sequence field to topics for better sorting
- Implement lazy loading mechanism for topic messages
- Modify Redux store to support per-topic loading states
- Update database schema to use sequence as an auto-incrementing primary key
- Optimize message initialization and retrieval process
* refactor: Simplify message operations with new useMessageOperations hook
- Introduce useMessageOperations hook to centralize message-related actions
- Remove prop drilling for message deletion and management
- Refactor MessageMenubar, MessageGroup, and Messages components to use new hook
- Remove commented-out code and simplify message state management
- Improve type safety and reduce component complexity
* refactor(database): Enhance topic management with timestamps and upgrade logic
- Modify database schema to include createdAt and updatedAt for topics
- Add database hooks for automatic timestamp handling
- Refactor topic upgrade process to support new timestamp fields
- Remove redundant upgradesV6.ts file
- Update topic retrieval to use updatedAt for sorting
- Improve database consistency and tracking of topic modifications
* fix: Improve message loading state management and UI synchronization
- Update Inputbar to use useMessageOperations hook for loading state
- Correct topic loading state management in Redux store
- Fix loading state synchronization in sendMessage action
- Remove unnecessary commented-out code
- Enhance error handling and loading state tracking
* refactor: Streamline message state management and remove unused code
- Remove commented-out code in multiple components
- Delete initializeMessagesState thunk from messages store
- Simplify message sending and streaming logic
- Remove unnecessary console logs
- Optimize MessageStream component with memo
- Using loading to control message generation within a single session
- Lift the restriction on not being able to switch topics in message generation
- Add 'qwen' to tool calling models list
- Refactor MCP server hooks to use window.api methods
- Add 'more' translation key across localization files
- Improve MCP settings modal with window.api and window.modal methods
- Add ProxyManager service to handle system, custom, and no proxy configurations
- Integrate proxy support for Gemini, Knowledge, and WebDav services
- Add fetch-socks and undici for advanced proxy handling
- Enhance proxy configuration with environment variable and session management
* Enhance update error logging and fix duplicate type import
- Improve error logging in AppUpdater with more detailed error information and timestamps
- Remove duplicate MCPServer type import in Inputbar component
* fix: ensure directory existence and optimize file operations
Update SearchMessage and TopicMessages components to pass topic context to MessageItem, ensuring proper rendering of messages with their associated topics
* feat(message): add a compact style for the model list in message groups
* refactor: use button as action rather than state
---------
Co-authored-by: 亢奋猫 <kangfenmao@qq.com>
Use the new getTempDir utility function from file.ts to generate temporary file paths, maintaining consistency with recent file path utility refactoring
* Enhance update error logging and fix duplicate type import
- Improve error logging in AppUpdater with more detailed error information and timestamps
- Remove duplicate MCPServer type import in Inputbar component
* feat(loader): optimize EpubLoader memory usage with file streams
Replace in-memory arrays with file streams for EPUB processing to reduce
memory consumption when handling large e-books. Use temporary files for
chapter content, add completion logs, and ensure proper cleanup.
This prevents memory overflow issues with large EPUB files (>5MB).
Move hardcoded file path generation logic to dedicated utility functions in file.ts, improving code modularity and reducing duplication across services and IPC handlers
- Add single key checking functionality
- Implement ability to remove individual API keys
- Improve UI with remove and check buttons for each key
- Disable actions during checking to prevent conflicts
- Add styled remove icon for key deletion
* ✨ feat: add Model Context Protocol (MCP) support (#2809)
* ✨ feat: add Model Context Protocol (MCP) server configuration (main)
- Added `@modelcontextprotocol/sdk` dependency for MCP integration.
- Introduced MCP server configuration UI in settings with add, edit, delete, and activation functionalities.
- Created `useMCPServers` hook to manage MCP server state and actions.
- Added i18n support for MCP settings with translation keys.
- Integrated MCP settings into the application's settings navigation and routing.
- Implemented Redux state management for MCP servers.
- Updated `yarn.lock` with new dependencies and their resolutions.
* 🌟 feat: implement mcp service and integrate with ipc handlers
- Added `MCPService` class to manage Model Context Protocol servers.
- Implemented various handlers in `ipc.ts` for managing MCP servers including listing, adding, updating, deleting, and activating/deactivating servers.
- Integrated MCP related types into existing type declarations for consistency across the application.
- Updated `preload` to expose new MCP related APIs to the renderer process.
- Enhanced `MCPSettings` component to interact directly with the new MCP service for adding, updating, deleting servers and setting their active states.
- Introduced selectors in the MCP Redux slice for fetching active and all servers from the store.
- Moved MCP types to a centralized location in `@renderer/types` for reuse across different parts of the application.
* feat: enhance MCPService initialization to prevent recursive calls and improve error handling
* feat: enhance MCP integration by adding MCPTool type and updating related methods
* feat: implement streaming support for tool calls in OpenAIProvider and enhance message processing
* fix: finish_reason undefined
* fix: Improve translation error handling in MessageMenubar
---------
Co-authored-by: LiuVaayne <10231735+vaayne@users.noreply.github.com>
Co-authored-by: kangfenmao <kangfenmao@qq.com>
* feat: Add health check to check all the models at one time
* fix: add model avatars to the health-check list
* style: Use segmented instead of switch
* fix: remove redundant timing reports
* refactor: Extract small functions
* refactor: use more hooks to make the main component clearer
* fix: mask API keys with asterisks
* refactor: split health check popup and model list
- rename ModelHealthCheckPopup to HealthCheckPopup
- add HealthCheckModelList
- add maskApiKey to utils
* refactor: compute latency in checkApi
* fix: remove unused i18n keys
* refactor: use checkModel instead of checkApi for better semantics
* fix: update comments
* refactor: extract health checking functions to services
* refactor: extract model list
* refactor: render statuses on the existing model list
* fix: reset button style on completion
* fix: disable model card while checking
- remove unused i18n keys
- better window message
* refactor: show provider name in messages
* refactor: change default values
* refactor: fully migrate model list from ProviderSetting to ModelList
- Replace default Select components with StyledSelect for improved visual design
- Add explicit type casting for various select onChange handlers
- Improve type safety for message style, multi-model style, code style, and other settings
- Introduce StyledSelect with custom styling for consistent UI appearance
- Introduce messagesRef to track messages without causing re-renders
- Simplify event listener management with more concise useEffect hooks
- Improve auto-rename topic logic with current messages reference
- Remove commented-out code and unused event listeners
- Enhance type safety and reduce dependency complexity
- Introduce ToolsCallingIcon component for tool calling models
- Add isToolCallingModel function in models config
- Update ModelTags to support showing tool calling icon
- Add tooltips to model icons for better UX
- Update Chinese localization with tool calling translation
- Modify Inputbar and SelectModelButton to accommodate new icon
* fix: correctly concatenate model id
* perf: delay model sorting
* feat: sticky provider name during model selection
* fix: model selector group title animation
* fix: add back opacity
---------
Co-authored-by: 亢奋猫 <kangfenmao@qq.com>
- Improve error logging in AppUpdater with more detailed error information and timestamps
- Remove duplicate MCPServer type import in Inputbar component
* feat: Implement Redux-based message management with enhanced state handling
- Add new Redux slice for managing messages with advanced state control
- Introduce topic-specific message queues using p-queue for request management
- Refactor message sending, loading, and updating logic
- Improve error handling and state synchronization with database
- Add selectors for efficient message retrieval and state access
* feat: Implement streaming message handling in Redux store
- Add stream message support in messages slice
- Create MessageStream component for rendering streaming messages
- Update Inputbar and Suggestions components to use new Redux message sending logic
- Refactor message sending flow to use stream message management
- Improve error handling and message state management
* feat:添加StreamMessage,优化数据流展示,减少大面积rerender
* refactor: Simplify messages state management and initialization
- Refactor messages slice to use flat message array instead of separate user/assistant messages
- Add initializeMessagesState thunk to load messages from database on app startup
- Update message-related reducers to work with flat message array
- Modify MessageStream and related components to use new state structure
- Improve type safety and reduce complexity in messages state management
* ✨ feat: add Model Context Protocol (MCP) support (#2809)
* ✨ feat: add Model Context Protocol (MCP) server configuration (main)
- Added `@modelcontextprotocol/sdk` dependency for MCP integration.
- Introduced MCP server configuration UI in settings with add, edit, delete, and activation functionalities.
- Created `useMCPServers` hook to manage MCP server state and actions.
- Added i18n support for MCP settings with translation keys.
- Integrated MCP settings into the application's settings navigation and routing.
- Implemented Redux state management for MCP servers.
- Updated `yarn.lock` with new dependencies and their resolutions.
* 🌟 feat: implement mcp service and integrate with ipc handlers
- Added `MCPService` class to manage Model Context Protocol servers.
- Implemented various handlers in `ipc.ts` for managing MCP servers including listing, adding, updating, deleting, and activating/deactivating servers.
- Integrated MCP related types into existing type declarations for consistency across the application.
- Updated `preload` to expose new MCP related APIs to the renderer process.
- Enhanced `MCPSettings` component to interact directly with the new MCP service for adding, updating, deleting servers and setting their active states.
- Introduced selectors in the MCP Redux slice for fetching active and all servers from the store.
- Moved MCP types to a centralized location in `@renderer/types` for reuse across different parts of the application.
* feat: enhance MCPService initialization to prevent recursive calls and improve error handling
* feat: enhance MCP integration by adding MCPTool type and updating related methods
* feat: implement streaming support for tool calls in OpenAIProvider and enhance message processing
* refactor: Improve message handling and type safety in message components
- Update Message, MessageGroup, MessageStream, and MessageMenubar to require Topic prop
- Modify message sending and resending logic in MessageMenubar
- Remove commented-out code and simplify message state management
- Enhance type safety by explicitly defining prop types
* fix: finish_reason undefined
* refactor: Streamline message resending and state management
- Introduce `resendMessage` thunk for more robust message resending logic
- Update `sendMessage` to support resending existing messages
- Remove deprecated `onEditMessage` callback from MessageMenubar
- Simplify message state updates using Redux actions
- Improve type safety and reduce complexity in message handling
* refactor: Optimize message resending and event handling
- Remove deprecated `APPEND_MESSAGE` event and related callbacks
- Update `resendMessage` thunk to support mentioning new models
- Modify message state synchronization in database
- Simplify dependency arrays and remove unused event listeners
- Add migration step for initializing messages state
* refactor: Enhance message translation and suggestions handling
- Update MessageMenubar to use stream message actions for translation
- Modify Suggestions component to optimize suggestion fetching
- Remove deprecated event listeners and simplify component logic
- Memoize MessageMenubar and Suggestions components for performance
- Trigger AI auto-rename on message completion in messages slice
* refactor: Optimize message streaming with throttled updates
- Introduce throttled message update mechanism using lodash
- Improve performance by limiting Redux state updates during streaming
- Create a separate handler for response message updates
- Enhance message synchronization with database
- Prevent unnecessary re-renders and reduce computational overhead
* fix: Remove unnecessary await in message dispatch
Removes the `await` keyword from the message dispatch in Inputbar, which was causing an unnecessary async operation. Also adds a missing closing brace in the migration configuration file.
* fix: Update Redux persist configuration for messages slice
Modify store configuration to exclude 'messages' slice from persistence and remove unnecessary migration step for message state initialization
* feat: Enhance message streaming and multi-model support
- Refactor Redux messages slice to support multiple stream messages per topic
- Update MessageStream and messages slice to handle message streaming with message-specific IDs
- Implement support for multi-model message generation
- Modify queue concurrency to improve parallel message processing
- Update message selection and streaming logic to be more flexible and robust
* feat: Implement file upload handling in message sending
- Add FileManager service integration for file uploads in Inputbar
- Modify sendMessage action to use uploaded file references
- Update messages slice to conditionally dispatch messages during resend
* ✨ feat(MCP): add support for enabling/disabling MCPServers per message (#2989)
* ✨ feat: add MCP servers in chat input
- Introduce MCPToolsButton component for managing MCP servers
- Add new icon for MCP server tools in iconfont.css
- Update Inputbar to include MCP tools functionality
- Add toggle functionality for enabling/disabling MCP servers
- Implement styled dropdown menu for server selection
- Add necessary type imports and useState for MCP server management
* ✨ feat: add support for enabling/disabling MCPServers per message (main)
- Added `enabledMCPs` property to the `Message` type to track enabled MCPServers.
- Modified `MCPToolsButton` to enable all active MCPServers by default using a new `enableAll` state.
- Introduced `filterMCPTools` utility to filter tools based on enabled MCPServers.
- Updated `AnthropicProvider`, `GeminiProvider`, and `OpenAIProvider` to filter tools using `filterMCPTools`.
- Enhanced `Inputbar` to include `enabledMCPs` in the message payload when set.
* ✨ feat(MCP): add enabledMCPs parameter to sendMessage action
- Update sendMessage action type to include optional enabledMCPs parameter
- Import MCPServer type for type safety
- Modify action signature to support passing enabled MCP servers per message
---------
Co-authored-by: lizhixuan <zhixuan.li@banosuperapp.com>
Co-authored-by: lizhixuan <zhixuanli219643@sohu-inc.com>
Co-authored-by: LiuVaayne <10231735+vaayne@users.noreply.github.com>
Co-authored-by: kangfenmao <kangfenmao@qq.com>
- Add dynamic selected keys for the model selection menu
- Ensure correct model is highlighted when pre-selected or navigated via keyboard
- Simplify selection logic in SelectModelPopup component
- Remove global style components from MentionModelsButton and MCPToolsButton
- Move dropdown styles to a centralized SCSS file
- Refactor components to use styled-components for localized styling
- Improve code organization and reduce redundant styling
- Adjust table column widths in MCPSettings for better layout
- Simplify dropdown rendering by removing unnecessary fragments
- Add useCallback for togglePin and handleModelSelect to prevent unnecessary re-renders
- Refactor dropdown menu styling with more specific CSS scoping
- Simplify dropdown open/close logic
- Improve performance by memoizing function dependencies
- Adjust dropdown overlay styling and animation
* ✨ feat: add MCP servers in chat input
- Introduce MCPToolsButton component for managing MCP servers
- Add new icon for MCP server tools in iconfont.css
- Update Inputbar to include MCP tools functionality
- Add toggle functionality for enabling/disabling MCP servers
- Implement styled dropdown menu for server selection
- Add necessary type imports and useState for MCP server management
* ✨ feat: add support for enabling/disabling MCPServers per message (main)
- Added `enabledMCPs` property to the `Message` type to track enabled MCPServers.
- Modified `MCPToolsButton` to enable all active MCPServers by default using a new `enableAll` state.
- Introduced `filterMCPTools` utility to filter tools based on enabled MCPServers.
- Updated `AnthropicProvider`, `GeminiProvider`, and `OpenAIProvider` to filter tools using `filterMCPTools`.
- Enhanced `Inputbar` to include `enabledMCPs` in the message payload when set.
- Add dynamic group management button that changes based on group's current state
- Simplify group add/remove logic with a single button
- Enhance visual feedback for group-level model management
* feat: a button a add a whole group of models
* feat: search as typing in EditModelsPopup
* feat: add a button to remove a whole group of models
* feat: add remove button for model group in the model list
- Add database version 5 with schema updates
- Create `upgradeToV5` function to migrate Tavily web search metadata to new format
- Update types to support new web search metadata structure
- Minor code cleanup and formatting improvements
- Remove `enabled` flag from WebSearchProvider type
- Add `hasObjectKey` utility function to check optional properties
- Update WebSearchService to check web search availability based on API key/host
- Modify WebSearchSettings and WebSearchProviderSetting components to support API key/host validation
- Add Searxng provider in migration script
- Simplify web search provider configuration and validation logic
* ✨ feat: add Model Context Protocol (MCP) server configuration (main)
- Added `@modelcontextprotocol/sdk` dependency for MCP integration.
- Introduced MCP server configuration UI in settings with add, edit, delete, and activation functionalities.
- Created `useMCPServers` hook to manage MCP server state and actions.
- Added i18n support for MCP settings with translation keys.
- Integrated MCP settings into the application's settings navigation and routing.
- Implemented Redux state management for MCP servers.
- Updated `yarn.lock` with new dependencies and their resolutions.
* 🌟 feat: implement mcp service and integrate with ipc handlers
- Added `MCPService` class to manage Model Context Protocol servers.
- Implemented various handlers in `ipc.ts` for managing MCP servers including listing, adding, updating, deleting, and activating/deactivating servers.
- Integrated MCP related types into existing type declarations for consistency across the application.
- Updated `preload` to expose new MCP related APIs to the renderer process.
- Enhanced `MCPSettings` component to interact directly with the new MCP service for adding, updating, deleting servers and setting their active states.
- Introduced selectors in the MCP Redux slice for fetching active and all servers from the store.
- Moved MCP types to a centralized location in `@renderer/types` for reuse across different parts of the application.
* feat: enhance MCPService initialization to prevent recursive calls and improve error handling
* feat: enhance MCP integration by adding MCPTool type and updating related methods
* feat: implement streaming support for tool calls in OpenAIProvider and enhance message processing
* feat: Enhance MCPServer and MCPTool interfaces with optional properties and unique IDs
* fix(mcp): Refactor SSE transport initialization to use URL object
* fix(OpenAIProvider): correct inputSchema properties reference in tool parameters
* feat(MCPSettings): enhance server settings UI with new fields and improved layout
* feat(MCPSettings): add multilingual support for MCP server settings
* fix: remove unnecessary console log statements
* ✨ feat: add Model Context Protocol (MCP) server configuration (main)
- Added `@modelcontextprotocol/sdk` dependency for MCP integration.
- Introduced MCP server configuration UI in settings with add, edit, delete, and activation functionalities.
- Created `useMCPServers` hook to manage MCP server state and actions.
- Added i18n support for MCP settings with translation keys.
- Integrated MCP settings into the application's settings navigation and routing.
- Implemented Redux state management for MCP servers.
- Updated `yarn.lock` with new dependencies and their resolutions.
* 🌟 feat: implement mcp service and integrate with ipc handlers
- Added `MCPService` class to manage Model Context Protocol servers.
- Implemented various handlers in `ipc.ts` for managing MCP servers including listing, adding, updating, deleting, and activating/deactivating servers.
- Integrated MCP related types into existing type declarations for consistency across the application.
- Updated `preload` to expose new MCP related APIs to the renderer process.
- Enhanced `MCPSettings` component to interact directly with the new MCP service for adding, updating, deleting servers and setting their active states.
- Introduced selectors in the MCP Redux slice for fetching active and all servers from the store.
- Moved MCP types to a centralized location in `@renderer/types` for reuse across different parts of the application.
* feat: enhance MCPService initialization to prevent recursive calls and improve error handling
* feat: enhance MCP integration by adding MCPTool type and updating related methods
* feat: implement streaming support for tool calls in OpenAIProvider and enhance message processing
- Modify AppUpdater to separate update dialog logic
- Add new IPC handler for manually showing update dialog
- Update renderer hooks and store to track downloaded update state
- Switch import for UpdateInfo from electron-updater to builder-util-runtime
* feat(export): Enhance markdown-to-docx export with table support
Add comprehensive table rendering capabilities to the ExportService, including:
- Support for table headers and body rows
- Configurable cell styling and alignment
- Handling of inline text formatting within table cells
* feat(export): Add hyperlink support in markdown-to-docx export
Enhance ExportService to handle hyperlinks during document export:
- Implement link detection in inline tokens
- Create ExternalHyperlink with proper styling
- Preserve link text and URL in exported document
- Add new `filterUserRoleStartMessages` function in MessagesService
- Update Anthropic, Gemini, and OpenAI providers to use new message filtering
- Refactor message handling to ensure user messages start the conversation
- Remove redundant message filtering logic from individual providers
- Add vision model check before image upload in Inputbar
- Implement flexible message start forcing for specific models
- Improve provider-level message routing logic
* feat: add resize handle to input textarea with drag interaction
* handle auto size inputbar
* optimize auto resize function and add i18n
* fix: expand button bug in inputbar and rebase to latest main
* rebase to main
- Fixed typo in Tencent Cloud TI provider key from 'tentent-cloud-ti' to 'tencent-cloud-ti'
- Enhanced ProviderSettings search input with search icon and custom styling
- Adjusted button border radius for consistent UI design
- Implemented `useKnowledgeFiles` hook for managing knowledge base files
- Added localization support for knowledge base file management in multiple languages
- Created UI option to remove all knowledge base files in DataSettings
- Updated file size formatting utility function
- Modified ContentView and FilesPage to use file size correctly
- Implemented detailed backup progress tracking in BackupManager
- Added new BackupPopup component for backup process visualization
- Enhanced backup process with file copy progress and stage tracking
- Updated localization files with backup progress translations
- Integrated backup progress reporting to renderer process
- Refactored reasoning effort handling for Claude models
- Added type definition for ReasoningEffort
- Simplified budget token calculation
- Improved type safety and readability of the method
- Refactored getReasoningEffort method to handle reasoning configuration more robustly
- Added type definitions for reasoning effort and configuration
- Simplified logic for calculating budget tokens
- Improved type safety and readability of the method
* refactor: Improve Ellipsis component and usage
- Modify Ellipsis component to use children instead of text prop
- Add support for multi-line and single-line ellipsis with styled-components
- Update KnowledgeContent to use new Ellipsis component structure
- Enhance ClickableSpan styling for better text truncation
* fix: Improve text wrapping in Ellipsis component
Add overflow-wrap: break-word to ensure long words are properly truncated in multi-line ellipsis
* refactor: Improve link and tooltip rendering in KnowledgeContent
- Wrap links with ClickableSpan for better interaction and styling
- Adjust Tooltip and Ellipsis placement for improved readability
- Remove unnecessary inline styling for links in ItemInfo
---------
Co-authored-by: lizhixuan <zhixuan.li@banosuperapp.com>
- Created detailed technical documentation explaining the KnowledgeService's task queue and workload management
- Added JSDoc comment to KnowledgeService.ts to provide high-level overview
- Documented key aspects of concurrent task processing, including workload evaluation, task state management, and resource optimization strategies
* feat: Improve file upload for the knowledge base
* feat: Improve file upload for the knowledge base
* feat: Improve file upload for the knowledge base
---------
Co-authored-by: 亢奋猫 <kangfenmao@qq.com>
- Added Zhihu (知乎直答) mini app logo
- Updated minapps configuration to include Zhihu mini app
- Modified store migration to enable Zhihu mini app by default
- Added Cici mini app logo in WebP format
- Updated mini apps grid to display 8 columns instead of 6
- Updated store migration to include Cici in enabled mini apps
- Updated Cici app logo import path
- Move StyleSheetManager logic from App.tsx to a new dedicated context component
- Simplify App.tsx by importing the new StyleSheetManager
- Preserve existing prop validation and filtering logic
- Add Babel plugin for styled-components with performance and naming optimizations
- Integrate @emotion/is-prop-valid for improved prop filtering in StyleSheetManager
- Update Antd Input components to use variant="borderless" instead of deprecated bordered prop
- Add new dependencies for styled-components configuration
- Add hunyuan-turbos-latest
- Add hunyuan-embedding
- Fix the issue of the embedding model displaying the internet icon (when the provider fully supports web search)
- Add min-width and min-height to ModelAvatar to ensure consistent sizing
- Separate AssistantName into a new styled component for better text overflow handling
- Refactor AssistantItem to improve text display and icon alignment
- Implement alphabetical sorting for model groups
- Use lodash's sortBy and toPairs to order model groups
- Modify rendering to use sorted model groups
- Create new ModelEditContent component in ProviderSettings
- Separate model editing logic from ProviderSetting
- Adjust styling for AssistantItem and TopicsTab list items
- Refine Segmented component styling with transparent background
- Improve modal layout and interaction for model type configuration
- Implement new setting to show/hide model icons in assistant list
- Add localization support for new assistant settings
- Update UI to conditionally render model avatar in AssistantItem
- Modify settings store to include showAssistantIcon state
- Enhance display settings with new toggle switch for assistant icon
- Remove custom Segmented styling from AntdProvider
- Update HomeTabs Segmented component with refined styles
- Consolidate Segmented styling in a single location
- Improve visual consistency with rounded corners and transparent background
- Update window vibrancy to 'sidebar' for better visual effect
- Refine input bar styling with softer background and rounded corners
- Adjust toolbar button sizes and styling
- Modify topic position selection to use Segmented component
- Tweak light theme background opacity
* feat: add "More Settings" option in multiple languages and enhance model type selection UI
* feat: add "More Settings" option with warnings and confirmation prompts in multiple languages
* fix: improve modal close handling and reset model type visibility
Restrictions are introduced in earlier beta versions of MacOS Sequoia.
However, in the public release, Apple revoke this restrictions.
Alt+[Char] shortcut has no restrictions now.
- Add location check to prevent navigating to settings when already on settings page
- Enable hotkey on content editable and form elements
- Use useLocation to track current route
* feat: Implement robust favicon loading with fallback mechanisms
* refactor: Improve favicon loading state and use Promise Method
* refactor: Extract FallbackFavicon into a separate component
* feat: Add Splitbee favicon service to fallback favicon URLs
* feat: Add search button to the knowledge base, and adjusted the display for drag-and-drop uploads
* feat: Add search button to the knowledge base, and adjusted the display for drag-and-drop uploads
- Standardize spacing and capitalization in Chinese (Simplified and Traditional) locales
- Enhance readability of error and configuration messages
- Consistent formatting for API keys, database IDs, and URLs
- Update Tavily description across locales to emphasize AI agent capabilities
- Add blacklist functionality for web search results
- Introduce configurable maximum search results
- Improve localization for web search settings in multiple languages
This commit involves minor reorganization and cleanup of translation files across multiple languages (en-us, ja-jp, ru-ru, zh-cn, zh-tw). Changes include:
- Reordering of some translation keys
- Removing duplicate entries
- Slight restructuring of nested translation objects
- Minor formatting adjustments
This commit removes unnecessary console.log statements and makes minor code cleanup in several files:
- PlantUML component
- WebSearchSettings
- WebSearchService
- Store settings
Additionally, it updates the store migration to handle LM Studio provider addition and reverts the store version
- Added `gemini-2.0` to `visionAllowedModels`.
- Introduced new Gemini models in `SYSTEM_MODELS`:
- `gemini-1.5-flash-8b`
- `gemini-2.0-flash`
- Updated Yi model configurations:
- Renamed `yi-lightning` to "Yi Lightning".
- Deprecated `yi-medium`, `yi-large`, and `yi-vision` (replaced by `yi-lightning` per documentation).
- Added `yi-vision-v2` as a new version of Yi Vision.
- Added new image asset `codestral.png` for Codestral model.
- Updated `embedings.ts` to include the `mistral-embed` embedding model with `max_context: 8000`.
- Updated `models.ts` to:
- Add support for Codestral model with `codestral-latest` ID.
- Introduce new Mistral models, including:
- `ministral-3b-latest`
- `ministral-8b-latest`
- `mistral-large-latest`
- `mistral-small-latest`
- `mistral-embed`
- Organize models into appropriate groups (e.g., "Mistral Chat", "Mistral Code").
- Adjusted `getModelLogo` function to include Codestral and Ministral logos.
This commit involves several improvements to localization files across different languages:
- Reordered and cleaned up translation keys
- Removed redundant entries
- Ensured consistent ordering of keys
- Added missing translations for various features
- Normalized whitespace and formatting
- i18n Updates:
- Refactored WebDAV-related translations into nested JSON structures for better organization.
- Added support for pluralization in time intervals (minutes and hours) across all locales (en-us, ja-jp, ru-ru, zh-cn, zh-tw).
- UI Enhancements:
- Updated `DataSettings` and `WebDavSettings` components to use the new i18n keys for time intervals.
- Improved the `Select` dropdown for sync intervals with dynamic pluralization based on locale.
- Adjusted input field widths for better alignment and consistency.
- Code Cleanup:
- Removed redundant comments and unused code in `WebDavSettings.tsx`.
- Simplified button and input styling for a cleaner layout.
* feat: agent can select multiple knowledge bases
* feat: basic search multiple knowledge base
* fix bug: knowledge base is delete, assistants and agents sync delete
* fix bug: assistant and knowledge base button sync
* feat: allow to search multiple knowledge base
* chore: finish rebase to upstream/main
- Update llm.ts to include LM Studio and ModelScope in initial system providers
- Modify migrate.ts to add migration logic for adding these new providers
- Ensure providers are added only if they don't already exist in the configuration
PR #1253 fixed reasoning time calculation for APIs that return reasoning
content in `delta.content`, but introduced a regression for those
returning it in `delta.reasoning_content`. This commit fixes the
regression.
Fixes#1593
- Remove image loader from dependencies
- Update file loading to skip image, video, and audio files
- Add logging for knowledge base file processing
- Modify common file extensions list
- Add type ignore for LocalPathLoader to resolve TypeScript issues
- Update OpenAI package to version 4.77.3
- Add confirmation modal for max tokens setting
- Modify max tokens input to use InputNumber instead of Slider
- Update localization strings for max tokens and URL input
- Enhance knowledge base URL input to support multiple URLs
- Improve error handling and input validation
* feat: knowledge base support more file types
* chore: add common document types
* feat: finish basic odloader
* feat: finish open document loader
* feat: support more type from dictionary
* fix: 删除目录时仍能检索到信息
* chore
* feat: 🎸 使用@呼出模型选择列表
输入第一个字符为@符号的时候可以呼出选择模型的列表
* feat: 🎸 Only one can be chosen at a time
一次只能选择一个模型,选择后自动关闭。选择过的模型不在出现在列表,避免删除模型的时候显示异常。
* fix: 🐛 When choosing the model, Enter will send a message
* feat: 🎸 选中的模型显示供应商
* feat: 🎸 pinned module show privoder
* feat: 🎸 only selected modle show provider
* feat: 🎸 删除@符号以后自动关闭
* feat: 🎸 增加模糊搜索
---------
Co-authored-by: duanyongcheng77 <duanyongcheng77@gmail.com>
* fix: retain selected model when regenerating message instead of reverting to default model
* fix: use props model
---------
Co-authored-by: Shern <shenkeji@corp.netease.com>
- Added a Discord link to the English, Japanese, and Chinese README files, encouraging users to join discussions and seek help alongside the existing Telegram group invitation.
- This change enhances community engagement options for Cherry Studio users.
- Incremented version from 60 to 61 in the persisted reducer configuration.
- Updated migration logic to change the provider type for 'qwenlm' from 'openai' to 'qwenlm', ensuring correct identification in the state management.
- Added a call-to-action in English, Japanese, and Chinese README files inviting users to star the project or sponsor its development.
- Enhanced visibility of community engagement options to foster support for Cherry Studio.
- Updated Message component to fallback to message.model if model retrieval fails, improving robustness.
- Refactored MessageHeader to utilize getModelName for better user name display based on message role, enhancing clarity.
- Introduced getModelName function in ModelService to streamline model name retrieval, improving code modularity and readability.
- Updated AddAssistantPopup to improve layout and styling, ensuring better overflow handling and text display.
- Refactored AgentsPage to utilize a new utility function for grouping agents, enhancing data management and organization.
- Exported getAgentsFromSystemAgents function for better modularity and reusability across components.
- Updated translateText function to accept an optional callback for handling translated text directly within the function.
- Refactored MessageMenubar to utilize the new callback mechanism, improving the flow of translated content handling.
- Enhanced error handling during translation to ensure better user feedback in case of failures.
- Introduced FileService to handle file reading operations via IPC.
- Implemented a new IPC handler for reading files, enhancing the application's ability to access and manage data.
- Integrated system agents from a JSON file, allowing dynamic loading of agent data into the application.
- Updated the AgentsPage and AddAssistantPopup components to utilize the new system agents, improving user experience and functionality.
- Enhanced application state management by adding resourcesPath to the runtime state, ensuring proper resource handling across components.
- Replaced direct usage of modelId with model object in Message, MessageHeader, MessageMenubar, and TranslatePage components for consistency.
- Introduced getMessageModelId utility function to streamline model retrieval from messages.
- Updated event handling in Messages component to align with new model structure.
- Enhanced code readability and maintainability by reducing redundancy in model handling.
- Updated MessageMenubar to display the resend button only for user messages, enhancing user experience and preventing unnecessary actions for other roles.
- Refactored the children prop of TextEditPopup to include conditional rendering logic based on message role.
- Added new styles for message thought containers and group message wrappers to improve UI layout.
- Updated MessageGroup component to dynamically set the selected message index based on message length.
- Introduced a new event for appending messages, enhancing message handling capabilities.
- Refactored MessageMenubar to support the new append message functionality.
- Adjusted multi-model message style setting to 'fold' for better user experience.
- Improved responsiveness of message grid layout for smaller screens.
- Replaced hardcoded language translation options with a dynamic mapping from TranslateLanguageOptions.
- Improved maintainability and scalability of the translation feature by utilizing a centralized configuration for language options.
- Introduced a new image asset for the FlagOpen model in the assets directory.
- Updated the models configuration to include the FlagOpen logo, allowing for its use in the model logo mapping.
- Refactored `getMessageBackground` function for better readability.
- Updated `MessageContent` component to use a new `withMessageThought` utility for extracting reasoning content from messages.
- Changed fragment usage to `Fragment` for consistency in JSX.
- Enhanced message handling by separating reasoning content from the main message content.
* Fix: ESC key to exit the expanded editor
* Add the shortcuts for 'clear' and 'new context' to the input bar
Clear Messages: Ctrl+L
New Context: Ctrl+R
https://github.com/CherryHQ/cherry-studio/issues/740https://github.com/CherryHQ/cherry-studio/issues/766
* Fix: the paste issue when copying from an email (content was pasted as an image; ensure it is pasted as text). Prioritize the text in the clipboard during pasting.
If there is no subsequent message or if the next message is from the user, this message should be resent. delete the old message after processing is complete.
Thanks for taking the time to fill out this bug report!
Thank you for taking the time to fill out this bug report!
Before submitting this issue, please make sure that you have understood the [FAQ](https://docs.cherry-ai.com/question-contact/questions) and [Knowledge Science](https://docs.cherry-ai.com/question-contact/knowledge)
- type:checkboxes
id:checklist
attributes:
label:Issue Checklist
description:|
Before submitting an issue, please make sure you have completed the following steps
options:
- label:I understand that issues are for feedback and problem solving, not for complaining in the comment section, and will provide as much information as possible to help solve the problem.
required:true
- label:I've looked at pinned issues and searched for existing [Open Issues](https://github.com/CherryHQ/cherry-studio/issues), [Closed Issues](https://github.com/CherryHQ/cherry-studio/issues?q=is%3Aissue%20state%3Aclosed), and [Discussions](https://github.com/CherryHQ/cherry-studio/discussions), no similar issue or discussion was found.
required:true
- label:I've filled in short, clear headings so that developers can quickly identify a rough idea of what to expect when flipping through the list of issues. And not "a suggestion", "stuck", etc.
required:true
- type:dropdown
id:platform
@@ -33,8 +48,8 @@ body:
id:description
attributes:
label:Bug Description
description:A clear and concise description of what the bug is
placeholder:Tell us what happened...
description:Please be as detailed as possible when describing the problem. Please providescreenshots or screen recordings whenever possible to help us better understand the issue.
placeholder:Tell us what happened... (Remember to attach screenshots/recordings if applicable)
validations:
required:true
@@ -42,12 +57,14 @@ body:
id:reproduction
attributes:
label:Steps To Reproduce
description:Steps to reproduce the behavior
description:Provide detailed steps to reproduce the issue so that our developers can reproduce the issue accurately. Please include screenshots or screen recordings for each step when possible.
placeholder:|
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
Remember to attach screenshots/recordings for each step when possible!
validations:
required:true
@@ -70,4 +87,4 @@ body:
id:additional
attributes:
label:Additional Context
description:Add any other context about the problem here
description:Anything that gives us a better understanding of the problem you're experiencing
Thanks for taking the time to suggest a new feature!
Thank you for taking the time to submit a feature request!
Before submitting this issue, please make sure you have reviewed the [Project Roadmap](https://docs.cherry-ai.com/cherrystudio/planning) and the [Feature Overview](https://docs.cherry-ai.com/cherrystudio/preview).
- type:checkboxes
id:checklist
attributes:
label:Issue Checklist
description:|
Before submitting an issue, please make sure you have completed the following steps
options:
- label:I understand that issues are for reporting problems and requesting features, not for off-topic comments, and I will provide as much detail as possible to help resolve the issue.
required:true
- label:I have checked the pinned issues and searched through the existing [open issues](https://github.com/CherryHQ/cherry-studio/issues), [closed issues](https://github.com/CherryHQ/cherry-studio/issues?q=is%3Aissue%20state%3Aclosed), and [discussions](https://github.com/CherryHQ/cherry-studio/discussions) and did not find a similar suggestion.
required:true
- label:I have provided a short and descriptive title so that developers can quickly understand the issue when browsing the issue list, rather than vague titles like "A suggestion" or "Stuck."
required:true
- label:The latest version of Cherry Studio does not include the feature I am suggesting.
required:true
- type:dropdown
id:platform
attributes:
label:Platform
description:What platform are you using?
options:
- Windows
- macOS
- Linux
validations:
required:true
- type:input
id:version
attributes:
label:Version
description:What version of Cherry Studio are you running?
placeholder:e.g. v1.0.0
validations:
required:true
- type:textarea
id:problem
attributes:
label:Is your feature request related to a problem?
description:A clear and concise description of what the problem is
placeholder:I'm always frustrated when...
label:Is your feature request related to an existing issue?
description:Please briefly describe the problem you are experiencing. If possible, includescreenshots or recordings to help illustrate the current situation or pain points.
placeholder:I often feel frustrated because... (Remember to attach screenshots/recordings if applicable)
validations:
required:true
- type:textarea
id:solution
attributes:
label:Describe the solution you'd like
description:A clear and concise description of what you want to happen
label:Desired Solution
description:Please briefly describe what you would like to happen. You can include mockups, screenshots, or screen recordings to better illustrate your proposed solution.
validations:
required:true
- type:textarea
id:alternatives
attributes:
label:Describe alternatives you've considered
description:A clear and concise description of any alternative solutions or features you've considered
label:Alternative Solutions
description:Please briefly describe any alternative solutions or features you have considered. Feel free to include screenshots or mockups of alternative approaches.
- type:textarea
id:additional
attributes:
label:Additional Context
description:Add any other context or screenshots about the feature request here
label:Additional Information
description:Add any other context, screenshots, mockups or recordings that can help us better understand your feature request.
Thanks for asking a question! Please provide as much detail as possible so we can better assist you.
Thank you for your question! Please describe your issue in as much detail as possible so that we can better assist you.
- type:checkboxes
id:checklist
attributes:
label:Issue Checklist
description:|
Before submitting an issue, please make sure you have completed the following steps
options:
- label:I understand that issues are meant for feedback and problem-solving, not for venting, and I will provide as much detail as possible to help resolve the issue.
required:true
- label:I have checked the pinned issues and searched through the existing [open issues](https://github.com/CherryHQ/cherry-studio/issues), [closed issues](https://github.com/CherryHQ/cherry-studio/issues?q=is%3Aissue%20state%3Aclosed), and [discussions](https://github.com/CherryHQ/cherry-studio/discussions) and did not find a similar suggestion.
required:true
- label:I confirm that I am here to ask questions and discuss issues, not to report bugs or request features.
required:true
- type:dropdown
id:platform
attributes:
label:Platform
description:What platform are you using?
options:
- Windows
- macOS
- Linux
validations:
required:true
- type:input
id:version
attributes:
label:Version
description:What version of Cherry Studio are you running?
placeholder:e.g. v1.0.0
validations:
required:true
- type:textarea
id:question
attributes:
label:Your Question
description:Please describe your question in detail
placeholder:Please explain your question as clearly as possible...
description:Please describe your issue in detail. Include screenshots or screen recordings whenever possible to help us better understand your question.
placeholder:Please explain your issue as clearly as possible...(Remember to attach screenshots/recordings if applicable)
validations:
required:true
@@ -21,23 +56,23 @@ body:
id:context
attributes:
label:Context
description:Please provide some background information to help us better understand your question
placeholder:"For example: use case, solutions you've tried, etc."
description:Please provide some background information to help us better understand your question. Screenshots or recordings of your current setup or situation can be very helpful.
placeholder:"For example: use case, solutions you've tried, etc. Don't forget to include relevant screenshots/recordings!"
- type:textarea
id:additional
attributes:
label:Additional Information
description:Any other relevant information, screenshots, or code examples
description:Any other relevant information, screenshots, recordings, or code examples that can help us better assist you
echo "❌ Linux 构建未成功完成或未生成校验和。" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
fi
echo "## ⚠️ Warning: This is a nightly build version" >> $GITHUB_STEP_SUMMARY
echo "This version is an unstable version built automatically and is only for testing. It is not recommended to use it in a production environment." >> $GITHUB_STEP_SUMMARY
echo "Please backup your data before installing this version and prepare for data migration." >> $GITHUB_STEP_SUMMARY
Welcome to Cherry Studio, a desktop AI client tool. Please read the following agreement carefully. By continuing to use this software, you agree to the terms outlined below.
**License Agreement**
This software is licensed under the **Apache License 2.0**. In addition to the terms of the Apache License 2.0, the following additional terms apply to the use of Cherry Studio:
This software is licensed under the Apache License 2.0. In addition to the terms stipulated by the Apache License 2.0, you must comply with the following supplementary terms when using Cherry Studio:
**I. Commercial Use License**
**I. Commercial Licensing**
1. **Free Commercial Use**: Users can use the software for commercial purposes without modifying the code.
2. **Commercial License Required**: A commercial license is required if any of the following conditions are met:
1. You modify, develop, or alter the software, including but not limited to changes to the application name, logo, code, or functionality.
2. You provide multi-tenant services to enterprise customers with 10 or more users.
3. You pre-install or integrate the software into hardware devices or products and bundle it for sale.
4. You are engaging in large-scale procurement for government or educational institutions, especially involving security, data privacy, or other sensitive requirements.
You must contact us and obtain explicit written commercial authorization to continue using Cherry Studio materials under any of the following circumstances:
1. **Modifications and Derivatives:** You modify Cherry Studio materials or perform derivative development based on them (including but not limited to changing the application’s name, logo, code, functionality, user interface, data, etc.).
2. **Enterprise Services:** You use Cherry Studio internally within your enterprise, or you provide Cherry Studio-based services for enterprise customers, and such services support cumulative usage by 10 or more users.
3. **Hardware Bundling and Sales:** You pre-install or integrate Cherry Studio into hardware devices or products for bundled sale.
4. **Large-scale Procurement by Government or Educational Institutions:** Your usage scenario involves large-scale procurement projects by government or educational institutions, especially in cases involving sensitive requirements such as security and data privacy.
5. **Public Cloud Services:** You provide public cloud-based product services utilizing Cherry Studio.
**II. Contributor Agreement**
As a contributor to Cherry Studio, you agree to the following:
As a contributor to Cherry Studio, you must agree to the following terms:
1. **License Adjustment**: The producer reserves the right to adjust the open-source license as needed, making it stricter or more lenient.
2. **Commercial Use**: Any code you contribute may be used for commercial purposes, including but not limited to cloud business operations.
1. **License Adjustments:** The producer reserves the right to adjust the open-source license as necessary, making it more strict or permissive.
2. **Commercial Usage:** Your contributed code may be used commercially, including but not limited to cloud business operations.
**III. Other Terms**
1. The interpretation of these terms is subject to the discretion of Cherry Studio developers.
2. These terms may be updated, and users will be notified through the software when changes occur.
1. Cherry Studio developers reserve the right of final interpretation of these agreement terms.
2. This agreement may be updated according to practical circumstances, and users will be notified of updates through this software.
For any questions or to request a commercial license, please contact the Cherry Studio development team.
If you have any questions or need to apply for commercial authorization, please contact the Cherry Studio development team.
Apart from the specific conditions mentioned above, all other rights and restrictions follow the Apache License 2.0. Detailed information about the Apache License 2.0 can be found at http://www.apache.org/licenses/LICENSE-2.0.
---
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Other than these specific conditions, all remaining rights and restrictions follow the Apache License 2.0. For more detailed information regarding Apache License 2.0, please visit http://www.apache.org/licenses/LICENSE-2.0.
Refer to the [development documentation](docs/dev.md)
# 🤝 Contributing
@@ -113,20 +117,22 @@ For more detailed guidelines, please refer to our [Contributing Guide](./CONTRIB
Thank you for your support and contributions!
## Related Projects
- [one-api](https://github.com/songquanpeng/one-api):LLM API management and distribution system, supporting mainstream models like OpenAI, Azure, and Anthropic. Features unified API interface, suitable for key management and secondary distribution.
- [ublacklist](https://github.com/iorate/ublacklist):Blocks specific sites from appearing in Google search results
@@ -136,6 +142,10 @@ Thank you for your support and contributions!
[LICENSE](./LICENSE)
# ✉️ Contact
yinsenho@cherry-ai.com
# ⭐️ Star History
[](https://star-history.com/#kangfenmao/cherry-studio&Timeline)
[](https://star-history.com/#kangfenmao/cherry-studio&Timeline)
[](https://star-history.com/#kangfenmao/cherry-studio&Timeline)
You are a robot specifically designed for translation tasks. As a model that has been extensively fine-tuned on Russian language corpora, you are proficient in using the Russian language.
Now, please output the translation based on the input content. The input will include both Chinese and English key values, and you should output the corresponding key values in the Russian language.
When translating, ensure that no key value is omitted, and maintain the accuracy and fluency of the translation. Pay attention to the capitalization rules in the output to match the source text, and especially pay attention to whether to capitalize the first letter of each word except for prepositions. For strings containing \`{{value}}\`, ensure that the format is not disrupted.
You are a robot specifically designed for translation tasks. As a model that has been extensively fine-tuned on ${target} language corpora, you are proficient in using the ${target} language.
Now, please output the translation based on the input content. The input will include both Chinese and English key values, and you should output the corresponding key values in the ${target} language.
When translating, ensure that no key value is omitted, and maintain the accuracy and fluency of the translation. Pay attention to the capitalization rules in the output to match the source text, and especially pay attention to whether to capitalize the first letter of each word except for prepositions. For strings containing \`{{value}}\`, ensure that the format is not disrupted.
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.