Skip to content

Commit c6c40cc

Browse files
authored
Merge branch 'MicrosoftDocs:main' into main
2 parents 7079bd4 + e9e47d6 commit c6c40cc

File tree

14 files changed

+682
-74
lines changed

14 files changed

+682
-74
lines changed

articles/ai-studio/how-to/create-manage-runtime.md

Lines changed: 27 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -23,34 +23,44 @@ A prompt flow runtime has computing resources that are required for the applicat
2323

2424
Azure AI Studio supports the following types of runtimes:
2525

26-
|Runtime type|Underlying compute type|Life cycle management| Customize packages |
26+
|Runtime type|Underlying compute type|Life cycle management|Customize environment |
2727
|------------|----------------------|---------------------|---------------------|
28-
|Automatic runtime |Serverless compute| Automatic | Easily customize Python packages|
29-
|Compute instance runtime | Compute instance | Manual | |
28+
|Automatic runtime (preview) |[Serverless compute](../../machine-learning/how-to-use-serverless-compute.md) and [Compute instance](../../machine-learning/how-to-create-compute-instance.md)| Automatic | Easily customize packages|
29+
|Compute instance runtime | [Compute instance](../../machine-learning/how-to-create-compute-instance.md) | Manual | Manually customize via Azure Machine Learning environment|
3030

31-
If you're a new user, we recommend that you use an automatic runtime. You can easily customize the environment for this runtime.
31+
If you're a new user, we recommend that you use the automatic runtime (preview). You can easily customize the environment by adding packages in the `requirements.txt` file in `flow.dag.yaml` in the flow folder.
3232

33-
If you have a compute instance, you can use it to build your compute instance runtime.
33+
If you want manage compute resource by your self, you can use compute instance as compute type in automatic runtime or use compute instance runtime.
3434

3535
## Create a runtime
3636

3737
### Create an automatic runtime on a flow page
3838

3939
Automatic is the default option for a runtime. You can start an automatic runtime by selecting an option from the runtime dropdown list on a flow page:
4040

41-
- Select **Start**. Start creating an automatic runtime by using the environment defined in `flow.dag.yaml` in the flow folder on the virtual machine (VM) size where you have a quota in the project.
41+
- Select **Start**. Start creating an automatic runtime by using the environment defined in `flow.dag.yaml` in the flow folder, it runs on the virtual machine (VM) size of serverless compute which you have enough quota in the workspace.
4242

4343
:::image type="content" source="../media/prompt-flow/how-to-create-manage-runtime/runtime-create-automatic-init.png" alt-text="Screenshot of prompt flow with default settings for starting an automatic runtime on a flow page." lightbox = "../media/prompt-flow/how-to-create-manage-runtime/runtime-create-automatic-init.png":::
4444

4545
- Select **Start with advanced settings**. In the advanced settings, you can:
4646

47-
- Customize the VM size that the runtime uses.
48-
- Customize the idle time, which saves code by deleting the runtime automatically if it isn't in use.
49-
- Set the user-assigned managed identity. The automatic runtime uses this identity to pull a base image and install packages. Make sure that the user-assigned managed identity has Azure Container Registry pull permission.
47+
- Select compute type. You can choose between serverless compute and compute instance.
48+
- If you choose serverless compute, you can set following settings:
49+
- Customize the VM size that the runtime uses.
50+
- Customize the idle time, which saves code by deleting the runtime automatically if it isn't in use.
51+
- Set the user-assigned managed identity. The automatic runtime uses this identity to pull a base image and install packages. Make sure that the user-assigned managed identity has Azure Container Registry pull permission.
52+
53+
If you don't set this identity, we use the user identity by default. [Learn more about how to create and update user-assigned identities for a workspace](../../machine-learning/how-to-identity-based-service-authentication.md#to-create-a-workspace-with-multiple-user-assigned-identities-use-one-of-the-following-methods).
5054

