Skip to content

Model names change under your apps

Apps call a name your organisation chooses. When a new version arrives, a provider renames a model or retires it, or you move to another provider, you point the name somewhere else, and no app changes.

The problem

A provider announces that a model is retired next quarter. Its id is hard-coded in forty services, a few notebooks and a vendor's tool. Each needs a change, a test and a deploy. Meanwhile a better, cheaper version came out last month, and nobody has moved to it, because moving means the same forty changes.

Why it stays unsolved

A model id is the provider's name for its model, and code uses it directly. There's nothing between the app and the provider to say "this name now means that model". Every version bump and every provider change becomes a code change in every app that calls it, so they happen late, or not at all.

How Vidai handles it

  • A model has a name of your own, separate from its id at the provider. Apps call the name; the gateway sends the provider its own id.
  • Aliases are extra names. Give a model a vendor-neutral name like fast-model, or a stable name that you move to the next version when you're ready. An alias is its model everywhere: access, prices, routing and logs.
  • Every app sees only what it may call. GET /v1/models lists exactly the models a key may call, by the names your organisation chose.
  • The answer says what really served it. x-vidai-model names the model that answered, and x-vidai-requested-model the one asked for when they differ.
  • Routing moves traffic without moving names. A routing rule can send a name to another provider, or split calls between two models to trial one, before you make the move for everyone.

A model's Names: its name, its id at the provider, and the aliases apps can call it by

What changes for you

  • A retirement notice is a change in the Control room, not a release train.
  • New versions get adopted, because adopting one costs a minute.
  • Provider choice stays open. A vendor-neutral name can move to another provider with no app noticing.
  • Proof: call GET /v1/models with any key and see exactly the names it may call.