HirCoir commited on
Commit
5887527
1 Parent(s): 0720389

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -16
app.py CHANGED
@@ -12,24 +12,12 @@ app = Flask(__name__)
12
 
13
  # Define the folder where files are saved
14
  file_folder = '/home/app/'
15
-
16
  # Models with specific character replacements
17
  models_replacements = {
18
- "Español México | Claude": {
19
- "model_path": "es_MX-claude-14947-epoch-high.onnx",
20
- "replacements": [('(', ','), (')', ','), ('?', ','), ('¿', ','), (':', ','), ('\n', ' ')]
21
- },
22
- "Español México | Cortana Infinnity": {
23
- "model_path": "es_MX-cortana-19669-epoch-high.onnx",
24
- "replacements": [('(', ','), (')', ','), ('?', ','), ('¿', ','), (':', ','), ('\n', ' ')]
25
- },
26
- "Español México | TheGevy": {
27
- "model_path": "es_MX-gevy-10196-epoch-high.onnx",
28
- "replacements": [('(', ','), (')', ','), ('?', ','), ('¿', ','), (':', ','), ('\n', ' ')]
29
- },
30
- "English US | Voice": {
31
- "model_path": "en_US-ljspeech-high.onnx",
32
- "replacements": [('(', ','), (')', ','), ('?', ','), ('¿', ','), (':', ','), ('\n', ' ')]
33
  }
34
  }
35
 
 
12
 
13
  # Define the folder where files are saved
14
  file_folder = '/home/app/'
15
+ model_name = os.getenv('MODELNAME')
16
  # Models with specific character replacements
17
  models_replacements = {
18
+ model_name: {
19
+ "model_path": model_name + ".onnx",
20
+ "replacements": [(')', ','), ('\n', ' ')]
 
 
 
 
 
 
 
 
 
 
 
 
21
  }
22
  }
23