CLI
More ▾
Render an MP4 or run a live avatar from the terminal, on macOS (Apple silicon) and Linux (x86_64, arm64), with no code. On Linux it needs no GPU.
One binary, no code: bithuman render turns an audio file into a talking-avatar MP4, and bithuman run opens a live conversation with an avatar in your browser. It renders on your own machine. To program against the models instead, use Python.
Note: On Linux, both models run live on the CPU alone, no GPU. See CPU only (no GPU).
| Detail | Expression 2 | Essence 2 |
|---|---|---|
| Renders | any character from one portrait | a photoreal person from one portrait |
render and run | both | both |
| Download per avatar | about 190 MB | 140–160 MB, plus a shared audio encoder (about 66 MB) once |
Before you start
| You need | For | Check |
|---|---|---|
| macOS 14+ on Apple silicon, or Linux on x86_64 or arm64 | the binary | uname -sm |
| A bitHuman sign-in or API secret | run and render (browsing and downloading need none) | bithuman account exits 0 |
ffmpeg on PATH | render, and run with an Essence 2 avatar | ffmpeg -version |
livekit-server 1.13 or newer (the Linux download includes it) | run | livekit-server --version; update with brew upgrade livekit |
Python 3.11 or newer with venv (python3-venv on Debian/Ubuntu) | run (its voice agent) | python3 --version |
Install
# macOS (Apple silicon): also installs ffmpeg, livekit-server and Python
brew install bithuman-product/bithuman/bithuman-cli
# Linux, x86_64 or arm64 (Debian/Ubuntu); the download includes livekit-server
sudo apt install -y ffmpeg python3-venv
curl -fsSL https://install.bithuman.ai | sh
The installer puts the CLI in ~/.local/bin (set BITHUMAN_INSTALL_DIR to change it) and verifies its checksum. If it asks you to, add export PATH="$HOME/.local/bin:$PATH" to your shell profile. On macOS, curl -fsSL https://install.bithuman.ai | sh installs the same release (then brew install ffmpeg livekit yourself). bithuman --version prints the CLI and engine versions.
Check the install:
$ bithuman --version
libessence 2.11.16 ABI 7
bithuman 2.8.3
The CLI is not on PyPI. pip install bithuman installs the Python library, which has no command.
Authenticate
bithuman login # opens a browser and stores a credential for this device
bithuman login --device # over SSH: prints a code to enter in any browser
bithuman account # exit 0 when signed in
Sign in first, because every render path needs a credential: without one, run and render stop before the first frame with exit 77 and write nothing. In scripts and CI, set BITHUMAN_API_SECRET instead of signing in (Your API secret). Credits pay for session time, talking or idle, by the exact second (pricing). Listing, downloading and opening avatars need no account.
First frame
Render the sample speech through the wise-pup sample avatar:
bithuman login
curl -fsSLo speech.wav https://docs.bithuman.ai/samples/speech.wav
bithuman render wise-pup speech.wav -o out.mp4
# → out.mp4: 416×720, 300 frames, 15.0 s
Then talk to it live:
bithuman run wise-pup
# → open the printed http://127.0.0.1:8088/<CODE> and allow the microphone
render accepts any audio format ffmpeg reads. bithuman run needs two more things from Before you start: livekit-server and Python. It starts a local livekit-server and the voice agent; the first run installs the agent, about 350 MB on disk, in one to two minutes.
Complete example
From a fresh machine to a talking-avatar MP4 in four commands.
Requirements
| You need | Notes |
|---|---|
| macOS (Apple silicon) or Linux (x86_64, arm64) | |
| An API secret | or bithuman login |
ffmpeg | brew install ffmpeg or sudo apt install -y ffmpeg |
Run it
curl -fsSL https://install.bithuman.ai | sh
export BITHUMAN_API_SECRET="<your API secret>"
curl -fsSLo speech.wav https://docs.bithuman.ai/samples/speech.wav
bithuman render wise-pup speech.wav
Expected output
wise-pup.mp4: 416×720, as long as the audio (15 seconds for the sample). To talk to the avatar instead, run bithuman run wise-pup and open the printed URL (this also needs livekit-server; see CLI).
Make it your own
- Your own avatar: create one with the Agents API (or on bitHuman), then
bithuman pull <AGENT_CODE>and render it the same way. - Your own words: any audio file
ffmpegreads works as the second argument; generate speech with Text to speech. - A photoreal person:
bithuman render sofia-ramirez speech.wavrenders Essence 2 (this avatar is 1080×1920 portrait). - Scripts and CI: add
--jsonand branch on exit codes (reference). - A conversation instead of a clip:
bithuman run wise-pup— Talk to an avatar on your machine.
Integrate into your app
| Job | Command |
|---|---|
| List the sample avatars | bithuman list (the same list as https://api.bithuman.ai/v1/models/showcase) |
| Download one | bithuman pull <slug> prints the cached path; --force downloads again |
| Download your own agent | bithuman pull <AGENT_CODE> --model essence-2 (needs sign-in) |
| Inspect an avatar | bithuman open <avatar> |
| Render | bithuman render <avatar> in.wav -o out.mp4 (a code or name is downloaded on first use) |
| Serve a live session | bithuman run <avatar>; --host <LAN address> to expose it (0.0.0.0 also needs BITHUMAN_ALLOW_PUBLIC_BIND=1) |
| Talk with your own OpenAI key | export OPENAI_API_KEY=… before bithuman run (voice settings) |
| Run the brain on your own hardware | local conversation brain |
| Drive it from an AI agent | bithuman mcp (MCP server) |
| Script it | add --json: every failure prints one JSON object with a stable code, and the exit code is the contract (reference) |
Voice settings
bithuman run starts a voice agent on OpenAI Realtime. Both settings are read from the environment:
| Variable | Default | What it does |
|---|---|---|
OPENAI_API_KEY | — | Your OpenAI key. Without it, the voice runs on your bitHuman account at the managed voice-chat rate, 10 credits per minute (pricing). |
BITHUMAN_INSTRUCTIONS | a short assistant prompt | The agent’s system prompt |
The whole setup, and the same conversation in your own Python code: Talk to an avatar on your machine.
Platform notes
- Essence 1 avatars work with
runonly; for a file use Python or the video API. Expression 1 runs on the cloud API. - The first Essence 2 render on a machine downloads a shared audio encoder (about 66 MB) to
~/.bithuman/engines/essence-2/once. - Intel Macs and Windows have no binary. Use WSL2 on Windows, or the web embed or cloud API.
Performance
| Configuration | Essence 2 | Expression 2 |
|---|---|---|
| Intel Core i7-13700F (x86_64) Linux · CLI CPU only (no GPU) | 2.0× real timeIntel Core i7-13700F (x86_64), CPU only (no GPU) · CLI 2.8.1 · measured 2026-09-27 | 2.2× real timeIntel Core i7-13700F (x86_64), CPU only (no GPU) · CLI 2.8.1 · measured 2026-09-27 |
| Apple M4 macOS · CLI | 4.2× real timeApple M4 · CLI 2.8.1 · measured 2026-09-27 | 8.4× real timeApple M4 · CLI 2.8.1 · measured 2026-09-27 |
Times real time: seconds of avatar video rendered per second. At 1.0× or more, an avatar holds a live conversation. Select a figure for its release and date. All configurations and how we measure.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
bithuman: command not found | ~/.local/bin is not on PATH | export PATH="$HOME/.local/bin:$PATH" |
not signed in, exit 77, nothing written | no credential | bithuman login, or set BITHUMAN_API_SECRET |
your credential is invalid or expired or the API secret was rejected, exit 77 | the secret was revoked or mistyped | bithuman login again, or create a new API secret |
bithuman login prints token exchange failed or times out, exit 1 | the browser or device approval did not complete | run bithuman login (or --device) again |
render exits 69: ffmpeg not found | ffmpeg is not on PATH (common in scripts) | install it, or set BITHUMAN_FFMPEG to its path |
run with an Essence 2 avatar: no avatar in the page, and the terminal shows essence-2: ffmpeg not found | ffmpeg is not on PATH | sudo apt install -y ffmpeg, or set BITHUMAN_FFMPEG |
run says the livekit-server binary was not found | livekit-server is not installed | brew install livekit (macOS), or rerun the installer (Linux) |
run exits 69: livekit-server 1.8.0 at …/livekit-server is too old for bithuman run (it needs 1.13 or newer) | an old livekit-server found on PATH | brew upgrade livekit (macOS), or reinstall with curl -fsSL https://install.bithuman.ai | sh (Linux) |
SLUG_NOT_FOUND, exit 66 | the slug is not in the sample list | bithuman list and copy a slug |
pull <CODE> fails with 404 NOT_FOUND | not your agent and not a sample avatar | check the code under your agents |
pull <CODE> fails with 409 MODEL_NOT_GENERATED | the agent has no model of that kind | add the model, or pass the --model it has |
PUBLIC_BIND_REFUSED, exit 2 | --host 0.0.0.0 without consent | use a LAN address, or set BITHUMAN_ALLOW_PUBLIC_BIND=1 |
| the installer names your platform and stops | no binary for this platform | see Platform notes |
Reference
- CLI reference: every command, flag, exit code and environment variable.
- Local conversation brain: run the conversation fully on your hardware.
- CLI example scripts: live stream, offline render, REST.
- Changelog and Downloads & versions.
