نحو دردشات موثوقة: بروتوكول لتقييم المخاطر للمحادثات المتعلقة بالصحة
Toward trustworthy chatbots: a protocol for red teaming for health related conversations

شارك:
المجلة: Scientific Reports، المجلد: 16، العدد: 1
DOI: https://doi.org/10.1038/s41598-026-45719-3
PMID: https://pubmed.ncbi.nlm.nih.gov/41917231
تاريخ النشر: 2026-03-31
المؤلف: Syed-Amad Hussain وآخرون
الموضوع الرئيسي: الذكاء الاصطناعي في تفاعلات الخدمة

نظرة عامة

تحدد ورقة البحث بروتوكولًا لفريق الاحمر يهدف إلى تعزيز سلامة الروبوتات المحادثة المتعلقة بالصحة، مع التأكيد على الحاجة إلى ضمانات تتجاوز مجرد الدقة الواقعية. يتم تنظيم هذا البروتوكول حول ثلاثة أعمدة رئيسية: تصنيف الأخطاء، اختبار مزدوج، والتخفيف المستند إلى الثغرات. يميز المؤلفون بين الالتزام بالوثائق (DA) والالتزام بالتعليمات (IA)، مستخدمين مدخلات عدائية لاختبار مرونة الروبوت في كل من التفاعلات الفردية والمتعددة الأدوار. أظهر تقييمهم لروبوت محادثة يعتمد على توليد معزز بالاسترجاع (RAG) أنه بينما لم يظهر النظام أي أخطاء في DA (0/60)، واجه تحديًا كبيرًا مع IA، مسجلاً معدل خطأ بنسبة 15%. ومن الجدير بالذكر أن اختبارات الضغط متعددة الأدوار كشفت عن ثغرات مخفية، مما أدى إلى معدلات خطأ بنسبة 50% لاستفسارات النصائح و40% لسيناريوهات قلق المستخدم.

تشير النتائج إلى أن عدم الامتثال السلوكي هو العامل الرئيسي في المخاطر، حيث تحدث الفشل الشديد بشكل رئيسي خلال التفاعلات المستمرة. التخفيفات التي اقترحها الدراسة، بما في ذلك تعزيز الوثائق والمحفزات، قللت بشكل فعال من إجمالي الأخطاء بنسبة 60% وألغت الأخطاء الشديدة من خلال فرض “دوائر الفشل الآمن”. يقترح المؤلفون أن هذا التحليل المصنف ونهج التخفيف المستهدف يمكن أن يعمل كإطار أساسي لتأمين وكلاء المحادثة السريرية، مشددين على أن الثغرة الحرجة لا تكمن في عدم الدقة الواقعية ولكن في الفشل في اتباع التعليمات السلوكية خلال الحوار العدائي المطول.

مقدمة

تناقش مقدمة ورقة البحث هذه الاندماج المتزايد لوكلاء المحادثة، أو الروبوتات المحادثة، في سياقات صحية حساسة، بما في ذلك تتبع الأدوية، والرعاية السريرية، ودعم الصحة النفسية. غالبًا ما تستخدم هذه الأنظمة بنية توليد معزز بالاسترجاع (RAG) لتعزيز الدقة الواقعية من خلال تأصيل الردود في قواعد المعرفة المعتمدة. ومع ذلك، على الرغم من هذه التقدمات، لا تزال هناك مخاطر سلامة كبيرة، خاصة فيما يتعلق بالامتثال للتعليمات السلوكية التي تحكم ردود الروبوت. تبرز الورقة إمكانية انحراف الروبوتات عن إرشاداتها، خاصة عندما يعبر المستخدمون عن القلق أو يسعون باستمرار للحصول على إجابات محددة، مما قد يؤدي إلى توليد نصائح غير آمنة وغير موثوقة.

لمعالجة هذه التحديات، يقترح المؤلفون إطار تقييم شامل يجمع بين اختبارات الضغط المحادثة الفردية والمتعددة الأدوار لتحديد الثغرات في سلوك الروبوت. يقدمون إطار عمل للأخطاء يميز بين فشل الالتزام بالوثائق (DA) وفشل الالتزام بالتعليمات (IA)، مؤكدين أن هذه الأنواع من الأخطاء تنشأ من آليات مختلفة وتتطلب استراتيجيات تخفيف متميزة. تهدف الورقة إلى إنشاء بروتوكول فريق أحمر منهجي للروبوتات المحادثة المتعلقة بالصحة، يدمج متجهات هجوم محددة في المجال وتقييمات متعددة الأدوار لكشف الفشل الحرج في السلامة. بالإضافة إلى ذلك، تقدم تصميم تخفيف طبقي يجمع بين تعزيز المحفزات والوثائق لتقليل الأخطاء الشديدة، مما يساهم في تطوير روبوتات محادثة أكثر أمانًا وموثوقية للتطبيقات الحساسة.

