Home/
Part XIV — Team Workflows and "Shipping With Adults in the Room"/44. Governance and Compliance (If You're Building a Real Company Product)/44.5 Model/provider change management
44.5 Model/provider change management
Overview and links for this section of the guide.
On this page
Model Portability
Don't hardcode `google.generativeai`. Use an adapter pattern.
interface LLM {
generate(prompt: string): Promise;
}
class GeminiAdapter implements LLM { ... }
class OtherAdapter implements LLM { ... }
The Wrapper
This allows you to swap providers if: - One goes down. - One raises prices. - A better model comes out.