DOI: https://doi.org/10.1007/s10664-026-10827-1
تاريخ النشر: 2026-03-02
المؤلف: Romina Etezadi وآخرون
الموضوع الرئيسي: أبحاث هندسة البرمجيات
نظرة عامة
تستكشف هذه الورقة البحثية الحلول الآلية لتتبع المتطلبات القانونية (LRT) في تطوير البرمجيات، مع التركيز على الامتثال للمعايير الأخلاقية والسلامة العامة. تقيم الدراسة نهجين: كاشف، وهو مصنف يستخدم محولات الجمل للتشابه الدلالي، وRice LRT، الذي يستخدم نموذج لغة كبير مولد (LLM) يعتمد على إطار هندسة المطالبات الهيكلية. تظهر النتائج التجريبية أن كاشف يحقق درجة F2 تبلغ حوالي 63% على مجموعة بيانات مرجعية، متفوقًا على سبعة مصنفات أساسية بفارق كبير يبلغ 21 نقطة مئوية. ومع ذلك، فإن أدائه يتراجع على مجموعات البيانات الأكثر تعقيدًا، مثل تلك المتعلقة باللائحة العامة لحماية البيانات الأوروبية (GDPR)، حيث يحقق فقط 15% من الاسترجاع.
في المقابل، يتفوق Rice LRT في سياق GDPR، حيث يحقق درجة F2 تبلغ 61% ومتوسط استرجاع يبلغ 84%، مما يمثل تحسينًا قدره 34 نقطة مئوية مقارنة بأفضل مطالبة أساسية. تشير النتائج إلى أن التقنيات التقليدية غير كافية لمعالجة تحديات تتبع المتطلبات القانونية، مما يبرز الحاجة إلى حلول مخصصة تأخذ في الاعتبار الفروق الدقيقة المحددة للسياقات القانونية والتنظيمية. كما تحدد الدراسة تحديات مثل الفجوات في المصطلحات بين المتطلبات والأحكام القانونية، مما يشير إلى الحاجة لمزيد من الاستكشاف. ستتضمن الأعمال المستقبلية دراسة بمشاركة الإنسان مع خبراء المجال وجهودًا لتعزيز أداء LLM من خلال دمج المعرفة الخاصة بالمجال لسد هذه الفجوات.
مقدمة
تسلط مقدمة هذه الورقة البحثية الضوء على التأثير التحويلي للتقدم التكنولوجي، وخاصة الذكاء الاصطناعي (AI)، على تطوير البرمجيات عبر مختلف القطاعات، بما في ذلك الرعاية الصحية. مع تزايد تعقيد أنظمة البرمجيات، ظهرت أطر تنظيمية مثل اللائحة العامة لحماية البيانات (GDPR) لضمان الامتثال للمعايير الأخلاقية والقانونية. تعتبر هندسة المتطلبات (RE) ضرورية في هذا السياق، حيث تركز على تحديد وصيانة متطلبات البرمجيات التي تتماشى مع الالتزامات القانونية. تؤكد الورقة على أهمية تتبع المتطلبات القانونية (LRT)، والذي يتضمن تتبع متطلبات البرمجيات إلى أحكام قانونية محددة، خاصة خلال مراحل استنباط المتطلبات وما بعد النشر.
يستعرض المؤلفون تحديات LRT باستخدام مثال تطبيق التنقل، WeMobilize، الذي يجب أن يمتثل لـ GDPR أثناء توسيعه في الاتحاد الأوروبي. يحددون قضايا مثل التباينات اللغوية بين النصوص القانونية ومتطلبات البرمجيات، فضلاً عن ندرة البيانات المعلّمة لتدريب النماذج. تعاني الأساليب الحالية للتتبع من قيود، حيث تعتمد بشكل أساسي على التداخل اللفظي وتفشل في التقاط العلاقات الدلالية الأعمق. لمعالجة هذه التحديات، تقترح الورقة نهجين آليين جديدين يستفيدان من التقدم الأخير في معالجة اللغة الطبيعية (NLP) ونماذج اللغة الكبيرة (LLMs). النهج الأول، كاشف، يستخدم محولات الجمل للتنبؤ بروابط التتبع بناءً على التشابه الدلالي، بينما الثاني، Rice LRT، يستخدم استراتيجية تحفيز مع LLMs لتعزيز الدقة في تحديد روابط التتبع. تهدف الورقة إلى إثبات فعالية هذه الأساليب في تحسين الامتثال للمتطلبات القانونية في تطوير البرمجيات.
نقاش
في قسم النقاش من الورقة، يحدد المؤلفون هيكل عملهم ويفصلون في نهجهم المقترح لربط متطلبات البرمجيات بالأحكام التنظيمية. يقدمون منهجيتين رئيسيتين: كاشف وRice LRT. يستخدم كاشف مجموعة تدريب من الأمثلة المعلّمة لضبط محولات الجمل (ST) لتصنيف روابط التتبع المرشحة بين المتطلبات \( R = \{r_1, r_2, \ldots, r_n\} \) والأحكام \( C = \{c_1, c_2, \ldots, c_m\} \). تتضمن العملية عدة خطوات، بما في ذلك اختيار النموذج، والمعالجة المسبقة، وحساب التشابه باستخدام التشابه الكوني، الذي ينتج مصفوفة تشابه للتنبؤ بروابط التتبع بناءً على عتبة محددة \( \theta \). يقترح المؤلفون استراتيجيات متعددة لتحديد \( \theta \)، بما في ذلك الثابتة، والديناميكية، والحد الأقصى للاختلاف، والعتبات المضبوطة، كل منها ينتج أنواعًا مختلفة من نموذج كاشف.
من ناحية أخرى، يستفيد Rice LRT من نهج قائم على التحفيز باستخدام نموذج لغة كبير (LLM) للتنبؤ بروابط التتبع. يتم تصميم التحفيز وفقًا لإطار Rice، مع التركيز على السياق، والتعليمات، والأمثلة لتوجيه LLM في تحديد الأحكام ذات الصلة للمتطلبات المعطاة. يؤكد المؤلفون على أهمية تحسين التحفيز لتعزيز قدرات التفكير للنموذج وضمان أن تكون المخرجات منطقية وذات صلة. يتم تأطير التقييم التجريبي لكلا النهجين حول عدة أسئلة بحثية، تركز على دقة النموذج، والمقارنة مع الأسس الحالية، والأداء عبر مجموعات بيانات متنوعة، بما في ذلك مجموعة بيانات HIPAA والمستندات الجديدة التي تعكس متطلبات GDPR. تهدف النتائج إلى المساهمة في مجال هندسة المتطلبات من خلال توفير أدوات فعالة لتتبع الامتثال التنظيمي.
DOI: https://doi.org/10.1007/s10664-026-10827-1
Publication Date: 2026-03-02
Author(s): Romina Etezadi et al.
Primary Topic: Software Engineering Research
Overview
This research paper investigates automated solutions for Legal Requirements Traceability (LRT) in software development, focusing on compliance with ethical standards and public safety. The study evaluates two approaches: Kashif, a classifier utilizing sentence transformers for semantic similarity, and Rice LRT, which employs a generative large language model (LLM) based on a structured prompt engineering framework. Empirical results demonstrate that Kashif achieves an F2 score of approximately 63% on a benchmark dataset, outperforming seven baseline classifiers by a significant margin of 21 percentage points. However, its performance declines on more complex datasets, such as those related to the European General Data Protection Regulation (GDPR), where it yields only 15% recall.
In contrast, Rice LRT excels in the GDPR context, achieving an F2 score of 61% and an average recall of 84%, marking a 34 percentage point improvement over the best baseline prompt. The findings suggest that traditional techniques are inadequate for addressing legal traceability challenges, emphasizing the need for tailored solutions that account for the specific nuances of legal and regulatory contexts. The study also identifies challenges such as terminology gaps between requirements and legal provisions, indicating a need for further exploration. Future work will involve a human-in-the-loop study with domain experts and efforts to enhance LLM performance by integrating domain-specific knowledge to bridge these gaps.
Introduction
The introduction of this research paper highlights the transformative impact of technological advancements, particularly artificial intelligence (AI), on software development across various sectors, including healthcare. As software systems grow increasingly complex, regulatory frameworks such as the General Data Protection Regulation (GDPR) have emerged to ensure compliance with ethical and legal standards. Requirements Engineering (RE) is crucial in this context, focusing on specifying and maintaining software requirements that align with legal obligations. The paper emphasizes the importance of legal requirements traceability (LRT), which involves tracing software requirements to specific legal provisions, particularly during the requirements elicitation and post-deployment phases.
The authors illustrate the challenges of LRT using the example of a mobility app, WeMobilize, which must comply with GDPR as it expands into the EU. They identify issues such as language discrepancies between legal texts and software requirements, as well as the scarcity of annotated data for training models. Existing traceability approaches have limitations, primarily relying on lexical overlap and failing to capture deeper semantic relationships. To address these challenges, the paper proposes two novel automated approaches leveraging recent advancements in natural language processing (NLP) and large language models (LLMs). The first approach, Kashif, utilizes sentence transformers to predict trace links based on semantic similarity, while the second, Rice LRT, employs a prompting strategy with LLMs to enhance accuracy in identifying trace links. The paper aims to demonstrate the effectiveness of these approaches in improving compliance with legal requirements in software development.
Discussion
In the discussion section of the paper, the authors outline the structure of their work and detail their proposed approaches for linking software requirements to regulatory provisions. They introduce two primary methodologies: Kashif and Rice LRT. Kashif employs a training set of labeled examples to fine-tune Sentence Transformers (ST) for classifying candidate trace links between requirements \( R = \{r_1, r_2, \ldots, r_n\} \) and provisions \( C = \{c_1, c_2, \ldots, c_m\} \). The process involves several steps, including model selection, preprocessing, and similarity computation using cosine similarity, which generates a similarity matrix to predict trace links based on a defined threshold \( \theta \). The authors propose multiple strategies for determining \( \theta \), including constant, dynamic, maximum delta cutoff, and tuned thresholds, each yielding different variants of the Kashif model.
Rice LRT, on the other hand, leverages a prompt-based approach using a large language model (LLM) to predict trace links. The prompt is designed following the Rice framework, emphasizing context, instructions, and examples to guide the LLM in identifying relevant provisions for given requirements. The authors emphasize the importance of refining the prompt to enhance the model’s reasoning capabilities and ensure the output is logical and relevant. The empirical evaluation of both approaches is framed around several research questions, focusing on model accuracy, comparison with existing baselines, and performance across diverse datasets, including the HIPAA dataset and newly curated documents reflecting GDPR requirements. The findings aim to contribute to the field of requirements engineering by providing effective tools for regulatory compliance traceability.
