* Fix: Handle deprecated appindicator package on Debian 13+
Fixes#69
The gir1.2-appindicator3-0.1 package was deprecated in Debian 13 (trixie)
and replaced with gir1.2-ayatana-appindicator3. This change adds fallback
logic to try the new package if the old one is not available.
Changes:
- install.sh: Try old package first, fall back to ayatana-appindicator
- docs/INSTALL.md: Document both package options
- src/vocalinux/main.py: Update error message with Debian 13+ note
- CONTRIBUTING.md: Update dev setup instructions
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix: clean up whitespace in filtered package list
---------
Co-authored-by: Claude Opus <noreply@anthropic.com>
Fixes#66
The --system-site-packages flag causes the virtual environment to inherit
system packages, which can include versions incompatible with newer Python
versions. On Arch/EndeavourOS with Python 3.12, an old coverage package
from the system causes Whisper to fail with:
module 'coverage.types' has no attribute 'Tracer'
By creating an isolated virtual environment, all dependencies are installed
at compatible versions within the venv, avoiding such conflicts.
Problem: Even though the website fetched install.sh from a specific release tag,
the script itself would clone the repository from main branch, installing
potentially unstable/untested code.
Solution:
- Add --tag parameter to install.sh to specify which release to install
- Default to v0.3.0-alpha (latest stable) instead of main
- Clone the specific tag using 'git clone --branch <tag>'
- Update website to pass --tag parameter with fetched release
Changes:
- install.sh: Add --tag parameter, default to v0.3.0-alpha, clone specific tag
- web/src/app/page.tsx: Pass --tag=<version> to install script
This ensures users install the exact release version they intended, not
whatever code is currently on main branch.
Co-authored-by: Claude Opus <noreply@anthropic.com>
- Add vosk_model_size and whisper_model_size to config to track model
selection independently for each engine
- Update config manager with get_model_size_for_engine() and
set_model_size_for_engine() methods for per-engine model tracking
- Add automatic migration for existing configs without per-engine model sizes
- Update settings dialog to use engine-specific model sizes when populating
model options
- Update install.sh to include new per-engine model fields in default config
- Fix: Previously, switching from VOSK to Whisper would incorrectly try to
download the recommended model instead of the previously used model
Fixes the issue where switching back to Whisper after using VOSK would
start downloading the medium model instead of remembering the tiny model
that was configured during installation.
* fix: VOSK-only install and CLI arg handling for low-memory systems
Fixes several issues reported by users on low-memory systems (8GB RAM):
1. Install script: Don't auto-install Whisper in non-interactive mode
- Previously, running 'curl | bash' would install Whisper by default
- Now requires explicit --with-whisper flag to install Whisper
- Prevents OOM errors on systems with limited RAM
2. CLI arguments: Command-line flags now properly override saved config
- --engine vosk now works even if config file has whisper set
- --model flag also properly overrides saved model setting
- Checks sys.argv to detect if user explicitly provided arguments
3. Default engine: Changed from 'whisper' to 'vosk'
- VOSK works on low-memory systems without OOM issues
- Users can still install and use Whisper with --with-whisper flag
- Existing configs with 'whisper' engine are still respected
Reported issues:
- OOM during installation on 8GB RAM system
- vocalinux --engine vosk being ignored
- Config file not respected when trying to force VOSK
* fix: keep whisper as default engine, improve test robustness
- Reverted default engine back to 'whisper' for better accuracy
- Install script still defaults to VOSK-only install (--with-whisper for Whisper)
- CLI args still properly override saved config
- Improved test_config_manager tests to handle module caching issues
* fix: default to Whisper install, --no-whisper for VOSK-only on low-RAM systems
Updated install behavior:
- Default (curl|bash): Installs Whisper for best experience
- --no-whisper flag: Skips Whisper AND creates config with VOSK as default engine
This allows low-RAM users (8GB) to run:
curl -fsSL .../install.sh | bash -s -- --no-whisper
Which will:
1. Skip installing torch/whisper (avoids OOM)
2. Create ~/.config/vocalinux/config.json with engine='vosk'
3. App will use VOSK by default without needing CLI flags
* docs: clarify --no-whisper is for low-RAM systems (8GB or less)
Updated README and website to explain that --no-whisper flag:
- Is intended for systems with 8GB RAM or less
- Avoids out-of-memory errors during installation
- Configures VOSK as the default speech recognition engine
* feat: add --whisper-cpu flag for CPU-only PyTorch installation
New installation option for users without NVIDIA GPU or with limited RAM:
Install script changes:
- Added --whisper-cpu flag: Installs CPU-only PyTorch (~200MB vs ~2.3GB)
- Uses https://download.pytorch.org/whl/cpu index for smaller torch package
- Interactive mode now offers 3 options: GPU, CPU-only, or skip Whisper
- Updated help text to explain all Whisper installation options
Documentation updates:
- README: Added --whisper-cpu example with explanation
- Website: Added new 'Whisper CPU-only' install option section
Installation options summary:
- Default (curl|bash): Whisper + GPU/CUDA support (~2.3GB, 5-10 min)
- --whisper-cpu: Whisper + CPU-only PyTorch (~200MB, 3-4 min)
- --no-whisper: VOSK only, no Whisper (~2-3 min)
* feat: Make Whisper tiny the default engine and download during install
- Changed default engine from 'vosk' to 'whisper' in config_manager.py
- Changed default model_size from 'small' to 'tiny' in config_manager.py
- Added install_whisper_model() function to install.sh that downloads
the Whisper tiny model (~75MB) during installation
- Whisper model is downloaded when Whisper package is installed
(in non-interactive mode or with --with-whisper flag)
- Updated installation summary to show Whisper model status
- Updated documentation (README.md, INSTALL.md, SECURITY.md, USER_GUIDE.md)
to reflect Whisper tiny as the default engine
This provides a better out-of-box experience: users can install and
immediately use Vocalinux without any additional downloads or prompts.
* test: Update test to reflect whisper as default engine
* fix: install/uninstall scripts for curl | bash usage
Install script improvements:
- Detect non-interactive mode (curl | bash) automatically
- Skip interactive prompts in non-interactive mode
- Add --no-whisper and -y/--yes flags for explicit control
- Continue with defaults when stdin is not a tty
Uninstall script improvements:
- Clean up curl-installed files:
- ~/.local/share/vocalinux-install (cloned repo)
- ~/.local/share/vocalinux/venv (virtual environment)
- ~/.local/bin/vocalinux (symlink)
- ~/.local/bin/activate-vocalinux.sh
- Add -y/--yes flag for non-interactive mode
- Verify all curl-installed components are removed
README updates:
- Document curl installation with --with-whisper option
- Add uninstall instructions for both methods
- Clarify what gets installed where
* feat: install Whisper by default in non-interactive mode
- curl | bash now installs both VOSK and Whisper out of the box
- Users can freely switch between engines in settings
- Add --no-whisper flag for faster install (VOSK only)
- Update README to reflect new default behavior
* chore: remove install-whisper.sh (now part of install.sh)
Whisper is installed by default via install.sh, making this
separate script redundant.
* chore: remove activate-vocalinux.sh (generated by install.sh)
This file is dynamically created by install.sh based on the
venv location, so the static template is not needed.
* feat: Implement comprehensive Whisper speech recognition support
🎯 Complete Whisper Implementation:
- Proper model size validation and mapping (small->base, medium->small, large->medium)
- GPU/CPU device detection and automatic model placement
- Efficient in-memory audio processing (no temporary files)
- Custom model cache directory for organized storage
- Enhanced error handling with detailed logging
- Optimized transcription parameters for better accuracy
🔧 Technical Improvements:
- Replace temporary file approach with direct tensor processing
- Add torch.no_grad() context for efficient inference
- Implement proper audio normalization and padding
- Add comprehensive error handling and recovery
- Support for both CPU and CUDA acceleration
📦 Installation Integration:
- Add --with-whisper flag to installation script
- Update setup.py with correct openai-whisper dependencies
- Include torch and torchaudio in whisper extras
- Automatic and manual installation options
🧪 Testing & Validation:
- Add comprehensive test suite for Whisper functionality
- Test model size mapping, initialization, and transcription
- Mock-based testing for environments without Whisper installed
- Integration with existing test infrastructure
💡 Performance Optimizations:
- Efficient audio buffer processing without file I/O
- GPU acceleration when available
- Optimized Whisper parameters for real-time usage
- Memory-efficient model loading and caching
🔄 Backward Compatibility:
- Maintains full compatibility with existing VOSK implementation
- Graceful fallback when Whisper dependencies are missing
- No breaking changes to existing API
This implementation provides a production-ready Whisper integration
that significantly improves transcription accuracy while maintaining
the performance characteristics needed for real-time voice dictation.
* feat: Add comprehensive Whisper installation support and error handling
🎯 Enhanced User Experience:
- Add intelligent Whisper import error detection in settings dialog
- Show helpful installation instructions when Whisper is missing
- Automatically revert to VOSK when Whisper selection fails
- Provide multiple installation methods and troubleshooting tips
📋 New Installation Helper:
- Create install-whisper.sh script for dedicated Whisper installation
- Support multiple installation methods (standard, trusted hosts, break-system-packages)
- Comprehensive error handling and fallback options
- Clear instructions for SSL issues and alternative approaches
🔧 Improved Error Handling:
- Detect Whisper import errors specifically in settings dialog
- Show user-friendly dialog with installation instructions
- Graceful fallback to VOSK when Whisper unavailable
- Detailed logging for troubleshooting
💡 User Guidance:
- Step-by-step installation instructions in error dialog
- Multiple installation options for different environments
- Clear explanation of disk space and time requirements
- Troubleshooting tips for common SSL issues
🛠️ Technical Features:
- Automatic virtual environment detection
- Installation verification and model listing
- SSL issue detection and workarounds
- Comprehensive error reporting and recovery
This addresses the immediate issue where users get cryptic errors
when trying to use Whisper without proper installation, providing
clear guidance and multiple solutions for different scenarios.
* feat: Enhance Whisper support and improve Settings UI
## Whisper Implementation Fixes
- Fix Whisper transcription by removing unnecessary audio padding
- Fix API usage: pass numpy array directly instead of torch tensor
- Remove confusing model size remapping (users select exact model names)
- Add fp16=False for CPU to prevent warnings
- Fix missing 'import torch' in install-whisper.sh verification
## Audio System Improvements
- Add ALSA error handler to suppress noisy warnings
- Process remaining audio buffer when stopping recognition (fixes test button)
## Settings Dialog UI Enhancements
- Add model metadata display (download status, size, recommendations)
- Show ✓ for downloaded models, ↓ for pending downloads, ★ for recommended
- Add system-based model recommendations (based on RAM/GPU)
- Implement auto-apply settings on change (remove Apply button)
- Fix VOSK settings visibility when Whisper is selected
- Add VOSK model info panel with same features as Whisper
- Fix test recognition to show results in dialog instead of injecting text
- Fix race condition in test result display
## Startup Improvements
- Load saved config on startup (engine/model now persists correctly)
- Settings are remembered between app restarts
## Code Quality
- Add get_text_callbacks/set_text_callbacks methods for test isolation
- Update tests with proper mocking
* feat: Package VOSK model with installation for faster first-run experience
🚀 Installation Improvements:
- Add VOSK small model download during installation process
- Eliminate first-run model download delay for better user experience
- Add --skip-models option for offline installations
- Include wget, curl, unzip in system dependencies for model download
🔍 Model Management Enhancements:
- Add multi-location model search (user, system-wide, pre-installed)
- Prioritize pre-installed models over downloads
- Add informative logging for model source detection
- Create marker files to identify installer-provided models
📦 Installation Script Features:
- Robust model download with progress indicators
- Internet connectivity checking before download attempts
- Graceful fallback when download fails (runtime download)
- Comprehensive error handling and cleanup
- Installation summary includes model status
🔧 Recognition Manager Updates:
- Check multiple model locations in priority order:
1. User's local models directory
2. System-wide installation directories
3. Download to user directory if not found
- Enhanced logging for model source identification
- Backward compatibility with existing installations
💡 Benefits:
- Faster application startup (no initial model download)
- Better offline installation support
- Reduced first-run friction for users
- Maintains fallback to runtime download if needed
- Clear feedback about model installation status
This addresses the issue where users had to wait for model downloads
on first application launch, making VocaLinux ready to use immediately
after installation.
* fix: Move install_vosk_models function definition before its call
The function was being called before it was defined, causing a
'command not found' error during installation. Fixed by moving
the function definition to before the installation steps where
it's called.
This resolves the installation error:
./install.sh: line 701: install_vosk_models: command not found
* Implement custom icon for Vocalinux (Closes#10)
* Fix system tray icon display issue
* Temp commit before purging
* refactor: restructure project into proper vocalinux package
* test: fix and improve audio_feedback and tray_indicator tests with proper mocking and isolation
* test: update import paths in test files to use the new package structure
* Remove icon background
* fix: implement robust resource path discovery in audio_feedback module
* fix: improve resource discovery across application for consistent icon and sound loading
* chore: ensure uninstall script is compatible with new resource paths
* Fix black formatting