Darkspyre.Inference.Connect
11.20.0
Prefix Reserved
dotnet add package Darkspyre.Inference.Connect --version 11.20.0
NuGet\Install-Package Darkspyre.Inference.Connect -Version 11.20.0
<PackageReference Include="Darkspyre.Inference.Connect" Version="11.20.0" />
<PackageVersion Include="Darkspyre.Inference.Connect" Version="11.20.0" />
<PackageReference Include="Darkspyre.Inference.Connect" />
paket add Darkspyre.Inference.Connect --version 11.20.0
#r "nuget: Darkspyre.Inference.Connect, 11.20.0"
#:package Darkspyre.Inference.Connect@11.20.0
#addin nuget:?package=Darkspyre.Inference.Connect&version=11.20.0
#tool nuget:?package=Darkspyre.Inference.Connect&version=11.20.0
Darkspyre.Inference.Connect
Image, speech and audio connectors for .NET applications: image generation through a ComfyUI server, speech through a PocketTTS server and sound generation through a TangoFlux server. Each connector calls a server the application names; it never starts the server, installs models or plays audio.
Install
dotnet add package Darkspyre.Inference.Connect --prerelease
Register
services.AddImageConnect();
services.AddTtsConnect();
services.AddAudioConnect();
Each call registers one capability's provider service: ImageProviderService, TtsProviderService and
AudioProviderService. Register only the ones the application uses.
Example
TtsProviderService ttsProviders = serviceProvider.GetRequiredService<TtsProviderService>();
await using ITtsClient speech = ttsProviders.Bind(new TtsConnection
{
Endpoint = new Uri("http://127.0.0.1:8020"),
PocketTts = new PocketTtsEndpointOptions { Protocol = PocketTtsProtocol.Multipart }
});
IReadOnlyList<TtsVoice> voices = await speech.ListVoicesAsync(cancellationToken);
TtsResult clip = await speech.SpeakAsync(new TtsRequest
{
Text = "The next room is quiet.",
VoiceId = voices[0].Id,
Format = TtsAudioFormat.Wav
}, cancellationToken);
AudioProviderService.Bind(new AudioConnection { Endpoint = ... }) returns an IAudioGenerationClient the same way.
ImageProviderService.GetRequiredTransport(ImageTransport.ComfyUi) returns the ComfyUI transport, which uploads
reference images, prepares a workflow request, submits it and reads the job.
Settings
Each provider service exposes SetupDefinitions and CreateSettingsManager, which open the connection's typed
settings for the shared setup editor:
- PocketTTS: endpoint, timeout, protocol, paths, protected headers, voice and speech defaults.
- TangoFlux: endpoint, timeout, generation path, protected headers, duration, steps, guidance, seed and the provider-cache choice.
Save makes no network request. Voice checks, test synthesis and test generation are separate actions.
Limits
- PocketTTS returns WAV only. TangoFlux accepts durations of 1 to 30 seconds, 10 to 100 steps and guidance from 0.1 to 20; a value outside these ranges fails before any request.
- TangoFlux has no model list or health check: its test sends a real generation request.
- Speech and audio requests are never retried automatically, and their errors carry no prompts, protected headers or raw server responses.
- The speech and audio registrations turn off automatic redirects, so protected headers never follow a redirect to another origin.
- The application owns connection storage, credentials, workflow storage, job scheduling and media storage.
The Darkspyre.Inference packages
This package is one library of the Darkspyre.Inference family. The family runs AI inference from .NET applications through typed, provider-neutral contracts.
Darkspyre.Inference.Commonholds the contracts every other package shares: requests, results, capabilities, failures and the provider setup model.Darkspyre.Inference.Connect.Commonholds the conversation and embedding services. Each Connect provider package adds one provider, andAddLlmConnect()discovers every provider package the application references.- The Tensor packages load and run models inside the application's own process.
- The UI.Settings packages provide the setup editors a host places in its own window or page.
Every package of the family carries the same version. Reference all of them at the same version: each package depends on the exact version of the family packages it uses.
The packages are licensed under the MIT license. LICENSE.md in each package holds the license text.
| Package | Holds |
|---|---|
| Darkspyre.Inference.Common | Shared contracts for Connect and Tensor |
| Darkspyre.Inference.Connect | Image, speech and audio connectors |
| Darkspyre.Inference.Connect.Common | Conversation and embedding services and provider discovery |
| Darkspyre.Inference.Connect.Codex | Conversations on a ChatGPT subscription |
| Darkspyre.Inference.Connect.Claude | Conversations on a Claude subscription through the Claude CLI |
| Darkspyre.Inference.Connect.HostTools | The host-tools local service and its client |
| Darkspyre.Inference.Connect.Antigravity | Conversations on a Google subscription through the Antigravity CLI |
| Darkspyre.Inference.Connect.Grok | Conversations on a Grok subscription |
| Darkspyre.Inference.Connect.Anthropic | Conversations through the Anthropic API with an API key, with hosted web search |
| Darkspyre.Inference.Connect.OpenAiApi | Conversations and embeddings through the OpenAI API |
| Darkspyre.Inference.Connect.SelfHost | Conversations and embeddings on engines the application runs |
| Darkspyre.Inference.Tensor.Common | Model packs, the model lifecycle and the Tensor capability interfaces |
| Darkspyre.Inference.Tensor.Decision.Laya | Laya typed decisions through ONNX Runtime |
| Darkspyre.Inference.Tensor.Embedding | Text embeddings from GGUF sentence encoders |
| Darkspyre.Inference.Tensor.Embedding.Gemma | EmbeddingGemma text and image embeddings |
| Darkspyre.Inference.Tensor.Ggml | The process's GGML and MLX native runtime |
| Darkspyre.Inference.Tensor.Image.Supra | Supra2-IMG image generation |
| Darkspyre.Inference.Tensor.LLM.Qwen | Qwen GGUF text generation |
| Darkspyre.Inference.Tensor.Registry | Registration and discovery of the Tensor engines |
| Darkspyre.Inference.Tensor.STT.Whisper | Whisper speech transcription |
| Darkspyre.Inference.UI.Settings.Core | Editor state and host contracts both setup editors share |
| Darkspyre.Inference.UI.Settings.Avalonia | The Avalonia setup editor |
| Darkspyre.Inference.UI.Settings.Blazor | The Blazor setup editor |
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net11.0 is compatible. |
-
net11.0
- Darkspyre.Inference.Common (= 11.20.0)
- Darkspyre.Inference.Connect.Common (= 11.20.0)
- Darkspyre.ML.Tokenizers (>= 2.0.1.1)
- JsonSchema.Net (>= 9.4.0)
- Microsoft.Bcl.Memory (>= 10.0.9)
- Microsoft.Extensions.Http (>= 10.0.9)
- Microsoft.ML.Tokenizers.Data.O200kBase (>= 2.0.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 11.20.0 | 90 | 11/15/2026 |
| 11.19.4-rc.3 | 73 | 11/6/2026 |
| 11.19.3-rc.3 | 59 | 11/5/2026 |
| 11.19.3-rc.2 | 71 | 10/31/2026 |
| 11.17.3-rc.2 | 81 | 10/26/2026 |