pyscribe-app 2.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pyscribe_app-2.0.0/LICENSE +21 -0
- pyscribe_app-2.0.0/PKG-INFO +279 -0
- pyscribe_app-2.0.0/README.md +223 -0
- pyscribe_app-2.0.0/pyproject.toml +352 -0
- pyscribe_app-2.0.0/pyproject.toml.orig +296 -0
- pyscribe_app-2.0.0/src/pyscribe/__init__.py +5 -0
- pyscribe_app-2.0.0/src/pyscribe/__main__.py +4 -0
- pyscribe_app-2.0.0/src/pyscribe/app.py +153 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/backend.py +75 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/coretap.py +139 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/importer.py +80 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/macos.py +10 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/mixdown.py +26 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/monitor.py +150 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/owned.py +43 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/platform.py +30 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/portaudio.py +93 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/pulse.py +130 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/recorder.py +554 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/split.py +19 -0
- pyscribe_app-2.0.0/src/pyscribe/audio/wasapi.py +96 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/devices.py +42 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/errors.py +2 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/formats.py +9 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/jobs.py +79 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/notes.py +99 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/runs.py +72 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/timeline.py +125 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/transcript.py +149 -0
- pyscribe_app-2.0.0/src/pyscribe/domain/transcription.py +161 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/__init__.py +15 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/api.py +42 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/audio_io.py +107 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/cuda_libs.py +36 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/diarize.py +53 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/hub.py +70 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/models.py +76 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/parakeet.py +41 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/pipeline.py +71 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/process.py +118 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/runtime.py +31 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/tokens.py +24 -0
- pyscribe_app-2.0.0/src/pyscribe/engine/whisper.py +64 -0
- pyscribe_app-2.0.0/src/pyscribe/jobs/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/jobs/manager.py +332 -0
- pyscribe_app-2.0.0/src/pyscribe/jobs/protocol.py +57 -0
- pyscribe_app-2.0.0/src/pyscribe/jobs/remote.py +350 -0
- pyscribe_app-2.0.0/src/pyscribe/jobs/runners.py +102 -0
- pyscribe_app-2.0.0/src/pyscribe/py.typed +0 -0
- pyscribe_app-2.0.0/src/pyscribe/storage/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/storage/atomic.py +58 -0
- pyscribe_app-2.0.0/src/pyscribe/storage/instance.py +66 -0
- pyscribe_app-2.0.0/src/pyscribe/storage/runs.py +277 -0
- pyscribe_app-2.0.0/src/pyscribe/storage/settings.py +120 -0
- pyscribe_app-2.0.0/src/pyscribe/summary/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/summary/claude_cli.py +200 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/controller.py +525 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/dialogs.py +40 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/formatting.py +63 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/native.py +34 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/page.py +1078 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/ports.py +19 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/security.py +35 -0
- pyscribe_app-2.0.0/src/pyscribe/ui/theme.py +176 -0
- pyscribe_app-2.0.0/src/pyscribe/worker/__init__.py +1 -0
- pyscribe_app-2.0.0/src/pyscribe/worker/server.py +252 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Tobias Würth
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,279 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: pyscribe-app
|
|
3
|
+
Version: 2.0.0
|
|
4
|
+
Summary: Record microphones and system audio, transcribe meetings on your own machine, summarize with Claude.
|
|
5
|
+
Keywords: transcription,speech-to-text,whisper,speaker-diarization,meeting-notes,audio-recording,obsidian,apple-silicon
|
|
6
|
+
Author: Tobias Würth
|
|
7
|
+
License-Expression: MIT
|
|
8
|
+
License-File: LICENSE
|
|
9
|
+
Classifier: Development Status :: 4 - Beta
|
|
10
|
+
Classifier: Environment :: GPU :: NVIDIA CUDA
|
|
11
|
+
Classifier: Environment :: Web Environment
|
|
12
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
13
|
+
Classifier: Natural Language :: English
|
|
14
|
+
Classifier: Natural Language :: German
|
|
15
|
+
Classifier: Operating System :: MacOS
|
|
16
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
17
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
18
|
+
Classifier: Programming Language :: Python :: 3
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Classifier: Topic :: Multimedia :: Sound/Audio :: Capture/Recording
|
|
21
|
+
Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
|
|
22
|
+
Classifier: Typing :: Typed
|
|
23
|
+
Requires-Dist: av>=14
|
|
24
|
+
Requires-Dist: ctranslate2>=4.9
|
|
25
|
+
Requires-Dist: fastapi>=0.165
|
|
26
|
+
Requires-Dist: httpx2>=2.16
|
|
27
|
+
Requires-Dist: huggingface-hub>=2.4
|
|
28
|
+
Requires-Dist: nicegui>=4.1,<5
|
|
29
|
+
Requires-Dist: opentelemetry-api<1.46
|
|
30
|
+
Requires-Dist: numpy>=2
|
|
31
|
+
Requires-Dist: platformdirs>=4.3
|
|
32
|
+
Requires-Dist: pyaudiowpatch>=0.2.12.9 ; sys_platform == 'win32'
|
|
33
|
+
Requires-Dist: pydantic>=2.10
|
|
34
|
+
Requires-Dist: python-multipart>=0.0.20
|
|
35
|
+
Requires-Dist: pywebview>=6
|
|
36
|
+
Requires-Dist: pywebview[pyside6]>=6 ; sys_platform == 'linux'
|
|
37
|
+
Requires-Dist: catap>=0.6.2 ; sys_platform == 'darwin'
|
|
38
|
+
Requires-Dist: sounddevice>=0.5 ; sys_platform == 'darwin'
|
|
39
|
+
Requires-Dist: soundcard>=0.4.6 ; sys_platform == 'linux'
|
|
40
|
+
Requires-Dist: soundfile>=0.13
|
|
41
|
+
Requires-Dist: starlette>=1.10
|
|
42
|
+
Requires-Dist: uvicorn>=0.32
|
|
43
|
+
Requires-Dist: faster-whisper>=1.2.1
|
|
44
|
+
Requires-Dist: nvidia-cublas-cu12>=12.6 ; (platform_machine == 'x86_64' and sys_platform == 'linux') or (platform_machine == 'AMD64' and sys_platform == 'win32')
|
|
45
|
+
Requires-Dist: onnx-asr[hub]>=0.12
|
|
46
|
+
Requires-Dist: pyannote-audio>=4.1.1
|
|
47
|
+
Requires-Dist: torch>=2.11
|
|
48
|
+
Requires-Dist: torchaudio>=2.11
|
|
49
|
+
Requires-Dist: transformers>=4.57
|
|
50
|
+
Requires-Python: >=3.12, <3.13
|
|
51
|
+
Project-URL: Homepage, https://github.com/tobiaswuerth/pyscribe
|
|
52
|
+
Project-URL: Source, https://github.com/tobiaswuerth/pyscribe
|
|
53
|
+
Project-URL: Issues, https://github.com/tobiaswuerth/pyscribe/issues
|
|
54
|
+
Project-URL: Changelog, https://github.com/tobiaswuerth/pyscribe/blob/main/CHANGELOG.md
|
|
55
|
+
Description-Content-Type: text/markdown
|
|
56
|
+
|
|
57
|
+
# PyScribe
|
|
58
|
+
|
|
59
|
+
PyScribe records any mix of microphones and speakers (system audio) and transcribes the recording
|
|
60
|
+
on your own computer or a GPU worker, with speakers separated. Claude can summarize and title it;
|
|
61
|
+
the result copies as plain text or as a Markdown note. Tuned for German (including Swiss German)
|
|
62
|
+
and English. Windows, macOS 14.2+ (Apple Silicon) and Linux.
|
|
63
|
+
|
|
64
|
+

