Linux 软件免费装
Banner图

AIPCF - AI Provider for Cloudflare

开发者 deshabhishek007
fitehal
更新时间 2026年5月30日 02:46
PHP版本: 7.4 及以上
WordPress版本: 7.0
版权: GPL-2.0-or-later
版权网址: 版权信息

标签

ai cloudflare mistral workers-ai llama

下载

1.0.0 1.0.1 1.0.2 1.0.3

详情介绍:

This plugin connects WordPress to Cloudflare Workers AI, making its hosted large language models available to any WordPress feature or plugin that uses the WordPress AI Client (introduced in WordPress 7.0). Supported models The plugin fetches the full list of available text generation models directly from your Cloudflare account and shows them in the settings dropdown, so you always see what is actually available to you. The list is cached for 12 hours and refreshed whenever you save your credentials. A built-in fallback list is used when your credentials are not yet configured or the API is unreachable. See Cloudflare's model catalogue for the current full list. Why Cloudflare Workers AI? Unlike hosted AI services that charge per seat or per API call at a premium rate, Cloudflare Workers AI runs inference at the edge on a usage-based model. The free tier covers 10,000 neurons per day (Cloudflare's billing unit — roughly 200–500 average generation requests) — enough for a content-heavy site to generate post summaries, meta descriptions, and moderation checks without any cost. Paid usage is billed per neuron, making it significantly cheaper at scale compared to per-token pricing from closed providers. Your prompts and completions also never leave Cloudflare's network to reach a third-party AI company's servers, which matters for sites with privacy or data-residency requirements. What you need
  1. A Cloudflare account with Workers AI enabled.
  2. Your Account ID — visible on the Workers AI dashboard sidebar.
  3. A Cloudflare API token with the "Workers AI - Edit" permission.

安装:

  1. Upload the plugin folder to /wp-content/plugins/.
  2. Activate the plugin through the Plugins menu in WordPress.
  3. Go to Settings → Cloudflare Workers AI.
  4. Enter your Cloudflare Account ID and API token.
  5. Click Save Changes, then Test connection to verify.
  6. Use the Text generation model dropdown to choose your preferred model. The full list is fetched live from your Cloudflare account and cached for 12 hours.
wp-config.php constants (optional) You can define credentials in wp-config.php instead of the settings page: define( 'CLOUDFLARE_WORKERS_AI_ACCOUNT_ID', 'your-account-id' ); define( 'CLOUDFLARE_WORKERS_AI_API_TOKEN', 'your-api-token' ); You can also hard-code the default model (the settings page dropdown takes precedence over this constant): define( 'CLOUDFLARE_WORKERS_AI_DEFAULT_MODEL', '@cf/meta/llama-3.3-70b-instruct-fp8-fast' ); Environment variables with the same names are also supported.

屏幕截图:

  • Adding your API key via Settings → Connectors.
  • Cloudflare Workers AI shows as Connected on the Connectors screen.
  • Connector Approvals — allow AIPCF to use the Cloudflare connector.
  • Settings page after a successful connection test.
  • AI-powered content suggestions working in the WordPress block editor.
  • AI-generated meta description for a page.
  • AI Request Logs showing Cloudflare Workers AI handling requests.

常见问题:

Where do I find my Account ID?

Go to dash.cloudflare.com and select your account. The Account ID appears in the right-hand sidebar of the account home page.

How do I create an API token?

Visit dash.cloudflare.com/profile/api-tokens, click Create Token, and select the Workers AI template (or manually add "Workers AI - Edit" permission).

Can I choose which model WordPress AI features use?

Yes. Go to Settings → Cloudflare Workers AI and use the Text generation model dropdown. The list is fetched live from your Cloudflare account (all text generation models available to you are shown) and cached for 12 hours. The default when nothing is selected is Meta Llama 4 Scout 17B — a good all-round starting point. You can also override the model in wp-config.php — the settings page takes precedence over the constant.

Results look off — what should I try?

Different models have different strengths, response styles, and context lengths. If the default model isn't producing the results you want:

  • Try Meta Llama 3.3 70B for richer, more detailed output.
  • Try Meta Llama 3.2 3B or Meta Llama 3.1 8B for faster, lighter responses.
  • Try Qwen QwQ 32B or DeepSeek R1 for reasoning-heavy tasks.
Swap models from the Text generation model dropdown in Settings — no code changes needed.

Does this plugin support image generation?

Not in version 1.0. Text generation is supported in this release. Image generation support via Cloudflare Workers AI is planned for a future version.

I get "connector has not been approved" — what does that mean?

WordPress requires site administrators to explicitly allow each AI connector before any feature can use it. Go to Settings → Connectors, find Cloudflare Workers AI, and click Allow. You only need to do this once.

Does this work without WordPress 7.0?

No. The WordPress AI Client API is introduced in WordPress 7.0. The plugin will not register itself if the AI Client is not available.

更新日志:

1.0.3 1.0.2 1.0.1 1.0.0