Personal health records · Public source · Self-hosted

PHR: keeping the evidence attached to the record

A patient-centered record system that connects clinical information with its source documents and medical imaging. The design makes evidence, review, patient-scoped access, and data portability part of the product rather than afterthoughts.

A record is easier to trust when the source is still available.

PHR is a patient-centered application for organizing longitudinal medical information. It combines structured clinical records, source documents, and medical imaging. The interesting engineering problem is not simply how to put those things into one database. It is how to let them work together without losing the distinctions between evidence, interpretation, and a reviewed record.

A document and a clinical fact are different objects

A document might describe a medication, a procedure, or a laboratory result. Turning it into structured data makes the information easier to search and compare, but it introduces a new interpretation of the source.

In PHR, supporting documents remain separate artifacts, with relationships connecting them to the records derived from them. The record can become useful without replacing the evidence that produced it.

This distinction also shapes the interface. A useful record view should help someone move from a summary to the underlying material, not force them to choose between a searchable database and an unstructured folder of files.

The general design principle is straightforward: make the interpretation useful, but keep it inspectable.

Review is a state transition

A machine-generated clinical record should not acquire authority merely because it passed schema validation.

PHR's documented agent-write workflow makes that distinction explicit. New agent-created clinical records enter a pending-review state. An effective agent edit returns a record to review, while an exact replay does not undo a human decision. The agent cannot set the record's review status to confirmed through the write API.

That matters because retries, edits, and review are different operations. A successful retry should settle uncertainty about whether a write happened. It should not reopen an unchanged record or silently grant it a stronger status.

Clinical exports are documented as using confirmed records. Native backups deliberately preserve the fuller state, including information that does not belong in a clinical summary. This is a useful example of the same stored data requiring different publication rules for different purposes.

The patient is the access boundary

The application can be used through the browser, an external API, and an MCP integration. Those are different interfaces to the product, not different definitions of who is allowed to see a patient's information.

PHR centralizes patient access in a shared service. The external API adds OAuth scopes, but the existence of a scope does not replace access to the particular patient. MCP delegates to the versioned API rather than creating a shortcut to the underlying models.

My preference is to make a new interface inherit existing product rules before adding capabilities to it. Otherwise, integration work becomes an opportunity to accidentally create a second, weaker application.

This is an architectural intention backed by documented controls, not a claim that the system has received an independent security certification.

A portable summary is not a full backup

PHR separates interoperable summaries from application-preserving archives.

C-CDA, FHIR, and PDF exports serve the purpose of exchanging selected clinical information. The native archive serves a different purpose: retaining application-specific relationships and original files for backup and restore.

Treating these as separate products avoids a misleading promise. A file can be useful for exchange without being sufficient to rebuild an application. Conversely, a complete backup is not necessarily the right artifact to share with another person or system.

I would rather explain those two purposes clearly than put an ambiguous “Export everything” button in the interface.

The broader lesson

The most important boundaries in a records product are not always between services or databases. They are also between what was observed and what was inferred, what was written and what was reviewed, and what can be stored and what should be shared.

Making those distinctions explicit gives the product a clearer explanation of its own behavior. That is the part of PHR I would want a case study to make visible.

Availability and limits: PHR's source is available for self-hosting. This page does not offer public hosted signup or a HIPAA-compliant service. Suitability for any particular deployment requires its own review.

Source notes

This case study is grounded in the public PHR README and agent-API security documentation, first reviewed on 22 September 2026 and rechecked against commit 2ce7886 in November 2026.