Back to Projects
React NativeExpoSupabasepgvectorGemini AITauri v2
Aion
Aion is an AI-powered Bible companion that lets users ask questions about scripture in plain language. Responses are grounded in actual Bible data retrieved via a Hybrid RAG pipeline combining keyword matching and semantic vector search (pgvector), then streamed in real time via SSE from Gemini. The app runs on mobile (React Native + Expo) and desktop (Tauri v2).
01. Problem
Bible study tools are either keyword-only search engines that miss semantic meaning, or AI chatbots that hallucinate verses. Users need conversational AI that is genuinely grounded in scripture with verifiable citations.
02. Solution Overview
- Built a Hybrid RAG pipeline combining regex-based keyword extraction with OpenAI embedding (1536-dim) + pgvector semantic search
- Implemented real-time SSE streaming from Gemini via Supabase Edge Functions
- Designed rich inline verse cards with full book/chapter/verse attribution for verifiability
- Added cross-platform support: React Native for mobile + Tauri v2 for native desktop
Build
Tech Stack
React Native 0.81Expo 54TypeScriptSupabase PostgreSQLpgvectorOpenAI EmbeddingsGemini 3.1 FlashTauri v2TanStack Query v5NativeWind
- • Hybrid RAG pipeline: regex keyword extraction + OpenAI embedding (1536-dim) + pgvector semantic search
- • Real-time SSE streaming from Gemini via Supabase Edge Functions
- • Rich inline verse cards with book/chapter/verse attribution
- • Cross-platform: React Native (iOS/Android) + Tauri v2 (macOS/Windows/Linux)
Secure
- All API keys (OpenAI, Gemini, service_role) stored server-side only in Edge Function secrets
- IP-based rate limiting: 5/min burst, 30/3hrs per IP, 200/day global cap
- Row-Level Security (RLS) on all Supabase tables
- 500-character message length cap to prevent token-stuffing
- Exact-match response cache (zero LLM cost on repeated queries)
- Fail-closed: rate limit errors default to deny
03. Proof & Verification
Verified Claims
- >Hybrid RAG retrieval ensures answers are grounded in actual scripture, not hallucinated
- >IP-based rate limiting (5/min burst, 30/3hrs, 200/day) with fail-closed defaults
- >Exact-match response cache eliminates redundant LLM costs
- >Anonymous auth with zero sign-up friction — Supabase RLS enforced on all tables