Case study · Own product · In progress

Practio: one platform for the whole practice

Own product: clinics, therapists and patients in one platform, on the web and on mobile. Scheduling, messaging, journals, clinic pages and clinical frameworks where AI only proposes.

Client
Own product · psychotherapy
Role
Founder and sole engineer
Stack
TypeScript · React · oRPC · SST (AWS)

Context

Practio is my own product: everything a psychotherapy practice needs, in one platform, for three sides at once, on the web and on mobile. It is not in production yet. This page marks what is built and what is still a design, part by part.

  • Patients find a therapist, book a visit, message their therapist and keep a journal, deciding who can see it.
  • Therapists run their calendar, availability across locations, prices, patients and documentation.
  • Clinics run the team, the reception inbox, the whole clinic’s calendar and their own public page, edited block by block.

Designed, built and run by one person: about 1,800 commits since December 2025, a database of around 60 schema files and 71 migrations, split into domain packages (scheduling, marketplace, clinic, journal, messaging, clinical and more). The screens below come from a local build with fictional demo data.

The clinical core

The deepest part of the product is how therapists document their work. Therapists work in different modalities: cognitive behavioural, systemic, psychodynamic. Each of them documents a session differently and works with different tools: a thought record, a genogram, a timeline, a scale tracked week by week.

Problem

One fixed note format fits nobody. A CBT therapist and a psychodynamic one need different sections and different tools, and every therapist adjusts their own way of working over time.

AI makes it harder, not easier. A model can draft a note from a session, but a clinical record is the therapist’s responsibility, so the model cannot be allowed to write into it.

What is built: frameworks

A framework describes how a therapist works with a patient: its intent, the artifacts it uses, the measures, how often they are filled in. Artifacts are built from 12 primitives, such as a note section, a structured table, a cycle diagram, a genogram, a scale tracker or a timeline.

  • Presets, then your own version. Practio comes with presets (CBT, systemic, psychodynamic and a minimal one). A therapist forks a preset and changes it.
  • Versions, not edits. A saved framework definition never changes. Editing it creates the next version, and the API reports which patients are still on an older one, so moving them is a deliberate step.
  • One active framework per patient. Switching archives the old one; nothing is deleted.
  • Content validated per primitive. Each primitive has its own Zod schema in a shared package, used by the client and the server.

Built in the API and the database, with integration tests. The screens for it are still prototypes on sample data.

AI proposes, the therapist decides

The rule is in the data model: the AI never changes a document. It writes a proposal (add, update, append or relabel), each with the fragments of the session it comes from. The therapist accepts or rejects it. An accepted proposal is applied by a pure function and written to an append-only history, which records whether a change came from the therapist or from an accepted proposal. Rejected proposals are kept for audit and, later, for evaluating the model.

A change to a clinical document

01 · Session

Recording and transcription are designed, not built yet.

  1. 01 · Session Recording and transcription are designed, not built yet.
  2. 02 · PII anonymisation Names and other personal details are replaced before any text reaches a model, so the model works on the session without knowing who it is about.
  3. 03 · AI proposal The model writes a proposal with the fragments of the session it is based on. It never edits the document itself. Proposals exist in the data model today; the model that creates them is planned.
  4. 04 · Therapist review The therapist accepts or rejects each proposal. Rejected ones are kept, not deleted.
  5. 05 · Apply An accepted proposal is applied by a pure function from the shared package, so the same logic can run anywhere and is easy to test. Built for the first artifact types.
  6. 06 · History Every change is recorded with who made it: the therapist, or an accepted proposal.
  7. 07 · Encryption Clinical documents and their history are stored encrypted.

Built: AI Studio, the no-code note editor

A therapist defines their own session note without code. AI Studio is built in the app and is not public yet.

  • A note is an ordered list of sections. Each section is drafted by AI, written by the therapist, or private (never sent to AI and never exported). Risk is always written by the therapist. For an AI section the therapist says in plain language what to include and what not to write, and picks the length and the form (prose or bullets). Sections are reordered by dragging.
  • Three ways to start. A Practio preset (CBT, systemic, psychodynamic or minimal), the therapist’s own form pasted from Word (its headings become sections), or an empty template.
  • Tested before it goes live. A draft runs on synthetic sessions with fixed transcripts, five from Practio and the therapist’s own, beside the active version. Every sentence of the result cites its stretch of the transcript; the therapist rates each section and compares the two versions side by side.
  • Published versions do not change. Activating a version changes only future notes; approved notes keep the version that produced them. An older version can be restored as a new draft.
  • What it produces is a proposal. The note sections and the framework artifacts go through the same rule as above: the therapist accepts them before they become part of the record.

Decisions & trade-offs

  1. The AI only proposes

    A clinical record is the therapist’s responsibility. Proposals with their sources, accepted one by one, keep the therapist the author and leave a trail of every change.

    TRADE-OFF More clicks for the therapist than a note that fills itself in

  2. A new version instead of editing a framework in place

    A patient’s documentation always matches the framework version it was written in.

    TRADE-OFF Patients on an older version have to be moved deliberately

  3. Clinical content as JSON in PostgreSQL, for now

    Simpler while there is no real data yet. The logic that changes the documents is written as pure functions, so the storage can move later without rewriting it.

    TRADE-OFF Large documents live in the database instead of object storage

  4. Keep rejected proposals

    A rejected proposal is evidence of what the model got wrong, which is exactly what a later evaluation needs.

    TRADE-OFF More data to store

Status

Practio is not launched yet, so there are no numbers from production. Built: the flows for patients, therapists and clinics shown above; AI Studio, the no-code note editor; in the clinical core, frameworks with versions and presets, the proposal and review model, in the API and the database, with integration tests. Designed and prototyped: the framework screens. Planned: recording, transcription, PII anonymisation before the model, the AI that writes the proposals, and encryption of clinical documents.

Stack

  • TypeScript
  • React
  • oRPC
  • SST (AWS)
  • PostgreSQL
  • Drizzle
  • Zod
  • AWS Lambda
  • React Native
  • Expo

Contact

Facing something similar?

Book a call Write to hello@paxcode.it