/
mikopbx
/
ModulePhraseStudio
Обзор
Документация
Войти
/
mikopbx
/
ModulePhraseStudio
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
master
Messages/en.php
171 строка
12 KB
Nikolay Beketov
fix: localize Phrase Studio REST API metadata
11 авг 2026, 11:59
11 авг 2026, 11:59
c34fa31
Код
Авторство
О чём код?
<?php declare(strict_types=1); /* * MikoPBX - free phone system for small business * Copyright © 2017-2026 Alexey Portnov and Nikolay Beketov */ return [ // Module metadata 'AdditionalMenuItemModulePhraseStudio' => 'Phrase Studio (TTS)', 'BreadcrumbModulePhraseStudio' => 'Phrase Studio (TTS)', 'SubHeaderModulePhraseStudio' => 'Generate voice phrases with Piper TTS directly on the MikoPBX server.', // REST API tags and resource descriptions 'rest_tag_ModulePhraseStudioEngine' => 'Phrase Studio - Engine', 'rest_tag_ModulePhraseStudioPhrases' => 'Phrase Studio - Phrases', 'rest_tag_ModulePhraseStudioVoices' => 'Phrase Studio - Voices', 'rest_phrase_studio_engine_ResourceDescription' => 'Install, update, inspect, and remove the Piper TTS engine.', 'rest_phrase_studio_phrases_ResourceDescription' => 'Generate and manage cached TTS phrases.', 'rest_phrase_studio_voices_ResourceDescription' => 'Browse, install, and remove Piper voice models.', // REST API operations 'rest_phrase_studio_engine_GetRecord' => 'Get engine status', 'rest_phrase_studio_engine_GetRecordDesc' => 'Returns the Piper installation status, version, and binary path.', 'rest_phrase_studio_engine_Install' => 'Install or update the engine', 'rest_phrase_studio_engine_InstallDesc' => 'Downloads and installs the Piper binary for the current system architecture.', 'rest_phrase_studio_engine_Delete' => 'Remove the engine', 'rest_phrase_studio_engine_DeleteDesc' => 'Removes the installed Piper binary from the PBX.', 'rest_phrase_studio_phrases_GetList' => 'Get generated phrases', 'rest_phrase_studio_phrases_GetListDesc' => 'Returns the phrase generation history.', 'rest_phrase_studio_phrases_Generate' => 'Generate a phrase', 'rest_phrase_studio_phrases_GenerateDesc' => 'Synthesizes text with an installed Piper voice and caches the resulting audio.', 'rest_phrase_studio_phrases_Download' => 'Download a phrase', 'rest_phrase_studio_phrases_DownloadDesc' => 'Downloads the generated phrase as a WAV file.', 'rest_phrase_studio_phrases_PromoteToTmp' => 'Add phrase to PBX sound files', 'rest_phrase_studio_phrases_PromoteToTmpDesc' => 'Converts a cached phrase to PBX audio formats and stores it in the selected sound category.', 'rest_phrase_studio_phrases_Delete' => 'Delete a phrase', 'rest_phrase_studio_phrases_DeleteDesc' => 'Deletes a generated phrase and its cached audio file.', 'rest_phrase_studio_voices_GetList' => 'Get voice catalog', 'rest_phrase_studio_voices_GetListDesc' => 'Returns available Piper voices and their installation status.', 'rest_phrase_studio_voices_Install' => 'Install a voice', 'rest_phrase_studio_voices_InstallDesc' => 'Queues the selected Piper voice model for background download.', 'rest_phrase_studio_voices_InstallAccepted' => 'Voice installation queued', 'rest_phrase_studio_voices_Delete' => 'Remove a voice', 'rest_phrase_studio_voices_DeleteDesc' => 'Removes an installed Piper voice model from the PBX.', // REST API parameters 'rest_param_phrase_studio_text' => 'Text to synthesize.', 'rest_param_phrase_studio_voice_id' => 'Piper voice identifier.', 'rest_param_phrase_studio_sample_rate' => 'Output sample rate: native or telephony.', 'rest_param_phrase_studio_language' => 'Filter voices by language code.', 'rest_param_phrase_studio_installed_only' => 'Return only installed voices.', // REST API schema fields 'rest_schema_phrase_studio_engine_id' => 'Piper engine identifier.', 'rest_schema_phrase_studio_engine_installed' => 'Whether the Piper engine is installed.', 'rest_schema_phrase_studio_engine_version' => 'Installed Piper engine version.', 'rest_schema_phrase_studio_engine_binary_path' => 'Absolute path to the Piper executable.', 'rest_schema_phrase_studio_phrase_id' => 'Unique phrase identifier.', 'rest_schema_phrase_studio_cache_key' => 'Cache key derived from text, voice, and sample rate.', 'rest_schema_phrase_studio_cached' => 'Whether the response was served from the phrase cache.', 'rest_schema_phrase_studio_duration_ms' => 'Phrase duration in milliseconds.', 'rest_schema_phrase_studio_phrase_size_bytes' => 'Phrase audio size in bytes.', 'rest_schema_phrase_studio_created_at' => 'Phrase creation time as a Unix timestamp.', 'rest_schema_phrase_studio_voice_name' => 'Human-readable voice name.', 'rest_schema_phrase_studio_voice_quality' => 'Piper voice quality level.', 'rest_schema_phrase_studio_voice_sample_rate' => 'Native voice sample rate in hertz.', 'rest_schema_phrase_studio_voice_installed' => 'Whether the voice model is installed.', 'rest_schema_phrase_studio_voice_size_bytes' => 'Installed voice model size in bytes.', // Tabs 'module_phrase_studio_TabStudio' => 'Studio', 'module_phrase_studio_TabVoices' => 'Voices', 'module_phrase_studio_TabEngine' => 'Engine', 'module_phrase_studio_TabHistory' => 'History', 'module_phrase_studio_HistoryHeader' => 'Generation history', 'module_phrase_studio_VoiceInstalled_Toast' => 'Voice installed', 'module_phrase_studio_VoiceUninstalled_Toast' => 'Voice removed', 'module_phrase_studio_RowReuseTooltip' => 'Click to copy text and voice back into the form', 'module_phrase_studio_HistoryEmptyTitle' => 'No phrases yet', 'module_phrase_studio_HistoryEmptyDescription' => 'Generate your first phrase using the form above — entries will appear in this list.', 'module_phrase_studio_RememberDefaults' => 'Remember this choice as default for next phrases', 'module_phrase_studio_DisabledHeader' => 'Module is disabled', 'module_phrase_studio_DisabledHint' => 'Enable the module on the PBX Extensions page to access Studio, Voices, Engine and History.', // Studio tab 'module_phrase_studio_TextLabel' => 'Text to synthesise', 'module_phrase_studio_TextPlaceholder' => 'Enter the text you want to convert to speech…', 'module_phrase_studio_VoiceLabel' => 'Voice', 'module_phrase_studio_SampleRateLabel' => 'Sample rate', 'module_phrase_studio_SampleRateNative' => 'Native (22 kHz, high quality)', 'module_phrase_studio_SampleRateTelephony' => 'Telephony (8 kHz, mono)', 'module_phrase_studio_SampleRatePlaceholder' => 'Pick a sample rate', 'module_phrase_studio_GenerateButton' => 'Generate', 'module_phrase_studio_DownloadButton' => 'Download .wav', 'module_phrase_studio_PickerEmpty' => 'Install at least one voice first', // Voices tab 'module_phrase_studio_VoicesHint' => 'Pick the languages you need and click "Install". Models are stored locally under db/voices/.', 'module_phrase_studio_VoicesColLanguage' => 'Language', 'module_phrase_studio_VoicesColName' => 'Voice', 'module_phrase_studio_VoicesColQuality' => 'Quality', 'module_phrase_studio_VoicesColRate' => 'Rate', 'module_phrase_studio_VoicesColStatus' => 'Status', 'module_phrase_studio_VoicesColActions' => 'Actions', 'module_phrase_studio_VoiceInstalled' => 'Installed', 'module_phrase_studio_VoiceNotInstalled' => 'Not installed', 'module_phrase_studio_VoiceInstalling' => 'Downloading…', 'module_phrase_studio_VoiceFailed' => 'Install failed', 'module_phrase_studio_VoiceInstall' => 'Install', 'module_phrase_studio_VoiceRetry' => 'Retry', 'module_phrase_studio_VoiceDelete' => 'Remove', 'module_phrase_studio_VoiceInstallQueued_Toast' => 'Voice download queued — installing in the background', 'module_phrase_studio_VoiceInstallTimeout' => 'Voice download is taking longer than expected — refresh the page to check status.', 'module_phrase_studio_VoiceNotInstalledError' => 'Voice is not installed:', // Engine tab 'module_phrase_studio_EngineHint' => 'The Piper binary is downloaded from GitHub the first time you enable the module.', 'module_phrase_studio_EngineInstalled' => 'Piper engine installed', 'module_phrase_studio_EngineNotInstalled'=> 'Piper engine is not installed', 'module_phrase_studio_EngineVersion' => 'Version', 'module_phrase_studio_EngineInstallHint' => 'Click "Install" to download the architecture-matched binary and extract it into db/piper/.', 'module_phrase_studio_EngineInstall' => 'Install engine', 'module_phrase_studio_EngineUpdate' => 'Update engine', 'module_phrase_studio_EngineUninstall' => 'Uninstall engine', // History tab 'module_phrase_studio_HistoryColCreated' => 'Created', 'module_phrase_studio_HistoryColText' => 'Text', 'module_phrase_studio_HistoryColVoice' => 'Voice', 'module_phrase_studio_HistoryColDuration' => 'Duration', 'module_phrase_studio_HistoryColPlayer' => 'Player', 'module_phrase_studio_HistoryColActions' => 'Actions', 'module_phrase_studio_HistoryDelete' => 'Remove from history', // Settings page 'module_phrase_studio_SettingsTitle' => 'Phrase Studio Settings', 'module_phrase_studio_DefaultVoiceLabel' => 'Default voice', 'module_phrase_studio_DefaultVoiceHelp' => 'For example: ru_RU-irina-medium. Used in the Studio when the user has not picked a voice manually.', 'module_phrase_studio_DefaultSampleRateLabel' => 'Default sample rate', 'module_phrase_studio_ResampleForTelephonyLabel' => 'Automatically convert to 8 kHz mono for telephony', 'module_phrase_studio_MaxTextLengthLabel' => 'Maximum text length (chars)', 'module_phrase_studio_CacheSizeLimitLabel' => 'Phrase cache limit (entries)', // Validation 'module_phrase_studio_ValidationMissing' => 'Provide text and pick a voice.', 'module_phrase_studio_ValidateMaxTextLength' => 'Enter a value between 1 and 10 000.', 'module_phrase_studio_ValidateCacheSizeLimit' => 'Enter a value between 0 and 10 000.', // SoundFiles modify hook 'module_phrase_studio_SoundFilesHookHeader' => 'Generate from text (Phrase Studio)', 'module_phrase_studio_SoundFilesHookSub' => 'Synthesize a phrase via Piper and use it as the source for this sound file.', 'module_phrase_studio_SoundFilesHookGenerate' => 'Generate and use as source', 'module_phrase_studio_SoundFilesHookSuccess' => 'Generated phrase has been imported as the source file.', 'module_phrase_studio_SoundFilesHookNoVoice' => 'Install at least one voice in Phrase Studio first.', 'module_phrase_studio_SoundFilesHookEngineOff' => 'The Piper engine is not installed. Open Phrase Studio → Engine and install it.', 'module_phrase_studio_SoundFilesHookHistoryLabel' => 'Reuse a previously generated phrase', 'module_phrase_studio_SoundFilesHookHistoryPlaceholder' => 'Pick a phrase from history…', // Errors 'module_phrase_studio_ErrorEngineStatus' => 'Failed to fetch engine status.', 'module_phrase_studio_ErrorEngineInstall' => 'Failed to install the Piper engine.', 'module_phrase_studio_ErrorEngineUninstall' => 'Failed to remove the Piper engine.', 'module_phrase_studio_ErrorVoicesList' => 'Failed to load the voice list.', 'module_phrase_studio_ErrorVoiceInstall' => 'Failed to download the voice model.', 'module_phrase_studio_ErrorVoiceUninstall' => 'Failed to remove the voice model.', 'module_phrase_studio_ErrorGenerate' => 'Phrase generation failed.', 'module_phrase_studio_ErrorHistoryDelete' => 'Failed to remove the history entry.', ];