diff --git a/frontend/src/components/Message.tsx b/frontend/src/components/Message.tsx index 5971019..f020ed5 100644 --- a/frontend/src/components/Message.tsx +++ b/frontend/src/components/Message.tsx @@ -344,8 +344,10 @@ const MessageContainer = (props: MessageContainerProps) => { {icon !== null && icon} {messageView} - {metadataView} - {copyContent && } + + {copyContent && } + {metadataView} + ; }; @@ -374,31 +376,36 @@ const Message = (props: MessageProps) => { let metadataView = (<>); if (message.metadata) { - metadataView = (<> - - - - - - - - - - - - ); + metadataView = ( + + + + + + + + + + + + + + ); } + const copyContent = message.sender === 'assistant' ? message.content : undefined; + if (!expandable) { /* When not expandable, the styles are applied directly to MessageContainer */ return (<> - {messageView && } + {messageView && } ); } @@ -427,7 +434,7 @@ const Message = (props: MessageProps) => { {title || ''} - + ); diff --git a/src/backend/agents/base.py b/src/backend/agents/base.py index 3ed7fab..c0461e3 100644 --- a/src/backend/agents/base.py +++ b/src/backend/agents/base.py @@ -447,7 +447,7 @@ Content: { content } messages.append( LLMMessage( role="user", - content=f"<|context|>\n{rag_context.strip()}\n\n\nPrompt to respond to:\n{user_message.content.strip()}\n" + content=f"<|context|>\nThe following is context information about {user.full_name}:\n{rag_context.strip()}\n\n\nPrompt to respond to:\n{user_message.content.strip()}\n" ) ) else: