
health-os
io.github.andronaft由 GitHub 账号 andronaft 发布v0.3.0更新于 Oct 24, 2026
Local-first personal health record: labs, meds, wearables, food log, deterministic safety checks
发布方自己的服务:Health OS
概览
本地优先的个人健康记录 MCP 服务器:化验、用药、穿戴设备与饮食记录存于自建 Postgres,并带确定性安全检查。
- 可以做什么
- 从 PDF 或照片导入化验单,规范化名称与单位,并逐行批准或拒绝待审记录
- 读取与更新健康记录:化验、诊断、用药、穿戴设备导入与饮食日志
- 生成趋势、异常检测、筛查日历、周报与就诊简报
- 对危急值给出确定性告警,并提供固定的危机与药物相互作用回应
- 记录餐食的 41 项营养画像、RDA 百分比与缺乏或过量标记
- 适用场景
- 适合希望助手在本机查询和维护个人健康数据的人,例如询问 LDL 趋势、待审化验结果或本周营养缺口,同时把数据库留在自己机器上。
- 运行要求
- 以本地 Docker 容器通过 stdio 运行。完整安装需要 Docker 与 Python 3.12+、一个 PostgreSQL 16 + pgvector 数据库(需先执行迁移与种子数据),以及 DATABASE_URL 连接串;建议另设 READONLY_DATABASE_URL 用于只读 SQL。另提供含虚构患者的一键演示。
安装
在 SourceWeft 中
- 打开 控制台中的 health-os,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
health-os
[tests] [Listed on mcpservers.org]
Local-first personal health record, exposed over MCP. Your labs, diagnoses, medications, wearable data and food log live in your own Postgres; any MCP client — one running a local model or a cloud assistant — can read and update them through guarded tools. Critical values, drug-safety rules and screening schedules are deterministic code, not LLM judgement.
[An MCP session with the demo patient: LDL trend and the pending-review queue]
Medical disclaimer. This is not a medical device and does not give medical advice. Critical-value alerts and screening reminders are only a signal to contact a doctor — never a diagnosis and never a reason to delay care. Use at your own risk.
What it does
- Lab results — drop a PDF or photo into your MCP client; the model extracts the values, health-os normalizes names (uk/ru/en/Latin synonyms) and units, and stages the panel as pending. Nothing counts as fact until you approve it.
- Safety net in code — critical values alert immediately (log, macOS notification, optional Telegram); critical findings in narrative reports are flagged; drug-interaction questions are refused and redirected to a doctor/pharmacist (only deterministic checks run: total daily paracetamol across products, biotin before lab tests); a crisis tool returns a fixed response with hotlines, independent of the model.
- Trends and analytics — Mann-Kendall trends with a per-year slope, anomalies against your
own baseline (
get_anomalies), a screening calendar, a weekly report, a doctor-visit brief. Risk calculators (SCORE2, ASCVD, FRAX) so far only enforce their validated age range; the formulas aren't implemented yet. - Food log — meals with a 41-nutrient profile, %RDA, deficiency/excess flags, meal templates.
- Devices — Apple Health export and Garmin import.
- 38 MCP tools + server instructions — the safety rules are sent to every client on connect; see mcp_server/README.md.
Try it in one command
Only Docker needed. Starts a throwaway database with a fictional patient — two years of labs (LDL creeping up), blood pressure, medications, a food log and a lab panel awaiting approval:
Point your MCP client at it:
Ask "show my health summary", "is my LDL trending up?", "what's pending review?",
"what am I short on nutritionally?". Remove it all with make demo-down.
Install for your own data
Requires Docker and Python 3.12+.
Then connect an MCP client — config for LM Studio, Open WebUI, Ollama CLI and Claude is in mcp_server/README.md. Try: "show my health summary", "LDL trend", "what am I short on nutritionally this week?".
Local models: the server speaks standard MCP over stdio, so any MCP client that runs a local model can use it. Verified so far: the server itself with the official MCP Python client (CI + the Docker demo). Not yet verified end-to-end with a local model — see #9; reports welcome.
Browser UI (preview)
Starts a local, read-only web page on 127.0.0.1:8765 (port: UI_PORT in .env) and opens it
with this run's session link. Only this machine can reach it: the server listens on 127.0.0.1,
refuses requests with a foreign Host, and its API answers only GET requests that carry the
session token. So far the page only shows whether it is connected to the server and the
health-os version — the data pages come in 0.4.0
(milestone).
How it works
A lab result, from report to fact
Every row of a staged panel ends up pending — nothing becomes a fact without an explicit approve. A row the catalog can't place is kept, not dropped:
[How a lab result row moves from stage_lab_panel through pending states to approved]
Unmapped and pending rows show up in list_pending_reviews and in the health summary's
"awaiting review" block; a learned name maps automatically on the next panel.
Privacy / local-first
- Your data stays in your own database. Postgres runs locally in Docker;
data/and.envare outside git. Nothing is sent anywhere by health-os itself. - What leaves the machine depends on the MCP client you connect. With a local model (LM Studio, Open WebUI + Ollama, …) nothing does. With a cloud assistant, whatever the tools return is sent to that provider — use one whose terms fit medical data (no training on your data, zero/short retention).
- The goal is fully local: local models for chat and extraction, local embeddings for search (already supported via fastembed). Cloud clients remain optional.
- Optional alert channel (Telegram) sends only a generic "check your health system" text, never values.
- Encrypt the disk (FileVault / LUKS / BitLocker) — the database files are plaintext at rest.
- Never put real medical data in issues, PRs or tests — synthetic data only.
Tests
Integration tests never touch the working database: tests/conftest.py drops and recreates
<POSTGRES_DB>_test on the same server (migrations + seed) on every run. Override with
TEST_DATABASE_URL (the name must end in _test). Without Postgres, integration tests are
skipped locally; CI sets REQUIRE_DB=1 so they fail instead.
Development history: PROGRESS.md.
License
AGPL-3.0-or-later. You may use, modify and fork health-os; if you distribute it or run a modified version as a network service, you must publish your source under the same license.
Want to use it in a closed-source or commercial product without those obligations? A separate commercial license is available from the author — reach out via GitHub (@andronaft).
Contributions are welcome — see CONTRIBUTING.md (includes a short CLA).
来源:README.md,提交 fbcdf5c
工具
0版本历史
3- v0.3.0最新Oct 18, 2026
- v0.2.1Oct 1, 2026
- v0.2.0Sep 30, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分