PHPackages                             netresearch/t3-cowriter - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. netresearch/t3-cowriter

ActiveTypo3-cms-extension[Utility &amp; Helpers](/categories/utility)

netresearch/t3-cowriter
=======================

With the help of AI you can now work on a page together with a cowriter - a digital assistant that helps you to write your content.

v3.1.1(3mo ago)1011.5k↑195.7%2[1 issues](https://github.com/netresearch/t3x-cowriter/issues)GPL-3.0-or-laterPHPPHP ^8.2CI passing

Since Jan 14Pushed 2w ago5 watchersCompare

[ Source](https://github.com/netresearch/t3x-cowriter)[ Packagist](https://packagist.org/packages/netresearch/t3-cowriter)[ Docs](https://github.com/netresearch/t3x-cowriter)[ RSS](/packages/netresearch-t3-cowriter/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (10)Dependencies (11)Versions (26)Used By (0)

TYPO3 Extension: t3\_cowriter
=============================

[](#typo3-extension-t3_cowriter)

[![CI](https://github.com/netresearch/t3x-cowriter/actions/workflows/ci.yml/badge.svg)](https://github.com/netresearch/t3x-cowriter/actions/workflows/ci.yml)[![codecov](https://camo.githubusercontent.com/fc746f9748cd84d0c2bb745e50daccf1a1d25eca57f6ada301b8378f47c77e96/68747470733a2f2f636f6465636f762e696f2f67682f6e657472657365617263682f7433782d636f7772697465722f67726170682f62616467652e737667)](https://codecov.io/gh/netresearch/t3x-cowriter)

[![OpenSSF Scorecard](https://camo.githubusercontent.com/3ec420f6cbff305588900f06ae97cba0a163cbb928fe115743cb87d086d2ac6c/68747470733a2f2f6170692e736563757269747973636f726563617264732e6465762f70726f6a656374732f6769746875622e636f6d2f6e657472657365617263682f7433782d636f7772697465722f6261646765)](https://securityscorecards.dev/viewer/?uri=github.com/netresearch/t3x-cowriter)[![OpenSSF Best Practices](https://camo.githubusercontent.com/f9dcd1c577759f15c4aee1c8dc9d1d0d7b3dd89f3f8b67fc33445e4d5d76ff0a/68747470733a2f2f7777772e626573747072616374696365732e6465762f70726f6a656374732f31313835332f6261646765)](https://www.bestpractices.dev/projects/11853)[![SLSA 3](https://camo.githubusercontent.com/dc294f15fb5f1c96307863a1e96860310be940504e7ee370cee94bf4400cbac9/68747470733a2f2f736c73612e6465762f696d616765732f67682d62616467652d6c6576656c332e737667)](https://slsa.dev)

[![PHPStan](https://camo.githubusercontent.com/d18b9a987aa81e64470a11caecf72caa66597c9ebd6b307bd1c2cb7a752b0dff/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048505374616e2d6c6576656c25323031302d627269676874677265656e2e737667)](https://phpstan.org/)[![PHP 8.2+](https://camo.githubusercontent.com/0f16581d1180dbfd4c0e13166ec1267d4ad2f2fab8281ea6d6b284cf5c65d921/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e322532422d626c75652e737667)](https://www.php.net/)[![TYPO3 v13](https://camo.githubusercontent.com/39b7ea332fe50c744dd651e5de37137e22f86909ed8327d044205f6a1ce9dbde/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5459504f332d7631332d6f72616e67652e737667)](https://typo3.org/)[![TYPO3 v14](https://camo.githubusercontent.com/4408aa531f9e1f713217cffa7f7143a33dbd648599f9d048211a1c8afe2c06a2/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5459504f332d7631342d6f72616e67652e737667)](https://typo3.org/)[![License: GPL v3](https://camo.githubusercontent.com/7b8bafba66ad667644f929650e95999ed543861daa523111404f5f1d5f9b6fd4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d47504c5f76332d626c75652e737667)](https://www.gnu.org/licenses/gpl-3.0.en.html)[![Latest Release](https://camo.githubusercontent.com/05aa285c449b02ca9a08a252d3b8b9bf348dd24348a0f646256613d9168338dc/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f6e657472657365617263682f7433782d636f777269746572)](https://github.com/netresearch/t3x-cowriter/releases)[![Contributor Covenant](https://camo.githubusercontent.com/817d29b29dcac8a671e6670fb01f792302989c853922a3714322e78af3dc7c85/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f436f6e7472696275746f72253230436f76656e616e742d332e302d3462616161612e737667)](CODE_OF_CONDUCT.md)

[![Composer](https://camo.githubusercontent.com/6bf7987f28c9bf01a4c3cf9933adef2ae5c9aac58b40055104149604e3d38552/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f636f6d706f7365722f736869656c64732e737667)](https://camo.githubusercontent.com/6bf7987f28c9bf01a4c3cf9933adef2ae5c9aac58b40055104149604e3d38552/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f636f6d706f7365722f736869656c64732e737667)[![Downloads](https://camo.githubusercontent.com/5272aaa87ae6c0e811593d72e86100dcca6c9fd7301f2fb2ad431fe3b1fd328c/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f646f776e6c6f6164732f736869656c64732e737667)](https://camo.githubusercontent.com/5272aaa87ae6c0e811593d72e86100dcca6c9fd7301f2fb2ad431fe3b1fd328c/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f646f776e6c6f6164732f736869656c64732e737667)[![Extension](https://camo.githubusercontent.com/69e3001471894096c010f6468c8c8aabe50dae432464255cc29d05d62e7c8bc4/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f657874656e73696f6e2f736869656c64732e737667)](https://camo.githubusercontent.com/69e3001471894096c010f6468c8c8aabe50dae432464255cc29d05d62e7c8bc4/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f657874656e73696f6e2f736869656c64732e737667)[![Stability](https://camo.githubusercontent.com/af4b519742753d8c5a647e4801258f3d30db648d97c9c08b2ee9c46bed631f39/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f73746162696c6974792f736869656c64732e737667)](https://camo.githubusercontent.com/af4b519742753d8c5a647e4801258f3d30db648d97c9c08b2ee9c46bed631f39/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f73746162696c6974792f736869656c64732e737667)[![TYPO3](https://camo.githubusercontent.com/b559f6fa6667ddadad204a332437285b31712439f8b091c5f07fce61dd240caa/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f7479706f332f736869656c64732e737667)](https://camo.githubusercontent.com/b559f6fa6667ddadad204a332437285b31712439f8b091c5f07fce61dd240caa/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f7479706f332f736869656c64732e737667)[![Version](https://camo.githubusercontent.com/c076c128b85b82bb8c0244bc8a6e58c31f9a68e6d9edc11147630789e90b8a46/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f76657273696f6e2f736869656c64732e737667)](https://camo.githubusercontent.com/c076c128b85b82bb8c0244bc8a6e58c31f9a68e6d9edc11147630789e90b8a46/68747470733a2f2f7479706f332d6261646765732e6465762f62616467652f74335f636f7772697465722f76657273696f6e2f736869656c64732e737667)

AI-powered content assistant for TYPO3 CKEditor - write better content with help from AI.

[![Cowriter dialog in TYPO3 v14 backend](Documentation/Images/CowriterHero.png)](Documentation/Images/CowriterHero.png)

Features
--------

[](#features)

- **Task-based dialog**: Select from predefined tasks (Improve, Summarize, Extend, Fix Grammar, Translate) with result preview before inserting
- **Vision / Alt Text**: Analyze images and generate descriptive alt text via the CKEditor toolbar
- **Translation**: Translate selected text into 10+ languages directly from the toolbar dropdown
- **Prompt Templates**: Load reusable prompt presets from the backend for consistent content generation
- **Tool Calling**: Structured function calling that lets the LLM query TYPO3 content during conversations
- **CKEditor Integration**: Four toolbar components — main dialog, vision, translation, and templates
- **Multi-Provider Support**: Works with all LLM providers supported by nr-llm (OpenAI, Claude, Gemini, etc.)
- **Secure Backend Proxy**: API keys never exposed to frontend — all requests proxied through TYPO3 backend
- **Context control**: Choose between selected text or full content element as context
- **Ad-hoc instructions**: Add custom instructions per request (e.g., "Write in formal tone")
- **Rate limiting**: 20 requests/minute per backend user
- **Streaming**: Server-Sent Events for real-time completions
- **Content sanitization**: Frontend DOMParser-based sanitization with CKEditor's HTML processing pipeline

Requirements
------------

[](#requirements)

- PHP 8.2+
- TYPO3 v13 or v14
- [netresearch/nr-llm](https://github.com/netresearch/t3x-nr-llm) extension (LLM provider abstraction)

Installation
------------

[](#installation)

Install via Composer:

```
composer require netresearch/t3-cowriter
```

Configuration
-------------

[](#configuration)

### 1. Configure nr-llm Extension

[](#1-configure-nr-llm-extension)

First, set up at least one LLM provider in the nr-llm extension:

1. Navigate to **Admin Tools → LLM Management**
2. Add a provider (e.g., OpenAI with your API key)
3. Create a model configuration
4. Create an LLM configuration and set it as default

### 2. Add CKEditor Preset

[](#2-add-ckeditor-preset)

#### Option A: Use the included preset

[](#option-a-use-the-included-preset)

Add the cowriter preset to your Page TSconfig:

```
RTE.default.preset = cowriter

```

#### Option B: Extend your existing preset

[](#option-b-extend-your-existing-preset)

Add to your RTE configuration YAML:

```
editor:
  config:
    importModules:
      - { module: '@netresearch/t3_cowriter/cowriter', exports: ['Cowriter'] }
    toolbar:
      items:
        - cowriter
        - cowriterVision
        - cowriterTranslate
        - cowriterTemplates
```

Usage
-----

[](#usage)

1. Open a content element with a rich text field in the TYPO3 backend
2. Optionally select text in CKEditor (or leave empty to use full content)
3. Click the **Cowriter** button in the toolbar
4. A dialog opens where you can:
    - **Select a task** (Improve Text, Summarize, Extend, Fix Grammar, Translate to EN/DE)
    - **Choose context scope** — selected text or whole content element
    - **Add instructions** — optional ad-hoc rules like "Write in formal tone"
5. Click **Execute** — the task is sent to the LLM
6. Review the result in the preview area
7. Click **Insert** to replace content, or **Retry** to re-execute

### Available tasks

[](#available-tasks)

Tasks are managed in the nr-llm extension (`tx_nrllm_task` table) with `category = 'content'`. Default tasks:

TaskDescriptionImprove TextEnhance readability and qualitySummarizeCreate a concise summaryExtend / ElaborateAdd depth and detailFix Grammar &amp; SpellingCorrect grammar and spellingTranslate to EnglishTranslate to EnglishTranslate to GermanTranslate to GermanArchitecture
------------

[](#architecture)

```
CKEditor Toolbar
  ├─ cowriter         → [CowriterDialog] → AIService.js → AjaxController
  ├─ cowriterVision   → AIService.js     ──────────────→ VisionController
  ├─ cowriterTranslate→ AIService.js     ──────────────→ TranslationController
  ├─ cowriterTemplates→ AIService.js     ──────────────→ TemplateController
  └─ (tool calling)   → AIService.js     ──────────────→ ToolController
                                                              ↓
                                                   [LlmServiceManagerInterface]
                                                              ↓
                                                        [nr-llm Provider]
                                                              ↓
                                                        [External LLM API]

```

All LLM requests are proxied through the TYPO3 backend. API keys are stored encrypted and never exposed to the browser.

Development
-----------

[](#development)

### Prerequisites

[](#prerequisites)

- DDEV for local development
- PHP 8.2+ with required extensions

### Setup

[](#setup)

```
ddev start
ddev composer install
ddev install-v14
```

### Testing

[](#testing)

```
# Run all quality checks (lint, phpstan, rector, code style)
make ci

# Run all tests (unit, functional, integration, e2e)
make test

# Individual test suites
make test-unit           # Unit tests
make test-functional     # Functional tests
make test-integration    # Integration tests
make test-e2e            # End-to-end tests

# Code quality
make lint               # PHP-CS-Fixer
make phpstan            # PHPStan level 10
```

### Test Coverage

[](#test-coverage)

Target: &gt;80% code coverage

```
make test-coverage
open var/coverage/unit/index.html
```

Security
--------

[](#security)

- API keys stored in nr-llm with sodium encryption
- All backend AJAX endpoints require TYPO3 authentication
- Frontend DOMParser-based content sanitization via CKEditor's HTML processing pipeline
- TYPO3 backend route authentication with nonce-based URL tokens
- Content Security Policy (CSP) compatible

Migration to v3.x
-----------------

[](#migration-to-v3x)

Version 3.0 requires TYPO3 v13.4+ and PHP 8.2+. It removes the frontend-only architecture and uses the nr-llm extension for provider-agnostic LLM access. API keys are no longer stored in extension settings.

See [CHANGELOG.md](CHANGELOG.md) for migration details.

License
-------

[](#license)

This project is licensed under the GNU General Public License v3.0 - see the [LICENSE](LICENSE) file for details.

Contributing
------------

[](#contributing)

See [CONTRIBUTING.md](CONTRIBUTING.md) for contribution guidelines.

Contact
-------

[](#contact)

[Netresearch DTT GmbH](https://www.netresearch.de/) - Your TYPO3 and eCommerce experts.

> [Twitter](https://twitter.com/netresearch) | [LinkedIn](https://www.linkedin.com/company/netresearch/) | [GitHub](https://github.com/netresearch)

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance89

Actively maintained with recent releases

Popularity33

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity68

Established project with proven stability

 Bus Factor1

Top contributor holds 64.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~58 days

Recently: every ~29 days

Total

21

Last Release

93d ago

Major Versions

0.0.2 → 1.0.02023-01-25

1.2.4 → v2.0.0-alpha.12024-02-16

1.2.7 → v2.0.0-alpha.22025-11-24

v2.0.0 → v3.0.02026-03-11

PHP version history (2 changes)v2.0.0PHP ^8.2 || ^8.3 || ^8.4

v3.0.0PHP ^8.2

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/151247?v=4)[Netresearch DTT GmbH](/maintainers/netresearch)[@netresearch](https://github.com/netresearch)

---

Top Contributors

[![CybotTM](https://avatars.githubusercontent.com/u/326348?v=4)](https://github.com/CybotTM "CybotTM (230 commits)")[![renovate[bot]](https://avatars.githubusercontent.com/in/2740?v=4)](https://github.com/renovate[bot] "renovate[bot] (60 commits)")[![TheDevMinerTV](https://avatars.githubusercontent.com/u/29845135?v=4)](https://github.com/TheDevMinerTV "TheDevMinerTV (13 commits)")[![Copilot](https://avatars.githubusercontent.com/in/1143301?v=4)](https://github.com/Copilot "Copilot (12 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (12 commits)")[![Gitsko](https://avatars.githubusercontent.com/u/17161911?v=4)](https://github.com/Gitsko "Gitsko (12 commits)")[![Thoemel42](https://avatars.githubusercontent.com/u/32194305?v=4)](https://github.com/Thoemel42 "Thoemel42 (6 commits)")[![just-tobi](https://avatars.githubusercontent.com/u/5242689?v=4)](https://github.com/just-tobi "just-tobi (4 commits)")[![olagwin](https://avatars.githubusercontent.com/u/49477230?v=4)](https://github.com/olagwin "olagwin (2 commits)")[![ngolatka](https://avatars.githubusercontent.com/u/7393538?v=4)](https://github.com/ngolatka "ngolatka (2 commits)")[![vergissberlin](https://avatars.githubusercontent.com/u/179964?v=4)](https://github.com/vergissberlin "vergissberlin (1 commits)")[![AndreasMueller75](https://avatars.githubusercontent.com/u/32193606?v=4)](https://github.com/AndreasMueller75 "AndreasMueller75 (1 commits)")

---

Tags

aickeditorcontent-generationllmopenaiphptypo3typo3-extensionaiextensionbackendtypo3cowriter

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/netresearch-t3-cowriter/health.svg)

```
[![Health](https://phpackages.com/badges/netresearch-t3-cowriter/health.svg)](https://phpackages.com/packages/netresearch-t3-cowriter)
```

###  Alternatives

[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

101466.4k45](/packages/friendsoftypo3-content-blocks)[wazum/sluggi

TYPO3 extension for URL slug management with inline editing, auto-sync, locking, access control, and redirects

41515.2k](/packages/wazum-sluggi)[georgringer/news

News system - Versatile news system based on Extbase &amp; Fluid and using the latest technologies provided by TYPO3 CMS.

2825.2M112](/packages/georgringer-news)[netresearch/rte-ckeditor-image

Image support in CKEditor for the TYPO3 ecosystem - by Netresearch

611.0M6](/packages/netresearch-rte-ckeditor-image)[friendsoftypo3/extension-builder

Tool to kickstart and maintain TYPO3 extensions

112811.4k5](/packages/friendsoftypo3-extension-builder)[friendsoftypo3/visual-editor

TYPO3 CMS Visual Editor - Brings a modern WYSIWYG editing experience to TYPO3 CMS.

523.1k2](/packages/friendsoftypo3-visual-editor)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
