DEV Community

Daniel Dong
Daniel Dong

Posted on

I migrated my app from one AI provider to four. Here's the code change.

I migrated my app from one AI provider to four. Here's the code change.

# Before: one provider, one model
openai.OpenAI(
    api_key="sk-deepseek-xxx",
    base_url="https://api.deepseek.com/v1"
)

# After: four providers, 15 models
openai.OpenAI(
    api_key="mb-xxx",
    base_url="https://aibridge-api.com/v1"
)
Enter fullscreen mode Exit fullscreen mode

That's it. One string changed. Zero new imports. Zero SDK rewrites.
Suddenly I have DeepSeek, Qwen, GLM, and Kimi K3 behind the same endpoint.

Why I needed more than one model

My app does three things: classify user input, translate content
to Chinese, and occasionally debug customer-reported issues.

Sending everything to deepseek-chat ($0.27/M) worked. But the
debugging tasks needed more reasoning power. The translations
needed better multilingual support. I was using one model for
three very different jobs.

Now I route by task type:

model = (
    "deepseek-chat" if task == "classify" else     # $0.27/M
    "qwen-max"      if task == "translate" else     # multilingual
    "kimi-k3"       if task == "debug" else         # 1M context + always thinks
    "deepseek-chat"                                  # default
)

client.chat.completions.create(model=model, messages=messages)
Enter fullscreen mode Exit fullscreen mode

Same code. Same bill. Different model for different work.

The K3 difference

Kimi K3 is the one I reach for when the question is hard and the
context is large. 1M token window — I've pasted entire modules and
asked it to find race conditions. It reads every line, runs a
reasoning pass without being told, then gives me locations with
suggested fixes.

No "think step by step." No reasoning toggle. Just send the prompt.

What made this easy

  • GitHub OAuth — one click to register. Five seconds.
  • Instant onboarding — after login: API key + curl example + Python code, all copyable. 30 seconds to first response.
  • Free playground — 15 models, no signup. 10 requests/day.
  • Usage dashboard — progress bar that goes from polite to urgent as you approach your free tier limit. Free tier: 500K tokens/month. No credit card.

aibridge-api.com/playground.html (try K3, no signup)
aibridge-api.com/register.html (GitHub login, one click)

1

2

3

4

Top comments (0)