Plugin.Maui.Spine.Server.AI 0.1.26

dotnet add package Plugin.Maui.Spine.Server.AI --version 0.1.26
                    
NuGet\Install-Package Plugin.Maui.Spine.Server.AI -Version 0.1.26
                    
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="Plugin.Maui.Spine.Server.AI" Version="0.1.26" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Plugin.Maui.Spine.Server.AI" Version="0.1.26" />
                    
Directory.Packages.props
<PackageReference Include="Plugin.Maui.Spine.Server.AI" />
                    
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 Plugin.Maui.Spine.Server.AI --version 0.1.26
                    
#r "nuget: Plugin.Maui.Spine.Server.AI, 0.1.26"
                    
#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 Plugin.Maui.Spine.Server.AI@0.1.26
                    
#: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=Plugin.Maui.Spine.Server.AI&version=0.1.26
                    
Install as a Cake Addin
#tool nuget:?package=Plugin.Maui.Spine.Server.AI&version=0.1.26
                    
Install as a Cake Tool

Plugin.Maui.Spine.Server.AI

AI on the server for Spine apps. Features are named in configuration, and each one names its provider and model. Every token and image is metered and priced. Budgets and per-user limits stop runaway cost. The endpoints run on ASP.NET Core and in an Azure Functions isolated worker. It is built on Microsoft.Extensions.AI: a provider is the vendor's own adapter, registered in one line, so this package references no vendor SDK.

dotnet add package Plugin.Maui.Spine.Server.AI
builder.Services.AddSpineAI(builder.Configuration.GetSection("Ai"), ai =>
{
    ai.Chat("anthropic", (p, model) => new AnthropicClient { ApiKey = p["ApiKey"] }.AsIChatClient(model));
    ai.Chat("openai", (p, model) => new OpenAIClient(p["ApiKey"]).GetChatClient(model).AsIChatClient());
    ai.UseAzureTableUsageStore(cfg["Storage"]);   // or UseInMemoryUsageStore()
});

app.MapSpineAI();   // POST /ai/features/{name} for exposed features, GET /ai/usage
"Ai": {
  "Providers": { "anthropic": { "ApiKey": "" } },
  "Features": {
    "RaceStory": { "Provider": "anthropic", "Model": "<model id>", "MaxOutputTokens": 800,
                   "Budget": { "DaySoft": 2, "DayHard": 5 } }
  },
  "Prices": { "anthropic": { "<model id>": { "InputPerMillion": 3, "OutputPerMillion": 15 } } },
  "Currency": "USD"
}
var caller = await ai.IdentifyAsync(request);
if (ai.Chat("RaceStory", caller) is not { } story) return Results.NotFound();   // off: no key, disabled or budget spent

A feature with "Kind": "Realtime" hands the app a short-lived token for a live voice session at POST /ai/realtime/{name} (ai.Realtime("openai", AIRealtimeProviders.OpenAI) and app.MapSpineRealtimeSessions()). The provider's key stays on the server, and each session reserves its minutes from the budgets; the app may ask for a shorter limit. GPT-Live ("Protocol": "Live"), which has no client token, goes through a relay on the server instead, which ends the session at its limit and settles the reservation with what it used (ASP.NET Core, with app.UseWebSockets()).

A feature with "Kind": "Speech" reads text aloud at POST /ai/speech/{name}: PCM16 with the mouth shapes and their times from Azure Speech (ai.Speech("azure", AISpeechProviders.AzureSpeech), over the service's WebSocket, no native SDK), or audio alone from OpenAI (AISpeechProviders.OpenAI). Metered by characters (PerMillionCharacters).

Swapping provider is a change to Provider and Model in configuration, and takes effect without a deploy.

Documentation

Product Compatible and additional computed target framework versions.
.NET 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 (1)

Showing the top 1 NuGet packages that depend on Plugin.Maui.Spine.Server.AI:

Package Downloads
Plugin.Maui.Spine.Server.AI.Assets

Generated images for Spine's server, made once and served from blob storage: a lookup answers with the image's URL or orders it, a Spine messaging handler generates it through a metered, budgeted Server.AI feature, checks it and archives it under a versioned path. A version bump remakes images lazily, and failures are visible to the app.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.26 0 10/24/2026
0.1.25 0 10/24/2026
0.1.24 36 10/23/2026
0.1.23 29 10/23/2026
0.1.22 37 10/23/2026
0.1.21 32 10/23/2026
0.1.20 37 10/23/2026
0.1.19 45 10/22/2026
0.1.18 63 10/21/2026
0.1.17 61 10/20/2026
0.1.16 66 10/20/2026
0.1.15 88 10/16/2026