OuroborosAI.Core
3.1.0
dotnet add package OuroborosAI.Core --version 3.1.0
NuGet\Install-Package OuroborosAI.Core -Version 3.1.0
<PackageReference Include="OuroborosAI.Core" Version="3.1.0" />
<PackageVersion Include="OuroborosAI.Core" Version="3.1.0" />
<PackageReference Include="OuroborosAI.Core" />
paket add OuroborosAI.Core --version 3.1.0
#r "nuget: OuroborosAI.Core, 3.1.0"
#:package OuroborosAI.Core@3.1.0
#addin nuget:?package=OuroborosAI.Core&version=3.1.0
#tool nuget:?package=OuroborosAI.Core&version=3.1.0
What is Ouroboros?
Ouroboros makes it easy to chain and transform API calls with OpenAI. You get:
- Clean chaining: Fluent interface for feeding the output of one API call into the input of another.
- Easily capture the output of one call, save it to a variable, and then use it as input downchain.
- Template engine: Store your prompts as markdown right in your project, with a corresponding class for fields.
- Store your prompts as markdown right in your project.
- You can use a class with the same name for field injection using {{ mustache syntax }}.
- You can also inject other templates using the same syntax.
- Transform model results into code: using our Hermetic Codex and Proteus Convert (both parts of this project).
- Detect a numbered list and auto-transform it into a List<String> or List<NumberedListItem>
- Convert results directly into classes or enums.
- Smart, recoverable detection of errors / unmappable output.
- Exponential backoff (retry): Always on, for transient outages via <a href="https://github.com/App-vNext/Polly">Polly</a> on all calls.
- Simple Chat API: You can also do regular Chat Completions calls, which gives you Retry.
How do I get started?
Check out the Getting Started Guide (this needs updating).
Where do I get it?
First, <a href="http://docs.nuget.org/docs/start-here/installing-nuget">install NuGet</a>. Then you can install Ouroboros from the package manager console:
PM> Install-Package OuroborosAI.Core
Limits and Possible Contributions
Ouroboros is production-ready, but it does have limits. If you would like those limits to go away, get involved!
- Only supports OpenAI API calls. We built this on top of Betalgo, so it should also be possible to support OpenAI on Azure.
- Chaining only supports the Chat Completions API, meaning GPT 4.1, GPT 4o, etc.
- You can't modify our retry policy, although you can turn it off.
- We could use some help implementing Logging, support for other providers, and the new Responses API.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | 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 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. |
-
net9.0
- Betalgo.Ranul.OpenAI (>= 9.1.0)
- Microsoft.Extensions.Logging.Abstractions (>= 9.0.7)
- Polly (>= 8.6.2)
- Polly.Contrib.WaitAndRetry (>= 1.1.1)
- Scriban (>= 6.2.1)
- TypeMerger (>= 2.1.4)
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 |
|---|---|---|
| 3.1.0 | 889 | 7/23/2025 |
| 3.0.1 | 178 | 7/3/2025 |
| 3.0.0 | 204 | 7/2/2025 |
| 2.9.9 | 300 | 6/5/2025 |
| 2.9.8 | 155 | 5/30/2025 |
| 2.9.7 | 376 | 5/15/2025 |
| 2.9.6 | 228 | 4/23/2025 |
| 2.9.5 | 882 | 8/16/2024 |
| 2.9.4 | 198 | 8/16/2024 |
| 2.9.3 | 207 | 8/15/2024 |
| 2.9.2 | 266 | 6/4/2024 |
| 2.9.1 | 343 | 2/20/2024 |
| 2.9.0 | 202 | 2/14/2024 |
| 2.8.8 | 232 | 1/27/2024 |
| 2.8.8-beta | 147 | 1/27/2024 |
| 2.8.7-beta | 136 | 1/27/2024 |
| 2.8.6-beta | 133 | 1/27/2024 |
| 2.8.5-beta | 173 | 1/21/2024 |
| 2.8.4-beta | 137 | 1/20/2024 |
| 2.8.3 | 202 | 1/19/2024 |
| 2.8.2 | 183 | 1/18/2024 |
| 2.8.1 | 179 | 1/18/2024 |
| 2.8.0 | 158 | 1/18/2024 |
| 2.7.4 | 311 | 12/19/2023 |
| 2.7.3 | 214 | 12/18/2023 |
| 2.7.2 | 204 | 12/15/2023 |
| 2.7.1 | 219 | 12/13/2023 |
| 2.7.0 | 227 | 12/12/2023 |
| 2.6.1 | 198 | 12/8/2023 |
| 2.6.0 | 234 | 11/29/2023 |
| 2.5.0 | 267 | 10/26/2023 |
| 2.4.2 | 211 | 10/20/2023 |
| 2.4.1 | 191 | 10/19/2023 |
| 2.4.0 | 209 | 10/19/2023 |
| 2.3.1 | 209 | 10/17/2023 |
| 2.3.0 | 345 | 9/8/2023 |
| 2.2.0 | 231 | 9/8/2023 |
| 2.1.0 | 380 | 7/9/2023 |
| 2.0.0 | 266 | 7/6/2023 |
| 1.0.5 | 276 | 5/24/2023 |
| 1.0.4 | 330 | 5/23/2023 |
| 1.0.3 | 270 | 5/19/2023 |
| 1.0.2 | 315 | 4/25/2023 |
| 1.0.1 | 307 | 4/25/2023 |
| 1.0.0 | 510 | 3/16/2023 |
| 0.8.7 | 349 | 3/13/2023 |
| 0.8.6 | 359 | 3/10/2023 |
| 0.8.5 | 362 | 3/10/2023 |
| 0.8.4 | 314 | 3/10/2023 |
| 0.8.3 | 335 | 3/10/2023 |
| 0.8.1 | 379 | 3/9/2023 |
| 0.8.0 | 365 | 2/13/2023 |
Finished support for o4-mini, retired Max_Tokens in favor of Max_Completion_Tokens.