Commit graph

17 commits

Author SHA1 Message Date
Max
1058598be3 Enhance localization support in chat and assistant functionalities
- Added locale parameter to GetChats, GetChat, and GetAssistants methods across various store implementations for improved localization.
- Updated handleChatList, handleChatLatest, and handleChatDetail functions to utilize the new locale handling for better user experience.
- Refactored assistant methods to support localized names and descriptions based on user input.
- Introduced WithLocale function in context to manage locale settings effectively.
2025-05-27 11:49:19 +08:00
Max
6467a9c37e Refactor API response handling and enhance locale support in assistant functions
- Removed the generateResponse struct and its associated methods to simplify response handling.
- Added locale support in handleAssistantList and handleAssistantDetail functions to allow for localized responses based on user input.
- Updated the Context struct to include locale information for better customization.
- Refactored the Load function in load.go to incorporate i18n support for assistant localization.
2025-05-24 20:36:00 +08:00
Max
9a0ad73f4c Enhance Context struct by adding Locale and Theme fields
- Introduced Locale and Theme fields to the Context struct for improved customization options.
- Updated the Map method to include these new fields in the returned data.
2025-05-19 18:15:36 +08:00
Max
aca3014167 feat: Add support for Vision and Search in Assistant API
- Introduced Vision and Search capabilities in the Assistant API, enhancing its functionality.
- Updated the Context struct to include Vision and Search fields for better context management.
- Added a new Search type to facilitate search engine integration.
- Adjusted the execute method to handle the new features appropriately.
2025-05-14 16:03:13 +08:00
Max
eb89272048 fix: Update client type constant for Android in context management
- Renamed ClientTypeSDK to ClientTypeAndroid for clarity and consistency in client type definitions.
- Updated SupportedClientTypes map to reflect the change in client type naming.
2025-05-09 12:14:41 +08:00
Max
712bb99ab1 feat: Enhance context management and update asset metadata in SUI
- Updated modification times for various asset files in bindata.go to reflect recent changes.
- Improved context handling in the API by adding support for silent mode, history visibility, and client type.
- Refactored assistant ID usage to ensure consistent access to the default assistant across various methods.
- Enhanced the Agent class in libsui/agent.ts to manage silent mode and history visibility settings effectively.
2025-05-08 20:05:39 +08:00
Max
83bdab3499 feat: Enhance context management and agent functionality in SUI
- Added support for assistant ID in context handling to improve user-specific interactions.
- Updated asset metadata in bindata.go to reflect recent changes in modification times.
- Enhanced the Agent class in libsui/agent.ts with improved type definitions for the Call method, ensuring better type safety and clarity in asynchronous operations.
- Improved event handling in the Agent class to manage message completion more effectively.
2025-05-06 19:24:06 +08:00
Max
d3734cf1d0 Add support for passing arguments in assistant method calls
- Extend Context struct to include Args field for storing call arguments
- Modify objectCall.run to capture and store arguments in chat context
- Update context mapping to include arguments when present
2025-03-12 17:24:36 +08:00
Max
c74d32390c Add retry mechanism for chat streaming with error handling
- Implement HookRetry method to handle retry scenarios in chat streaming
- Add retry tracking with RetryTimes and Retry flag in context
- Create retryMessages method to modify messages for retry attempts
- Enhance error handling and logging for retry scenarios
- Add color-coded error output for retry failures
2025-03-03 14:49:31 +08:00
Max
392676f2cb Add silent mode support for chat history and filtering
- Implement silent flag in chat and history storage
- Add filter options to retrieve chats and messages with silent mode
- Update store interfaces to support silent message filtering
- Enhance GetChats, GetHistory, and related methods to handle silent messages
- Add comprehensive test cases for silent mode functionality
2025-03-01 16:08:56 +08:00
Max
ca6d075a22 Add shared space methods to JavaScript bridge
- Implement Set, Get, Del, and Clear methods for shared space interactions
- Add error handling and validation for shared space method calls
- Enhance context management with Release method to clear shared space
- Update context initialization to create a default memory shared space
2025-02-27 16:32:25 +08:00
Max
13c4e65a95 Add retry and silent modes to assistant chat processing
- Introduce retry and silent mode flags in context and message structures
- Modify API and hooks to support new context modes
- Update message handling to propagate retry and silent flags
- Replace debug print statements with structured logging
- Enhance tool call and message processing with new context options
2025-02-18 11:20:20 +08:00
Max
069105d7bd
Revert "Revert "Add RAG and Version support to Assistant context and options"" 2025-01-26 17:05:10 +08:00
Max
b9c89127b6
Revert "Add RAG and Version support to Assistant context and options" 2025-01-26 17:03:06 +08:00
Max
3c38e968f8 Add RAG and Version support to Assistant context and options
- Introduced Version and RAG flags in the Context struct to support advanced assistant features
- Updated Execute method to set RAG and Version context properties
- Enhanced withOptions method to conditionally add custom options and tools
- Modified HookInit to pass options parameter, improving hook flexibility

This change improves the Assistant's configurability and supports more dynamic assistant interactions.
2025-01-26 17:01:03 +08:00
Max
b01f27d70f Refactor assistant initialization and enhance context handling in Neo API
- Updated the Answer method to improve assistant initialization by directly calling the new HookInit method, streamlining the process of selecting and initializing assistants based on context.
- Introduced ResHookInit struct to encapsulate the response from the assistant initialization hook, enhancing clarity and maintainability.
- Enhanced the context package by adding a Map method to facilitate easier mapping of context data, improving the overall structure of context management.
- Refactored the assistant interface to include the new HookInit method, ensuring a consistent approach to assistant interactions.

These changes improve the robustness and maintainability of the Neo API, paving the way for future enhancements in assistant functionalities and context management.
2025-01-13 11:07:12 +08:00
Max
90967f58c1 Refactor Neo API context handling and improve context management
- Replaced the custom context creation functions with a new context package, enhancing consistency and maintainability across the API.
- Updated multiple methods in the DSL to utilize the new context package, ensuring a unified approach to context management.
- Removed the obsolete context.go file, streamlining the codebase and reducing redundancy.

These changes improve the overall structure and clarity of the Neo API, paving the way for future enhancements in context handling and assistant functionalities.
2025-01-06 14:20:39 +08:00