supervoxtral 0.1.0__tar.gz → 0.1.1__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.
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/PKG-INFO +1 -1
- supervoxtral-0.1.1/README.md +235 -0
- supervoxtral-0.1.1/macos-shortcut.png +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/notes.md +1 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/pyproject.toml +1 -1
- supervoxtral-0.1.1/supervoxtral.png +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/config.py +1 -1
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/prompt.py +1 -1
- supervoxtral-0.1.0/README.md +0 -237
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/.gitignore +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/AGENTS.md +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/LICENSE +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/logs/.gitkeep +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/prompt/.gitkeep +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/recordings/.gitkeep +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/__init__.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/cli.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/__init__.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/audio.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/clipboard.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/pipeline.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/core/storage.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/providers/__init__.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/providers/base.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/providers/mistral.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/svx/ui/qt_app.py +0 -0
- {supervoxtral-0.1.0 → supervoxtral-0.1.1}/transcripts/.gitkeep +0 -0
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
# supervoxtral
|
|
2
|
+
|
|
3
|
+

|
|
4
|
+
|
|
5
|
+
SuperVoxtral is a lightweight Python CLI/GUI utility for recording microphone audio and integrate with Mistral's Voxtral APIs for transcription or audio-enabled chat.
|
|
6
|
+
|
|
7
|
+
Voxtral models, such as `voxtral-mini-latest` and `voxtral-small-latest`, deliver fast inference times, high transcription accuracy across languages and accents, and minimal API costs. In contrast to OpenAI's Whisper, which performs only standalone transcription, Voxtral supports two modes: pure transcription via a dedicated endpoint (no prompts needed) or chat mode, where audio input combines with text prompts for refined outputs—like error correction or contextual summarization—without invoking a separate LLM.
|
|
8
|
+
|
|
9
|
+
For instance, use a prompt like: "_Transcribe this audio precisely and remove all minor speech hesitations: "um", "uh", "er", "euh", "ben", etc._"
|
|
10
|
+
|
|
11
|
+
The GUI is minimal, launches fast, and can be bound to a system hotkey. Upon stopping recording, it transcribes via the pipeline and copies the result directly to the system clipboard, enabling efficient voice-driven workflows: e.g., dictating code snippets into an IDE or prompting LLMs via audio without typing.
|
|
12
|
+
|
|
13
|
+
## Requirements
|
|
14
|
+
|
|
15
|
+
- Python 3.11+
|
|
16
|
+
- ffmpeg (for MP3/Opus conversions)
|
|
17
|
+
- macOS: `brew install ffmpeg`
|
|
18
|
+
- Ubuntu/Debian: `sudo apt-get install ffmpeg`
|
|
19
|
+
- Windows: https://ffmpeg.org/download.html
|
|
20
|
+
|
|
21
|
+
## Installation
|
|
22
|
+
|
|
23
|
+
The package is available on PyPI. We recommend using `uv` (a fast Python package installer) for a simple, global tool installation—no virtual environment setup required.
|
|
24
|
+
|
|
25
|
+
- For core CLI functionality:
|
|
26
|
+
```
|
|
27
|
+
uv tool install supervoxtral
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
- For GUI support (includes PySide6):
|
|
31
|
+
```
|
|
32
|
+
uv tool install "supervoxtral[gui]"
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
This installs the `svx` command globally. If you don't have `uv`, install it first via `curl -LsSf https://astral.sh/uv/install.sh | sh` (or from https://docs.astral.sh/uv/getting-started/installation/).
|
|
36
|
+
|
|
37
|
+
**Alternative: Using pip with a virtual environment**
|
|
38
|
+
|
|
39
|
+
If you prefer not to use uv, you can install via pip in a virtual environment:
|
|
40
|
+
|
|
41
|
+
1. Create and activate a virtual environment:
|
|
42
|
+
|
|
43
|
+
- macOS/Linux:
|
|
44
|
+
```
|
|
45
|
+
python -m venv .venv
|
|
46
|
+
source .venv/bin/activate
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
- Windows (PowerShell):
|
|
50
|
+
```
|
|
51
|
+
python -m venv .venv
|
|
52
|
+
.\.venv\Scripts\Activate.ps1
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
2. Install the package:
|
|
56
|
+
```
|
|
57
|
+
pip install supervoxtral
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
For GUI support (includes PySide6):
|
|
61
|
+
```
|
|
62
|
+
pip install supervoxtral[gui]
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
This installs the `svx` command within the virtual environment. Make sure to activate the environment before running `svx`.
|
|
66
|
+
|
|
67
|
+
**For development** (local editing):
|
|
68
|
+
1. Clone the repo and navigate to the project root.
|
|
69
|
+
2. Create/activate a virtual environment:
|
|
70
|
+
- macOS/Linux: `python -m venv .venv && source .venv/bin/activate`
|
|
71
|
+
- Windows: `python -m venv .venv && .\.venv\Scripts\Activate.ps1`
|
|
72
|
+
3. Install in editable mode: `pip install -e .` (or `pip install -e ".[dev]"` for dev tools).
|
|
73
|
+
|
|
74
|
+
## Quick Start
|
|
75
|
+
|
|
76
|
+
To get started quickly with SuperVoxtral:
|
|
77
|
+
|
|
78
|
+
1. Initialize the configuration: `svx config init`
|
|
79
|
+
This creates the default `config.toml` file with zero-footprint settings.
|
|
80
|
+
|
|
81
|
+
2. Open the configuration directory: `svx config open`
|
|
82
|
+
Edit `config.toml` and add your [Mistral API key](https://console.mistral.ai/api-keys) under the `[providers.mistral]` section:
|
|
83
|
+
```
|
|
84
|
+
[providers.mistral]
|
|
85
|
+
api_key = "your_mistral_api_key_here"
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
3. Launch the GUI for transcription: `svx record --gui --transcribe`
|
|
89
|
+
This opens the minimal GUI, starts recording on launch, and transcribes the audio upon stopping (results copied to clipboard).
|
|
90
|
+
|
|
91
|
+
### macOS Shortcuts Integration
|
|
92
|
+
|
|
93
|
+
To enable fast, hotkey-driven access on macOS, integrate SuperVoxtral with the Shortcuts app. Create a new Shortcut that runs `svx record --gui` via a "Run Shell Script" action (ensure `svx` is in your PATH). Assign a global hotkey in Shortcuts settings for instant GUI launch—ideal for quick voice-to-text workflows, with results copied directly to the clipboard.
|
|
94
|
+
|
|
95
|
+
#### Quick Setup Steps
|
|
96
|
+
1. Open the Shortcuts app and create a new shortcut.
|
|
97
|
+
2. Add the "Run Shell Script" action with input: `svx record --gui`.
|
|
98
|
+
3. In shortcut details, set a keyboard shortcut (e.g., Cmd+Shift+V).
|
|
99
|
+
|
|
100
|
+

|
|
101
|
+
|
|
102
|
+
## Configuration (API keys and prompts)
|
|
103
|
+
|
|
104
|
+
API keys and default behavior are configured only in your user configuration file (config.toml), not via environment variables.
|
|
105
|
+
|
|
106
|
+
- Location of the user config:
|
|
107
|
+
- macOS: ~/Library/Application Support/SuperVoxtral/config.toml
|
|
108
|
+
- Linux: ${XDG_CONFIG_HOME:-~/.config}/supervoxtral/config.toml
|
|
109
|
+
- Windows: %APPDATA%/SuperVoxtral/config.toml
|
|
110
|
+
|
|
111
|
+
- Initialize your user config and user prompt file:
|
|
112
|
+
- `svx config init`: Creates config.toml (with sensible defaults, including zero-footprint mode) and a user prompt file at: `~/Library/Application Support/SuperVoxtral/` (macOS), `${XDG_CONFIG_HOME:-~/.config}/supervoxtral/` (Linux), or `%APPDATA%/SuperVoxtral/prompt/` (Windows).
|
|
113
|
+
- `svx config open`: Opens the directory.
|
|
114
|
+
- `svx config show`: Displays the current configuration.
|
|
115
|
+
|
|
116
|
+
Here's an example of the default `config.toml` generated by `svx config init`:
|
|
117
|
+
|
|
118
|
+
```toml
|
|
119
|
+
# SuperVoxtral - User configuration
|
|
120
|
+
#
|
|
121
|
+
# Basics:
|
|
122
|
+
# - This configuration controls the default behavior of `svx record`.
|
|
123
|
+
# - The parameters below override the binary's built-in defaults.
|
|
124
|
+
# - You can override a few options at runtime via the CLI:
|
|
125
|
+
# --prompt / --prompt-file (set a one-off prompt for this run)
|
|
126
|
+
# --log-level (debugging)
|
|
127
|
+
# --outfile-prefix (one-off output naming)
|
|
128
|
+
#
|
|
129
|
+
# Output persistence:
|
|
130
|
+
# - Set keep_* = true to create and save files to project
|
|
131
|
+
# directories (recordings/, transcripts/, logs/).
|
|
132
|
+
# - false (default): use temp files/console only (no disk
|
|
133
|
+
# footprint in project dir).
|
|
134
|
+
#
|
|
135
|
+
# Authentication:
|
|
136
|
+
# - API keys are defined in provider-specific sections in this file.
|
|
137
|
+
[providers.mistral]
|
|
138
|
+
# api_key = ""
|
|
139
|
+
|
|
140
|
+
[defaults]
|
|
141
|
+
# Provider to use (currently supported: "mistral")
|
|
142
|
+
provider = "mistral"
|
|
143
|
+
|
|
144
|
+
# File format sent to the provider: "wav" | "mp3" | "opus"
|
|
145
|
+
# Recording is always WAV; conversion is applied if "mp3" or "opus"
|
|
146
|
+
format = "opus"
|
|
147
|
+
|
|
148
|
+
# Model to use on the provider side (example for Mistral Voxtral)
|
|
149
|
+
model = "voxtral-mini-latest"
|
|
150
|
+
|
|
151
|
+
# Language hint (may help the provider)
|
|
152
|
+
language = "fr"
|
|
153
|
+
|
|
154
|
+
# Audio recording parameters
|
|
155
|
+
rate = 16000
|
|
156
|
+
channels = 1
|
|
157
|
+
device = ""
|
|
158
|
+
|
|
159
|
+
# Output persistence:
|
|
160
|
+
# - keep_audio_files: false uses temp files (no recordings/ dir),
|
|
161
|
+
# true saves to recordings/
|
|
162
|
+
keep_audio_files = false
|
|
163
|
+
# - keep_transcript_files: false prints/copies only (no
|
|
164
|
+
# transcripts/ dir), true saves to transcripts/
|
|
165
|
+
keep_transcript_files = false
|
|
166
|
+
# - keep_log_files: false console only (no logs/ dir), true
|
|
167
|
+
# saves to logs/app.log
|
|
168
|
+
keep_log_files = false
|
|
169
|
+
|
|
170
|
+
# Automatically copy the transcribed text to the system clipboard
|
|
171
|
+
copy = true
|
|
172
|
+
|
|
173
|
+
# Log level: "DEBUG" | "INFO" | "WARNING" | "ERROR"
|
|
174
|
+
log_level = "INFO"
|
|
175
|
+
|
|
176
|
+
[prompt]
|
|
177
|
+
# Default user prompt source:
|
|
178
|
+
# - Option 1: Use a file (recommended)
|
|
179
|
+
file = "~/.config/supervoxtral/prompt/user.md"
|
|
180
|
+
#
|
|
181
|
+
# - Option 2: Inline prompt (less recommended for long text)
|
|
182
|
+
# text = "Please transcribe the audio and provide a concise summary in French."
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
**Configuration is centralized via a structured `Config` object loaded from your user configuration file (`config.toml`). CLI arguments override select values (e.g., prompt, log level), but most defaults (provider, model, keep flags) come from `config.toml`. No environment variables are used for API keys or settings.**
|
|
186
|
+
|
|
187
|
+
No `.env` or shell environment variables are used for API keys.
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
## Usage (CLI)
|
|
191
|
+
|
|
192
|
+
The CLI provides config utilities and a unified `record` entrypoint for both CLI and GUI modes, using a centralized pipeline for consistent behavior (recording, conversion, transcription, saving, clipboard copy, logging).
|
|
193
|
+
|
|
194
|
+
**Zero-footprint defaults**: No directories created; outputs to console/clipboard. Use `--save-all` or set `keep_* = true` in config.toml for persistence.
|
|
195
|
+
|
|
196
|
+
Most defaults (provider, format, model, language, rate, channels, device, keep flags, copy) come from config.toml. CLI overrides are limited to specific options.
|
|
197
|
+
|
|
198
|
+
### Record Command
|
|
199
|
+
|
|
200
|
+
```
|
|
201
|
+
svx record [OPTIONS]
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
**Options**:
|
|
205
|
+
- `--user-prompt TEXT` (or `--prompt TEXT`): Inline user prompt for this run.
|
|
206
|
+
- `--user-prompt-file PATH` (or `--prompt-file PATH`): Path to a markdown file with the user prompt.
|
|
207
|
+
- `--transcribe`: Enable pure transcription mode (ignores prompts; uses dedicated endpoint).
|
|
208
|
+
- `--outfile-prefix PREFIX`: Custom prefix for output files (default: timestamp).
|
|
209
|
+
- `--gui`: Launch the GUI frontend (respects config and other CLI options).
|
|
210
|
+
- `--save-all`: Override config to keep audio, transcripts, and logs for this run.
|
|
211
|
+
- `--log-level LEVEL`: Set logging level (DEBUG, INFO, WARNING, ERROR; default: INFO).
|
|
212
|
+
|
|
213
|
+
**Examples**:
|
|
214
|
+
- Record with prompt: `svx record --prompt "What's in this audio?"`
|
|
215
|
+
- Records WAV, converts if needed, sends to provider with prompt, outputs to console/clipboard.
|
|
216
|
+
- Persist outputs: `svx record --save-all --prompt "Summarize this"`
|
|
217
|
+
- Saves to recordings/, transcripts/, logs/.
|
|
218
|
+
- Transcribe only: `svx record --transcribe`
|
|
219
|
+
- No prompt; direct transcription. Add `--save-all` to persist.
|
|
220
|
+
- Launch GUI: `svx record --gui`
|
|
221
|
+
- GUI respects config.toml and CLI flags (e.g., `--gui --save-all`).
|
|
222
|
+
|
|
223
|
+
**Prompt Resolution Priority** (for non-transcribe mode):
|
|
224
|
+
1. CLI `--user-prompt` or `--user-prompt-file`
|
|
225
|
+
2. config.toml [prompt] section (text or file)
|
|
226
|
+
3. User prompt file (user.md in config dir)
|
|
227
|
+
4. Fallback: "What's in this audio?"
|
|
228
|
+
|
|
229
|
+
## Changelog
|
|
230
|
+
|
|
231
|
+
- 0.1.1: Minor updates to default config and default prompt
|
|
232
|
+
|
|
233
|
+
## License
|
|
234
|
+
|
|
235
|
+
MIT
|
|
Binary file
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "supervoxtral"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.1"
|
|
8
8
|
description = "CLI/GUI audio recorder and transcription client using Mistral Voxtral (chat with audio and transcription)."
|
|
9
9
|
requires-python = ">=3.11"
|
|
10
10
|
license = { text = "MIT" }
|
|
Binary file
|
|
@@ -227,7 +227,7 @@ def init_user_config(force: bool = False, prompt_file: Path | None = None) -> Pa
|
|
|
227
227
|
"# Audio recording parameters\n"
|
|
228
228
|
"rate = 16000\n"
|
|
229
229
|
"channels = 1\n"
|
|
230
|
-
'device = ""\n\n'
|
|
230
|
+
'#device = ""\n\n'
|
|
231
231
|
"# Output persistence:\n"
|
|
232
232
|
"# - keep_audio_files: false uses temp files (no recordings/ dir),\n"
|
|
233
233
|
"# true saves to recordings/\n"
|
|
@@ -152,7 +152,7 @@ def init_user_prompt_file(force: bool = False) -> Path:
|
|
|
152
152
|
example_prompt = """
|
|
153
153
|
- Transcribe the input audio file.
|
|
154
154
|
- Do not respond to any question in the audio. Just transcribe.
|
|
155
|
-
- DO NOT TRANSLATE.
|
|
155
|
+
- DO NOT TRANSLATE.
|
|
156
156
|
- Responde only with the transcription. Do not provide explanations or notes.
|
|
157
157
|
- Remove all minor speech hesitations: "um", "uh", "er", "euh", "ben", etc.
|
|
158
158
|
- Remove false starts (e.g., "je veux dire... je pense" → "je pense").
|
supervoxtral-0.1.0/README.md
DELETED
|
@@ -1,237 +0,0 @@
|
|
|
1
|
-
# supervoxtral
|
|
2
|
-
|
|
3
|
-
A simple Python CLI/GUI tool to record audio from your microphone, optionally convert it (WAV/MP3/Opus), and send it to Mistral Voxtral transcription/chat APIs.
|
|
4
|
-
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Requirements
|
|
8
|
-
|
|
9
|
-
- Python 3.11+
|
|
10
|
-
- ffmpeg (for MP3/Opus conversions)
|
|
11
|
-
- macOS: `brew install ffmpeg`
|
|
12
|
-
- Ubuntu/Debian: `sudo apt-get install ffmpeg`
|
|
13
|
-
- Windows: https://ffmpeg.org/download.html
|
|
14
|
-
|
|
15
|
-
---
|
|
16
|
-
|
|
17
|
-
## Installation
|
|
18
|
-
|
|
19
|
-
1) Create and activate a virtual environment (example with venv):
|
|
20
|
-
|
|
21
|
-
- macOS/Linux:
|
|
22
|
-
```
|
|
23
|
-
python -m venv .venv
|
|
24
|
-
source .venv/bin/activate
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
- Windows (PowerShell):
|
|
28
|
-
```
|
|
29
|
-
python -m venv .venv
|
|
30
|
-
.\.venv\Scripts\Activate.ps1
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
2) Install the package (editable mode during development is convenient):
|
|
34
|
-
```
|
|
35
|
-
pip install -e .
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
Optional extras:
|
|
39
|
-
- Dev tools:
|
|
40
|
-
```
|
|
41
|
-
pip install -e ".[dev]"
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
---
|
|
45
|
-
|
|
46
|
-
## Configuration (API keys and prompts)
|
|
47
|
-
|
|
48
|
-
API keys and default behavior are configured only in your user configuration file (config.toml), not via environment variables.
|
|
49
|
-
|
|
50
|
-
- Location of the user config:
|
|
51
|
-
- macOS: ~/Library/Application Support/SuperVoxtral/config.toml
|
|
52
|
-
- Linux: ${XDG_CONFIG_HOME:-~/.config}/supervoxtral/config.toml
|
|
53
|
-
- Windows: %APPDATA%/SuperVoxtral/config.toml
|
|
54
|
-
|
|
55
|
-
- Initialize your user config and user prompt file:
|
|
56
|
-
|
|
57
|
-
```
|
|
58
|
-
svx config init
|
|
59
|
-
```
|
|
60
|
-
|
|
61
|
-
This creates:
|
|
62
|
-
|
|
63
|
-
- config.toml (with sensible defaults, including zero-footprint mode)
|
|
64
|
-
- a user prompt file at: ~/Library/Application Support/SuperVoxtral/prompt/user.md (macOS)
|
|
65
|
-
- Linux: ${XDG_CONFIG_HOME:-~/.config}/supervoxtral/prompt/user.md
|
|
66
|
-
- Windows: %APPDATA%/SuperVoxtral/prompt/user.md
|
|
67
|
-
|
|
68
|
-
**Key config sections (edit `config.toml`):**
|
|
69
|
-
- **[defaults]**: provider (e.g., "mistral"), model, format (e.g., "opus"), language, rate, channels, device, copy (clipboard), keep_audio_files = false, keep_transcript_files = false, keep_log_files = false.
|
|
70
|
-
- Zero-footprint mode (defaults): When `keep_* = false`, files are handled in OS temporary directories (auto-cleaned, no project dirs created). Set to `true` for persistence (creates `recordings/`, etc.).
|
|
71
|
-
- **[providers.mistral]**: api_key = "your_mistral_key_here", model (e.g., "voxtral-small-latest").
|
|
72
|
-
- **[prompt]**: text (inline prompt), file (path to prompt.md).
|
|
73
|
-
- Resolution priority: CLI `--prompt`/`--prompt-file` > config.toml [prompt] > user.md fallback > "What's in this audio?".
|
|
74
|
-
|
|
75
|
-
**Configuration is centralized via a structured `Config` object loaded from your user configuration file (`config.toml`). CLI arguments override select values (e.g., prompt, log level), but most defaults (provider, model, keep flags) come from `config.toml`. No environment variables are used for API keys or settings.**
|
|
76
|
-
|
|
77
|
-
No `.env` or shell environment variables are used for API keys.
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
---
|
|
81
|
-
|
|
82
|
-
## Usage (CLI)
|
|
83
|
-
|
|
84
|
-
Make sure your virtual environment is activated and the project is installed (`pip install -e .`).
|
|
85
|
-
|
|
86
|
-
General command form:
|
|
87
|
-
```
|
|
88
|
-
svx record [OPTIONS]
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
**Unified entrypoint**: `svx record` handles both CLI and GUI modes via a centralized pipeline (`svx.core.pipeline.RecordingPipeline`). This ensures consistent behavior for recording, conversion, transcription, saving, clipboard copy, and logging across CLI and GUI.
|
|
92
|
-
|
|
93
|
-
**Zero-footprint defaults**: No directories created; outputs to console/clipboard. Use `--save-all` or config `keep_* = true` for persistence.
|
|
94
|
-
|
|
95
|
-
Note: the CLI now exposes a single recording entrypoint. Use `svx record --gui` to launch the GUI frontend. Most defaults (provider, format, model, language, rate, channels, device, keep_audio_files, copy) are configured via your user config (config.toml). The CLI only supports one-off overrides for: --prompt/--prompt-file, --log-level, --outfile-prefix, --gui, --save-all, --transcribe.
|
|
96
|
-
|
|
97
|
-
Planned MVP commands:
|
|
98
|
-
|
|
99
|
-
- Record with Mistral Voxtral (chat with audio) and a prompt (provider/format from config):
|
|
100
|
-
```
|
|
101
|
-
svx record --prompt "What's in this file?"
|
|
102
|
-
```
|
|
103
|
-
Tip: Outputs to console and clipboard (if copy=true in config). No files saved unless overridden.
|
|
104
|
-
|
|
105
|
-
Persist all outputs (one-off override):
|
|
106
|
-
```
|
|
107
|
-
svx record --save-all --prompt "What's in this file?"
|
|
108
|
-
```
|
|
109
|
-
Creates `recordings/`, `transcripts/`, `logs/` and saves files/logs.
|
|
110
|
-
|
|
111
|
-
- Pure transcription mode with Mistral Voxtral (no prompt, dedicated endpoint):
|
|
112
|
-
```
|
|
113
|
-
svx record --transcribe
|
|
114
|
-
```
|
|
115
|
-
Note: Prompts are ignored in this mode. Combine with --save-all for persistence:
|
|
116
|
-
```
|
|
117
|
-
svx record --transcribe --save-all
|
|
118
|
-
```
|
|
119
|
-
|
|
120
|
-
To start the GUI frontend:
|
|
121
|
-
```
|
|
122
|
-
svx record --gui
|
|
123
|
-
```
|
|
124
|
-
The GUI uses the same pipeline and respects config + CLI overrides (e.g., `--gui --save-all` propagates persistence).
|
|
125
|
-
|
|
126
|
-
The CLI defaults have been unified to favour the previous GUI defaults (e.g. `--format opus`, `--copy` enabled, and `--no-keep-audio-files` by default). The final effective values still respect the precedence: CLI explicit > user config defaults (config.toml) > built-in defaults.
|
|
127
|
-
|
|
128
|
-
### Advanced prompt management
|
|
129
|
-
|
|
130
|
-
You can provide a user prompt, either inline or via a file:
|
|
131
|
-
|
|
132
|
-
#### User prompt (inline)
|
|
133
|
-
```
|
|
134
|
-
svx record --user-prompt "Transcris puis résume ce qui est dit dans l'audio."
|
|
135
|
-
```
|
|
136
|
-
|
|
137
|
-
#### User prompt from file
|
|
138
|
-
```
|
|
139
|
-
svx record --user-prompt-file ~/Library/Application\ Support/SuperVoxtral/prompt/user.md
|
|
140
|
-
```
|
|
141
|
-
(Adjust the path for your OS; see “Configuration” for locations.)
|
|
142
|
-
|
|
143
|
-
#### Resolution priority (no concatenation)
|
|
144
|
-
Order of precedence for determining the final prompt:
|
|
145
|
-
1) `--user-prompt` (inline)
|
|
146
|
-
2) `--user-prompt-file` (explicit file)
|
|
147
|
-
3) `config.toml` → `[prompt].text`
|
|
148
|
-
4) `config.toml` → `[prompt].file`
|
|
149
|
-
5) User prompt file in your user config dir (`.../SuperVoxtral/prompt/user.md`)
|
|
150
|
-
6) Default fallback: "What's in this audio?"
|
|
151
|
-
|
|
152
|
-
Note: the file and inline prompts are not concatenated; the first non-empty source wins. Uses `Config.resolve_prompt()` for unified resolution across CLI/GUI.
|
|
153
|
-
|
|
154
|
-
If no user prompt is provided (by any of the above), it defaults to "What's in this audio?".
|
|
155
|
-
|
|
156
|
-
A single user message is sent containing the audio and (optionally) text.
|
|
157
|
-
|
|
158
|
-
Flow:
|
|
159
|
-
- Starts recording WAV immediately.
|
|
160
|
-
- Press Enter to stop recording.
|
|
161
|
-
- Converts WAV to MP3 (if `--format mp3`) or Opus (if `--format opus`).
|
|
162
|
-
- Sends the audio to Mistral Voxtral as base64 input_audio plus your text prompt.
|
|
163
|
-
- Prints and saves the response to `transcripts/` (if keep_transcript_files=true or --save-all).
|
|
164
|
-
|
|
165
|
-
Flow:
|
|
166
|
-
- Starts recording WAV.
|
|
167
|
-
- Press Enter to stop.
|
|
168
|
-
- Sends the audio to Voxtral (transcription).
|
|
169
|
-
- Prints and saves the transcript.
|
|
170
|
-
|
|
171
|
-
Config-driven options (set these in config.toml under [defaults]):
|
|
172
|
-
- rate, channels, device
|
|
173
|
-
- provider, model, format, language
|
|
174
|
-
- keep_audio_files, copy
|
|
175
|
-
|
|
176
|
-
One-off CLI overrides:
|
|
177
|
-
- `--outfile-prefix mynote_2025-09-09` (custom file prefix)
|
|
178
|
-
- `--log-level debug` (verbose logs)
|
|
179
|
-
- `--user-prompt` (alias: `--prompt`; user prompt text, inline)
|
|
180
|
-
- `--user-prompt-file` (alias: `--prompt-file`; path to user prompt markdown file in your user config dir)
|
|
181
|
-
- `--transcribe` (pure transcription mode, ignores prompts)
|
|
182
|
-
|
|
183
|
-
Alternative invocation (without console script):
|
|
184
|
-
```
|
|
185
|
-
python -m svx.cli record --prompt "..."
|
|
186
|
-
```
|
|
187
|
-
|
|
188
|
-
---
|
|
189
|
-
|
|
190
|
-
## Provider details
|
|
191
|
-
|
|
192
|
-
### Mistral Voxtral (chat with audio)
|
|
193
|
-
- Model: `voxtral-small-latest` by default (configurable)
|
|
194
|
-
- API: `mistralai` Python client
|
|
195
|
-
- Request structure:
|
|
196
|
-
- Messages with `content` array containing:
|
|
197
|
-
- `{ "type": "input_audio", "input_audio": "<base64>" }`
|
|
198
|
-
- `{ "type": "text", "text": "<prompt>" }`
|
|
199
|
-
- Output: text content from the chat response; saved to `transcripts/`.
|
|
200
|
-
|
|
201
|
-
Recommended formats:
|
|
202
|
-
- Opus reduces file size and upload time.
|
|
203
|
-
|
|
204
|
-
Authentication:
|
|
205
|
-
- Mistral: key read from `Config` (user config at `providers.mistral.api_key`).
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
---
|
|
209
|
-
|
|
210
|
-
## Recording formats and conversion
|
|
211
|
-
|
|
212
|
-
- Recording happens in WAV (PCM 16-bit, mono, 16k/32k Hz).
|
|
213
|
-
- Optional conversion via ffmpeg:
|
|
214
|
-
- WAV -> MP3:
|
|
215
|
-
```
|
|
216
|
-
ffmpeg -y -i input.wav -codec:a libmp3lame -q:a 3 output.mp3
|
|
217
|
-
```
|
|
218
|
-
- WAV -> Opus:
|
|
219
|
-
```
|
|
220
|
-
ffmpeg -y -i input.wav -c:a libopus -b:a 24k output.opus
|
|
221
|
-
```
|
|
222
|
-
|
|
223
|
-
The tool will send the converted file if you set `--format mp3` or `--format opus`; otherwise it sends the raw WAV.
|
|
224
|
-
|
|
225
|
-
---
|
|
226
|
-
|
|
227
|
-
## macOS notes
|
|
228
|
-
|
|
229
|
-
- Microphone permission: on first run, macOS will ask for microphone access. Approve it in System Settings > Privacy & Security > Microphone if needed.
|
|
230
|
-
- If you face issues with device selection, we will add a `--device` flag to choose a specific input device.
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
---
|
|
234
|
-
|
|
235
|
-
## License
|
|
236
|
-
|
|
237
|
-
MIT
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|