Skip to content

Commit c345c1c

Browse files
authored
Merge pull request #8132 from microsoft/prompt-builder-toc
Prompt builder edit pass and ToC update
2 parents b808d00 + ed13b46 commit c345c1c

File tree

10 files changed

+78
-53
lines changed

10 files changed

+78
-53
lines changed

build/sitemap.xml

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1694,5 +1694,44 @@
16941694
<changefreq>weekly</changefreq>
16951695
<priority>0.8</priority>
16961696
</url>
1697-
1697+
<url>
1698+
<loc>https://code.visualstudio.com/docs/intelligentapps/overview</loc>
1699+
<changefreq>weekly</changefreq>
1700+
<priority>0.8</priority>
1701+
</url>
1702+
<url>
1703+
<loc>https://code.visualstudio.com/docs/intelligentapps/models</loc>
1704+
<changefreq>weekly</changefreq>
1705+
<priority>0.8</priority>
1706+
</url>
1707+
<url>
1708+
<loc>https://code.visualstudio.com/docs/intelligentapps/playground</loc>
1709+
<changefreq>weekly</changefreq>
1710+
<priority>0.8</priority>
1711+
</url>
1712+
<url>
1713+
<loc>https://code.visualstudio.com/docs/intelligentapps/promptbuilder</loc>
1714+
<changefreq>weekly</changefreq>
1715+
<priority>0.8</priority>
1716+
</url>
1717+
<url>
1718+
<loc>https://code.visualstudio.com/docs/intelligentapps/bulkrun</loc>
1719+
<changefreq>weekly</changefreq>
1720+
<priority>0.8</priority>
1721+
</url>
1722+
<url>
1723+
<loc>https://code.visualstudio.com/docs/intelligentapps/evaluation</loc>
1724+
<changefreq>weekly</changefreq>
1725+
<priority>0.8</priority>
1726+
</url>
1727+
<url>
1728+
<loc>https://code.visualstudio.com/docs/intelligentapps/finetune</loc>
1729+
<changefreq>weekly</changefreq>
1730+
<priority>0.8</priority>
1731+
</url>
1732+
<url>
1733+
<loc>https://code.visualstudio.com/docs/intelligentapps/faq</loc>
1734+
<changefreq>weekly</changefreq>
1735+
<priority>0.8</priority>
1736+
</url>
16981737
</urlset>

docs/intelligentapps/bulkrun.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 5
3-
Area: intelligentapps
4-
TOCTitle: Bulk Run
52
ContentId: 1124d141-e893-4780-aba7-b6ca13628bc5
6-
PageTitle: Bulk Run Prompts
73
DateApproved: 12/11/2024
84
MetaDescription: Run a set of prompts in an imported dataset, individually or in a full batch towards the selected genAI models and parameters.
95
---

docs/intelligentapps/evaluation.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 6
3-
Area: intelligentapps
4-
TOCTitle: Evaluation
52
ContentId: 3342b8ef-72fe-4cca-baad-64ee57c05b5f
6-
PageTitle: AI Evaluation
73
DateApproved: 12/11/2024
84
MetaDescription: Import a dataset with LLMs or SLMs output or rerun it for the queries. Run evaluation job for the popular evaluators like F1 score, relevance, coherence, similarity... find, visualize, and compare the evaluation results in tables or charts.
95
---

docs/intelligentapps/faq.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 8
3-
Area: intelligentapps
4-
TOCTitle: FAQ
52
ContentId: c35d24d0-5d2c-493d-9635-10601a13848e
6-
PageTitle: FAQ for AI Toolkit
73
DateApproved: 12/11/2024
84
MetaDescription: Find answers to frequently asked questions (FAQ) using AI Toolkit. Get troubleshooting recommendations.
95
---

docs/intelligentapps/finetune.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 7
3-
Area: intelligentapps
4-
TOCTitle: Finetune
52
ContentId: 5b6626b8-98a9-497e-bbc6-e2274885be56
6-
PageTitle: Finetune AI Models
73
DateApproved: 12/11/2024
84
MetaDescription: Use custom dataset to fine-tune a generative AI model in the Azure cloud or locally with GPUs. Deploy the fine-tuned model to the Azure cloud or download incremental files from fine-tuned model.
95
---

