Spaces:
Build error

File size: 976 Bytes
161c152
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/usr/bin/env python3
import subprocess
import sys

print("🔧 Installing Voice Translator (Simplified)...")
print("="*60)

# Install required packages
packages = [
    'SpeechRecognition==3.10.0',
    'gTTS==2.4.0',
    'requests==2.31.0',
    'streamlit==1.28.0',
    'pyttsx3==2.90',
    'pydub==0.25.1',
    'numpy==1.24.3',
]

for package in packages:
    print(f"Installing {package}...")
    subprocess.check_call([sys.executable, '-m', 'pip', 'install', package])

print("\n" + "="*60)
print("✅ Installation complete!")
print("\n🚀 How to run:")
print("1. Console app: python voice_translator_final.py")
print("2. Web app: streamlit run web_translator_final.py")
print("\n💡 For microphone on Windows:")
print("- Install PyAudio from: https://www.lfd.uci.edu/~gohlke/pythonlibs/#pyaudio")
print("- Or use text input if microphone doesn't work")
print("\n🎯 Features:")
print("- No complex dependencies")
"- Works on all platforms"
"- Audio via system player"