Skip to content

Commit b98d0a8

Browse files
committed
add:添加tts提供商缺失的i18n
1 parent c64b1e7 commit b98d0a8

3 files changed

Lines changed: 169 additions & 12 deletions

File tree

astrbot/core/config/default.py

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1534,6 +1534,66 @@ class ChatProviderTemplate(TypedDict):
15341534
},
15351535
},
15361536
"items": {
1537+
"gemini_tts_api_key": {
1538+
"description": "Google Gemini TTS API 密钥",
1539+
"type": "string",
1540+
"hint": "请在 Google Cloud Console 获取 Gemini TTS API 密钥,用于身份验证和服务调用。"
1541+
},
1542+
"gemini_tts_api_base": {
1543+
"description": "Google Gemini TTS API 基础地址",
1544+
"type": "string",
1545+
"hint": "Gemini TTS 服务的 API 接口地址,一般使用默认值即可,特殊网络环境可能需要修改。"
1546+
},
1547+
"gemini_tts_timeout": {
1548+
"description": "Google Gemini TTS 超时时间",
1549+
"type": "integer",
1550+
"hint": "设置 API 请求超时时间(秒),建议 20 秒,网络较差时可适当增加。"
1551+
},
1552+
"gemini_tts_model": {
1553+
"description": "Google Gemini TTS 模型选择",
1554+
"type": "string",
1555+
"hint": "选择使用的 TTS 模型,默认为 gemini-2.5-flash-preview-tts,不同模型支持的特性可能不同。"
1556+
},
1557+
"gemini_tts_prefix": {
1558+
"description": "Google Gemini TTS 前缀设置",
1559+
"type": "string",
1560+
"hint": "可选参数,用于在合成语音前添加特定前缀文本。"
1561+
},
1562+
"gemini_tts_voice_name": {
1563+
"description": "Google Gemini TTS 音色选择",
1564+
"type": "string",
1565+
"hint": "选择合成语音的音色,默认为 Leda,不同音色效果可参考官方文档。"
1566+
},
1567+
"character": {
1568+
"description": "GPT-SoVITS 角色选择",
1569+
"type": "string",
1570+
"hint": "选择要使用的语音角色,需要提前在 GPT-SoVITS 服务中配置好对应的角色模型。"
1571+
},
1572+
"emotion": {
1573+
"description": "GPT-SoVITS 情感选择",
1574+
"type": "string",
1575+
"hint": "选择合成语音的情感风格,默认为 default,具体可选情感取决于角色模型的支持。"
1576+
},
1577+
"edge-tts-voice": {
1578+
"description": "Edge TTS 音色选择",
1579+
"type": "string",
1580+
"hint": "选择微软 Edge TTS 的语音角色,默认为 zh-CN-XiaoxiaoNeural,可参考微软官方文档获取完整列表。"
1581+
},
1582+
"rate": {
1583+
"description": "Edge TTS 语速调节",
1584+
"type": "string",
1585+
"hint": "调整语音语速,格式如 +0% 表示正常语速,可增减百分比进行调整。"
1586+
},
1587+
"volume": {
1588+
"description": "Edge TTS 音量调节",
1589+
"type": "string",
1590+
"hint": "调整语音音量,格式如 +0% 表示正常音量,可增减百分比进行调整。"
1591+
},
1592+
"pitch": {
1593+
"description": "Edge TTS 音调调节",
1594+
"type": "string",
1595+
"hint": "调整语音音调,格式如 +0Hz 表示正常音调,可增减 Hz 值进行调整。"
1596+
},
15371597
"genie_onnx_model_dir": {
15381598
"description": "ONNX Model Directory",
15391599
"type": "string",

dashboard/src/i18n/locales/en-US/features/config-metadata.json

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -916,6 +916,54 @@
916916
},
917917
"provider_group": {
918918
"provider": {
919+
"gemini_tts_api_key": {
920+
"description": "Google Gemini TTS API Key",
921+
"hint": "Please obtain the Gemini TTS API key from Google Cloud Console for authentication and service calls."
922+
},
923+
"gemini_tts_api_base": {
924+
"description": "Google Gemini TTS API Base URL",
925+
"hint": "The API endpoint URL for Gemini TTS service. Default value is usually sufficient, modify only for special network environments."
926+
},
927+
"gemini_tts_timeout": {
928+
"description": "Google Gemini TTS Timeout",
929+
"hint": "Set API request timeout in seconds. 20 seconds is recommended, increase if network is poor."
930+
},
931+
"gemini_tts_model": {
932+
"description": "Google Gemini TTS Model Selection",
933+
"hint": "Select the TTS model to use. Default is gemini-2.5-flash-preview-tts, different models may support different features."
934+
},
935+
"gemini_tts_prefix": {
936+
"description": "Google Gemini TTS Prefix Setting",
937+
"hint": "Optional parameter to add specific prefix text before speech synthesis."
938+
},
939+
"gemini_tts_voice_name": {
940+
"description": "Google Gemini TTS Voice Selection",
941+
"hint": "Select the voice for speech synthesis. Default is Leda, refer to official documentation for different voice effects."
942+
},
943+
"character": {
944+
"description": "GPT-SoVITS Character Selection",
945+
"hint": "Select the voice character to use. The corresponding character model needs to be configured in GPT-SoVITS service in advance."
946+
},
947+
"emotion": {
948+
"description": "GPT-SoVITS Emotion Selection",
949+
"hint": "Select the emotional style for speech synthesis. Default is default, available emotions depend on character model support."
950+
},
951+
"edge-tts-voice": {
952+
"description": "Edge TTS Voice Selection",
953+
"hint": "Select the voice character for Microsoft Edge TTS. Default is zh-CN-XiaoxiaoNeural, refer to Microsoft official documentation for complete list."
954+
},
955+
"rate": {
956+
"description": "Edge TTS Speech Rate Adjustment",
957+
"hint": "Adjust speech rate. Format like +0% means normal rate, can increase or decrease percentage."
958+
},
959+
"volume": {
960+
"description": "Edge TTS Volume Adjustment",
961+
"hint": "Adjust speech volume. Format like +0% means normal volume, can increase or decrease percentage."
962+
},
963+
"pitch": {
964+
"description": "Edge TTS Pitch Adjustment",
965+
"hint": "Adjust speech pitch. Format like +0Hz means normal pitch, can increase or decrease Hz value."
966+
},
919967
"genie_onnx_model_dir": {
920968
"description": "ONNX Model Directory",
921969
"hint": "The directory path containing the ONNX model files"

dashboard/src/i18n/locales/zh-CN/features/config-metadata.json

Lines changed: 61 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@
139139
"description": "文档解析提供商"
140140
},
141141
"moonshotai_api_key": {
142-
"description": "Moonshot AI API Key"
142+
"description": "Moonshot AI API 密钥"
143143
}
144144
}
145145
}
@@ -486,20 +486,20 @@
486486
"hint": "必填项。"
487487
},
488488
"slack_connection_mode": {
489-
"description": "Slack Connection Mode",
490-
"hint": "The connection mode for Slack. `webhook` uses a webhook server, `socket` uses Slack's Socket Mode."
489+
"description": "Slack 连接模式",
490+
"hint": "Slack 的连接模式。`webhook` 使用 Webhook 服务器,`socket` 使用 SlackSocket 模式。"
491491
},
492492
"slack_webhook_host": {
493-
"description": "Slack Webhook Host",
494-
"hint": "Only valid when Slack connection mode is `webhook`."
493+
"description": "Slack Webhook 主机",
494+
"hint": "仅在 Slack 连接模式为 `webhook` 时有效。"
495495
},
496496
"slack_webhook_path": {
497-
"description": "Slack Webhook Path",
498-
"hint": "Only valid when Slack connection mode is `webhook`."
497+
"description": "Slack Webhook 路径",
498+
"hint": "仅在 Slack 连接模式为 `webhook` 时有效。"
499499
},
500500
"slack_webhook_port": {
501-
"description": "Slack Webhook Port",
502-
"hint": "Only valid when Slack connection mode is `webhook`."
501+
"description": "Slack Webhook 端口",
502+
"hint": "仅在 Slack 连接模式为 `webhook` 时有效。"
503503
},
504504
"telegram_command_auto_refresh": {
505505
"description": "Telegram 命令自动刷新",
@@ -919,12 +919,61 @@
919919
},
920920
"provider_group": {
921921
"provider": {
922+
"gemini_tts_api_key": {
923+
"description": "Google Gemini TTS API 密钥",
924+
"hint": "请在 Google Cloud Console 获取 Gemini TTS API 密钥,用于身份验证和服务调用。"
925+
},
926+
"gemini_tts_api_base": {
927+
"description": "Google Gemini TTS API 基础地址",
928+
"hint": "Gemini TTS 服务的 API 接口地址,一般使用默认值即可,特殊网络环境可能需要修改。"
929+
},
930+
"gemini_tts_timeout": {
931+
"description": "Google Gemini TTS 超时时间",
932+
"hint": "设置 API 请求超时时间(秒),建议 20 秒,网络较差时可适当增加。"
933+
},
934+
"gemini_tts_model": {
935+
"description": "Google Gemini TTS 模型选择",
936+
"hint": "选择使用的 TTS 模型,默认为 gemini-2.5-flash-preview-tts,不同模型支持的特性可能不同。"
937+
},
938+
"gemini_tts_prefix": {
939+
"description": "Google Gemini TTS 前缀设置",
940+
"hint": "可选参数,用于在合成语音前添加特定前缀文本。"
941+
},
942+
"gemini_tts_voice_name": {
943+
"description": "Google Gemini TTS 音色选择",
944+
"hint": "选择合成语音的音色,默认为 Leda,不同音色效果可参考官方文档。"
945+
},
946+
"character": {
947+
"description": "GPT-SoVITS 角色选择",
948+
"hint": "选择要使用的语音角色,需要提前在 GPT-SoVITS 服务中配置好对应的角色模型。"
949+
},
950+
"emotion": {
951+
"description": "GPT-SoVITS 情感选择",
952+
"hint": "选择合成语音的情感风格,默认为 default,具体可选情感取决于角色模型的支持。"
953+
},
954+
"edge-tts-voice": {
955+
"description": "Edge TTS 音色选择",
956+
"hint": "选择微软 Edge TTS 的语音角色,默认为 zh-CN-XiaoxiaoNeural,可参考微软官方文档获取完整列表。"
957+
},
958+
"rate": {
959+
"description": "Edge TTS 语速调节",
960+
"hint": "调整语音语速,格式如 +0% 表示正常语速,可增减百分比进行调整。"
961+
},
962+
"volume": {
963+
"description": "Edge TTS 音量调节",
964+
"hint": "调整语音音量,格式如 +0% 表示正常音量,可增减百分比进行调整。"
965+
},
966+
"pitch": {
967+
"description": "Edge TTS 音调调节",
968+
"hint": "调整语音音调,格式如 +0Hz 表示正常音调,可增减 Hz 值进行调整。"
969+
},
922970
"genie_onnx_model_dir": {
923-
"description": "ONNX Model Directory",
924-
"hint": "The directory path containing the ONNX model files"
971+
"description": "ONNX 模型目录",
972+
"hint": "包含 ONNX 模型文件的目录路径"
925973
},
926974
"genie_language": {
927-
"description": "Language"
975+
"description": "语言",
976+
"hint": "设置 Genie 使用的语言"
928977
},
929978
"xai_native_search": {
930979
"description": "启用原生搜索功能",

0 commit comments

Comments
 (0)