Skip to content

Commit 3b36037

Browse files
JarbasAlgitlocalize-app[bot]femelomt-gitlocalizemarccasadesus
authored
Release 0.2.21a2 (#75)
* Add pt-BR (#55) * Translate skill.json via GitLocalize * Translate dialogs.json via GitLocalize * Translate intents.json via GitLocalize * Translate vocabs.json via GitLocalize --------- Co-authored-by: Flávio De Melo <flavio.eler@gmail.com> Co-authored-by: mt-gitlocalize <mt@gitlocalize.com> * Update translations * Increment Version to 0.2.20a1 * Update Changelog * es-es/translate (#57) * Translate dialogs.json via GitLocalize * Translate vocabs.json via GitLocalize --------- Co-authored-by: marccasadesus <marc.casadesus.bsc@gmail.com> * Update translations * Increment Version to 0.2.20a2 * Update Changelog * Translate intents.json via GitLocalize (#59) Co-authored-by: marccasadesus <marc.casadesus.bsc@gmail.com> * Update translations * Increment Version to 0.2.20a3 * Update Changelog * Add renovate.json (#61) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Increment Version to 0.2.20a4 * Update Changelog * Update dependency python to 3.14 (#63) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Increment Version to 0.2.20a5 * Update Changelog * Update stefanzweifel/git-auto-commit-action action to v7 (#68) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Increment Version to 0.2.20a6 * Update Changelog * Update dependency ovos-workshop to v8 (#67) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Increment Version to 0.2.20a7 * Update Changelog * Translate intents.json via GitLocalize (#70) Co-authored-by: Andreas Lorensen <andlo@outlook.dk> * Update translations * Translate intents.json via GitLocalize (#69) Co-authored-by: nuriapochatbsc <nuria.poch.at.bsc@gmail.com> * Increment Version to 0.2.20a8 * Update translations * Increment Version to 0.2.20a9 * Update Changelog * Update actions/checkout action to v6 (#64) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Update actions/setup-python action to v6 (#66) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> * Increment Version to 0.2.20a10 * Increment Version to 0.2.20a11 * Update Changelog * fix: is_dictating (#71) * fix: is_dictating * 📝 Add docstrings to `JarbasAl-patch-1` (#72) Docstrings generation was requested by @JarbasAl. * #71 (comment) The following files were modified: * `__init__.py` Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: JarbasAI <33701864+JarbasAl@users.noreply.github.com> --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * Increment Version to 0.2.21a1 * Update Changelog * Update release_workflow.yml * Update Python version from 3.14 to 3.11 * Increment Version to 0.2.21a2 --------- Co-authored-by: gitlocalize-app[bot] <55277160+gitlocalize-app[bot]@users.noreply.github.com> Co-authored-by: Flávio De Melo <flavio.eler@gmail.com> Co-authored-by: mt-gitlocalize <mt@gitlocalize.com> Co-authored-by: JarbasAl <JarbasAl@users.noreply.github.com> Co-authored-by: marccasadesus <marc.casadesus.bsc@gmail.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Andreas Lorensen <andlo@outlook.dk> Co-authored-by: JarbasAl <33701864+JarbasAl@users.noreply.github.com> Co-authored-by: nuriapochatbsc <nuria.poch.at.bsc@gmail.com> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2 parents 7f02b40 + e7a0937 commit 3b36037

36 files changed

+1511
-417
lines changed

.github/workflows/publish_stable.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ jobs:
1919
if: success() # Ensure this job only runs if the previous job succeeds
2020
runs-on: ubuntu-latest
2121
steps:
22-
- uses: actions/checkout@v4
22+
- uses: actions/checkout@v6
2323
with:
2424
ref: master
2525
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
2626
- name: Setup Python
27-
uses: actions/setup-python@v5
27+
uses: actions/setup-python@v6
2828
with:
29-
python-version: "3.10"
29+
python-version: "3.11"
3030
- name: Install Build Tools
3131
run: |
3232
python -m pip install build wheel
@@ -61,12 +61,12 @@ jobs:
6161
if: success() # Ensure this job only runs if the previous job succeeds
6262
runs-on: ubuntu-latest
6363
steps:
64-
- uses: actions/checkout@v4
64+
- uses: actions/checkout@v6
6565
with:
6666
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
6767
ref: master
6868
- name: Push master -> dev
6969
uses: ad-m/github-push-action@master
7070
with:
7171
github_token: ${{ secrets.GITHUB_TOKEN }}
72-
branch: dev
72+
branch: dev

.github/workflows/release_workflow.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Check out repository
15-
uses: actions/checkout@v4
15+
uses: actions/checkout@v6
1616
with:
1717
ref: dev
1818
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
1919
- name: Setup Python
20-
uses: actions/setup-python@v5
20+
uses: actions/setup-python@v6
2121
with:
2222
python-version: "3.11"
2323

@@ -30,7 +30,7 @@ jobs:
3030
python scripts/sync_translations.py
3131
3232
- name: Commit to dev
33-
uses: stefanzweifel/git-auto-commit-action@v4
33+
uses: stefanzweifel/git-auto-commit-action@v7
3434
with:
3535
commit_message: Update translations
3636
branch: dev
@@ -52,7 +52,7 @@ jobs:
5252
needs: publish_alpha
5353
runs-on: ubuntu-latest
5454
steps:
55-
- uses: actions/checkout@v4
55+
- uses: actions/checkout@v6
5656
- name: Send message to Matrix bots channel
5757
id: matrix-chat-message
5858
uses: fadenb/matrix-chat-message@v0.0.6
@@ -69,12 +69,12 @@ jobs:
6969
if: success() # Ensure this job only runs if the previous job succeeds
7070
runs-on: ubuntu-latest
7171
steps:
72-
- uses: actions/checkout@v4
72+
- uses: actions/checkout@v6
7373
with:
7474
ref: dev
7575
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
7676
- name: Setup Python
77-
uses: actions/setup-python@v5
77+
uses: actions/setup-python@v6
7878
with:
7979
python-version: "3.11"
8080
- name: Install Build Tools
@@ -97,14 +97,14 @@ jobs:
9797
runs-on: ubuntu-latest
9898
steps:
9999
- name: Checkout dev branch
100-
uses: actions/checkout@v4
100+
uses: actions/checkout@v6
101101
with:
102102
ref: dev
103103

104104
- name: Setup Python
105-
uses: actions/setup-python@v5
105+
uses: actions/setup-python@v6
106106
with:
107-
python-version: '3.10'
107+
python-version: '3.11'
108108

109109
- name: Get version from setup.py
110110
id: get_version

CHANGELOG.md

Lines changed: 87 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,98 @@
11
# Changelog
22

3-
## [0.2.19a1](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.19a1) (2025-06-07)
3+
## [0.2.21a1](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.21a1) (2026-02-27)
44

5-
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/V0.2.18...0.2.19a1)
5+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a10...0.2.21a1)
66

