Skip to content

Commit d416449

Browse files
authored
Merge pull request #6923 from lgayhardt/pfflow0825
PF flow freshness
2 parents f22d3ff + d8590f2 commit d416449

File tree

2 files changed

+19
-18
lines changed

2 files changed

+19
-18
lines changed

articles/ai-foundry/how-to/flow-develop.md

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ms.custom:
1010
- ignite-2024
1111
- hub-only
1212
ms.topic: how-to
13-
ms.date: 01/10/2025
13+
ms.date: 09/03/2025
1414
ms.reviewer: none
1515
ms.author: lagayhar
1616
author: lgayhardt
@@ -47,7 +47,7 @@ In this article, you learn how to create and develop your first prompt flow in A
4747
- Use the **Add role assignment** page to add yourself as a member.
4848
- Select **Review + assign** to review the assignment.
4949
- Select **Review + assign** to assign the role.
50-
50+
5151
## Create and develop your Prompt flow
5252

5353
You can create a flow by either cloning the samples available in the gallery or creating a flow from scratch. If you already have flow files in local or file share, you can also import the files to create a flow.
@@ -66,12 +66,12 @@ To create a prompt flow from the gallery in Azure AI Foundry portal:
6666
:::image type="content" source="../media/prompt-flow/create-standard-flow.png" alt-text="Screenshot of selecting and creating a standard flow." lightbox="../media/prompt-flow/create-standard-flow.png":::
6767

6868
1. The prompt flow authoring page opens. Select **Start compute session** to have a compute session running for the flow.
69-
1. You can start authoring your flow now. By default you see a sample flow. This example flow has nodes for the LLM and Python tools.
69+
1. You can start authoring your flow now. By default you see a sample flow. This example flow has nodes for the LLM and Python tools.
7070

7171
:::image type="content" source="../media/prompt-flow/create-flow-in-out.png" alt-text="Screenshot of flow input and output on the edit prompt flow page." lightbox="../media/prompt-flow/create-flow-in-out.png":::
7272

7373
> [!NOTE]
74-
> The graph view for visualization only. It shows the flow structure you're developing. You cannot edit the graph view directly, but you can zoom in, zoom out, and scroll. You can select a node in the graph view to highlight and navigate to the node in the tool edit view.
74+
> The graph view for visualization only. It shows the flow structure you're developing. You can't edit the graph view directly, but you can zoom in, zoom out, and scroll. You can select a node in the graph view to highlight and navigate to the node in the tool edit view.
7575
7676
1. Optionally, you can add more tools to the flow. The visible tool options are **LLM**, **Prompt**, and **Python**. To view more tools, select **+ More tools**.
7777

@@ -129,17 +129,24 @@ If the condition isn't met, the node is skipped. The node status is shown as "By
129129

130130
You can test the flow in two ways:
131131

132-
- Run **single node**.
133-
- To run a single node, select the **Run icon** on a node in the default view. Once running is completed, you can quickly check result in **node output section**.
134-
132+
- Run single node:
133+
- To run a single node, select the **Run** icon on a node in the default view. Once running is completed, you can quickly check result in node *Outputs* section.
134+
n
135135
:::image type="content" source="../media/prompt-flow/node-card-run.png" alt-text="Screenshot shows the run button in the node card.":::
136136

137-
- Run **the whole flow**.
138-
- To run the whole flow, select the **Run button** at the right top.
137+
- Run the whole flow:
138+
- To run the whole flow, select the **Run** button at the right top.
139139

140140
#### View test result and trace (preview)
141141

142-
For the whole flow run, after you execute the flow, you can see the run status in the run banner. Then you can select **View trace** to view the trace for checking the result and observing the flow execution, where you can see the input and output of the whole flow and each node, along with more detailed information for debugging. It's available during the running and after the run is completed.
142+
Tracing is disabled by default, to enable tracing you need to set the environment variable `PF_DISABLE_TRACING` to `false`. One way you can do this is by adding the following to the python node:
143+
144+
```python
145+
import os
146+
os.environ["PF_DISABLE_TRACING"] = "false"
147+
```
148+
149+
For the whole flow run, after you execute the flow, you can see the run status in the run banner. To view the trace for checking the result and observing the flow execution, you can select **View outputs** and then select the **trace** tab. You can see the input and output of the whole flow and each node, along with more detailed information for debugging. It's available during the running and after the run is completed.
143150

144151
##### Understand the trace view
145152

@@ -152,12 +159,6 @@ Select the **Trace** tab on the Outputs screen to see a graph that provides info
152159
>
153160
> To learn more about span types, see [Trace span](https://microsoft.github.io/promptflow/reference/trace-span-spec-reference.html).
154161
155-
After the flow run is completed, for checking the results, you can select the **View test results** button to check all historical run records in a list. By default, the run records created in the last 7 days are displayed. You can select the **Filter** to change the condition.
156-
157-
:::image type="content" source="../media/prompt-flow/authoring-test-result.png" alt-text="Screenshot of flow test result."lightbox="../media/prompt-flow/authoring-test-result.png":::
158-
159-
You can also select on the **Name** of the run record to view the detailed information in trace view.
160-
161162
## Develop a chat flow
162163

163164
Chat flow is designed for conversational application development, building upon the capabilities of standard flow and providing enhanced support for chat inputs/outputs and chat history management. With chat flow, you can easily create a chatbot that handles chat input and output.
@@ -172,7 +173,7 @@ The most important elements that differentiate a chat flow from a standard flow
172173
- **Chat history**: Chat history is the record of all interactions between the user and the chatbot, including both user inputs and AI-generated outputs. Maintaining chat history is essential for keeping track of the conversation context and ensuring the AI can generate contextually relevant responses.
173174
- **Chat output**: Chat output refers to the AI-generated messages that are sent to the user in response to their inputs. Generating contextually appropriate and engaging chat output is vital for a positive user experience.
174175

175-
A chat flow can have multiple inputs, chat history and chat input are **required** in chat flow.
176+
A chat flow can have multiple inputs, chat history, and chat input are **required** in chat flow.
176177

177178
- In the chat flow inputs section, a flow input can be marked as chat input. Then you can fill the chat input value by typing in the chat box.
178179
- Prompt flow can help user to manage chat history. The `chat_history` in the Inputs section is reserved for representing Chat history. All interactions in the chat box, including user chat inputs, generated chat outputs, and other flow inputs and outputs, are automatically stored in chat history. User can't manually set the value of `chat_history` in the Inputs section. It's structured as a list of inputs and outputs:
@@ -207,7 +208,7 @@ A chat flow can have multiple inputs, chat history and chat input are **required
207208
```
208209

209210
> [!NOTE]
210-
> The capability to automatically save or manage chat history is a feature on the authoring page when conducting tests in the chat box. For batch runs, it's necessary for users to include the chat history within the batch run dataset. If there's no chat history available for testing, simply set the chat_history to an empty list `[]` within the batch run dataset.
211+
> The capability to automatically save or manage chat history is a feature on the authoring page when conducting tests in the chat box. For batch runs, it's necessary for users to include the chat history within the batch run dataset. If there's no chat history available for testing, set the chat_history to an empty list `[]` within the batch run dataset.
211212

212213
### Author prompt with chat history
213214

121 KB
Loading

0 commit comments

Comments
 (0)