Bimo is an ultra-premium, privacy-first, open-source streaming AI chat workspace. Built to rival frontier flagship interfaces, it features a dual-engine orchestration layer—supporting high-speed coding (Stanza) and complex multi-step reasoning (Nexos).
Powered by the best NVIDIA-hosted open models, Bimo uses Supabase as a fully isolated backend store (Auth + Postgres + Storage) and a blazing fast Python/Flask streaming gateway deployed on Render.
- Frontend — plain HTML / CSS / JavaScript (no framework, no build step)
- Backend — Flask gateway hosted on Render (gunicorn)
- Auth — Supabase Google OAuth (no passwords)
- Database — Supabase Postgres with row-level security per user
- Storage — Supabase Storage (private bucket, signed URLs)
- Inference — NVIDIA AI Foundation endpoints (OpenAI-compatible)
- Streaming — Server-Sent Events end-to-end (token-by-token)
- Google sign-in via Supabase — single-click OAuth, no passwords
- Streaming chat — tokens render live; markdown + syntax-highlighted code
- Per-chat model picker — switch between Llama 3.3 70B, Llama 3.1 405B, Llama 3.2 90B Vision, Nemotron 70B, DeepSeek R1, Mixtral 8x22B, and more
- Per-chat persona — override the system prompt per conversation
- Image attachments — uploaded to Supabase Storage and passed to vision models as OpenAI-style image content parts
- Structured feedback — 1–5 rating, correctness, length per message
- Analytics dashboard — live summary, breakdown bars, downloadable PNG chart of the rating distribution
- Settings — backend URL, Supabase project, integrations, profile
- Responsive — drawer sidebar on mobile, persistent sidebar on desktop
Browser ──Google OAuth──▶ Supabase Auth ──JWT──▶ Browser
│
│ Authorization: Bearer <jwt>
▼
Flask gateway (Render) ──verify JWT──▶
│
├── Supabase Postgres (RLS, service-role)
├── Supabase Storage (signed URLs)
└── NVIDIA chat-completions (SSE) ──stream tokens──▶ Browser
The browser never touches Supabase data directly: all reads/writes go through
the Flask gateway, which validates the Supabase JWT (HS256,
SUPABASE_JWT_SECRET) and then uses the Supabase service role key to
operate on the user's rows. RLS policies in backend/migrations/0001_init.sql
mean a leaked anon key can never read another user's data.
fyp/
├── backend/
│ ├── app/
│ │ ├── main.py Flask gateway (routes + SSE streaming)
│ │ ├── auth.py Supabase JWT verification
│ │ ├── store.py Supabase Postgres + Storage data layer
│ │ ├── supabase_client.py service-role admin client
│ │ ├── nvidia_client.py NVIDIA chat-completions client
│ │ └── analytics.py pandas / matplotlib reports
│ ├── migrations/
│ │ └── 0001_init.sql Postgres schema + RLS + Storage bucket
│ ├── tests/test_bimo.py smoke tests (health + auth gating)
│ ├── requirements.txt
│ ├── pytest.ini
│ ├── Procfile gunicorn entrypoint for Render
│ └── .env.example
├── frontend/
│ ├── index.html single-page shell
│ ├── css/styles.css design system + markdown / hljs styles
│ ├── assets/favicon.svg
│ └── js/
│ ├── main.js entry + route table
│ ├── router.js hash router
│ ├── auth.js Supabase Auth integration
│ ├── supabaseClient.js browser-side Supabase client
│ ├── api.js fetch wrapper + streamChat (SSE)
│ ├── config.js runtime backend / Supabase overrides
│ ├── icons.js inline SVG icons (Lucide subset)
│ ├── app-shell.js sidebar + layout shared by app pages
│ ├── components/ avatar, logo, message, feedback, toast,
│ │ markdown, model-picker, sidebar, …
│ └── pages/ landing, chat, analytics, settings, not-found
├── render.yaml Render Blueprint (backend service)
└── README.md
- Go to app.supabase.com and create a new project.
- Open SQL editor and run
backend/migrations/0001_init.sql. - Open Authentication → Providers → Google and enable it.
- Create OAuth credentials at Google Cloud Console.
- Add the redirect URI shown by Supabase (e.g.
https://<project>.supabase.co/auth/v1/callback). - Paste the client ID and client secret back into Supabase.
- From Settings → API copy:
Project URL→SUPABASE_URLand the frontendsupabaseUrlanon publickey → frontendsupabaseAnonKey(safe in browser)service_rolekey →SUPABASE_SERVICE_ROLE_KEY(server-only)JWT secret→SUPABASE_JWT_SECRET
Create one at build.nvidia.com and copy it to
NVIDIA_API_KEY on the backend.
cd backend
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env # then fill in the Supabase + NVIDIA values
python -m app.main # http://localhost:8000/health should return {"status":"ok","store":"supabase","model_provider":"nvidia"}.
The frontend is static, so any HTTP server works:
cd frontend
python -m http.server 5500Then open http://localhost:5500. On first visit, go to Settings →
Environment, paste your Supabase project URL + anon key (and, if not running
the backend on :8000, your backend URL), save, and sign in with Google.
For zero-config production, hard-code the defaults in
frontend/js/config.js before deploying.
-
Push this repo to GitHub.
-
In Render, click New → Blueprint and pick the repo. Render reads
render.yamland provisions abimo-backendweb service. -
Open the service → Environment and set:
Var Value SUPABASE_URLfrom Supabase API settings SUPABASE_SERVICE_ROLE_KEYfrom Supabase API settings (server-only) SUPABASE_JWT_SECRETfrom Supabase API settings NVIDIA_API_KEYfrom build.nvidia.com CORS_ORIGINSyour frontend origin (e.g. https://bimo.app) -
Trigger a deploy. The service launches via
gunicorn(seeProcfile). -
Update the frontend
config.apiUrlto your Render URL.
The frontend is a static folder — drop frontend/ on Netlify, Vercel,
Cloudflare Pages, or any static host. Make sure frontend/js/config.js points
at your Render backend and Supabase project, or rely on the in-app
Settings → Environment override.
cd backend
pytest -qtests/test_bimo.py is a smoke suite — it boots the Flask app, hits
/health, and asserts that protected routes return 401 without a JWT. The
full integration suite (real Supabase + NVIDIA) lives outside this repo.
- Plain ES modules in
frontend/js/; no bundler, no transpiler. - Markdown rendering via
marked+marked-highlight+highlight.js, loaded fromesm.sh(seefrontend/js/components/markdown.js). - Backend follows a thin gateway pattern:
auth.pyvalidates JWTs,supabase_client.pywraps the service-role client,store.pyis the data layer,nvidia_client.pyis the inference client,main.pyonly wires routes.
This project is licensed under the MIT License.