mirror of
https://github.com/home-assistant/core.git
synced 2025-07-24 13:47:35 +00:00
Migrate tts services to support translations (#96412)
Co-authored-by: c0ffeeca7 <38767475+c0ffeeca7@users.noreply.github.com>
This commit is contained in:
parent
7021daf9fb
commit
021aaa9994
@ -1,88 +1,58 @@
|
|||||||
# Describes the format for available TTS services
|
# Describes the format for available TTS services
|
||||||
|
|
||||||
say:
|
say:
|
||||||
name: Say a TTS message
|
|
||||||
description: Say something using text-to-speech on a media player.
|
|
||||||
fields:
|
fields:
|
||||||
entity_id:
|
entity_id:
|
||||||
name: Entity
|
|
||||||
description: Name(s) of media player entities.
|
|
||||||
required: true
|
required: true
|
||||||
selector:
|
selector:
|
||||||
entity:
|
entity:
|
||||||
domain: media_player
|
domain: media_player
|
||||||
message:
|
message:
|
||||||
name: Message
|
|
||||||
description: Text to speak on devices.
|
|
||||||
example: "My name is hanna"
|
example: "My name is hanna"
|
||||||
required: true
|
required: true
|
||||||
selector:
|
selector:
|
||||||
text:
|
text:
|
||||||
cache:
|
cache:
|
||||||
name: Cache
|
|
||||||
description: Control file cache of this message.
|
|
||||||
default: false
|
default: false
|
||||||
selector:
|
selector:
|
||||||
boolean:
|
boolean:
|
||||||
language:
|
language:
|
||||||
name: Language
|
|
||||||
description: Language to use for speech generation.
|
|
||||||
example: "ru"
|
example: "ru"
|
||||||
selector:
|
selector:
|
||||||
text:
|
text:
|
||||||
options:
|
options:
|
||||||
name: Options
|
|
||||||
description:
|
|
||||||
A dictionary containing platform-specific options. Optional depending on
|
|
||||||
the platform.
|
|
||||||
advanced: true
|
advanced: true
|
||||||
example: platform specific
|
example: platform specific
|
||||||
selector:
|
selector:
|
||||||
object:
|
object:
|
||||||
|
|
||||||
speak:
|
speak:
|
||||||
name: Speak
|
|
||||||
description: Speak something using text-to-speech on a media player.
|
|
||||||
target:
|
target:
|
||||||
entity:
|
entity:
|
||||||
domain: tts
|
domain: tts
|
||||||
fields:
|
fields:
|
||||||
media_player_entity_id:
|
media_player_entity_id:
|
||||||
name: Media Player Entity
|
|
||||||
description: Name(s) of media player entities.
|
|
||||||
required: true
|
required: true
|
||||||
selector:
|
selector:
|
||||||
entity:
|
entity:
|
||||||
domain: media_player
|
domain: media_player
|
||||||
message:
|
message:
|
||||||
name: Message
|
|
||||||
description: Text to speak on devices.
|
|
||||||
example: "My name is hanna"
|
example: "My name is hanna"
|
||||||
required: true
|
required: true
|
||||||
selector:
|
selector:
|
||||||
text:
|
text:
|
||||||
cache:
|
cache:
|
||||||
name: Cache
|
|
||||||
description: Control file cache of this message.
|
|
||||||
default: true
|
default: true
|
||||||
selector:
|
selector:
|
||||||
boolean:
|
boolean:
|
||||||
language:
|
language:
|
||||||
name: Language
|
|
||||||
description: Language to use for speech generation.
|
|
||||||
example: "ru"
|
example: "ru"
|
||||||
selector:
|
selector:
|
||||||
text:
|
text:
|
||||||
options:
|
options:
|
||||||
name: Options
|
|
||||||
description:
|
|
||||||
A dictionary containing platform-specific options. Optional depending on
|
|
||||||
the platform.
|
|
||||||
advanced: true
|
advanced: true
|
||||||
example: platform specific
|
example: platform specific
|
||||||
selector:
|
selector:
|
||||||
object:
|
object:
|
||||||
|
|
||||||
clear_cache:
|
clear_cache:
|
||||||
name: Clear TTS cache
|
|
||||||
description: Remove all text-to-speech cache files and RAM cache.
|
|
||||||
|
60
homeassistant/components/tts/strings.json
Normal file
60
homeassistant/components/tts/strings.json
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
{
|
||||||
|
"services": {
|
||||||
|
"say": {
|
||||||
|
"name": "Say a TTS message",
|
||||||
|
"description": "Says something using text-to-speech on a media player.",
|
||||||
|
"fields": {
|
||||||
|
"entity_id": {
|
||||||
|
"name": "Entity",
|
||||||
|
"description": "Media players to play the message."
|
||||||
|
},
|
||||||
|
"message": {
|
||||||
|
"name": "Message",
|
||||||
|
"description": "The text you want to convert into speech so that you can listen to it on your device."
|
||||||
|
},
|
||||||
|
"cache": {
|
||||||
|
"name": "Cache",
|
||||||
|
"description": "Stores this message locally so that when the text is requested again, the output can be produced more quickly."
|
||||||
|
},
|
||||||
|
"language": {
|
||||||
|
"name": "Language",
|
||||||
|
"description": "Language to use for speech generation."
|
||||||
|
},
|
||||||
|
"options": {
|
||||||
|
"name": "Options",
|
||||||
|
"description": "A dictionary containing integration-specific options."
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"speak": {
|
||||||
|
"name": "Speak",
|
||||||
|
"description": "Speaks something using text-to-speech on a media player.",
|
||||||
|
"fields": {
|
||||||
|
"media_player_entity_id": {
|
||||||
|
"name": "Media player entity",
|
||||||
|
"description": "Media players to play the message."
|
||||||
|
},
|
||||||
|
"message": {
|
||||||
|
"name": "[%key:component::tts::services::say::fields::message::name%]",
|
||||||
|
"description": "[%key:component::tts::services::say::fields::message::description%]"
|
||||||
|
},
|
||||||
|
"cache": {
|
||||||
|
"name": "[%key:component::tts::services::say::fields::cache::name%]",
|
||||||
|
"description": "[%key:component::tts::services::say::fields::cache::description%]"
|
||||||
|
},
|
||||||
|
"language": {
|
||||||
|
"name": "[%key:component::tts::services::say::fields::language::name%]",
|
||||||
|
"description": "[%key:component::tts::services::say::fields::language::description%]"
|
||||||
|
},
|
||||||
|
"options": {
|
||||||
|
"name": "[%key:component::tts::services::say::fields::options::name%]",
|
||||||
|
"description": "[%key:component::tts::services::say::fields::options::description%]"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"clear_cache": {
|
||||||
|
"name": "Clear TTS cache",
|
||||||
|
"description": "Removes all cached text-to-speech files and purges the memory."
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user