Skip to content

Commit

Permalink
[CS] add and fix intents in the satellite area (home-assistant#2036)
Browse files Browse the repository at this point in the history
* lights in the satellite area

* set cover position in the satellite area

* consistent spaces in optional phrases

* covers in the satelitte area

* light set in the satellite area

* never mind
  • Loading branch information
bruxy70 authored and schizza committed Mar 16, 2024
1 parent 2e63084 commit 86c5879
Show file tree
Hide file tree
Showing 15 changed files with 159 additions and 28 deletions.
2 changes: 1 addition & 1 deletion sentences/cs/_common.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ expansion_rules:
vypnout: "(vypni|vypnout|zastavit|zastav)"
rozsvitit: "(rozsviť|rozsvítit|rožn(i|out))" #some dialect to be served for users :)
zhasnout: "(zhasni|zhasnout)"
svetla: "(světlo|[všechna ]světla)"
svetla: "(svět(lo|el)|[všech[na] ]svět(la|el))"
nastavit: "(nastav|nastavit)"
zmenit: "(změň|změnit)"
ztlumit: "(ztlu(m|it)|snížit|sniž)"
Expand Down
9 changes: 9 additions & 0 deletions sentences/cs/cover_HassTurnOff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,12 @@ intents:
- shutter
domain: cover
response: cover

- sentences:
- "<zavrit> {cover_classes:device_class}"
slots:
domain: cover
response: cover
requires_context:
area:
slot: true
9 changes: 9 additions & 0 deletions sentences/cs/cover_HassTurnOn.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,12 @@ intents:
- shutter
domain: cover
response: cover

- sentences:
- "<otevrit> {cover_classes:device_class}"
slots:
domain: cover
response: cover
requires_context:
area:
slot: true
7 changes: 7 additions & 0 deletions sentences/cs/homeassistant_HassNevermind.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
language: cs
intents:
HassNevermind:
data:
- sentences:
- "[to] nevadí"
- "zapomeň na to"
8 changes: 8 additions & 0 deletions sentences/cs/homeassistant_HassSetPosition.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,11 @@ intents:
- valve
- sentences:
- "<nastavit> [polohu] <area> [na] <pozice>"

- sentences:
- "<nastavit> [všechny] {cover_classes:device_class} [na] <pozice>"
slots:
domain: cover
requires_context:
area:
slot: true
41 changes: 31 additions & 10 deletions sentences/cs/light_HassLightSet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ language: cs
intents:
HassLightSet:
data:
# Brightness
- sentences:
- "(<nastavit>|<zmenit>) jas {name} <brightness>"
- "(<ztlumit>|<zvysit>) [jas] {name} <brightness>"
Expand All @@ -16,40 +17,60 @@ intents:

# max intents
- sentences:
- "(<nastavit>|<zvysit>|<zmenit>) [jas] <area> na {max:brightness}"
- "(<nastavit>|<zvysit>|<zmenit>) [jas] <area> [jas] na {max:brightness}"
- "(<nastavit>|<zvysit>|<zmenit>) [na] {max:brightness} [jas] <area>"
- "[jas] <area> (<zvysit>|<nastavit>|<zmenit>) [jas] [na] [{max:brightness}] [jas] [{max:brightness}]"
- "[jas] <area> (<zvysit>|<nastavit>|<zmenit>) [jas] [na] [{max:brightness}] [jas]"
slots:
name: all
response: brightness
- sentences:
- "(<nastavit>|<zmenit>|<zvysit>) {max:brightness} [jas] [u] {name}"
- "(<nastavit>|<zmenit>|<zvysit>) [jas] [na] {max:brightness} [jas] [u] {name}"
- "(<nastavit>|<zmenit>|<zvysit>) [jas] [u] {name} [na] {max:brightness}"
- "[jas] [u] {name} (<nastavit>|<zvysit>|<zmenit>) [jas] [na] {max:brightness} [jas]"
response: brightness

#min intents
- sentences:
- "(<nastavit>|<zmenit>|<ztlumit>) [jas] <area> na {min:brightness}"
- "(<nastavit>|<zmenit>|<ztlumit>) [na] {min:brightness} [jas] <area>"
- "[jas] <area> (<nastavit>|<zmenit>|<ztlumit>) [jas] [na] [{min:brightness}] [jas] [{min:brightness}]"
- "(<nastavit>|<zmenit>|<ztlumit>) [jas] <area> [jas] na {min:brightness}"
- "(<nastavit>|<zmenit>|<ztlumit>) [na] {max:brightness} [jas] <area>"
- "[jas] <area> (<nastavit>|<zmenit>|<ztlumit>) [jas] [na] [{min:brightness}] [jas]"
slots:
name: all
response: brightness
- sentences:
- "(<nastavit>|<zmenit>|<ztlumit>) {min:brightness} [jas] [u] {name}"
- "(<nastavit>|<zmenit>|<ztlumit>) [jas] [na] {min:brightness} [jas] [u] {name}"
- "(<nastavit>|<zmenit>|<ztlumit>) [jas] [u] {name} [na] {min:brightness}"
- "[jas] [u] {name} (<nastavit>|<ztlumit>|<zmenit>) [jas] [na] {min:brightness} [jas]"
response: brightness

- sentences:
- "(<nastavit>|<zmenit>) {color} [barvu] [na] {name}"
- "(<nastavit>|<zmenit>) [jas] <svetla> na <brightness>"
response: "brightness"
slots:
brightness:
requires_context:
area:
slot: true

# Color
- sentences:
- "(<nastavit>|<zmenit>) [barvu] {name} [na] {color}"
- "(<nastavit>|<zmenit>) {name} na {color} [barvu]"
- "{name} (<zmenit>|<nastavit>) na {color} [barvu]"
- "Barvu {name} (<zmenit>|<nastavit>) na {color} [barvu]"
response: color
- sentences:
- "(<nastavit>|<zmenit>) {color} [barvu] <area>"
- "(<nastavit>|<zmenit>) <area> na {color} [barvu]"
- "<area> (<zmenit>|<nastavit>) [na] {color} [barvu]"
- "(<nastavit>|<zmenit>) [barvu] <area> na {color}"
- "<area> (<zmenit>|<nastavit>) barvu na {color}"
- "Barvu <area> (<zmenit>|<nastavit>) na {color} [barvu]"
- "<area> (<zmenit>|<nastavit>) [na] {color} [barvu]"
- "Barvu <area> (<zmenit>|<nastavit>) na {color}"
response: color

- sentences:
- "(<nastavit>|<zmenit>) [barvu] <svetla> na {color}"
response: "color"
requires_context:
area:
slot: true
16 changes: 9 additions & 7 deletions sentences/cs/light_HassTurnOff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,29 @@ intents:
data:
- sentences:
- "<vypnout> světlo {name}"
- "<zhasnout>[ světlo] {name}"
- "<zhasnout> [světlo] {name}"
- "{name} <vypnout> světlo"
- "{name} <zhasnout>[ světlo]"
- "{name} <zhasnout> [světlo]"
requires_context:
domain: light
slots:
domain: light
response: light
- sentences:
- "<vypnout> <svetla> <area>"
- "<zhasnout>[ <svetla>] <area>"
- "<zhasnout> [<svetla>] <area>"
- "<area> <vypnout> <svetla>"
- "<area> <zhasnout>[ <svetla>]"
- "<area> <zhasnout> [<svetla>]"
slots:
domain: light
response: lights_area
- sentences:
- "(<vypnout>|<zhasnout>)[ úplně][ všechna] světla"
- "(<vypnout>|<zhasnout>) [úplně] [všechna] světla"
- "<vypnout> světlo"
- "<zhasnout>[ světlo]"
- "<zhasnout> [světlo]"
response: "light_all"
requires_context:
area:
slot: true
slots:
domain: "light"
name: "all"
16 changes: 9 additions & 7 deletions sentences/cs/light_HassTurnOn.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,29 @@ intents:
data:
- sentences:
- "<zapnout> světlo {name}"
- "<rozsvitit>[ světlo] {name}"
- "<rozsvitit> [světlo] {name}"
- "{name} <zapnout> světlo"
- "{name} <rozsvitit>[ světlo]"
- "{name} <rozsvitit> [světlo]"
requires_context:
domain: light
slots:
domain: light
response: light
- sentences:
- "<zapnout> <svetla> <area>"
- "<rozsvitit>[ <svetla>] <area>"
- "<rozsvitit> [<svetla>] <area>"
- "<area> <zapnout> <svetla>"
- "<area> <rozsvitit>[ <svetla>]"
- "<area> <rozsvitit> [<svetla>]"
slots:
domain: light
response: lights_area
- sentences:
- "(<zapnout>|<rozsvitit>)[ úplně][ všechna] světla"
- "(<zapnout>|<rozsvitit>) [úplně] [všechna] světla"
- "<zapnout> světlo"
- "<rozsvitit>[ světlo]"
- "<rozsvitit> [světlo]"
response: "light_all"
requires_context:
area:
slot: true
slots:
domain: "light"
name: "all"
12 changes: 12 additions & 0 deletions tests/cs/cover_HassTurnOff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -134,3 +134,15 @@ tests:
- shutter
domain: cover
response: "Zavřeno"

- sentences:
- "zavři rolety"
intent:
name: HassTurnOff
context:
area: Ložnice
slots:
domain: cover
area: Ložnice
device_class: blind
response: "Zavřeno"
12 changes: 12 additions & 0 deletions tests/cs/cover_HassTurnOn.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -154,3 +154,15 @@ tests:
- shutter
domain: cover
response: "Otevřeno"

- sentences:
- "otevři rolety"
intent:
name: HassTurnOn
context:
area: Ložnice
slots:
domain: cover
area: Ložnice
device_class: blind
response: "Otevřeno"
8 changes: 8 additions & 0 deletions tests/cs/homeassistant_HassNevermind.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
language: cs
tests:
- sentences:
- "to nevadí"
- "nevadí"
- "zapomeň na to"
intent:
name: HassNevermind
12 changes: 12 additions & 0 deletions tests/cs/homeassistant_HassSetPosition.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,15 @@ tests:
area: "Ložnici"
position: 50
response: "Pozice nastavena"
- sentences:
- "nastav rolety na 50%"
intent:
name: HassSetPosition
context:
area: "Ložnice"
slots:
domain: cover
area: "Ložnice"
device_class: blind
position: 50
response: "Pozice nastavena"
27 changes: 26 additions & 1 deletion tests/cs/light_HassLightSet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,20 @@ tests:
response:
- Jas nastaven

#color
- sentences:
- "nastav jas světla na 50%"
- "nastav světlo na 50%"
intent:
name: HassLightSet
context:
area: Ložnice
slots:
brightness: 50
area: Ložnice
response:
"Jas nastaven"

#color
- sentences:
- Barvu lampičky v ložnici změň na modrou
- Lampičku v ložnici změň na modrou barvu
Expand Down Expand Up @@ -173,3 +186,15 @@ tests:
color: blue
response:
- Barva nastavena

- sentences:
- "změň barvu světla na červenou"
- "nastav světlo na červenou"
intent:
name: HassLightSet
context:
area: Ložnice
slots:
color: red
area: Ložnice
response: "Barva nastavena"
4 changes: 3 additions & 1 deletion tests/cs/light_HassTurnOff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,10 @@ tests:
- "zhasni"
intent:
name: HassTurnOff
context:
area: "Ložnice"
slots:
domain: light
name: all
area: "Ložnice"
response:
- "Všechna světla byla zhasnuta"
4 changes: 3 additions & 1 deletion tests/cs/light_HassTurnOn.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,10 @@ tests:
- "rozsviť"
intent:
name: HassTurnOn
context:
area: "Ložnice"
slots:
domain: light
name: all
area: "Ložnice"
response:
- "Všechna světla byla rozsvícena"

0 comments on commit 86c5879

Please sign in to comment.