Skip to content

fix: entity grounding, latency bands, STOI sliding-window, null guards, overlap fix, silence threshold#5

Merged
unforkopensource merged 9 commits into
mainfrom
fix/trustworthiness-scan
Jun 22, 2026
Merged

fix: entity grounding, latency bands, STOI sliding-window, null guards, overlap fix, silence threshold#5
unforkopensource merged 9 commits into
mainfrom
fix/trustworthiness-scan

Conversation

@unforkopensource

Copy link
Copy Markdown
Contributor

Summary

Source files (10 modified)

  1. config.py: Added response_gap and turn_gap band tuples to LatencyScoringConfig
  2. orchestrator.py: Both context dicts now pass response_gap_max_ms
  3. compliance.py: Null guard for transcript.text (was crashing on None)
  4. wer.py: Same null guard
  5. hallucination.py: Word-boundary regex (\b) for entity grounding, preventing false matches like "500" inside "1500"
  6. interruption.py: Fixed double-counting in overlap detection (removed + chunk)
  7. stoi.py: Sliding-window FFT (2048 frames, 50% hop) across full audio instead of single window
  8. latency.py: response_gap_avg_ms threshold reads from latency_bands with fallback
  9. score.py: intelligibility_estimate curve fixed (was producing negative scores); response_gap/turn_gap use score_band
  10. silence.py: dead_air_max_ms default changed from 3000 to 1500

Test files (8 modified + 1 new)

  • Added tests for null guards, word-boundary matching, overlap exact values, band-based scoring, silence threshold, and STOI multi-signal estimation

- Fix unsorted imports (I001) in 5 files
- Add missing trailing newlines (W292) in 4 files
- Use ternary expressions instead of if-else (SIM108, SIM201)
- Add missing CallTrace import in orchestrator.py (F821)
- Add noqa for FastAPI File() default arg pattern (B008)
- BaseEvaluator.evaluate: scenario is required (Scenario), not Optional;
  fixes 8 Liskov-substitution violations in wer/mos/latency/interruption/
  hallucination/compliance/stoi/silence evaluators
- Orchestrator.evaluate_trace: skip evaluators when scenario is None
- upload.py: add type annotations (Click ctx) and return type for
  upload_audio and inner _run; use save_call_evaluation(trace, result)
  instead of non-existent save_eval_result
- api/routes/calls.py: replace DecibenchConfig = ... sentinel with
  Depends(get_config) so FastAPI performs proper dependency injection
  and mypy can type-check the parameter

All 341 tests pass, ruff lint/format/mypy clean.
…ow, null guards, overlap fix, silence threshold
@vercel

vercel Bot commented Jun 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
decibench Ready Ready Preview, Comment Jun 13, 2026 6:46pm

@unforkopensource
unforkopensource merged commit 2115925 into main Jun 22, 2026
11 checks passed
@unforkopensource
unforkopensource deleted the fix/trustworthiness-scan branch June 22, 2026 02:37
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