|
|
65
|
+
|
|
66
|
+
## Install
|
|
67
|
+
|
|
68
|
+
Install it with [uv](https://docs.astral.sh/uv/), which also fetches the Python 3.12 that
|
|
69
|
+
PyScribe needs. Windows, Linux and Apple Silicon Macs are supported; Intel Macs are not, as
|
|
70
|
+
PyTorch, ONNX Runtime and TorchCodec publish no current builds for them. The commands in this
|
|
71
|
+
file are the same in PowerShell, bash and zsh unless noted.
|
|
72
|
+
|
|
73
|
+
```sh
|
|
74
|
+
uv tool install --python 3.12 --torch-backend auto pyscribe-app
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
Then start it with `pyscribe`. To update, run the install line again with `--upgrade` at the end,
|
|
78
|
+
so that the PyTorch build for your computer is chosen again (uv does not record
|
|
79
|
+
`--torch-backend` for `uv tool upgrade`). To remove it: `uv tool uninstall pyscribe-app`
|
|
80
|
+
(recordings, settings and models stay; see [Files](https://github.com/tobiaswuerth/pyscribe#files)).
|
|
81
|
+
|
|
82
|
+
`--torch-backend auto` installs the CUDA build of PyTorch on computers with an NVIDIA GPU and the
|
|
83
|
+
CPU build elsewhere. On Windows and Linux, PyScribe also brings NVIDIA's cuBLAS for CUDA 12, which
|
|
84
|
+
the Whisper models need on the GPU. Without a GPU (and on macOS), set **Device** to *Processor
|
|
85
|
+
(CPU)* before the first transcription, or use a [remote worker](https://github.com/tobiaswuerth/pyscribe#remote-worker).
|
|
86
|
+
|
|
87
|
+
| OS | Microphones | Speakers (system audio) | Needs |
|
|
88
|
+
|---|---|---|---|
|
|
89
|
+
| Windows | WASAPI, shared mode | WASAPI loopback | nothing |
|
|
90
|
+
| macOS 14.2+, Apple Silicon | Core Audio | Core Audio taps | microphone and *System Audio Recording* permission when asked |
|
|
91
|
+
| Linux | PulseAudio / PipeWire | monitor sources | PulseAudio or PipeWire (`pipewire-pulse`); Qt for the window |
|
|
92
|
+
|
|
93
|
+
PyScribe never takes a device exclusively: Teams, Zoom and other apps keep using the same
|
|
94
|
+
microphone. A device that drops out (unplugged, or reset when a call starts) is reopened every
|
|
95
|
+
2 seconds and its track continues.
|
|
96
|
+
|
|
97
|
+
## Start
|
|
98
|
+
|
|
99
|
+
```sh
|
|
100
|
+
pyscribe # desktop window
|
|
101
|
+
pyscribe --mode browser # in the web browser; file and folder pickers become text fields
|
|
102
|
+
pyscribe --mode server --port 8080 # serve on localhost only, open nothing
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
`--settings <file>` uses another settings file; one PyScribe runs per settings file.
|
|
106
|
+
|
|
107
|
+
## Use
|
|
108
|
+
|
|
109
|
+
1. **Devices** (right pane): every microphone and speaker shows a live level meter. Click the ones
|
|
110
|
+
to record, also during a recording; the refresh button finds newly plugged devices.
|
|
111
|
+
2. **Record**, **Pause**/**Resume**, **Stop**. Each device is written to its own FLAC track, all
|
|
112
|
+
on one clock; a device added later starts with silence so its track lines up.
|
|
113
|
+
3. **Transcribe** starts by itself after **Stop** (setting *Transcribe automatically*). The arrow
|
|
114
|
+
next to it picks another model for this recording; **Abort** stops a job at once.
|
|
115
|
+
4. **The recording** (middle pane): edit its title; see status, length, words, speakers and audio
|
|
116
|
+
size; then **Summarize**, **Copy text**, **Copy Markdown**, **Delete audio** (keeps the
|
|
117
|
+
transcript) or **Delete** (both ask first, neither can be undone). The upload button above the
|
|
118
|
+
recordings adds an existing audio or video file.
|
|
119
|
+
|
|
120
|
+
All tracks are mixed before transcription; voices are numbered by first appearance:
|
|
121
|
+
|
|
122
|
+
```
|
|
123
|
+
[00:00:03] Speaker 1: Grüezi mitenand, wir beginnen mit dem Budget.
|
|
124
|
+
[00:00:09] Speaker 2: Danke. Ich habe zwei Fragen dazu.
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
**Copy Markdown** gives title, summary and transcript with YAML front matter (date, duration,
|
|
128
|
+
speakers, words, language, model, tags), ready to paste into Obsidian.
|
|
129
|
+
|
|
130
|
+
## First run
|
|
131
|
+
|
|
132
|
+
- **Models** download with the first transcription, 0.7 to 6.2 GB each; the start screen says
|
|
133
|
+
which and how big.
|
|
134
|
+
- **Speaker separation** uses [pyannote speaker-diarization-community-1](https://huggingface.co/pyannote/speaker-diarization-community-1),
|
|
135
|
+
which needs a free Hugging Face token. *Setup needed* in the header leads to the steps: create
|
|
136
|
+
an account, accept the model's terms, create a Read token, paste it, **Check and save**. The
|
|
137
|
+
token is stored where Hugging Face's own tools look (`HF_TOKEN` also works). Or turn off
|
|
138
|
+
*Separate speakers*.
|
|
139
|
+
- **Summaries** run through [Claude Code](https://claude.com/claude-code): install it and run
|
|
140
|
+
`claude` once to log in. PyScribe calls it with no tools, no MCP servers and no saved session,
|
|
141
|
+
capped at USD 2 per summary; the transcript goes to Anthropic. A summary has sections for
|
|
142
|
+
summary, decisions, action items and open questions, and titles an untitled recording.
|
|
143
|
+
|
|
144
|
+
## Privacy
|
|
145
|
+
|
|
146
|
+
Recording, transcription and speaker separation run on your computer. What leaves it:
|
|
147
|
+
|
|
148
|
+
- Model downloads from Hugging Face on first use, and the check of your Hugging Face token against
|
|
149
|
+
the speaker model's terms.
|
|
150
|
+
- The transcript, to Anthropic, only when you press **Summarize** (through Claude Code).
|
|
151
|
+
- The audio, to your own worker, only if **Transcribe on** is *Remote worker*.
|
|
152
|
+
|
|
153
|
+
Nothing else; the telemetry of ONNX Runtime and pyannote is switched off.
|
|
154
|
+
|
|
155
|
+
## Settings
|
|
156
|
+
|
|
157
|
+
| Setting | Meaning |
|
|
158
|
+
|---|---|
|
|
159
|
+
| Save folder | where recordings go (default `Documents/PyScribe`) |
|
|
160
|
+
| Transcribe on | *This PC* or *Remote worker* (URL and token) |
|
|
161
|
+
| Device | *Graphics card (GPU)* or *Processor (CPU)* of the computer that transcribes; Parakeet always uses the CPU |
|
|
162
|
+
| Language, Model | German or English and one of its models, see below |
|
|
163
|
+
| Separate speakers | name voices Speaker 1, 2, … (pyannote counts them) |
|
|
164
|
+
| Transcribe automatically after recording | start a job when a recording stops or a file is added |
|
|
165
|
+
| Claude model | Haiku (fast, cheap) or Sonnet (more thorough) for summaries |
|
|
166
|
+
|
|
167
|
+
## Models
|
|
168
|
+
|
|
169
|
+
Word error rate (WER) and speed of PyScribe's pipeline (batched, with voice detection) on FLEURS
|
|
170
|
+
dev clips, normalised for case and punctuation (and ß as ss). GPU: 100 clips on an RTX 4090; CPU:
|
|
171
|
+
30 clips on an i9-14900K.
|
|
172
|
+
|
|
173
|
+
| Language | Preset | Model | WER | Speed (x real time) |
|
|
174
|
+
|---|---|---|---|---|
|
|
175
|
+
| German | `german-turbo` (default) | [primeline/whisper-large-v3-turbo-german](https://huggingface.co/primeline/whisper-large-v3-turbo-german) | 3.95 % GPU, 2.8 % CPU | 94 GPU, 2.9 CPU |
|
|
176
|
+
| German | `swiss-german` | [matildecs/whisper-large-stt4sg](https://huggingface.co/matildecs/whisper-large-stt4sg) | 6.0 % (Standard German) | 31 GPU |
|
|
177
|
+
| German | `parakeet-cpu` | NVIDIA Parakeet TDT 0.6B v3, int8 | 8.2 % | 14 CPU |
|
|
178
|
+
| English | `english-distil` (default) | [distil-whisper/distil-large-v3.5](https://huggingface.co/distil-whisper/distil-large-v3.5) | 4.24 % GPU, 6.7 % CPU | 107 GPU, 2.7 CPU |
|
|
179
|
+
| English | `english-parakeet` | NVIDIA Parakeet TDT 0.6B v2, int8 | 11.1 % | 12 CPU |
|
|
180
|
+
| both | `multilingual-large-v3` | OpenAI Whisper large-v3 | 4.26 % German, 4.10 % English | 31 GPU |
|
|
181
|
+
|
|
182
|
+
- `german-turbo` writes "ss" for "ß" (Swiss spelling). `swiss-german` writes dialect as Standard
|
|
183
|
+
German (about 20 % WER reported on dialect test sets).
|
|
184
|
+
- Parakeet is the option for slow computers. `english-parakeet` writes numbers as words and keeps
|
|
185
|
+
filler words, which FLEURS counts as errors.
|
|
186
|
+
- Tested, not adopted: Qwen3-ASR-1.7B (German 4.10 % at 6.6x, conflicting dependencies), Whisper
|
|
187
|
+
large-v3-turbo for English (4.44 %, slower than Distil), Parakeet v3 for English (14 %).
|
|
188
|
+
- FLEURS is read speech; meetings score worse with every model.
|
|
189
|
+
|
|
190
|
+
## Remote worker
|
|
191
|
+
|
|
192
|
+
On a computer with a GPU (installed as above):
|
|
193
|
+
|
|
194
|
+
```sh
|
|
195
|
+
export PYSCRIBE_WORKER_TOKEN="a long random secret" # bash, zsh
|
|
196
|
+
# PowerShell: $env:PYSCRIBE_WORKER_TOKEN = "a long random secret"
|
|
197
|
+
pyscribe-worker --host 0.0.0.0 # port 41738; --port and --data-dir change them
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
In PyScribe, set **Transcribe on** to *Remote worker*, enter the URL (for example
|
|
201
|
+
`http://gpu-box:41738`) and the token, and **Save**. PyScribe uploads the tracks, follows the job,
|
|
202
|
+
fetches the transcript and deletes the job on the worker. The API is plain HTTP with a bearer
|
|
203
|
+
token: use it on a trusted network or behind a TLS proxy or VPN. The token is stored in plain text
|
|
204
|
+
in the settings file.
|
|
205
|
+
|
|
206
|
+
## Files
|
|
207
|
+
|
|
208
|
+
| What | Where (Windows · macOS · Linux) | Owner and lifecycle |
|
|
209
|
+
|---|---|---|
|
|
210
|
+
| Recordings | `<save folder>/<YYYY-MM-DD_HH-MM-SS>/`: `NN-mic-….flac` / `NN-system-….flac` per track (added file: `01-audio.<ext>`), `recording.json`, `transcription.json`, `transcript.txt`, `transcript.json`, `notes.json` (title, summary) | Written by PyScribe; deleted from the app or by you. After a crash the audio up to the crash is kept and the recording shows as *Interrupted*. |
|
|
211
|
+
| Settings | `%LOCALAPPDATA%\PyScribe\settings.json` · `~/Library/Application Support/PyScribe/` · `~/.config/PyScribe/` | Written on every change; delete to reset. |
|
|
212
|
+
| Instance lock | `settings.lock` next to the settings file | Never written; the OS releases it when PyScribe exits, even after a crash. |
|
|
213
|
+
| Converted models | `%LOCALAPPDATA%\PyScribe\Cache\models` · `~/Library/Caches/PyScribe/models` · `~/.cache/PyScribe/models` | Written on first use of a preset that needs conversion; delete to convert again. |
|
|
214
|
+
| Downloaded models, Hugging Face token | `~/.cache/huggingface` | Managed by `huggingface_hub`. |
|
|
215
|
+
| Worker jobs | `worker` next to `models` in the cache folder above, on the worker | Deleted once the client fetched the result; finished jobs older than a day are purged when the next job arrives. |
|
|
216
|
+
|
|
217
|
+
## Limitations
|
|
218
|
+
|
|
219
|
+
- **Mixed languages:** Whisper may skip passages not in the chosen language.
|
|
220
|
+
- **No headset:** the microphone also hears the speakers, so remote voices are in the mix twice
|
|
221
|
+
with a slight delay. Recognition usually copes; a headset is cleaner.
|
|
222
|
+
- **Microphone indicator:** the level meters keep microphones open, so the OS shows "microphone in
|
|
223
|
+
use" while PyScribe runs. Nothing is stored unless you record.
|
|
224
|
+
- **No live transcript:** transcription starts when the recording stops.
|
|
225
|
+
- **macOS and Linux** capture is tested in CI against virtual devices (BlackHole, PulseAudio null
|
|
226
|
+
sinks); Windows also on real hardware.
|
|
227
|
+
|
|
228
|
+
## Troubleshooting
|
|
229
|
+
|
|
230
|
+
- **No GPU, or a CUDA error:** set **Device** to *Processor (CPU)*, or use a remote worker.
|
|
231
|
+
- **"cuBLAS 12 ... not installed"** (or `cublas64_12.dll` / `libcublas.so.12` not found): run the
|
|
232
|
+
install line again with `--reinstall` at the end.
|
|
233
|
+
- **"Setup needed" in the header:** speaker separation lacks its Hugging Face token; follow the
|
|
234
|
+
steps there, or turn off *Separate speakers*.
|
|
235
|
+
- **macOS records silence or nothing:** allow *Microphone* and *System Audio Recording* for the app
|
|
236
|
+
that started PyScribe (System Settings > Privacy & Security), then start PyScribe again.
|
|
237
|
+
- **Linux lists no devices:** PyScribe needs a PulseAudio or PipeWire server (`pipewire-pulse`);
|
|
238
|
+
`pactl info` must answer.
|
|
239
|
+
|
|
240
|
+
## Development
|
|
241
|
+
|
|
242
|
+
```sh
|
|
243
|
+
git clone https://github.com/tobiaswuerth/pyscribe.git
|
|
244
|
+
cd pyscribe
|
|
245
|
+
uv sync # CUDA PyTorch on Windows/Linux; CPU only: uv sync --no-group gpu --group cpu
|
|
246
|
+
uv run prek install # git hooks: checks on commit, the whole gate before push
|
|
247
|
+
uv run nox # the gate: hooks, types per OS, tests at 100 % line and branch coverage,
|
|
248
|
+
# each test file alone, lowest dependency versions, the built package
|
|
249
|
+
uv run nox -s fresh # the gate from a fresh clone (fresh-wsl: the same in WSL)
|
|
250
|
+
uv run nox -s audio # record from virtual devices (CI sets them up)
|
|
251
|
+
uv run nox -s smoke # end to end: real devices, GPU, CPU, remote worker, app server
|
|
252
|
+
uv run nox -s bench -- --language en # WER and speed of a language's presets
|
|
253
|
+
```
|
|
254
|
+
|
|
255
|
+
CI runs the gate sessions as jobs, the tests on Windows, macOS and Linux and real recordings on
|
|
256
|
+
macOS and Linux virtual devices, behind one required check.
|
|
257
|
+
Merging to `main` publishes to PyPI and creates the GitHub release once the top `CHANGELOG.md`
|
|
258
|
+
section has a date (`## 2.1.0 - 2026-12-24`, not in the future); `unreleased` does nothing. Each
|
|
259
|
+
step runs only if it is still missing, so the next run on `main` finishes one that failed.
|
|
260
|
+
A weekly run (`uv run nox -s highest`) tests the newest allowed versions of every dependency.
|
|
261
|
+
Rules for contributions: [CONTRIBUTING.md](https://github.com/tobiaswuerth/pyscribe/blob/main/CONTRIBUTING.md).
|
|
262
|
+
|
|
263
|
+
Code layout (`src/pyscribe`; dependencies point down only, enforced by import-linter):
|
|
264
|
+
|
|
265
|
+
| Package | Responsibility |
|
|
266
|
+
|---|---|
|
|
267
|
+
| `app.py` | composition root, command line |
|
|
268
|
+
| `ui/` | `controller.py` (all behaviour, no toolkit), `page.py` (NiceGUI view), `native.py` (window) |
|
|
269
|
+
| `worker/` | the remote worker's HTTP API |
|
|
270
|
+
| `jobs/`, `audio/`, `summary/` | job queue and remote client; capture per OS, recorder, level meters, file import; Claude Code summaries |
|
|
271
|
+
| `engine/`, `storage/` | decoding, ASR and diarization adapters in a killable process, Hugging Face access; run folders, settings, instance lock, atomic writes |
|
|
272
|
+
| `domain/` | pure logic: timeline, job states, model presets, transcript merge, notes |
|
|
273
|
+
|
|
274
|
+
Torch, faster-whisper, pyannote and onnx-asr load only inside the engine process; a test checks
|
|
275
|
+
that the app loads none of them.
|
|
276
|
+
|
|
277
|
+
## License
|
|
278
|
+
|
|
279
|
+
MIT, see [LICENSE](https://github.com/tobiaswuerth/pyscribe/blob/main/LICENSE).
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
# PyScribe
|
|
2
|
+
|
|
3
|
+
PyScribe records any mix of microphones and speakers (system audio) and transcribes the recording
|
|
4
|
+
on your own computer or a GPU worker, with speakers separated. Claude can summarize and title it;
|
|
5
|
+
the result copies as plain text or as a Markdown note. Tuned for German (including Swiss German)
|
|
6
|
+
and English. Windows, macOS 14.2+ (Apple Silicon) and Linux.
|
|
7
|
+
|
|
8
|
+

|
|
9
|
+
|
|
10
|
+
## Install
|
|
11
|
+
|
|
12
|
+
Install it with [uv](https://docs.astral.sh/uv/), which also fetches the Python 3.12 that
|
|
13
|
+
PyScribe needs. Windows, Linux and Apple Silicon Macs are supported; Intel Macs are not, as
|
|
14
|
+
PyTorch, ONNX Runtime and TorchCodec publish no current builds for them. The commands in this
|
|
15
|
+
file are the same in PowerShell, bash and zsh unless noted.
|
|
16
|
+
|
|
17
|
+
```sh
|
|
18
|
+
uv tool install --python 3.12 --torch-backend auto pyscribe-app
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Then start it with `pyscribe`. To update, run the install line again with `--upgrade` at the end,
|
|
22
|
+
so that the PyTorch build for your computer is chosen again (uv does not record
|
|
23
|
+
`--torch-backend` for `uv tool upgrade`). To remove it: `uv tool uninstall pyscribe-app`
|
|
24
|
+
(recordings, settings and models stay; see [Files](https://github.com/tobiaswuerth/pyscribe#files)).
|
|
25
|
+
|
|
26
|
+
`--torch-backend auto` installs the CUDA build of PyTorch on computers with an NVIDIA GPU and the
|
|
27
|
+
CPU build elsewhere. On Windows and Linux, PyScribe also brings NVIDIA's cuBLAS for CUDA 12, which
|
|
28
|
+
the Whisper models need on the GPU. Without a GPU (and on macOS), set **Device** to *Processor
|
|
29
|
+
(CPU)* before the first transcription, or use a [remote worker](https://github.com/tobiaswuerth/pyscribe#remote-worker).
|
|
30
|
+
|
|
31
|
+
| OS | Microphones | Speakers (system audio) | Needs |
|
|
32
|
+
|---|---|---|---|
|
|
33
|
+
| Windows | WASAPI, shared mode | WASAPI loopback | nothing |
|
|
34
|
+
| macOS 14.2+, Apple Silicon | Core Audio | Core Audio taps | microphone and *System Audio Recording* permission when asked |
|
|
35
|
+
| Linux | PulseAudio / PipeWire | monitor sources | PulseAudio or PipeWire (`pipewire-pulse`); Qt for the window |
|
|
36
|
+
|
|
37
|
+
PyScribe never takes a device exclusively: Teams, Zoom and other apps keep using the same
|
|
38
|
+
microphone. A device that drops out (unplugged, or reset when a call starts) is reopened every
|
|
39
|
+
2 seconds and its track continues.
|
|
40
|
+
|
|
41
|
+
## Start
|
|
42
|
+
|
|
43
|
+
```sh
|
|
44
|
+
pyscribe # desktop window
|
|
45
|
+
pyscribe --mode browser # in the web browser; file and folder pickers become text fields
|
|
46
|
+
pyscribe --mode server --port 8080 # serve on localhost only, open nothing
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
`--settings <file>` uses another settings file; one PyScribe runs per settings file.
|
|
50
|
+
|
|
51
|
+
## Use
|
|
52
|
+
|
|
53
|
+
1. **Devices** (right pane): every microphone and speaker shows a live level meter. Click the ones
|
|
54
|
+
to record, also during a recording; the refresh button finds newly plugged devices.
|
|
55
|
+
2. **Record**, **Pause**/**Resume**, **Stop**. Each device is written to its own FLAC track, all
|
|
56
|
+
on one clock; a device added later starts with silence so its track lines up.
|
|
57
|
+
3. **Transcribe** starts by itself after **Stop** (setting *Transcribe automatically*). The arrow
|
|
58
|
+
next to it picks another model for this recording; **Abort** stops a job at once.
|
|
59
|
+
4. **The recording** (middle pane): edit its title; see status, length, words, speakers and audio
|
|
60
|
+
size; then **Summarize**, **Copy text**, **Copy Markdown**, **Delete audio** (keeps the
|
|
61
|
+
transcript) or **Delete** (both ask first, neither can be undone). The upload button above the
|
|
62
|
+
recordings adds an existing audio or video file.
|
|
63
|
+
|
|
64
|
+
All tracks are mixed before transcription; voices are numbered by first appearance:
|
|
65
|
+
|
|
66
|
+
```
|
|
67
|
+
[00:00:03] Speaker 1: Grüezi mitenand, wir beginnen mit dem Budget.
|
|
68
|
+
[00:00:09] Speaker 2: Danke. Ich habe zwei Fragen dazu.
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
**Copy Markdown** gives title, summary and transcript with YAML front matter (date, duration,
|
|
72
|
+
speakers, words, language, model, tags), ready to paste into Obsidian.
|
|
73
|
+
|
|
74
|
+
## First run
|
|
75
|
+
|
|
76
|
+
- **Models** download with the first transcription, 0.7 to 6.2 GB each; the start screen says
|
|
77
|
+
which and how big.
|
|
78
|
+
- **Speaker separation** uses [pyannote speaker-diarization-community-1](https://huggingface.co/pyannote/speaker-diarization-community-1),
|
|
79
|
+
which needs a free Hugging Face token. *Setup needed* in the header leads to the steps: create
|
|
80
|
+
an account, accept the model's terms, create a Read token, paste it, **Check and save**. The
|
|
81
|
+
token is stored where Hugging Face's own tools look (`HF_TOKEN` also works). Or turn off
|
|
82
|
+
*Separate speakers*.
|
|
83
|
+
- **Summaries** run through [Claude Code](https://claude.com/claude-code): install it and run
|
|
84
|
+
`claude` once to log in. PyScribe calls it with no tools, no MCP servers and no saved session,
|
|
85
|
+
capped at USD 2 per summary; the transcript goes to Anthropic. A summary has sections for
|
|
86
|
+
summary, decisions, action items and open questions, and titles an untitled recording.
|
|
87
|
+
|
|
88
|
+
## Privacy
|
|
89
|
+
|
|
90
|
+
Recording, transcription and speaker separation run on your computer. What leaves it:
|
|
91
|
+
|
|
92
|
+
- Model downloads from Hugging Face on first use, and the check of your Hugging Face token against
|
|
93
|
+
the speaker model's terms.
|
|
94
|
+
- The transcript, to Anthropic, only when you press **Summarize** (through Claude Code).
|
|
95
|
+
- The audio, to your own worker, only if **Transcribe on** is *Remote worker*.
|
|
96
|
+
|
|
97
|
+
Nothing else; the telemetry of ONNX Runtime and pyannote is switched off.
|
|
98
|
+
|
|
99
|
+
## Settings
|
|
100
|
+
|
|
101
|
+
| Setting | Meaning |
|
|
102
|
+
|---|---|
|
|
103
|
+
| Save folder | where recordings go (default `Documents/PyScribe`) |
|
|
104
|
+
| Transcribe on | *This PC* or *Remote worker* (URL and token) |
|
|
105
|
+
| Device | *Graphics card (GPU)* or *Processor (CPU)* of the computer that transcribes; Parakeet always uses the CPU |
|
|
106
|
+
| Language, Model | German or English and one of its models, see below |
|
|
107
|
+
| Separate speakers | name voices Speaker 1, 2, … (pyannote counts them) |
|
|
108
|
+
| Transcribe automatically after recording | start a job when a recording stops or a file is added |
|
|
109
|
+
| Claude model | Haiku (fast, cheap) or Sonnet (more thorough) for summaries |
|
|
110
|
+
|
|
111
|
+
## Models
|
|
112
|
+
|
|
113
|
+
Word error rate (WER) and speed of PyScribe's pipeline (batched, with voice detection) on FLEURS
|
|
114
|
+
dev clips, normalised for case and punctuation (and ß as ss). GPU: 100 clips on an RTX 4090; CPU:
|
|
115
|
+
30 clips on an i9-14900K.
|
|
116
|
+
|
|
117
|
+
| Language | Preset | Model | WER | Speed (x real time) |
|
|
118
|
+
|---|---|---|---|---|
|
|
119
|
+
| German | `german-turbo` (default) | [primeline/whisper-large-v3-turbo-german](https://huggingface.co/primeline/whisper-large-v3-turbo-german) | 3.95 % GPU, 2.8 % CPU | 94 GPU, 2.9 CPU |
|
|
120
|
+
| German | `swiss-german` | [matildecs/whisper-large-stt4sg](https://huggingface.co/matildecs/whisper-large-stt4sg) | 6.0 % (Standard German) | 31 GPU |
|
|
121
|
+
| German | `parakeet-cpu` | NVIDIA Parakeet TDT 0.6B v3, int8 | 8.2 % | 14 CPU |
|
|
122
|
+
| English | `english-distil` (default) | [distil-whisper/distil-large-v3.5](https://huggingface.co/distil-whisper/distil-large-v3.5) | 4.24 % GPU, 6.7 % CPU | 107 GPU, 2.7 CPU |
|
|
123
|
+
| English | `english-parakeet` | NVIDIA Parakeet TDT 0.6B v2, int8 | 11.1 % | 12 CPU |
|
|
124
|
+
| both | `multilingual-large-v3` | OpenAI Whisper large-v3 | 4.26 % German, 4.10 % English | 31 GPU |
|
|
125
|
+
|
|
126
|
+
- `german-turbo` writes "ss" for "ß" (Swiss spelling). `swiss-german` writes dialect as Standard
|
|
127
|
+
German (about 20 % WER reported on dialect test sets).
|
|
128
|
+
- Parakeet is the option for slow computers. `english-parakeet` writes numbers as words and keeps
|
|
129
|
+
filler words, which FLEURS counts as errors.
|
|
130
|
+
- Tested, not adopted: Qwen3-ASR-1.7B (German 4.10 % at 6.6x, conflicting dependencies), Whisper
|
|
131
|
+
large-v3-turbo for English (4.44 %, slower than Distil), Parakeet v3 for English (14 %).
|
|
132
|
+
- FLEURS is read speech; meetings score worse with every model.
|
|
133
|
+
|
|
134
|
+
## Remote worker
|
|
135
|
+
|
|
136
|
+
On a computer with a GPU (installed as above):
|
|
137
|
+
|
|
138
|
+
```sh
|
|
139
|
+
export PYSCRIBE_WORKER_TOKEN="a long random secret" # bash, zsh
|
|
140
|
+
# PowerShell: $env:PYSCRIBE_WORKER_TOKEN = "a long random secret"
|
|
141
|
+
pyscribe-worker --host 0.0.0.0 # port 41738; --port and --data-dir change them
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
In PyScribe, set **Transcribe on** to *Remote worker*, enter the URL (for example
|
|
145
|
+
`http://gpu-box:41738`) and the token, and **Save**. PyScribe uploads the tracks, follows the job,
|
|
146
|
+
fetches the transcript and deletes the job on the worker. The API is plain HTTP with a bearer
|
|
147
|
+
token: use it on a trusted network or behind a TLS proxy or VPN. The token is stored in plain text
|
|
148
|
+
in the settings file.
|
|
149
|
+
|
|
150
|
+
## Files
|
|
151
|
+
|
|
152
|
+
| What | Where (Windows · macOS · Linux) | Owner and lifecycle |
|
|
153
|
+
|---|---|---|
|
|
154
|
+
| Recordings | `<save folder>/<YYYY-MM-DD_HH-MM-SS>/`: `NN-mic-….flac` / `NN-system-….flac` per track (added file: `01-audio.<ext>`), `recording.json`, `transcription.json`, `transcript.txt`, `transcript.json`, `notes.json` (title, summary) | Written by PyScribe; deleted from the app or by you. After a crash the audio up to the crash is kept and the recording shows as *Interrupted*. |
|
|
155
|
+
| Settings | `%LOCALAPPDATA%\PyScribe\settings.json` · `~/Library/Application Support/PyScribe/` · `~/.config/PyScribe/` | Written on every change; delete to reset. |
|
|
156
|
+
| Instance lock | `settings.lock` next to the settings file | Never written; the OS releases it when PyScribe exits, even after a crash. |
|
|
157
|
+
| Converted models | `%LOCALAPPDATA%\PyScribe\Cache\models` · `~/Library/Caches/PyScribe/models` · `~/.cache/PyScribe/models` | Written on first use of a preset that needs conversion; delete to convert again. |
|
|
158
|
+
| Downloaded models, Hugging Face token | `~/.cache/huggingface` | Managed by `huggingface_hub`. |
|
|
159
|
+
| Worker jobs | `worker` next to `models` in the cache folder above, on the worker | Deleted once the client fetched the result; finished jobs older than a day are purged when the next job arrives. |
|
|
160
|
+
|
|
161
|
+
## Limitations
|
|
162
|
+
|
|
163
|
+
- **Mixed languages:** Whisper may skip passages not in the chosen language.
|
|
164
|
+
- **No headset:** the microphone also hears the speakers, so remote voices are in the mix twice
|
|
165
|
+
with a slight delay. Recognition usually copes; a headset is cleaner.
|
|
166
|
+
- **Microphone indicator:** the level meters keep microphones open, so the OS shows "microphone in
|
|
167
|
+
use" while PyScribe runs. Nothing is stored unless you record.
|
|
168
|
+
- **No live transcript:** transcription starts when the recording stops.
|
|
169
|
+
- **macOS and Linux** capture is tested in CI against virtual devices (BlackHole, PulseAudio null
|
|
170
|
+
sinks); Windows also on real hardware.
|
|
171
|
+
|
|
172
|
+
## Troubleshooting
|
|
173
|
+
|
|
174
|
+
- **No GPU, or a CUDA error:** set **Device** to *Processor (CPU)*, or use a remote worker.
|
|
175
|
+
- **"cuBLAS 12 ... not installed"** (or `cublas64_12.dll` / `libcublas.so.12` not found): run the
|
|
176
|
+
install line again with `--reinstall` at the end.
|
|
177
|
+
- **"Setup needed" in the header:** speaker separation lacks its Hugging Face token; follow the
|
|
178
|
+
steps there, or turn off *Separate speakers*.
|
|
179
|
+
- **macOS records silence or nothing:** allow *Microphone* and *System Audio Recording* for the app
|
|
180
|
+
that started PyScribe (System Settings > Privacy & Security), then start PyScribe again.
|
|
181
|
+
- **Linux lists no devices:** PyScribe needs a PulseAudio or PipeWire server (`pipewire-pulse`);
|
|
182
|
+
`pactl info` must answer.
|
|
183
|
+
|
|
184
|
+
## Development
|
|
185
|
+
|
|
186
|
+
```sh
|
|
187
|
+
git clone https://github.com/tobiaswuerth/pyscribe.git
|
|
188
|
+
cd pyscribe
|
|
189
|
+
uv sync # CUDA PyTorch on Windows/Linux; CPU only: uv sync --no-group gpu --group cpu
|
|
190
|
+
uv run prek install # git hooks: checks on commit, the whole gate before push
|
|
191
|
+
uv run nox # the gate: hooks, types per OS, tests at 100 % line and branch coverage,
|
|
192
|
+
# each test file alone, lowest dependency versions, the built package
|
|
193
|
+
uv run nox -s fresh # the gate from a fresh clone (fresh-wsl: the same in WSL)
|
|
194
|
+
uv run nox -s audio # record from virtual devices (CI sets them up)
|
|
195
|
+
uv run nox -s smoke # end to end: real devices, GPU, CPU, remote worker, app server
|
|
196
|
+
uv run nox -s bench -- --language en # WER and speed of a language's presets
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
CI runs the gate sessions as jobs, the tests on Windows, macOS and Linux and real recordings on
|
|
200
|
+
macOS and Linux virtual devices, behind one required check.
|
|
201
|
+
Merging to `main` publishes to PyPI and creates the GitHub release once the top `CHANGELOG.md`
|
|
202
|
+
section has a date (`## 2.1.0 - 2026-12-24`, not in the future); `unreleased` does nothing. Each
|
|
203
|
+
step runs only if it is still missing, so the next run on `main` finishes one that failed.
|
|
204
|
+
A weekly run (`uv run nox -s highest`) tests the newest allowed versions of every dependency.
|
|
205
|
+
Rules for contributions: [CONTRIBUTING.md](https://github.com/tobiaswuerth/pyscribe/blob/main/CONTRIBUTING.md).
|
|
206
|
+
|
|
207
|
+
Code layout (`src/pyscribe`; dependencies point down only, enforced by import-linter):
|
|
208
|
+
|
|
209
|
+
| Package | Responsibility |
|
|
210
|
+
|---|---|
|
|
211
|
+
| `app.py` | composition root, command line |
|
|
212
|
+
| `ui/` | `controller.py` (all behaviour, no toolkit), `page.py` (NiceGUI view), `native.py` (window) |
|
|
213
|
+
| `worker/` | the remote worker's HTTP API |
|
|
214
|
+
| `jobs/`, `audio/`, `summary/` | job queue and remote client; capture per OS, recorder, level meters, file import; Claude Code summaries |
|
|
215
|
+
| `engine/`, `storage/` | decoding, ASR and diarization adapters in a killable process, Hugging Face access; run folders, settings, instance lock, atomic writes |
|
|
216
|
+
| `domain/` | pure logic: timeline, job states, model presets, transcript merge, notes |
|
|
217
|
+
|
|
218
|
+
Torch, faster-whisper, pyannote and onnx-asr load only inside the engine process; a test checks
|
|
219
|
+
that the app loads none of them.
|
|
220
|
+
|
|
221
|
+
## License
|
|
222
|
+
|
|
223
|
+
MIT, see [LICENSE](https://github.com/tobiaswuerth/pyscribe/blob/main/LICENSE).
|