ChatStream.OpenAi.Client.Net 8.0.2

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

ChatStream.OpenAi.Client.Net

NuGet Version License: MIT

一个轻量级、高性能的 .NET 8 库,用于调用 OpenAI 兼容的聊天 API,支持流式输出函数调用(Tool Calling) 以及多种响应格式(SSE、OpenAI 标准)。同时提供了 ASP.NET Core 集成扩展,让你轻松在 Web API 中实现打字机效果的流式响应。

✨ 特性

  • 🚀 原生支持异步流式输出(IAsyncEnumerable<string>
  • 🔧 函数调用(Tools)支持 – 让大模型自动调用你定义的本地方法
  • 🌐 兼容 OpenAI、Azure OpenAI、阿里云 DashScope(通义千问)等兼容端点
  • 📦 无重度依赖 – 核心库仅依赖 Microsoft.Extensions.AIOpenAI 官方包
  • 🎯 开箱即用的 ASP.NET Core 集成 – 提供 StreamResult 支持三种 SSE 格式
  • 🧪 支持依赖注入(DI)和单元测试友好设计

📦 安装

核心库(所有项目通用)

dotnet add package ChatStream.OpenAi.Client.Net
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 was computed.  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

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
8.0.5 93 5/17/2026
8.0.4 105 4/28/2026
8.0.3 105 4/27/2026
8.0.2 104 4/26/2026
8.0.1 115 4/23/2026