Skip to content
Open access

Bridging context gaps in low-resource language chatbots through multilevel attention and hybrid embedding approaches

Aug 2026 · Journal of the Nigerian Society of Physical Sciences · pp. 3097 · 0 citations · 39 references

TL;DR

A multilevel-attention and hybrid-embedding framework that integrates FastText subword representations with multilingual BERT with potential applicability to other African languages is proposed to improve semantic understanding and context retention in conversational agents for Igbo.

Abstract

Conversational agents for low-resource languages (LRLs), such as Igbo, face major challenges, including limited annotated data, code-switching, and weak contextual coherence in multi-turn dialogue. This study proposes a multilevel-attention and hybrid-embedding framework that integrates FastText subword representations with multilingual BERT (mBERT) to improve semantic understanding and context retention. The architecture applies hierarchical attention at the word, utterance, and dialogue levels, enabling effective modeling of conversational dependencies and reducing context drift. The model was evaluated on a curated Igbo--English conversational dataset and benchmarked against long short-term memory (LSTM), Transformer, FastText, mBERT, and XLM-R baselines. For response generation, the proposed framework achieved a bilingual evaluation understudy (BLEU) score of 44.1%, a longest-common-subsequence recall-oriented understudy for gisting evaluation (ROUGE-L) score of 60.3%, and a context-retention accuracy (CRA) of 81.5%. For intent classification, it attained an F1-score of 87.3% and an area under the receiver operating characteristic curve (ROC-AUC) of 0.91; for context-dependency detection, it achieved an F1-score of 84.3%. The framework also reduced inference latency and was robust to code-switching and noisy conversational input. Human evaluation confirmed improvements in response clarity, cultural relevance, and multi-turn coherence. The findings show that hybrid embeddings combined with multilevel attention provide an effective and scalable approach to conversational AI for LRLs, with potential applicability to other African languages.

Read PDF

Similar papers

Book Open access Aug 2026

KGA-LM: Representation-Level Grounding for Conversational Search over Knowledge Graphs

Integrating structured knowledge graphs (KGs) with Large Language Models (LLMs) is essential for trustworthy, knowledge intensive conversational systems. However, existing Retrieval Augmented Generation (RAG) methods typically rely on a retrieval-as-context paradigm that linearizes structured subgraphs into unstructured prompt tokens. This approach not only flattens rich structural dependencies but also leads to context inflation and evidence attenuation in multi-turn dialogues. To address these limitations, we propose KGA-LM, a framework that integrates external knowledge via representation-level grounding. Rather than treating retrieved evidence as transient input artifacts, KGA-LM encodes compact multi-hop subgraphs using a Graph Transformer and fuses them into the LLM decoder through a compatibility-aware latent interface. This design aligns the heterogeneous latent spaces of the graph encoder and the LLM, while a dual-gated fusion mechanism dynamically regulates the influence of non-parametric graph evidence across turns. Experiments on multiple conversational benchmarks demonstrate that KGA-LM significantly improves factual accuracy and reduces hallucination compared to prompt-linearized baselines. Crucially, by decoupling knowledge injection from prompt length, our approach mitigates retrieval signal decay under long contexts, offering a superior trade-off between grounding quality and inference efficiency.

Yunfei Li, Chengfei Liu, Rui Zhou et al. · 0 citations
Conference Jul 2026

An On-Premise Multilingual Academic Chatbot using Retrieval-Augmented Generation and Context-Aware Memory for University Assistance

Universities now use Large Language Models (LLMs) to transform their processes for managing student information. The paper introduces an upgraded chatbot system for Narasaraopeta Engineering College (NEC) which extends previous on-premise LLM chatbot research by providing four new functions. The system uses (1) Retrieval-Augmented Generation (RAG) to create citation-based responses through LlamaIndex and ChromaDB, (2) Context Memory which maintains conversation flow during multiple dialogue exchanges, (3) Voice Input through OpenAI Whisper Speech-to-Text (STT) technology, and (4) Multilingual Support which covers English and these seven languages: Hindi, Telugu, Tamil, Kannada, and Malayalam through IndicNLP. The system tested 60 benchmark questions across four academic categories which included regulations and examination policies and fee structures and multilingual queries and achieved 96.7% overall accuracy with sub-second text response times and 1.0–1.4 second voice response times. The system operates entirely on-premise through Docker which safeguards institutional data privacy while eliminating the need for recurring cloud API expenses. The upcoming development will create Emotion-Aware AI, FAQ Auto-Learning, Student Portal Integration, and a Mobile Application.

