docs: unify Foundry agent configuration in azure.yaml#8560
Open
huimiu wants to merge 7 commits into
Open
Conversation
Records the agreed direction from #7962: consolidate agent.yaml / agent.manifest.yaml into azure.yaml, split agent-scoped vs project-scoped config across host: azure.ai.agent and the new host: azure.ai.project, and capture the locked decisions, open provision/deploy boundary questions, core impact, and alternatives considered. Refs #7962
Remove the Consequences and Alternatives Considered sections (impact is already well understood by reviewers) so the ADR focuses on proposing the final azure.yaml shape, and add a standalone illustrative example file referenced from the ADR. Refs #7962
…ng-image example - container.resources (cpu/memory) is part of the Foundry create-agent API for both code-deploy and container/image agents (defaults cpu:1, memory:2Gi), so it stays in the agent config regardless of deploy source — corrected in the ADR and shown in the code-deploy example. - Add a third deploy source: existing pre-built image via the top-level image: field (e.g. ACR), mutually exclusive with docker:/runtime:, with an example variant in the sample azure.yaml. Refs #7962
Add two commented brownfield variants to the example azure.yaml: existing project + reuse existing model, and existing project + create a new model deployment. Both use the resourceId: field from the Bicep-less RFC (#8065, Phase 2), clearly noted as such. ADR prose updated to reference them. Refs #7962
Replace the single combined example with five self-contained files under docs/architecture/azure-yaml-examples/ (code-deploy, container-build, existing-image, brownfield-existing-model, brownfield-new-model) and index them from the ADR with a scenario table. Refs #7962
🔗 Linked Issue RequiredThanks for the contribution! Please link a GitHub issue to this PR by adding |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds an Architecture Decision Record (ADR) proposing a unified, azure.yaml-only configuration model for Foundry agent projects, along with illustrative end-state azure.yaml examples that demonstrate the proposed schema across common scenarios.
Changes:
- Adds a Proposed ADR documenting decisions and phasing for consolidating
azure.ai.agentsconfiguration intoazure.yamlviahost: azure.ai.agent+ newhost: azure.ai.project. - Adds five scenario-based
azure.yamlexamples showingruntime:(code/zip deploy),docker:(Dockerfile build), andimage:(pre-built image) deployment sources. - Documents brownfield patterns via a proposed
resourceId:field and references related RFC/issues for Phase 2.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| docs/architecture/adr-unify-foundry-agent-config.md | Proposed ADR capturing the decision to split agent runtime vs project-scoped Foundry resources across two host kinds in azure.yaml. |
| docs/architecture/azure-yaml-examples/code-deploy.yaml | Example showing code/zip deploy via a typed runtime: { stack, version } block plus project-scoped resources. |
| docs/architecture/azure-yaml-examples/container-build.yaml | Example showing container mode via docker: build configuration. |
| docs/architecture/azure-yaml-examples/existing-image.yaml | Example showing image-only deploy via top-level image: with no build step. |
| docs/architecture/azure-yaml-examples/brownfield-existing-model.yaml | Brownfield example showing reuse of an existing model deployment and referencing an existing Foundry project. |
| docs/architecture/azure-yaml-examples/brownfield-new-model.yaml | Brownfield example showing creation of a new model deployment against an existing Foundry project. |
Comments suppressed due to low confidence (1)
docs/architecture/adr-unify-foundry-agent-config.md:141
- This ADR omits the
### Consequencesand### Alternatives Consideredsections that are part of the standard ADR template (docs/architecture/adr-template.md). Adding these sections helps readers understand tradeoffs and why this approach was chosen, especially since the status is still Proposed.
### Proposed `azure.yaml` shape
The proposed end-state of `azure.yaml` is captured as standalone, illustrative
examples alongside this ADR, one self-contained file per scenario, under
[`azure-yaml-examples/`](./azure-yaml-examples/):
| Scenario | File | Deploy source |
|---|---|---|
| New project, zip/code-deploy | [`code-deploy.yaml`](./azure-yaml-examples/code-deploy.yaml) | `runtime:` |
| New project, build from Dockerfile | [`container-build.yaml`](./azure-yaml-examples/container-build.yaml) | `docker:` |
| New project, existing pre-built image (ACR) | [`existing-image.yaml`](./azure-yaml-examples/existing-image.yaml) | `image:` |
| Existing project, reuse existing model | [`brownfield-existing-model.yaml`](./azure-yaml-examples/brownfield-existing-model.yaml) | `runtime:` |
| Existing project, create new model | [`brownfield-new-model.yaml`](./azure-yaml-examples/brownfield-new-model.yaml) | `runtime:` |
Each file pairs a single `host: azure.ai.project` service (project-scoped
data-plane resources — model deployments, connections, toolboxes) with a
`host: azure.ai.agent` service that references it via `uses:`. The three deploy
sources (`runtime:` / `docker:` / `image:`) are mutually exclusive; exactly one
is required. The brownfield files use the `resourceId:` field introduced by the
Bicep-less RFC [#8065](https://github.com/Azure/azure-dev/issues/8065) (Phase 2).
Comment on lines
+1
to
+5
| # ADR: Unify Foundry agent configuration in `azure.yaml` | ||
|
|
||
| **Status:** Proposed | ||
|
|
||
| **Date:** 2026-06-08 |
Comment on lines
+32
to
+34
| - { type: web_search } | ||
| - { type: code_interpreter } | ||
| - { type: mcp, connection: ${GITHUB_MCP_CONN} } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds
docs/architecture/adr-unify-foundry-agent-config.md— the architecture decision record for #7962: Unify Foundry agent configuration inazure.yaml.Also adds five illustrative
azure.yamlexamples (underdocs/architecture/azure-yaml-examples/) that capture the proposed end-state schema, one file per scenario.Why (context)
The
azure.ai.agentsextension currently spreads a hosted Foundry agent across three files:azure.yaml,agent.yaml, andagent.manifest.yaml. This causes:services.<agent>.configmixes agent-scoped concerns with project-scoped resources (model deployments, connections, toolboxes).agent.yamldirectly whileazd ai agentworks off anAgentManifest.What the ADR records
Decisions (locked)
host: azure.ai.agentowns agent-runtime config only (kind,container.resources,env,startupCommand, etc.)host: azure.ai.project(new) owns all project-scoped Foundry data-plane state (toolboxes, connections, deployments)uses:field — no newdependsOn, no core schema changedocker:block; existing images use the existingimage:fieldruntime: { stack, version }blockimage:/docker:/runtime:— validation error otherwisecontainer.resources(cpu/memory) applies to every deploy mode${VAR}expansion inconfig:is performed by the extension (core does not expandconfig:)initpopulatesconfig:and stops emittingagent.yaml/agent.manifest.yaml(deprecation window kept)Phasing (locked)
agent.yaml/agent.manifest.yaml, introducehost: azure.ai.project. No mandatory azd core change.Open questions (to resolve before locking the schema)
azure.ai.projectDeploy create vs. what stays in Bicep? (model deployments and connections are ambiguous)azd deploy; how are removals handled? (relates to #8350, #8349)azure.ai.projectDeploy fails partway through theuseschainruntime:typing —AdditionalProperties(untyped) vs. promotingruntimeto a first-classServiceConfigfield in coreExample scenarios
code-deploy.yamlruntime:container-build.yamldocker:existing-image.yamlimage:brownfield-existing-model.yamlruntime:brownfield-new-model.yamlruntime:Notes
Refs #7962