Skip to content

Commit

Permalink
Adding Marathi Language (#2878)
Browse files Browse the repository at this point in the history
  • Loading branch information
sacbhale authored Feb 7, 2025
1 parent 0529e2b commit 93591f3
Show file tree
Hide file tree
Showing 125 changed files with 1,080 additions and 0 deletions.
2 changes: 2 additions & 0 deletions languages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,8 @@ mn:
nativeName: монгол хэл
leaders:
- chuk-a
mr:
nativeName: Marathi
ms:
nativeName: Bahasa Melayu
leaders:
Expand Down
17 changes: 17 additions & 0 deletions responses/mr/HassCancelAllTimers.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
language: mr
responses:
intents:
HassCancelAllTimers:
default:
"TODO: {% if slots.canceled < 1: %} No timers were canceled. {% elif
slots.canceled == 1: %} Canceled 1 timer. {% else: %} Canceled {{ slots.canceled
}} timers. {% endif %}
"
area:
"TODO: {% if slots.canceled < 1: %} No timers were canceled in {{ slots.area
}}. {% elif slots.canceled == 1: %} Canceled 1 timer in {{ slots.area }}.
{% else: %} Canceled {{ slots.canceled }} timers in {{ slots.area }}. {% endif
%}
"
5 changes: 5 additions & 0 deletions responses/mr/HassCancelTimer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassCancelTimer:
default: "TODO: Timer cancelled"
10 changes: 10 additions & 0 deletions responses/mr/HassClimateGetTemperature.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
language: mr
responses:
intents:
HassClimateGetTemperature:
default:
"TODO: {% set temperature = state_attr(state.entity_id, 'current_temperature')
%} {% if temperature == 1: %} {{ temperature }} degree {% else: %} {{ temperature
}} degrees {% endif %}
"
5 changes: 5 additions & 0 deletions responses/mr/HassClimateSetTemperature.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassClimateSetTemperature:
default: "TODO: Temperature set"
19 changes: 19 additions & 0 deletions responses/mr/HassDecreaseTimer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
language: mr
responses:
intents:
HassDecreaseTimer:
default:
'TODO: {% set h = slots.hours if slots.hours is defined else none %}
{% set m = slots.minutes if slots.minutes is defined else none %} {% set s
= slots.seconds if slots.seconds is defined else none %} {% set h_text = h
~ ('' hour'' if h in [ "1", ''one''] else '' hours'') if h else '''' %} {%
set m_text = (30 if m in [''half'', ''1/2''] else m) ~ ('' minute'' if m in
[ "1", ''one''] else '' minutes'') if m else '''' %} {% set s_text = (30 if
s in [''half'', ''1/2''] else s) ~ ('' second'' if s in [ "1", ''one''] else
'' seconds'') if s else '''' %} {% set text_list = [ h_text, m_text, s_text]
| select() | list %} {% set text = text_list[:-1] | join('', '') ~ '' and
'' ~ text_list[-1] if text_list | count > 2 else text_list | join('' and '')
%} {% set name = ('' named '' ~ slots.name | trim) if slots.name is defined
else '''' %} {{ text }} removed from timer{{ name }}
'
17 changes: 17 additions & 0 deletions responses/mr/HassGetCurrentDate.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
language: mr
responses:
intents:
HassGetCurrentDate:
default:
"TODO: {% set months = {\n 1: 'January',\n 2: 'February',\n 3:\
\ 'March',\n 4: 'April',\n 5: 'May',\n 6: 'June',\n 7: 'July',\n \
\ 8: 'August',\n 9: 'September',\n 10: 'October',\n 11: 'November',\n\
\ 12: 'December',\n} %} {% set ordinal = {\n 1: '1st',\n 2: '2nd',\n\
\ 3: '3rd',\n 4: '4th',\n 5: '5th',\n 6: '6th',\n 7: '7th',\n \
\ 8: '8th',\n 9: '9th',\n 10: '10th',\n 11: '11th',\n 12: '12th',\n\
\ 13: '13th',\n 14: '14th',\n 15: '15th',\n 16: '16th',\n 17: '17th',\n\
\ 18: '18th',\n 19: '19th',\n 20: '20th',\n 21: '21st',\n 22: '22nd',\n\
\ 23: '23rd',\n 24: '24th',\n 25: '25th',\n 26: '26th',\n 27: '27th',\n\
\ 28: '28th',\n 29: '29th',\n 30: '30th',\n 31: '31st',\n } %}\n{{\
\ months[slots.date.month] }} {{ ordinal[slots.date.day] }}, {{ slots.date.year\
\ }}\n"
12 changes: 12 additions & 0 deletions responses/mr/HassGetCurrentTime.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
language: mr
responses:
intents:
HassGetCurrentTime:
default: "TODO: {% set minute_str = '{0:02d}'.format(slots.time.minute) %}
{% if slots.time.hour == 0: %} 12:{{ minute_str }} AM {% elif slots.time.hour
< 12: %} {{ slots.time.hour }}:{{ minute_str }} AM {% elif slots.time.hour
== 12: %} 12:{{ minute_str }} PM {% else: %} {{ slots.time.hour - 12 }}:{{
minute_str }} PM {% endif %}
"
43 changes: 43 additions & 0 deletions responses/mr/HassGetState.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
language: mr
responses:
intents:
HassGetState:
default: "TODO: {{ state.state_with_unit }}"
one: "TODO: {{ slots.name | capitalize }} is {{ state.state_with_unit }}
"
one_yesno:
"TODO: {% if query.matched %}\n Yes\n{% else %}\n No, {{ state.state_with_unit\
\ }}\n{% endif %}\n"
any:
"TODO: {% if query.matched %}\n {% set match = query.matched | map(attribute=\"\
name\") | sort | list %}\n {% if match | length > 4 %}\n Yes, {{ match[:3]\
\ | join(\", \") }} and {{ (match | length - 3) }} more\n {%- else -%}\n\
\ Yes,\n {% for name in match -%}\n {% if not loop.first and not\
\ loop.last %}, {% elif loop.last and not loop.first %} and {% endif -%}\n\
\ {{ name }}\n {%- endfor -%}\n {% endif %}\n{% else %}\n No\n{%\
\ endif %}\n"
all:
"TODO: {% if not query.unmatched: %}\n Yes\n{% else %}\n {% set no_match\
\ = query.unmatched | map(attribute=\"name\") | sort | list %}\n {% if no_match\
\ | length > 4 %}\n No, {{ no_match[:3] | join(\", \") }} and {{ (no_match\
\ | length - 3) }} more are not {{ slots.state }}\n {%- else -%}\n No,\n\
\ {% for name in no_match -%}\n {% if not loop.first and not loop.last\
\ %}, {% elif loop.last and not loop.first %} and {% endif -%}\n {{ name\
\ }}\n {%- endfor %} {% if no_match | length > 1 %}are{% else %}is{% endif\
\ %} not {{ slots.state }}\n {% endif %}\n{% endif %}\n"
which:
"TODO: {% if not query.matched %}\n Not any\n{% else: %}\n {% set match\
\ = query.matched | map(attribute=\"name\") | sort | list %}\n {% if match\
\ | length > 4 %}\n {{ match[:3] | join(\", \") }} and {{ (match | length\
\ - 3) }} more\n {% else %}\n {%- for name in match -%}\n {% if not\
\ loop.first and not loop.last %}, {% elif loop.last and not loop.first %}\
\ and {% endif -%}\n {{ name }}\n {%- endfor -%}\n {% endif %}\n\
{% endif %}\n"
how_many: "TODO: {{ query.matched | length }}
"
where:
"TODO: {% if state == \"not_home\" %}\n {{ slots.name | capitalize }}\
\ is away\n{% else %}\n {{ slots.name | capitalize }} is at {{ state.state\
\ }}\n{% endif %}\n"
14 changes: 14 additions & 0 deletions responses/mr/HassGetWeather.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
language: mr
responses:
intents:
HassGetWeather:
default:
"TODO: {% set weather_condition = {\n 'clear': 'and clear',\n 'clear-night':\
\ 'and clear',\n 'cloudy': 'and cloudy',\n 'exceptional': 'and exceptional',\n\
\ 'fog': 'with fog',\n 'hail': 'with hail',\n 'lightning': 'with lightning',\n\
\ 'lightning-rainy': 'with lightning and rain',\n 'partlycloudy': 'and partly\
\ cloudy',\n 'pouring': 'and pouring rain',\n 'rainy': 'and raining',\n\
\ 'snowy': 'and snowing',\n 'snowy-rainy': 'with snow and rain',\n 'sunny':\
\ 'and sunny',\n 'windy': 'and windy',\n 'windy-variant': 'with wind and\
\ clouds'\n} %} {{ state.attributes.get('temperature') }} {{ state.attributes.get('temperature_unit')\
\ }} {{ weather_condition.get((state.state | string).lower(), \"\") }}\n"
19 changes: 19 additions & 0 deletions responses/mr/HassIncreaseTimer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
language: mr
responses:
intents:
HassIncreaseTimer:
default:
'TODO: {% set h = slots.hours if slots.hours is defined else none %}
{% set m = slots.minutes if slots.minutes is defined else none %} {% set s
= slots.seconds if slots.seconds is defined else none %} {% set h_text = h
~ ('' hour'' if h in [ "1", ''one''] else '' hours'') if h else '''' %} {%
set m_text = (30 if m in [''half'', ''1/2''] else m) ~ ('' minute'' if m in
[ "1", ''one''] else '' minutes'') if m else '''' %} {% set s_text = (30 if
s in [''half'', ''1/2''] else s) ~ ('' second'' if s in [ "1", ''one''] else
'' seconds'') if s else '''' %} {% set text_list = [ h_text, m_text, s_text]
| select() | list %} {% set text = text_list[:-1] | join('', '') ~ '' and
'' ~ text_list[-1] if text_list | count > 2 else text_list | join('' and '')
%} {% set name = ('' named '' ~ slots.name | trim) if slots.name is defined
else '''' %} {{ text }} added to timer{{ name }}
'
6 changes: 6 additions & 0 deletions responses/mr/HassLightSet.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
language: mr
responses:
intents:
HassLightSet:
brightness: "TODO: Brightness set"
color: "TODO: Color set"
5 changes: 5 additions & 0 deletions responses/mr/HassListAddItem.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassListAddItem:
item_added: "TODO: Added {{ slots.item }}"
5 changes: 5 additions & 0 deletions responses/mr/HassMediaNext.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassMediaNext:
default: "TODO: Playing next"
5 changes: 5 additions & 0 deletions responses/mr/HassMediaPause.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassMediaPause:
default: "TODO: Paused"
5 changes: 5 additions & 0 deletions responses/mr/HassMediaPrevious.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassMediaPrevious:
default: "TODO: Playing previous"
5 changes: 5 additions & 0 deletions responses/mr/HassMediaUnpause.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassMediaUnpause:
default: "TODO: Resumed"
5 changes: 5 additions & 0 deletions responses/mr/HassPauseTimer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassPauseTimer:
default: "TODO: Timer paused"
14 changes: 14 additions & 0 deletions responses/mr/HassRespond.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
language: mr
responses:
intents:
HassRespond:
default: "TODO: "
hello: "TODO: Hello from Home Assistant."
listening: "TODO: No, I only record when you speak the wake word."
data: "TODO: Your data is sent to your Home Assistant server."
commands:
"TODO: To learn what you can ask, visit home dash assistant dot I.O.
slash voice."
creator:
"TODO: I was created by the wonderful Home Assistant community, made
up of tinkerers world wide."
5 changes: 5 additions & 0 deletions responses/mr/HassSetPosition.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassSetPosition:
default: "TODO: Position set"
5 changes: 5 additions & 0 deletions responses/mr/HassSetVolume.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassSetVolume:
default: "TODO: Volume set"
5 changes: 5 additions & 0 deletions responses/mr/HassShoppingListAddItem.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassShoppingListAddItem:
item_added: "TODO: Added {{ slots.item }}"
33 changes: 33 additions & 0 deletions responses/mr/HassStartTimer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
language: mr
responses:
intents:
HassStartTimer:
default:
'TODO: {% set h = slots.hours if slots.hours is defined else none %}
{% set m = slots.minutes if slots.minutes is defined else none %} {% set s
= slots.seconds if slots.seconds is defined else none %} {% set h_text = h
~ ('' hour'' if h in [ "1", ''one''] else '' hours'') if h else '''' %} {%
set m_text = (30 if m in [''half'', ''1/2''] else m) ~ ('' minute'' if m in
[ "1", ''one''] else '' minutes'') if m else '''' %} {% set s_text = (30 if
s in [''half'', ''1/2''] else s) ~ ('' second'' if s in [ "1", ''one''] else
'' seconds'') if s else '''' %} {% set text_list = [ h_text, m_text, s_text]
| select() | list %} {% set text = text_list[:-1] | join('', '') ~ '' and
'' ~ text_list[-1] if text_list | count > 2 else text_list | join('' and '')
%} {% set name = ('' named '' ~ slots.name | trim) if slots.name is defined
else '''' %} Timer set for {{ text }}{{ name }}
'
command:
'TODO: {% set h = slots.hours if slots.hours is defined else none %}
{% set m = slots.minutes if slots.minutes is defined else none %} {% set s
= slots.seconds if slots.seconds is defined else none %} {% set h_text = h
~ ('' hour'' if h in [ "1", ''one''] else '' hours'') if h else '''' %} {%
set m_text = (30 if m in [''half'', ''1/2''] else m) ~ ('' minute'' if m in
[ "1", ''one''] else '' minutes'') if m else '''' %} {% set s_text = (30 if
s in [''half'', ''1/2''] else s) ~ ('' second'' if s in [ "1", ''one''] else
'' seconds'') if s else '''' %} {% set text_list = [ h_text, m_text, s_text]
| select() | list %} {% set text = text_list[:-1] | join('', '') ~ '' and
'' ~ text_list[-1] if text_list | count > 2 else text_list | join('' and '')
%} Command will be executed in {{ text }}
'
48 changes: 48 additions & 0 deletions responses/mr/HassTimerStatus.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
language: mr
responses:
intents:
HassTimerStatus:
default:
"TODO: {% set num_timers = slots.timers | length %}\n{% set active_timers\
\ = slots.timers | selectattr('is_active') | list %}\n{% set num_active_timers\
\ = active_timers | length %}\n{% set paused_timers = slots.timers | rejectattr('is_active')\
\ | list %}\n{% set num_paused_timers = paused_timers | length %}\n{% set\
\ next_timer = None %}\n\n{% if num_timers == 0: %}\n No timers.\n{% elif\
\ num_active_timers == 0: %}\n {# No active timers #}\n {% if num_paused_timers\
\ == 1: %}\n {% set next_timer = paused_timers[0] %}\n Timer is paused.\n\
\ {% else: %}\n {{ num_paused_timers }} paused timers.\n {% endif %}\n\
{% else: %}\n {# At least one active timer #}\n {% if num_active_timers\
\ == 1: %}\n {% set next_timer = active_timers[0] %}\n {% else: %}\n \
\ {# Get active timer that will finish soonest #}\n {% set sorted_timers\
\ = active_timers | sort(attribute='total_seconds_left') %}\n {% set next_timer\
\ = sorted_timers[0] %}\n {{ num_active_timers }} running timers.\n {%\
\ endif %}\n\n {% if num_paused_timers == 1: %}\n 1 paused timer.\n {%\
\ elif num_paused_timers > 0: %}\n {{ num_paused_timers }} paused timers.\n\
\ {% endif %}\n{% endif %}\n\n{% if next_timer: %}\n {# At least one active\
\ timer #}\n {% if (next_timer.rounded_hours_left == 1) and (next_timer.rounded_minutes_left\
\ > 0): %}\n 1 hour and {{ next_timer.rounded_minutes_left }} minutes\n\
\ {% elif (next_timer.rounded_hours_left == 1): %}\n 1 hour\n {% elif\
\ (next_timer.rounded_hours_left > 1) and (next_timer.rounded_minutes_left\
\ > 0): %}\n {{ next_timer.rounded_hours_left }} hours and {{ next_timer.rounded_minutes_left\
\ }} minutes\n {% elif (next_timer.rounded_hours_left > 1): %}\n {{ next_timer.rounded_hours_left\
\ }} hours\n {% elif (next_timer.rounded_minutes_left == 1) and (next_timer.rounded_seconds_left\
\ > 0): %}\n 1 minute and {{ next_timer.rounded_seconds_left }} seconds\n\
\ {% elif (next_timer.rounded_minutes_left == 1): %}\n 1 minute\n {%\
\ elif (next_timer.rounded_minutes_left > 1) and (next_timer.rounded_seconds_left\
\ > 0): %}\n {{ next_timer.rounded_minutes_left }} minutes and {{ next_timer.rounded_seconds_left\
\ }} seconds\n {% elif (next_timer.rounded_minutes_left > 1): %}\n {{\
\ next_timer.rounded_minutes_left }} minutes\n {% elif (next_timer.rounded_seconds_left\
\ == 1): %}\n 1 second\n {% elif (next_timer.rounded_seconds_left > 1):\
\ %}\n {{ next_timer.rounded_seconds_left }} seconds\n {% endif %}\n\n\
\ {% if num_timers > 1: %}\n {# Give some extra information to disambiguate\
\ #}\n left on\n {% if (next_timer.start_hours > 0) and (next_timer.start_minutes\
\ > 0): %}\n {{ next_timer.start_hours }} hour and {{ next_timer.start_minutes\
\ }} minute\n {% elif (next_timer.start_hours > 0): %}\n {{ next_timer.start_hours\
\ }} hour\n {% elif (next_timer.start_minutes > 0) and (next_timer.start_seconds\
\ > 0): %}\n {{ next_timer.start_minutes }} minute and {{ next_timer.start_seconds\
\ }} second\n {% elif (next_timer.start_minutes > 0): %}\n {{ next_timer.start_minutes\
\ }} minute\n {% elif (next_timer.start_seconds > 0): %}\n {{ next_timer.start_seconds\
\ }} second\n {% endif %}\n\n {% if next_timer.name: %}\n {{ next_timer.name\
\ }}\n {% elif next_timer.area: %}\n {{ next_timer.area }}\n {%\
\ endif %}\n\n timer.\n {% else: %}\n left.\n {% endif %}\n{% endif\
\ %}\n"
23 changes: 23 additions & 0 deletions responses/mr/HassTurnOff.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
language: mr
responses:
intents:
HassTurnOff:
default:
"TODO: {% set translations = {\n \"button\": \"the button\",\n \"\
camera\": \"the camera\",\n \"input_button\": \"the button\",\n \"alarm_control_panel\"\
: \"the alarm\",\n \"automation\": \"the automation\",\n \"fan\": \"the\
\ fan\",\n \"climate\": \"the thermostat\",\n \"humidifier\": \"the humidifier\"\
,\n \"input_boolean\": \"the switch\",\n \"siren\": \"the siren\",\n \"\
water_heater\": \"the water heater\",\n \"light\": \"the light\",\n \"switch\"\
: \"the switch\",\n \"remote\": \"the remote\",\n \"vacuum\": \"the vacuum\
\ cleaner\",\n \"media_player\": \"the media player\",\n \"lawn_mower\"\
: \"the lawn mower\"\n} %} Turned off {{ translations.get(state.domain) }}"
lights_area: "TODO: Turned off the lights"
lights_floor: "TODO: Turned off the lights"
fans_area: "TODO: Turned off the fans"
cover: "TODO: Closed"
light_all: "TODO: Turned off all of the lights"
fan_all: "TODO: Turned off all of the fans"
cover_device_class: "TODO: Closed the {{ slots.device_class }}"
lock: "TODO: Unlocked"
valve: "TODO: Closed"
24 changes: 24 additions & 0 deletions responses/mr/HassTurnOn.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
language: mr
responses:
intents:
HassTurnOn:
default:
"TODO: {% set translations = {\n \"button\": \"the button\",\n \"\
camera\": \"the camera\",\n \"input_button\": \"the button\",\n \"alarm_control_panel\"\
: \"the alarm\",\n \"automation\": \"the automation\",\n \"fan\": \"the\
\ fan\",\n \"climate\": \"the thermostat\",\n \"humidifier\": \"the humidifier\"\
,\n \"input_boolean\": \"the switch\",\n \"siren\": \"the siren\",\n \"\
water_heater\": \"the water heater\",\n \"light\": \"the light\",\n \"switch\"\
: \"the switch\",\n \"remote\": \"the remote\",\n \"vacuum\": \"the vacuum\
\ cleaner\",\n \"media_player\": \"the media player\",\n \"lawn_mower\"\
: \"the lawn mower\"\n} %} Turned on {{ translations.get(state.domain) }}"
lights_area: "TODO: Turned on the lights"
lights_floor: "TODO: Turned on the lights"
light_all: "TODO: Turned on all of the lights"
fans_area: "TODO: Turned on the fans"
cover: "TODO: Opened"
cover_device_class: "TODO: Opened the {{ slots.device_class }}"
scene: "TODO: Activated"
script: "TODO: Started"
lock: "TODO: Locked"
valve: "TODO: Opened"
5 changes: 5 additions & 0 deletions responses/mr/HassUnpauseTimer.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassUnpauseTimer:
default: "TODO: Timer resumed"
5 changes: 5 additions & 0 deletions responses/mr/HassVacuumReturnToBase.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: mr
responses:
intents:
HassVacuumReturnToBase:
default: "TODO: Returning"
Loading

0 comments on commit 93591f3

Please sign in to comment.