Files
rag-technical-docs-assistant/docs/evaluation/openai-persian-speech-baseline.json

421 lines
15 KiB
JSON

{
"report_id": "openai-persian-speech-phase1-20261011",
"date": "2026-10-11",
"implementation_status": "implemented",
"acceptance_status": "not_run",
"phase_closed": false,
"scope": "Phase 1 only, main app.server path",
"manifest_id": "openai-persian-speech-v1",
"recordings_supplied": 0,
"human_labels_supplied": 0,
"provider_evaluation": {
"status": "not_run",
"authorization": null,
"sessions": 0,
"audio_seconds": 0,
"tool_calls": 0,
"embedding_calls": 0,
"spend": 0
},
"deployment_observation": {
"status": "passed",
"method": "Read-only docker exec of VoiceSettings and adapter setup in existing rag-api; allowlisted values only",
"provider": "openai",
"model": "gpt-realtime-mini",
"voice": "shimmer",
"voice_transport_testing": true,
"calibration_report_configured": false,
"adapter_requested_audio_input": {
"format": {
"type": "audio/pcm",
"rate": 24000
},
"transcription": {
"model": "whisper-1",
"language": "fa"
},
"turn_detection": {
"type": "server_vad",
"create_response": false,
"interrupt_response": false
}
},
"provider_effective_audio_input": null,
"provider_acknowledgment_observed": false,
"new_code_deployed": false,
"hardware_frontend_observed": false
},
"local_observation": {
"status": "passed",
"method": "VoiceSettings from local environment after implementation, allowlisted values only",
"provider": "openai",
"model": "gpt-realtime-mini",
"voice": "shimmer",
"voice_transport_testing": true,
"calibration_report_configured": false,
"requested_audio_input": {
"format": {
"type": "audio/pcm",
"rate": 24000
},
"transcription": {
"model": "whisper-1",
"language": "fa"
},
"turn_detection": {
"type": "server_vad",
"create_response": false,
"interrupt_response": false,
"threshold": 0.5,
"prefix_padding_ms": 300,
"silence_duration_ms": 500
},
"noise_reduction": null
}
},
"official_schema": {
"status": "passed",
"checked_date": "2026-10-11",
"gpt_transcribe_committed_websocket": true,
"languages": [
"fa",
"en"
],
"keywords_supported": true,
"sources": [
"https://developers.openai.com/api/docs/guides/realtime-transcription",
"https://developers.openai.com/api/reference/resources/realtime/client-events",
"https://developers.openai.com/api/docs/deprecations"
],
"baseline_shutdown_dates": {
"gpt-realtime-mini": "2027-01-20",
"whisper-1": "2027-02-26"
}
},
"profiles": [
{
"profile_id": "baseline",
"configuration_status": "prepared_not_evaluated",
"voice_profile_without_search": {
"provider": "openai",
"model": "gpt-realtime-mini",
"voice": "shimmer",
"input_sample_rate": 24000,
"output_sample_rate": 24000,
"audio_input": {
"format": {
"type": "audio/pcm",
"rate": 24000
},
"transcription": {
"model": "whisper-1",
"language": "fa"
},
"turn_detection": {
"type": "server_vad",
"create_response": false,
"interrupt_response": false,
"threshold": 0.5,
"prefix_padding_ms": 300,
"silence_duration_ms": 500
},
"noise_reduction": null
}
},
"voice_profile_without_search_sha256": "9410d136e1b9a0f4f5997a3fba78f0ba40a9586237affab72bfa0dfae5b75f38",
"measured_full_execution_profile": null,
"measured_full_execution_profile_sha256": null,
"provider_acknowledgment_status": "not_run",
"wer": {
"quiet": null,
"office": null,
"moderate_noise": null
},
"critical_errors": null,
"empty_transcripts": null,
"segmentation_errors": null,
"truncated_transcripts": null,
"completion_delay_ms": {
"p50": null,
"p95": null
},
"response_latency_ms": {
"p50": null,
"p95": null
},
"usage": null,
"cost": null
},
{
"profile_id": "asr-candidate",
"configuration_status": "prepared_not_evaluated",
"voice_profile_without_search": {
"provider": "openai",
"model": "gpt-realtime-mini",
"voice": "shimmer",
"input_sample_rate": 24000,
"output_sample_rate": 24000,
"audio_input": {
"format": {
"type": "audio/pcm",
"rate": 24000
},
"transcription": {
"model": "gpt-transcribe",
"languages": [
"fa",
"en"
],
"prompt": "Iranian Persian technical support with English terminology.",
"keywords": [
"PCM16LE",
"API"
]
},
"turn_detection": {
"type": "server_vad",
"create_response": false,
"interrupt_response": false,
"threshold": 0.5,
"prefix_padding_ms": 300,
"silence_duration_ms": 500
},
"noise_reduction": null
}
},
"voice_profile_without_search_sha256": "d570b5051c3a1c8a434408ab2d78c0e65bc44e8386d804d2d82dbe1dceac167b",
"measured_full_execution_profile": null,
"measured_full_execution_profile_sha256": null,
"provider_acknowledgment_status": "not_run",
"wer": {
"quiet": null,
"office": null,
"moderate_noise": null
},
"critical_errors": null,
"empty_transcripts": null,
"segmentation_errors": null,
"truncated_transcripts": null,
"completion_delay_ms": {
"p50": null,
"p95": null
},
"response_latency_ms": {
"p50": null,
"p95": null
},
"usage": null,
"cost": null
}
],
"comparisons": [
{
"dimension": "ASR",
"profiles": [
"baseline",
"asr-candidate"
],
"status": "not_run"
},
{
"dimension": "VAD silence 500 versus 800 ms",
"profiles": [],
"status": "not_run"
},
{
"dimension": "Device-specific noise reduction",
"profiles": [],
"status": "not_run"
}
],
"failure_categories": [
{
"category": "capture",
"status": "not_run",
"observed_failures": null
},
{
"category": "assembly",
"status": "not_run",
"observed_failures": null
},
{
"category": "ASR",
"status": "not_run",
"observed_failures": null
},
{
"category": "segmentation",
"status": "not_run",
"observed_failures": null
},
{
"category": "direct_audio_understanding",
"status": "not_run",
"observed_failures": null
}
],
"acceptance_gates": {
"held_out_wer": "not_run",
"quiet_office_critical_facts": "not_run",
"actual_frontend_transcript_reconciliation": "not_run",
"actual_pcm_capture_playback": "not_run",
"natural_pauses": "not_run",
"latency_comparison": "not_run"
},
"checks": [
{
"command": ".venv/Scripts/python -m pytest tests/unit/test_phase2_provider_selection.py tests/unit/test_realtime_phase1.py -q -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 81,
"seconds": 28.07
},
{
"command": ".venv/Scripts/python -m pytest tests/unit/test_speech_scorer.py tests/unit/test_openai_speech_configuration.py -q -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 37,
"seconds": 2.86,
"note": "Before two final acknowledgment/malformed-event regressions; full suite includes final files"
},
{
"command": ".venv/Scripts/python -m pytest tests/integration/test_openai_speech_profile.py -m postgres --require-postgres -q -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 8,
"seconds": 55.17
},
{
"command": ".venv/Scripts/python -m pytest -m \"not postgres\" -q -p no:cacheprovider --tb=short",
"status": "failed",
"note": "Existing 50-ms search runner deadline failed; nested ordinary-suite regression also failed from search deadline and 103.80-ms JSON heartbeat gap against 100 ms. Concurrent PostgreSQL run; no causal attribution established. Retest pending.",
"passed": 1871,
"failed": 2,
"skipped": 3,
"deselected": 423,
"seconds": 418.08
},
{
"command": ".venv/Scripts/python -m pytest -m postgres --require-postgres -q -p no:cacheprovider --tb=short",
"status": "failed",
"note": "Interrupted after a reported failure and several minutes without further results, beyond 68 percent progress. Test database sessions were idle; no traceback was available after tool interruption. Full 423-case acceptance is not established; no causal attribution.",
"completed": false,
"reported_failures_at_least": 1
},
{
"command": "git diff --check",
"status": "passed"
},
{
"command": ".venv/Scripts/python -m pytest tests/unit/test_openai_speech_configuration.py tests/unit/test_speech_scorer.py tests/unit/test_phase2_provider_selection.py tests/unit/test_search_phase3.py tests/unit/test_json_processing.py -q -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 111,
"seconds": 28.66,
"note": "Includes focused retest of initial timing-sensitive failures"
},
{
"command": ".venv/Scripts/python -m pytest tests/unit/test_openai_speech_configuration.py tests/unit/test_speech_scorer.py tests/unit/test_realtime_phase1.py tests/unit/test_realtime_repairs.py tests/unit/test_realtime_remaining.py tests/unit/test_live_context_sync.py tests/unit/test_voice_input_accounting.py tests/unit/test_phase2_provider_selection.py tests/unit/test_voice_client_example.py -q -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 361,
"seconds": 100.0,
"note": "Final implementation including unexpected provider guidance rejection"
},
{
"command": ".venv/Scripts/python -m app.score_speech --help",
"status": "passed"
},
{
"command": "New-file whitespace / ast.parse / json.loads / relative handoff links inspection",
"status": "passed"
},
{
"command": "Offline scorer against empty supplied templates",
"status": "passed",
"note": "Correctly rejected missing effective-profile digest; no quality score claimed"
},
{
"command": ".venv/Scripts/python -m pytest -m \"not postgres\" -q -p no:cacheprovider --tb=short",
"attempt": 2,
"status": "failed",
"passed": 1871,
"failed": 2,
"skipped": 3,
"deselected": 423,
"seconds": 474.64,
"note": "JSON responsiveness 148.52 ms versus 100 ms; nested suite failed JSON responsiveness 215.70 ms and existing GeminiVision blocked-read deadline. Concurrent task suites ran; no cause established. Final acknowledgment follow-up validated separately."
},
{
"command": ".venv/Scripts/python -m pytest tests/integration/test_openai_speech_profile.py tests/integration/test_phase2_postgres.py tests/integration/test_voice_session_incident.py tests/integration/test_realtime_phase3_http.py::test_authenticated_selection_removal_closes_active_voice_and_redacts_polling -m postgres --require-postgres -x -vv -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 82,
"skipped": 0,
"seconds": 361.58,
"note": "Final affected PostgreSQL acceptance, without another task test suite running"
},
{
"command": "docker rm -f -v <verified task-owned container ID>",
"status": "passed",
"note": "Only rag-speech-phase1-20261011-test and its anonymous test storage removed"
},
{
"command": ".venv/Scripts/python -m pytest -m \"not postgres\" -q -p no:cacheprovider --tb=short",
"attempt": 3,
"status": "failed",
"passed": 1874,
"failed": 1,
"skipped": 3,
"deselected": 423,
"seconds": 362.63,
"note": "Final code, no concurrent task test suite. Existing GeminiVision extraction test test_transport_capacity_survives_timeout_and_recovers_without_late_results[False] failed because its mock opener was not entered within the 0.1-second deadline. Nested full-suite driver passed. No causal attribution."
},
{
"command": ".venv/Scripts/python -m pytest tests/unit/test_phase3_context_repairs.py::test_transport_capacity_survives_timeout_and_recovers_without_late_results -q -p no:cacheprovider --tb=short",
"status": "passed",
"passed": 2,
"seconds": 1.34,
"note": "Final broader failure isolated; both parameter variants passed without changing code or assertions."
}
],
"database_isolation": {
"container": "rag-speech-phase1-20261011-test",
"port": 55441,
"database": "rag_speech_phase1_test",
"schemas": "Disposable per-test schemas; test_vector namespace; no operational database access",
"cleanup_status": "passed"
},
"frontend_handoff": "docs/guides/openai-persian-speech-phase1.md",
"unrun_prerequisites": [
"Approved real recordings from at least three native Iranian Persian speakers",
"Native human reference annotations and critical fact designations",
"Explicit bounded real-provider evaluation authorization",
"Actual production frontend workspace, developer signoff and browser/hardware evidence",
"Deployed source update and real provider acknowledgment of new settings",
"Unqualified full PostgreSQL acceptance and resolution of broader ordinary-suite timing failures"
],
"affected_files": [
".env.example",
"app/modules/voice/configuration.py",
"app/infrastructure/voice_provider.py",
"app/infrastructure/realtime.py",
"app/modules/voice/runtime.py",
"app/score_speech.py",
"examples/voice-transcripts.js",
"tests/unit/test_openai_speech_configuration.py",
"tests/unit/test_speech_scorer.py",
"tests/support/voice_transcripts.mjs",
"tests/integration/test_openai_speech_profile.py",
"docs/guides/openai-persian-speech-phase1.md",
"docs/evaluation/openai-persian-speech-manifest.json",
"docs/evaluation/openai-persian-speech-annotations.json",
"docs/evaluation/openai-persian-speech-observations.template.json",
"docs/evaluation/openai-persian-speech-baseline.json",
"docs/agent-reference-map.md",
"docs/specifications/RAG-Phase1-API-Catalog.md"
],
"preserved_files": [
"docs/plans/openai-realtime-persian-quality-plan.md (pre-existing untracked user plan)",
"scripts/live_voice_server.py",
"all applied migrations",
"Gemini adapter and shared POLICY"
],
"validation_status": "affected_checks_passed_broader_acceptance_incomplete"
}