From c483f287c1e97c0455ee37cd888033265e5a5487 Mon Sep 17 00:00:00 2001
From: Mallard AI <347955780+Mallard-AI@users.noreply.github.com>
Date: Sun, 25 Oct 2026 18:57:43 +0000
Subject: [PATCH 1/3] feat: add Mallard AI provider
Mallard AI (Radiant RX Ltd, UK): an OpenAI-compatible API processed only in the UK,
with zero data retention. Adds the provider, its logo and Qwen3.6 35B A3B.
---
providers/mallard/logo.svg | 12 ++++++
.../mallard/models/qwen/qwen3.6-35b-a3b.toml | 39 +++++++++++++++++++
providers/mallard/provider.toml | 8 ++++
3 files changed, 59 insertions(+)
create mode 100644 providers/mallard/logo.svg
create mode 100644 providers/mallard/models/qwen/qwen3.6-35b-a3b.toml
create mode 100644 providers/mallard/provider.toml
diff --git a/providers/mallard/logo.svg b/providers/mallard/logo.svg
new file mode 100644
index 00000000000..f7f637a8784
--- /dev/null
+++ b/providers/mallard/logo.svg
@@ -0,0 +1,12 @@
+
diff --git a/providers/mallard/models/qwen/qwen3.6-35b-a3b.toml b/providers/mallard/models/qwen/qwen3.6-35b-a3b.toml
new file mode 100644
index 00000000000..753011430d5
--- /dev/null
+++ b/providers/mallard/models/qwen/qwen3.6-35b-a3b.toml
@@ -0,0 +1,39 @@
+# Sources (accessed 2026-10-25): https://mallardai.co.uk/pricing/, https://mallardai.co.uk/docs/,
+# https://api.mallardai.co.uk/v1/models
+# Billed in GBP: £0.08 input / £0.02 cached input / £0.75 output per 1M tokens; converted at the ECB rate
+# 1 GBP = 1.3368 USD (2026-10-23).
+# Toggle: reasoning.enabled = true|false. reasoning_effort = "none" and chat_template_kwargs.enable_thinking = false
+# also turn it off. There is no graded effort: reasoning_effort = "low" is accepted and reasoning stays on.
+# Reasoning is returned in message.reasoning. reasoning_field = "reasoning" is valid in v2 but v1's interleaved.field
+# only allows reasoning_content|reasoning_details, so no reasoning_field is set.
+# Live checks 2026-10-25 on POST /v1/chat/completions:
+# - Reasoning is on by default; each off switch above returns no reasoning.
+# - Images: a PNG data URL is read correctly; video_url returns 400. Image input is PNG, JPEG and WebP.
+# - Tools: tool_choice auto|required|named function|none behave as expected.
+# - structured_output: response_format json_schema (strict, enum field) and json_object are enforced.
+# - Cache: automatic prefix cache in pages of 2,096 tokens, no markers; a repeated 6,016-token prompt reported
+# prompt_tokens_details.cached_tokens = 4,192 on the second request.
+# - Limit: max_tokens = 235_929 accepted; 262_144 rejected (prompt plus output past the 262,144-token window).
+# - Streaming: stream_options.include_usage returns usage in a chunk.
+schema = 2
+base_model = "alibaba/qwen3.6-35b-a3b"
+
+[modalities]
+input = ["text", "image/png", "image/jpeg", "image/webp"]
+output = ["text"]
+
+[capabilities]
+reasoning = { supported = true, toggle = true }
+structured_output = true
+cache = { implicit = { min_tokens = 2_096 } }
+stream_usage = true
+
+[limit]
+output = 235_929
+
+[cost.text.input]
+price = 0.106944
+cache = { read = 0.026736 }
+
+[cost.text.output]
+price = 1.0026
diff --git a/providers/mallard/provider.toml b/providers/mallard/provider.toml
new file mode 100644
index 00000000000..d91ee0265cd
--- /dev/null
+++ b/providers/mallard/provider.toml
@@ -0,0 +1,8 @@
+# Mallard AI (Radiant RX Ltd, England and Wales): an OpenAI-compatible API processed only in the UK, with zero data
+# retention. Quick start: https://mallardai.co.uk/docs/ (accessed 2026-10-25).
+name = "Mallard AI"
+npm = "@ai-sdk/openai-compatible"
+opencodeai = "@opencode/ai/providers/openai-compatible"
+api = "https://api.mallardai.co.uk/v1"
+env = ["MALLARD_API_KEY"]
+doc = "https://mallardai.co.uk/docs/"
From 045602424635355472e4e257afff9e28aa306e7f Mon Sep 17 00:00:00 2001
From: Mallard AI <347955780+Mallard-AI@users.noreply.github.com>
Date: Sun, 25 Oct 2026 19:19:57 +0000
Subject: [PATCH 2/3] fix: clip the Mallard AI logo's neck ring to the disc
---
providers/mallard/logo.svg | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/providers/mallard/logo.svg b/providers/mallard/logo.svg
index f7f637a8784..601d9b65480 100644
--- a/providers/mallard/logo.svg
+++ b/providers/mallard/logo.svg
@@ -1,11 +1,14 @@