webiny-ai-powerups-content

Generates Headless CMS entry content via the configured AI Power Ups provider and personas.

8.0k|673|Updated Jan 9, 2018
One-click install
npx skills add https://github.com/webiny/webiny-js --skill webiny-ai-powerups-content
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: webiny-ai-powerups-content
Source: https://github.com/webiny/webiny-js/tree/main/skills/user-skills/api/ai-powerups-content
Command: npx skills add https://github.com/webiny/webiny-js --skill webiny-ai-powerups-content

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Developers who want to generate, summarize, or rewrite Webiny Headless CMS entry content programmatically often end up calling an LLM directly, which means managing API keys, picking models, and hardcoding prompts. This Skill shows how to delegate that work to the AI Power Ups extension so the provider, Projects, and Writer/Reader Personas the user already configured are applied automatically.

Core Features & Use Cases

  • Configured AI generation: Inject CmsGenerateEntryContentUseCase from webiny/api/ai-powerups and call execute(...) with a model id, prompt, and optional project or persona ids.
  • Safe output handling: The result is an entry-shaped object keyed by field ids; read only the fields you want (e.g. aiSummary) instead of writing the whole object back, then persist with UpdateEntryUseCase.
  • Admin persona picker: Use GetSettingsFeature from webiny/admin/ai-powerups to list configured Projects and Personas so users can pick one in the Admin UI.
  • Use Case: A bulk action whose processData generates a one-sentence marketing summary for each selected entry and writes it into an aiSummary field as a background task.

Quick Start

Ask the AI to add a bulk action that uses CmsGenerateEntryContentUseCase to generate an aiSummary field for selected CMS entries with the configured AI Power Ups provider.

Frequently Asked Questions about webiny-ai-powerups-content

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate Webiny CMS entry content with AI from my own code?

Inject CmsGenerateEntryContentUseCase from webiny/api/ai-powerups and call execute with the modelId and a prompt. It uses the provider configured in AI Power Ups and returns entry-shaped values you can persist with UpdateEntryUseCase.

Should I use CmsGenerateEntryContentUseCase or call Ai.generateText directly?

Use CmsGenerateEntryContentUseCase when you want the user's configured AI Power Ups setup, including provider, Projects, and Personas. Call Ai.generateText directly only when you deliberately want a raw, hardcoded prompt without that configuration.

What Webiny version is required for AI Power Ups content generation?

AI Power Ups content generation requires Webiny 6.5.0 or newer, with the AI Power Ups extension installed and at least one AI provider configured in its settings.

Why does the AI result overwrite fields I did not want changed?

The result values object is entry-shaped and the AI decides which fields to fill. Read only the specific field you want, such as values.aiSummary, and persist a targeted update with skipValidation instead of writing the whole object back.

How do I let admins pick a Project or Persona for AI generation?

Use GetSettingsFeature from webiny/admin/ai-powerups via the useFeature hook to read settings. It exposes writerPersonas.presets, readerPersonas.presets, and projects.presets, whose ids you forward to your backend call.