List of functions
The range
capability has functions. Functions have parameters and voice scenarios that let you describe the skills for the device.
Function |
Description |
Changing brightness of lighting elements. |
|
Changing the channel (for example, on a TV). |
|
Changing the humidity. |
|
Opening something (shades or windows). |
|
Changing the temperature. It may indicate the heating temperature of an electric kettle, heater, or an air conditioner in any of its modes. |
|
Changing the device volume. |
brightness
Changing brightness of lighting elements.
Below is the description of the parameters
object from the Description of capability section.
parameters
object
Parameter |
Type |
Description |
instance |
String |
Function name for this capability. Acceptable values: |
unit |
String |
Function value units. Acceptable values: |
random_access |
Boolean |
Setting arbitrary function values. If this feature is disabled, the user can only change the values gradually, either up or down. For example, turning the TV volume up or down via an IR remote. Acceptable values:
Default value: |
range |
Object |
Object that describes the range of function values. |
range
object
Parameter |
Type |
Description |
min |
Float |
Minimum acceptable value: 0. |
max |
Float |
Maximum acceptable value: 100. |
precision |
Float |
The minimum step between values in the range. Default value: 1. |
-
Алиса, установи яркость ночника на минимум.
Translation: Alice, set the night light to minimum brightness.
-
Алиса, прибавь яркость люстры.
Translation: Alice, make the chandelier brighter.
Use this function to describe the features of various devices:
Example of the parameters
object
See the full example in Example of use.
{
...
"parameters": {
"instance": "brightness",
"unit": "unit.percent",
"range": {
"min": 0,
"max": 100,
"precision": 10
}
}
...
}
Examples of devices with the brightness function
channel
Changing the channel (for example, on a TV).
Below is the description of the parameters
object from the Description of capability section.
parameters
object
Parameter |
Type |
Description |
instance |
String |
Function name for this capability. Accepted values: |
random_access |
Boolean |
Setting arbitrary function values. If this feature is disabled, the user can only change the values gradually, either up or down. For example, turning the TV volume up or down via an IR remote. Acceptable values:
Default value: |
range |
Object |
Object that describes the range of function values. |
range
object
Parameter |
Type |
Description |
min |
Float |
No restrictions. |
max |
Float |
No restrictions. |
precision |
Float |
The minimum step between values in the range. Default value: 1. |
-
Алиса, включи следующий канал на телевизоре.
Translation: Alice, switch to the next TV channel.
-
Алиса, переключи телевизор на предыдущий канал.
Translation: Alice, switch to the previous TV channel.
-
Алиса, включи пятый канал на телевизоре.
Translation: Alice, set the TV to channel five.
Use this function to describe the features of various devices:
Example of the parameters
object
See the full example in Example of use.
{
...
"parameters": {
"instance": "channel",
"random_access": true,
"range": {
"min": 0,
"max": 999,
"precision": 1
}
}
...
}
Examples of devices with the channel function
humidity
Changing the humidity.
Below is the description of the parameters
object from the Description of capability section.
parameters
object
Parameter |
Type |
Description |
instance |
String |
Function name for this capability. Accepted values: |
unit |
String |
Function value units. Acceptable values: |
random_access |
Boolean |
Setting arbitrary function values. If this feature is disabled, the user can only change the values gradually, either up or down. For example, turning the TV volume up or down via an IR remote. Acceptable values:
Default value: |
range |
Object |
Object that describes the range of function values. |
range
object
Parameter |
Type |
Description |
min |
Float |
Minimum acceptable value: 0. |
max |
Float |
Maximum acceptable value: 100. |
precision |
Float |
The minimum step between values in the range. Default value: 1. |
-
Алиса, поставь максимальную влажность.
Translation: Alice, set humidity to maximum.
-
Алиса, поставь влажность на 45%.
Translation: Alice, set humidity to 45%.
-
Алиса, увеличь влажность в детской.
Translation: Alice, add humidity in the nursery.
Use this function to describe the features of various devices:
Example of the parameters
object
See the full example in Example of use.
{
...
"parameters": {
"instance": "humidity",
"random_access": true,
"range": {
"max": 100,
"min": 10,
"precision": 10
},
"unit": "unit.percent"
}
...
}
Examples of devices with the humidity function
open
Opening something (shades or windows).
Below is the description of the parameters
object from the Description of capability section.
parameters
object
Parameter |
Type |
Description |
instance |
String |
Function name for this capability. Acceptable values: |
unit |
String |
Function value units. Acceptable values: |
random_access |
Boolean |
Setting arbitrary function values. If this feature is disabled, the user can only change the values gradually, either up or down. For example, turning the TV volume up or down via an IR remote. Acceptable values:
Default value: |
range |
Object |
Object that describes the range of function values. |
range
object
Parameter |
Type |
Description |
min |
Float |
Minimum acceptable value: 0. |
max |
Float |
Maximum acceptable value: 100. |
precision |
Float |
The minimum step between values in the range. Default value: 1. |
-
Алиса, открой шторы на 10%.
Translation: Alice, open the shades 10%.
-
Алиса, открой окно на треть.
Translation: Alice, open the window one-third of the way.
-
Алиса, приоткрой ворота.
Translation: Alice, open the gate slightly.
Use this function to describe the features of various devices:
Example of the parameters
object
See the full example in Example of use.
{
...
"parameters": {
"instance": "open",
"random_access": true,
"range": {
"max": 100,
"min": 0,
"precision": 10
},
"unit": "unit.percent"
}
...
}
Examples of devices with the open function
temperature
Changing the temperature. It may indicate the heating temperature of an electric kettle, heater, or an air conditioner in any of its modes.
Below is the description of the parameters
object from the Description of capability section.
parameters
object
Parameter |
Type |
Description |
instance |
String |
Function name for this capability. Accepted values: |
unit |
String |
Function value units. Acceptable values:
|
random_access |
Boolean |
Setting arbitrary function values. If this feature is disabled, the user can only change the values gradually, either up or down. For example, turning the TV volume up or down via an IR remote. Acceptable values:
Default value: |
range |
Object |
Object that describes the range of function values. |
range
object
Parameter |
Type |
Description |
min |
Float |
No restrictions. |
max |
Float |
No restrictions. |
precision |
Float |
The minimum step between values in the range. Default value: 1. |
-
Алиса, установи температуру кондиционера на 20 градусов.
Translation: Alice, set air conditioning to 20 degrees.
-
Алиса, убавь температуру кондиционера.
Translation: Alice, turn down the temperature on the air conditioner.
-
Алиса, сделай теплее в детской.
Translation: Alice, make it warmer in the nursery.
-
Алиса, сделай прохладнее в гостиной.
Translation: Alice, make it cooler in the living room.
Use this function to describe the features of various devices:
Example of the parameters
object
See the full example in Example of use.
{
...
"parameters": {
"instance": "temperature",
"random_access": true,
"range": {
"max": 40,
"min": 18,
"precision": 1
},
"unit": "unit.temperature.celsius"
}
...
}
Examples of devices with the temperature function
volume
Changing the device volume.
Below is the description of the parameters
object from the Description of capability section.
parameters
object
Parameter |
Type |
Description |
instance |
String |
Function name for this capability. Accepted values: |
random_access |
Boolean |
Setting arbitrary function values. If this feature is disabled, the user can only change the values gradually, either up or down. For example, turning the TV volume up or down via an IR remote. Acceptable values:
Default value: |
range |
Object |
Object that describes the range of function values. |
unit |
String |
Function value units. Acceptable values:
If the parameter is omitted, the function is measured in abstract units. Example of a voice command: Алиса, увеличь громкость телевизора на 3. Translation: Alice, turn the TV volume up by 3. |
range
object
Parameter |
Type |
Description |
min |
Float |
No restrictions. |
max |
Float |
No restrictions. |
precision |
Float |
The minimum step between values in the range. Default value: 1. |
-
Алиса, сделай телевизор потише.
Translation: Alice, turn down the volume on the TV.
-
Алиса, прибавь громкость телевизора.
Translation: Alice, turn up the volume on the TV.
-
Алиса, поставь громкость на 3 на телевизоре.
Translation: Alice, set the volume to 3 on the TV.
Use this function to describe the features of various devices:
Example of the parameters
object
See the full example in Example of use.
{
...
"parameters": {
"instance": "volume",
"random_access": true,
"unit": "unit.percent",
"range": {
"min": 0,
"max": 100,
"precision": 10
}
}
...
}
Examples of devices with the volume function
Floating-point number with a precision of 6-9 decimal digits.
String enclosed in quotation marks, for example: "Hello, world"
.
List of "key": value
pairs separated by commas. The list is enclosed in curly brackets {}
.
{
"name": "John",
"surname": "Smith"
}
Boolean value without quotes: true
or false
.