Table of Contents
Fetching ...

Implementing a Sharia Chatbot as a Consultation Medium for Questions About Islam

Wisnu Uriawan, Aria Octavian Hamza, Ade Ripaldi Nuralim, Adi Purnama, Ahmad Juaeni Yunus, Anissya Auliani Supriadi Putri

TL;DR

This paper presents a Sharia-compliant chatbot that answers Islamic questions using a reinforcement learning framework (Q-Learning) coupled with sentence-transformer embeddings, trained on a curated Islam QA dataset of 25,000 QA pairs. It follows a CRISP-DM workflow, with a Flask API and a Flutter frontend to deliver real-time, semantically guided responses across fiqh, aqidah, ibadah, and muamalah. The system achieves 87% semantic accuracy in functional testing and is positioned as a bridge between traditional Islamic scholarship and AI-driven digital da’wah, though it remains limited by static learning and dataset dependence. Future work includes continuous learning, multi-turn dialogue support, and broader topic coverage to enhance adaptability and reliability in Islamic digital consultation.

Abstract

This research presents the implementation of a Sharia-compliant chatbot as an interactive medium for consulting Islamic questions, leveraging Reinforcement Learning (Q-Learning) integrated with Sentence-Transformers for semantic embedding to ensure contextual and accurate responses. Utilizing the CRISP-DM methodology, the system processes a curated Islam QA dataset of 25,000 question-answer pairs from authentic sources like the Qur'an, Hadith, and scholarly fatwas, formatted in JSON for flexibility and scalability. The chatbot prototype, developed with a Flask API backend and Flutter-based mobile frontend, achieves 87% semantic accuracy in functional testing across diverse topics including fiqh, aqidah, ibadah, and muamalah, demonstrating its potential to enhance religious literacy, digital da'wah, and access to verified Islamic knowledge in the Industry 4.0 era. While effective for closed-domain queries, limitations such as static learning and dataset dependency highlight opportunities for future enhancements like continuous adaptation and multi-turn conversation support, positioning this innovation as a bridge between traditional Islamic scholarship and modern AI-driven consultation.

Implementing a Sharia Chatbot as a Consultation Medium for Questions About Islam

TL;DR

This paper presents a Sharia-compliant chatbot that answers Islamic questions using a reinforcement learning framework (Q-Learning) coupled with sentence-transformer embeddings, trained on a curated Islam QA dataset of 25,000 QA pairs. It follows a CRISP-DM workflow, with a Flask API and a Flutter frontend to deliver real-time, semantically guided responses across fiqh, aqidah, ibadah, and muamalah. The system achieves 87% semantic accuracy in functional testing and is positioned as a bridge between traditional Islamic scholarship and AI-driven digital da’wah, though it remains limited by static learning and dataset dependence. Future work includes continuous learning, multi-turn dialogue support, and broader topic coverage to enhance adaptability and reliability in Islamic digital consultation.

Abstract

This research presents the implementation of a Sharia-compliant chatbot as an interactive medium for consulting Islamic questions, leveraging Reinforcement Learning (Q-Learning) integrated with Sentence-Transformers for semantic embedding to ensure contextual and accurate responses. Utilizing the CRISP-DM methodology, the system processes a curated Islam QA dataset of 25,000 question-answer pairs from authentic sources like the Qur'an, Hadith, and scholarly fatwas, formatted in JSON for flexibility and scalability. The chatbot prototype, developed with a Flask API backend and Flutter-based mobile frontend, achieves 87% semantic accuracy in functional testing across diverse topics including fiqh, aqidah, ibadah, and muamalah, demonstrating its potential to enhance religious literacy, digital da'wah, and access to verified Islamic knowledge in the Industry 4.0 era. While effective for closed-domain queries, limitations such as static learning and dataset dependency highlight opportunities for future enhancements like continuous adaptation and multi-turn conversation support, positioning this innovation as a bridge between traditional Islamic scholarship and modern AI-driven consultation.

Paper Structure

This paper contains 15 sections, 1 equation, 6 figures.

Figures (6)

  • Figure 1: Popular survey methods
  • Figure 2: CRISP-DM Methodology
  • Figure 3: Comparison of the Q-Learning–based chatbot workflow (a) and the API communication workflow using Flask (b) presented in a single column.
  • Figure 4: API Communication Flow
  • Figure 5: Mobile Application Prompt
  • ...and 1 more figures