selfhost.directory

The index of self-hostable projects — ranked, categorized and served with live updates.
Own your data and stop giving it to big tech.

Mirobody logo

Self-host Mirobody

1.5.9

AI health-data engine with traceable lab answers

ReleaseOpen SourceApache-2.0
Updated14 hours ago
LanguagePython
Setup difficultyModerate
Stars
1 395
RAM
16 GB (at least 8 GB of it for Docker)
Port
18060 (The web app, its HTTP API under /api/* and MCP under /mcp; published to 127.0.0.1:18060 by default (MIROBODY_HOST_PORT).)
Requires
PostgreSQL with pgvector
Docker
thetahealth4mirobody/mirobody
Install with Docker

What is Mirobody?

Mirobody gathers lab reports, wearable exports, journal notes and genetic files into one coded record, using bundled LOINC, ICPC-3 and UCUM vocabularies so the same test named five ways by five labs becomes a single comparable history. On top of that record an AI agent answers questions with charts and links each number back to the document page it came from, while arithmetic runs in local Python rather than in the model. Other capabilities: a health journal that turns free text into coded complaints and readings, family care circles with per-member view or edit grants, 23andMe/AncestryDNA/WeGene/VCF queries by rsID, gene or region, a personal MCP link for Claude Code, Codex or Cursor, CSV/JSON/NDJSON/VCF/FHIR exports, and a REST API. Deploy it with Docker Compose via ./deploy.sh, natively without containers on Debian/Ubuntu through install scripts, or in GitHub Codespaces; the local profile adds llama.cpp so app, records and models never leave the machine, with no API key. The fully local route wants 16 GB of memory, and the app binds to 127.0.0.1 unless you change it. At-rest encryption covers chat, uploads, medication text and profiles but not yet readings or genotypes. Theta Health is a separate consumer product built on this engine.

Should you self-host Mirobody?

Mirobody scores 56/100 on selfhost.directory (how scoring works) and ranks #2 of 5 in Healthcare. It has 1 395 GitHub stars.

It shipped 10 stable releases in the past year. The latest, 1.5.9, came out on 27 October 2026. New versions land roughly every 3 days.

Setup is moderate: expect some configuration beyond a single command. An official Docker image is available. It is Apache-2.0-licensed and written mostly in Python.

Its closest alternative on selfhost.directory is OpenEMR (72/100, 5 555 stars). It scores higher overall, so compare the two before you pick. See Mirobody vs OpenEMR side by side.

Features

  • AI agent chat over health records
  • Data export and backup
  • Document ingestion with OCR
  • Encryption at RestReadings and genotypes are not covered yet.
  • Family care circles
  • Genetic data analysis
  • Health data standardization
  • Health journaling
  • Local LLM Inference
  • Local Python calculationsThe optional containerized calculator needs a local Docker image and daemon connection.
  • MCP Server
  • Privacy: no telemetry
  • REST API
  • Source citations for answers
  • Wearable and device data importOura/Whoop are pulled on a schedule; Garmin pushes via webhook and needs vendor developer credentials.

Mirobody README

How to install Mirobody

Install Mirobody with Docker

git clone --depth 1 https://github.com/thetahealth/mirobody.git && cd mirobody scripts/install_native.sh # PostgreSQL, pgvector, the Python package, a .env scripts/start_native.sh # the worker and the app on port 18060

On Debian or Ubuntu, PostgreSQL 16 with pgvector comes from the distribution's packages; needs your own model API key.

How to configure Mirobody

  • AGENT_DIRSmirobody/agent
  • BOOTSTRAP_SCHEMAtrue
  • COMPOSE_PROFILESlocal-cpu or local starts llama.cpp beside the stack so every model runs on this machine.

    local-cpu or local starts llama.cpp beside the stack so every model runs on this machine.

    values: local, local-cpu

  • CONFIG_ENCRYPTION_KEYEncrypts secret values in the config overlay.

    Encrypts secret values in the config overlay.

  • DEFAULT_TIMEZONEAmerica/Los_Angeles
  • DOCKER_MIRRORRegistry mirror prefix used when Docker Hub is unreachable from the daemon; empty turns the mirror off.

    Registry mirror prefix used when Docker Hub is unreachable from the daemon; empty turns the mirror off.

  • EMAIL_PREDEFINE_CODESthe two demo accounts
  • ENABLE_INDICATOR_EXTRACTION1
  • HF_ENDPOINTMirror for the one-time Hugging Face model download.

    Mirror for the one-time Hugging Face model download.

  • HTTP_HEADERSunset
  • JWT_KEYSession signing key generated into .env on first run.

    Session signing key generated into .env on first run.

  • LOCAL_BASE_URLOpenAI-compatible local model server for answering (host llama-server or http://llama:8080/v1 with a Compose profile).

    OpenAI-compatible local model server for answering (host llama-server or http://llama:8080/v1 with a Compose profile).

  • LOCAL_MODELminicpm5-2bThe answering model served locally.

    The answering model served locally.

    values: minicpm5-2b, qwen3.8-27b

  • LOCAL_OCR_MODELglm-ocrThe document reader model.

    The document reader model.

  • MCP_PUBLIC_URLunset
  • MCP_TOOL_DIRSmirobody/agent/tools
  • MCP_URL_TTL_DAYS
  • MIROBODY_BIND127.0.0.1Address the app port is bound to; 0.0.0.0 offers it to other machines.

    Address the app port is bound to; 0.0.0.0 offers it to other machines.

  • MIROBODY_CONFIG_FILEPath to a config.{ENV}.yaml overlay for config.yaml.

    Path to a config.{ENV}.yaml overlay for config.yaml.

  • MIROBODY_HOST_PORT18060Host port the app is published on (paired with MIROBODY_BIND).

    Host port the app is published on (paired with MIROBODY_BIND).

  • MIROBODY_IMAGEOverride the application container image.

    Override the application container image.

  • OPENROUTER_API_KEYVendor model key in .env; a key here outranks the local entries.

    Vendor model key in .env; a key here outranks the local entries.

  • PG_ENCRYPTION_KEYEncrypts stored content such as chat messages and uploaded files.

    Encrypts stored content such as chat messages and uploaded files.

  • PG_PASSWORDDatabase password; ./deploy.sh generates it with openssl rand -hex 32 on first run.

    Database password; ./deploy.sh generates it with openssl rand -hex 32 on first run.

  • PRODUCTIONfalse
  • PROVIDER_DIRSmirobody/collect/providers
  • REQUEST_RATE_LIMITERper-path limits
  • SEED_DEMO_DATAtrue
  • SETUP_TOKENRequired by the first-run page before it changes where health data is sent.

    Required by the first-run page before it changes where health data is sent.

Mirobody releases & version history

Rate this project

Click to rate — no account needed.

0 comments

Posting as guest
Loading comments…