Curator icon indicating copy to clipboard operation
Curator copied to clipboard

Update wer-filtering.md

Open arhamm1 opened this issue 1 year ago • 1 comments

Description

More descriptive title and introduction Properly formatted WER formula with component explanations Step-by-step workflow structure Detailed parameter documentation for all code examples Expanded statistical filtering section with complete workflow Added context for domain-specific thresholds with use cases Complete working pipeline example New best practices section Enhanced related topics

Usage

# Add snippet demonstrating usage

Checklist

  • [x] I am familiar with the Contributing Guide.
  • [x] New or Existing tests cover these changes.
  • [x] The documentation is up to date with these changes.

arhamm1 avatar Nov 19 '25 17:11 arhamm1

Greptile Overview

Greptile Summary

This PR significantly improves the WER filtering documentation by adding comprehensive explanations, structured workflows, and practical examples. The changes transform a basic reference into a complete tutorial guide.

Key improvements:

  • Added detailed WER formula breakdown with component explanations (substitutions, deletions, insertions)
  • Restructured basic filtering into clear Step 1 and Step 2 workflow with parameter documentation
  • Enhanced statistical filtering section with complete workflow and practical tips for analysis
  • Expanded domain-specific sections with rationale for different thresholds (conversational vs broadcast speech)
  • Added complete working pipeline example demonstrating end-to-end WER filtering
  • Introduced new "Best Practices" section with actionable recommendations
  • Enhanced "Related Topics" section with proper cross-references

All code examples reference valid classes and methods from the codebase, and the documentation follows proper markdown formatting conventions.

Confidence Score: 5/5

  • This PR is safe to merge with no risks - documentation-only changes with accurate technical content
  • Documentation enhancements are well-structured, technically accurate, and all referenced classes/methods exist in the codebase. No code changes, no breaking changes, and improves user experience significantly.
  • No files require special attention

Important Files Changed

File Analysis

Filename Score Overview
docs/curate-audio/process-data/quality-assessment/wer-filtering.md 5/5 Enhanced documentation with detailed explanations, complete examples, and best practices

Sequence Diagram

sequenceDiagram
    participant User
    participant Pipeline
    participant CreateManifest as CreateInitialManifestFleursStage
    participant ASRInference as InferenceAsrNemoStage
    participant WERCalc as GetPairwiseWerStage
    participant Filter as PreserveByValueStage
    participant Export as AudioToDocumentStage
    participant Writer as JsonlWriter

    User->>Pipeline: Initialize WER filtering pipeline
    User->>Pipeline: Add CreateInitialManifestFleursStage
    Pipeline->>CreateManifest: Load audio data with ground truth
    CreateManifest-->>Pipeline: Audio manifest with "text" field
    
    User->>Pipeline: Add InferenceAsrNemoStage
    Pipeline->>ASRInference: Generate ASR predictions
    ASRInference-->>Pipeline: Manifest with "pred_text" field
    
    User->>Pipeline: Add GetPairwiseWerStage
    Pipeline->>WERCalc: Calculate WER(text, pred_text)
    WERCalc-->>Pipeline: Manifest with "wer" field
    
    User->>Pipeline: Add PreserveByValueStage
    Pipeline->>Filter: Filter samples (wer ≤ threshold)
    Filter-->>Pipeline: Filtered manifest (high-quality samples)
    
    User->>Pipeline: Add export stages
    Pipeline->>Export: Convert to document format
    Export->>Writer: Write filtered results
    Writer-->>Pipeline: Output to ./filtered_audio
    
    User->>Pipeline: Execute pipeline
    Pipeline-->>User: Filtered audio dataset

greptile-apps avatar Nov 19 '25 17:11 greptile-apps