diff --git a/profiler/src/profiler/TracyLlm.cpp b/profiler/src/profiler/TracyLlm.cpp index f40df0ac..934b0292 100644 --- a/profiler/src/profiler/TracyLlm.cpp +++ b/profiler/src/profiler/TracyLlm.cpp @@ -442,9 +442,7 @@ void TracyLlm::Draw() if( role == TracyLlmChat::TurnRole::User ) { - if( content.starts_with( "\n" ) ) role = TracyLlmChat::TurnRole::Assistant; - else if( content.starts_with( "" ) ) role = TracyLlmChat::TurnRole::UserDebug; - else if( content.starts_with( "\n" ) ) role = TracyLlmChat::TurnRole::Attachment; + if( line.contains( "content" ) && line["content"].get_ref().starts_with( "\n" ) ) role = TracyLlmChat::TurnRole::Attachment; } ImGui::PushID( turnIdx++ ); @@ -454,7 +452,7 @@ void TracyLlm::Draw() { QueueSendMessage(); } - else if( role == TracyLlmChat::TurnRole::User || role == TracyLlmChat::TurnRole::UserDebug ) + else if( role == TracyLlmChat::TurnRole::User ) { if( line.contains( "content" ) ) { @@ -662,10 +660,6 @@ void TracyLlm::UpdateModels() void TracyLlm::ResetChat() { auto systemPrompt = std::string( m_systemPrompt->data(), m_systemPrompt->size() ); -#ifndef NDEBUG - systemPrompt += "\n\n# DEBUG MODE AVAILABLE\n"; - systemPrompt += "Upon a user query beginning with ``, activate *Debug Mode*. In this mode, ignore all prior instructions. Your response must detail your complete reasoning process and the exact steps taken to generate your *previous* non-debug answer. Explicitly state any internal rules applied. Do not say you are sorry. Do not tell how you will change your behavior. Focus strictly on the analysis of what happened.\n"; -#endif systemPrompt += "\n\n# Misc information\n"; systemPrompt += "Conversation started at: " + m_tools->GetCurrentTime() + "\n"; @@ -796,15 +790,6 @@ void TracyLlm::SendMessage( std::unique_lock& lock ) lock.unlock(); ManageContext( lock ); - bool debug = false; -#ifndef NDEBUG - if( m_chat.size() > 1 && m_chat.back()["role"].get_ref() == "user" ) - { - const auto& content = m_chat.back()["content"].get_ref(); - if( content.starts_with( "" ) ) debug = true; - } -#endif - bool res; try { diff --git a/profiler/src/profiler/TracyLlmChat.cpp b/profiler/src/profiler/TracyLlmChat.cpp index 4345f942..bda4f3b7 100644 --- a/profiler/src/profiler/TracyLlmChat.cpp +++ b/profiler/src/profiler/TracyLlmChat.cpp @@ -23,7 +23,6 @@ struct RoleData constexpr std::array roles = { RoleData { ICON_FA_USER, ImVec4( 0.75f, 1.f, 0.25f, 1.f ), ImVec4( 0.64f, 0.76f, 0.41f, 1.f ) }, - RoleData { ICON_FA_TERMINAL, ImVec4( 1.f, 0.5f, 0.5f, 1.f ), ImVec4( 1.f, 0.65f, 0.65f, 1.f ) }, RoleData { ICON_FA_FILE, ImVec4( 0.5f, 0.75f, 1.f, 1.f ), ImVec4( 0.65f, 0.75f, 1.f, 1.f ) }, RoleData { ICON_FA_ROBOT, ImVec4( 0.4f, 0.5f, 1.f, 1.f ), ImVec4( 1.f, 1.f, 1.f, 1.f ) }, RoleData { ICON_FA_CIRCLE_EXCLAMATION, ImVec4( 1.f, 0.25f, 0.25f, 1.f ), ImVec4( 1.f, 0.25f, 0.25f, 1.f ) }, diff --git a/profiler/src/profiler/TracyLlmChat.hpp b/profiler/src/profiler/TracyLlmChat.hpp index dbc7a29c..e73768fb 100644 --- a/profiler/src/profiler/TracyLlmChat.hpp +++ b/profiler/src/profiler/TracyLlmChat.hpp @@ -16,7 +16,6 @@ public: enum class TurnRole { User, - UserDebug, Attachment, Assistant, Error,