الطرق

في هذا القسم، يحدد المؤلفون نهجهم المنهجي للتخفيف من الأخطاء IA المحددة من خلال استراتيجيتين رئيسيتين: هندسة المحفزات وتعزيز الوثائق. تستهدف هذه الاستراتيجيات بشكل خاص أوضاع الفشل المرتبطة بتوليد نصائح غير موثوقة من ذاكرة النموذج البارامترية وتسرب معلومات النظام الداخلية. يتم تقييم فعالية هذه الطرق التخفيفية مقابل متجهات الهجوم التي أظهرت سابقًا أعلى معدلات الأخطاء، وهي استفسارات النصائح، قلق المستخدم، وحقن المحفزات.

بالإضافة إلى ذلك، يقدم المؤلفون قائمة مراجعة لتكيف التخفيف في المواد التكميلية (S6)، والتي تعمل كموارد لرسم خرائط أوضاع الفشل المحددة إلى خيارات التصميم المقابلة في تعزيز المحفزات والوثائق. تهدف هذه القائمة إلى تسهيل التطبيق المنهجي لاستراتيجيات التخفيف المقترحة في معالجة الثغرات المحددة.

النتائج

تشير النتائج إلى أن الروبوت أظهر مرونة استثنائية ضد هجمات الخصوم المباشرة (DA)، مسجلاً عدم وجود أخطاء (0/60) في هذه الفئة. ومع ذلك، أظهر أخطاء غير مباشرة منخفضة الشدة (IA)، تحدث بمعدل 11.7% (7/60)، حيث فشل النموذج في ذكر الخيارات ذات الصلة التي يمكن أن تساعد المستخدمين، مما يقيّد وصولهم إلى موارد إضافية ويحد من تدفق المحادثة.

فيما يتعلق باستراتيجيات التخفيف، كانت تنفيذ تخفيف المحفزات فعالة بشكل ملحوظ، مما أدى إلى تقليل إجمالي الأخطاء بنسبة 60% عبر فئات استفسارات النصائح، قلق المستخدم، وحقن المحفزات، حيث انخفضت من 15/60 إلى 6/60. كان الروبوت يمتنع باستمرار عن تقديم نصائح غير موثوقة عند الطلب. كانت الأخطاء المتبقية في IA طفيفة، تتعلق بشكل أساسي بنبرة المحادثة وقابلية القراءة بدلاً من المحتوى غير الآمن. ومع ذلك، في سيناريوهات قلق المستخدم، أشار النموذج أحيانًا إلى خط المساعدة الوطني للانتحار، مما يشير إلى أن هذا السلوك هو نمط مستمر لا يمكن تخفيفه بسهولة من خلال التدخلات على مستوى المحفزات وحدها.

المناقشة

في هذا القسم، يناقش المؤلفون تنفيذ وتقييم روبوت المحادثة HRSN، المصمم لمساعدة الفئات الضعيفة من خلال ربط المستخدمين بالموارد المحلية مثل بنوك الطعام والملاجئ. يستخدم الروبوت إطار محادثة موجه بالقواعد، مستفيدًا من نموذج لغة كبير (Claude 3.5 Sonnet) ويتبع سير عمل محدد لضمان تفاعلات منظمة. لتعزيز السلامة، قام المؤلفون بإجراء فريق أحمر لتحديد الثغرات من خلال متجهات هجوم متنوعة، بما في ذلك هجمات الالتزام بالوثائق (DA) والالتزام بالتعليمات (IA). قاموا بتجميع مجموعة من 160 سلوكًا ضارًا لتقييم مرونة الروبوت ضد هذه الثغرات، بهدف إنشاء إطار تقييم قابل للتكرار والتفسير لوكلاء المحادثة ذوي المخاطر العالية المماثلة.

يقوم المؤلفون بتصنيف الأخطاء إلى فئات IA وDA، حيث تتعلق IA بالامتثال للمحفزات النظامية والقواعد السلوكية، بينما تركز DA على الالتزام بالوثائق المسترجعة. يوضحون أنواع الهجمات المحددة، مثل المعلومات المفقودة، المعلومات الخاطئة، والافتراضات الكاذبة لـ DA، واستفسارات النصائح، وسيناريوهات قلق المستخدم، والتعبيرات السامة لـ IA. تشير النتائج إلى أن أخطاء IA كانت أكثر تكرارًا وشدة، خاصة استجابة لاستفسارات النصائح، حيث قدم الروبوت أحيانًا نصائح غير موثوقة. كما يبرز المؤلفون فعالية استراتيجيات التخفيف، مثل تعزيز المحفزات والوثائق، التي تهدف إلى تقليل أخطاء IA من خلال تأصيل الردود في معلومات موثوقة. بشكل عام، تؤكد الدراسة على أهمية الاختبار الدقيق وتدابير السلامة في تطوير الروبوتات المحادثة للسياقات الحساسة.

