Linux 软件免费装
Banner图

LS AI Provider for ElevenLabs

开发者 laurisaarni
whyisjake
更新时间 2026年9月14日 20:14
PHP版本: 7.4 及以上
WordPress版本: 7.1
版权: GPL-2.0-or-later
版权网址: 版权信息

标签

tts ai text-to-speech connector elevenlabs

下载

1.0.2

详情介绍:

This plugin provides a third-party ElevenLabs integration for the PHP AI Client SDK. It enables WordPress sites to use ElevenLabs models for text-to-speech conversion and sound effects generation. It is not affiliated with, endorsed by, or sponsored by ElevenLabs. "LS" is the author's initials, Lauri Saarni, because the WordPress.org plugin directory requires a plugin name to begin with a distinctive identifier rather than a generic description. The plugin has no admin screens of its own. It registers ElevenLabs with the AI Client so that WordPress core and any other plugin built on the AI Client can use it, and it never contacts ElevenLabs until such a request is actually made. See "External services" below. Features: Available Capabilities: Requirements:

安装:

  1. Ensure the PHP AI Client SDK is available (bundled in WordPress 7.0+)
  2. Upload the plugin files to /wp-content/plugins/ls-ai-provider-for-elevenlabs/
  3. Activate the plugin through the 'Plugins' menu in WordPress
  4. Configure your ElevenLabs API key in Settings > Connectors (WordPress 7.0+), or via the ELEVENLABS_API_KEY environment variable or constant

升级注意事项:

1.0.2 Renamed to "LS AI Provider for ElevenLabs" to meet the directory's naming requirements. Filter, option and Composer package names are unchanged, so existing integrations keep working. 1.0.1 Settings > Connectors now verifies your ElevenLabs key with the service instead of only checking that one was entered, so a mistyped key is reported instead of appearing to work. 1.0.0 First WordPress.org release. The plugin bootstrap file was renamed to match the plugin slug, so if you installed an earlier build from GitHub, reactivate the plugin once after updating. 0.1.0 Initial release.

常见问题:

How do I get an ElevenLabs API key?

Visit https://elevenlabs.io/app/settings/api-keys to create an account and generate an API key. Using this plugin requires an ElevenLabs account, and ElevenLabs bills you for the requests it makes on your behalf.

Does this plugin work without the PHP AI Client SDK?

No. This plugin contains only the ElevenLabs-specific implementation of the AI Client's provider interfaces, so the SDK has to be loadable for it to do anything. WordPress 7.0 and later bundle the SDK in core. On earlier WordPress, the SDK has to be provided by your project (for example through Composer); it is a library, not a plugin. When the SDK is missing, this plugin registers nothing and stays inert instead of erroring.

How do I specify which voice to use?

Set the outputSpeechVoice option in your ModelConfig to the voice ID. You can discover available voices using the VoiceDirectory class or the ElevenLabs voice library.

What happens if I don't specify a voice?

The provider resolves a default: the ELEVENLABS_DEFAULT_VOICE_ID environment variable or constant, the ai_provider_for_elevenlabs_default_voice_id option, a voice discovered from your own ElevenLabs account (preferring premade voices; requires the Voices permission on the API key), and finally the premade voice "George" (JBFqnCBsd6RMkjVDRZzb), which is available on every account. The result passes through the ai_provider_for_elevenlabs_default_voice_id filter. An explicitly configured outputSpeechVoice always takes precedence.

Can it narrate a whole post?

Text longer than the model's per-request character limit is split on paragraph and sentence boundaries, narrated in several requests, and returned as one audio file. Note that narration is slow (roughly 90 to 95 characters per second) and runs inside one PHP request, so very long text can exceed the PHP execution time limit. Each chunk is billed as its own API request. See the README for details and for the public per-chunk methods a background-processing plugin can build on.

Why does the AI plugin say there is no valid AI Connector?

The WordPress.org AI plugin treats a connector as valid only when it can generate text, and ElevenLabs generates speech and sound. The warning is expected and does not affect this provider; add a text-generation connector alongside it to satisfy the AI plugin's own features.

What audio formats are supported?

The default output format is MP3 (mp3_44100_128). Other supported formats include PCM, ulaw, Opus, and AAC at various sample rates and bitrates. When long text has to be split across requests, only formats whose audio can be joined are allowed (MP3, PCM, ulaw, alaw).

Does the plugin send anything anywhere on its own?

No. Nothing leaves your site until code on your site asks the AI Client for speech, sound, a model list, or a voice list. There is no telemetry, no analytics, and no phone-home. The "External services" section below documents every request the plugin can make.

更新日志:

1.0.2 1.0.1 1.0.0 0.4.0 0.3.0 0.2.0 0.1.2 0.1.1 0.1.0