Scope. This flowmap captures the per-turn quality layer (the new AI call that didn't exist in the old flat-prompt design) and the reclassification subflow that fires when contradictions warrant a visible swap. The reclassification check node in the master flowmap (discovery-architecture.html, per-turn loop phase) is the upstream entry point; this flowmap zooms in on its mechanics.
Conversation-depth-aligned reclassification. Reclassification fires at conversation depth ~turns 2-3 across all modes. Triggered by either content-driven contradictions (mode contradiction once anchor / claim / recipient lands) or the turn-count sanity gate (turns 2-3 regardless of beat state). Both surface via the reflective offer; first to fire wins. See narrative-skeleton.html, transactional-skeleton.html, and analytical-skeleton.html for per-mode trigger conditions.
Door classification as hypothesis. The doorHypothesisFlag on Project tracks whether the OpenerService classification is still tentative. Set true at door-cross; cleared after the reclassification check confirms (writer accepts the door classification or amends it explicitly) OR after the turn-2-3 sanity gate passes without contradictions surfacing. While the flag is true, the quality layer runs a heightened check on each turn looking for the sanity-gate trigger.
Folded response parsing. The writer's response to a reflective offer (confirm/amend/reject) is parsed implicitly by the next per-turn quality layer call — no separate parse-only AI call. The quality layer reads pendingProposal alongside the writer's latest turn and classifies the response. Saves a call; works because the parsing is itself a contradiction-detection task (does the writer's latest turn agree with the proposed swap?).
Resolved this pass : (1) ruledOutHypotheses lives on MentorContext — session-scoped, persists across app restarts within the project; manual steering is the v1 escape hatch if the writer wants to revisit a rejection. (2) Reset semantics on amend: mode change resets all beats (the new skeleton's beats are different; quality layer re-mines from priorTurns); type-within-mode change keeps beats and retunes layer-specific tuning only. (3) Term-contradiction stays a sub-check within analytical Beats 1-2 — not a 5th axis on the cross-cutting quality layer (avoids coupling the cross-mode quality layer to a mode-specific concern).
Open question retained for prompt design : whether response-parsing fold-in (parsing confirm/amend/reject in the next quality layer call rather than a dedicated parse call) works under prompt-design load. Try fold-in first; fall back to dedicated parse call if confirm/amend/reject classification accuracy proves unreliable.
Source files referenced (current implementations being replaced or extended): Atticus/Rooms/Concept/DiscoveryConversationService.swift, Atticus/Rooms/Concept/OpenerService.swift, Atticus/Rooms/Concept/DiscoveryStreamParser.swift, Atticus/Models/Project.swift. Spin-off references : discovery-architecture.html (master), reflective-offer.md (beat primitive), narrative-skeleton.html, transactional-skeleton.html, analytical-skeleton.html.
Code Raven analog for the per-turn quality layer prompt: CodeRaven/Code Raven/Services/Ideation/IdeationPromptLibrary.swift:509 (depthProbePrompt). Atticus's quality layer has wider scope — CR's only probes for surface depth; this also detects mode/type/objective contradictions and tracks satisfaction across multiple beats per turn.