From 64e88bd4938db94de6443f73f8cef5e06c56af8a Mon Sep 17 00:00:00 2001 From: n4ze3m Date: Sat, 16 Nov 2024 19:33:20 +0530 Subject: [PATCH] feat: Add support for chat mode in MessageSource component This commit extends the `MessageSource` component to support the `chat` mode in addition to the existing `rag` mode. This allows the component to handle and display messages from both chat and RAG (Rapid Automated Generation) sources. --- src/components/Common/Playground/MessageSource.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/Common/Playground/MessageSource.tsx b/src/components/Common/Playground/MessageSource.tsx index d0a006a..b0d3ad9 100644 --- a/src/components/Common/Playground/MessageSource.tsx +++ b/src/components/Common/Playground/MessageSource.tsx @@ -13,7 +13,7 @@ type Props = { } export const MessageSource: React.FC = ({ source, onSourceClick }) => { - if (source?.mode === "rag") { + if (source?.mode === "rag" || source?.mode === "chat") { return (