Commenced in January 2007
Frequency: Monthly
Edition: International
Paper Count: 2

Search results for: LLAMA2

2 Hallucination Detection and Mitigation in Chatbot: A Multi-Agent Approach with LLAMA2

Authors: Md. Ashfaqur Rahman

Abstract:

Hallucination in Large Language Models (LLMs) poses a significant challenge in chatbot reliability, especially in critical domains such as healthcare, finance, and education. This paper presents a multi-agent approach to hallucination detection and mitigation using LLAMA2, integrating retrieval-based verification, fact-checking mechanisms, and response correction strategies. Our proposed framework consists of specialized agents, including a Web Retrieval Agent that fetches factual information from external sources (e.g., Wikipedia, DuckDuckGo & Google Serper), Fact-Checking Agents that evaluate response accuracy using semantic similarity scoring, a Correction Agent that refines outputs when hallucinations are detected, and a Monitoring Agent that logs hallucination scores and calculates truthfulness metrics. Experimental results demonstrate that incorporating retrieval-augmented generation (RAG) and multi-agent verification significantly reduces hallucination rates. The study highlights the effectiveness of using LLAMA2 alongside external knowledge sources and multi-agent collaboration to improve chatbot reliability and factual accuracy. Future research will explore reinforcement learning for dynamic agent optimization and enhancing real-time fact verification methods.

Keywords: hallucination detection, LLAMA2, multi-agent systems, retrieval-augmented generation, fact-checking, chatbot reliability, truth scoring, large language models, response correction, semantic similarity

Procedia PDF Downloads 161
1 Optimizing Question Answering Efficiency: A LoRA-Based Approach to Fine-Tuning LLAMA2

Authors: Md. Ashfaqur Rahman

Abstract:

Fine-tuning large language models (LLMs) for question-answering (QA) tasks often incurs high computational costs, demanding significant memory and leading to increased inference latency. In this study, we investigate the effectiveness of Low-Rank Adaptation (LoRA) in optimizing the LLAMA2 7B model by reducing trainable parameters, minimizing memory consumption, and enhancing processing efficiency. Experimental results reveal that LoRA reduces memory usage from 8.49GB to 4.52GB and lowers trainable parameters from 6.73 billion to 4.19 million. Additionally, we analyze inference latency across different input configurations, where single-question, two-question, three-question, and four-question inputs are evaluated separately. The fine-tuned model consistently outperforms the base model, achieving latency reductions of 6.23s, 11.66s, 23.97s, and 43.11s, respectively. These results indicate that LoRA enhances efficiency without compromising model performance. To assess overall effectiveness, we employ multiple evaluation metrics, including memory usage, parameter pruning, inference latency, and human evaluation, ensuring a balanced trade-off between computational efficiency and accuracy. The dataset, sourced from the Hugging Face Library, is partitioned into 9.85k training samples and 518 testing samples. Our findings establish LoRA-based fine-tuning as a robust method for improving LLM performance in QA applications while reducing computational overhead, making large-scale QA systems more practical and resource-efficient.

Keywords: large language models (llms), fine-tuning, low-rank adaptation (lora), llama2, question answering (qa), inference latency, memory optimization, parameter pruning, computational efficiency, hugging face dataset.

Procedia PDF Downloads 110