No description
  • Python 84.4%
  • HTML 8.7%
  • JavaScript 4.1%
  • CSS 2.7%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Luca Zani c90b8d2293 Update 1.7.6
Security Improvements
2026-11-01 22:45:06 +01:00
.github Disable Dependabot 2026-11-01 22:40:45 +01:00
banana_backup Update 1.7.6 2026-11-01 22:45:06 +01:00
banana_ops Update 1.7.6 2026-11-01 22:45:06 +01:00
bananachat Update 1.7.6 2026-11-01 22:45:06 +01:00
compute Update 1.7.6 2026-11-01 22:45:06 +01:00
docs Update 1.7.6 2026-11-01 22:45:06 +01:00
scripts bump 1.7.3 2026-10-24 13:22:21 +02:00
tests Update 1.7.6 2026-11-01 22:45:06 +01:00
worker Update 1.7.6 2026-11-01 22:45:06 +01:00
.editorconfig General Release 2026-09-25 16:35:23 +02:00
.env.example Update 1.7.6 2026-11-01 22:45:06 +01:00
.gitignore bump 1.7 2026-10-20 15:18:40 +02:00
AUDIT.md Update 1.7.6 2026-11-01 22:45:06 +01:00
banana General Release 2026-09-25 16:35:23 +02:00
bandit.yaml Update 1.7.6 2026-11-01 22:45:06 +01:00
CHANGELOG.md Update 1.7.6 2026-11-01 22:45:06 +01:00
CODE_OF_CONDUCT.md bump 1.7 2026-10-20 15:18:40 +02:00
conftest.py Stability Update 2026-09-30 17:23:55 +02:00
CONTRIBUTING.md bump 1.7 2026-10-20 15:18:40 +02:00
dev.sh bump 1.7 2026-10-20 15:18:40 +02:00
gunicorn.conf.py Update 1.7.6 2026-11-01 22:45:06 +01:00
LICENSE General Release 2026-09-25 16:35:23 +02:00
Makefile bump 1.7 2026-10-20 15:18:40 +02:00
NOTICE bump 1.7.3 2026-10-24 13:22:21 +02:00
pytest.ini Stability Update 2026-09-30 17:23:55 +02:00
README.md bump 1.7.3 2026-10-24 13:22:21 +02:00
requirements-browser.txt bump 1.7 2026-10-20 15:18:40 +02:00
requirements-build.lock Update 1.7.6 2026-11-01 22:45:06 +01:00
requirements.lock Update 1.7.6 2026-11-01 22:45:06 +01:00
requirements.txt Update 1.7.6 2026-11-01 22:45:06 +01:00
ruff.toml bump 1.7 2026-10-20 15:18:40 +02:00
SECURITY.md bump 1.7 2026-10-20 15:18:40 +02:00
sqlite_migrations.py General Release 2026-09-25 16:35:23 +02:00
sqlite_runtime.py General Release 2026-09-25 16:35:23 +02:00
sqlite_snapshot.py General Release 2026-09-25 16:35:23 +02:00
UPGRADING.md Update 1.7.6 2026-11-01 22:45:06 +01:00
wsgi.py Stability Update 2026-09-30 17:23:55 +02:00

BananaChat logo

BananaChat

