github
393 TopicsClaude Code on Microsoft Foundry with Claude apps gateway and UI Console
Deploy Anthropic's Claude apps gateway on Azure Container Apps in front of Claude models in Microsoft Foundry: Entra sign-in for developers, no model keys on laptops, and an admin console for spend caps, access and chargeback.269Views0likes0CommentsCreate an Active Student badge on Microsoft Learn
Create an Active Student badge on Microsoft Learn Description: I suggest adding an official Active Student” badge in the Microsoft Community and Microsoft Learn platforms. This badge would Highlight students’ commitment to learning. Encourage continuous participation through visible recognition. Connect learning achievements (Learn) with community contributions (Community Hub). Provide a public credential that can be showcased on a CV or professional profile. Such a symbolic addition would strengthen motivation, visibility, and the bridge between Microsoft Learn and the Community.Solved1KViews2likes6CommentsDesigning a Reliable AI Workflow on Azure: Production Lessons from Translation Automation
Many teams can build an AI prototype that works. A trigger arrives, the model produces a plausible response, and the demo ends with the expected file or message. But what happens when that prototype becomes a workflow that other people depend on? Imagine an AI-assisted process that prepares a recurring report. The notification arrives on time, but the report is blank. On another run, the research is useful but lands in the wrong template. A retry then replaces a version that someone had already reviewed. In each case, the model may have responded normally while the application still delivered the wrong operational result. I encountered versions of these failures while operating Localizeflow, an independent translation orchestration project built around Co-op Translator. A translation could appear to finish without producing a complete, reviewable document. A credential failure could look like a missing result. Overlapping requests could place too much work and state inside one long-running worker. Those experiences changed the question I ask after an AI prototype succeeds. The next question is not simply, “Can the model do the task?” It is, “Can the workflow record the request, survive failure, validate the final artifact, and return something another person can trust?” This article uses translation as one worked example, but the lessons apply to any long-running AI workflow that produces a report, document, batch, or repository change. We will follow three failure classes from prototype to production, then add one operating requirement that makes the workflow's progress visible. A working prototype proves only one thing The translation prototype was deliberately simple. A trigger started the process, the process downloaded the source, called the model, wrote the translated files, and uploaded the result. It proved that the model could translate a document. It did not prove that the workflow had used the intended input revision, preserved a partial result, rejected stale output, or left enough evidence to explain a failure. It also did not prove that the resulting document was ready for someone else to use. That distinction became visible in public repository work. MCP for Beginners pull request #926 shows an incomplete translation batch that stopped with two of 19 translation tasks complete and was closed without merge. The screen records the observable state, but it does not establish the root cause or prove that every generated file was blank. Figure 1. Public failure evidence from MCP for Beginners pull request #926. The Localizeflow progress record showed two of 19 translation tasks complete, and the pull request was closed without merge. This screen establishes the observable outcome, not the root cause or the contents of every generated file. By contrast, AI Agents for Beginners pull request #790 connects a completed translation update to a visible diff, review findings, follow-up fixes, and a repository decision. The Localizeflow bot opened the update, and the repository merged it on October 30, 2026. The merge proves that the repository accepted the change. It does not prove translation accuracy, time saved, or a separate deployment. We will return to this accepted result at the end. The two records illustrate the central distinction in this article: A model response, a completed process, a delivered artifact, and an accepted result are different outcomes. Translation exposed that distinction, but it is not unique to translation. A report generator can return text while omitting a required section. A post-processor can damage a valid response. An uploader can publish the wrong revision. A retry can replace work that a person had already approved. What the workflow had to add The production-oriented design starts by treating each request as durable work rather than a long-running model call. Figure 2 applies that pattern to an independent translation example. The sections that follow explain the responsibility at each handoff. Figure 2. Independent reference architecture for hosting Co-op Translator on Azure. A GitHub documentation change enters an orchestrator hosted in Azure Container Apps, which records the request and starts an Azure Container Apps Job. The job runs Co-op Translator and calls Azure OpenAI to produce a candidate translation. Deterministic checks gate the pull request, and a person decides whether to merge it. This is an independent reference design, not a description of an existing project's internal implementation. Note: Azure Container Apps is suited to service-style workloads such as HTTP APIs, while Container Apps Jobs runs tasks that start, perform a finite unit of work, and stop. In this design, the Container App hosts the request-facing API and orchestrator, while each accepted translation attempt runs as a separate Job. The container app receives the GitHub change, validates the scope, records the logical job, and decides when an attempt may start. The job runs Co-op Translator, calls the deployed Azure OpenAI model, writes an attempt-scoped artifact, reports its outcome, and exits. Azure OpenAI performs model inference, but it does not own workflow state, validation policy, or merge authority. First, accept the work. The application checks that the caller, input, scope, and policy are allowed. In this worked example, the accepted request connects a GitHub documentation change to the repository, source revision, file scope, and target language. In a report workflow, it may mean the data source, reporting period, template, and recipient. Next, record and orchestrate it. The orchestrator hosted in Azure Container Apps saves the logical job before starting execution. The record connects the request to the input revision, policy version, attempt history, and eventual decision. If the process stops, the work still has an identity and a state. In this design, the application layer detects work, records the logical job, and coordinates bounded executions. Then, execute a bounded attempt. The orchestrator remains the request-facing service boundary in Azure Container Apps while an Azure Container Apps Job runs Co-op Translator for the finite unit of work. The worker receives the recorded job ID, writes to an attempt-specific workspace, and reports its outcome. Finally, validate and decide. The job's output remains a candidate. Application checks establish whether the artifact is complete, current, and within the allowed scope. Only then does the application prepare a reviewable change. In this worked example, that change is a pull request, and a person decides whether to merge it. The model call remains important, but it is no longer asked to carry workflow state, validation policy, and delivery authority by itself. What changes after the prototype works? Starting with the prototype was the right decision. A first version should answer the smallest useful question: can the model perform the task on one known input? Building job records, isolated workers, recovery logic, validation rules, and monitoring before that question is answered can become overengineering. The mistake is not starting simple. It is treating the simple version as production-ready. Reliability features should be added when the workflow crosses a real boundary: more inputs, overlapping requests, external dependencies, consequential delivery, or users who need to understand and recover from failure. The original prototype connected a trigger directly to a model call and treated the returned output as success. That was enough to prove the basic capability. Most state lived inside the process, however, so a stopped run or incomplete artifact left little durable evidence. The production-oriented workflow keeps the model call but changes the boundaries around it. The trigger records a job, each execution becomes an attempt, generated files remain separate from accepted state, and a retry cannot silently erase the failed attempt. Start with the simplest workflow that can prove the task. Add complexity only when a real failure boundary justifies it. Figure 3. The model call remains. Production adds durable state, bounded execution, artifact checks, and human review. This change matters because real operation adds failure surfaces that a successful demo does not exercise. A trigger can arrive twice. A credential can be invalid. The source can change while work is running. A model can return only part of a document. Application code can damage a valid response. A validator can reject acceptable variation. An external system can complete an action while the workflow loses the response. While writing this article, I went back through every Co-op Translator release, from v0.2.1 to v0.23.3. Reading them in order felt a little like replaying the project from the first prototype to the workflow it became. I had forgotten how many of the harder problems appeared only after the model was already returning translations. Credentials failed, chunks were reassembled incorrectly, retries needed boundaries, and valid output could still be rejected. Looking back helped me choose the cases below. I wanted to share the problems that became visible only after the prototype worked, because they are the kinds of problems other teams may meet when a proof of concept becomes an automation people depend on. Three failures changed the design most. Lesson 1: A successful model call can still produce a failed artifact In early runs, a translation could appear to finish while omitting source lines or changing protected Markdown structure. The provider request had completed, but the document was not complete enough to review. Co-op Translator pull request #568 records a reproducible version of this behavior. Azure OpenAI returned HTTP 200 with finish_reason='stop' , but a response could still omit source lines or lose, duplicate, or reorder protected Markdown placeholders. The affected responses were below the provider token limit and did not report a length or content-filter stop. The recovery logic therefore stopped treating a normal provider completion as proof of a valid artifact. It validated each translated chunk, preserved the verified prefix, and retried only the missing or damaged portion when possible. I described how that review path evolved, including marker checks, bounded retries, preserved human edits, and recorded failures, in What production taught us about reviewing AI translations. The model is not the only place where an artifact can break. Issue #505 showed a translated Markdown table that rendered correctly for the first four rows and then collapsed into unformatted text. Figure 4. Cropped evidence from Co-op Translator issue #505. Application reassembly inserted an extra newline at the chunk boundary, so the final Markdown table broke after row 03 even though translated chunks were available. Pull request #508 documents the fix. This is not a model-quality failure. The one-line repair was conceptually simple: join the translated chunks without injecting a new newline. The lesson was larger. Valid model outputs can become an invalid document after the response, so validation must inspect the final assembled artifact. The earlier article Fixing Broken Markdown in AI Translation: Hardening a Production Pipeline examines the wider class of structural failures, including damaged code fences, links, lists, images, anchors, and CJK formatting. Guardrails can also be wrong. Pull request #581 documents a valid Italian translation that preserved the protected structure but moved ordinary prose naturally. The validator retried the valid result and eventually failed, so the fix narrowed the invariant to the structure that actually needed protection. These cases led to one operating rule: treat every generated response as a candidate. Keep the logical job, attempt, candidate, and accepted result separate. Pull request #493 applied the same principle by preserving the last usable translation when a replacement failed. Where policy permits, quarantine a rejected candidate with its validation report. Where the content cannot be retained, preserve safe structural diagnostics such as the file, attempt ID, failed check, and expected and actual counts. Do not copy sensitive source content into routine logs. The same rule applies to a report workflow. A report with a missing required section is not a completed report, even if the model returned a normal response. A template populated with damaged fields is not safe to deliver, even if the original content was correct. Try this before production: remove one required section or protected marker from an otherwise normal candidate. The attempt should fail without replacing the previous accepted result, and the failure record should explain which check rejected it. Lesson 2: A missing result may be a dependency failure Another failure occurred before translation quality could matter. A credential problem prevented the provider from producing a usable response. In the early workflow, the expected artifact simply did not appear, while the underlying authentication problem surfaced only as a generic process failure. A blind retry would repeat a request that could not succeed. The workflow needed to distinguish “the model produced a bad candidate” from “a required dependency was unavailable.” Co-op Translator pull request #211 added a lightweight connectivity check that exercises the real provider data path before translation begins. It checks the endpoint, API version, credential, and deployment. Authentication failures such as 401 or 403 stop the run with actionable feedback instead of appearing after a long batch. Figure 5. Authentication failure becomes failed with a stable reason and does not publish an empty artifact. After repair, the workflow starts a new attempt under the same logical job. A startup check is valuable, but it cannot guarantee that a token or credential will remain valid throughout a long execution. A 401 or 403 received during execution should enter the same stable failure category. The job can become failed with a reason such as provider_authentication , while an operator repairs the endpoint, permission, or credential and starts a new attempt without losing the earlier history. The same pattern applies to retrieval indexes, databases, document stores, and delivery APIs. Report the dependency failure instead of allowing it to masquerade as missing or low-quality AI output. For Azure resources that support Microsoft Entra authentication, managed identities reduce the secrets that an application must store and rotate. Any remaining credentials belong in the execution environment or a secret store, never in prompts, repository content, or job payloads. Try this before production: use an invalid endpoint or unavailable credential. The workflow should stop before expensive work, record a stable dependency reason, and publish no empty artifact. After repair, the new attempt should remain connected to the original request. Lesson 3: Long-running work needs a bounded execution The first hosting path ran translation work through the same long-lived Container App process that served the application. When requests overlapped, the process had to coordinate more than one workspace, more than one translation state, and more memory-intensive work at the same time. Cleanup and failure isolation became harder to reason about. This was not evidence that Azure Container Apps inherently leaks memory. Container Apps can scale continuously available services horizontally. The problem was the execution model: a translation batch has a beginning, an end, and an artifact, while the worker behaved like a continuously running service. Figure 6. Keep the continuously available API in Azure Container Apps and give each finite attempt its own Azure Container Apps Job execution. Retries, cleanup, and admission control still require application policy. Microsoft describes a container app as a continuously running service and a Container Apps Job as a task that starts, performs a finite unit of work, and stops. That made the split clearer. The API and dispatcher could remain in a container app; Figure 2 groups those continuously available application responsibilities as the orchestrator. Each accepted unit of work could start a separate job execution linked to the logical job and attempt IDs. The job definition supplies the container image, resource allocation, timeout, and retry policy. Each execution has its own finite process lifetime, execution identity, status, logs, and an attempt-scoped workspace when the application creates one. A finite process lifetime does not remove the need to control memory or clean temporary files, but it limits how far one failed attempt can spread. Data written to persistent storage still needs an explicit retention and cleanup policy. Bound cost and permissions the same way: cap model usage per attempt, and give the dispatcher, worker, validator, and publisher only the access each one needs. The dispatcher can admit independent requests up to an application-defined limit and deliberately serialize work that might conflict, such as simultaneous updates to the same repository. Container Apps Jobs parallelism controls replicas within one execution. It does not replace request-level admission control. The application should not rely on external side effects happening exactly once. A retry, restart, or lost response can still occur. Attempt ownership, idempotent state transitions, and reconciliation of an existing pull request or downstream record remain application responsibilities. Try this before production: submit two independent requests together. Each should retain its own execution ID, workspace, result, logs, and retry path. Then submit two requests that would update the same downstream resource and confirm that the dispatcher applies the intended serialization policy. Then test the handoffs that fail quietly: submit the same request twice, change the source while an attempt is running, and lose the response after the downstream record is created. The recorded job, input revision, and current attempt owner should lead the workflow to one logical job, no stale output, and no duplicated downstream record. Lesson 4: Make progress visible before the final artifact appears A long-running AI workflow should not force a developer to infer its health from whether a file eventually appears. Without searching raw console logs, a person should be able to answer four questions: Was my request accepted? Is the work still advancing? Where did it stop? What result is waiting for review? The workflow should expose the current attempt, how many units are running, complete, queued, or failed, when progress last changed, and whether a reviewable artifact is ready. Those answers come from a small set of job states. Status should describe evidence, not optimism, so each state names what must be on record before a job can enter it. The following is a reference state model for this design, not a description of Localizeflow's current internal state machine. Here, accepted means the orchestrator has durably recorded the request and accepted it for processing. It does not mean that execution has completed. State What it means Evidence on record accepted The request is stored for processing. Request ID, input revision, scope, policy running A current attempt owns the job. Attempt ID, ownership expiry validating An artifact exists and checks are running. Candidate artifact, checks run so far ready_for_review Validation passed and a reviewable change is available. Validation result, artifact diff failed The latest attempt ended without a valid artifact. Failing stage, stable reason, safe diagnostics superseded A newer request or input revision replaced this job. Link to the replacement approved A person accepted the reviewable change. Reviewer identity, downstream decision record rejected A person declined the reviewable change. Reviewer identity, recorded reason approved and rejected come from the downstream decision, not from the workflow finishing. For failed , name the stage, such as dependency, generation, assembly, validation, or delivery, so the workflow never retries blindly. The Localizeflow progress records in the public pull requests make that distinction concrete. The failed record in Figure 1 exposes partial completion and failed jobs instead of presenting an empty destination as the only symptom. The completed record shown at the end exposes a different state using the same vocabulary. A developer can see that the automation is advancing, stopped, or ready for the next decision without treating a model response as the only signal. Progress is not quality. 19 / 19 completed means that the execution units reported completion; it does not mean every translation is accurate. Operational visibility must connect to artifact validation, a reviewable diff, and the final human decision. The dashboard explains what the workflow is doing. The checks and reviewer decide whether its result is acceptable. Whether the workflow saves time or improves quality needs its own measurements: review time, retries, dependency failures, superseded results, human corrections, and the model, container, and storage resources each run consumes. Collect them before claiming improvement. Try this before production: start a multi-unit request, then fail one worker or make a dependency unavailable. The progress view should stop advancing, identify the failed or blocked unit, preserve the earlier attempt, and lead an operator to the relevant evidence. After a retry, the new attempt should be visible without erasing the old one. Build for the moment after the demo The prototype answered whether a model could perform one task. Production asked a harder question: could the surrounding application explain failure, preserve usable work, reject unsafe output, and return something a person could trust? Translation revealed three failure classes, but the design lesson is broader. A normal model response can still produce a failed artifact. A missing result can be a dependency problem. A finite unit of work becomes easier to isolate when its process lifetime is finite too. Most reliability concerns in an AI workflow are familiar automation concerns: state, retries, dependencies, concurrency, and delivery. What AI adds is a probabilistic boundary. Even when the model call succeeds, its response may be incomplete, structurally invalid, or simply unsuitable for the intended use. A reliable design must therefore validate the artifact, preserve rejected candidates safely, and keep consequential acceptance outside the model. An AI workflow must handle ordinary automation failures and also assume that a successful model call can produce an unacceptable result. A reliable AI workflow connects the accepted request, input version, execution attempt, candidate artifact, validation result, and human decision. When a run fails or the input changes, that chain should explain what happened and what should happen next. Figure 7. The public Localizeflow run record linked from AI Agents for Beginners pull request #790 shows the overall state, all 19 work units complete, no active work, no recovery attempts, and no terminal failures. These fields make execution observable. Review findings still led to follow-up changes before the repository merged the pull request on October 30, 2026. Neither completed progress nor the merge alone proves translation accuracy, time saved, or deployment. That is the purpose of the progress view: make the AI and automation workflow inspectable while it is running, then connect completion to validation and a visible repository decision. A green progress bar is useful evidence, but it becomes trustworthy only as part of that larger chain. Start with one input, one expected artifact, and one downstream decision: in the translation example, one document, one language, and one test repository. Prove that one valid run stops at ready_for_review and waits for a person, then widen the scope. Track the work, preserve the evidence, validate the result, and return something a person can inspect.Foundry Toolbox Lifecycle: Deploy and Promote
Foundry Toolbox Lifecycle: Deploy and Promote For developers looking to manage Microsoft Foundry tools across agents, this article presents one recommended pattern: define each Toolbox in its own azure.yaml , deploy it separately from project infrastructure and agents, and pass environment-specific Bicep outputs through GitHub Actions. Why Manage a Foundry Toolbox Separately? Organizations are integrating agent development into established software development lifecycles, raising questions about how teams govern and reuse tools. In this post, a “tool” means an external capability an agent invokes such as web search, a tool exposed by a Model Context Protocol (MCP) server, or a third-party application. Tools let agents retrieve live data or take actions in external systems. How can teams avoid rebuilding the same integrations? Microsoft Foundry Toolbox offers a shared way to manage tools. This post explores how to structure Toolbox ownership and deployment so a reusable collection doesn’t become a Toolshed. What Is a Microsoft Foundry Toolbox? A Toolbox in Foundry is a versioned collection of tools exposed through a single MCP-compatible endpoint. It is created in the context of a Foundry Project, and agents connect to that endpoint to use its tools. Microsoft’s Toolbox overview describes a way to define shared tools once and expose them through a single MCP-compatible endpoint. It centralizes tool access, credentials, governance, and versioning so teams can reuse approved tools across agents without rebuilding each integration. Instead of embedding a separate Web IQ integration in every Finance agent, teams can configure Web IQ once in a shared Toolbox. Each agent then connects to the Toolbox’s MCP endpoint and invokes the tools it exposes. The Toolbox and its project connections provide the shared configuration and credentials. Should a Toolbox Be Deployed with an Agent? Foundry examples show toolboxes created through SDKs and consumed by agents. The key design decision is which deployment lifecycle owns toolbox version changes. When multiple agents share a toolbox, manage its versions separately from any one agent’s deployment. A Foundry Project can contain zero or more agents. Agent deployments should be idempotent and managed independently. An agent’s availability should not depend on another agent. A Toolbox has its own lifecycle and versioning. A Toolbox lives outside any single agent, within a Foundry Project. Creating a toolbox with the Python SDK does not, by itself, make the toolbox part of an agent; the SDK call creates a version in the Foundry Project. The coupling arises when the agent’s deployment pipeline also owns and publishes that toolbox. To keep the lifecycles independent, manage toolbox versions through a project-level pipeline and have agents consume the toolbox endpoint. This avoids redeploying an unrelated agent for toolbox changes and avoids making shared tool availability depend on one agent’s lifecycle. Provision the Project, Then Deploy the Toolbox A Foundry project is provisioned as an Azure resource (`Microsoft.CognitiveServices/accounts/projects`), while toolbox versions are created through the Foundry project API. In this deployment pattern, we need to provision the project and any required connections first, then create and deploy the toolbox using the project endpoint. See the toolbox version API reference for details. The Foundry project and its project-level role-based access control (RBAC) and connections are infrastructure prerequisites that can be managed with infrastructure as code (IaC). The toolbox version is then created in a separate deployment step using the project endpoint, with environment-specific values supplied as Bicep outputs. This keeps the Toolbox alongside the project’s lifecycle without coupling it to any one agent. Where to Store the Toolbox Configuration Like the Foundry Project, a Toolbox is shared across agents and should follow the project’s lifecycle rather than an individual agent’s lifecycle. Store its definition alongside the project’s IaC and include its deployment in the project-level infrastructure workflow. Create a separate folder and `azure.yaml` for each Toolbox. This gives each Toolbox its own deployment step and `azd` environment, so teams can deploy, update, and version Toolboxes independently without coupling their release cycles. This post uses that structure to make each Toolbox’s lifecycle explicit. Foundry Toolbox Versioning and Promotion Foundry stores each Toolbox version as an immutable snapshot of its configuration. Changes create a new version rather than modifying an existing one. The first version becomes the default automatically; subsequent versions must be promoted explicitly. See Foundry Toolbox version managementfor details. Agents using the Toolbox’s stable consumer endpoint receive the default version. Developers can use a version specific endpoint to validate changes before promotion. Promoting a version changes what the consumer endpoint serves without requiring a rebuild and deploy of the agents code. To roll back, promote a previously retained version. Foundry provides these versioning and promotion capabilities, but the team still decides how changes are tested, approved, retained, and retired. A version captures Toolbox configuration not a frozen copy of the external services it calls—so rolling back the Toolbox does not necessarily reverse downstream service changes. i.e. changes that were made to tools of a custom downstream MCP server. Teams can remove older or unwanted versions after confirming they aren’t needed for rollback or used through version specific endpoints. If multiple versions exist, promote another version before deleting the current default. When using `azd`, deleting the only remaining version also removes the Toolbox. One important connection to our example: its `postdeploy` hook promotes immediately. We should distinguish that sample behavior from a production process that validates a candidate version before promotion. Deploy a Foundry Toolbox with GitHub Actions In this example, the Toolbox is deployed as a separate step in the same GitHub Actions workflow, after the Bicep deployment provisions the Foundry Project. This lets the workflow populate the Toolbox’s `azd` environment with the infrastructure outputs before deployment. You can also split the deployments across jobs or workflows, provided the Toolbox step receives the required outputs and runs after its prerequisites are ready. Prerequisites Foundry Project and region: Create the Foundry Project and any project connections required by the Toolbox before deployment. Confirm that the target region supports the Toolbox’s tool types and models using the tool support by region and model table Identity and access: Configure GitHub Actions to authenticate to Azure using OpenID Connect (OIDC), as in the linked sample. The identity that creates or updates Toolbox versions needs the Foundry User role on the project (Toolbox prerequisites). If the same workflow deploys Bicep, that identity also needs permission to deploy the template’s resources and create its role assignments at the applicable scopes. Tooling: Install Azure Developer CLI 1.37.0+, as required by the unified `microsoft.foundry` extension. Install the extension with `azd ext install microsoft.foundry`, following the Foundry extension installation guidance. The linked sample pins `azd` 1.37.1 and installs `azure.ai.toolboxes` separately. Configuration Provide the project endpoint, environment name, location, and every downstream endpoint or connection name referenced by the Toolbox’s `azure.yaml`. Create the required Foundry project connections before deploying the Toolbox. Configure credentials on those connections or in an approved secret store, not in Bicep outputs; see Toolbox authentication. - name: Deploy and promote the toolbox working-directory: foundation/toolboxes/fibey-toolbox env: AZURE_ENV_NAME: ${{ steps.infrastructure.outputs.AZURE_ENV_NAME }} FOUNDRY_PROJECT_ENDPOINT: ${{ steps.infrastructure.outputs.FOUNDRY_PROJECT_ENDPOINT }} AZURE_AI_PROJECT_ENDPOINT: ${{ steps.infrastructure.outputs.AZURE_AI_PROJECT_ENDPOINT }} run: | azd deploy fibey-toolbox --no-prompt The infrastructure deployment should expose the values the Toolbox needs as outputs—in this case, Bicep outputs. The linked sample uses `AZURE_ENV_NAME`, `AZURE_LOCATION`, `FOUNDRY_PROJECT_ENDPOINT`, and `AZURE_AI_PROJECT_ENDPOINT` for the deployment context. Its Toolbox configuration also consumes `INVENTORY_MCP_URL`, `WORK_ORDERS_API_URL`, `KB_MCP_URL`, and `KB_CONNECTION_NAME`. Expose the corresponding values for each target environment and region. The Toolbox’s `azure.yaml` references the imported values, so the same definition can be reused across environments and regions. For each target, provide that target’s infrastructure outputs instead of manually changing endpoint values, and confirm that the required services and tools are supported in the target region. The example references `steps.infrastructure.outputs` because the infrastructure and Toolbox deployment steps run in the same GitHub Actions job. If they run in separate jobs, expose the required values as job outputs and consume them through `needs`. This keeps the deployments connected without tying their release cycles together: infrastructure provides the deployment context, and the Toolbox consumes it. Keep credentials in managed identities or approved secret stores rather than ordinary deployment outputs. The complete workflow demonstrates authentication, infrastructure outputs, and environment initialization. Its extension-install step currently uses `azure.ai.toolboxes`; replace that step with `azd ext install microsoft.foundry` when following the current Learn guidance above. Version promotion is handled by the `postdeploy` hook in the Toolbox’s `azure.yaml`. Verify Toolbox Deployment and Promotion The sample’s `postdeploy` hook promotes the deployed version to the default and checks that promotion succeeded. Redeploying an unchanged Toolbox definition does not create a new version. To inspect the versions and confirm which one is default, run: azd ai toolbox versions list fibey-toolbox The default version is marked with `*`. This confirms which version is default, but not that its tools work. For runtime verification, follow the Toolbox verification guidance to initialize MCP and list tools using the version-specific endpoint. Test a tool call only with a safe, read-only operation. The developer needs the Foundry User role on the project; prompt-agent and OAuth scenarios can require additional permissions for the agent identity or end user. Troubleshooting If deployment or promotion fails, check that the deployment identity has the required project role, that the project endpoint and Toolbox configuration values were supplied, and that the required project connections and tools are available in the target region. Conclusion Toolbox provides a shared way to manage tools across agents without tying their lifecycle to any one agent. Keeping toolbox definitions alongside your Foundry Project infrastructure, while deploying them as a separate step, lets teams update and version tools independently while retaining a clear dependency on the project. As your organization adopts this pattern, consider who owns each toolbox, how changes are tested and promoted, and who can access its tools. That governance will help keep a useful Toolbox from becoming a Toolshed.306Views0likes0CommentsThe GitHub app in Microsoft Teams is now generally available!
GitHub empowers any team to become builders in Microsoft Teams. Customer support teams are using GitHub to turn customer feedback from Teams channels into filed issues. Engineering teams are asking GitHub to investigate, reproduce, and fix bugs without leaving Teams. Business and marketing teams with innovative ideas are asking GitHub to turn their discussions into working prototypes. During public preview, our team has been hard at work addressing feedback and making product improvements to the GitHub experience in Teams. Here is what’s new. Review work in the GitHub Canvas The new GitHub canvas lets you review the plan, file changes, and pull request without leaving Teams. Click “Open Canvas” to follow GitHub Copilot’s progress and see your team’s ideas take shape in code, right beside the conversation. Go from notification to pull request in one app GitHub notifications and GitHub Copilot now live in a single app in Teams called GitHub. Stay on top of issue and pull request updates and act on them right in Teams. When an update needs attention, reply to the notification with "@GitHub". GitHub Copilot can investigate, make the fix, and draft a pull request in the same thread, so your team sees the update and the response together. Issues and pull requests created from Teams now carry attribution. Reviewers can see who started the work and link back to the Teams conversation where it was discussed. Work across repositories and tools Real work rarely lives in one repository. With multi-repo support, GitHub Copilot can work across all the repositories your task needs in the same conversation. In addition, MCP support lets you configure which tools and connected services GitHub can leverage in Teams. Learn more about configuring MCP. Get set up in a guided experience The new guided web onboarding experience helps you sign in through your default browser using saved passwords or passkeys and grant Teams access to the right organizations and repositories. You can now use natural language to ask GitHub to use a default repository or switch repositories in your Teams conversations. You can also choose the model GitHub Copilot uses for a task. Pick a faster model for quick fixes or a more capable model for larger changes. Get started today Add the GitHub app to Teams today, then click “Get started” from its welcome message to connect your account. Type "@GitHub help" to see what else it can do. Admins should verify the following are enabled for users to get started: Microsoft 365 admins: ensure resource-specific consent is enabled so users can let the GitHub app use conversation context. TAC admins: ensure the GitHub app is allowed for users in the Teams admin center. GitHub enterprise admins: ensure Copilot cloud agent, cloud sandboxes, and CLI billing are enabled for each organization and assign GitHub Copilot licenses to users. Learn more at teams.github.com! We'd love to hear what you build. Share your feedback in the comments below.2.5KViews1like0CommentsTurn GitHub notifications into code with GitHub Copilot in Microsoft Teams
GitHub can now bring repository updates into a channel, group chat, or private chat. When an update needs action, reply to the notification and @mention GitHub with the task you want GitHub Copilot to carry out. GitHub Copilot uses the issue or pull request linked in the notification and the conversation in the thread to understand the task. It can reproduce a bug, run tests, implement a fix, and prepare a pull request for review. Turn an issue notification into a pull request If the player doesn’t load, open the video in a new window: Open video For a bug report, the workflow starts in the notification thread: A GitHub Issue notification arrives in a Teams channel with a link to the reported bug. You @mention GitHub to investigate the issue and prepare a proposed fix in a pull request. The team reviews the pull request, iterates with GitHub Copilot, tests the proposed changes, and decides whether to merge. Starting from the linked issue and thread lets your team delegate the work to GitHub Copilot without rebuilding the request from scratch. The same workflow can be used to implement a feature, expand test coverage, update documentation, and more. Product and engineering teams at Microsoft are already leveraging the GitHub app in Teams to build products today. Get started Explore the new GitHub app in Microsoft Teams (previously called GitHub Notifications). If you already have GitHub Notifications installed, update the app to the latest version. The legacy GitHub app will be renamed “GitHub (deprecated)” and retired on November 16. Learn more at teams.github.com! Turn the updates your team follows into code your team can review.1.3KViews2likes0CommentsBuild an AI-Powered Space Invaders Game
Build an AI-Powered Space Invaders Game: Integrating LLMs into HTML5 Games with Microsoft Foundry Local Introduction What if your game could talk back to you? Imagine playing Space Invaders while an AI commander taunts you during battle, delivers personalized mission briefings, and provides real-time feedback based on your performance. This isn't science fiction it's something you can build today using HTML, JavaScript, and a locally-running AI model. In this tutorial, we'll explore how to create an HTML5 game with integrated Large Language Model (LLM) features using Microsoft Foundry Local. You'll learn how to combine classic game development with modern AI capabilities, all running entirely on your own machine—no cloud services, no API costs, no internet connection required during gameplay. We'll be working with the Space Invaders - AI Commander Edition project, which demonstrates exactly how to architect games that leverage local AI. Whether you're a student learning game development, exploring AI integration patterns, or building your portfolio, this guide provides practical, hands-on experience with technologies that are reshaping how we build interactive applications. What You'll Learn By the end of this tutorial, you'll understand how to combine traditional web development with local AI inference. These skills transfer directly to building chatbots, interactive tutorials, AI-enhanced productivity tools, and any application where you want intelligent, context-aware responses. Set up Microsoft Foundry Local for running AI models on your machine Understand the architecture of games that integrate LLM features Use GitHub Copilot CLI to accelerate your development workflow Implement AI-powered game features like dynamic commentary and adaptive feedback Extend the project with your own creative AI features Why Local AI for Games? Before diving into the code, let's understand why running AI locally matters for game development. Traditional cloud-based AI services have limitations that make them impractical for real-time gaming experiences. Latency is the first challenge. Cloud API calls typically take 500ms to several seconds, an eternity in a game running at 60 frames per second. Local inference can respond in tens of milliseconds, enabling AI responses that feel instantaneous and natural. When an enemy ship appears, your AI commander can taunt you immediately, not three seconds later. Cost is another consideration. Cloud AI services charge per token, which adds up quickly when generating dynamic content during gameplay. Local models have zero per-use cost, once installed, they run entirely on your hardware. This frees you to experiment without worrying about API bills. Privacy and offline capability complete the picture. Local AI keeps all data on your machine, perfect for games that might handle player information. And since nothing requires internet connectivity, your game works anywhere, on planes, in areas with poor connectivity, or simply when you want to play without network access. Understanding Microsoft Foundry Local Microsoft Foundry Local is a runtime that enables you to run small language models (SLMs) directly on your computer. It's designed for developers who want to integrate AI capabilities into applications without requiring cloud infrastructure. Think of it as having a miniature AI assistant living on your laptop. Foundry Local handles the complex work of loading AI models, managing memory, and processing inference requests through a simple API. You send text prompts, and it returns AI-generated responses, all happening locally on your CPU or GPU. The models are optimized to run efficiently on consumer hardware, so you don't need a supercomputer. For our Space Invaders game, Foundry Local powers the "AI Commander" feature. During gameplay, the game sends context about what's happening, your score, accuracy, current level, enemies remaining and receives back contextual commentary, taunts, and encouragement. The result feels like playing alongside an AI companion who actually understands the game. Setting Up Your Development Environment Let's get your machine ready for AI-powered game development. We'll install Foundry Local, clone the project, and verify everything works. The entire setup takes about 10-15 minutes. Step 1: Install Microsoft Foundry Local Foundry Local installation varies by operating system. Open your terminal and run the appropriate command: # Windows (using winget) winget install Microsoft.FoundryLocal # macOS (using Homebrew) brew install microsoft/foundrylocal/foundrylocal These commands download and install the Foundry Local runtime along with a default small language model. The installation includes everything needed to run AI inference locally. Verify the installation by running: foundry --version If you see a version number, Foundry Local is ready. If you encounter errors, ensure you have administrator/sudo privileges and that your package manager is up to date. Step 2: Install Node.js (If Not Already Installed) Our game's AI features require a small Node.js server to communicate between the browser and Foundry Local. Check if Node.js is installed: node --version If you see a version number (v16 or higher recommended), you're set. Otherwise, install Node.js: # Windows winget install OpenJS.NodeJS.LTS # macOS brew install node # Linux sudo apt install nodejs npm Node.js provides the JavaScript runtime that powers our proxy server, bridging browser code with the local AI model. Step 3: Clone the Project Get the Space Invaders project onto your machine: git clone https://github.com/leestott/Spaceinvaders-FoundryLocal.git cd Spaceinvaders-FoundryLocal This downloads all game files, including the HTML interface, game logic, AI integration module, and server code. Step 4: Install Dependencies and Start the Server Install the Node.js packages and launch the AI-enabled server: npm install npm start The first command downloads required packages (primarily for the proxy server). The second starts the server, which listens for AI requests from the game. You should see output indicating the server is running on port 3001. Step 5: Play the Game Open your browser and navigate to: http://localhost:3001 You should see Space Invaders with "AI: ONLINE" displayed in the game HUD, indicating that AI features are active. Use arrow keys or A/D to move, SPACE to fire, and P to pause. The AI Commander will start providing commentary as you play! Understanding the Project Architecture Now that the game is running, let's explore how the different pieces fit together. Understanding this architecture will help you modify the game and apply these patterns to your own projects. The project follows a clean separation of concerns, with each file handling a specific responsibility: Spaceinvaders-FoundryLocal/ ├── index.html # Main game page and UI structure ├── styles.css # Retro arcade visual styling ├── game.js # Core game logic and rendering ├── llm.js # AI integration module ├── sound.js # Web Audio API sound effects ├── server.js # Node.js proxy for Foundry Local └── package.json # Project configuration index.html: Defines the game canvas and UI elements. It's the entry point that loads all other modules. game.js: Contains the game loop, physics, collision detection, scoring, and rendering logic. This is the heart of the game. llm.js: Handles all communication with the AI backend. It formats game state into prompts and processes AI responses. server.js: A lightweight Express server that proxies requests between the browser and Foundry Local. sound.js: Synthesizes retro sound effects using the Web Audio API—no audio files needed! How the AI Integration Works The magic of the AI Commander happens through a simple but powerful pattern. Let's trace the flow from gameplay event to AI response. When something interesting happens in the game, you clear a wave, achieve a combo, or lose a life, the game logic in game.js triggers an AI request. This request includes context about the current game state: your score, accuracy percentage, current level, lives remaining, and what just happened. The llm.js module formats this context into a prompt. For example, when you clear a wave with 85% accuracy, it might construct: You are an AI Commander in a Space Invaders game. The player just cleared wave 3 with 85% accuracy. Score: 12,500. Lives: 3. Provide a brief, enthusiastic comment (1-2 sentences). This prompt travels to server.js , which forwards it to Foundry Local. The AI model processes the prompt and generates a response like: "Impressive accuracy, pilot! Wave 3 didn't stand a chance. Keep that trigger finger sharp!" The response flows back through the server to the browser, where llm.js passes it to the game. The game displays the message in the HUD, creating the illusion of playing alongside an AI companion. This entire round trip typically completes in 50-200 milliseconds, fast enough to feel responsive without interrupting gameplay. Using GitHub Copilot CLI to Explore and Modify the Code GitHub Copilot CLI accelerates your development workflow by letting you ask questions and generate code directly in your terminal. Let's use it to understand and extend the Space Invaders project. Installing Copilot CLI If you haven't installed Copilot CLI yet, here's the quick setup: # Install GitHub CLI winget install GitHub.cli # Windows brew install gh # macOS # Authenticate with GitHub gh auth login # Add Copilot extension gh extension install github/gh-copilot # Verify installation gh copilot --help With Copilot CLI ready, you can interact with AI directly from your terminal while working on the project. Exploring Code with Copilot CLI Use Copilot to understand unfamiliar code. Navigate to the project directory and try: gh copilot explain "How does llm.js communicate with the server?" Copilot analyzes the code and explains the communication pattern, helping you understand the architecture without reading every line manually. You can also ask about specific functions: gh copilot explain "What does the generateEnemyTaunt function do?" This accelerates onboarding to unfamiliar codebases, a valuable skill when working with open source projects or joining teams. Generating New Features Want to add a new AI feature? Ask Copilot to help generate the code: gh copilot suggest "Create a function that asks the AI to generate a mission briefing at the start of each level, including the level number and a random mission objective" Copilot generates starter code that you can customize and integrate. This combination of AI-powered development tools and AI-integrated gameplay demonstrates how LLMs are transforming both how we build games and how games behave. Customizing the AI Commander The default AI Commander provides generic gaming commentary, but you can customize its personality and responses. Open llm.js to find the prompt templates that control AI behavior. Changing the AI's Personality The system prompt defines who the AI "is." Find the base prompt and modify it: // Original const systemPrompt = "You are an AI Commander in a Space Invaders game."; // Customized - Drill Sergeant personality const systemPrompt = `You are Sergeant Blaster, a gruff but encouraging drill sergeant commanding space cadets. Use military terminology, call the player "cadet," and be tough but fair.`; // Customized - Supportive Coach personality const systemPrompt = `You are Coach Nova, a supportive and enthusiastic gaming coach. Use encouraging language, celebrate small victories, and provide gentle guidance when players struggle.`; These personality changes dramatically alter the game's feel without changing any gameplay code. It's a powerful example of how AI can add variety to games with minimal development effort. Adding New Commentary Triggers Currently the AI responds to wave completions and game events. You can add new triggers in game.js : // Add AI commentary when player achieves a kill streak if (killStreak >= 5 && !streakCommentPending) { requestAIComment('killStreak', { count: killStreak }); streakCommentPending = true; } // Add AI reaction when player narrowly avoids death if (nearMissOccurred) { requestAIComment('nearMiss', { livesRemaining: lives }); } Each new trigger point adds another opportunity for the AI to engage with the player, making the experience more dynamic and personalized. Understanding the Game Features Beyond AI integration, the Space Invaders project demonstrates solid game development patterns worth studying. Let's explore the key features. Power-Up System The game includes eight different power-ups, each with unique effects: SPREAD (Orange): Fires three projectiles in a spread pattern LASER (Red): Powerful beam with high damage RAPID (Yellow): Dramatically increased fire rate MISSILE (Purple): Homing projectiles that track enemies SHIELD (Blue): Grants an extra life EXTRA LIFE (Green): Grants two extra lives BOMB (Red): Destroys all enemies on screen BONUS (Gold): Random score bonus between 250-750 points Power-ups demonstrate state management, tracking which power-up is active, applying its effects to player actions, and handling timeouts. Study the power-up code in game.js to understand how temporary state modifications work. Leaderboard System The game persists high scores using the browser's localStorage API: // Saving scores localStorage.setItem('spaceInvadersScores', JSON.stringify(scores)); // Loading scores const savedScores = localStorage.getItem('spaceInvadersScores'); const scores = savedScores ? JSON.parse(savedScores) : []; This pattern works for any data you want to persist between sessions—game progress, user preferences, or accumulated statistics. It's a simple but powerful technique for web games. Sound Synthesis Rather than loading audio files, the game synthesizes retro sound effects using the Web Audio API in sound.js . This approach has several benefits: no external assets to load, smaller project size, and complete control over sound parameters. Examine how oscillators and gain nodes combine to create laser sounds, explosions, and victory fanfares. This knowledge transfers directly to any web project requiring audio feedback. Extending the Project: Ideas for Students Ready to make the project your own? Here are ideas ranging from beginner-friendly to challenging, each teaching valuable skills. Beginner: Customize Visual Theme Modify styles.css to create a new visual theme. Try changing the color scheme from green to blue, or create a "sunset" theme with orange and purple gradients. This builds CSS skills while making the game feel fresh. Intermediate: Add New Enemy Types Create a new enemy class in game.js with different movement patterns. Perhaps enemies that move in sine waves, or boss enemies that take multiple hits. This teaches object-oriented programming and game physics. Intermediate: Expand AI Interactions Add new AI features like: Pre-game mission briefings that set up the story Dynamic difficulty hints when players struggle Post-game performance analysis and improvement suggestions AI-generated names for enemy waves Advanced: Multiplayer Commentary Modify the game for two-player support and have the AI provide play-by-play commentary comparing both players' performance. This combines game networking concepts with advanced AI prompting. Advanced: Voice Integration Use the Web Speech API to speak the AI Commander's responses aloud. This creates a more immersive experience and demonstrates browser speech synthesis capabilities. Troubleshooting Common Issues If something isn't working, here are solutions to common problems. "AI: OFFLINE" Displayed in Game This means the game can't connect to the AI server. Check that: The server is running ( npm start shows no errors) You're accessing the game via http://localhost:3001 , not directly opening the HTML file Foundry Local is installed correctly ( foundry --version works) Server Won't Start If npm start fails: Ensure you ran npm install first Check that port 3001 isn't already in use by another application Verify Node.js is installed ( node --version ) AI Responses Are Slow Local AI performance depends on your hardware. If responses feel sluggish: Close other resource-intensive applications Ensure your laptop is plugged in (battery mode may throttle CPU) Consider that first requests may be slower as the model loads Key Takeaways Local AI enables real-time game features: Microsoft Foundry Local provides fast, free, private AI inference perfect for gaming applications Clean architecture matters: Separating game logic, AI integration, and server code makes projects maintainable and extensible AI personality is prompt-driven: Changing a few lines of prompt text completely transforms how the AI interacts with players Copilot CLI accelerates learning: Use it to explore unfamiliar code and generate new features quickly The patterns transfer everywhere: Skills from this project apply to chatbots, assistants, educational tools, and any AI-integrated application Conclusion and Next Steps You've now seen how to integrate AI capabilities into a browser-based game using Microsoft Foundry Local. The Space Invaders project demonstrates that modern AI features don't require cloud services or complex infrastructure, they can run entirely on your laptop, responding in milliseconds. More importantly, you've learned patterns that extend far beyond gaming. The architecture of sending context to an AI, receiving generated responses, and integrating them into user experiences applies to countless applications: customer support bots, educational tutors, creative writing tools, and accessibility features. Your next step is experimentation. Clone the repository, modify the AI's personality, add new commentary triggers, or build an entirely new game using these patterns. The combination of GitHub Copilot CLI for development assistance and Foundry Local for runtime AI gives you powerful tools to bring intelligent applications to life. Start playing, start coding, and discover what you can create when your games can think. Resources Space Invaders - AI Commander Edition Repository - Full source code and documentation Play Space Invaders Online - Try the basic version without AI features Microsoft Foundry Local Documentation - Official installation and API guide GitHub Copilot CLI Documentation - Installation and usage guide GitHub Education - Free developer tools for students Web Audio API Documentation - Learn about browser sound synthesis Canvas API Documentation - Master HTML5 game rendering1.3KViews0likes3CommentsTurn conversations into code with GitHub Copilot in Microsoft Teams
Coding where context lives and collaboration happens The best prompt may be the conversation your team has already had or is currently having. Until now, using a coding agent often meant paying context and coordination taxes. Developers had to leave the discussion, open another tool, and reconstruct the problem in a lengthy prompt: what happened, what the team decided, which constraints matter, and what needs to be built. With GitHub Copilot in Teams, teams can move directly from conversation to action. @mention GitHub Copilot when the team is ready to act, and it can use the conversation alongside repository context to understand the request, implement the change, and create a pull request for review. This makes working with a coding agent more collaborative and visible. Instead of one developer privately reconstructing the request, teammates can contribute context, correct assumptions, refine the approach in real time, and review the resulting work together. Let’s explore the new GitHub Copilot in Teams experience to see how it can streamline development tasks: If the player doesn’t load, open the video in a new window: Open video GitHub Copilot in Teams is available in Teams channels, group chats, meeting chats, and 1:1 chats. Once the GitHub app is installed and added to the conversation, @-mention GitHub Copilot to bring it into the discussion and start a task. During public preview, users can complete the following scenarios with GitHub Copilot in Teams: Build a feature based on requirements discussed in Teams Implement a fix for a bug Expand test coverage or improve documentation Create and update a pull request No copying the discussion into a CLI. No rewriting it in a desktop app. No asking one developer to translate a team decision into the perfect prompt. GitHub Copilot works where the context already lives, and because that context is shared, working with GitHub Copilot becomes a team activity. Built around the controls teams already use GitHub Copilot in Teams works within existing GitHub permissions and repository policies. Branch protections and required reviews continue to apply, and people remain responsible for deciding what gets merged, ensuring that humans stay in the loop at every step. Availability GitHub Copilot in Teams is now available in Public Preview. To try it, install the GitHub app for Microsoft Teams and check out our documentation to get started! Less context reconstruction. More progress from the conversations already happening.5.3KViews0likes1CommentModel router updates: new regions, a refreshed model pool, and understanding the hill climb
Across Microsoft, "hill climbing" has become shorthand for how real AI progress happens: not in one dramatic leap, but through a disciplined loop. Microsoft AI defines the hill climb as an organization that continuously improves, cycle after cycle, through more compute, better data, and sharper evaluation. Reinforcement fine-tuning in Foundry defines it as improving the deployable model package one measured step at a time across quality, latency, and cost. Different altitudes, same premise: progress is not a one-shot decision. It's a loop. For most teams, the decision of what model to use when is made manually or with custom routing tools. A developer picks a model based on benchmarks, familiarity, or the last launch that made headlines, ships it, and revisits the choice only when something breaks. In an ecosystem where the frontier moves monthly, that decision goes stale fast. Model router in Foundry Models brings the hill climb to the selection layer. What's new: a bigger pool, in more places This release expands where teams can deploy model router, broaden the supported model pool, and delivers updates through a stable endpoint. Together, these changes help teams run production workloads in more locations, match a wider range of tasks to suitable models, and adopt supported updates without changing the application integration. A refreshed model pool. The supported model list now includes Anthropic Claude Opus 4.8 — a high-capability model built for complex reasoning and long-form generation, for scenarios that demand depth, structure, and quality — and the GPT-5.6 family. Just as importantly, the pool is pruned: gpt-5-chat, gpt-5.2-chat, gpt-5.3-chat, Deepseek-V3.1 have been removed from the model router as models reach the end of their lifecycle and are deprecated in Foundry. New region availability. The model router is now available in 28 regions for global standard and 21 data zone regions. For many organizations, inference requests must stay within specific geographic boundaries for regulatory, governance, or customer-trust reasons — and intelligent routing shouldn't force a compromise on that. Find the full list of regions here. The most important detail is what you don't have to do: these updates occur automatically*. The endpoint remains stable as the supported model pool is refreshed, so teams do not need to redeploy the model router to receive the update. Applications can continue using the same integration while the model router evaluates requests against the current supported pool. Teams should continue monitoring routing traces and application outcomes to confirm that quality, cost, latency, and governance requirements are met. *Models from Anthropic still need to be deployed separately before they can be routed to through the model router. Interested in hearing more about what's new to the model router? Tune in for the next episode of Model Mondays with Sanjeev Jagtap and Lee Stott, where they talk all things model router from evaluations to hill climbing. Sign up here to watch live or view the replay: Model Mondays - Spotlight On Model router in Microsoft Foundry | Microsoft Reactor The selection-layer hill climb At the selection layer, a step is a routing decision. Each one is a micro-optimization against your objective, and each one is instrumented: every response from the model router includes a model field showing which underlying model was selected, so the climb leaves a complete, auditable trail. Model router supports three parts of the optimization loop: A/B testing to compare two router configurations to understand quality, cost, and latency tradeoffs; model decomposition to use routing results to decompose a single-model application into a multi-model or multi-agent design, and continuous routing to keep the router in production for continuous per-request selection. Each pattern turns model choice into a measured, repeatable process rather than a fixed decision. 1. A/B Testing Question: Which model or routing strategy should I use in production? A/B testing helps teams compare candidate models, model families, or router configurations against the same workload. Representative traffic is sent to competing deployments, and teams compare quality, cost, latency, and governance outcomes. The goal is to understand tradeoffs and identify the model or routing strategy that best meets workload requirements before promoting it to production. 2. Model Decomposition Question: What work is my application actually doing? Model decomposition uses model router as a diagnostic tool. By deploying the model router against a representative workload and examining routing telemetry, teams can see how requests naturally separate into different task classes. Simple retrieval, classification, and summarization requests may route to smaller models, while reasoning, planning, and agentic workflows may require more capable models. The goal is not to choose a winner, but to understand the structure of the workload and uncover opportunities for optimization, specialization, or architectural improvements. 3. Route continuously Question: Why choose a single model at all? Route continuously is the pattern model router was designed for but is not limited to. Rather than treating model selection as a one-time decision, teams leave the model router in production and allow the best-fit model to be selected for each request. As the supported model pool, regional availability, and platform capabilities evolve, teams can continue using the same endpoint while evaluating whether updates improve workload outcomes. Model selection becomes an ongoing optimization process rather than a project that must be repeated every time the model landscape changes. Together, these patterns illustrate a broader shift: the model router is more than a model. It is a tool for the optimization loop itself, helping teams evaluate tradeoffs, understand workload behavior, test hypotheses, and continuously refine model selection as requirements evolve. Whether used to compare candidate models, decompose applications into specialized tasks, or automate per-request routing in production, model router turns model selection into an observable, measurable, and repeatable process. As the model landscape continues to change, that optimization loop becomes a durable advantage. Getting Started Ready to start your own hill climb? Whether you're exploring the model router for the first time, evaluating routing strategies against your workload, or building a long-term optimization practice, these resources can help you move from experimentation to production with Microsoft Foundry. What's new in model router? Sign up for the next Model Mondays episode for a deep dive into new features, optimization patterns, and the latest model router updates. How do I build agents with model router? Check out the Model Router Agents Lab and build agent experiences with routing, retrieval, web search, tool calling, and multi-agent patterns. How do I evaluate model router? Compare model router against baseline models using your own prompts, then review quality, cost, latency, and routing decisions with the Auto Evaluation Toolkit. How do I optimize model router for my workload? Start your hill-climbing journey with the Model Mastery workshop, where you'll test one optimization lever at a time and measure how each change impacts workload outcomes. How do I build a model router optimization playbook? Explore the Model Releases repository to track new capabilities, understand the optimization question behind each release, and try focused notebooks that demonstrate one optimization lever at a time.3KViews2likes0Comments