- Updated the AgentEngine to emit final answer events even when the LLM stops without calling the final_answer tool, ensuring the frontend can render responses correctly.
- Added fallback logic in the AgentStreamHandler to emit final answers as fallback events when no answer events are streamed, improving robustness in edge cases.
- Updated DeleteChunks method to split IDs into batches of 5000 to prevent MySQL Error 1390.
- Added unit tests for CalculateFAQContentHash to ensure consistent hashing behavior across various scenarios, including normalization and case sensitivity.
- Removed the validation for a maximum of 10 knowledge IDs in GetDocumentInfoTool to allow more flexibility.
- Adjusted pagination settings in chunk retrieval to limit results to 1 per request for more granular control.
- Updated the searchChunks method to use case-insensitive matching based on the database type, improving compatibility across different systems.
- Enhanced query structure for better readability and maintainability.
- Updated the message streaming logic to handle <think> blocks more effectively, ensuring proper formatting for Feishu.
- Introduced a new transformThinkBlocks function to convert <think> content into Feishu-compatible markdown blockquotes.
- Improved the handling of tool call events to prevent duplicate processing and ensure correct message formatting.
- Enhanced documentation for permission configuration in the IM channel setup.
- Updated formatToolCallStart and formatToolCallResult functions to return plain-text lines instead of Markdown snippets for better integration within <think> blocks.
- Introduced briefToolSummary function to extract concise summaries from tool output.
- Enhanced handleMessageStream to manage <think> blocks more effectively during agent interactions.
- Added handling for server-side events in WeCom long connection management to improve reconnection logic.
1. Added CUDA debugging support
2. Improved memory management during model inference.
3. Fixed logits output
Test Device: Windows WSL Ubuntu 20.04 (python3.10 CUDA 5090 32G)
- Enhanced the SummaryGenerationPayload struct to include a Language field for better localization.
- Updated enqueueSummaryGenerationTask and ProcessSummaryGeneration methods to handle language context in summary generation tasks.
- Modified the session title generation template to focus on extracting only the intent of the user's question.
- Enhanced the session service to include language context when generating titles.
- Updated middleware to inject language into the request context.
- Added a new test suite for validating SSRF safety of URLs.
- Added critical language rules to fallback response templates to ensure consistent language usage in responses.
- Updated logger context to include language and session-related keys for improved context management.
- Added timezone and language settings to the environment configuration.
- Introduced built-in agent configurations with multilingual support for various agents.
- Updated Docker Compose to utilize new environment variables for timezone and language.
- Created new prompt templates for question generation, summary generation, and keywords extraction.
Add specific error handling for 'Endpoint url cannot have fully qualified paths'
to guide users to remove http:// or https:// prefix from endpoint URL."
- Reduced the bottom margin of the tree container from 16px to 10px for better spacing.
- Increased the top margin of the answer toolbar from 4px to 10px to enhance visual separation.
- Added hints for WeCom and Feishu platforms in the IM channel panel to guide users in obtaining credentials.
- Included a recommendation for using WebSocket for easier setup.
- Updated localization files for English, Korean, Russian, and Chinese to support new hints and console links.
- Changed the storage engine warning from a div to a paragraph for better semantic structure.
- Updated the warning icon from 'error-circle' to 'info-circle' to better reflect the message.
- Adjusted CSS styles for the storage engine warning, including reduced gap and margin, and modified font size for improved readability.
- Added a new integration guide link in the IM channel panel description for better user guidance.
- Updated localization files for English, Korean, Russian, and Chinese to include the new 'docLink' key for the integration guide.
- Improved styling for the add button in the IM channel panel to enhance visual alignment and user experience.
- Removed redundant dropdown menu styles from various components and centralized them in a new `dropdown-menu.less` file.
- Updated components to use the unified styles, ensuring consistency in appearance and behavior across the application.
This change simplifies maintenance and enhances the visual coherence of dropdown menus.
Table-driven tests for sanitizeManualDownloadFilename covering normal titles,
each dangerous character replacement (/ \ " \n \r), blank/whitespace-only
titles falling back to "untitled.md", and safe passthrough of = ; characters.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Use mime.FormatMediaType for both attachment and inline Content-Disposition
headers in DownloadKnowledgeFile and the preview handler, preventing header
injection via a user-controlled knowledge title (e.g. containing ';' or '=')
- Extract inline sanitize logic into sanitizeManualDownloadFilename helper and
add a blank/whitespace-only title fallback to "untitled" so the download
never produces a degenerate ".md" filename
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add an early-return branch that streams manual knowledge content
(stored as Markdown in Metadata.content) directly as a .md file,
avoiding the runtime error that occurred when FilePath is empty.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Introduced MessageContentPart and ImageURL types to allow for multi-content messages that can include both text and images.
- Updated the Message struct to include a MultiContent field for handling multiple message parts.
- Modified the ConvertMessages function to prioritize processing of multi-content messages, improving the handling of user messages with images.
These changes enhance the flexibility and functionality of chat messages, enabling richer content delivery.
- Removed outdated instructions regarding the `skip_kb_search` field in the conversation configuration.
- Clarified requirements for `image_description` to ensure it is non-empty when images are present.
- Adjusted the handling of message parts in the chat pipeline to improve image processing.
- Deleted unused migration files related to image handling in the database schema.
These changes enhance the clarity and functionality of the conversation and image processing logic.
- Introduced a new IMChannelPanel component for managing WeCom and Feishu channels.
- Added CRUD operations for IM channels, including create, update, delete, and list functionalities.
- Enhanced the backend with new API endpoints for IM channel management.
- Updated documentation to reflect changes in IM integration and channel management.
- Improved localization support for new IM-related UI elements across multiple languages.
- Added blur handling for the textarea in the Input-field component to prevent errors when navigating away from the component.
- Improved the sanitization process in the AgentStreamDisplay component to preserve specific tags during markdown processing, ensuring accurate content display.
- Introduced new methods for handling FAQ-specific post-processing in the knowledge base service, optimizing retrieval and filtering of search results.
These changes enhance user experience by improving input handling and content rendering in the chat interface.
- Introduced a new `QARequest` type to streamline parameters for KnowledgeQA and AgentQA service calls, replacing multiple parameters with a single structured request.
- Updated the `KnowledgeQA` and `AgentQA` methods in the session service interface to accept the new `QARequest` type, enhancing clarity and maintainability.
- Refactored the request parsing logic to utilize the new `buildQARequest` method, improving code organization and reducing redundancy.
- Implemented a new `resolveAgent` method to simplify custom agent resolution logic, enhancing readability and maintainability.
These changes improve the overall structure and usability of the QA request handling, facilitating easier updates and better code organization.
- Introduced a pulsing animation for the stop button in the Input-field component, enhancing visual feedback.
- Updated the loading indicator in the AgentStreamDisplay component to clarify its purpose and improve overall styling.
These changes enhance user interaction and visual appeal in the chat interface.
- Added a streaming steps container to the AgentStreamDisplay component, allowing for better organization of streaming events.
- Implemented auto-scrolling functionality to keep the latest events in view during streaming.
- Enhanced CSS styles for the streaming steps container and event items, including custom scrollbar styles for improved user experience.
These changes improve the usability and visual appeal of the AgentStreamDisplay, facilitating a smoother interaction during event streaming.
- Introduced a new parameter `webSearchEnabled` to the `AgentQA` method, allowing for conditional web search capabilities.
- Updated the session service interface and handler to accommodate the new parameter, enhancing the flexibility of the AgentQA process.
- Adjusted the configuration to ensure that web search functionality can be toggled based on the provided input.
These changes improve the AgentQA feature by enabling users to control web search integration, enhancing the overall user experience.
- Introduced a new method to resolve embedding model IDs to their actual identity keys (name + endpoint), enabling optimal grouping of knowledge bases across different tenants.
- Updated the concurrent search functionality to utilize the resolved model keys, improving the efficiency of query embedding computations.
- Refactored search target grouping to reduce redundant API calls and enhance performance during hybrid searches.
These changes significantly improve the knowledge search process by ensuring that embeddings are computed efficiently and reused across multiple knowledge bases sharing the same underlying model.
- Enhanced the concurrent search functionality to group search targets by their embedding model, allowing for a single computation of query embeddings per model.
- Implemented batch fetching of knowledge base records to improve efficiency and reduce redundant API calls.
- Updated the HybridSearch method to support multiple knowledge base IDs, enabling combined retrieval for full-KB targets and improving overall search performance.
- Added a new GetQueryEmbedding method to compute embeddings for queries, facilitating reuse across multiple knowledge bases sharing the same model.
These changes significantly enhance the performance and efficiency of the knowledge search process, reducing API calls and improving response times.