English | Tiếng Việt
A ChatGPT-style web UI for AI agents: watch them think, call tools and make things, live.
One agent run, live: thinking, a plan, tools, a sub-agent and generated images. Demo media were made with Gemini.
Peep has real accounts for a team, with an admin console to run them. Admins approve people who sign up, or create accounts themselves and hand over a temporary password, then manage everyone from one page that also works on a phone. Every admin change is written to an audit log, and each user can get a token limit. The full guide is in docs/usage.md.
- Create accounts (active at once, or pending), and approve, disable, enable or delete many at a time. Your own account is skipped.
- Make or remove admins, reset passwords, disable a user (sessions end, data stays) or delete one with their files.
- Set a token limit per user, per day or per month (UTC), checked before a message is sent. Unlimited by default.
- Users see their usage in the account menu; at the limit, the composer says when it resets.
- An audit log tab shows who did what to whom, with search and an action filter.
![]() Create and approve Make an account, approve a batch. |
![]() Audit log Who changed what, and when. |
![]() Token limits Set a limit; the user is blocked at the cap. |
![]() Admin on a phone The same console on mobile. |
Peep is a self-hosted chat web app that shows the whole run of an AI agent, not only its final answer: thinking, tool calls, sub-agents, images, video, audio and how much of the context window is used, all streaming live. It works with any OpenAI-compatible chat API (OpenAI, Gemini, DeepSeek, Anthropic compat, OpenRouter, vLLM, Ollama and others). Peep is a UI: it has no agent logic of its own yet, and ships recorded demo runs so you can see every part of it without a model.
Conversation
- Thinking streams into a quiet row and collapses to "Thought for 12s". Tool calls and nested sub-agents are inline rows with input and output; images, video and audio appear right in the flow.
- Markdown, syntax-highlighted code with Copy, and LaTeX math.
- Per-model thinking levels (Off, Low, High, ...) defined in your config, a Stop button, and replies that keep running if you close the tab.
- Attach images, video, audio and files; browse images in a zoom lightbox.
- The demo you see in the screenshots uses real AI output: the pictures were generated with Gemini and the short clip is assembled from them.
Know where you are
- A context gauge shows how much of the model's context window is used, with a breakdown and cache tokens.
- The sidebar shows which chats are running, unread or failed, with search and pinning.
Everyone gets in safely
- Email and password accounts. New accounts wait for an admin to approve them, or an admin creates them directly. Bulk actions, an audit log and optional per-user token limits are built in.
- Plugins and Skills page: users store MCP server entries and skill packages for a future agent (not used by the chat yet). Plugin secrets are encrypted at rest.
Everywhere
- Phone, tablet and desktop; installable as a PWA.
- Vietnamese and English, light and dark theme.
- Peep, the yellow chick, greets you in a new chat and keeps you company while a reply is on its way.
You need Docker with Compose v2.
git clone git@github.com:ensemlabs/peep.git && cd peep
make env-
make envcreates.envwith freshly generated secrets (database, MinIO, admin password,SECRETS_KEY) andconfig/models.yamlfrom the example. It never overwrites an existing.env. The admin login isADMIN_EMAILandADMIN_PASSWORDin.env; setADMIN_EMAILto your own address first. KeepSECRETS_KEY: without it, stored plugin headers cannot be read. In production Peep refuses to start while a password still holds thechange-meplaceholder from.env.example. -
Edit
config/models.yaml: pointactiveat a model of your provider (the file has presets to copy), and put the provider's API key in.envunder the name given byapi_key_env. -
Start it:
make up
-
Open http://127.0.0.1:8090 and log in with
ADMIN_EMAILandADMIN_PASSWORD.
make up also creates the two files if they are missing. After changing config/models.yaml, run
docker compose restart app. The built-in replay:* demo runs need no provider (see docs/usage.md).
To skip the build, use the single image ghcr.io/ensemlabs/peep published to GHCR (linux/amd64 and linux/arm64; it runs next to the official Postgres and MinIO images). Prepare .env and
config/models.yaml as above, then:
docker compose -f docker-compose.yml -f docker-compose.ghcr.yml up -dIt pulls latest; set PEEP_VERSION=0.1.0 (in .env or the shell) to pin a release. Needs Compose 2.24 or newer.
Peep reads its models from config/models.yaml. Users get the active model:
active: my-model
providers:
- id: my-provider
base_url: https://api.example.com/v1
api_key_env: MY_PROVIDER_API_KEY # name of a variable in .env; keys never go in this file
models:
- id: my-model
upstream: provider-model-name
context_window: 128000
thinking: # optional
default: "off"
levels:
- {id: "off", label: Off, patch: {}}
- {id: high, label: High, patch: {reasoning_effort: high}}config/models.example.yaml has presets for OpenAI, Gemini, DeepSeek, Anthropic compat,
OpenRouter and vLLM/Ollama. Provider settings change, so check each preset against the provider's documentation.
The variables you will most likely touch:
| Variable | Default | Meaning |
|---|---|---|
ADMIN_EMAIL, ADMIN_PASSWORD |
empty | First admin, created on startup |
SECRETS_KEY |
empty | Fernet key for plugin secrets |
APP_ORIGINS |
http://localhost:8090,http://127.0.0.1:8090 |
Allowed origins; add your public URL |
COOKIE_SECURE |
auto |
auto: Secure cookie (named __Host-ec_session) when every APP_ORIGINS entry is https; or true / false |
WEB_PORT |
8090 |
Host port, bound to 127.0.0.1 |
MAX_UPLOAD_MB |
200 |
Upload limit |
MODELS_CONFIG |
/app/config/models.yaml |
Models file inside the container |
Everything else (sessions, login throttling, S3, replay): docs/configuration.md.
Peep serves plain HTTP. For a public site, terminate TLS in a proxy (Caddy, Traefik, nginx), set APP_ORIGINS (https) or COOKIE_SECURE=true,
add the public URL to APP_ORIGINS, and set TRUSTED_PROXIES to the proxy's address so the real client IP is used
(it is empty by default: X-Forwarded-For is ignored). Disable proxy buffering for /api so SSE streams. See
docs/architecture.md.
Internal names keep the project's earlier name: the Docker Compose project, database and bucket are ensemble-chat
/ ensemble_chat, the session cookie is ec_session (__Host-ec_session over https), and browser settings use ec_* keys in localStorage.
browser ── app (FastAPI: SPA + /api, one worker, the only published port)
├── postgres users, chats, messages, plugins, skills
├── minio uploaded and generated files (S3)
└── LLM any OpenAI-compatible endpoint
Details and request flow: docs/architecture.md. HTTP and SSE contract: docs/api.md. Why this stack: ADR 0001.
| Command | What it does |
|---|---|
make up / make down |
Start and stop the stack |
make logs, make ps, make build |
Logs, status, build images |
make test-be |
Backend tests against real Postgres and MinIO |
make test-fe |
Frontend tests, type check and build |
make e2e |
Playwright suite against the live stack |
make clean |
Stop and delete all data volumes |
make help lists everything. More in docs/development.md.
- Passwords are hashed with argon2id. Sessions are random tokens in an
HttpOnly,SameSite=Laxcookie; only a hash is stored. Mutating requests must come from an allowed origin (CSRF check). - Login attempts are throttled: 5 failures lock an email and IP pair for 15 minutes, doubling up to 24 hours.
- Files are only readable by their owner. Only verified images, video and audio display inline; everything else
downloads, with
nosniffand a locked-down CSP. - Plugin header values are encrypted at rest (Fernet) and never returned. Peep never calls plugin URLs or runs skill code.
- Never commit
.envorconfig/models.yaml. - Known limits: registration tells whether an email is already registered (accepted trade-off for a self-hosted app).
The app connects to Postgres and MinIO with their admin credentials; for production create least-privilege users
(one database owner, one bucket-scoped S3 key). The KaTeX advisory affects only
trustmode, which Peep keeps off.
Full list and numbers: docs/configuration.md and docs/api.md.
- Peep runs one API worker: replies live in the process, so a restart marks running replies as interrupted. Scaling out needs a shared event bus.
- Plugins and Skills are stored but not used by the chat yet: connecting a real agent backend is the next step.
- No SSO, email verification, email invitations or password-reset emails; an admin resets passwords and hands over temporary ones.
- Uploads are not virus-scanned and have no per-user quota (token limits only count model tokens).
- The PWA has no service worker, so there is no offline mode.
MIT, see LICENSE. © 2026 Ensemble Labs.