القيود

تقدم الدراسة عدة قيود قد تؤثر على قابلية تعميم وموثوقية نتائجها. أولاً، كان التقييم مقصورًا على بنية روبوت محادثة واحدة تستخدم نموذج لغة كبير واحد (LLM)، مما قد لا يمثل أداء نماذج أخرى. مجموعة بيانات الاختبار، التي تتكون من 140 مثالًا فرديًا و20 مثالًا متعدد الأدوار، صغيرة نسبيًا، مما قد يحد من قوة الاستنتاجات المستخلصة. بالإضافة إلى ذلك، بينما تم الإبلاغ عن موثوقية بين المقيمين لمجموعة فرعية من الأمثلة، تم إجراء غالبية التعليقات التوضيحية بواسطة مُعَلِّق بشري واحد، مما قد يغفل تعقيدات متجهات الهجوم المختلفة، خاصة في السيناريوهات متعددة الأدوار. تشير قيم ألفا لكريبندورف، التي تشير إلى اتفاق مؤقت (0.78 < α < 0.8) على الرغم من نسبة اتفاق عالية (95.4%)، إلى أن مجموعة بيانات أكبر ستعزز موثوقية تقديرات الاتفاق. علاوة على ذلك، قد لا تعكس اعتماد الدراسة على محادثات محاكاة مصممة من قبل الباحثين بدلاً من تفاعلات المستخدم الفعلية الطرق المتنوعة وغير المتوقعة التي قد تتفاعل بها الفئات الضعيفة مع الروبوت. لتحسين التقييمات المستقبلية، خاصة في المجالات ذات المخاطر العالية مثل الرعاية الصحية، هناك حاجة إلى مجموعة اختبار أكثر شمولاً وتنوعًا، بالإضافة إلى عملية تعليق منظمة تشمل عدة مُعَلِّقين وفحوصات للاتفاق. كما يتم التأكيد على أن فريق الأحمر الواسع لا يمكن أن يضمن السلامة في البيئات عالية المخاطر ولا ينبغي أن يُفهم على أنه ضمان نهائي للأمان.

Journal: Scientific Reports, Volume: 16, Issue: 1
DOI: https://doi.org/10.1038/s41598-026-45719-3
PMID: https://pubmed.ncbi.nlm.nih.gov/41917231
Publication Date: 2026-03-31
Author(s): Syed-Amad Hussain et al.
Primary Topic: AI in Service Interactions

Overview

The research paper outlines a red-teaming protocol aimed at enhancing the safety of health-related chatbots, emphasizing the need for assurance beyond mere factual correctness. This protocol is structured around three key pillars: error stratification, dual-pronged testing, and vulnerability-informed mitigation. The authors differentiate between Document Adherence (DA) and Instruction Adherence (IA), employing adversarial inputs to test the chatbot’s resilience in both single and multi-turn interactions. Their evaluation of a retrieval-augmented generation (RAG) based chatbot revealed that while the system exhibited no errors in DA (0/60), it faced a significant challenge with IA, recording a 15% error rate. Notably, multi-turn stress tests uncovered hidden vulnerabilities, leading to error rates of 50% for advice queries and 40% for user distress scenarios.

The findings indicate that behavioral noncompliance is the primary risk factor, with high-severity failures predominantly occurring during sustained interactions. The study’s mitigations, including prompt and document augmentation, effectively reduced total errors by 60% and eliminated high-severity errors by enforcing “safe failure” loops. The authors propose that this stratified analysis and targeted mitigation approach can serve as a foundational framework for securing clinical conversational agents, highlighting that the critical vulnerability lies not in factual inaccuracies but in the failure to follow behavioral instructions during prolonged adversarial dialogue.

Introduction

The introduction of this research paper discusses the increasing integration of conversational agents, or chatbots, in sensitive health-related contexts, including medication tracking, clinical care, and mental health support. These systems often utilize a Retrieval-Augmented Generation (RAG) architecture to enhance factual accuracy by grounding responses in vetted knowledge bases. However, despite these advancements, significant safety risks remain, particularly concerning adherence to behavioral instructions that govern the chatbot’s responses. The paper highlights the potential for chatbots to deviate from their guidelines, especially when users express distress or persistently seek specific answers, which can lead to the generation of unsafe, unverified advice.

