Quivora Chat
A Flutter app for chatting with Gemini, Claude, and GPT-4o in one place, with image and document analysis.
A mobile app designed and built by Hassan Ur Rahman.
Overview
Quivora Chat is a cross-platform Flutter app where you pick a model from Google, Anthropic, or OpenAI and chat with it. You can attach photos for vision-capable models, or PDF, DOCX, TXT, and Markdown files, whose text is extracted on the device and added to the conversation. Conversations, messages, and files are saved to your account with Supabase.
Usage runs on credits: each model costs a set amount per message, from cheap fast models to premium ones. New users get a welcome balance and can earn more through rewarded ads, daily rewards, and achievements. The same product family includes a Next.js web client, a Telegram bot, and a terminal client written in Go.
Key features
Multi-provider model picker
Gemini 2.5 Flash and Pro, Claude 3.5 Haiku, Claude Sonnet 4 and 4.5, and GPT-4o, each showing its credit cost per message.
Streaming responses
Replies stream in token by token, and you can stop a response mid-stream.
Image analysis
Attach photos from the camera or gallery. They are compressed on the device before being sent to vision models.
Document analysis
Attach PDF, DOCX, TXT, or Markdown files up to 10 MB. Text is extracted on the device and the original is kept in cloud storage.
Cloud conversation history
Conversations sync to your account, protected by row-level security. Rename conversations, and retry or delete messages.
Accounts
Email and password or Google sign-in, with password reset through deep links that open straight in the app.
Credits and rewards
Per-message credits, topped up through rewarded ads, daily rewards, and achievement points that convert to credits.
Polished chat UI
Markdown rendering, syntax-highlighted code blocks, light and dark themes, a connection indicator, and a low-credit banner.
How it's built
- Flutter and Dart, with an AI service layer that routes each request to a per-provider implementation for Anthropic, OpenAI, and Google based on the selected model.
- Streaming is implemented by parsing Server-Sent Events from the chunked HTTP response by hand, so replies render as they arrive.
- Supabase handles authentication (email and Google OAuth), Postgres tables protected by row-level security, a trigger that sets up each new user's profile, and Storage for uploaded files.
- Credits and rewards run as Postgres functions, so balances are only changed inside the database.
- A lightweight reasoning helper spots math, logic, and code prompts and asks capable models to work step by step.
- Companion clients: a Next.js 15 web app with Drizzle on Neon Postgres, a grammY Telegram bot, and a Go command-line client.
Challenges & solutions
- Never double-spending credits
- Credit deduction is a single Postgres function that locks the user's row, checks the balance, and deducts in one transaction, so two messages sent at once can never overdraw an account.
- Large phone photos and vision APIs
- Images are capped at 1920px wide and JPEG quality is stepped down until the file fits a target size, then encoded in the format each provider expects.
- Using PDFs and Word files in chat
- Text is extracted on the device: PDFs through a PDF library, and DOCX files by unzipping the document and reading its text runs directly. Only the text goes to the model.
Tech stack
- Flutter
- Supabase
- Claude API
- OpenAI API
- Gemini API
- Google AdMob