M. Yaswanth, Kopparapu Sai Amar Durgesh, Mogili Harsha Vardhan et al. · 0 citations
Open access 2026

Semantic Structure and Importance Extraction from Sequential Conversational Data via Dimensional Reduction

This study proposes a robust and semantically enriched framework for conversation understanding based on a composite distributed representation that incorporates both temporal adjacency and semantic proximity between utterances, enabling the visualization of key conversational connections.

Takeshi Matsuda, Michio Sonoda · 0 citations
Open access Aug 2026

Context-Aware Large Language Model for Customer Support Chatbots

Despite their high conversational fluency, large language models (LLMs) tend to produce responses that are either contrived or factually inaccurate, a phenomenon known as hallucination. This constrains their dependability in areas where accuracy is crucial, like customer service. This study leverages a context-aware chatbot built on a Retrieval-Augmented Generation (RAG) pipeline to solve the problem. The system retrieves semantically relevant text from an external knowledge base by integrating neural information retrieval with LLMs to ensure factual correctness and enhanced contextual relevance. These externally retrieved documents are given as a reference during response generation. The LLM-as-a-judge approach is used to evaluate the system by comparing responses to a qualitative performance matrix using GPT-4o. Results show that the RAG-based chatbot increases context precision by a factor of 7.5, decreases hallucinations (measured through Faithfulness) by 73.20% and improves answer relevance by 6.97% when compared to a random retrieval baseline system. This study advances conversational AI by demonstrating how the retrieval method significantly enhances the usefulness and reliability of LLMs for enterprise-level customer service. The results show that the RAG architecture provides a scalable alternative for creating precise, contextually grounded conversational agents, thereby mitigating some of the main drawbacks of LLMs.

Rabia Shabbir, K. Talpur, Shakeel Ahmad · 0 citations
Open access Aug 2026

LEXF-ATT-XLM: A hybrid lexicon-enhanced attention model for hate speech detection in low-resource language Roman Urdu

Hate speech detection in low-resource and informally written languages remains a significant challenge due to the lack of annotated corpora, orthographic variability, and complex code-mixing. Roman Urdu a non-standardized variant of Urdu written in the Latin script exemplifies these linguistic hurdles. In this paper, we propose LEXF-ATT-XLM, a novel hybrid deep learning architecture that synergizes contextual language modeling with explicit domain knowledge. Our model leverages XLM-RoBERTa for deep contextual embeddings, passed through a two-layer Bidirectional Gated Recurrent Unit (BiGRU) and a multi-head attention mechanism to capture both sequential and salient linguistic patterns. Crucially, the pooled representations are fused via a learnable gating layer (Linear + tanh) before final classification. Furthermore, we integrate a domain specific Roman Urdu hate lexicon as an auxiliary regression supervision signal within a multi task learning framework to guide the model’s focus. Evaluated on the RU-HSD-30K dataset using 3-fold stratified cross-validation, the proposed model achieves an average accuracy of 88.83% and a weighted F1 score of 88.83%, with fold wise weighted F1-scores of 88.58%, 89.19%, and 88.71%. Extensive ablation studies confirm that the lexicon-guided auxiliary supervision significantly enhances the model’s ability to handle lexical variations, negations, and informal spelling. These findings demonstrate the robust effectiveness of our approach in addressing the unique linguistic challenges of Roman Urdu hate speech detection.

Jaweria Jalil Awan, Muhammad Hamid, T. Alshalali · 0 citations
Open access Aug 2026

Leveraging Large Language Models to Detect and Revise Unsafe Responses in Context-Sensitive Dialogues

Large Language Models (LLMs) excel at tasks like classification, summarisation, question answering among others, with performance comparable to humans. Despite these capabilities, leveraging LLMs to transform unsafe responses in context-sensitive dialogues is underexplored. In this work, we propose a pipeline that leverage LLMs as safety detector, editor and evaluator to mitigate undesired behaviour in human-computer dialogues. At the first iteration, our experimental results on two evaluation datasets show reduction in the unsafe dialogues from 47% to 13% and 48% to 2% respectively, with 82% and 92% agreement between the safety detector and evaluator after revision. Human evaluation of randomly sampled dialogues demonstrates reduction in unsafe responses after revision. Additionally, the revision LLM (editor) exhibits a higher proportion of refusals without compromising fluency and coherence of the revised dialogues.

T. Ajayi, M. Arcan, P. Buitelaar · 0 citations