Skip to content

Latest commit

 

History

History
 
 

TypeScript

README.md

Model Router

Model Router

The Model Router just leveled up with the latest GPT-5 models — and it’s ready to take your AI projects further. In this episode, April pulls back the curtain on how it works, then walks you through using it to pick the right model for any task. From building intelligent agents to optimizing performance and costs, you’ll see the full process in action.

Try it yourself in Microsoft Foundry and start routing your requests smarter: ai.azure.com

Learn more about Model Router: aka.ms/insideAIF/model-router

Prerequisites

Run the Samples

Basic call to the chat completion API

  1. Navigate to the folder: cd Samples/Model-Router/TypeScript
  2. Install dependencies: pnpm install
  3. Set up environment variables: cp .env.example .env
  4. Run the script: pnpm start

Multi-turn conversation

  1. Navigate to the folder: cd Samples/Model-Router/TypeScript
  2. Install dependencies: pnpm install
  3. Set up environment variables: cp .env.example .env
  4. Run the script: pnpm run start:multiturn