whspr 1.0.5 → 1.0.6
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.
- package/README.md +50 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -51,30 +51,75 @@ Press **Enter** to stop recording.
|
|
|
51
51
|
- 15-minute max recording time
|
|
52
52
|
- Transcription via Groq Whisper API
|
|
53
53
|
- AI-powered post-processing to fix transcription errors
|
|
54
|
-
- Custom vocabulary support via `WHSPR.md`
|
|
54
|
+
- Custom vocabulary support via `WHSPR.md` (global and local)
|
|
55
|
+
- Configurable settings via `~/.whspr/settings.json`
|
|
55
56
|
- Automatic clipboard copy
|
|
56
57
|
|
|
58
|
+
## Settings
|
|
59
|
+
|
|
60
|
+
Create `~/.whspr/settings.json` to customize whspr's behavior:
|
|
61
|
+
|
|
62
|
+
```json
|
|
63
|
+
{
|
|
64
|
+
"verbose": false,
|
|
65
|
+
"suffix": "\n\n(Transcribed via Whisper)",
|
|
66
|
+
"transcriptionModel": "whisper-large-v3-turbo",
|
|
67
|
+
"language": "en",
|
|
68
|
+
"systemPrompt": "Your task is to clean up transcribed text...",
|
|
69
|
+
"customPromptPrefix": "Here's my custom user prompt:",
|
|
70
|
+
"transcriptionPrefix": "Here's my raw transcription output:"
|
|
71
|
+
}
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
| Option | Type | Default | Description |
|
|
75
|
+
|--------|------|---------|-------------|
|
|
76
|
+
| `verbose` | boolean | `false` | Enable verbose output |
|
|
77
|
+
| `suffix` | string | none | Text appended to all transcriptions |
|
|
78
|
+
| `transcriptionModel` | string | `"whisper-large-v3-turbo"` | Whisper model (`"whisper-large-v3"` or `"whisper-large-v3-turbo"`) |
|
|
79
|
+
| `language` | string | `"en"` | ISO 639-1 language code (e.g., `"en"`, `"zh"`, `"es"`) |
|
|
80
|
+
| `systemPrompt` | string | (built-in) | System prompt for AI post-processing |
|
|
81
|
+
| `customPromptPrefix` | string | `"Here's my custom user prompt:"` | Prefix before custom prompt content |
|
|
82
|
+
| `transcriptionPrefix` | string | `"Here's my raw transcription output that I need you to edit:"` | Prefix before raw transcription |
|
|
83
|
+
|
|
57
84
|
## Custom Vocabulary
|
|
58
85
|
|
|
59
|
-
Create a `WHSPR.md` (or `WHISPER.md`) file
|
|
86
|
+
Create a `WHSPR.md` (or `WHISPER.md`) file to provide custom vocabulary, names, or instructions for the AI post-processor.
|
|
87
|
+
|
|
88
|
+
### Global Prompts
|
|
89
|
+
|
|
90
|
+
Place in `~/.whspr/WHSPR.md` for vocabulary that applies everywhere:
|
|
60
91
|
|
|
61
92
|
```markdown
|
|
62
|
-
#
|
|
93
|
+
# Global Vocabulary
|
|
94
|
+
|
|
95
|
+
- My name is "Alex" not "Alec"
|
|
96
|
+
- Common terms: API, CLI, JSON, OAuth
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
### Local Prompts
|
|
100
|
+
|
|
101
|
+
Place in your current directory (`./WHSPR.md`) for project-specific vocabulary:
|
|
102
|
+
|
|
103
|
+
```markdown
|
|
104
|
+
# Project Vocabulary
|
|
63
105
|
|
|
64
106
|
- PostgreSQL (not "post crest QL")
|
|
65
107
|
- Kubernetes (not "cooper netties")
|
|
66
108
|
- My colleague's name is "Priya" not "Maria"
|
|
67
109
|
```
|
|
68
110
|
|
|
111
|
+
When both exist, they are combined (global first, then local).
|
|
112
|
+
|
|
69
113
|
## How It Works
|
|
70
114
|
|
|
71
115
|
1. Records audio from your default microphone using FFmpeg
|
|
72
116
|
2. Displays a live waveform visualization based on audio levels
|
|
73
117
|
3. Converts the recording to MP3
|
|
74
118
|
4. Sends audio to Groq's Whisper API for transcription
|
|
75
|
-
5.
|
|
119
|
+
5. Loads custom prompts from `~/.whspr/WHSPR.md` and/or `./WHSPR.md`
|
|
76
120
|
6. Sends transcription + custom vocabulary to AI for post-processing
|
|
77
|
-
7.
|
|
121
|
+
7. Applies suffix (if configured)
|
|
122
|
+
8. Prints result and copies to clipboard
|
|
78
123
|
|
|
79
124
|
If transcription fails, the recording is saved to `~/.whspr/recordings/` for manual recovery.
|
|
80
125
|
|