ElBruno.Speech.Pipeline
0.5.4
dotnet add package ElBruno.Speech.Pipeline --version 0.5.4
NuGet\Install-Package ElBruno.Speech.Pipeline -Version 0.5.4
<PackageReference Include="ElBruno.Speech.Pipeline" Version="0.5.4" />
<PackageVersion Include="ElBruno.Speech.Pipeline" Version="0.5.4" />
<PackageReference Include="ElBruno.Speech.Pipeline" />
paket add ElBruno.Speech.Pipeline --version 0.5.4
#r "nuget: ElBruno.Speech.Pipeline, 0.5.4"
#:package ElBruno.Speech.Pipeline@0.5.4
#addin nuget:?package=ElBruno.Speech.Pipeline&version=0.5.4
#tool nuget:?package=ElBruno.Speech.Pipeline&version=0.5.4
ElBruno.Speech
Local-first speech runtime for .NET — VAD → STT → LLM → TTS 🎙️
A reusable, local-first speech runtime for .NET 8 and .NET 10. Built on Microsoft.Extensions.AI provider boundaries — works with local models (Whisper, VibeVoice, Qwen-TTS, Ollama) and cloud providers (Azure OpenAI, OpenAI) without changing orchestration code.
Audio input
↓
Audio normalization · resampling · framing · buffering
↓
Voice Activity Detection (Silero VAD)
↓
Turn detection · utterance assembly
↓
ISpeechToTextClient
↓
IChatClient
↓
Streaming text segmentation
↓
ITextToSpeechClient
↓
Audio output
Packages
Installation
dotnet add package ElBruno.Speech.Pipeline
dotnet add package ElBruno.Speech.Vad.Silero
Install the CLI tool globally:
dotnet tool install -g ElBruno.Speech.Cli
elbrunospeech --help
Quick Start
// Register providers
services.AddWhisper(o => o.Model = KnownWhisperModels.WhisperBaseEn);
services.AddLocalLLMs(o => o.Model = KnownModels.Phi35MiniInstruct);
services.AddVibeVoiceTTS(o => o.SampleRate = 24_000);
services.AddSileroVad(o => o.MinimumSilenceDuration = TimeSpan.FromMilliseconds(500));
// Build the pipeline
services.AddSpeechPipeline(builder =>
{
builder
.UseVoiceActivityDetector<SileroVoiceActivityDetector>()
.UseSpeechToText(sp => sp.GetRequiredService<ISpeechToTextClient>())
.UseChatClient(sp => sp.GetRequiredService<IChatClient>())
.UseTextToSpeech(sp => sp.GetRequiredService<ITextToSpeechClient>())
.UseSentenceChunking(o =>
{
o.MinimumCharacters = 24;
o.MaximumCharacters = 220;
o.FlushTimeout = TimeSpan.FromMilliseconds(350);
})
.UseBargeIn(o => o.CancelOnSpeechStart = true);
});
// Use it
var pipeline = sp.GetRequiredService<ISpeechPipeline>();
await using var session = await pipeline.CreateSessionAsync();
await session.WriteAudioAsync(frame);
await foreach (var update in session.GetUpdatesAsync())
{
// SpeechStartedUpdate, FinalTranscriptUpdate, AssistantAudioChunkUpdate, ...
}
CLI Tool
elbrunospeech devices # list audio input/output devices
elbrunospeech transcribe recording.wav # transcribe a WAV file
elbrunospeech vad recording.wav # run voice activity detection
elbrunospeech talk "Hello world" out.wav # synthesize text to WAV
Observability
builder.Services.AddOpenTelemetry()
.AddSpeechPipelineTelemetry(); // meter: ElBruno.Speech, source: ElBruno.Speech
// Aspire automatically configures OTLP export via OTEL_EXPORTER_OTLP_ENDPOINT
Samples
| Sample | Description |
|---|---|
FileToSpeech |
WAV file → transcript → answer → WAV output |
LocalVoiceAgent |
Microphone → VAD → Whisper → LLM → VibeVoice → speaker (barge-in) |
WebSocketVoiceAgent |
ASP.NET Core WebSocket endpoint + browser client |
AspireVoiceAgent |
Full Aspire AppHost with tracing, metrics, and dashboard |
Related Repositories
- ElBruno.Whisper —
ISpeechToTextClientvia ONNX Whisper - ElBruno.LocalLLMs —
IChatClientfor local LLMs - ElBruno.VibeVoiceTTS —
ITextToSpeechClientvia VibeVoice - ElBruno.QwenTTS —
ITextToSpeechClientvia Qwen3-TTS - ElBruno.HuggingFace.Downloader — model downloads
Requirements
- .NET 8.0 or .NET 10.0
- Windows, Linux, or macOS
- NAudio package requires Windows (microphone/speaker I/O)
Building from Source
git clone https://github.com/elbruno/ElBruno.Speech.git
cd ElBruno.Speech
dotnet restore
dotnet build
dotnet test --filter "Category!=Integration"
📄 License
MIT — see LICENSE.
👋 About the Author
Hi! I'm ElBruno 🧡, a passionate developer and content creator exploring AI, .NET, and modern development practices.
Made with ❤️ by ElBruno
If you like this project, consider following my work across platforms:
- 📻 Podcast: No Tienen Nombre — Spanish-language episodes on AI, development, and tech culture
- 💻 Blog: ElBruno.com — Deep dives on embeddings, RAG, .NET, and local AI
- 📺 YouTube: youtube.com/elbruno — Demos, tutorials, and live coding
- 🔗 LinkedIn: @elbruno — Professional updates and insights
- 𝕏 Twitter: @elbruno — Quick tips, releases, and tech news
🙏 Acknowledgments
- Microsoft.Extensions.AI — ISpeechToTextClient, IChatClient, ITextToSpeechClient interfaces
- Silero VAD — voice activity detection model
- ONNX Runtime — local model inference
- NAudio — Windows audio I/O
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- ElBruno.Speech.Abstractions (>= 0.5.4)
- ElBruno.Speech.Audio (>= 0.5.4)
- Microsoft.Extensions.AI (>= 10.8.0)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.10)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.9)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.10)
- Microsoft.Extensions.Options (>= 10.0.10)
-
net8.0
- ElBruno.Speech.Abstractions (>= 0.5.4)
- ElBruno.Speech.Audio (>= 0.5.4)
- Microsoft.Extensions.AI (>= 10.8.0)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.10)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.9)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.10)
- Microsoft.Extensions.Options (>= 10.0.10)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on ElBruno.Speech.Pipeline:
| Package | Downloads |
|---|---|
|
ElBruno.Speech.AspNetCore
ASP.NET Core integration for ElBruno.Speech — WebSocket endpoint, session registry, health checks, and protocol handling. |
|
|
ElBruno.Speech.OpenTelemetry
OpenTelemetry instrumentation for ElBruno.Speech — activities, metrics, and Aspire-compatible setup. |
GitHub repositories
This package is not used by any popular GitHub repositories.