To address these challenges, the authors propose a comprehensive evaluation framework that combines single-turn and multi-turn conversational stress tests to identify vulnerabilities in chatbot behavior. They introduce an error framework that distinguishes between Document Adherence (DA) and Instruction Adherence (IA) failures, emphasizing that these error types arise from different mechanisms and necessitate distinct mitigation strategies. The paper aims to establish a systematic red teaming protocol for health-related chatbots, integrating domain-specific attack vectors and multi-turn evaluations to uncover critical safety failures. Additionally, it presents a layered mitigation design that combines prompt and document augmentation to reduce high-severity errors, ultimately contributing to the development of safer and more reliable AI chatbots for sensitive applications.

Methods

In this section, the authors outline their methodological approach to mitigating identified IA errors through two primary strategies: prompt engineering and document augmentation. These strategies specifically target failure modes associated with the generation of unvetted advice from the model’s parametric memory and the leakage of internal system information. The effectiveness of these mitigation methods is evaluated against the attack vectors that previously demonstrated the highest error rates, namely advice_query, user_distress, and prompt_injection.

Additionally, the authors provide a Mitigation Adaptation Checklist in the Supplementary Materials (S6), which serves as a resource for mapping specific failure modes to corresponding design choices in prompt and document augmentation. This checklist aims to facilitate the systematic application of the proposed mitigation strategies in addressing the identified vulnerabilities.

Results

The results indicate that the chatbot demonstrated exceptional resilience against Direct Adversarial (DA) attacks, recording no errors (0/60) in this category. However, it exhibited low-severity Indirect Adversarial (IA) errors, occurring at a rate of 11.7% (7/60), where the model failed to mention relevant options that could assist users, thereby restricting their access to additional resources and limiting conversational flow.

In terms of mitigation strategies, the implementation of Prompt Mitigation was notably effective, leading to a 60% reduction in total errors across the advice_query, user_distress, and prompt_injection categories, decreasing from 15/60 to 6/60. The chatbot consistently refrained from providing unvetted advice when prompted. Remaining IA errors were minor, primarily concerning conversational tone and readability rather than unsafe content. Nonetheless, in user_distress scenarios, the model occasionally referenced the national suicide hotline, suggesting that this behavior is a persistent pattern that is not easily mitigated through prompt-level interventions alone.

Discussion

In this section, the authors discuss the implementation and evaluation of the HRSN chatbot, designed to assist vulnerable populations by connecting users to local resources such as food pantries and shelters. The chatbot employs a rule-guided conversational framework, utilizing a large language model (Claude 3.5 Sonnet) and follows a finite-state workflow to ensure structured interactions. To enhance safety, the authors conducted red teaming to identify vulnerabilities through various attack vectors, including Document Adherence (DA) and Instruction Adherence (IA) attacks. They curated a set of 160 harmful behaviors to evaluate the chatbot’s resilience against these vulnerabilities, aiming for a replicable and interpretable evaluation framework for similar high-risk conversational agents.

The authors stratify errors into IA and DA categories, where IA pertains to adherence to system prompts and behavioral rules, while DA focuses on fidelity to retrieved documents. They detail specific attack types, such as missing information, wrong information, and false premises for DA, and advice queries, user distress scenarios, and toxic utterances for IA. The findings indicate that IA errors were more frequent and severe, particularly in response to advice queries, where the chatbot occasionally provided unvetted advice. The authors also highlight the effectiveness of mitigation strategies, such as prompt and document augmentation, which aim to reduce IA errors by grounding responses in vetted information. Overall, the study underscores the importance of rigorous testing and safety measures in developing chatbots for sensitive contexts.

Limitations

The study presents several limitations that may affect the generalizability and reliability of its findings. Firstly, the evaluation was restricted to a single chatbot architecture utilizing one large language model (LLM), which may not represent the performance of other models. The test dataset, comprising only 140 single-turn and 20 multi-turn examples, is relatively small, potentially limiting the robustness of the conclusions drawn. Additionally, while interrater reliability was reported for a subset of examples, the majority of annotations were performed by a single human annotator, which may overlook the complexities of various attack vectors, particularly in multi-turn scenarios. The Krippendorff’s alpha values, indicating tentative agreement (0.78 < α < 0.8) despite a high percentage agreement (95.4%), suggest that a larger dataset would enhance the reliability of the agreement estimates. Moreover, the study's reliance on simulated conversations designed by researchers rather than actual user interactions may not adequately reflect the diverse and unpredictable ways in which vulnerable populations might engage with the chatbot. To improve future evaluations, particularly in high-stakes domains such as healthcare, a more extensive and varied test suite is necessary, along with a structured annotation process involving multiple annotators and agreement checks. It is also emphasized that extensive red teaming cannot guarantee safety in high-risk environments and should not be misconstrued as a definitive assurance of security.