Leanpub Header

Skip to main content

Building Automatic Speech Recognition Applications from the Ground Up

A Production Guide to Voice Activity Detection, Model Selection, and Real-Time Inference

This book is 100% completeLast updated on 2026-07-13

This practical guide shows you how to build production-ready speech recognition applications from the ground up. Learn how to use Voice Activity Detection, choose the right ASR models, build real-time inference pipelines, and deploy scalable systems with hands-on examples and modern open-source tools.

Minimum price

$19.00

$29.00

You pay

Author earns

$

Also available for 1 book credit with a Reader Membership

PDF
EPUB
128
Pages
About

About

About the Book

This book is a comprehensive, production-focused guide to building Automatic Speech Recognition (ASR) applications from the ground up. It covers the complete signal chain, with deep emphasis on Voice Activity Detection as the critical pre-processing step that determines what the ASR model actually sees. You will learn how to select and fine-tune state-of-the-art open-source models, design streaming and batch inference pipelines, deploy to production at scale, and continuously benchmark quality. Every chapter includes practical code examples, implementation walkthroughs, and references to leading open-source frameworks like Whisper, Vosk, ESPnet, SpeechBrain, and more. Whether you are building a voice assistant, a live captioning service, or a medical transcription pipeline, this book gives you the architectural knowledge and engineering judgment needed to ship a robust ASR system.

Bundle

Bundles that include this book

Author

About the Author

Steve Publications

Steve is a technology professional with more than 20 years of experience in software development, server infrastructure, cybersecurity, vulnerability research and reverse engineering. Throughout his career, he has designed, secured, analyzed and tested complex software and infrastructure, with a particular focus on understanding how systems fail and how they can be made more secure.

Outside of work, Steve enjoys sharing knowledge with the technology community. He collaborates with researchers, industry experts and technology professionals to write practical books covering software development, cybersecurity, cloud computing, networking, DevOps, artificial intelligence and enterprise technologies. His books focus on practical learning through clear explanations, real-world examples and hands-on exercises. With more than two decades of industry experience, his goal is to help IT professionals, students and technology enthusiasts build useful skills and stay current in a rapidly changing industry.

We believe readers deserve to know how our books are created. Most of our authors are not native English speakers, so we use AI to help translate, proofread manuscripts, fix grammar, improve sentence structure and make technical explanations easier to read. AI is used as an editing tool only. It does not replace the research, technical knowledge or hands-on experience behind our books. Some of our authors also prefer to remain anonymous for privacy or professional reasons. In those cases, we publish their work under a different name. The author's name may be different, but the quality of the content and our review process remain the same.

Every book is written, reviewed and maintained by experienced technology professionals, with contributions from our private technical community of more than 400 engineers and researchers from Ukraine, Belarus and Russia. We spend far more time validating technical accuracy and keeping our content up to date than generating text. We are always interested in working with experienced professionals who have deep expertise in a particular technology or domain. If you would like to publish a book with us or help review an existing manuscript, we'd love to hear from you. Send us a message describing your area of expertise. We are especially interested in niche technologies, specialized skills and emerging topics that are underrepresented in existing technical literature.

If you look through the contents of our books, you'll see practical examples, detailed explanations and material that is regularly updated. Our goal is to publish books that professionals can actually rely on, not low-effort AI-generated content. If you ever feel that one of our books does not meet that standard, Leanpub offers a 60-day money-back guarantee. Feel free to request a refund if you are not satisfied with your purchase.

Contents

Table of Contents

A Production Guide to Voice Activity Detection, Model Selection, and Real-Time Inference

Introduction: The Sound of Machines

Chapter 1: The ASR Landscape From DTMF to Transformers

  1. A Brief History of Speech Recognition
  2. The Transformer Revolution in ASR
  3. The Open-Source ASR Ecosystem
  4. When to Use What: A Decision Narrative
  5. Key Metrics That Matter
  6. When to Use What
  7. Key Metrics That Matter

Chapter 2: The Signal Chain Audio Preprocessing Fundamentals

  1. Digital Audio Basics
  2. Noise Reduction and Denoising
  3. Normalization, Gain Control, and Loudness Standards
  4. Feature Extraction: From Waveforms to Model Inputs
  5. Tokenization: The Bridge Between Audio and Text
  6. Normalization, Gain Control, and Loudness Standards
  7. Feature Extraction: From Waveforms to Model Inputs
  8. Tokenization: The Bridge Between Audio and Text

Chapter 3: Voice Activity Detection The Gatekeeper

  1. What VAD Does and Why It Matters
  2. Rule-Based VAD: Energy, Zero-Crossing, and CMU Sphinx
  3. Statistical VAD: Gaussian Mixture Models and HMMs
  4. Neural VAD: WebRTC, Silero, and Pyannote
  5. VAD Evaluation: DRD, F1, and ROC Curves
  6. Threshold Tuning and Post-Processing
  7. Handling Edge Cases
  8. VAD Debugging: Common Failure Modes and Fixes
  9. VAD Threshold Tuning: A Mathematical Intuition
  10. VAD in Practice: Choosing the Right Tool

Chapter 4: End-to-End ASR Architectures

  1. Connectionist Temporal Classification (CTC)
  2. Attention-Based Encoder-Decoder (AED)
  3. The Recurrent Neural Network Transducer (RNN-T)
  4. The Conformer Architecture
  5. Whisper’s Architecture: A Simplified Encoder-Decoder
  6. Whisper’s Architecture: A Simplified Encoder-Decoder
  7. Streaming vs. Non-Streaming Architectures
  8. Tokenization Deep Dive
  9. Architecture Comparison Summary

Chapter 5: Data Pipelines Fueling the Engine

  1. Public Speech Corpora
  2. Data Augmentation Techniques
  3. Transcript Cleaning and Normalization
  4. Quality Assurance and Filtering
  5. Synthetic Data Generation
  6. Data Quality Metrics and Filtering
  7. Data Versioning and Reproducibility
  8. Data Versioning and Reproducibility

Chapter 6: Model Selection and Fine-Tuning

  1. The Model Zoo: Choosing Your Base
  2. Fine-Tuning Strategies for ASR: A Deep Dive
  3. Quantization and Pruning for Efficiency: A Deeper Look
  4. Benchmarking Models: Methodology and Caveats
  5. Fine-Tuning Strategies for ASR
  6. Domain Adaptation: Medical, Legal, Technical
  7. Quantization and Pruning for Efficiency
  8. Benchmarking Models

Chapter 7: Streaming and Real-Time ASR

  1. The Challenge of Real-Time Speech Recognition
  2. Streaming ASR Fundamentals
  3. Chunked Processing with Whisper
  4. Stateful Inference and Buffer Management
  5. Real-Time Architecture Patterns
  6. Latency Budgeting
  7. End-to-End Streaming Server Walkthrough
  8. Real-Time Architecture Patterns

Chapter 8: Batch Inference and Throughput Optimization

  1. The Throughput Challenge
  2. Batching Strategies
  3. Parallel Processing and GPU Utilization
  4. Throughput Benchmarks
  5. Cost Analysis
  6. Throughput Optimization: Beyond Batching

Chapter 9: Deployment From Notebook to Production

  1. Serving Architectures
  2. Containerization and Orchestration
  3. Model Serving Frameworks
  4. Edge Deployment
  5. Horizontal Scaling Strategies for ASR Pipelines
  6. Observability with Prometheus and Grafana
  7. PII Detection and Redaction in Production
  8. Deployment Architecture Summary

Chapter 10: Multilingual and Cross-Lingual ASR

  1. Multilingual Model Architectures
  2. Language Identification
  3. Code-Switching and Mixed-Language Audio
  4. Accent Normalization and Dialect Handling
  5. Low-Resource Language Strategies
  6. Evaluation Across Languages
  7. Accent Normalization and Dialect Handling
  8. Low-Resource Language Strategies
  9. Evaluation Across Languages

Chapter 11: Testing, Benchmarking, and Quality Assurance

  1. Building Test Sets: A Production Strategy
  2. Adversarial Testing: A Practical Framework
  3. Continuous Evaluation Pipelines
  4. Human-in-the-Loop Quality Assurance
  5. WER and CER Analysis: Beyond the Aggregate Number
  6. Latency Benchmarking
  7. Robustness Testing
  8. WER and CER Analysis
  9. Latency Benchmarking
  10. Robustness Testing
  11. Continuous Evaluation Pipelines
  12. Human-in-the-Loop Quality Assurance

Chapter 12: Production Best Practices and Future Directions

  1. The Production ASR Checklist: A Narrative Guide
  2. Cost Optimization Strategies
  3. PII and Privacy in Speech Data
  4. Build vs. Buy
  5. Emerging Trends
  6. Lessons Learned: Engineering Judgment Over Benchmark Chasing
  7. Lessons Learned

Conclusion

References

Get the free sample chapters

Click the buttons to get the free sample in PDF or EPUB, or read the sample online here

The Leanpub 60 Day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

See full terms...

Earn $8 on a $10 Purchase, and $16 on a $20 Purchase

We pay 80% royalties on purchases of $7.99 or more, and 80% royalties minus a 50 cent flat fee on purchases between $0.99 and $7.98. You earn $8 on a $10 sale, and $16 on a $20 sale. So, if we sell 5000 non-refunded copies of your book for $20, you'll earn $80,000.

(Yes, some authors have already earned much more than that on Leanpub.)

In fact, authors have earned over $15 million writing, publishing and selling on Leanpub.

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub