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/machine-learning/prompt-flow/tools-reference/llm-tool.md
+10-4Lines changed: 10 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,12 +16,12 @@ ms.date: 11/02/2023
16
16
17
17
# LLM tool
18
18
19
-
The large language model (LLM) tool in prompt flow enables you to take advantage of widely used large language models like [OpenAI](https://platform.openai.com/) or [Azure OpenAI Service](../../../cognitive-services/openai/overview.md) for natural language processing.
19
+
The large language model (LLM) tool in prompt flow enables you to take advantage of widely used large language models like [OpenAI](https://platform.openai.com/), [Azure OpenAI Service](../../../cognitive-services/openai/overview.md), or any language model supported by the [Azure AI model inference API](https://aka.ms/azureai/modelinference) for natural language processing.
20
20
21
21
Prompt flow provides a few different large language model APIs:
22
22
23
23
-[Completion](https://platform.openai.com/docs/api-reference/completions): OpenAI's completion models generate text based on provided prompts.
24
-
-[Chat](https://platform.openai.com/docs/api-reference/chat): OpenAI's chat models facilitate interactive conversations with text-based inputs and responses.
24
+
-[Chat](https://platform.openai.com/docs/api-reference/chat): OpenAI's chat models and the [Azure AI](https://aka.ms/azureai/modelinference) chat models facilitate interactive conversations with text-based inputs and responses.
25
25
26
26
> [!NOTE]
27
27
> We removed the `embedding` option from the LLM tool API setting. You can use an embedding API with the [embedding tool](embedding-tool.md).
@@ -41,6 +41,11 @@ Create OpenAI resources:
41
41
42
42
- Create Azure OpenAI resources with [these instructions](../../../ai-services/openai/how-to/create-resource.md).
43
43
44
+
-**Models deployed to Serverless API endpoints**
45
+
46
+
- Select the model from the catalog you are interested in [and deploy it with a serverless API endpoint](../../how-to-deploy-models-serverless.md).
47
+
- To use models deployed to serverless API endpoints supported by the [Azure AI model inference API](https://aka.ms/azureai/modelinference), like Mistral, Cohere, Meta Llama, or Microsoft family of models (among others), you need to [create a connection in your project to your endpoint](../../how-to-connect-models-serverless.md?#create-a-serverless-api-endpoint-connection).
48
+
44
49
## Connections
45
50
46
51
Set up connections to provisioned resources in prompt flow.
@@ -50,6 +55,7 @@ Set up connections to provisioned resources in prompt flow.
> - To use Microsoft Entra ID auth type for Azure OpenAI connection, you need assign either the `Cognitive Services OpenAI User` or `Cognitive Services OpenAI Contributor role` to user or user assigned managed identity.
@@ -83,7 +89,7 @@ The following sections show various inputs.
| prompt | string | Text prompt that the language model uses for a response. | Yes |
86
-
| model, deployment_name | string | Language model to use. | Yes|
92
+
| model, deployment_name | string | Language model to use. This parameter is not required if the model is deployed to a serverless API endpoint. | Yes*|
87
93
| max\_tokens | integer | Maximum number of tokens to generate in the response. Default is inf. | No |
88
94
| temperature | float | Randomness of the generated text. Default is 1. | No |
89
95
| stop | list | Stopping sequence for the generated text. Default is null. | No |
@@ -101,6 +107,6 @@ The following sections show various inputs.
101
107
102
108
## Use the LLM tool
103
109
104
-
1. Set up and select the connections to OpenAI resources.
110
+
1. Set up and select the connections to OpenAI resources or to a serverless API endpoint.
105
111
1. Configure the large language model API and its parameters.
106
112
1. Prepare the prompt with [guidance](prompt-tool.md#write-a-prompt).
0 commit comments