Chatgptsansjules#2
Merged
Merged
Conversation
- Introduced a toggle between 'canvas' and 'chat' view modes in CanvasView, allowing users to switch seamlessly. - Updated ChatPanel to accept view mode as a prop, enabling dynamic rendering based on the selected mode. - Enhanced message handling in message-handler.ts to utilize effective model names consistently across streaming events. - Added optional properties to the Message interface for better flexibility in handling chat messages.
… awareness - Updated AI and RAG chat request handlers to accept the sender parameter, allowing for better context management. - Added logic to conditionally fetch page content based on whether the request is internal or external, improving efficiency. - Enhanced logging to provide clearer insights into request origins and handling processes. - Introduced a new streaming request type in StreamingService for better handling of simple text chat streams.
- Removed unnecessary overflow-hidden class from the header in CanvasView for better visual consistency. - Updated ChatPanel to conditionally render message content based on activeViewMode, improving user experience and interaction flow. - Streamlined the rendering logic for initial hub view and message display, enhancing clarity in the component structure.
…consistency - Changed background color from 'bg-slate-850' to 'bg-slate-800' in the dropdown menu of DodaiModelSelector to enhance visual coherence with the overall theme.
…management - Updated MainLayout to include enhanced logic for creating new canvas sessions, including saving current chat sessions and managing conversation history. - Integrated new conversation handling in CanvasView, allowing users to load, delete, and rename conversations with improved state management. - Added a toggle for the chat history panel in CanvasView, enhancing user interaction and accessibility to past conversations. - Refactored the resetChatAndArtifact function to support a callback for pre-reset actions, improving flexibility in chat management. - Updated ChatPanel to support toggling the history panel, streamlining user experience in chat interactions.
…ression in config - Modified ChatPanel to conditionally render based on the onToggleHistory prop, improving user interaction. - Enabled compression in repomix.config.json for optimized configuration settings.
…or enhanced chat management - Added new interfaces for ChatArtifact and ChatArtifactWithHistory to structure chat artifacts and their history. - Updated CanvasView to handle currentArtifact more effectively during conversation loading and saving. - Enhanced useDodaiCanvasHistory hook to manage artifact conversion between storage and canvas formats, improving data handling.
- Disabled compression in repomix.config.json for better compatibility. - Added STREAM_START message handling in agent-service.ts to notify UI when streaming begins. - Improved chat response generation logic to provide clearer user feedback based on artifact generation success or failure. - Updated streaming-service.ts to include a new simple chat stream type for better message handling. - Refactored MainLayout.tsx to streamline chat session saving and removed unused conversation creation logic. - Adjusted CanvasView.tsx to determine panel visibility based on artifact mode and streaming state. - Removed deprecated TextChatView component and its associated hook for a cleaner codebase.
- Updated MainLayout to save current chat sessions with the current artifact and reset active sessions appropriately. - Improved CanvasView to handle new conversation creation and reset chat state, enhancing user experience. - Added a new button in DodaiCanvasHistoryPanel for initiating new conversations, improving accessibility. - Enhanced useDodaiCanvasHistory to support saving sessions as new and resetting active sessions, streamlining chat management. - Added logging for better debugging and tracking of chat session states and actions.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Priority*
Purpose of the PR*
Changes*
This pull request introduces several enhancements and bug fixes to the
MessageHandlerclass, streaming services, and UI components in the Chrome extension. The key changes include adding sender information to specific message handlers, improving artifact generation and streaming logic, and refining UI interactions for better user experience.Enhancements to Message Handling:
handleAiChatRequestandhandleRagChatRequestto include thesenderparameter, enabling sender-specific logic. For example, it now checks if the sender is internal before fetching page content. (chrome-extension/src/background/handlers/message-handler.ts, [1] [2] [3] [4] [5] [6] [7]Improvements to Streaming and Artifact Generation:
effectiveModelNamefor better model selection and consistency during streaming. (chrome-extension/src/background/handlers/message-handler.ts, [1] [2] [3] [4]AgentService. (chrome-extension/src/background/services/agent-service.ts, [1] [2]UI Enhancements:
pages/main/src/components/layout/MainLayout.tsx, [1] [2] [3]packages/ui/lib/components/DodaiSidebar.tsx, packages/ui/lib/components/DodaiSidebar.tsxL54-R56)Structural and Data Model Updates:
ChatArtifactandChatArtifactWithHistoryto represent artifacts and their history in the chat storage. (packages/storage/lib/impl/chat-history-storage.ts, [1] [2]Streaming Service Updates:
simple_text_chat_stream_andsimple_chat_stream_) in theStreamingServiceclass. (chrome-extension/src/background/services/streaming-service.ts, chrome-extension/src/background/services/streaming-service.tsL43-R45)How to check the feature
Reference