OutWit.Shared.Intelligence.Providers 1.0.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package OutWit.Shared.Intelligence.Providers --version 1.0.0
                    
NuGet\Install-Package OutWit.Shared.Intelligence.Providers -Version 1.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="OutWit.Shared.Intelligence.Providers" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="OutWit.Shared.Intelligence.Providers" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="OutWit.Shared.Intelligence.Providers" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add OutWit.Shared.Intelligence.Providers --version 1.0.0
                    
#r "nuget: OutWit.Shared.Intelligence.Providers, 1.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package OutWit.Shared.Intelligence.Providers@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=OutWit.Shared.Intelligence.Providers&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=OutWit.Shared.Intelligence.Providers&version=1.0.0
                    
Install as a Cake Tool

OutWit.Shared.Intelligence.Providers

Vendor-neutral contract for language-model providers in OutWit hosts. A caller owns its prompts, its answer schema and the validation of answers; a provider only sends one structured request and reports the answer, or a failure that carries no vendor text and no credential.

The pieces

Type What
IIntelligenceProvider SendAsync(IntelligenceRequest) returns an IntelligenceResponse: the text (when the model gave one text part), why it stopped, the model and the tokens
IIntelligenceProviderFactory makes a provider over an IntelligenceConnection (base URL, default model, retries, timeout) and an IIntelligenceKeySource; cheap, so a host may make one per request
IIntelligenceKeySource where a provider reads its key, once a request: the operating system's credential store on a desktop, the key a job brought on a server, none for a local server
IIntelligenceProviderPlugin the plugin marker (IWitPlugin with a Key); its Initialize registers the vendor's factory
IntelligenceTransportException no answer: NotConfigured, AccessDenied, Rejected, Throttled, Unavailable, Network, Timeout, with the HTTP status when there was one
IntelligenceEnvelopeException an answer whose envelope could not be read

Why a factory per connection

Email and storage hosts pick one provider by configuration and the provider reads its own key. A model host differs: a user picks a vendor for each run, and a server may serve many users' keys at once. So every loaded plugin registers its factory, the host keeps them all and picks one by ProviderKey, and the key reaches the provider only through the key source, once a request.

var loader = new WitPluginLoader<IIntelligenceProviderPlugin>(Path.Combine(AppContext.BaseDirectory, "@Intelligence"));
// ... each plugin's Initialize(services) registers an IIntelligenceProviderFactory

var factory = services.GetServices<IIntelligenceProviderFactory>().Single(item => item.ProviderKey == "anthropic");
var provider = factory.Create(new IntelligenceConnection { ModelId = "claude-sonnet-5-5" }, new IntelligenceKeySourceFixed(key));
var answer = await provider.SendAsync(new IntelligenceRequest
{
    Label = "planning", Instructions = "...", Content = "...", Schema = "{...}", MaximumOutputTokens = 2000
});

Providers

  • OutWit.Shared.Intelligence.Provider.Anthropic: Claude, through the official Anthropic SDK.
  • OutWit.Shared.Intelligence.Provider.OpenAI: any OpenAI-compatible Chat Completions service: OpenAI, and the servers people run themselves (Ollama, LM Studio, vLLM, llama.cpp).
Product 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 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on OutWit.Shared.Intelligence.Providers:

Package Downloads
OutWit.Shared.Intelligence.Provider.Anthropic

Claude provider for OutWit hosts, through the official Anthropic SDK: structured answers by JSON schema, the least thinking each model family allows within the answer's output limit, retries of throttled and overloaded requests, and failures that carry no vendor text and no key. A plugin (IIntelligenceProviderPlugin) that registers its IIntelligenceProviderFactory under the key "anthropic".

OutWit.Shared.Intelligence.Provider.OpenAI

OpenAI-compatible provider for OutWit hosts: any Chat Completions service, OpenAI's own and the servers people run themselves (Ollama, LM Studio, vLLM, llama.cpp). Structured answers by JSON schema, bounded retries of throttled and overloaded requests (Retry-After honoured), an optional key, and failures that carry no vendor text and no key. Plain HTTP, no vendor SDK. A plugin (IIntelligenceProviderPlugin) that registers its IIntelligenceProviderFactory under the key "openai".

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.0 97 11/26/2026
1.0.0 80 11/23/2026