BananaChat is a self-hosted chat application for Ollama. Run open models on your own hardware and give a group of people a private chat interface with accounts, quotas and administration.

  • Chat with streaming answers, reasoning display, Markdown, attachments (images, PDFs, text and code), personalities, share links, search, exports and no-history chats.
  • OpenAI-compatible API (/v1/chat/completions, /v1/models, /v1/images/generations) with personal keys, a playground and per-account token limits.
  • External API providers: Anthropic, OpenAI, OpenRouter and other OpenAI-compatible services, with presets and keys encrypted on the server. LM Studio, llama.cpp and vLLM on your own hardware count as local models, with their model lists kept current. See setup.
  • Claude Code and Codex subscription pools: several subscription accounts each, with automatic model and usage discovery, caps at a share of each provider's five-hour, weekly and per-family allowance, and strict model limits. Off by default; administrators sign each account in from the administration page with the official CLIs' own login (a link and a code), after a one-time setup script. See Claude Code and Codex for provider-approved deployment.
  • Cloud sessions for coding work in isolated sandboxes. Off by default. See agents.
  • Two-step verification for every account, which administrators can require for all administrators. See two-step verification.
  • Administration: users and invitations, model catalogue and downloads, access policies, quotas, metrics, audit log, maintenance mode and theming.
  • Scales out: separate web and GPU servers, volunteer worker PCs, and image generation with ComfyUI. Workers whose owners allow it can be maintained from the browser (terminal and VNC) or with native SSH, VNC and RDP clients over a virtual network, without opening ports, and administrators manage their models remotely. See workers.
  • Operations: one command installs, updates with automatic rollback, backs up (optionally encrypted to a private Git repository) and restores a server. The HTTPS proxy it writes also works behind Cloudflare.
  • English, Italian and German interface, light and dark themes, accessibility options, and BM mode: an easy mode with a simpler interface.

Try it locally

You need Python 3.12 or newer and Ollama with at least one model:

ollama pull qwen3:4b
./dev.sh

Open http://127.0.0.1:8000. The terminal prints the setup token for creating the first administrator. The development server listens on loopback only.

Run the tests

make test creates a virtual environment and runs the suite; make lint runs ruff. By hand:

python3 -m venv .venv && . .venv/bin/activate
python -m pip install -r requirements.txt pytest ruff==0.17.1
python -m pytest -q
python -m ruff check .

Some tests need tools outside Python: Git and age for the backup tests, ssh-keygen for the signed-update tests, and Node.js for the Markdown renderer tests (skipped without it). See CONTRIBUTING and development.

Install on a server

On Linux with systemd, the usual layout is two servers: a GPU server that runs the models and a web server (a VPS is enough) that keeps accounts and chats. Install from the newest release tag. On the GPU server:

git clone https://github.com/BananaSuite/BananaChat.git
cd BananaChat
git checkout "$(git tag --list 'v*' --sort=-v:refname | head -n 1)"
sudo ./banana install --mode compute --domain compute.example.org
sudo bananachat proxy --install

It prints a pairing code; keep it secret. On the web server, check out the same release and run:

sudo ./banana install --domain chat.example.org --pair
sudo bananachat proxy --install

--pair asks for the code, shows its address for confirmation and tests the connection before installing. --mode single runs everything on one machine.

Updates are off by default and follow release tags. Run sudo bananachat update when you want one, or turn on automatic updates with sudo bananachat updates enable --require-signatures ALLOWED_SIGNERS. Every update backs up the installation first and rolls back if the new version does not start. Read UPGRADING.md before updating and the changelog for what changed. See deployment and backups.

Documentation

Privacy

Conversations are stored in the server's SQLite database and sent only to the inference backend you configure. No-history chats are left out of the user's history and erased after a configurable time, but administrators can review them in an audit log, and the interface says so. If you enable volunteer worker PCs, the people running them can read the prompts they process. Shared links make a conversation readable by anyone who has the link.

History

BananaChat began as BananaAI, a way to run AI models ourselves instead of sending every request to someone else's servers. It started inside BananaWiki and was rewritten as a separate application for the open-source release. The public repository starts from a clean export; NOTICE records the original dates. The about page on the BananaWiki site tells the longer story.

Licence

BananaChat is licensed under the GNU Affero General Public License v3.0 only (AGPL-3.0-only). Personal and commercial use are allowed. If you run a modified version for others over a network, offer them its source code (AGPL section 13) and set BC_SOURCE_URL to it; the interface links to it. See LICENSE and NOTICE.

Copyright © 2026 Luca Zani and contributors. Started by Luca Zani (OverloadedTech) in July 2026. Each contributor retains copyright in their contributions.

Maintainers

Maintained by Luca Zani and contributors. To take part, start with CONTRIBUTING.md.