77
**Merged pull requests:**
88

9-
- fix:workshop 7.0.0 compat [\#53](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/53) ([JarbasAl](https://github.com/JarbasAl))
9+
- fix: is\_dictating [\#71](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/71) ([JarbasAl](https://github.com/JarbasAl))
1010

11-
## [V0.2.18](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/V0.2.18) (2025-06-07)
11+
## [0.2.20a10](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a10) (2026-02-03)
1212

13-
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.18...V0.2.18)
13+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a11...0.2.20a10)
14+
15+
## [0.2.20a11](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a11) (2026-02-03)
16+
17+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a9...0.2.20a11)
18+
19+
**Merged pull requests:**
20+
21+
- Update actions/setup-python action to v6 [\#66](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/66) ([renovate[bot]](https://github.com/apps/renovate))
22+
- Update actions/checkout action to v6 [\#64](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/64) ([renovate[bot]](https://github.com/apps/renovate))
23+
24+
## [0.2.20a9](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a9) (2026-01-19)
25+
26+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a8...0.2.20a9)
27+
28+
## [0.2.20a8](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a8) (2026-01-19)
29+
30+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a7...0.2.20a8)
31+
32+
**Merged pull requests:**
33+
34+
- da-dk/translate [\#70](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/70) ([gitlocalize-app[bot]](https://github.com/apps/gitlocalize-app))
35+
- ca-es/translate [\#69](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/69) ([gitlocalize-app[bot]](https://github.com/apps/gitlocalize-app))
36+
37+
## [0.2.20a7](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a7) (2025-12-19)
38+
39+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a6...0.2.20a7)
40+
41+
**Merged pull requests:**
42+
43+
- Update dependency ovos-workshop to v8 [\#67](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/67) ([renovate[bot]](https://github.com/apps/renovate))
44+
45+
## [0.2.20a6](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a6) (2025-12-19)
46+
47+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a5...0.2.20a6)
48+
49+
**Merged pull requests:**
50+
51+
- Update stefanzweifel/git-auto-commit-action action to v7 [\#68](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/68) ([renovate[bot]](https://github.com/apps/renovate))
52+
53+
## [0.2.20a5](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a5) (2025-12-19)
54+
55+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a4...0.2.20a5)
56+
57+
**Merged pull requests:**
58+
59+
- Update dependency python to 3.14 [\#63](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/63) ([renovate[bot]](https://github.com/apps/renovate))
60+
61+
## [0.2.20a4](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a4) (2025-12-18)
62+
63+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a3...0.2.20a4)
64+
65+
**Merged pull requests:**
66+
67+
- Configure Renovate [\#61](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/61) ([renovate[bot]](https://github.com/apps/renovate))
68+
69+
## [0.2.20a3](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a3) (2025-11-20)
70+
71+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a2...0.2.20a3)
72+
73+
**Merged pull requests:**
74+
75+
- es-es/translate [\#59](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/59) ([gitlocalize-app[bot]](https://github.com/apps/gitlocalize-app))
76+
77+
## [0.2.20a2](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a2) (2025-11-19)
78+
79+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.20a1...0.2.20a2)
80+
81+
**Merged pull requests:**
82+
83+
- es-es/translate [\#57](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/57) ([gitlocalize-app[bot]](https://github.com/apps/gitlocalize-app))
84+
85+
## [0.2.20a1](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/0.2.20a1) (2025-09-29)
86+
87+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/V0.2.19...0.2.20a1)
88+
89+
**Merged pull requests:**
90+
91+
- Add pt-BR [\#55](https://github.com/OpenVoiceOS/ovos-skill-dictation/pull/55) ([gitlocalize-app[bot]](https://github.com/apps/gitlocalize-app))
92+
93+
## [V0.2.19](https://github.com/OpenVoiceOS/ovos-skill-dictation/tree/V0.2.19) (2025-06-07)
94+
95+
[Full Changelog](https://github.com/OpenVoiceOS/ovos-skill-dictation/compare/0.2.19...V0.2.19)
1496

1597

1698

__init__.py

Lines changed: 55 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,14 @@ def initialize(self):
4242

4343
@property
4444
def default_listen_mode(self):
45+
"""
46+
Determine the default listener mode from the configuration.
47+
48+
Selects 'continuous' when the listener's `continuous_listen` setting is true, otherwise selects 'hybrid' when `hybrid_listen` is true, and falls back to 'wakeword' if neither is enabled.
49+
50+
Returns:
51+
str: One of 'continuous', 'hybrid', or 'wakeword' indicating the default listening mode.
52+
"""
4553
listener_config = Configuration().get("listener", {})
4654
if listener_config.get("continuous_listen", False):
4755
return "continuous"
@@ -50,8 +58,35 @@ def default_listen_mode(self):
5058
else:
5159
return "wakeword"
5260

61+
def is_dictating(self, sess) -> bool:
62+
"""
63+
Check whether dictation is active for the given session.
64+
65+
Parameters:
66+
sess: The session object whose dictation state should be checked.
67+
68+
Returns:
69+
True if the session currently has an active dictation, False otherwise.
70+
"""
71+
if sess.session_id in self.dictation_sessions:
72+
return self.dictation_sessions[sess.session_id].get("dictating", False)
73+
return False
74+
5375
@adds_context("DictationKeyword", "dictation")
5476
def start_dictation(self, message=None):
77+
"""
78+
Begin a dictation session for the current conversation session.
79+
80+
Creates or updates an entry in self.dictation_sessions for the session returned by SessionManager.get(message) with:
81+
- file_name taken from message.data["name"] if present, otherwise the current timestamp,
82+
- dictating set to True,
83+
- an empty dictation_stack.
84+
85+
Also emits a bus message to set the recognizer loop mode to "continuous".
86+
87+
Parameters:
88+
message (Message, optional): Incoming message whose .data may contain a "name" key to use as the dictation file name. If omitted, a default Message is used.
89+
"""
5590
message = message or Message("")
5691
sess = SessionManager.get(message)
5792
self.dictation_sessions[sess.session_id] = dict(
@@ -82,15 +117,33 @@ def stop_dictation(self, message=None):
82117

83118
@intent_handler("start_dictation.intent")
84119
def handle_start_dictation_intent(self, message):
85-
if not self.dictating:
120+
"""
121+
Handle the user intent to begin dictation for the current session.
122+
123+
Speaks a confirmation dialog ("start") if dictation is not already active for the session, or an "already_dictating" dialog if it is, then enables dictation listening for the session.
124+
125+
Parameters:
126+
message: Bus message containing the intent payload and session information.
127+
"""
128+
sess = SessionManager.get(message)
129+
if not self.is_dictating(sess):
86130
self.speak_dialog("start", wait=True)
87131
else:
88132
self.speak_dialog("already_dictating", wait=True)
89133
self.start_dictation(message) # enable continuous listening, no wake word needed
90134

91135
@intent_handler("stop_dictation.intent")
92136
def handle_stop_dictation_intent(self, message):
93-
if self.dictating:
137+
"""
138+
Handle a stop-dictation intent by notifying the user and stopping any active dictation.
139+
140+
If there is no active dictation for the session, speaks the "stop" dialog; otherwise speaks "not_dictating". Always invokes stop_dictation to ensure dictation is terminated and saved as appropriate.
141+
142+
Parameters:
143+
message: The incoming intent message containing session and intent data.
144+
"""
145+
sess = SessionManager.get(message)
146+
if not self.is_dictating(sess):
94147
self.speak_dialog("stop")
95148
else:
96149
self.speak_dialog("not_dictating")

locale/ca-es/intents/start_dictation.intent

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,14 +63,17 @@ comença a convertir la veu en text
6363
comença a convertir sa veu en text
6464
comença a desar a text
6565
comença a desar com a text
66+
comença a desar en text
6667
comença a desar les paraules parlades
6768
comença a desar ses paraules parlades
6869
comença a enregistrar el text
6970
comença a enregistrar es text
7071
comença a enregistrar informació verbal
72+
comença a enregistrar la informació verbal
7173
comença a escriure des de la veu
7274
comença a escriure des de sa veu
7375
comença a escriure des de veu
76+
comença a escriure per veu
7477
comença a escriure text
7578
comença a escriure text com a {name}
7679
comença a fer dictats
@@ -85,6 +88,8 @@ comença a guardar a text
8588
comença a guardar com a text
8689
comença a guardar les paraules parlades
8790
comença a guardar ses paraules parlades
91+
comença a prendre dictat
92+
comença a prendre el dictat anomenat {name}
8893
comença a prendre notes
8994
comença a prendre notes amb el nom de {name}
9095
comença a prendre notes amb el nom de {name} si us plau

locale/ca-es/intents/stop_dictation.intent

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
acaba amb el dictat
22
acaba amb es dictat
33
acaba la presa de notes
4+
acaba la transcripció
45
acabem amb el dictat
56
acabem amb es dictat
67
acabem amb la presa de notes

locale/da/intents/start_dictation.intent

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,18 @@ begynd at konvertere tale til tekst
1818
begynd at oprette tekstudskrift
1919
begynd at optage tekst
2020
begynd at optage tekst som {name}
21+
begynd at skrive fra stemmen
22+
begynd at skrive tekst
23+
begynd at skrive tekst som {name}
2124
begynd at tage noter
2225
begynd at tage noter kald venligst {name}
2326
begynd at tage noter med navnet {name}
2427
begynd at tage noter med navnet {navn}
2528
begynd at tage noter nu kald venligst {name}
2629
begynd at tage noter nu med navnet {name}
30+
begynd at tage tekstnoter
31+
begynd at transskribere
32+
begynd at transskribere lyd som {name}
2733
begynd at transskribere som {name}
2834
begynd diktat
2935
begynd diktat med navn {name}

locale/da/intents/stop_dictation.intent

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,5 +54,4 @@ lad os stoppe transskriptionen
5454
stop diktering
5555
stop med at fange tekst
5656
stop med at tage noter
57-
stop transskription
58-
stoppe med at tage noter
57+
stop transskription
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
El dictado ya está habilitado
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
El último dictado fue
2+
Leyendo el último dictado

0 commit comments

Comments
 (0)