DEV Community

Cover image for LlmTornado - The C# Gateway to call 100+ LLM APIs
Matěj Štágl
Matěj Štágl

Posted on

1 1 1 1 1

LlmTornado - The C# Gateway to call 100+ LLM APIs

LlmTornado is a .NET library I've been maintaining for over two years, now with the help of many amazing Contributors. Tornado acts as a gateway similar to LiteLLM, supporting commercial providers (OpenAI, Anthropic, Google, DeepSeek, Cohere, Mistral, Azure, Groq..) and self-hosted inference servers (Ollama, LocalAI..)

Tornado provides a unified, OpenAI-shaped inference interface with powerful, strongly typed Vendor Extensions enabling the use of the specific APIs various Providers offer, allowing a broader scope of applications than relying on any single provider can. This approach promotes resiliency to temporary downtime of providers - which is still the norm when using public APIs.

Tornado also acts as an API harmonizer for the supported providers. For example, suppose a request accidentally passes a temperature parameter to a reasoning model, where such an argument is not supported. We take care of that, to maximize the probability of the call succeeding. This applies to various whims of the providers, such as developer_messagevs system_prompt (in Tornado there is just a System role for Messages), Google having completely different endpoints for embedding multiple texts at once, and many other annoyances.

With fewer abstractions than full frameworks like Semantic Kernel, Tornado aims to reduce the complexity of building applications, while enabling easy synthetisation of the abstractions your unique project will benefit from. Out-of-the-box Tornado includes conversations, strongly typed RAG primitives, and FSMs.

Tornado is extensively documented and covered with 200+ unit tests, powering real-world applications with thousands of active users daily.

👉 Check the awesome demos in the readme: https://github.com/lofcz/LlmTornado

Heroku

Amplify your impact where it matters most — building exceptional apps.

Leave the infrastructure headaches to us, while you focus on pushing boundaries, realizing your vision, and making a lasting impression on your users.

Get Started

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Explore a trove of insights in this engaging article, celebrated within our welcoming DEV Community. Developers from every background are invited to join and enhance our shared wisdom.

A genuine "thank you" can truly uplift someone’s day. Feel free to express your gratitude in the comments below!

On DEV, our collective exchange of knowledge lightens the road ahead and strengthens our community bonds. Found something valuable here? A small thank you to the author can make a big difference.

Okay