vectorbross / vb_ai_ckeditor
Adds the AI CKEditor integration on top of VB AI Core and configures the toolbar, AI tools and a tone of voice vocabulary.
Package info
bitbucket.org/vectorbross/vb_ai_ckeditor
Type:drupal-recipe
pkg:composer/vectorbross/vb_ai_ckeditor
Requires
- drupal/ai: ^1.4
- drupal/core: ^11.4
- vectorbross/vb_ai_core: ^1.0
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is not auto-updated.
Last update: 2026-12-03 21:54:40 UTC
README
Adds the AI CKEditor 5 integration on top of
vb_ai_core.
Editors get an AI tools button in the rich text toolbar for completion,
summarize, tone, spellfix and more.
What it installs
| Module | Purpose |
|---|---|
ai_ckeditor | AI tools in the CKEditor 5 toolbar |
taxonomy | Holds the tone of voice vocabulary |
It also applies these recipes first:
vb_ai_core(ai,key,token)core/recipes/full_html_format_editorcore/recipes/basic_html_format_editor
What it configures
Text formats
The Full HTML and Basic HTML editors get the same toolbar, with the AI buttons first:
AI CKEditor, AI balloon menu | bold, italic | link | bulleted list,
numbered list | block quote, insert image | heading, code | source
The AI dialog opens at 900 × 800 px (autoresize min-width: 600px).
AI tools
| Tool | Enabled | Provider |
|---|---|---|
ai_ckeditor_completion | yes | default chat |
ai_ckeditor_modify_prompt | yes | default chat |
ai_ckeditor_reformat_html | yes | default chat |
ai_ckeditor_spellfix | yes | default chat |
ai_ckeditor_summarize | yes | default chat |
ai_ckeditor_tone | yes | default chat |
An empty provider means the default chat provider set by the provider
recipe is used.
Tone of voice
The recipe creates a Tone of voice (tone_of_voice) vocabulary with
five default terms, imported from content/taxonomy_term:
| Term | Description sent to the model |
|---|---|
| Formal | Polite, correct and distant. No slang or contractions. |
| Professional | Clear, confident and businesslike. Direct without being stiff. |
| Friendly | Warm, approachable and conversational. |
| Informal | Relaxed and casual, as if talking to a peer. |
| Persuasive | Convincing and benefit driven, with a clear call to action. |
The tone tool offers these terms as choices and sends the term description
to the model (use_description: true). New terms are not created
automatically (autocreate: false). Add or edit terms at
/admin/structure/taxonomy/manage/tone_of_voice. Applying the recipe again
skips terms that already exist, so local edits are kept.
Tone prompt
The recipe adds its own prompt entity, ai_ckeditor_tone__vb
(config/ai.ai_prompt.ai_ckeditor_tone__vb.yml), and sets it as the tone
prompt in ai_ckeditor.settings. Compared to the module's default prompt,
it also tells the model to preserve the meaning and HTML formatting. It is
written in English and keeps the language of the input text.
prompts.tone holds the ID of an ai_prompt entity, not the prompt text.
To change the prompt, edit the entity in config/ or under the AI prompt
management pages, and keep the {tone}, {toneDescription} and
{inputText} placeholders.
Requirements
- Drupal 11.4+
- Drush 13+
- The project setup from
vb_ai_core(composer/installers2.3+, therecipes/{$name}installer path and the VBrepositoriesentry) - A chat capable provider recipe, already required and applied, for
example
vb_ai_provider_anthropic. The provider recipe sets the default for thechatoperation, which the AI tools use.
Install
Require the recipe. Composer pulls in vb_ai_core and drupal/ai (which
contains the ai_ckeditor module) as dependencies.
ddev composer require vectorbross/vb_ai_ckeditor
Apply the recipe
Make sure a provider recipe has been applied first (see
Requirements). Run from the project root; Drush runs from
the web docroot, so the path starts with ../recipes.
ddev drush recipe ../recipes/vb_ai_ckeditor
ddev drush cr
Permissions
The recipe grants the Use AI CKEditor permission to the
content_editor and webmaster roles, but only if they already exist.
The actions are marked optional with a ? prefix (supported by Drupal
core recipes), so missing roles are skipped, not created. The administrator role already
has every permission. Grant it manually if another role needs access.
Verify
ddev drush pm:list --status=enabled --filter=ai_ckeditor
Then edit content with a body field, select Full HTML or Basic HTML and click the AI CKEditor button in the toolbar. Pick a tool, such as Summarize, and the result is generated by the chat model.
Options
- Toolbar and AI tool settings live per text format at
/admin/config/content/formats. Changes made there are overwritten when the recipe is applied again; to change them for every site, updaterecipe.yml. - To use a different provider or model for one tool, set its
providerinrecipe.ymlinstead of leaving it empty. - To use another tone prompt, point
prompts.toneinrecipe.ymlto a differentai_promptentity ID, for exampleai_ckeditor_tone__defaultfor the module's own prompt.
License
GPL-2.0-or-later. See LICENSE.txt.