Implementation of the mawaris fiqh hybrid chatbot based on retrieval-augmented generation and rule-based expert system - Irpan Afrizal Putra Eriani; Nazruddin Safaat Harahap; Suwanto Sanjaya; Muhammad Irsyad (Lembaga Studi Pendidikan dan Rekayasa Alam Riau, 2026)
Islamic inheritance law (mawaris fiqh) regulates the distribution of inheritance based on the Quran, Sunnah, and ijma’. However, many people still have difficulty in understanding the concept of inheritance and performing accurate inheritance calculations due to the complexity of faraidh rules and limited sources of information about faraidh. This study aims to develop a hybrid-based mawaris chatbot that integrates retrieval-augmented generation (RAG) and rule-based expert system to support both conceptual question answering and deterministic inheritance calculations. This system is implemented using the Voyage-3-Large embedding model, Qdrant vector database, semantic caching, large language models (LLM) for contextual response generation using models from GPT-4o (main) and llama3.2:3b (fallback mode) as well as semantic cache using paraphrase-multilingual-MiniLM-L12-v2. The