Current Task

Sprint 3 Prompt Library

Create ONLY:

docs/02-architecture/SPRINT3_PROMPT_LIBRARY.md

This is a documentation task only.

Do NOT implement code.

Do NOT modify Sprint 3 Planning.

Do NOT modify Sprint 3 Execution Guide.

Do NOT create implementation prompts outside this library.

Do NOT continue to WS-001.

Wait for Human Approval after completing this document.

--------------------------------------------------
Mandatory Reading
--------------------------------------------------

Governance

- AI.md v1.1
- AI_DEVELOPMENT_SYSTEM.md
- WORKFLOW.md
- PROJECT.md

Architecture

- ADR v1.0
- DBP v1.1
- MASTER_IMPLEMENTATION_BACKLOG_v1.1

Sprint Documents

- SPRINT3_PLANNING.md
- SPRINT3_EXECUTION_GUIDE.md

Reference Documents

- SPRINT1_PROMPT_LIBRARY.md
- SPRINT2_PROMPT_LIBRARY.md

Use Sprint 2 Prompt Library as the editorial baseline.

--------------------------------------------------
Objective
--------------------------------------------------

Create the official Prompt Library for Sprint 3.

The library standardizes every AI prompt used during Sprint 3.

It does NOT define architecture.

It does NOT define implementation.

It defines reusable prompt templates.

--------------------------------------------------
Required Prompt Templates
--------------------------------------------------

Template 1

Pre-Implementation Prompt

Purpose:

Verify:

- dependencies
- clean working tree
- parent commits
- documentation consistency
- expected files
- frozen kernel
- workspace assumptions

before implementation begins.

--------------------------------------------------

Template 2

Workspace Implementation Prompt

Reusable for:

WorkspaceMiddleware

WS-001

WS-002

WS-003

Must require:

- dependency verification

- files expected

- implementation boundaries

- security checklist

- implementation report

- no automatic continuation

--------------------------------------------------

Template 3

Implementation Review Prompt

Standard implementation audit.

Require:

- php -l

- acceptance criteria

- dependency verification

- security verification

- workspace isolation verification

- implementation report

--------------------------------------------------

Template 4

Architecture Review Prompt

Used after Sprint 3 implementation.

Review:

- tenant isolation

- middleware architecture

- service layer

- transaction ownership

- audit integrity

- DRP requirement

- technical debt

Produce:

SPRINT3_ARCHITECTURE_REVIEW.md

--------------------------------------------------

Template 5

Planning Review Prompt

Reusable.

Review:

- planning consistency

- dependency order

- file paths

- middleware naming

- task sequencing

- governance alignment

--------------------------------------------------

Template 6

Execution Guide Review Prompt

Reusable.

Review:

- workflow

- security

- quality gates

- dependency rules

- implementation lifecycle

--------------------------------------------------

Template 7

Prompt Library Review Prompt

Reusable.

Review:

- template consistency

- governance alignment

- duplicate prompts

- numbering

- terminology

--------------------------------------------------

Template 8

Document Synchronization Prompt

Reusable.

After approved DRP only.

Synchronize:

- MIB

- DBP

- ADR

- AI Development System

- Planning

Never synchronize before approval.

--------------------------------------------------
Standard Workflow
--------------------------------------------------

For every Sprint 3 implementation:

Planning

↓

Execution Guide

↓

Prompt Library

↓

Single Task Prompt

↓

Implementation

↓

Implementation Review

↓

Human Approval

↓

Git Commit

↓

Git Push

↓

Memory

↓

Next Task

No automatic continuation.

--------------------------------------------------
Governance Rules
--------------------------------------------------

Every implementation session:

- one task only

- one implementation report

- one memory

- one approval

- one commit

No multi-task implementation.

No skipping workflow.

--------------------------------------------------
Conflict Rules
--------------------------------------------------

If any documentation conflict occurs:

STOP

Identify documents

Explain conflict

Propose options

Wait for approval

Previously approved Sprint 2 architectural clarifications remain authoritative.

Do not reopen resolved conflicts.

--------------------------------------------------
Prompt Design Rules
--------------------------------------------------

All templates must:

- be reusable

- be implementation-independent

- remain sprint-oriented

- avoid project-specific hardcoding whenever possible

- preserve governance wording

--------------------------------------------------
Review Requirements
--------------------------------------------------

Perform a complete editorial review.

Verify:

- numbering

- terminology

- workflow

- headings

- consistency

- cross references

Correct editorial issues only.

No architecture changes.

--------------------------------------------------
Output
--------------------------------------------------

Create only:

SPRINT3_PROMPT_LIBRARY.md

Provide:

1. Prompt Templates Created

2. Standard Workflow Summary

3. Reusable Templates Summary

4. Governance Validation

5. Editorial Improvements

6. Final Recommendation

If no further issues remain:

Status:
FINAL

Version:
1.0 (Final)

Ready for:
WS-001 Implementation

Do NOT continue to implementation.

Wait for Human Approval.