ADR-069: Remove the unusable PromptTemplate stack
- Status
-
Accepted
- Date
-
2026-07-16
- Authors
-
Netresearch DTT GmbH
Context
The extension shipped a Prompt domain stack from an early
design phase: the Domain entity, its
Domain, the
Service (+ Prompt),
the Exception, and the
tx_nrllm_prompttemplate table in ext_.
The stack was never usable at runtime and had no production consumers:
- No TCA.
Configuration/has noTCA/ tx_nrllm_prompttemplate.phpandConfiguration/has noExtbase/ Persistence/ Classes. php Promptmapping. Without either, Extbase cannot map the table, so everyTemplate Promptmethod fails at runtime.Template Repository - Zero consumers. Nothing injected
Promptor the repository. The onlyTemplate Service Interface PromptTemplatereferences elsewhere were the unrelatedTask::/get Prompt Template () prompt_templatestring column and ADR-031's contrast withPrompt.Snippet - No coverage. No functional test loaded the
PromptTemplates.csvfixture; the repository had 0% coverage from every suite. The service was unit-tested only against a mocked repository, so the runtime gap never surfaced. This was found while closing zero-coverage gaps (GitHub issue #399).
The stack was superseded twice: ADR-031 introduced the lightweight
Prompt library for reusable prompt fragments, and the
Task entity (with its prompt_template string field) covers
predefined, editor-managed prompts. Adding TCA plus functional tests to
resurrect the stack would invest in a surface no code uses.
Decision
Remove the dormant PromptTemplate stack in full:
- the
Domainentity andModel Prompt Template Domain;Repository Prompt Template Repository - the
ServiceandPrompt Template Service Service, including the public interface alias inPrompt Template Service Interface Configuration/;Services. yaml - the
Exception(used solely by the removed service);Prompt Template Not Found Exception - the
tx_nrllm_prompttemplateCREATE TABLEblock inext_;tables. sql - the unit tests and the
PromptTemplates.csvfunctional fixture that covered only the removed classes.
Task's unrelated prompt_template string field,
Prompt, and ADR-031 are untouched.
Consequences
- BREAKING (public API).
ServiceandPrompt Template Service Serviceare removed from the DI container. Any external caller resolving them would have failed at runtime already (no TCA), so no working integration can break; the removal is nonetheless a public-surface change and is called out for completeness. Pre-1.0, this is acceptable.Prompt Template Service Interface - Orphaned database table.
tx_nrllm_prompttemplateis no longer declared. TYPO3 does not drop tables automatically; on existing installations the table becomes orphaned. Operators remove it via the database analyzer (Admin Tools > Maintenance > Analyze Database Structure). No upgrade wizard is provided — the table held no data any code ever wrote. - Public-service count: 27 → 26. Removing the
Promptalias drops the auditedTemplate Service Interface public: truecount from 27 (ADR-065) to 26. This ADR is the new count authority, superseding ADR-065's count exactly as ADR-065 superseded ADR-028's. The breakdown is now 14 + 5 + 1 + 4 + 2 = 26: ADR-065's Category B (supporting-service interface aliases) drops from 6 to 5. TheTestsUnit Configuration Public Services Policy Test EXPECTED_PUBLIC_TRUE_COUNTconstant and this ADR are the audit trail. ADR-065 remains the record of the 45 → 27 reduction. - One prompt surface, not two. ADR-031's "two prompt-related
entities now coexist" no longer holds:
Prompt(fragments) andSnippet Task(predefined prompts) are the remaining surfaces.