Mallard AI

LiteLLM

Call the API from LiteLLM's Python SDK or proxy, with openai/ before the model ID.

Python SDK

Python
import os
import litellm

response = litellm.completion(
    model="openai/qwen/qwen3.6-35b-a3b",
    api_base="https://api.mallardai.co.uk/v1",
    api_key=os.environ["MALLARD_API_KEY"],
    messages=[{"role": "user", "content": "What is the capital of Wales?"}],
)
print(response.choices[0].message.content)

Proxy

Add this to the proxy's config.yaml, with MALLARD_API_KEY set in the proxy's environment. Clients then ask for qwen3.6-35b-a3b.

config.yaml
model_list:
  - model_name: qwen3.6-35b-a3b
    litellm_params:
      model: openai/qwen/qwen3.6-35b-a3b
      api_base: https://api.mallardai.co.uk/v1
      api_key: os.environ/MALLARD_API_KEY
    model_info:
      input_cost_per_token: 0.00000008          # pounds
      cache_read_input_token_cost: 0.00000002   # pounds
      output_cost_per_token: 0.00000075         # pounds

These costs are per token, in pounds: input, cached input and output.

LiteLLM's docs