You've already forked Irene-Voice-Assistant
mirror of
https://github.com/janvarev/Irene-Voice-Assistant.git
synced 2025-11-23 22:45:08 +02:00
v2.1
- добавлен STT через SpeechRecognition - поправлено ридми, чтобы это отразить - поправлен plugin_timer.py для работы с числами - откомментирован plugin_greetings.py
This commit is contained in:
@@ -63,6 +63,12 @@ def set_timer(core:VACore, phrase:str):
|
||||
set_timer_real(core,i,txt)
|
||||
return
|
||||
|
||||
txt3 = str(i) + " секунд "
|
||||
if phrase.startswith(txt3):
|
||||
#print(txt,txt2)
|
||||
set_timer_real(core,i,txt)
|
||||
return
|
||||
|
||||
# ставим минуты?
|
||||
for i in range(1,100):
|
||||
txt = num_to_text.num2text(i, female_units_min) + " "
|
||||
@@ -75,6 +81,12 @@ def set_timer(core:VACore, phrase:str):
|
||||
set_timer_real(core,i*60,txt)
|
||||
return
|
||||
|
||||
txt3 = str(i) + " минут "
|
||||
if phrase.startswith(txt3):
|
||||
#print(txt,txt2)
|
||||
set_timer_real(core,i*60,txt)
|
||||
return
|
||||
|
||||
# без указания единиц измерения - ставим минуты
|
||||
for i in range(1,100):
|
||||
txt = num_to_text.num2text(i, female_units_min) + " "
|
||||
@@ -83,6 +95,12 @@ def set_timer(core:VACore, phrase:str):
|
||||
set_timer_real(core,i*60,txt)
|
||||
return
|
||||
|
||||
txt3 = str(i)
|
||||
if phrase.startswith(txt3):
|
||||
#print(txt,txt2)
|
||||
set_timer_real(core,i*60,txt)
|
||||
return
|
||||
|
||||
# спецкейс под одну минуту
|
||||
if phrase.startswith("один ") or phrase.startswith("одна ") or phrase.startswith("одну "):
|
||||
txt = num_to_text.num2text(1, female_units_min)
|
||||
|
||||
Reference in New Issue
Block a user