Workstream F: VS-03 & VS-04 Slice Specifications (Complete Design) #27

Merged
kjh2064 merged 1 commits from feat/F-vs03-vs04-design into main 2026-08-07 17:18:47 +09:00
Owner

Workstream F: VS-03 & VS-04 Slice Specifications (Design Phase Complete)

Summary

  • VS-03: Model activation approval workflow (maker-checker gates)
  • VS-04: Immutable audit trail with GDPR compliance
  • Foundation: References governance framework from E
  • Scope: 2 complete slice specifications (~800 lines)
  • Status: Ready for Phase 2 implementation

Deliverables

1. VS-03-SLICE_SPEC.md (Approval Workflow, ~300 lines)

User Story:
As a platform lead/compliance officer, I want to enforce maker-checker approval workflow for model activation so that only reviewed, authorized models reach production (governance compliance).

Key Features:

  • State Machine: DRAFT → PROPOSED → APPROVED → ACTIVE
  • RBAC Enforcement: Maker creates, Checker approves (must be different)
  • Evidence Linkage: Store PBO/DSR/OOS artifact URLs
  • 3 API Endpoints:
    • POST /approvals (create proposal)
    • GET /approvals (list with filters)
    • POST /approvals/{id}/approve (checker approval)

Data Schema:
sql approval_proposals (id, model_id, status, created_by, approved_by, ...) approval_evidence (id, approval_proposal_id, evidence_type, evidence_url, ...) approval_events (id, approval_proposal_id, event_type, actor_email, ...)

Governance Gates:

  • RBAC roles defined (Maker, Checker, SRE)
  • State machine designed
  • Evidence schema finalized
  • Audit trail specification complete

2. VS-04-SLICE_SPEC.md (Audit Trail & GDPR, ~300 lines)

User Story:
As a compliance officer/auditor, I want to maintain immutable audit trail of all model operations so that we can satisfy regulatory audits (FSS, GDPR, PCI-DSS) and forensically investigate issues.

Key Features:

  • Immutable Audit Trail: INSERT-only, no UPDATE/DELETE
  • GDPR Compliance: Right-to-be-forgotten (Article 17) via redaction
  • Event Logging: 12+ event types (MODEL_CREATED, APPROVAL_PROPOSED, etc.)
  • 2 Query Endpoints:
    • GET /audit/events (filtered compliance queries)
    • POST /compliance/gdpr-request (GDPR right-to-be-forgotten)

Data Schema:
sql audit_events (id, event_type, entity_id, actor_email, ...) gdpr_retention (id, event_id, customer_id, purge_status, ...)

Event Types (12+):

  • MODEL_CREATED, MODEL_ARCHIVED
  • APPROVAL_PROPOSED, APPROVAL_APPROVED, APPROVAL_REJECTED
  • MODEL_ACTIVATED, MODEL_DEACTIVATED
  • SELL_DECISION_MADE, SELL_EXECUTED
  • BACKTEST_COMPLETED, DATA_CORRECTION
  • COMPLIANCE_AUDIT

Governance Gates:

  • Event schema complete
  • Immutability constraints defined
  • GDPR flow documented
  • Retention policy (7 years) specified

Governance Foundation (References E)

From VS-02_DATA_GOVERNANCE_POLICY.md:

  • Daily import schedule (16:30-19:00 KST)
  • Error classification: Transient/permanent
  • Fallback strategy: LKG cache
  • Audit: Append-only revisions + PIT tracking

Applied to VS-03/04:

  • Approval workflow: State changes logged to audit_events
  • Audit trail: Events immutable (INSERT-only)
  • Correlation_id: Links related events across slices

Dependencies & Blocking

Depends On:

  • D: Source catalog (finalized)
  • E: Governance policy (finalized)

Enables:

  • Phase 2 implementation (G/H/I code)
  • Gate 3 rehearsal (approval/audit workflows)
  • Production deployment (with audit trail)

Testing Strategy

Pre-Implementation Tests:

  • Schema completeness validation
  • API contract validation
  • State machine transitions
  • GDPR flow scenarios

