From 6ac62dec1c7c2cdf54e220398cf9520addaad917 Mon Sep 17 00:00:00 2001 From: Tom Softreck Date: Tue, 4 Aug 2026 14:23:08 +0200 Subject: [PATCH 1/5] plan(interfaces): restore communication prompt resolution Ticket: ticket-033 Workstream: interfaces --- TODO.md | 5 +++ project/TICKETS.md | 1 + project/ticket-033/README.md | 48 ++++++++++++++++++++++++++++ project/ticket-033/ai-codex-logs.txt | 4 +++ project/ticket-033/ai-codex.md | 36 +++++++++++++++++++++ project/ticket-033/changelog.md | 9 ++++++ project/ticket-033/intent.json | 17 ++++++++++ project/ticket-033/preprompt.md | 8 +++++ 8 files changed, 128 insertions(+) create mode 100644 project/ticket-033/README.md create mode 100644 project/ticket-033/ai-codex-logs.txt create mode 100644 project/ticket-033/ai-codex.md create mode 100644 project/ticket-033/changelog.md create mode 100644 project/ticket-033/intent.json create mode 100644 project/ticket-033/preprompt.md diff --git a/TODO.md b/TODO.md index 7ce22cb..8ca2342 100644 --- a/TODO.md +++ b/TODO.md @@ -2,6 +2,11 @@ ## Active tickets +- [ ] [`ticket-033`](project/ticket-033/README.md) — restore communication LLM + prompt resolution after its helper moved one directory deeper. Current + state: `PLAN / WAIT_FOR_APPROVAL`; one production file, estimated under 30 + minutes, no test or prompt-content changes. + - [ ] [`ticket-019`](project/ticket-019/README.md) — publish the dependency-free Python SDK as the root PyPI distribution `todo2code` through `goal -a`, with one root `pyproject.toml` and SDK-only artifacts. Current state: diff --git a/project/TICKETS.md b/project/TICKETS.md index 071ccc8..a7788bc 100644 --- a/project/TICKETS.md +++ b/project/TICKETS.md @@ -27,4 +27,5 @@ of `project/README.md`, which remains a generated technical-analysis artifact. | **ticket-019** | [`README.md`](./ticket-019/README.md) | [`preprompt.md`](./ticket-019/preprompt.md) | - | [`ai-codex.md`](./ticket-019/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-019/ai-codex-logs.txt) | [`changelog.md`](./ticket-019/changelog.md) | | **ticket-020** | [`README.md`](./ticket-020/README.md) | [`preprompt.md`](./ticket-020/preprompt.md) | - | [`ai-codex.md`](./ticket-020/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-020/ai-codex-logs.txt) | [`changelog.md`](./ticket-020/changelog.md) | | **ticket-022** | [`README.md`](./ticket-022/README.md) | [`preprompt.md`](./ticket-022/preprompt.md) | - | [`ai-codex.md`](./ticket-022/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-022/ai-codex-logs.txt) | [`changelog.md`](./ticket-022/changelog.md) | +| **ticket-033** | [`README.md`](./ticket-033/README.md) | [`preprompt.md`](./ticket-033/preprompt.md) | - | [`ai-codex.md`](./ticket-033/ai-codex.md) | [`ai-codex-logs.txt`](./ticket-033/ai-codex-logs.txt) | [`changelog.md`](./ticket-033/changelog.md) | diff --git a/project/ticket-033/README.md b/project/ticket-033/README.md new file mode 100644 index 0000000..daee9c2 --- /dev/null +++ b/project/ticket-033/README.md @@ -0,0 +1,48 @@ +# Ticket 033: Restore communication prompt resolution after module split + +- **ID**: ticket-033 +- **Owner**: unresolved:human +- **Status**: PLAN +- **Workflow state**: WAIT_FOR_APPROVAL +- **Created**: 2026-08-04 + +## Goal and scope + +Restore runtime resolution of `communication-to-intent.system.md` after the +communication LLM implementation moved one directory deeper. The copied path +logic still climbs three levels, which resolves from +`dist/src/communication/llm` to `dist/prompts`; repository prompts live at the +root `prompts` directory, requiring four levels from the compiled helper. + +The repair changes only the relative prompt root in the helper. It will not +copy prompts into `dist`, change provider fallback behavior, weaken +`require-llm`, edit tests or contact a live provider. One production file is +allowed and expected implementation time is under 30 minutes. + +## Planned changed paths + +- `src/communication/llm/implementation-helpers.ts`: correct the prompt root + for the module's new filesystem depth. +- `project/ticket-033/**`, `TODO.md`, `project/TICKETS.md`: intent and evidence. + +## Acceptance criteria + +- [ ] AC-01: Scope is approved by a human owner. +- [ ] AC-02: The communication prompt resolves from both compiled test/runtime + execution without relying on stale artifacts. +- [ ] AC-03: Both audited communication enrichment tests pass using their + mocked provider and no live request. +- [ ] AC-04: `require-llm` and correction validation behavior remain strict. +- [ ] AC-05: Clean build, focused/full tests, diff scope and governance evidence + are recorded without changing tests or prompt contents. + +## Participants + +- Human participant: unresolved; no user-* file was created by this script. +- Agent participant: [ai-codex.md](ai-codex.md) + +## Approval boundary + +- Current state: `PLAN / WAIT_FOR_APPROVAL`. +- Chat approval authorizes this interactive implementation only; trusted merge + evidence must remain independent and bound to the final SHA. diff --git a/project/ticket-033/ai-codex-logs.txt b/project/ticket-033/ai-codex-logs.txt new file mode 100644 index 0000000..8a8727d --- /dev/null +++ b/project/ticket-033/ai-codex-logs.txt @@ -0,0 +1,4 @@ +2026-08-04 planning +- Fresh base `caf6551`: two communication LLM tests fail because the split + helper resolves the prompt under nonexistent `dist/prompts`. +- No production source edited; state remains `WAIT_FOR_APPROVAL`. diff --git a/project/ticket-033/ai-codex.md b/project/ticket-033/ai-codex.md new file mode 100644 index 0000000..397e842 --- /dev/null +++ b/project/ticket-033/ai-codex.md @@ -0,0 +1,36 @@ +--- +participant-id: agent:codex +participant: codex +role: agent +ticket: ticket-033 +--- +# Participant: codex (AI agent) + +## Understanding + +The old implementation lived at `src/communication/llm.ts`; its compiled +module needed three parent traversals to reach repository-root `prompts`. +`loadCommunicationPrompt` now lives in +`src/communication/llm/implementation-helpers.ts`, one directory deeper, but +retained the old traversal. The error therefore names nonexistent +`dist/prompts/communication-to-intent.system.md`. This explains exactly two +tests and does not indicate provider or schema failure. + +## Execution plan + +1. Wait for explicit human approval before editing source. +2. Correct the relative prompt root by one directory in the owning helper. +3. Run build and focused communication LLM tests with their mocked provider. +4. Run the full fresh suite and verify both prompt failures disappear. +5. Record diff/scope and governance evidence; do not change tests or prompts. + +## Actual changes + +- None; waiting for approval. + +## Blockers + +- Human approval is required before implementation. +- Tickets 030, 031 and 032 remain independent sibling repairs and are not + absorbed into this diff. +- Four inherited ticket-018/ticket-019 governance errors remain outside scope. diff --git a/project/ticket-033/changelog.md b/project/ticket-033/changelog.md new file mode 100644 index 0000000..56b3889 --- /dev/null +++ b/project/ticket-033/changelog.md @@ -0,0 +1,9 @@ +# Ticket Changelog (ticket-033) + +## [0.1.0] - 2026-08-04 + +- Initial governance scaffold created. +- No human participant identity or content was generated. +- Renumbered the unpublished scaffold from 023 to 033 because remote PR #3 + already owns ticket-023. +- Documented the bounded prompt-resolution regression repair. diff --git a/project/ticket-033/intent.json b/project/ticket-033/intent.json new file mode 100644 index 0000000..ef068c4 --- /dev/null +++ b/project/ticket-033/intent.json @@ -0,0 +1,17 @@ +{ + "schema": "new-project.intent/v2", + "ticket": "ticket-033", + "summary": "Restore communication prompt resolution after module split", + "workstream": "interfaces", + "allowedPaths": [ + "src/communication/llm/implementation-helpers.ts", + "project/ticket-033/**", + "TODO.md", + "project/TICKETS.md" + ], + "forbiddenPaths": ["project/ticket-*/user-*.md"], + "stacks": ["node"], + "dependsOn": [], + "conflictsWith": [], + "integrationTicket": null +} diff --git a/project/ticket-033/preprompt.md b/project/ticket-033/preprompt.md new file mode 100644 index 0000000..c355298 --- /dev/null +++ b/project/ticket-033/preprompt.md @@ -0,0 +1,8 @@ +# Ticket preprompt + +- **Task ID**: ticket-033 +- **Task title**: Restore communication prompt resolution after module split +- **Created**: 2026-08-04T12:22:18Z + +Keep executable implementation outside this governance/evidence directory. +Read a human-owned user-*.md file only when one exists. From ece125e8d8674d06c286c5f31973b0e863620549 Mon Sep 17 00:00:00 2001 From: Tom Softreck Date: Tue, 4 Aug 2026 14:24:08 +0200 Subject: [PATCH 2/5] chore(ticket-033): enter approved edit state Ticket: ticket-033 Workstream: interfaces --- TODO.md | 2 +- project/ticket-033/README.md | 8 ++++---- project/ticket-033/ai-codex-logs.txt | 2 ++ project/ticket-033/ai-codex.md | 4 ++-- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/TODO.md b/TODO.md index 8ca2342..8fd57a9 100644 --- a/TODO.md +++ b/TODO.md @@ -4,7 +4,7 @@ - [ ] [`ticket-033`](project/ticket-033/README.md) — restore communication LLM prompt resolution after its helper moved one directory deeper. Current - state: `PLAN / WAIT_FOR_APPROVAL`; one production file, estimated under 30 + state: `IN_PROGRESS / EDIT`; one production file, estimated under 30 minutes, no test or prompt-content changes. - [ ] [`ticket-019`](project/ticket-019/README.md) — publish the dependency-free diff --git a/project/ticket-033/README.md b/project/ticket-033/README.md index daee9c2..ef86de6 100644 --- a/project/ticket-033/README.md +++ b/project/ticket-033/README.md @@ -2,8 +2,8 @@ - **ID**: ticket-033 - **Owner**: unresolved:human -- **Status**: PLAN -- **Workflow state**: WAIT_FOR_APPROVAL +- **Status**: IN_PROGRESS +- **Workflow state**: EDIT - **Created**: 2026-08-04 ## Goal and scope @@ -27,7 +27,7 @@ allowed and expected implementation time is under 30 minutes. ## Acceptance criteria -- [ ] AC-01: Scope is approved by a human owner. +- [x] AC-01: Scope is approved by a human owner. - [ ] AC-02: The communication prompt resolves from both compiled test/runtime execution without relying on stale artifacts. - [ ] AC-03: Both audited communication enrichment tests pass using their @@ -43,6 +43,6 @@ allowed and expected implementation time is under 30 minutes. ## Approval boundary -- Current state: `PLAN / WAIT_FOR_APPROVAL`. +- Current state: `IN_PROGRESS / EDIT` after explicit chat approval. - Chat approval authorizes this interactive implementation only; trusted merge evidence must remain independent and bound to the final SHA. diff --git a/project/ticket-033/ai-codex-logs.txt b/project/ticket-033/ai-codex-logs.txt index 8a8727d..3e67499 100644 --- a/project/ticket-033/ai-codex-logs.txt +++ b/project/ticket-033/ai-codex-logs.txt @@ -2,3 +2,5 @@ - Fresh base `caf6551`: two communication LLM tests fail because the split helper resolves the prompt under nonexistent `dist/prompts`. - No production source edited; state remains `WAIT_FOR_APPROVAL`. +- Human response `kontynuuj` authorized ticket-033; transitioned to + `IN_PROGRESS / EDIT`. diff --git a/project/ticket-033/ai-codex.md b/project/ticket-033/ai-codex.md index 397e842..d93b9d0 100644 --- a/project/ticket-033/ai-codex.md +++ b/project/ticket-033/ai-codex.md @@ -26,11 +26,11 @@ tests and does not indicate provider or schema failure. ## Actual changes -- None; waiting for approval. +- The human explicitly approved ticket-033 by replying `kontynuuj`; the + interactive implementation may enter `EDIT`. ## Blockers -- Human approval is required before implementation. - Tickets 030, 031 and 032 remain independent sibling repairs and are not absorbed into this diff. - Four inherited ticket-018/ticket-019 governance errors remain outside scope. From f96c0a8c100dfb4345603857bd40c6757cae4cc7 Mon Sep 17 00:00:00 2001 From: Tom Softreck Date: Tue, 4 Aug 2026 14:24:51 +0200 Subject: [PATCH 3/5] fix(communication): resolve prompt from split helper Ticket: ticket-033 Workstream: interfaces --- src/communication/llm/implementation-helpers.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/communication/llm/implementation-helpers.ts b/src/communication/llm/implementation-helpers.ts index b139af3..7a0cb06 100644 --- a/src/communication/llm/implementation-helpers.ts +++ b/src/communication/llm/implementation-helpers.ts @@ -297,7 +297,7 @@ export function audit( } export async function readPrompt(): Promise { - const promptPath = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '../../../prompts', 'communication-to-intent.system.md'); + const promptPath = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '../../../../prompts', 'communication-to-intent.system.md'); if (!(await pathExists(promptPath))) throw new Error(`Prompt not found: ${promptPath}`); return fs.readFile(promptPath, 'utf8'); } From f2afd42fa1bf29fa821d508862e5f068b4e5167c Mon Sep 17 00:00:00 2001 From: Tom Softreck Date: Tue, 4 Aug 2026 14:25:24 +0200 Subject: [PATCH 4/5] docs(ticket-033): record prompt regression validation Ticket: ticket-033 Workstream: interfaces --- TODO.md | 4 ++-- project/ticket-033/README.md | 24 ++++++++++++++++++------ project/ticket-033/ai-codex-logs.txt | 6 ++++++ project/ticket-033/ai-codex.md | 6 ++++++ project/ticket-033/changelog.md | 7 +++++++ 5 files changed, 39 insertions(+), 8 deletions(-) diff --git a/TODO.md b/TODO.md index 8fd57a9..f441f5f 100644 --- a/TODO.md +++ b/TODO.md @@ -4,8 +4,8 @@ - [ ] [`ticket-033`](project/ticket-033/README.md) — restore communication LLM prompt resolution after its helper moved one directory deeper. Current - state: `IN_PROGRESS / EDIT`; one production file, estimated under 30 - minutes, no test or prompt-content changes. + state: `IN_PROGRESS / VALIDATION`; focused tests pass and both targeted + failures are removed, with no test or prompt-content changes. - [ ] [`ticket-019`](project/ticket-019/README.md) — publish the dependency-free Python SDK as the root PyPI distribution `todo2code` through `goal -a`, with diff --git a/project/ticket-033/README.md b/project/ticket-033/README.md index ef86de6..452cf94 100644 --- a/project/ticket-033/README.md +++ b/project/ticket-033/README.md @@ -3,7 +3,7 @@ - **ID**: ticket-033 - **Owner**: unresolved:human - **Status**: IN_PROGRESS -- **Workflow state**: EDIT +- **Workflow state**: VALIDATION - **Created**: 2026-08-04 ## Goal and scope @@ -28,12 +28,12 @@ allowed and expected implementation time is under 30 minutes. ## Acceptance criteria - [x] AC-01: Scope is approved by a human owner. -- [ ] AC-02: The communication prompt resolves from both compiled test/runtime +- [x] AC-02: The communication prompt resolves from both compiled test/runtime execution without relying on stale artifacts. -- [ ] AC-03: Both audited communication enrichment tests pass using their +- [x] AC-03: Both audited communication enrichment tests pass using their mocked provider and no live request. -- [ ] AC-04: `require-llm` and correction validation behavior remain strict. -- [ ] AC-05: Clean build, focused/full tests, diff scope and governance evidence +- [x] AC-04: `require-llm` and correction validation behavior remain strict. +- [x] AC-05: Clean build, focused/full tests, diff scope and governance evidence are recorded without changing tests or prompt contents. ## Participants @@ -43,6 +43,18 @@ allowed and expected implementation time is under 30 minutes. ## Approval boundary -- Current state: `IN_PROGRESS / EDIT` after explicit chat approval. +- Current state: `IN_PROGRESS / VALIDATION` after implementing and testing the + bounded repair. - Chat approval authorizes this interactive implementation only; trusted merge evidence must remain independent and bound to the final SHA. + +## Validation evidence + +- `npm run build`: PASS. +- Focused communication LLM suite: 3 passed, 0 failed; mocked provider only. +- Full fresh suite on isolated base: 338 tests, 328 passed, 9 failed and one + skipped. Both prompt failures are removed. The remaining failures correspond + exactly to independent tickets 030, 031 and 032. +- `git diff --check`: PASS. +- `make governance`: only four inherited ticket-018/ticket-019 diagnostics; + no ticket-033 scope or workstream finding. diff --git a/project/ticket-033/ai-codex-logs.txt b/project/ticket-033/ai-codex-logs.txt index 3e67499..8ce0cf0 100644 --- a/project/ticket-033/ai-codex-logs.txt +++ b/project/ticket-033/ai-codex-logs.txt @@ -4,3 +4,9 @@ - No production source edited; state remains `WAIT_FOR_APPROVAL`. - Human response `kontynuuj` authorized ticket-033; transitioned to `IN_PROGRESS / EDIT`. +- `npm run build`: PASS. +- `node --test dist/test/communication-llm.test.js`: PASS (3/3), mocked provider. +- Fresh full suite: 338 total, 328 pass, 9 fail, 1 skip; both ticket-033 prompt + failures removed, remaining failures belong to tickets 030/031/032. +- `git diff --check`: PASS. +- `make governance`: four inherited ticket-018/ticket-019 errors, no ticket-033 finding. diff --git a/project/ticket-033/ai-codex.md b/project/ticket-033/ai-codex.md index d93b9d0..e4eb0a2 100644 --- a/project/ticket-033/ai-codex.md +++ b/project/ticket-033/ai-codex.md @@ -28,9 +28,15 @@ tests and does not indicate provider or schema failure. - The human explicitly approved ticket-033 by replying `kontynuuj`; the interactive implementation may enter `EDIT`. +- Corrected the prompt traversal by one directory in the owning helper. No + prompt content, provider behavior, schema or test changed. +- Clean build and all three focused communication LLM tests pass, including + correction retry and strict require-mode behavior. The isolated full suite + no longer contains either prompt-resolution failure. ## Blockers - Tickets 030, 031 and 032 remain independent sibling repairs and are not absorbed into this diff. - Four inherited ticket-018/ticket-019 governance errors remain outside scope. +- Trusted merge approval for the final head SHA is still required. diff --git a/project/ticket-033/changelog.md b/project/ticket-033/changelog.md index 56b3889..98687b5 100644 --- a/project/ticket-033/changelog.md +++ b/project/ticket-033/changelog.md @@ -7,3 +7,10 @@ - Renumbered the unpublished scaffold from 023 to 033 because remote PR #3 already owns ticket-023. - Documented the bounded prompt-resolution regression repair. + +## [0.2.0] - 2026-08-04 + +- Corrected communication prompt resolution for the helper's post-refactor + directory depth without changing prompt contents or LLM policy. +- Focused communication LLM tests pass 3/3 and the two targeted full-suite + failures are removed. From 9086e308ccef8c0216b7564906c875c880bc860f Mon Sep 17 00:00:00 2001 From: Tom Softreck Date: Tue, 4 Aug 2026 14:26:33 +0200 Subject: [PATCH 5/5] docs(ticket-033): record combined green integration Ticket: ticket-033 Workstream: interfaces --- project/ticket-033/README.md | 3 +++ project/ticket-033/ai-codex-logs.txt | 2 ++ project/ticket-033/ai-codex.md | 3 +++ project/ticket-033/changelog.md | 2 ++ 4 files changed, 10 insertions(+) diff --git a/project/ticket-033/README.md b/project/ticket-033/README.md index 452cf94..a3e72b3 100644 --- a/project/ticket-033/README.md +++ b/project/ticket-033/README.md @@ -58,3 +58,6 @@ allowed and expected implementation time is under 30 minutes. - `git diff --check`: PASS. - `make governance`: only four inherited ticket-018/ticket-019 diagnostics; no ticket-033 scope or workstream finding. +- Ephemeral integration of implementation commits `9c25942`, `bbd236f`, + `c5db5fb` and `f96c0a8` over base `caf6551`: clean build PASS; full suite + 338 tests, 337 passed, 0 failed and one environment-dependent JDK skip. diff --git a/project/ticket-033/ai-codex-logs.txt b/project/ticket-033/ai-codex-logs.txt index 8ce0cf0..303e0dc 100644 --- a/project/ticket-033/ai-codex-logs.txt +++ b/project/ticket-033/ai-codex-logs.txt @@ -10,3 +10,5 @@ failures removed, remaining failures belong to tickets 030/031/032. - `git diff --check`: PASS. - `make governance`: four inherited ticket-018/ticket-019 errors, no ticket-033 finding. +- Combined implementation-only integration on `caf6551`: build PASS; full suite + PASS (338 total, 337 pass, 0 fail, 1 JDK skip). diff --git a/project/ticket-033/ai-codex.md b/project/ticket-033/ai-codex.md index e4eb0a2..eb71c88 100644 --- a/project/ticket-033/ai-codex.md +++ b/project/ticket-033/ai-codex.md @@ -33,6 +33,9 @@ tests and does not indicate provider or schema failure. - Clean build and all three focused communication LLM tests pass, including correction retry and strict require-mode behavior. The isolated full suite no longer contains either prompt-resolution failure. +- Verified the four sibling implementation commits together in a detached, + uncommitted integration worktree: build passes and all 337 runnable tests + pass. This is test evidence, not merge approval. ## Blockers diff --git a/project/ticket-033/changelog.md b/project/ticket-033/changelog.md index 98687b5..f9137c1 100644 --- a/project/ticket-033/changelog.md +++ b/project/ticket-033/changelog.md @@ -14,3 +14,5 @@ directory depth without changing prompt contents or LLM policy. - Focused communication LLM tests pass 3/3 and the two targeted full-suite failures are removed. +- Combined tickets 030-033 implementation verification passes all 337 runnable + tests on a clean build.