Architecture Decision Records
This section documents the significant architectural decisions made while building nr_repurpose. Each record captures the context, the decision, and its consequences, in the format used across the Netresearch TYPO3 extensions.
Decision records
ADR-001: Asynchronous generation via Symfony Messenger
Why job generation runs in a worker, and why the handler swallows failures onto the job row.
ADR-002: Node + Playwright renderer for image composition
Why HTML-to-PNG and AI-background compositing run through a bundled Node renderer driving system Chromium.
ADR-003: Provider credentials delegated to nr-llm
Why this extension owns no provider code and no API key, and reaches every provider only through nr-llm.
ADR-004: Text formats as schema-validated structured output
Why the text formats ask nr-llm for schema-validated JSON and enforce limits in the generator, not only in the prompt.
ADR-005: AI label on every artifact, embedded at storage
Why every file carries a machine-readable AI marker written in PHP when it is stored, and which visible labels are optional.
ADR-006: Document formats as HTML printed to PDF
Why the slide deck and the handout are Fluid templates printed by Chromium, and how the PDF carries the AI label.
ADR-007: Approval step and publishing through a webhook
Why every artifact has an approval state, and why approved social posts leave through a webhook instead of network APIs.
ADR-008: Capability permissions checked before spend
Why the extension checks generate_ and
generate_ itself, for the job's creator, before the budget.