Skip to content

Commit f314952

Browse files
committed
feat: implement smart Windows installer with automatic GPU detection and fallback
1 parent b0e5290 commit f314952

File tree

2 files changed

+93
-18
lines changed

2 files changed

+93
-18
lines changed

README.md

Lines changed: 26 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,7 @@ VoiceTypr is an open source AI voice-to-text dictation tool, alternative to Wisp
6666
#### Windows
6767
- Windows 10/11 (64-bit)
6868
- 3-4 GB free disk space (for AI models)
69-
- Two versions available:
70-
- **CPU Version**: Universal compatibility (works on all systems)
71-
- **GPU Version**: Vulkan acceleration (works with NVIDIA, AMD, Intel GPUs)
69+
- GPU acceleration available (5-10x faster with NVIDIA, AMD, Intel GPUs)
7270

7371
### Quick Install
7472

@@ -81,25 +79,18 @@ VoiceTypr is an open source AI voice-to-text dictation tool, alternative to Wisp
8179
> **Note**: VoiceTypr is fully signed and notarized by Apple, so you can run it without security warnings.
8280
8381
#### Windows
84-
1. Choose your version from the [latest release](https://github.com/moinulmoin/voicetypr/releases/latest):
85-
- **VoiceTypr_x.x.x_x64-setup.exe**: CPU version (recommended for most users)
86-
- **VoiceTypr_x.x.x_x64-gpu-setup.exe**: GPU version (faster, requires compatible GPU)
82+
1. Download the latest [VoiceTypr installer](https://github.com/moinulmoin/voicetypr/releases/latest)
8783
2. Run the installer
8884
3. Launch VoiceTypr from Start Menu
8985
4. Follow the onboarding to download your preferred AI model
9086

91-
> **Which version should I choose?**
92-
> - **CPU Version**: Works on any Windows 10/11 PC. Choose this if unsure.
93-
> - **GPU Version**: ~2-3x faster transcription. Requires:
94-
> - Vulkan-compatible GPU (NVIDIA GTX/RTX, AMD Radeon, Intel Arc/Iris Xe)
95-
> - Updated GPU drivers with Vulkan runtime installed
96-
> - ⚠️ **Important**: If the GPU version doesn't start (missing vulkan-1.dll), use the CPU version or update your GPU drivers
97-
98-
> **GPU Version Troubleshooting:**
99-
> - **Error: "vulkan-1.dll was not found"** → Your system lacks Vulkan runtime. Solutions:
100-
> 1. Use the CPU version instead (recommended)
101-
> 2. Update GPU drivers: [NVIDIA](https://www.nvidia.com/drivers) | [AMD](https://www.amd.com/support) | [Intel](https://www.intel.com/content/www/us/en/support/products/80939/graphics.html)
102-
> - The GPU version has a load-time dependency on Vulkan - it won't start without proper GPU drivers
87+
> **GPU Acceleration (5-10x faster)**
88+
> - VoiceTypr automatically uses your GPU if available
89+
> - For best performance, ensure your graphics drivers are up to date:
90+
> - [NVIDIA Drivers](https://www.nvidia.com/drivers)
91+
> - [AMD Drivers](https://www.amd.com/support)
92+
> - [Intel Drivers](https://www.intel.com/content/www/us/en/support/products/80939/graphics.html)
93+
> - Falls back to CPU automatically if GPU unavailable
10394
10495
## 🎮 Usage
10596

@@ -135,6 +126,23 @@ voicetypr/
135126
└── tests/ # Test suites
136127
```
137128

129+
## 🔧 Troubleshooting
130+
131+
### Windows GPU Acceleration
132+
133+
VoiceTypr automatically detects and uses your GPU for faster transcription. If you're experiencing slower performance:
134+
135+
1. **Update your graphics drivers** - This is the most common fix:
136+
- [NVIDIA Drivers](https://www.nvidia.com/drivers)
137+
- [AMD Drivers](https://www.amd.com/support)
138+
- [Intel Drivers](https://www.intel.com/content/www/us/en/support/products/80939/graphics.html)
139+
140+
2. **Check logs** - Enable debug logging in Settings to see if GPU is being used
141+
142+
3. **Verify GPU support** - Modern GPUs (2016+) should work automatically
143+
144+
> **Note**: VoiceTypr always works - it automatically falls back to CPU if GPU acceleration is unavailable
145+
138146
## 📄 License
139147

140148
VoiceTypr is licensed under the [GNU Affero General Public License v3.0](LICENSE.md).

scripts/release-windows.ps1

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ if (-not $SkipBuild) {
132132

133133
# Sign if key available
134134
$keyPath = "$env:USERPROFILE\.tauri\voicetypr.key"
135+
$signature = ""
135136
if (Test-Path $keyPath) {
136137
Write-Info "Signing update artifact..."
137138
$env:TAURI_SIGNING_PRIVATE_KEY_PATH = $keyPath
@@ -140,11 +141,71 @@ if (-not $SkipBuild) {
140141

141142
if (Test-Path "$zipPath.sig") {
142143
Write-Success "Update artifact signed"
144+
# Read signature for latest.json - ensure proper formatting
145+
$signature = (Get-Content "$zipPath.sig" -Raw).Trim()
146+
# Remove any potential line breaks within the signature
147+
$signature = $signature -replace "`r`n", "" -replace "`n", ""
148+
Write-Info "Signature captured: $($signature.Substring(0, [Math]::Min(50, $signature.Length)))..."
143149
} else {
144150
Write-Warning "Failed to sign update artifact"
151+
$signature = ""
145152
}
146153
} else {
147154
Write-Warning "No signing key found - updates won't have signatures"
155+
$signature = ""
156+
}
157+
158+
# Update latest.json with Windows platform
159+
Write-Info "Updating latest.json with Windows platform..."
160+
161+
$latestJsonPath = "$OutputDir\latest.json"
162+
163+
# Try to download existing latest.json from GitHub release
164+
Write-Info "Checking for existing latest.json in release..."
165+
try {
166+
# Download latest.json if it exists in the release
167+
$null = gh release download $ReleaseTag -p "latest.json" -D $OutputDir --clobber 2>&1
168+
if (Test-Path $latestJsonPath) {
169+
Write-Success "Downloaded existing latest.json from release"
170+
}
171+
} catch {
172+
Write-Info "No existing latest.json found in release"
173+
}
174+
175+
if (Test-Path $latestJsonPath) {
176+
# Read existing latest.json
177+
$latestJson = Get-Content $latestJsonPath -Raw | ConvertFrom-Json
178+
179+
# Add Windows platform
180+
if (-not $latestJson.platforms) {
181+
$latestJson | Add-Member -NotePropertyName "platforms" -NotePropertyValue @{} -Force
182+
}
183+
184+
$latestJson.platforms."windows-x86_64" = @{
185+
signature = $signature
186+
url = "https://github.com/moinulmoin/voicetypr/releases/download/$ReleaseTag/VoiceTypr_${Version}_x64-setup.exe.zip"
187+
}
188+
189+
# Save updated latest.json
190+
$latestJson | ConvertTo-Json -Depth 10 | Set-Content $latestJsonPath
191+
Write-Success "Updated latest.json with Windows platform"
192+
} else {
193+
# Create new latest.json if it doesn't exist (Windows-only release)
194+
Write-Info "Creating new latest.json for Windows..."
195+
$latestJson = @{
196+
version = "v$Version"
197+
notes = "See the release notes for v$Version"
198+
pub_date = (Get-Date).ToUniversalTime().ToString("yyyy-MM-dd'T'HH:mm:ss'Z'")
199+
platforms = @{
200+
"windows-x86_64" = @{
201+
signature = $signature
202+
url = "https://github.com/moinulmoin/voicetypr/releases/download/$ReleaseTag/VoiceTypr_${Version}_x64-setup.exe.zip"
203+
}
204+
}
205+
}
206+
207+
$latestJson | ConvertTo-Json -Depth 10 | Set-Content $latestJsonPath
208+
Write-Success "Created latest.json for Windows"
148209
}
149210
}
150211

@@ -172,6 +233,12 @@ if (-not $SkipPublish) {
172233
}
173234
}
174235

236+
# Upload latest.json
237+
if (Test-Path "$OutputDir\latest.json") {
238+
Write-Info "Uploading latest.json..."
239+
gh release upload $ReleaseTag "$OutputDir\latest.json" --clobber
240+
}
241+
175242
Write-Success "Installer and update artifacts uploaded"
176243
}
177244

0 commit comments

Comments
 (0)