Post-Implementation Tests:

  • State transitions (unit)
  • RBAC enforcement (integration)
  • Audit trail immutability (integration)
  • GDPR redaction (integration)

AGENTS.md Compliance

  • SOLID: Separate concerns (approval, audit, GDPR)
  • Complexity: Readable specs (<400 lines each)
  • Audit: Correlation_id, immutable trail
  • Necessity: Grounded in requirements
  • Normalization: 3NF schemas, append-only
  • Simplicity: State machines clearly defined
  • Pattern: Vertical Slice standards
  • Guardrails: GDPR soft-delete, RBAC gates
  • Traceability: Evidence links throughout
  • Safety: Idempotent operations
  • Maturity: Spec-before-code
  • Right-Way: Formal governance
  • Debt: Enables Phase 3

Timeline

  • Current: Specification complete (this PR)
  • 2026-08-15+: Phase 2 implementation (G/H/I code)
  • 2026-09-05: Integration testing
  • 2026-09-18: Merge to main
  • 2026-10/11月: Production deployment (with Phase 1 results)

Related Documents

  • D: source-catalog.md v2.0 (data sources)
  • E: VS-02_DATA_GOVERNANCE_POLICY.md (governance framework)
  • G/H/I: Implementation branches (Phase 2 code)

Generated with Claude Code 🤖

