Coordinate the solution and use microsoft-foundry for platform operations. Explicit user choices override defaults. Reuse known context, ask only for missing decisions, read only the references a step needs, and report decisions, blockers and endpoints concisely.
microsoft-foundry is unavailable, ask, then install it (copilot plugin install azure@awesome-copilot, or gh skill install microsoft/azure-skills microsoft-foundry --agent github-copilot --scope project) and reload skills.foundry-agentic-loop-canvas and foundry-agentic-loop-workflow, listed as foundry-agentic-loop:<name> or <name>. Call extensions_manage with operation: "list". Never install extensions from a URL and never edit Copilot settings files. If one is listed under neither name, tell the user which is missing and that it ships with the plugin, then ask before running copilot plugin install foundry-agentic-loop@awesome-copilot; after they approve, call extensions_reload once. If one is disabled, tell the user to re-enable it in their extension settings and continue in a new session: running sessions keep it disabled, even after a reload. If one failed, inspect it and report its log. Without the canvas, continue in Chat; without the workflow, SDD cannot start, so offer rapid prototyping.open_canvas with canvasId: "foundry-agentic-loop-canvas", instanceId: "foundry-agentic-loop" and input: { mode }. Prompts that begin [Agentic Loop canvas action] come from the canvas; follow their target, approval and resume instructions literally.| Signal | Mode |
|---|---|
Root AGENTS.md has an Agentic Loop section | Its mode. Switch only when the user confirms, then rewrite the section |
| Canvas prompt or explicit choice | As stated |
| Existing Foundry project selected or named; fast prototype; no deployment pipeline needed | Rapid prototyping: rapid.md |
| Spec, new Foundry project, azd or IaC, CI-ready repo or full Azure deployment | SDD: sdd.md |
| Improve, learn from runs, or the canvas improve prompt | Improve: improve.md; measure changes with node scripts/evals.mjs (index, then run --base <commit>; exit 2 means evals are unavailable, so stop) |
| One named SDD phase, with no run active | Its guide (Specify, Implement, Verify or Deploy) with the SDD defaults |
Otherwise ask once with the choices "Rapid prototyping (existing Foundry project)" and "SDD (new project, deployed with azd)".
Lock it in. Before any other workspace write (in the rapid preflight, or just before the SDD workflow starts), upsert the section from agents-md-rapid.md or agents-md-sdd.md into the root AGENTS.md: replace everything between its foundry-agentic-loop begin and end markers, or append it, keeping other content; then read it back. The section routes short commands such as deploy and locks the mode for Chat, the canvas and the workflow. Azure settings go only in .azure/deployment-plan.md, never in AGENTS.md. Improve mode never writes it.
microsoft-foundry's foundry-agent/create/quick-start-hosted.md with the Basic sample, resolved through that skill, never a guessed URL. Use its advanced workflow only when quick-start cannot support a capability, keeping these defaults. Prompt agents only when requested.gpt-5.4-mini unless the spec needs otherwise. Run the joint placement preflight in foundry-models.md before creating resources. Never hard-code a replacement or silently duplicate a deployment.az containerapp up --name <app> --source <dir> --resource-group <rg> --environment <env>; SDD uses azd with a microsoft.foundry layer plus a Bicep (AVM) app layer, remoteBuild: true and one ACR pulled by managed identity. Add services from the reference architecture only when the solution needs them.| File | Holds |
|---|---|
AGENTS.md (root) | The mode lock and short-command routes; never Azure settings |
README.md (rapid) or docs/spec.md (SDD, from the spec template) | The contract |
.azure/deployment-plan.md | Every Azure setting, in both modes (template) |
.env (Git-ignored) | What the canvas reads: FOUNDRY_PROJECT (full ARM ID, once validated or created), LOCAL_FRONTEND and DEPLOYED_FRONTEND (verified URLs only). Upsert, keep other keys and read back |
docs/LOOP.md | Lessons (template) |
.agentic-loop/runs/<runId>.json | SDD flight records, written by the workflow |
.devcontainer/devcontainer.json | Optional dev container (asset) |
N/A with the reason, never as passed, and never add unused ones to satisfy the checkpoint.active never pass alone; require terminal completion, schema-valid output, execution evidence and correlated traces. Fix with bounded diagnostics, not unchanged redeployments.azure.yaml, infra/, docs/, .env, .azure/, .agentic-loop/, AGENTS.md and the root lockfiles. Keep teams small, avoid recursive delegation, serialize shared Azure mutations and integrate centrally; worker success is not acceptance. Delegation grants no extra approval. Without subagents, work sequentially and say so.docs/LOOP.md, scaffold from the Foundry samples and these references, and use code from other folders only when the user names them. Only improve mode reads past runs elsewhere.workiq MCP server before clarifying questions, fold in only the requirements that matter, cite each by source type and confirm them. Never copy confidential content, personal data or secrets into the workspace; if Work IQ is unavailable or needs consent, say so and continue without it.Right after a fix is verified (the failing probe or an equivalent boundary check reruns successfully; an edit, commit or deployment alone is not resolution), upsert a lesson in the workspace's docs/LOOP.md from the template before unrelated work, then read it back. Keep user notes, update matching lessons instead of duplicating them, and never include secrets, raw .env values or payloads. The coordinator, or the SDD phase lead, owns writes; workers report evidence. Lessons never authorize skill edits or weaker gates; improve mode applies them with approval.