> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mirobody.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Welcome to Mirobody

> An open-source, self-hosted data engine that bridges your personal data with the latest AI. This documentation covers Mirobody's health vertical, the foundation of Theta Wellness.

## What is Mirobody?

**Mirobody** is an open-source, self-hosted **data + agent engine** for *personal* AI — built on the belief that the next frontier of AI is not knowing more about the world, but knowing more about *you*.

* 🔌 **HTTP Remote MCP Server** — your tools instantly become callable by ChatGPT, Claude, Cursor, or any MCP client.
* 🤖 **Native agent runtime** — a self-developed engine that reproduces Claude Code's autonomous capabilities locally, plus support for **Claude Agent Skills** (`SKILL.md`).
* 🔄 **Pluggable data providers** — bring your own data source via the Providers API; 300+ wearables, Apple Health, Google Health, and EHR coverage for \~90% of US records are already wired up.
* 🏥 **Health-grade standards** — 400+ health indicators normalized to **FHIR / LOINC / SNOMED CT / RxNorm** with cross-vocabulary search.

> **Health, Finance & More.** Mirobody is domain-agnostic: this docs site focuses on the health vertical (the engine behind [Theta Wellness](https://www.thetahealth.ai/)), but the same architecture powers finance, legal, devops, or any vertical where personal data meets AI. Drop your own modules into `tools/` and `skills/` to start.

<CardGroup cols={2}>
  <Card title="Quick Start" icon="rocket" href="/en/quickstart">
    One-command Docker deploy in under 5 minutes
  </Card>

  <Card title="Use Cases & Examples" icon="lightbulb" href="/en/use-cases">
    Real conversations with synthetic health data
  </Card>

  <Card title="Provider Integration" icon="plug" href="/en/development/provider-integration">
    Add a new device or data source in hours
  </Card>

  <Card title="API Reference" icon="code" href="/en/api-reference/overview">
    Pulse, Chat, and MCP protocol endpoints
  </Card>
</CardGroup>

## Why Mirobody?

<AccordionGroup>
  <Accordion title="Write tools once, run everywhere" icon="wrench">
    Forget JSON schemas and manual bindings — **your Python code is the only definition required**. A function in `tools/` instantly works in ChatGPT (via Apps SDK), Claude / Cursor (via MCP), and the local web client. Mirobody runs simultaneously as an MCP **client** (to use tools) and an OAuth-enabled MCP **server** (to expose them).
  </Accordion>

  <Accordion title="Your data, never leaves your machine" icon="lock">
    The engine runs locally end-to-end — Postgres, Redis, agent runtime, MCP server, file pipeline. Bring your own LLM via OpenRouter or first-party keys (OpenAI, Gemini, Anthropic, Azure, Volcengine, Dashscope). No third-party data hop required.
  </Accordion>

  <Accordion title="Three agents for three jobs" icon="robot">
    * **DeepAgent** — single-model tool orchestration, best for complex multi-step research
    * **MixAgent** — two-phase fusion: a capable model orchestrates tools, a cheaper model writes the response. Cost/quality balance for high-volume workloads.
    * **BaseAgent** — direct LLM chat with no tools, ideal for low-latency Q\&A
  </Accordion>

  <Accordion title="Claude Agent Skills, natively" icon="bolt">
    Drop a `SKILL.md` + `metadata.json` into `skills/` and the agent auto-discovers it. The full Skill body is loaded into the agent's context when activated — write detailed playbooks, examples, edge cases freely.
  </Accordion>

  <Accordion title="Files, multimodally processed" icon="file">
    PDFs, Excel, CSV, audio (WAV/MP3/AIFF/AAC/OGG/FLAC), images (PNG/JPEG/WebP/HEIC/HEIF), genetic data. LLM-powered extraction maps free text to standard indicators automatically.
  </Accordion>

  <Accordion title="Sandbox code execution" icon="terminal">
    The built-in `execute` tool runs shell + Python in isolated [E2B](https://e2b.dev) cloud sandboxes for data analysis, chart generation, and computation — with PostgreSQL-backed file persistence so `write_file` in one turn is visible to `execute` in the next.
  </Accordion>

  <Accordion title="Deploy anywhere" icon="server">
    One-command `./deploy.sh` for Docker, `pip install -e .` for local Python dev, or `MCP_PUBLIC_URL=https://yourdomain.com` to expose your MCP server publicly for ChatGPT Apps.
  </Accordion>
</AccordionGroup>

## Architecture at a glance

| Layer                     | Path                                          | Notes                                                                             |
| ------------------------- | --------------------------------------------- | --------------------------------------------------------------------------------- |
| **Agent runtime**         | `mirobody/pub/agents/`                        | DeepAgent, MixAgent, BaseAgent                                                    |
| **LLM clients**           | `mirobody/utils/llm/`                         | OpenAI, Gemini, Anthropic, Azure, Volcengine, Dashscope (HIPAA-compliant routing) |
| **MCP server**            | `mirobody/mcp/`                               | JSON-RPC 2.0, local + HTTP remote                                                 |
| **Chat service**          | `mirobody/chat/`                              | Sessions, history, streaming (HTTP/WebSocket), memory                             |
| **Data pipeline (Pulse)** | `mirobody/pulse/`                             | 300+ wearables, Apple/Google Health, EHR, file parser, aggregation                |
| **Health standards**      | `mirobody/indicator/`, `mirobody/pulse/core/` | 400+ indicators, FHIR/LOINC/SNOMED CT/RxNorm                                      |
| **Embeddings**            | `mirobody/utils/embedding.py`                 | 1024-dim, Gemini/Qwen, pgvector                                                   |

**Extension points** are top-level directories — drop files in, they're auto-discovered:

| Directory    | Purpose                                            |
| ------------ | -------------------------------------------------- |
| `tools/`     | Python tools → auto-exposed as MCP tools           |
| `skills/`    | Claude Agent Skills (`SKILL.md` + `metadata.json`) |
| `agents/`    | Custom agent implementations                       |
| `providers/` | Custom data providers                              |
| `prompts/`   | Jinja2 prompt templates                            |
| `resources/` | Static resources exposed via MCP                   |

## Supported Providers (Health Vertical)

<CardGroup cols={3}>
  <Card title="Garmin" icon="watch">Activity, sleep, heart rate, HRV</Card>
  <Card title="Whoop" icon="heart-pulse">Recovery, sleep, workouts, cycles</Card>
  <Card title="Oura" icon="ring">Sleep, readiness, activity</Card>
  <Card title="Renpho" icon="weight-scale">Body composition, weight</Card>
  <Card title="Apple Health" icon="apple">iOS Health + CDA medical records</Card>
  <Card title="Google Health" icon="google">Android health data</Card>
</CardGroup>

300+ devices are reachable via the Vital integration; EHR coverage spans \~90% of US records. Custom providers can be added in hours — see [Provider Integration](/en/development/provider-integration).

## Tech Stack

* **Python 3.10+** with async/await throughout
* **FastAPI / Starlette ASGI** for the HTTP layer
* **PostgreSQL** for primary storage + **pgvector** for semantic search
* **Redis** for caching and session store
* **Docker Compose** for one-command deploy
* **E2B** for sandboxed code execution
* **OAuth 1.0a / 2.0 / OIDC / WebAuthn / FIDO2** for auth

## Who is this for?

<CardGroup cols={2}>
  <Card title="Individual users" icon="user">
    Anyone who wants a private, AI-powered home for their health data — without handing it over to a third party
  </Card>

  <Card title="Developers" icon="code">
    Engineers building personal-data AI products: health, finance, legal, devops, or anywhere else `tools/` + `skills/` can take you
  </Card>
</CardGroup>

## Real-World Examples

<Info>
  Showcase conversations below use **synthetic health data** and some Theta-private tools.
</Info>

### Private Health Data Management & Chat

<AccordionGroup>
  <Accordion title="Track health issues across systems and years" icon="timeline">
    Query the same condition across multiple health systems, even across countries:

    <CardGroup cols={2}>
      <Card title="Knee Pain Progress" icon="link" href="https://test-mirobody.thetahealth.ai/share/c2ee8160-33c5-4642-9b34-639390b350ba">
        Track knee pain progression across providers
      </Card>

      <Card title="Cardiovascular Disorders" icon="link" href="https://test-mirobody.thetahealth.ai/share/045adc4b-cf67-45ca-a416-9bdc12670f47">
        Monitor cardiovascular health across health systems
      </Card>
    </CardGroup>
  </Accordion>

  <Accordion title="Unified health issue analysis" icon="chart-line">
    Combine device data, medical records, and self-reported notes:

    <CardGroup cols={2}>
      <Card title="Cardiovascular Summary" icon="link" href="https://test-mirobody.thetahealth.ai/share/84b5e136-f8d1-4264-bd95-5dfdd814ba4f">
        Summarize cardiovascular conditions across sources
      </Card>

      <Card title="Diabetes History & Progress" icon="link" href="https://test-mirobody.thetahealth.ai/share/b1948930-ce86-4925-8082-62e5273b567c">
        Track diabetes from devices, records, and other sources
      </Card>
    </CardGroup>
  </Accordion>

  <Accordion title="Prepare for doctor visits" icon="user-doctor">
    <Card title="PCP Visit Preparation" icon="link" href="https://test-mirobody.thetahealth.ai/share/9c4aea9e-3a73-4bfa-901c-33392897bd52">
      Generate a comprehensive summary and questions for your primary care visit
    </Card>
  </Accordion>
</AccordionGroup>

### Deep Research for Personal Health

<AccordionGroup>
  <Accordion title="Identify patterns and drivers" icon="magnifying-glass-chart">
    Figure out what's actually helping or hurting you:

    <CardGroup cols={2}>
      <Card title="Blood Glucose Analysis" icon="link" href="https://test-mirobody.thetahealth.ai/share/efdb4367-2ae4-491f-a36f-a8f9ee7ed909">
        Find factors that help or harm your blood glucose
      </Card>

      <Card title="Symptoms & Feelings Drivers" icon="link" href="https://test-mirobody.thetahealth.ai/share/59710b3e-c3c2-4c21-a650-f2020316acd9">
        Discover the main drivers behind your symptoms and mood
      </Card>
    </CardGroup>
  </Accordion>

  <Accordion title="Personalized treatment research" icon="flask">
    <Card title="Diabetes Treatment Options" icon="link" href="https://test-mirobody.thetahealth.ai/share/b6490f33-b287-4c47-9474-fae89c8e5615">
      Research personalized options (meds, devices, lifestyle) for diabetes management
    </Card>
  </Accordion>
</AccordionGroup>

### Mirobody as a Data Engine for Developers

<CardGroup cols={2}>
  <Card title="Wearable manufacturers" icon="watch">
    Add AI chat over your device data without building the backend
  </Card>

  <Card title="Research applications" icon="microscope">
    Drop custom tools into `tools/` to deploy subject-facing research apps
  </Card>

  <Card title="Consumer health apps" icon="mobile">
    Use Mirobody as the data + AI backend behind your product
  </Card>

  <Card title="Enterprise" icon="building">
    Contact us for custom integrations and enterprise support
  </Card>
</CardGroup>

## Theta Wellness: Mirobody in Production

[**Theta Wellness**](https://www.thetahealth.ai/) is our flagship application built on Mirobody — a personal health intelligence app that demonstrates what Mirobody can do at production scale. It connects 300+ devices, Apple/Google Health, and EHR records, and supports voice, image, file, and text as inputs.

We're open-sourcing the engine because the same architecture that powers a medical-grade health agent can power your finance analyzer, legal assistant, or devops bot. Swap the files in `tools/` and you're in a new vertical.

## Next Steps

<Steps>
  <Step title="Get started">
    Follow the [Quick Start](/en/quickstart) to deploy locally with `./deploy.sh`.
  </Step>

  <Step title="Configure providers">
    Set OAuth credentials for the devices you want — see [Configuration](/en/configuration).
  </Step>

  <Step title="Explore the API">
    Read the [API Reference](/en/api-reference/overview) for Pulse, Chat, and MCP endpoints.
  </Step>

  <Step title="Add custom providers or tools">
    Use [Provider Integration](/en/development/provider-integration) for new devices, or just drop a Python file into `tools/`.
  </Step>
</Steps>

## Contributing

We welcome contributions — new providers, new tools, framework improvements, anything.

<CardGroup cols={2}>
  <Card title="GitHub Repository" icon="github" href="https://github.com/thetahealth/mirobody">
    Source code, issues, and PRs
  </Card>

  <Card title="Contributing Guide" icon="code-pull-request" href="/en/development/contributing">
    How to submit changes
  </Card>
</CardGroup>

## Community & Support

<CardGroup cols={2}>
  <Card title="Discord" icon="discord">
    Community discussions (coming soon)
  </Card>

  <Card title="GitHub Issues" icon="bug" href="https://github.com/thetahealth/mirobody/issues">
    Bug reports and feature requests
  </Card>

  <Card title="Mirobody Support" icon="envelope" href="mailto:developer@thetahealth.ai">
    Direct technical support
  </Card>
</CardGroup>

<Note>
  This docs site covers Mirobody's **health vertical**. For the open-source engine repo, see <a href="https://github.com/thetahealth/mirobody">github.com/thetahealth/mirobody</a>.
</Note>
