A privacy-first experiment in clinical documentation
A local AI system for automating clinical case notes. All processing happens on your machine—no data leaves your computer.
Read the full story behind this project
This tool automates the formatting of clinical case notes using on-device LLMs. Instead of recording sessions live (which creates privacy concerns and shifts the therapeutic dynamic), you record your own reflections after the session and have them structured by a local AI.
The pipeline:
- Record your post-session reflections as an audio file
- Transcribe using on-device transcription (Mac Whisper)
- Process through a local LLM prompt chain (LM Studio)
- Review the structured case note in your Obsidian vault
- Privacy: Client data never leaves your machine
- Security: No supply-chain vulnerabilities from cloud APIs
- Therapeutic Integrity: No "AI in the room" during sessions
- File Over App: Your data stays in universal formats (Markdown) that you control
- macOS (for Quick Action integration)
- Python 3.8+
- LM Studio running locally
requestsandPyYAMLlibraries
Tested with:
- Model: Gemma 3 27B (via LM Studio)
- Hardware: MacBook Pro M1 Max, 32GB RAM
- Clone this repository
- Install Python dependencies:
pip install requests pyyaml
- Configure LM Studio to run locally on
http://localhost:1234 - Edit
config_example.yamland save asconfig.yaml - Customize the prompts in
Prompts/to match your clinical voice
Organise client files within an encrypted Obsidian vault:
/Volumes/Clients/ # Encrypted macOS volume
└── Client Name/ # Template for each client
├── Documents/ # Intake forms, assessments
├── Representations/ # Client-created content
├── Transcriptions/ # Voice-recorded summaries
│ ├── S1 - Transcription.md # ← Input
│ └── S2 - Transcription.md
├── S1 - Case Note.md # ← Output
└── S2 - Case Note.md
- Do the session (no recording, no AI present)
- Immediately after: Voice-record a rough summary using Mac Whisper
- Drop the transcription into your Obsidian vault at
S1 - Transcription.md - Right-click → Quick Actions → Generate Case Note (runs the Python script)
- Review and edit the output in
S1 - Case Note.md
The system uses a 2-step prompt chain:
- Main Body (
Prompts/main_body.md): Generates the narrative case note - Dot Points (
Prompts/dot_points.md): Extracts themes, goals, and next session plans
Chunking prompts to specific tasks improves output quality, adherence, and speed. You'll need to tailor these to your own clinical voice—expect to iterate 3-5 times before landing on something usable.
AI can manage the formatting. Not the reflecting.
The act of recalling and verbalising the session is where clinical synthesis happens. This tool automates what comes after—the administrative slog that pulls you out of clinical headspace.
- Requires comfort with local LLM setup
- macOS-specific Quick Actions integration
- Prompts tuned to a collaborative, non-directive, Australian English therapeutic voice
- No error handling to speak of
- Working prototype, not production software
Important: This is not a medical device. You are responsible for reviewing all output for clinical accuracy.
MIT — use freely, modify, share.
How this was made: This code was "vibe coded"—written through conversation with AI assistants (Roo Code and Claude Code). My contribution is the structure and prompt chains, which I hand-wrote and tested against my preferred clinical outcomes. The AI handled the Python syntax.
Built by a therapist using AI tools, not a coder learning therapy. Expect rough edges and thoughtful intentions.