My First Hackathon… Nightmare!
I’d always heard about hackathons — the kind where you lock yourself in a room for 24 hours, survive on energy drinks, and ship an MVP before sunrise. So when I saw the AI Fiqh Hackathon by Bank Rakyat Malaysia x AI FIQH, I thought it was the perfect chance to finally experience one. I gathered my team, invited two colleagues from AEM — Rauf Hazim and Raja Hazwan — and registered us under the name BismillahMergePR.
None of us had deep experience in Islamic finance. But we were curious about how technology could strengthen trust and transparency in this domain. We figured we’d learn along the way. And honestly, we did — way more than we expected.
The Format (Not What I Expected)#
Here’s the thing — this wasn’t the typical 24-hour hackathon I’d been picturing. There was no grand hall, no sleeping bags under desks, no energy-drink-fuelled all-nighters in a venue. Instead, we built everything from home over three days and submitted our GitHub repos by the deadline. Two deliverables: an AI chatbot that uses their provided Shariah resources, and a second solution of our choice. Two full products. In three days. From home.
A couple of days after submission, the organiser emailed us with feedback — what we could improve, what they didn’t like. Which was… interesting. It felt less like a hackathon and more like free consultation work. Especially when the rules stated that all submitted projects would belong to the organiser. Yeah, you read that right.
Now, I don’t want to make accusations. But top 10 teams were guaranteed a prize (RM500), and when you think about the sheer volume of AI solutions 21 teams just handed over versus what they paid out in prizes — the math feels a little off. I could be wrong, maybe there’s a good reason for it. But the format left a weird taste. I’m not a fan of hackathons structured this way.
Anyway, the presentation slot was 10 minutes. Ten minutes to present two pitch decks and demo both projects. I’ll get to how that went later.
Building Agent Deen#
The first deliverable was the AI chatbot. We named it Agent Deen — an AI-powered assistant focused on answering questions about Islamic finance and Shariah compliance, with support for Arabic, English, and Bahasa Melayu.
We quickly realised that in Islamic finance, accuracy alone isn’t enough. Trust and verifiable sources matter deeply. You can’t just have a chatbot spit out an answer — people need to know where that answer came from, down to the exact page and paragraph. That pushed us to build a full RAG (Retrieval-Augmented Generation) pipeline from scratch.

Here’s what that involved:
- Language detection and translation — queries come in Arabic, English, or Malay, so we built auto-detection and translation to improve search precision
- PDF ingestion with OCR fallback — official Shariah documents come in all sorts of PDF quality, so we used PyMuPDF with a Tesseract OCR cascade for scanned pages
- Embeddings and vector indexing — text chunked at sentence level, embedded with Ollama’s nomic-embed-text, and stored in Pinecone
- Reranking — CrossEncoder models to re-score retrieved results for better relevance
- Grounded LLM generation — users choose between Ollama (local, free) or Claude Haiku (cloud), with responses grounded in retrieved context
- Page-level citations — exact quotes, page previews, and highlighted text passages so users can verify every answer
- Anti-hallucination guardrails — if the model can’t find a source, it says so instead of making something up
- Automated scraping pipelines — background jobs via APScheduler to keep official documents from BNM, AAOIFI, SC Malaysia, and JAKIM updated
Building this reshaped how we think about responsible AI. It’s one thing to get a model to answer questions. It’s another thing entirely to make sure every answer is traceable back to an authoritative source.
Tech: FastAPI, Streamlit, Pinecone, Supabase, Ollama/Claude, CrossEncoder, PyMuPDF
Building BarakahVault#
For the second deliverable — the one we got to choose — we built BarakahVault, an ethical Islamic investment platform powered by AI and blockchain.
The core idea was simple: most halal investment screening just checks if a company is halal or haram. Binary. But that felt too shallow. We wanted to evaluate whether companies actively promote Islamic values, not just avoid violating them. So we introduced Maqasid al-Shariah scoring — evaluating companies across five pillars:

- Faith (Deen) — privacy and religious freedom protections
- Life (Nafs) — worker safety and environmental stewardship
- Intellect (Aql) — innovation and research investment
- Lineage (Nasl) — family-friendly workplace policies
- Wealth (Mal) — fair compensation and economic stability
Beyond that, we built a zakat calculator that handles cryptocurrency — which is trickier than it sounds because scholars have different methodologies for calculating zakat on crypto. We included three scholar-backed approaches so users can choose based on their understanding.
The crowdfunding side used Solidity smart contracts for milestone-based fund releases. Every donation is blockchain-tracked, and projects need verification from a three-scholar Shariah Board before going live. Transparency was the whole point.
Tech: Next.js, Node.js, MongoDB, Solidity, Hardhat, OpenAI API, Web3.js
The Presentation Mess#
So here’s the part I’m still a bit salty about.
Ten minutes. That’s what every team got to present two pitch decks and demo two full projects. Ten minutes for everything we built in three days.
We underestimated the presentation. I’ll be honest — we spent most of our energy on building and not enough on preparing how to present it. We walked in thinking the work would speak for itself, but when you’ve got 10 minutes and two products to demo, every second counts. We rushed through slides, stumbled over transitions, and didn’t get to show half the features we built.
Looking back, the time limit was absurd. But the real lesson was that we should’ve prepared for it regardless. A great product with a bad presentation is still a missed opportunity.
5th Place (Wait, What?)#
After the presentation, we honestly thought we’d blown it. We walked out feeling like we’d left so much on the table. So when they announced the results and called our name for 5th place out of 21 teams — we were genuinely shook.
Like, properly shook. We looked at each other like “did they just say our team name?” It wasn’t the podium, but for a first hackathon with zero Islamic finance background, building two full products in three days, and messing up the presentation? We’ll take it.

It also made us think — if we’d nailed the presentation, where would we have placed?
What I Took Away#
I walked into this hackathon unfamiliar with most Islamic finance concepts. I walked out with a much deeper appreciation for the discipline — and hands-on experience building RAG systems, scraping workflows, and Solidity smart contracts under real pressure.
It was also my first time leading a team in this kind of setting. Figuring out how to split work, make architectural decisions on the fly, and keep momentum going for three days straight — that was its own kind of learning.
Would I do another hackathon? Absolutely. But next time, we’re rehearsing the presentation.
Shoutout to Rauf Hazim and Raja Hazwan. Couldn’t have done it without the teamwork, the late-night grinds, and the last-minute PRs. We walked in as BismillahMergePR. We walked out as #SadaqallahMergePR.

Check out the repos: