Skip to content

Add live testing backend UI and student registry#34

Open
Rajkoli145 wants to merge 11 commits into
mainfrom
testing_backend_ui
Open

Add live testing backend UI and student registry#34
Rajkoli145 wants to merge 11 commits into
mainfrom
testing_backend_ui

Conversation

@Rajkoli145

Copy link
Copy Markdown
Contributor

No description provided.

Rajkoli145 added 11 commits May 24, 2026 12:52
# Conflicts:
#	backend/src/agents/gatekeeper/agent.py
#	backend/src/agents/gatekeeper/registry/registry_store.py
…9 pydantic models

- IntelligenceArtifact, VivaTarget, VivaSessionState, ExecutionNode, FailureScenario
- ExamSession, ExamSessionState, GatekeeperAdmissionDecision, SessionAuditEvent
- SentinelAlert, IntegritySignalType, EvaluationArtifact, ContradictionChainEntry
- Updated events.py and __init__.py to include new event types
…service

- IntelligenceArtifactBuilder: converts ORACLE StructuredContext to IntelligenceArtifact
- OracleMainHandoffOrchestrator: persists artifact, emits ORACLE_INTELLIGENCE_READY event
- OracleIntelligenceService: combined analysis + handoff in single flow
- ExamSessionService: full exam session lifecycle state machine
  (DRAFT → CONFIGURED → READY → LIVE → ACTIVE_VIVA → COMPLETED → ARCHIVED)
  with gatekeeper precheck, student admission, ORACLE analysis trigger
- Updated main.py with new API routes
- MainAgentVivaOrchestrator: full viva lifecycle
  * Phase progression: INTRODUCTORY → CORE → DEEP_DIVE → CONTRADICTION_PROBE → CLOSING
  * Answer depth scoring: GENERIC / SHALLOW / ADEQUATE / DEEP / EXPERT
  * Adaptive difficulty adjustment based on response quality
  * Contradiction detection across turns
  * Follow-up generation for shallow/generic answers
- VivaPersistenceService: persists turns and session summaries to disk
- RuntimeEventOrchestrator: central event bus for stages 4-9
  * Stage4/5/6/7/8/9 event coordinators
  * Async emit with storage persistence and subscriber callbacks
- VoiceSessionOrchestrator: turn-based TTS → listen → STT flow
- SystemTTSProvider: cross-platform TTS (macOS say, Linux espeak, Windows SAPI)
- MockSTTProvider: deterministic mock for testing
- SilenceDetector: finalizes recording on silence threshold or max duration
- TranscriptNormalizer: corrects common STT errors for technical terms
  (e.g. 'fast api' → 'FastAPI', 'postgres' → 'PostgreSQL', 'jwt' → 'JWT')
- VoiceVivaSession: orchestrates full multi-turn voice viva with MAIN Agent
… engine

Stage 7 - SENTINEL Parallel Oversight:
- SentinelParallelMonitor: deterministic integrity signal detection
  * Gaze offscreen, repeated gaze shifts, session interruptions
  * Suspicious audio patterns, low visibility, confidence instability
  * Contradiction escalation, excessive silence, environment changes
  * Generates SentinelAlert with manual review recommendation

Stage 8 - MAIN Agent Evaluation Loop:
- MainAgentEvaluationLoop: 7-dimension scoring per response
  * Implementation specificity, runtime understanding, operational reasoning
  * Architectural understanding, failure path awareness, tradeoff understanding
  * Consistency score with contradiction penalty
  * Runtime-aware follow-up generation (Redis, DB, JWT, contradiction probes)
  * Builds EvaluationArtifact and ContradictionChain per turn

Stage 9 - Curriculum Engine:
- CurriculumQuestionEngine: manages topic transitions and question sequencing
- test_stages_4_5_6_integration.py: integration tests for ORACLE handoff, viva orchestration, voice pipeline
- test_stages_7_8_9_integration.py: integration tests for SENTINEL, evaluation loop, curriculum engine
- scripts/smoke_main_agent.py: end-to-end smoke test for main agent flow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant