Aller au contenu

speechbrainasr-crdnn-rnnlm-librispeech

SpeechBrainASR

Uses the audited SpeechBrain CRDNN/RNNLM decoder with an explicit beam size.

Automatic speech recognitionVoiceHub-nativespeechbrain-crdnn-asrParameters: Not reportedLanguage: enTraining: nativeLicense: Apache-2.0

Parameter metadata: Not reported: the audited metadata available for the registered default does not provide an exact parameter total.

Usage

Complete the VoiceHub installation once, then run this repository-authored example. Model pages intentionally contain no package-install command.

This example is maintained against VoiceHub's public API; it is not copied from an upstream demo or package README.

Model-specific path: Uses the audited SpeechBrain CRDNN/RNNLM decoder with an explicit beam size.

Inputs and controls: The released LibriSpeech graph is English-only and does not expose calibrated timestamps.

from pathlib import Path

from voicehub import AutoModelForSpeechRecognition

AUDIO_FILE = Path("speech.wav")
if not AUDIO_FILE.is_file():
    raise FileNotFoundError(AUDIO_FILE)

model = AutoModelForSpeechRecognition.from_pretrained(
    'speechbrain/asr-crdnn-rnnlm-librispeech',
    model_type='asr_speechbrain',
    device="cuda",
    lazy_load=True,
)
output = model.transcribe(
    AUDIO_FILE,
    language="en",
    num_beams=8,
)
print(output.text)
for segment in output.segments:
    print(segment.start, segment.end, segment.text, segment.confidence)

Use authorized recordings. Verify hardware needs and pin a revision in production.

Overview

asr_speechbrain is a VoiceHub automatic speech recognition integration. This page is generated from its registry contract. Open the asr_speechbrain Colab notebook.

Property Value
Task Automatic speech recognition
Architecture speechbrain-crdnn-asr
Runtime VoiceHub-native
Languages en
Capabilities automatic-speech-recognition, english, beam-search, safetensors, fine-tuning, voicehub-native, crdnn, ctc-seq2seq, rnnlm-shallow-fusion
Reusable components —
Normalized output ASROutput

Language support

Supported language abbreviations

en

Paper and GitHub

Configuration

Load configuration without constructing the model:

from voicehub import AutoConfig

config = AutoConfig.for_model('asr_speechbrain')
print(config.model_type)
Property Value
Canonical model type asr_speechbrain
Configuration class SpeechBrainASRConfig
Architecture class SpeechBrainASRForSpeechRecognition

Processing

Create the registered processor without allocating model weights:

from voicehub import AutoProcessor

processor = AutoProcessor.from_pretrained(
    'speechbrain/asr-crdnn-rnnlm-librispeech',
    model_type='asr_speechbrain',
)
print(type(processor).__name__)

Inference

The Usage example returns ASROutput through AutoModelForSpeechRecognition.

Input and output contract

Property Value
Readiness integrated-raw
Data architecture hybrid-ctc-attention
Sample rate 16,000 Hz
Contract getter get_asr_dataset_spec('asr_speechbrain')
Variant Required fields One of Boundary Other rules
raw-audio — audio / audio_path; text / transcription / transcript Source at most one: audio / audio_path; text / transcription / transcript
speechbrain-model-ready waveforms, waveform_lengths, tokens_bos, tokens_eos, token_lengths, ctc_tokens, ctc_token_lengths — Prepared —

SpeechBrain CRDNN joint CTC/attention fine-tuning records. See the data workflow.

Training and optimization

Use available_optimization_passes() to discover reversible public passes. Unsupported runtime or hardware fails closed before mutation.

Training contract

Property Value
Support native
Family speech-sequence-to-sequence
Recipe single-phase
Default phase speech_recognition
Training checkpoint speechbrain/asr-crdnn-rnnlm-librispeech
Native training graph yes
Phase Kind Components Required inputs Loss keys
speech_recognition objective model waveforms, waveform_lengths, tokens_bos, tokens_eos, token_lengths, ctc_tokens, ctc_token_lengths loss, seq2seq_loss, ctc_loss

The integration accepts its declared source or prepared contract directly. Call model.validate_training_support() first, then follow the training workflow.

Checkpoints, provenance, license, and limitations

Property Value
Default checkpoint speechbrain/asr-crdnn-rnnlm-librispeech
Hugging Face ID speechbrain/asr-crdnn-rnnlm-librispeech
Repository availability verified through the Hugging Face model API on 2026-08-11; pin a revision before production use.
Checkpoint status Registry default; pin an immutable revision for production and reproducible evidence
Optional dependency extra Core package
Hardware and runtime Usage selects cuda; verify checkpoint-specific requirements
Real-checkpoint evidence Release evidence; a registry default alone is not execution evidence
Implementation voicehub.models.asr_native.speechbrain.SpeechBrainASRForSpeechRecognition
Configuration voicehub.models.asr_native.configuration.SpeechBrainASRConfig
Source provenance voicehub/architectures/speechbrain_asr/SOURCE.json
License Apache-2.0

The pinned CRDNN, RNNLM, tokenizer, and source implementation are Apache-2.0. The original pickle files cross a strict one-time conversion boundary; steady-state artifacts are Safetensors. Commercial use: allowed by the registered terms.

Confirm the checkpoint revision, access terms, provenance, and license.

Limitations

  • No integration-specific checkpoint limitation is registered. Verify the selected checkpoint revision and its documented runtime requirements.
  • Validate memory, precision, and optional dependencies on the target system.
  • Public optimizations fail closed when the runtime or hardware cannot satisfy their validation contract; an unavailable pass is not reported as applied.
  • Contract tests do not replace the linked released-checkpoint evidence.

Public API

Use the stable configuration, processor, and task-model facades below.

Configuration

SpeechBrainASRConfig

View source

SpeechBrainASRConfig(**config_kwargs)

Parameters

  • **config_kwargs — Configuration fields validated by SpeechBrainASRConfig.

Model

SpeechBrainASRForSpeechRecognition

View source

AutoModelForSpeechRecognition.from_pretrained(
    pretrained_model_name_or_path,
    *,
    model_type='asr_speechbrain',
    config=None,
    **model_kwargs,
)

Parameters

  • pretrained_model_name_or_path — Hub ID or compatible local directory.
  • model_type — Canonical model type; use 'asr_speechbrain'.
  • config — Optional preloaded SpeechBrainASRConfig instance.
  • **model_kwargs — Model-specific loading arguments.
from voicehub import get_model_spec

spec = get_model_spec('asr_speechbrain')
print(spec.display_name, spec.task.value)
Purpose Public object
Discover get_model_spec('asr_speechbrain')
Load and run AutoModelForSpeechRecognition
Configure SpeechBrainASRConfig
Process AutoProcessor
Model implementation SpeechBrainASRForSpeechRecognition
Normalized output ASROutput
Training contract get_training_spec('asr_speechbrain')
Optimization lifecycle available_optimization_passes, apply_optimization_plan, optimization_manifest, restore_optimization_plan

See all model guides, inference, and the training matrix.