docs/intelligentapps/models.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 2
3-
Area: intelligentapps
4-
TOCTitle: Models
52
ContentId: 52ad40fe-f352-4e16-a075-7a9606c5df3b
6-
PageTitle: AI Models in AI Toolkit
73
DateApproved: 12/11/2024
84
MetaDescription: Find a popular generative AI model by publisher and source. Bring your own model that is hosted with a URL, or select an Ollama model.
95
---

docs/intelligentapps/overview.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 1
3-
Area: intelligentapps
4-
TOCTitle: AI Toolkit Overview
52
ContentId: 164299e8-d27d-40b9-8b8d-a6e05df8ac69
6-
PageTitle: AI Toolkit Overview
73
DateApproved: 12/11/2024
84
MetaDescription: Develop and test AI apps with AI Toolkit for Visual Studio Code. Inference test, batch run, evaluate, fine-tune and deploy LLMs and SLMs.
95
---

docs/intelligentapps/playground.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
---
2-
Order: 3
3-
Area: intelligentapps
4-
TOCTitle: Playground
52
ContentId: e919aee8-fd2e-401b-9d83-0ff6f98b23ba
6-
PageTitle: AI Model Playground
73
DateApproved: 12/11/2024
84
MetaDescription: Chat with selected generative AI model in playground. Change system prompt and parameters. Add attachment for Multi-Modal models. Keep chat history.
95
---

docs/intelligentapps/promptbuilder.md

Lines changed: 37 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,79 @@
11
---
2-
Order: 4
3-
Area: intelligentapps
4-
TOCTitle: Prompt Builder
52
ContentId: bd3d7555-3d84-4500-ae95-6dcd39641af0
6-
PageTitle: Prompt Builder
73
DateApproved: 04/09/2025
84
MetaDescription: Get Started with creating, iterating and optimizing your prompts in AI Toolkit.
95
---
106
# Prompt engineering in AI Toolkit
117

12-
Prompt builder in AI Toolkit streamlines the prompt engineering workflow by generating starter prompts, helping you iterate and refine with each run, breaking down complex tasks through prompt chaining and structured outputs, and providing easy access to code for seamless LLM integration via APIs.
8+
Prompt builder in AI Toolkit streamlines the prompt engineering workflow. It can generate starter prompts, helping you iterate and refine with each run, break down complex tasks through prompt chaining and structured outputs, and provide easy access to code for seamless Large Language Model (LLM) integration via APIs.
139

1410
![Getting started with prompt builder](./images/promptbuilder/promptbuilder.gif)
1511

16-
## Create, edit and test prompts
12+
## Create, edit, and test prompts
13+
14+
To access the prompt builder, use either of these options:
1715

18-
To access the prompt builder, use one of these options:
1916
- In the AI Toolkit view, select **Prompt Builder**
2017
- Select **Try in Prompt Builder** from a model card in the model catalog
2118

2219
To test a prompt in the prompt builder, follow these steps:
20+
2321
1. In **Models**, select a model from the dropdown list, or select **Browse models** to add another model from the model catalog.
22+
2423
![select a model](./images/promptbuilder/s1_models.png)
25-
2. Enter a **User prompt** and optionally enter a **System prompt**
26-
The user prompt is the input that you want to send to the model. The optional system prompt is used to provide instructions with relevant context to guide the model response.
24+
25+
1. Enter a **User prompt** and optionally enter a **System prompt**.
26+
27+
The *user prompt* is the input that you want to send to the model. The optional *system prompt* is used to provide instructions with relevant context to guide the model response.
2728

2829
> [!TIP]
2930
> If you don't know how to input these prompts, you can describe your project idea in natural language and let the AI-powered feature generate prompts for you to experiment with.
3031
> ![generate prompts with natural language](./images/promptbuilder/generate_prompt.gif)
31-
3. Select **Run** to send the prompts to the selected model
32-
4. Optionally, select **Add Prompts** to add more user and assistant prompts to the conversation, or select **Use Response as Assistant Prompt** as the history and context you send to the model to further guide the model's behavior
33-
5. Repeat the previous steps to iterate over your prompts by observing the model response and making changes to the prompts
32+
33+
1. Select **Run** to send the prompts to the selected model.
34+
35+
1. Optionally, select **Add Prompts** to add more user and assistant prompts to the conversation, or select **Use Response as Assistant Prompt** as the history and context you send to the model to further guide the model's behavior.
36+
37+
1. Repeat the previous steps to iterate over your prompts by observing the model response and making changes to the prompts.
3438

3539
## Structured output
3640

3741
Structured output support helps you design prompts to deliver outputs in a structured, predictable format.
42+
3843
![Use structured output](./images/promptbuilder/structured_output.gif)
3944

4045
To test a prompt in the prompt builder, follow these steps:
4146

42-
1. Select the **Format** dropdown in the **Response** area, and select **json_schema**
43-
2. Select **Prepare schema**
44-
3. From the Command Palette, either select **Select local file** to use your own schema, or select **Use an example** to use a predefined schema
45-
If you proceed with an example, you can select a schema from the dropdown list
46-
5. Select **Run** to send the prompts to the selected model
47-
6. You can also edit the schema by selecting **Edit**
47+
1. Select the **Format** dropdown in the **Response** area, and select **json_schema**.
48+
49+
1. Select **Prepare schema**, and then select **Select local file** to use your own schema, or select **Use an example** to use a predefined schema.
50+
51+
If you proceed with an example, you can select a schema from the dropdown list.
52+
53+
1. Select **Run** to send the prompts to the selected model.
54+
55+
1. You can also edit the schema by selecting **Edit**.
56+
4857
![edit schema](./images/promptbuilder/edit_schema.png)
4958

5059
## Integrate prompt engineering into your application
5160

5261
After experimenting with models and prompts, you can get into coding right away with the automatically generated Python code.
62+
5363
![view code](./images/promptbuilder/view_code.gif)
64+
5465
To view the Python code, follow these steps:
55-
1. Select **View Code**
56-
1. Select the inference SDK you want to use if it's hosted by GitHub
5766

58-
AI Toolkit generates the code for the model you selected by using the provider's client SDK. For models hosted by GitHub, you have the option to select the inference SDK you want to use: [Azure AI Inference SDK](https://learn.microsoft.com/python/api/overview/azure/ai-inference-readme?view=azure-python-preview) or the SDK from the model provider, such as [OpenAI SDK](https://platform.openai.com/docs/libraries) or [Mistral API](https://docs.mistral.ai/api).
67+
1. Select **View Code**.
68+
69+
1. For models hosted on GitHub, select the inference SDK you want to use.
70+
71+
AI Toolkit generates the code for the model you selected by using the provider's client SDK. For models hosted by GitHub, you can choose which inference SDK you want to use: [Azure AI Inference SDK](https://learn.microsoft.com/python/api/overview/azure/ai-inference-readme?view=azure-python-preview) or the SDK from the model provider, such as [OpenAI SDK](https://platform.openai.com/docs/libraries) or [Mistral API](https://docs.mistral.ai/api).
72+
5973
1. The generated code snippet is shown in a new editor, where you can copy it into your application.
60-
1. You can view the generated code snippet in a new file window and copy them into your application.
61-
> To authenticate with the model you usually need an API key from the provider. To access models hosted by GitHub, [generate a personal access token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens) (PAT) in your GitHub settings
74+
75+
> To authenticate with the model, you usually need an API key from the provider. To access models hosted by GitHub, [generate a personal access token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens) (PAT) in your GitHub settings.
6276
6377
## Next steps
6478

6579
- [Run an evaluation job](/docs/intelligentapps/evaluation.md) for the popular evaluators
66-
- [Run evaluation](/docs/intelligentapps/evaluation.md) job for the popular evaluators

docs/toc.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,7 @@
300300
["AI Toolkit Overview", "/docs/intelligentapps/overview"],
301301
["Models", "/docs/intelligentapps/models"],
302302
["Playground", "/docs/intelligentapps/playground"],
303+
["Prompt Builder", "/docs/intelligentapps/promptbuilder"],
303304
["Bulk Run", "/docs/intelligentapps/bulkrun"],
304305
["Evaluation", "/docs/intelligentapps/evaluation"],
305306
["Fine-tune", "/docs/intelligentapps/finetune"],

0 commit comments

Comments
 (0)