Pure Swift/SwiftUI implementation of Vhisper voice input app for macOS.
-
Multiple ASR Engines
- Qwen Realtime (WebSocket streaming)
- DashScope Paraformer
- OpenAI Whisper
- FunASR (local deployment)
-
LLM Text Refinement
- DashScope (Qwen)
- OpenAI ChatGPT
- Ollama (local)
-
System Integration
- Global hotkey support
- Menu bar app
- Waveform visualization
- Direct text input (Espanso-style)
- macOS 14.0+
- Xcode 15.0+
- Swift 5.9+
- Open Xcode
- File > New > Project
- Select "macOS" > "App"
- Configure:
- Product Name:
VhisperNative - Team: Your team
- Organization Identifier:
com.yourcompany - Interface: SwiftUI
- Language: Swift
- Product Name:
- Delete the default
ContentView.swiftandVhisperNativeApp.swift - Drag the
VhisperNativefolder contents into your project - Make sure "Copy items if needed" is checked
-
Select the project in navigator
-
Select the target
-
Under "Signing & Capabilities":
- Add "App Sandbox" capability (disable if needed for accessibility)
- Enable "Audio Input"
- Enable "Outgoing Connections (Client)"
-
Update Info.plist:
- Add
NSMicrophoneUsageDescription - Set
LSUIElementtoYES(menu bar only app)
- Add
- Select "My Mac" as destination
- Build and run (Cmd+R)
- Click the menu bar icon
- Open Settings
- Configure your ASR provider and API key
- Optionally enable LLM text refinement
Default hotkey is Option key. You can change it in Settings > General.
The app requires:
- Microphone: For voice recording
- Accessibility: For global hotkeys and text input
Grant these permissions in System Settings > Privacy & Security.
VhisperNative/
├── App/ # Application entry
├── Core/
│ ├── ASR/ # Speech recognition services
│ ├── LLM/ # Language model services
│ ├── Audio/ # Audio recording & FFT
│ ├── Pipeline/ # Voice processing pipeline
│ └── Config/ # Configuration management
├── System/
│ ├── Hotkey/ # Global hotkey management
│ ├── Output/ # Text output & clipboard
│ └── Permissions/ # Permission management
├── UI/
│ ├── Settings/ # Settings views
│ └── Waveform/ # Waveform visualization
└── Managers/ # State management
Copyright 2024. All rights reserved.