English | 简体中文 | Español | हिन्दी | العربية
A cutting-edge macOS input method application that integrates local AI services, offering real-time translation, voice recognition, and intelligent text processing in 5 major languages.
FlowKey supports 5 of the world's most widely used languages:
- 🇺🇸 English (Default)
- 🇨🇳 中文 (Chinese)
- 🇪🇸 Español (Spanish)
- 🇮🇳 हिन्दी (Hindi)
- 🇸🇦 العربية (Arabic)
- ✅ Selection Translation: Instant translation of any selected text with overlay UI
- ✅ Quick Translate: Triple-press Space for immediate translation
- ✅ Input Method Translation: Direct text replacement in input fields
- ✅ Hybrid Translation: Online/Local/Smart translation modes
- ✅ Multi-language Support: Seamless switching between major world languages
- ✅ Local AI Translation: MLX-powered offline translation models
- ✅ Speech Recognition: Whisper-based voice dictation and commands
- ✅ Smart Text Detection: Context-aware text analysis and suggestions
- ✅ Intelligent Recommendations: AI-powered contextual suggestions
- ✅ Knowledge Base: Semantic search with personal documents
- ✅ 16 Built-in Commands: Translation, insertion, search, system commands
- ✅ Custom Voice Commands: Create personalized voice commands
- ✅ Global Hotkey: Command+Shift+V for voice activation
- ✅ Real-time Feedback: Visual waveforms and status indicators
- ✅ Multi-language Recognition: Support for Chinese, English, Japanese, Korean
- ✅ Smart Rewrite: Style conversion and grammar correction
- ✅ Template System: Complete document template management
- ✅ Phrase Management: Quick phrase insertion and management
- ✅ Text Style Conversion: Professional terminology optimization
- ✅ User Habit Learning: Intelligent learning of user preferences
- ✅ End-to-End Encryption: Complete privacy protection mechanism
- ✅ Local-First Processing: All AI processing happens on-device
- ✅ Data Backup: Automatic backup and restore system
- ✅ Secure Cloud Sync: iCloud synchronization with conflict resolution
- ✅ Access Control: Granular permission management
- ✅ iCloud Integration: Cross-device data synchronization
- ✅ Offline Mode Support: Full functionality without internet connection
- ✅ Sync Conflict Resolution: Intelligent conflict handling
- ✅ Real-time Sync: Instant updates across all devices
- ✅ Data Consistency: Ensured data integrity across platforms
- Swift + SwiftUI: Native macOS development
- MLX Swift: Local AI inference optimized for Apple Silicon
- IMKInputMethod: Official macOS input method framework
- Core Data: Robust local data persistence
- iCloud Sync: Seamless cross-device synchronization
FlowKey/
├── Sources/FlowKey/
│ ├── App/ # Application entry point
│ ├── InputMethod/ # IME core functionality
│ ├── Models/ # Data models and services
│ ├── Services/ # Business logic layer
│ ├── Views/ # User interface
│ └── Resources/ # Assets and resources
├── Sources/FlowKeyTests/ # Test suite
└── Documentation/ # Project documentation
- macOS 14.0 or later
- Xcode 15.0 or later
- Swift 5.9 or later
- Apple Silicon Mac recommended for AI features
- Clone the repository
git clone <repository-url>
cd flow-key- Build the application
# Development build
swift build
# Release build
swift build -c release- Run the application
# Development mode
swift run
# Or use the build script
./run_app.sh- Copy to Applications
cp -r .build/debug/FlowKey.app /Applications/- Enable Input Method
- Open System Settings > Keyboard > Input Sources
- Click "+" to add new input source
- Select "FlowKey" from the list
- Enable it in your input sources
- Select text in any application
- Translation appears automatically in the overlay
- Use the copy button to save results
- Triple-press Space: Instant translation of current selection
- Cmd+Shift+T: Manual translation trigger
- Cmd+Shift+V: Voice input activation
- Enable voice recognition in Settings
- Click the microphone button or use voice shortcut
- Speak naturally - text is transcribed and translated
- Results appear instantly with copy options
- Open FlowKey Settings
- Navigate to "App Language" section
- Select your preferred language from the dropdown
- Interface updates immediately with full localization
# Install dependencies
swift package update
# Generate Xcode project
swift package generate-xcodeproj
# Run tests
swift test
# Build for release
swift build -c releaseFlowInputController.swift: Handles user input and text processingFlowInputMethod.swift: Main input method class and system registrationFlowCandidateView.swift: Candidate selection interface
MLXService.swift: Local AI model integrationAIService.swift: Unified AI service interfaceSpeechRecognizer.swift: Voice recognition capabilities
LocalizationService.swift: Multilingual support system- Supports 5 major languages with real-time switching
- Complete UI localization with user preference persistence
# Build release version
swift build -c release
# Create app bundle
mkdir -p FlowKey.app/Contents/MacOS
cp .build/release/FlowKey FlowKey.app/Contents/MacOS/
# Sign the app (required for distribution)
codesign --deep --force --verify --verbose --sign "-" FlowKey.appWe welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Follow Swift coding conventions
- Add tests for new features
- Update documentation
- Ensure all tests pass before submitting
A: Copy the app to Applications folder, then go to System Settings > Keyboard > Input Sources, click "+" and select "FlowKey".
A: Check your internet connection for online translation, or ensure local AI models are downloaded for offline mode.
A: Grant microphone permissions in System Settings > Privacy & Security > Microphone, and ensure speech models are downloaded.
A: Open FlowKey Settings, go to "App Language", and select your preferred language from the dropdown menu.
- ✅ Input Method Framework: Complete IMKInputMethod integration
- ✅ Selection Translation: Real-time text selection and translation
- ✅ Quick Translation: Triple-space instant translation
- ✅ Data Storage: Core Data models with encryption
- ✅ Input Field Translation: Direct text replacement functionality
- ✅ Local AI Translation: MLX-powered offline translation models
- ✅ Knowledge Base System: Vector database with semantic search
- ✅ Voice Recognition: Whisper-based speech processing
- ✅ Smart Text Detection: Context-aware text analysis
- ✅ Translation Quality Optimization: Continuous learning system
- ✅ iCloud Integration: Cross-device data synchronization
- ✅ Voice Command System: 16 built-in commands with custom support
- ✅ Smart Text Processing: Style conversion and grammar correction
- ✅ Template System: Complete document template management
- ✅ Phrase Management: Quick phrase insertion and organization
- ✅ End-to-End Encryption: Complete data protection
- ✅ Privacy-First Architecture: All processing on-device
- ✅ Data Backup System: Automatic backup and restore
- ✅ Access Control: Granular permission management
- ✅ 5 Major Languages: English, Chinese, Spanish, Hindi, Arabic
- ✅ Real-time Language Switching: Instant interface localization
- ✅ Complete UI Translation: All interface elements localized
- ✅ User Preference Persistence: Language settings saved automatically
All planned features have been successfully implemented and tested. FlowKey is now a fully-featured intelligent input method with comprehensive AI capabilities.
This project is licensed under the MIT License. See LICENSE for details.
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: hello@zhanghe.dev
- Website: zhanghe.dev
FlowKey — Type smarter. Communicate better. 🚀