Thalos.NET 0.1.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package Thalos.NET --version 0.1.1
                    
NuGet\Install-Package Thalos.NET -Version 0.1.1
                    
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="Thalos.NET" Version="0.1.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Thalos.NET" Version="0.1.1" />
                    
Directory.Packages.props
<PackageReference Include="Thalos.NET" />
                    
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 Thalos.NET --version 0.1.1
                    
#r "nuget: Thalos.NET, 0.1.1"
                    
#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 Thalos.NET@0.1.1
                    
#: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=Thalos.NET&version=0.1.1
                    
Install as a Cake Addin
#tool nuget:?package=Thalos.NET&version=0.1.1
                    
Install as a Cake Tool

Thalos.NET

CI License: MIT

Named after Talos, the bronze guardian of Crete. Spelled Thalos because Talos.* is taken on nuget.org.

A Hermes-style, ZeroAlloc-native agent framework for .NET, built on Microsoft Agent Framework with first-class AI.Sentinel security and Model Context Protocol tools.

Package Purpose Depends on
Thalos.NET.Abstractions Ports (IAgentRuntime, IAgentSessionStore, IToolSource, IChatClientProvider, …), models, typed ids, AgentError ZeroAlloc.*, Microsoft.Extensions.AI.Abstractions
Thalos.NET Runtime: agent factory, tool catalog + authorization, session state machine, in-memory store, AddThalos(...) Abstractions, Microsoft.Agents.AI
Thalos.NET.Testing ScriptedChatClient, RecordingNotificationPublisher, reusable IAgentSessionStore contract tests (ships xunit + AwesomeAssertions references by design) Thalos.NET
Thalos.NET.Mcp MCP servers (stdio / http / sse, Claude Code-style .mcp.json) as tool sources Thalos.NET, ModelContextProtocol
Thalos.NET.Anthropic Anthropic Claude chat-client provider Thalos.NET, Anthropic
Thalos.NET.Sentinel AI.Sentinel scanning at the model boundary, quarantine → AgentError Thalos.NET, AI.Sentinel

Targets net8.0 and net10.0.

Quick start

services.AddThalos(thalos => thalos
    .UseAnthropic(configuration)                       // Thalos:Anthropic section; ApiKey falls back to ANTHROPIC_API_KEY
    .UseAISentinel(o => o.EmbeddingGenerator = myEmbeddings)   // see the security note below
    .UseInMemorySessionStore()
    .AddMcpServersFromFile(Path.Combine(AppContext.BaseDirectory, ".mcp.json"))
    .RequireToolPolicy("roslyn__apply_*", "developer")
    .AddPolicy<DeveloperPolicy>()                      // any ZeroAlloc.Authorization [Policy("developer")]
    .AddAgent(new AgentDefinition
    {
        Id = AgentId.Parse("01ARZ3NDEKTSV4RRFFQ69G5FAV", null),
        Name = "Architect",
        Instructions = "You are a senior .NET architect. Use the roslyn tools to answer precisely.",
        Tools = ["roslyn__*"],
    }));

var runtime = provider.GetRequiredService<IAgentRuntime>();
var session = await runtime.CreateSessionAsync(agentId, caller, ct);           // caller: ISecurityContext supplied by the channel
var turn = await runtime.RunTurnAsync(new AgentTurnRequest(session.Value, "Who calls TaskRepository.UpdateAsync?", caller), ct);

await foreach (var evt in runtime.RunTurnStreamingAsync(new AgentTurnRequest(session.Value, "…", caller), ct))
{
    // TextDeltaEvent, ToolCallStartedEvent, ToolCallFinishedEvent, UsageEvent, TurnCompletedEvent | TurnFailedEvent
}

Tool names exposed to the model are {source}__{tool} (e.g. roslyn__find_callers); AgentDefinition.Tools and RequireToolPolicy take globs over that qualified name. Authorization is enforced by Thalos at the function boundary — before the tool runs — not by inspecting the chat stream afterwards.

A runnable REPL lives in samples/Thalos.Sample.Console.

Security: AI.Sentinel needs an embedding generator

AI.Sentinel 2.0.1's security detectors (prompt injection, jailbreak, exfiltration, …) are semantic. Without SentinelOptions.EmbeddingGenerator they return Clean and only the lexical/operational detectors run — UseAISentinel() with no embedding generator is not prompt-injection protection. Wire a real IEmbeddingGenerator (Ollama, OpenAI, …):

