How yastech722/soapdocs works
SOAPDocs is a desktop consultation assistant: users can enter or record/upload a conversation, process audio into a speaker-attributed transcript, and use the consultation screen for note generation and transcript revision. A separate encounter screen answers questions over JSON documents using retrieval-augmented generation. The excerpts show the RAG query path and transcript-revision call; parts of the chat screen are omitted, so links for its note-generation and audio-processing workflow reflect the documented screen responsibilities and imports rather than inspected call sites.
Main entry points: chatscreen.py Consultation screen · RAG.py Retrieval and answering · NoteGenerator.py SOAP generation and revision · main.py Window and navigation
Components 13
Desktop app
- Window and navigation
main.py
Consultation workflow
- Consultation screen
Screens/chatscreen.py - Audio capture
utils/audio_recorder.py - Transcription and diarization
utils/speech_to_text.py - SOAP generation and revision
utils/NoteGenerator.py
Document Q&A
- Encounter Q&A screen
Screens/encounterscreen.py - Retrieval and answering
utils/RAG.py
Local data
- JSON source documents
doc/generated-notes.json - Chroma index
db/chroma.sqlite3
Other components
- User
- Ollama models
- Microphone
- Selected audio
Connections 20
- User → Window and navigation: opens
- Window and navigation → Consultation screen: shows session
- Window and navigation → Encounter Q&A screen: opens history
- User → Consultation screen: enters dialogue
- Consultation screen → Audio capture: starts capture
- Microphone → Audio capture: provides audio
- User → Selected audio: selects audio
- Consultation screen → Transcription and diarization: processes audio
- Audio capture → Consultation screen: supplies recording
- Selected audio → Consultation screen: supplies audio
- Consultation screen → SOAP generation and revision: revises transcript
- Consultation screen → SOAP generation and revision: requests SOAP note
- SOAP generation and revision → Ollama models: calls model
- SOAP generation and revision → JSON source documents: writes notes
- User → Encounter Q&A screen: asks question
- Encounter Q&A screen → Retrieval and answering: queries
- Retrieval and answering → JSON source documents: loads JSON
- Retrieval and answering → Chroma index: builds index
- Retrieval and answering → Ollama models: embeds and answers
- Retrieval and answering → Chroma index: searches chunks