Modules
Lossless serialisation of Omni structs to and from JSON-safe maps.
An attachment content block for binary content such as images, PDFs, and other media.
A text content block.
A thinking content block representing the model's chain-of-thought reasoning.
A tool result content block representing the output of a tool invocation.
A tool use content block representing the model's intent to invoke a tool.
The context for a conversation with an LLM.
Behaviour for wire format translation between Omni types and provider APIs.
Dialect implementation for the Anthropic Messages wire format.
Dialect implementation for the Google Gemini wire format.
Dialect implementation for the Ollama native chat API wire format.
Dialect implementation for the OpenAI Chat Completions wire format.
Dialect implementation for the OpenAI Responses wire format.
A message in a conversation.
A data struct describing a specific LLM.
Behaviour and shared logic for LLM providers.
Provider for the Anthropic API, using the Omni.Dialects.AnthropicMessages
dialect.
Provider for the Google Gemini API, using the Omni.Dialects.GoogleGemini
dialect.
Provider for the Groq API, using the Omni.Dialects.OpenAICompletions
dialect.
Provider for the Moonshot AI (Kimi) API, using the
Omni.Dialects.OpenAICompletions dialect.
Provider for the Ollama API, using the Omni.Dialects.OllamaChat dialect.
Provider for the OpenAI API, using the Omni.Dialects.OpenAIResponses
dialect.
Provider for the OpenCode Zen API.
Provider for the OpenRouter API, using the Omni.Dialects.OpenAICompletions
dialect.
Provider for the Z.ai API, using the Omni.Dialects.OpenAICompletions
dialect.
The result of a text generation request.
Builders and validation for JSON Schema maps.
A streaming LLM response that yields events as they arrive from the provider.
Reusable, validated tools that an LLM can invoke during a conversation.
Executes tool use blocks in parallel and returns tool result blocks.
Token counts and computed costs for a generation request.
Mix Tasks
Fetches model catalog data from models.dev and writes JSON files to priv/models/.