.UseAISentinel(o =>
{
    o.EmbeddingGenerator = embeddingGenerator;   // IEmbeddingGenerator<string, Embedding<float>>
    o.OnCritical = SentinelAction.Quarantine;    // surfaces as AgentError.Quarantined ("<Severity>: <DetectorId>")
    o.OnHigh = SentinelAction.Alert;
})

Local development against Daedalus

Until the packages are on nuget.org, consumers (Daedalus, phase 1.1) build from a local folder feed:

pwsh scripts/pack-local.ps1          # → C:\Projects\Prive\.nuget-local\Thalos.NET*.0.1.0-local.<timestamp>.nupkg

The script prints the exact version. In the consuming repo:

nuget.config (next to the solution):

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <clear />
    <add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
    <add key="thalos-local" value="C:\Projects\Prive\.nuget-local" />
  </packageSources>
</configuration>

Directory.Packages.props (central package management):

<ItemGroup>
  <PackageVersion Include="Thalos.NET.Abstractions" Version="0.1.0-local.20260816120000" />
  <PackageVersion Include="Thalos.NET"              Version="0.1.0-local.20260816120000" />
  <PackageVersion Include="Thalos.NET.Testing"      Version="0.1.0-local.20260816120000" />
  <PackageVersion Include="Thalos.NET.Mcp"          Version="0.1.0-local.20260816120000" />
  <PackageVersion Include="Thalos.NET.Anthropic"    Version="0.1.0-local.20260816120000" />
  <PackageVersion Include="Thalos.NET.Sentinel"     Version="0.1.0-local.20260816120000" />
</ItemGroup>

Re-run the script and bump the pin after every change to Thalos.NET (NuGet caches by exact version, so never re-pack the same version — the timestamp suffix guarantees a fresh one). If a stale package is still picked up, clear %USERPROFILE%\.nuget\packages\thalos.net*.

Building

dotnet build              # 0 warnings — TreatWarningsAsErrors with Meziantou, Roslynator and ZeroAlloc analyzers
dotnet test               # unit, MCP (launches tests/Thalos.NET.Tests.McpServer over stdio), Sentinel, architecture

Versioning and releases

Same setup as Rag.NET; the runbook is docs/release.md.

  • Versions come from git history via GitVersion (dotnet tool restore && dotnet dotnet-gitversion); nothing is hand-edited. Stable versions only — no prereleases are published.
  • Releases are cut by release-please from conventional commits (enforced on PRs by commitlint): dispatch → review/merge the release PR → dispatch → vX.Y.Z tag + GitHub release.
  • CI (.github/workflows/ci.yml) builds and tests on Ubuntu and Windows on every push/PR, packs and validates the six packages, and rehearses the nuget.org push against a local feed. Publishing to nuget.org is a manual dispatch with publish_to_nuget=true on the tagged release commit, using nuget.org Trusted Publishing (no stored API key).

Status: 0.1.0 — API is unstable until 1.0.

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 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (6)

Showing the top 5 NuGet packages that depend on Thalos.NET:

Package Downloads
Thalos.NET.Anthropic

Anthropic Claude chat-client provider for Thalos.NET.

Thalos.NET.Mcp

Model Context Protocol servers (stdio, http) as Thalos.NET tool sources. Loads Claude Code-style .mcp.json.

Thalos.NET.Sentinel

AI.Sentinel security middleware at the model boundary for Thalos.NET agents.

Thalos.NET.Testing

Test doubles and contract tests for Thalos.NET: ScriptedChatClient (scripted IChatClient), RecordingNotificationPublisher (in-memory IAgentNotificationPublisher), reusable IAgentSessionStore contract tests, memory store/index contract tests, skill store/index contract tests, deterministic embedding generator (xUnit + AwesomeAssertions).

Thalos.NET.Memory

Curated long-term memory for Thalos.NET agents: MemoryRecord model, IMemoryStore/IMemoryIndex/IMemoryService ports, auto-recall AIContextProvider, memory tools, in-memory implementations.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.3.0 0 8/19/2026
0.2.0 93 8/17/2026
0.1.1 83 8/17/2026