T6D W04 Approved Product Contract¶
| Field | Value |
|---|---|
| Approver | Requesting user via current conversation (W04 PASS + promote production plan) |
| Date | 2026-08-30 |
| Scope | SC-ASSESS / W04 only |
| Status | APPROVED_BY_REQUESTING_USER_CONVERSATION |
| Core V1 impact | None |
| Production authority | Only via exact demo candidate → UAT → GBN promotion runbook |
This record is the immutable W04 product contract for engineering. It does not certify Core V1. It does not certify W07 or SC-ADM overlay unless separately entitled and tested.
Bound platform decisions: DEC-003, DEC-005, DEC-007, DEC-012, STAB-024, STAB-028.
1. Package boundary¶
- SKU: SC-ASSESS /
PKG-ASSESS-W04 - Installer:
scola_bundle_assessment→scola_cbt - Prerequisites: W00 PASS; W01/W02 assignment/enrollment for
exam_context=learning - Overlay
scola_admission_assessment: separately entitled; not required for base W04 PASS - Gradebook publish (
scola_report_card): optional integration; fail-closed when not installed/entitled
2. Exam state machine¶
Canonical OpenEduCat exam states for CBT: draft, schedule, held, done, cancel.
Allowed transitions (fail closed otherwise):
| From | To | Actor |
|---|---|---|
draft |
schedule, cancel |
exam author/manager |
schedule |
held, done, cancel |
exam author/manager |
held |
done, cancel |
exam author/manager |
cancel |
draft |
exam author/manager only if zero attempts exist |
Forbidden:
done→ any other state (terminal)held→draftorschedule(no exam reopen in V1)- Direct
write({'state': ...})bypassing transition API - Phantom state
result_in_progressin transition logic
Publish requires: CBT question set present; learning context requires participants.
3. Late policy¶
- Runner start denied when
now > exam.end_time - Runner submit denied when
now > exam.end_time(no late-submit-with-flag) - Grace period applies only to in-progress attempt deadline (
duration + grace_minutes, capped by exam end + grace) - Policy
auto_submit_on_timeout: autosubmit when grace exhausted; does not extend exam window for new starts
4. Attempt reopen (proctor)¶
- Proctor may reset attempt
in_progress|submitted→draftbeforeexam.end_time - Requires reason + audit log
- Not allowed from
graded - Exam state reopen (
done/held→ earlier) not allowed in V1
5. Retry¶
- Default
max_attempts = 1 - New attempt allowed only when latest attempt is
submitted|gradedandattempt_number < max_attempts - Field
auto_allow_retakeignored unlessmax_attempts > 1 - Retake does not reset exam timer for other participants; each attempt gets fresh duration from policy
6. Submit idempotency¶
- Second submit on same attempt in
submitted|gradedwith same payload: return success with existing result (no duplicate grade/submission) - Concurrent double-submit: exactly one authoritative submission
7. Result visibility¶
- Student sees score only when attempt is
gradedand (policy.show_score_immediatelyor exam state isdone) - Default policy:
show_score_immediately = false - Parent sees only linked-child results when published per same rule
- Non-participants and early readers see nothing (no existence leak)
8. Roles and capabilities (DEC-003)¶
| Action | Capability |
|---|---|
| Question bank / exam CRUD / publish transition | academics.cbt_exams.manage |
| Proctor console / force-submit / reset | academics.cbt_proctor.manage |
| Manual grading / finalize | academics.cbt_grading.manage |
| Runner start/answer/sync/submit | academics.cbt_exams.sit |
| View results (read) | academics.exam_results.view |
| Publish to gradebook | academics.cbt_grading.manage (not view) |
SoD: author cannot proctor or grade same exam unless explicitly assigned all three roles on that exam record (M2M assignment fields).
9. SC-ADM overlay (XMD)¶
- Base CBT lifecycle works with SC-CORE + SC-ASSESS only
exam_context=admissionrequires SC-ADM entitlement + overlay module when used- Without overlay: admission-context APIs return
feature_disabledor 403 - No duplicate participant/result identity across admission and learning contexts
10. SC-REPORT optional (STAB-024)¶
scola_cbtmust install without harddependsonscola_report_card- Gradebook publish endpoint fail-closed when report card not installed/entitled
- W07 propagation not part of W04 certification
11. Attempt states¶
draft → in_progress → submitted → graded
- Start only from
draft - Submit only from
in_progress - Objective-only exams may auto-transition to
gradedon submit - Essay requires grader finalize
12. Recovery (DEC-005)¶
- Autosave/heartbeat preserves answers during disconnect
- Resume
in_progressattempt reuses same attempt record - Stale session timeout: 5 minutes without heartbeat → treated per policy (warn/autosubmit)
- Operator reconciliation via proctor console; no silent data loss
13. Evidence¶
- Runtime matrix: 11 rows
RT-W04-*PASS on exact FE/BE candidate - Identity bind:
backend_git_commit_sha+application_tree_hashin evidence JSON - Two reproducibility runs before GBN production promotion
Non-goals¶
W07, full SC-ADM overlay cert, complaints, Core V1 TF freeze, entitlement changes on production tenants, Spansa UAT.