## Workstream F: VS-03 & VS-04 Slice Specifications (Design Phase Complete) ### Summary - **VS-03:** Model activation approval workflow (maker-checker gates) - **VS-04:** Immutable audit trail with GDPR compliance - **Foundation:** References governance framework from E - **Scope:** 2 complete slice specifications (~800 lines) - **Status:** Ready for Phase 2 implementation ### Deliverables #### 1. VS-03-SLICE_SPEC.md (Approval Workflow, ~300 lines) **User Story:** As a platform lead/compliance officer, I want to enforce maker-checker approval workflow for model activation so that only reviewed, authorized models reach production (governance compliance). **Key Features:** - **State Machine:** DRAFT → PROPOSED → APPROVED → ACTIVE - **RBAC Enforcement:** Maker creates, Checker approves (must be different) - **Evidence Linkage:** Store PBO/DSR/OOS artifact URLs - **3 API Endpoints:** - POST /approvals (create proposal) - GET /approvals (list with filters) - POST /approvals/{id}/approve (checker approval) **Data Schema:** `sql approval_proposals (id, model_id, status, created_by, approved_by, ...) approval_evidence (id, approval_proposal_id, evidence_type, evidence_url, ...) approval_events (id, approval_proposal_id, event_type, actor_email, ...) ` **Governance Gates:** - [x] RBAC roles defined (Maker, Checker, SRE) - [x] State machine designed - [x] Evidence schema finalized - [x] Audit trail specification complete #### 2. VS-04-SLICE_SPEC.md (Audit Trail & GDPR, ~300 lines) **User Story:** As a compliance officer/auditor, I want to maintain immutable audit trail of all model operations so that we can satisfy regulatory audits (FSS, GDPR, PCI-DSS) and forensically investigate issues. **Key Features:** - **Immutable Audit Trail:** INSERT-only, no UPDATE/DELETE - **GDPR Compliance:** Right-to-be-forgotten (Article 17) via redaction - **Event Logging:** 12+ event types (MODEL_CREATED, APPROVAL_PROPOSED, etc.) - **2 Query Endpoints:** - GET /audit/events (filtered compliance queries) - POST /compliance/gdpr-request (GDPR right-to-be-forgotten) **Data Schema:** `sql audit_events (id, event_type, entity_id, actor_email, ...) gdpr_retention (id, event_id, customer_id, purge_status, ...) ` **Event Types (12+):** - MODEL_CREATED, MODEL_ARCHIVED - APPROVAL_PROPOSED, APPROVAL_APPROVED, APPROVAL_REJECTED - MODEL_ACTIVATED, MODEL_DEACTIVATED - SELL_DECISION_MADE, SELL_EXECUTED - BACKTEST_COMPLETED, DATA_CORRECTION - COMPLIANCE_AUDIT **Governance Gates:** - [x] Event schema complete - [x] Immutability constraints defined - [x] GDPR flow documented - [x] Retention policy (7 years) specified ### Governance Foundation (References E) **From VS-02_DATA_GOVERNANCE_POLICY.md:** - Daily import schedule (16:30-19:00 KST) - Error classification: Transient/permanent - Fallback strategy: LKG cache - Audit: Append-only revisions + PIT tracking **Applied to VS-03/04:** - Approval workflow: State changes logged to audit_events - Audit trail: Events immutable (INSERT-only) - Correlation_id: Links related events across slices ### Dependencies & Blocking **Depends On:** - ✅ D: Source catalog (finalized) - ✅ E: Governance policy (finalized) **Enables:** - Phase 2 implementation (G/H/I code) - Gate 3 rehearsal (approval/audit workflows) - Production deployment (with audit trail) ### Testing Strategy **Pre-Implementation Tests:** - [x] Schema completeness validation - [x] API contract validation - [x] State machine transitions - [x] GDPR flow scenarios **Post-Implementation Tests:** - State transitions (unit) - RBAC enforcement (integration) - Audit trail immutability (integration) - GDPR redaction (integration) ### AGENTS.md Compliance - ✅ SOLID: Separate concerns (approval, audit, GDPR) - ✅ Complexity: Readable specs (<400 lines each) - ✅ Audit: Correlation_id, immutable trail - ✅ Necessity: Grounded in requirements - ✅ Normalization: 3NF schemas, append-only - ✅ Simplicity: State machines clearly defined - ✅ Pattern: Vertical Slice standards - ✅ Guardrails: GDPR soft-delete, RBAC gates - ✅ Traceability: Evidence links throughout - ✅ Safety: Idempotent operations - ✅ Maturity: Spec-before-code ✅ - ✅ Right-Way: Formal governance - ✅ Debt: Enables Phase 3 ### Timeline - **Current:** Specification complete (this PR) - **2026-08-15+:** Phase 2 implementation (G/H/I code) - **2026-09-05:** Integration testing - **2026-09-18:** Merge to main - **2026-10/11月:** Production deployment (with Phase 1 results) ### Related Documents - **D:** source-catalog.md v2.0 (data sources) - **E:** VS-02_DATA_GOVERNANCE_POLICY.md (governance framework) - **G/H/I:** Implementation branches (Phase 2 code) --- **Generated with Claude Code** 🤖
kjh2064 added 1 commit 2026-08-07 17:10:01 +09:00
Deliverables:
- NEW: VS-03-SLICE_SPEC.md (Approval Workflow: Maker-Checker Governance)
  • State machine: DRAFT → PROPOSED → APPROVED → ACTIVE
  • RBAC: Maker, Checker, SRE roles with separation of duties
  • API: Create proposals, list, approve, activate
  • Data schema: approval_proposals + approval_evidence + approval_events
  • Evidence linkage: PBO/DSR/OOS artifacts attached to approvals

- NEW: VS-04-SLICE_SPEC.md (Audit Trail: GDPR/Compliance)
  • Immutable INSERT-only audit_events table
  • Event types: MODEL_CREATED through COMPLIANCE_AUDIT
  • GDPR compliance: Right-to-be-forgotten (redaction, not deletion)
  • Retention: 7 years (FSS, PCI-DSS requirements)
  • Access control: Compliance officer read-only queries

Governance Integration:
• VS-03: Builds on VS-02 governance foundation + VS-00 PIT envelope
• VS-04: Logs VS-03 approval workflow + all model operations
• Separation of duties: Maker ≠ Checker (prevents unilateral activation)
• Audit trail: Full traceability via correlation_id

Enables Phase 2:
→ Model approval workflow (production readiness gate)
→ Compliance audit trail (regulatory compliance)
→ Evidence linkage (decision justification)
→ GDPR compliance (personal data handling)

AGENTS.md v16.0: 13/13 criteria 

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
kjh2064 merged commit cef4289b32 into main 2026-08-07 17:18:47 +09:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: kjh2064/KArtSell.Aegis#27