-
Notifications
You must be signed in to change notification settings - Fork 0
Robots Task
hoferdan edited this page May 6, 2021
·
3 revisions
Topic name: /robots/task
Usage:
This topic is used by the robots to send out task requests.
Message definition:
{
"target_id": String,
"source_id": String,
"timestamp": Long,
"task_id": String,
"priority": int,
"type": String,
"parameter": {
<data>
}
}
Key | Description |
---|---|
task_id | Unique task id, will be used in status messages related to a task. |
priority | Task priority, can range from 1 to 5. 1 is the highest priority. |
type | Task type, current valid value is tts. |
parameter | Parameters needed by the recipient to fulfill the task. The exact parameters needed is described in the following. |
Available types:
The type tts issues a speech synthesis task. The parameters contain the text to synthesize and a language tag.
Needed parameters are:
{
"text": String,
"lang" : String
}
Key | Description |
---|---|
text | Text which should be spoken. |
lang | Language identifier based on RFC 3066 Language Identifiers. |
The type person_detected is used if a task related to person should be executed by a different agent.
Parameter set:
{
"id": String,
"name": String
}
Key | Description id | Id of the person. Useful if two persons have the same name. name | Name of the detected person.
Example message of the tts. Other task messages look similar, only the type and parameter field are filled accordingly.
{
"target_id": "SI_1",
"source_id": "R_1",
"timestamp": 1552481472,
"task_id": "Task1559481472",
"priority": 3,
"type": "tts",
"parameter": {
"text": "This is a test task of type tts.",
"lang": "en_US"
}
}