You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/ai-services/openai/how-to/assistants-logic-apps.md
+18-18Lines changed: 18 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,23 +24,23 @@ The Assistants playground enumerates and lists all the workflows in your subscri
24
24
25
25
* Consumption Logic Apps: Currently we only support consumption workflows.
26
26
* Request Trigger: Function calling requires a REST-based API. Logic Apps with a request trigger provides a REST endpoint. Therefore only workflows with a request trigger are supported for function calling.
27
-
* Schema: The workflows you want to use for function calling should have a JSON schema describing the inputs and expected outputs. Using Logic Apps you can streamline and provide schema in the trigger which would be automatically imported as a function definition.
27
+
* Schema: The workflows you want to use for function calling should have a JSON schema describing the inputs and expected outputs. Using Logic Apps you can streamline and provide schema in the trigger, which would be automatically imported as a function definition.
28
28
29
29
## Import your Logic Apps workflows as functions
30
30
31
-
Here are the steps to import your Logic Apps workflows as function in the Assistants playground in Azure Open AI Studio:
31
+
Here are the steps to import your Logic Apps workflows as function in the Assistants playground in Azure OpenAI Studio:
32
32
33
33
1. In Azure OpenAI Studio, select **Assistants**. Select an existing Assistant or create a new one. After you have configured the assistant with a name and instructions, you are ready to add a function. Select **+ Add function**.
34
34
35
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png" alt-text="A screenshot showing the Assistant playground with the add function button." lightbox="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png:::
35
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png" alt-text="A screenshot showing the Assistant playground with the add function button." lightbox="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png":::
36
36
37
37
1. The **Add function** option opens a screen with two tabs. Navigate to the tab for Logic Apps to browse your workflows with a request trigger. Select the workflow from list and select **Save**.
38
38
39
39
> [!NOTE]
40
40
> This list only shows the consumption SKU workflows and with a request trigger.
41
41
42
42
43
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\import-logic-apps.png" alt-text="A screenshot showing the Assistant playground with the add function button." lightbox="..\media\how-to\assistants\logic-apps\import-logic-apps.png:::
43
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\import-logic-apps.png" alt-text="A screenshot showing the Assistant playground with the add function button." lightbox="..\media\how-to\assistants\logic-apps\import-logic-apps.png":::
44
44
45
45
46
46
## What happens when a Logic Apps is imported in AI Studio and invoked
@@ -51,17 +51,17 @@ Azure Logic App publishes an OpenAPI 2.0 definition (swagger) for workflows with
51
51
52
52
**How does authentication from AI Studio to Logic Apps work?**
53
53
54
-
Logic Apps support two primary types of authentications to invoke a request trigger.
54
+
Logic Apps supports two primary types of authentications to invoke a request trigger.
55
55
56
56
* Shared Access Signature (SAS) based authentication.
57
57
58
-
Users can obtain a callback URL containing a SAS using the [list callback URL](/rest/api/logic/workflows/list-callback-url) API. Logic Apps also support using multiple keys and rotating them as needed. Logic Apps also support creating SAS URLs with a specified validity period. For more information, see the [Logic Apps documentation](../../../logic-apps/logic-apps-securing-a-logic-app.md#generate-shared-access-signatures-sas).
58
+
Users can obtain a callback URL containing a SAS using the [list callback URL](/rest/api/logic/workflows/list-callback-url) API. Logic Apps also supports using multiple keys and rotating them as needed. Logic Apps also supports creating SAS URLs with a specified validity period. For more information, see the [Logic Apps documentation](../../../logic-apps/logic-apps-securing-a-logic-app.md#generate-shared-access-signatures-sas).
59
59
60
60
* Microsoft Entra ID-based OAuth base authentication policy.
61
61
62
-
Logic Apps also support authentication trigger invocations with Microsoft Entra ID OAuth, where you can specify authentication policies to be used in validating OAuth tokens. For more information, see the [Logic Apps documentation](../../../logic-apps/logic-apps-securing-a-logic-app.md#generate-shared-access-signatures-sas).
62
+
Logic Apps also supports authentication trigger invocations with Microsoft Entra ID OAuth, where you can specify authentication policies to be used in validating OAuth tokens. For more information, see the [Logic Apps documentation](../../../logic-apps/logic-apps-securing-a-logic-app.md#generate-shared-access-signatures-sas).
63
63
64
-
When Azure OpenAI Assistants requires invoking a Logic App as part of function calling, AI Studio will retrieve the callback URL with the SAS to invoke the workflow.
64
+
When Azure OpenAI Assistants require invoking a Logic App as part of function calling, AI Studio will retrieve the callback URL with the SAS to invoke the workflow.
65
65
66
66
## Create Logic Apps workflows for function calling
67
67
Here are the steps to create a new Logic Apps workflow for function calling.
@@ -81,41 +81,41 @@ Here are the steps to create a new Logic Apps workflow for function calling.
81
81
82
82
Select **Add a trigger** and then search for request trigger. Select the **When a HTTP request is received** operation.
Provide the JSON schema for the request. If you do not have the schema use the option to generate schema.
87
87
88
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-2.png" alt-text="A screenshot showing the option to provide a JSON schema." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-2.png:::
88
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-2.png" alt-text="A screenshot showing the option to provide a JSON schema." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-2.png":::
89
89
90
90
Here is an example of the request schema. You can add a description for your workflow in the comment box. This is imported by AI Studio as the function description.
91
91
92
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-3.png" alt-text="A screenshot showing an example request schema." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-3.png:::
92
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-3.png" alt-text="A screenshot showing an example request schema." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-3.png":::
93
93
94
94
Save the workflow. This will generate the REST endpoint for the workflow.
95
95
96
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-4.png" alt-text="A screenshot showing the REST endpoint." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-4.png:::
96
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-4.png" alt-text="A screenshot showing the REST endpoint." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-4.png":::
97
97
98
98
1. Depending on the business use case, you can now add one or more steps/actions in this workflow. For example, using the MSN weather connector to get the weather forecast for the current location.
In the action to **get forecast for today**, we are using the **location** property that was passed to this workflow as an input.
103
103
104
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-6.png" alt-text="A screenshot showing the location property." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-6.png:::
104
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-6.png" alt-text="A screenshot showing the location property." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-6.png":::
105
105
106
106
1. Configure the [response](../../../connectors/connectors-native-reqres.md#add-a-response-action). The workflow needs to return the response back to AI Studio. This is done using Response action.
107
107
108
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-7.png" alt-text="A screenshot showing the response action." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-7.png:::
108
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-7.png" alt-text="A screenshot showing the response action." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-7.png":::
109
109
110
110
In the response action, you can pick the output from any of the prior steps. You can optionally also provide a JSON schema if you want to return the output in a specific format.
111
111
112
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-7.png" alt-text="A screenshot showing the comment box to specify a JSON schema." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-7.png:::
112
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\create-logic-app-7.png" alt-text="A screenshot showing the comment box to specify a JSON schema." lightbox="..\media\how-to\assistants\logic-apps\create-logic-app-7.png":::
113
113
114
114
1. The workflow is now ready. In AI Studio, you can import this function using the **Add function** feature in the Assistants playground.
115
115
116
-
:::image type="content" source="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png" alt-text="A screenshot showing the Assistant playground." lightbox="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png:::
116
+
:::image type="content" source="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png" alt-text="A screenshot showing the Assistant playground." lightbox="..\media\how-to\assistants\logic-apps\assistants-playground-add-function.png":::
117
117
118
-
Azure Logic Apps has connectors to hundreds of line-of-business (LOB) applications and databases including but not limited to: SAP, Salesforce, Oracle, SQL, and more. You can also connect to SaaS applications or your in-house applications hosted in virtual networks. These out of box connectors provide operations to send and receive data in multiple formats. Leveraging these capabilities with Azure Open AI assistants, you should be able to quickly bring your data for Intelligent Insights powered by Azure Open AI.
118
+
Azure Logic Apps has connectors to hundreds of line-of-business (LOB) applications and databases including but not limited to: SAP, Salesforce, Oracle, SQL, and more. You can also connect to SaaS applications or your in-house applications hosted in virtual networks. These out of box connectors provide operations to send and receive data in multiple formats. Leveraging these capabilities with Azure OpenAI assistants, you should be able to quickly bring your data for Intelligent Insights powered by Azure OpenAI.
0 commit comments