Few-Shot Prompting for Extractive Quranic QA with Instruction-Tuned LLMs

Mohamed Basem, Islam Oshallah, Ali Hamdi, Ammar Mohammed
8/8/2025
cs.CLcs.IR

No confident code implementation found for this paper.

Abstract

This paper presents two effective approaches for Extractive Question Answering (QA) on the Quran. It addresses challenges related to complex language, unique terminology, and deep meaning in the text. The second uses few-shot prompting with instruction-tuned large language models such as Gemini and DeepSeek. A specialized Arabic prompt framework is developed for span extraction. A strong post-processing system integrates subword alignment, overlap suppression, and semantic filtering. This improves precision and reduces hallucinations. Evaluations show that large language models with Arabic instructions outperform traditional fine-tuned models. The best configuration achieves a pAP10 score of 0.637. The results confirm that prompt-based instruction tuning is effective for low-resource, semantically rich QA tasks.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Cite this paper

@article{basem2025fewshot,
  title  = {Few-Shot Prompting for Extractive Quranic QA with Instruction-Tuned LLMs},
  author = {Mohamed Basem and Islam Oshallah and Ali Hamdi and Ammar Mohammed},
  year   = {2025},
  eprint = {2508.06103},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2508.06103v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2508.06103.svg)](https://codeofpaper.com/paper/2508.06103)

Discussion