51-
If you don't set this identity, you use the user identity by default. [Learn more about how to create and update user-assigned identities for a project](../../machine-learning/how-to-identity-based-service-authentication.md#to-create-a-workspace-with-multiple-user-assigned-identities-use-one-of-the-following-methods).
55+
:::image type="content" source="../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-settings.png" alt-text="Screenshot of prompt flow with advanced settings using serverless compute for starting an automatic runtime on a flow page." lightbox = "../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-settings.png":::
56+
57+
- If you choose compute instance, you can only set idle shutdown time.
58+
- As it is running on an existing compute instance the VM size is fixed and cannot change in runtime side.
59+
- Identity used for this runtime also is defined in compute instance, by default it uses the user identity. [Learn more about how to assign identity to compute instance](../../machine-learning/how-to-create-compute-instance.md#assign-managed-identity)
60+
- For the idle shutdown time it is used to define life cycle of the runtime, if the runtime is idle for the time you set, it will be deleted automatically. And of you have idle shut down enabled on compute instance, then it will continue
61+
62+
:::image type="content" source="../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-compute-instance-settings.png" alt-text="Screenshot of prompt flow with advanced settings using compute instance for starting an automatic runtime on a flow page." lightbox = "../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-compute-instance-settings.png":::
5263

53-
:::image type="content" source="../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-settings.png" alt-text="Screenshot of prompt flow with advanced settings for starting an automatic runtime on a flow page." lightbox = "../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-settings.png":::
5464

5565
### Create a compute instance runtime on a runtime page
5666

@@ -142,7 +152,7 @@ If you want to use a private feed in Azure DevOps, follow these steps:
142152
143153
#### Change the base image for automatic runtime (preview)
144154
145-
By default, we use the latest prompt flow image as the base image. If you want to use a different base image, you need build your own base image, this docker image should be built from prompt flow base image that is `mcr.microsoft.com/azureml/promptflow/promptflow-runtime-stable:<newest_version>`. If possible use the [latest version of the base image](https://mcr.microsoft.com/v2/azureml/promptflow/promptflow-runtime-stable/tags/list). To use the new base image, you need to reset the runtime via the `reset` command. This process takes several minutes as it pulls the new base image and reinstalls packages.
155+
By default, we use the latest prompt flow image as the base image. If you want to use a different base image, you need build your own base image, this docker image should be built from prompt flow base image that is `mcr.microsoft.com/azureml/promptflow/promptflow-runtime:<newest_version>`. If possible use the [latest version of the base image](https://mcr.microsoft.com/v2/azureml/promptflow/promptflow-runtime/tags/list). To use the new base image, you need to reset the runtime via the `reset` command. This process takes several minutes as it pulls the new base image and reinstalls packages.
146156
147157
:::image type="content" source="../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-image-flow-dag.png" alt-text="Screenshot of actions for customizing a base image for an automatic runtime on a flow page." lightbox = "../media/prompt-flow/how-to-create-manage-runtime/runtime-creation-automatic-image-flow-dag.png":::
148158
@@ -166,9 +176,11 @@ Automatic runtime has following advantages over compute instance runtime:
166176
- Automatic manage lifecycle of runtime and underlying compute. You don't need to manually create and managed them anymore.
167177
- Easily customize packages by adding packages in the `requirements.txt` file in the flow folder, instead of creating a custom environment.
168178

169-
We would recommend you to switch to automatic runtime if you're using compute instance runtime. If you have a compute instance runtime, you can switch it to an automatic runtime (preview) by using the following steps:
170-
- Prepare your `requirements.txt` file in the flow folder. Make sure that you don't pin the version of `promptflow` and `promptflow-tools` in `requirements.txt`, because we already include them in the runtime base image. Packages specified in `requirements.txt` will be installed when the runtime is started.
171-
- If you want to keep the automatic runtime (preview) as long running compute like compute instance, you can disable the idle shutdown toggle under automatic runtime (preview) `edit` option.
179+
We would recommend you to switch to automatic runtime, if you're using compute instance runtime. You can switch it to an automatic runtime by using the following steps:
180+
- Prepare your `requirements.txt` file in the flow folder. Make sure that you don't pin the version of `promptflow` and `promptflow-tools` in `requirements.txt`, because we already include them in the runtime base image. Automatic runtimewill install the packages in `requirements.txt` file when it starts.
181+
- If you create custom environment to create compute instance runtime, you can also use get the image from environment detail page, and specify it in `flow.dag.yaml` file in the flow folder. To learn more, see [Change the base image for automatic runtime](#change-the-base-image-for-automatic-runtime-preview). Make sure you have `acr pull` permission for the image.
182+
183+
- For compute resource, you can continue to use the existing compute instance if you would like to manually manage the lifecycle of compute resource or you can try serverless compute which lifecycle is managed by system.
172184

173185

174186
## Next steps
Loading
60 KB
Loading

articles/azure-monitor/alerts/alerts-create-log-alert-rule.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
---
22
title: Create Azure Monitor log search alert rules
3-
description: This article shows you how to create a new log search alert rule.
3+
description: This article explains how to create a new Azure Monitor log search alert rule or edit an existing rule.
44
author: AbbyMSFT
55
ms.author: abbyweisberg
66
ms.topic: how-to
77
ms.date: 02/28/2024
88
ms.reviewer: nolavime
9+
10+
#Customer intent: As a customer, I want to create a new log search alert rule or edit an existing rule so that I can monitor my resources and receive alerts when certain conditions are met.
911
---
1012

1113
# Create or edit a log search alert rule
@@ -40,13 +42,14 @@ Alerts triggered by these alert rules contain a payload that uses the [common al
4042

4143
1. On the **Logs** pane, write a query that returns the log events for which you want to create an alert. To use one of the predefined alert rule queries, expand the **Schema and filter** pane on the left of the **Logs** pane. Then select the **Queries** tab, and select one of the queries.
4244

43-
> [!NOTE]
44-
> * Log search alert rule queries do not support the 'bag_unpack()', 'pivot()' and 'narrow()' plugins.
45-
> * The word "AggregatedValue" is a reserved word, it cannot be used in the query on Log search Alerts rules.
45+
Limitations for log search alert rule queries:
46+
- Log search alert rule queries do not support the 'bag_unpack()', 'pivot()' and 'narrow()' plugins.
47+
- The word "AggregatedValue" is a reserved word, it cannot be used in the query on Log search Alerts rules.
48+
- The combined size of all data in the log alert rule properties cannot exceed 64KB.
4649

4750
:::image type="content" source="media/alerts-create-new-alert-rule/alerts-log-rule-query-pane.png" alt-text="Screenshot that shows the Query pane when creating a new log search alert rule.":::
4851

49-
1. (Optional) If you're querying an ADX or ARG cluster, Log Analytics can't automatically identify the column with the event timestamp, so we recommend that you add a time range filter to the query. For example:
52+
1. (Optional) If you're querying an ADX or ARG cluster, Log Analytics can't automatically identify the column with the event timestamp. We recommend that you add a time range filter to the query. For example:
5053

5154
```KQL
5255
adx('https://help.kusto.windows.net/Samples').table
@@ -61,9 +64,9 @@ Alerts triggered by these alert rules contain a payload that uses the [common al
6164
6265
:::image type="content" source="media/alerts-create-new-alert-rule/alerts-logs-conditions-tab.png" alt-text="Screenshot that shows the Condition tab when creating a new log search alert rule.":::
6366
64-
For sample log search alert queries that query ARG or ADX, see [Log search alert query samples](./alerts-log-alert-query-samples.md)
67+
For sample log search alert queries that query ARG or ADX, see [Log search alert query samples](./alerts-log-alert-query-samples.md).
6568
66-
For limitations:
69+
These are the limitations for using cross queries:
6770
* [Cross-service query limitations](../logs/azure-monitor-data-explorer-proxy.md#limitations)
6871
* [Combine Azure Resource Graph tables with a Log Analytics workspace](../logs/azure-monitor-data-explorer-proxy.md#combine-azure-resource-graph-tables-with-a-log-analytics-workspace)
6972
* Not supported in government clouds

articles/communication-services/quickstarts/advanced-messaging/whatsapp/get-started.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ ms.date: 02/29/2024
1010
ms.topic: quickstart
1111
ms.service: azure-communication-services
1212
ms.custom: devx-track-extended-java, devx-track-js
13-
zone_pivot_groups: acs-js-csharp-java
13+
zone_pivot_groups: acs-js-csharp-java-python
1414
---
1515

16-
# Quickstart: Add Advanced Messaging to your app
16+
# Quickstart: Send WhatsApp Messages using Advanced Messages
1717

1818
Azure Communication Services enables you to send and receive WhatsApp messages. In this quickstart, get started integrating your app with Azure Communication Advanced Messages SDK and start sending/receiving WhatsApp messages. Completing this quickstart incurs a small cost of a few USD cents or less in your Azure account.
1919

@@ -29,6 +29,10 @@ Azure Communication Services enables you to send and receive WhatsApp messages.
2929
[!INCLUDE [Send WhatsApp Messages JavaScript SDK](./includes/get-started/messages-get-started-js.md)]
3030
::: zone-end
3131

32+
::: zone pivot="programming-language-python"
33+
[!INCLUDE [Send WhatsApp Messages Python SDK](./includes/get-started/messages-quickstart-python.md)]
34+
::: zone-end
35+
3236
## Next steps
3337

3438
In this quickstart, you tried out the Advanced Messaging for WhatsApp SDK. Next you might also want to see the following articles:

articles/communication-services/quickstarts/advanced-messaging/whatsapp/includes/get-started/messages-get-started-java.md

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,14 @@ First, create a MessageTemplate using the values for a template.
235235
Here's MessageTemplate creation using a default template, `sample_template`.
236236
If `sample_template` isn't available to you, skip to [Option 2](#option-2-initiate-conversation-from-user). For advanced users, see the page [Templates](../../../../../concepts/advanced-messaging/whatsapp/template-messages.md) to understand how to send a different template with Option 1.
237237

238+
Messages SDK allows Contoso to send templated WhatsApp messages to WhatsApp users. To send template messages below details are required:
239+
- [WhatsApp Channel ID](#set-channel-registration-id)
240+
- [Recipient Phone Number in E16 format](#set-recipient-list)
241+
- Template details
242+
- Name like 'sample_template'
243+
- Language like 'en_us'
244+
- Parameters if any
245+
238246
```java
239247
// Assemble the template content
240248
String templateName = "sample_template";
@@ -267,15 +275,20 @@ To do so, from your personal WhatsApp account, send a message to your business n
267275

268276
### Send a text message to a WhatsApp user
269277

278+
Messages SDK allows Contoso to send text WhatsApp messages, which initiated WhatsApp users initiated. To send text messages below details are required:
279+
- [WhatsApp Channel ID](#set-channel-registration-id)
280+
- [Recipient Phone Number in E16 format](#set-recipient-list)
281+
- Message body/text to be sent
282+
270283
> [!IMPORTANT]
271284
> To send a text message to a WhatsApp user, the WhatsApp user must first send a message to the WhatsApp Business Account. For more information, see [Start sending messages between business and WhatsApp user](#start-sending-messages-between-a-business-and-a-whatsapp-user).
272285
273-
In the text message, provide text to send to the recipient. In this example, we reply to the WhatsApp user with the text "Thanks for your feedback.".
286+
In this example, we reply to the WhatsApp user with the text "Thanks for your feedback.\n From Notification Messaging SDK".
274287

275288
Assemble then send the text message:
276289
```java
277290
// Assemble text message
278-
TextNotificationContent textContent = new TextNotificationContent(channelRegistrationId, recipientList, "“Thanks for your feedback.");
291+
TextNotificationContent textContent = new TextNotificationContent(channelRegistrationId, recipientList, "“Thanks for your feedback.\n From Notification Messaging SDK");
279292

280293
// Send text message
281294
SendMessageResult textMessageResult = notificationClient.send(textContent);
@@ -288,10 +301,14 @@ for (MessageReceipt messageReceipt : textMessageResult.getReceipts()) {
288301

289302
### Send a media message to a WhatsApp user
290303

304+
Messages SDK allows Contoso to send Image WhatsApp messages to WhatsApp users. To send Image embedded messages below details are required:
305+
- [WhatsApp Channel ID](#set-channel-registration-id)
306+
- [Recipient Phone Number in E16 format](#set-recipient-list)
307+
- MediaUri of the Image
308+
291309
> [!IMPORTANT]
292310
> To send a text message to a WhatsApp user, the WhatsApp user must first send a message to the WhatsApp Business Account. For more information, see [Start sending messages between business and WhatsApp user](#start-sending-messages-between-a-business-and-a-whatsapp-user).
293311
294-
To send a media message, provide a URI to an image.
295312
As an example, create a URI:
296313
```java
297314
String mediaUrl = "https://aka.ms/acsicon1";
@@ -325,7 +342,7 @@ for (MessageReceipt messageReceipt : mediaMessageResult.getReceipts()) {
325342
mvn exec:java -D"exec.mainClass"="com.communication.quickstart.App" -D"exec.cleanupDaemonThreads"="false"
326343
```
327344

328-
## Sample code
345+
## Full sample code
329346

330347
Find the finalized code for this quickstart on [GitHub](https://github.com/Azure/azure-sdk-for-java/tree/d668cb44f64d303e71d2ee72a8b0382896aa09d5/sdk/communication/azure-communication-messages/src/samples/java/com/azure/communication/messages).
331348

0 commit comments

Comments
 (0)