Skip to content

Commit 9b0b167

Browse files
GeekTrainerCopilot
andcommitted
docs: restructure Foundry lessons for Copilot app
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
1 parent 2d25acf commit 9b0b167

45 files changed

Lines changed: 3021 additions & 442 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎AUTHORING.md‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ copilot-workshops/
3131

3232
### Add a new lesson
3333

34-
1. **Pick a path and number.** Lessons live under `docs/{cli,vscode,app,cloud}/N-name.md`. `N` is the next available integer in that path; the number drives the URL slug (`/cli/3-generating-code/`).
34+
1. **Pick a path and number.** Lessons live under `docs/{cli,vscode,app,cloud}/N-name.md`. `N` is the next available integer in that path; the number drives the URL slug (`/cli/3-generating-code/`). A longer optional exercise can use `N-name/README.md` for its overview and numbered modules inside that folder. Preserve the entry URL with the overview's `slug`, keep the core review as the default next destination, and place the optional sidebar group after it.
3535
2. **Create the file** with frontmatter:
3636
```markdown
3737
---
@@ -82,6 +82,7 @@ Every folder's landing page is a `README.md` so it renders directly when someone
8282
- `docs/<harness>/README.md` → `slug: <harness>` (e.g. `slug: app` → `/app/`).
8383
- `docs/<locale>/README.md` → `slug: <locale>` (e.g. `slug: es-es` → `/es-es/`).
8484
- `docs/<locale>/<harness>/README.md` → `slug: <locale>/<harness>` (e.g. `slug: es-es/app` → `/es-es/app/`).
85+
- `docs/app/8-foundry-canvas/README.md` → `slug: app/8-foundry-canvas`; its localized overview uses `slug: <locale>/app/8-foundry-canvas`.
8586

8687
When you add a new harness or locale landing, name it `README.md` and set its `slug:` to match the folder path. Localized landings must use the locale-prefixed slug, never the English one.
8788

‎docs/app/7-canvases.md‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ description: "Create a shared, agent-driven canvas in the GitHub Copilot app to
44
authors:
55
- geektrainer
66
lastUpdated: 2026-07-09
7+
next:
8+
link: /copilot-workshops/app/9-review/
9+
label: "Review and next steps"
710
---
811

912
So far you've directed agents through chat. But a lot of work doesn't live in a conversation — it lives on a board, in a document, or on a checklist. **Canvases** give you and the agent a shared surface for exactly that kind of work, right inside the app. In this lesson you'll create a simple canvas to plan and track the backlog you've been working through.
@@ -113,16 +116,16 @@ You created a shared surface where you and the agent can collaborate! You:
113116
- saved and merged the canvas to your repository with Agent Merge.
114117
- opened the canvas in a new session and used it to start work.
115118

116-
With your backlog tracked, you're ready to wrap up — or go further. If you want to build a hosted AI agent from the Tailspin catalog, continue to the [optional Backer Concierge lesson][next-lesson]. Otherwise, skip ahead to [reviewing what you've built][review-lesson].
119+
With your backlog tracked, continue to [reviewing what you've built][next-lesson]. For an optional extension using Microsoft Foundry Canvas, explore [Optional: Incorporate Foundry][foundry-canvas].
117120

118121
## Resources
119122

120123
- [Working with canvas extensions in the GitHub Copilot app][canvas-docs]
121124
- [Canvases on Awesome Copilot][awesome-copilot-canvases]
122125
- [About the GitHub Copilot app][about-copilot-app]
123126

124-
[next-lesson]: ../8-foundry-canvas/
125-
[review-lesson]: ../9-review/
127+
[next-lesson]: ../9-review/
128+
[foundry-canvas]: ../8-foundry-canvas/
126129
[canvas-docs]: https://docs.github.com/copilot/how-tos/github-copilot-app/working-with-canvas-extensions
127130
[awesome-copilot-canvases]: https://awesome-copilot.github.com/extensions/
128131
[about-copilot-app]: https://docs.github.com/copilot/concepts/agents/github-copilot-app

‎docs/app/8-foundry-canvas.md‎

Lines changed: 0 additions & 405 deletions
This file was deleted.
Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
---
2+
title: "Prepare project and model"
3+
description: "Export the Tailspin catalog, create a Foundry project and model deployment, and validate them in Canvas."
4+
authors:
5+
- juliamuiruri4
6+
lastUpdated: 2026-09-16
7+
prev:
8+
link: /copilot-workshops/app/8-foundry-canvas/
9+
label: "Optional: Incorporate Foundry"
10+
next:
11+
link: /copilot-workshops/app/8-foundry-canvas/2-build-and-deploy/
12+
label: Build and deploy the agent
13+
---
14+
15+
This first module establishes the data and Azure resources for the Backer Concierge. No agent code or hosted deployment is needed yet.
16+
17+
By the end, you will have:
18+
19+
- A catalog export with explicit grounding limits.
20+
- A Foundry project and a model deployment chosen for the feature requirements.
21+
- A Canvas-validated deployment and a simple catalog-bounded model smoke check.
22+
23+
## Scenario
24+
25+
Tailspin Toys backers can filter games by category and publisher, but questions such as *Which games would suit someone who loves Git puns?* don't have dropdown answers. A Backer Concierge should recommend only games in the Tailspin catalog and never invent games, publishers, ratings, funding totals, backer counts, prices, player counts, play times, or release dates. A reliable catalog and a suitable model are the foundation for those answers.
26+
27+
## Prepare your tools and issue session
28+
29+
The setup connects the GitHub Copilot app to Azure while keeping all feature work together.
30+
31+
> [!IMPORTANT]
32+
> Microsoft Foundry Canvas and hosted agents are in public preview. This module creates billable Azure resources. Subscription, region, quota, and estimated cost need checking before resource creation.
33+
34+
1. Confirm you have an Azure subscription, such as a [free Azure subscription with $200 credit][azure-free] or [Azure for Students with $100 credits][azure-students], and permission to create the workshop resources.
35+
2. Install the [Azure CLI][install-azure-cli] for your OS, then verify the installation using `az version`. Azure Developer CLI setup is deferred until the hosted-agent module.
36+
3. Open the GitHub Copilot app, open **Customize**, then select **Plugins**. Search for `microsoft-foundry` and select **Install** for the Microsoft Foundry plugin, which bundles Canvas and the Foundry skills.
37+
38+
![Install Microsoft Foundry plugin](../../_images/app-8-install-foundry-plugin.png)
39+
40+
4. In **Customize**, select **Plugins**, search for `azure` or select it from the **Featured** list, then select **Install** for the Azure plugin.
41+
5. On the **My work** tab, find and open the issue titled **Add a Backer Concierge assistant for catalog questions** in your Tailspin Toys repository. Select **New session** to start an issue-linked session in a new worktree. Keep this repository, worktree branch, and issue session for all three modules.
42+
6. Type `/microsoft-foundry`, then `/azure` to confirm both skills are installed and available; don't send any prompts yet. If a plugin does not appear immediately, restart the app, return to this same issue session, and check again.
43+
44+
## Generate the catalog export
45+
46+
The sample repository includes an export script that gives the agent a file it can read.
47+
48+
7. In this issue-linked worktree session, replace the default `/fix-issue` prompt in the prompt box with:
49+
50+
```plaintext
51+
Install the project dependencies, seed the database, then run the existing db:export script. Show me the command output and summarize the shape and grounding limits of db/catalog.json.
52+
```
53+
54+
8. Review the command output. Copilot should run the equivalent of:
55+
56+
```bash
57+
npm install
58+
npm run db:setup
59+
npm run db:export
60+
```
61+
62+
![Generate catalog export](../../_images/app-8-generate-catalog-export.png)
63+
64+
9. Open `db/catalog.json` and confirm it contains 21 games with a title, description, category, publisher, and star rating. Check its `note` field: the catalog doesn't contain funding totals, backer counts, pledge tiers, or release dates. Treat missing prices, player counts, and play times as unavailable too, rather than filling gaps from outside knowledge. If the export fails or differs, ask Copilot to investigate and rerun it before continuing.
65+
66+
![Catalog export open in the Copilot app](../../_images/app-8-view-catalog.png)
67+
68+
## Set up a Foundry project and model
69+
70+
Creating the project and deployment in chat first means Canvas connects only to resources that already exist.
71+
72+
10. Select **+**, select **Terminal**, and sign in to Azure:
73+
74+
```bash
75+
az login
76+
```
77+
78+
11. Confirm the selected subscription, region, quota, and estimated cost before approving resource creation. Check in the Azure portal that `rg-tailspin-toys` is available for a dedicated workshop group. If that name belongs to unrelated or shared resources, stop and resolve a dedicated naming choice before using the following prompt; consistently use your approved names throughout the journey.
79+
12. In the same issue session, enter:
80+
81+
```plaintext
82+
Use the Microsoft Foundry skill to create a resource group named rg-tailspin-toys and a Foundry project named tailspin-toys.
83+
```
84+
85+
![Create Foundry project](../../_images/app-8-foundry-project-created.png)
86+
87+
13. Ask Copilot to recommend a model. The issue's acceptance criteria are already in context because the session started from the issue:
88+
89+
```plaintext
90+
Use the Microsoft Foundry skill to recommend two or three current chat models in the tailspin-toys project that meet this issue's acceptance criteria. Explain the tradeoffs and wait for me to choose.
91+
```
92+
93+
14. Confirm Copilot loads the `microsoft-foundry` skill, then choose an available model based on its tradeoffs. The Microsoft Foundry hosted-agent quickstart currently uses `gpt-5.4-mini`, but availability and quota vary by region.
94+
95+
![Select model](../../_images/app-8-select-model.png)
96+
97+
15. Ask Copilot to deploy your selection, reviewing the target project and cost before approval:
98+
99+
```plaintext
100+
Deploy the model I selected to the tailspin-toys Foundry project, using the model name as the deployment name.
101+
```
102+
103+
> [!TIP]
104+
> Model availability changes over time. The model Copilot confirms is available in your project is the appropriate choice, rather than a hardcoded model from this module.
105+
106+
## Validate and smoke-test the model in Canvas
107+
108+
This check verifies the project and model before any agent code exists. A model smoke check is not a substitute for the hosted agent's grounding tests in module 2.
109+
110+
16. Select **+**, then **Canvas**, then **Microsoft Foundry (Preview)**.
111+
17. Open the **More options** menu in the top-right corner of Canvas, then select **Sign in**.
112+
18. Select the **tailspin-toys** Foundry project. Expand **Models** and confirm your deployment appears with the expected name and status.
113+
114+
![Validate project and model in Canvas](../../_images/app-8-validate-project-model.png)
115+
116+
19. In the same GitHub Copilot app issue session, ask Copilot to run a small authenticated request to the model deployment you confirmed in Canvas, using your existing local Azure sign-in. Have it supply two actual entries from `db/catalog.json` plus the catalog's `note`, request one recommendation using only that excerpt, and ask whether the excerpt supplies prices. Check that the recommendation uses the supplied entries and the response acknowledges that prices are unavailable. Keep credentials local or server-side, never in browser code or chat output; no agent scaffold is needed.
117+
20. Compare the answer's title, publisher, and rating with the supplied entries. If the deployment cannot be tested, check the project, deployment status, access, and quota in Canvas and send the error to Copilot. If it invents details, make the excerpt-only instruction explicit and retry. Record the result without treating it as proof of full agent acceptance.
118+
119+
> [!NOTE]
120+
> Canvas remembers the selected project when reopened. Its stages are **Create new hosted agents** for scaffolding, **Build current hosted agent** for connecting models, toolboxes, skills, and guardrails, and **Deploy and test** for local runs and deployment to Foundry Agent Service.
121+
122+
## Checkpoint and next steps
123+
124+
The handoff is a catalog export plus a tested model deployment, not a scaffolded agent.
125+
126+
21. Record the Tailspin Toys repository, current worktree branch, issue-linked session, subscription ID, dedicated resource group, Foundry project, model deployment name, catalog export result, and smoke-check evidence in this session. Confirm the selected project before every later cost-bearing change.
127+
22. Continue to [Build and deploy the agent][next-module] in this same repository, worktree branch, issue session, Foundry project, and model deployment—do not create another project. If stopping here, follow [Clean up your resources][cleanup]; this stopping point needs neither `azure.yaml` nor `azd`.
128+
129+
[azure-free]: https://azure.microsoft.com/pricing/purchase-options/azure-account
130+
[azure-students]: https://azure.microsoft.com/free/students
131+
[install-azure-cli]: https://learn.microsoft.com/cli/azure/install-azure-cli
132+
[next-module]: ../2-build-and-deploy/
133+
[cleanup]: ../#clean-up-your-resources

0 commit comments

Comments
 (0)