szenario/craft-altpilot 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

szenario/craft-altpilot

最新稳定版本:5.0.13

Composer 安装命令:

composer require szenario/craft-altpilot

包简介

Generate and manage alt texts. Fully integrated, for thousands of assets.

README 文档

README


altpilot: alt text on autopilot

AI-powered alt text generation built into Craft CMS. Generate faster, review in context, and scale accessibility across large image libraries with full control.
Made possible by
szenario-design.com logo


The team behind the magic
Simon Wesp Thomas Bendl Erich Bendl

Features ✨

  • Dedicated UI for reviewing and managing generated alt text
  • Inline frontend editing workflow
  • Compatible with static page caching (Blitz, Varnish, CDN, etc.)
  • Automatic SPA support (Barba.js, Swup, Turbo, htmx, etc.)
  • Native Craft CMS integration for assets and action menus
  • CLI commands for batch generation and maintenance
  • Dynamic OpenAI rate-limit throttling for safer large runs
  • Alt text status tracking across assets/sites
  • Automatic generation for newly uploaded images

Requirements 📋

  • Craft CMS 5.0.0+
  • PHP 8.2+
  • Valid OpenAI API key with access to a vision-capable model
  • Reliable Craft queue runner for production (CRON or daemon-based)

altpilot uses Craft's queue system for generation jobs. For production, avoid relying only on browser-triggered queue execution.
Craft queue docs: https://craftcms.com/docs/5.x/system/queue.html#queue-runners

Installation 📦

Install from the Craft Plugin Store or via Composer.

Plugin Store

Install altpilot from the Craft Plugin Store

Composer

# from your Craft project root
composer require szenario/craft-altpilot && php craft plugin/install altpilot

Quickstart 🚀

  1. Open Settings -> Plugins -> altpilot.
  2. Add your OpenAI API key.
  3. Select the asset volumes altpilot should process.
  4. Run an initial generation pass:
php craft altpilot/missing
  1. Make sure your queue runner is active:
php craft queue/run --verbose

Configuration 🛠️

altpilot settings are available in the Craft control panel:

  • OpenAI API Key: API key used for generation requests
  • Volumes: limits processing to selected asset volumes
  • Inline Frontend Editing: toggles frontend overlay
  • Prompt: base prompt sent with each image
  • Prompt Role: optional role/context
  • Prompt Focus: optional domain-specific focus
  • OpenAI Model: model used for alt text generation (recommended: gpt-5-nano)

Model Recommendation and Cost

We recommend gpt-5-nano as the default model for most projects because it currently offers the best price/performance for alt text generation.

In our experience, generating 1,000 alt texts with gpt-5-nano costs less $0.7 USD.

Pricing is an estimate, not a guarantee. Actual cost depends on your prompt length, image complexity, response length, and OpenAI pricing changes over time.

Console Commands

altpilot includes CLI commands for batch operations:

# show available commands
php craft altpilot

# generate for one asset (optionally scoped by site)
php craft altpilot/asset <assetId> [--siteId=<id>]

# generate only missing alt text in configured volumes
php craft altpilot/missing [--siteId=<id>]

# regenerate all alt text (overwrites existing)
php craft altpilot/all [--siteId=<id>]

# regenerate all but optionally skip assets with manually set alt text
php craft altpilot/all [--siteId=<id>] --exclude-manual

# show status counts and queue overview
php craft altpilot/stats

Queue and Performance Notes

For stable production behavior:

  • Run queue workers via CRON or a daemon process
  • Monitor queue health during large generation batches
  • Keep PHP execution limits realistic for external API calls (120s+ is safer than very low defaults)

Support

统计信息

  • 总下载量: 5
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 4
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: proprietary
  • 更新时间: 2026-02-26

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固