Skip to content

Commit f3075ba

Browse files
committed
fine-tuning models in studio
1 parent 66964c2 commit f3075ba

File tree

3 files changed

+17
-54
lines changed

3 files changed

+17
-54
lines changed

articles/ai-services/openai/concepts/models.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,10 @@ These models can only be used with Embedding API requests.
494494

495495
## Fine-tuning models
496496

497-
`gpt-35-turbo` - fine-tuning of this model is limited to a subset of regions, and is not available in every region the base model is available.
497+
> [!NOTE]
498+
> The supported regions might vary if you use Azure OpenAI models in an AI Studio project versus outside a project.
499+
>
500+
> `gpt-35-turbo` - fine-tuning of this model is limited to a subset of regions, and is not available in every region the base model is available.
498501
499502
| Model ID | Fine-Tuning Regions | Max Request (tokens) | Training Data (up to) |
500503
| --- | --- | :---: | :---: |

articles/ai-services/openai/includes/fine-tuning-openai-in-ai-studio.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ ms.custom: include, build-2024
1919
- An [Azure AI hub resource](../../../ai-studio/how-to/create-azure-ai-resource.md).
2020
- An [Azure AI project](../../../ai-studio/how-to/create-projects.md) in Azure AI Studio.
2121
- An [Azure OpenAI connection](/azure/ai-studio/how-to/connections-add?tabs=azure-openai#connection-details) to a resource in a [region where fine-tuning is supported](/azure/ai-services/openai/concepts/models#fine-tuning-models).
22+
> [!NOTE]
23+
> The supported regions might vary if you use Azure OpenAI models in an AI Studio project versus outside a project.
2224
- Fine-tuning access requires **Cognitive Services OpenAI Contributor** role on the Azure OpenAI resource.
2325
- If you don't already have access to view quota and deploy models in Azure AI Studio you need [more permissions](../how-to/role-based-access-control.md).
2426

articles/ai-studio/concepts/fine-tuning-overview.md

Lines changed: 11 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ms.service: azure-ai-studio
77
ms.custom:
88
- build-2024
99
ms.topic: conceptual
10-
ms.date: 5/29/2024
10+
ms.date: 10/31/2024
1111
ms.reviewer: sgilley
1212
ms.author: sgilley
1313
author: sdgilley
@@ -19,7 +19,7 @@ author: sdgilley
1919

2020
Fine-tuning retrains an existing large language model (LLM) by using example data. The result is a new, custom LLM that's optimized for the provided examples.
2121

22-
This article can help you decide whether or not fine-tuning is the right solution for your use case. This article also describes how Azure AI Studio can support your fine-tuning needs.
22+
This article can help you decide whether or not fine-tuning is the right solution for your use case. This article also describes how [Azure AI Studio](https://ai.azure.com) can support your fine-tuning needs.
2323

2424
In this article, fine-tuning refers to *supervised fine-tuning*, not continuous pretraining or reinforcement learning through human feedback (RLHF). Supervised fine-tuning is the process of retraining pretrained models on specific datasets. The purpose is typically to improve model performance on specific tasks or to introduce information that wasn't well represented when you originally trained the base model.
2525

@@ -48,9 +48,7 @@ You might not be ready for fine-tuning if:
4848
- You can't find the right data to serve the model.
4949
- You don't have a clear use case for fine-tuning, or you can't articulate more than "I want to make a model better."
5050

51-
If you identify cost as your primary motivator, proceed with caution. Fine-tuning might reduce costs for certain use cases by shortening prompts or allowing you to use a smaller model. But there's a higher upfront cost to training, and you have to pay for hosting your own custom model. For more information on fine-tuning costs in Azure OpenAI Service, refer to the [pricing page](https://azure.microsoft.com/pricing/details/cognitive-services/openai-service/).
52-
53-
If you want to add out-of-domain knowledge to the model, you should start with RAG by using features like Azure OpenAI [On Your Data](../../ai-services/openai/concepts/use-your-data.md) or [embeddings](../../ai-services/openai/tutorials/embeddings.md). Using RAG in this way is often a cheaper, more adaptable, and potentially more effective option, depending on the use case and data.
51+
If you identify cost as your primary motivator, proceed with caution. Fine-tuning might reduce costs for certain use cases by shortening prompts or allowing you to use a smaller model. But typically there's a higher upfront cost to training, and you have to pay for hosting your own custom model.
5452

5553
### What isn't working with alternate approaches?
5654

@@ -82,7 +80,7 @@ You might not be ready for fine-tuning if:
8280

8381
Even with a great use case, fine-tuning is only as good as the quality of the data that you can provide. You need to be willing to invest the time and effort to make fine-tuning work. Different models require different data volumes, but you often need to be able to provide fairly large quantities of high-quality curated data.
8482

85-
Another important point is that even with high-quality data, if your data isn't in the necessary format for fine-tuning, you'll need to commit engineering resources for the formatting. For more information on how to prepare your data for fine-tuning, refer to the [fine-tuning documentation](../../ai-services/openai/how-to/fine-tuning.md?context=/azure/ai-studio/context/context).
83+
Another important point is that even with high-quality data, if your data isn't in the necessary format for fine-tuning, you'll need to commit engineering resources for the formatting.
8684

8785
You might be ready for fine-tuning if:
8886

@@ -101,54 +99,14 @@ There isn't a single right answer to this question, but you should have clearly
10199

102100
## Supported models for fine-tuning in Azure AI Studio
103101

104-
Now that you know when to use fine-tuning for your use case, you can go to Azure AI Studio to find models available to fine-tune. The following sections describe the available models.
105-
106-
### Azure OpenAI models
107-
108-
The following Azure OpenAI models are supported in Azure AI Studio for fine-tuning:
109-
110-
| Model ID | Fine-tuning regions | Max request (tokens) | Training data (up to) |
111-
| --- | --- | :---: | :---: |
112-
| `babbage-002` | North Central US <br> Sweden Central <br> Switzerland West | 16,384 | Sep 2021 |
113-
| `davinci-002` | North Central US <br> Sweden Central <br> Switzerland West | 16,384 | Sep 2021 |
114-
| `gpt-35-turbo` (0613) | East US2 <br> North Central US <br> Sweden Central <br> Switzerland West | 4,096 | Sep 2021 |
115-
| `gpt-35-turbo` (1106) | East US2 <br> North Central US <br> Sweden Central <br> Switzerland West | Input: 16,385<br> Output: 4,096 | Sep 2021|
116-
| `gpt-35-turbo` (0125) | East US2 <br> North Central US <br> Sweden Central <br> Switzerland West | 16,385 | Sep 2021 |
117-
| `gpt-4` (0613) <sup>1<sup> | North Central US <br> Sweden Central | 8192 | Sep 2021 |
118-
119-
<sup>1</sup> GPT-4 fine-tuning is currently in public preview. For more information, see the [GPT-4 fine-tuning safety evaluation guidance](/azure/ai-services/openai/how-to/fine-tuning?tabs=turbo%2Cpython-new&pivots=programming-language-python#safety-evaluation-gpt-4-fine-tuning---public-preview).
120-
121-
To fine-tune Azure OpenAI models, you must add a connection to an Azure OpenAI resource with a supported region to your project.
122-
123-
### Phi-3 family models
124-
125-
The following Phi-3 family models are supported in Azure AI Studio for fine-tuning:
126-
127-
- `Phi-3-mini-4k-instruct`
128-
- `Phi-3-mini-128k-instruct`
129-
- `Phi-3-medium-4k-instruct`
130-
- `Phi-3-medium-128k-instruct`
131-
132-
Fine-tuning of Phi-3 models is currently supported in projects located in East US2.
133-
134-
### Meta Llama 2 family models
135-
136-
The following Llama 2 family models are supported in Azure AI Studio for fine-tuning:
137-
138-
- `Meta-Llama-2-70b`
139-
- `Meta-Llama-2-7b`
140-
- `Meta-Llama-2-13b`
141-
142-
Fine-tuning of Llama 2 models is currently supported in projects located in West US3.
143-
144-
### Meta Llama 3.1 family models
145-
146-
The following Llama 3.1 family models are supported in Azure AI Studio for fine-tuning:
147-
148-
- `Meta-Llama-3.1-70b-Instruct`
149-
- `Meta-Llama-3.1-8b-Instruct`
102+
Now that you know when to use fine-tuning for your use case, you can go to Azure AI Studio to find models available to fine-tune. The following table describes models that you can fine-tune in Azure AI Studio, along with the regions where you can fine-tune them.
150103

151-
Fine-tuning of Llama 3.1 models is currently supported in projects located in West US3.
104+
| Model family | Model ID | Fine-tuning regions |
105+
| --- | --- | --- |
106+
| [Azure OpenAI models](../../ai-services/openai/how-to/fine-tuning.md?context=/azure/ai-studio/context/context) | Azure OpenAI Service models that you can fine-tune include among others `gpt-4` and `gpt-4o-mini`.<br/><br/>For details about Azure OpenAI models that are available for fine-tuning, see the [Azure OpenAI Service models documentation](../../ai-services/openai/concepts/models.md#fine-tuning-models). | Azure OpenAI Service models that you can fine-tune include among others North Central US and Sweden Central.<br/><br/>The supported regions might vary if you use Azure OpenAI models in an AI Studio project versus outside a project.<br/><br/>For details about fine-tuning regions, see the [Azure OpenAI Service models documentation](../../ai-services/openai/concepts/models.md#fine-tuning-models). |
107+
| [Phi-3 family models](../how-to/fine-tune-phi-3.md) | `Phi-3-mini-4k-instruct`<br/>`Phi-3-mini-128k-instruct`<br/>`Phi-3-medium-4k-instruct`<br/>`Phi-3-medium-128k-instruct` | East US2 |
108+
| [Meta Llama 2 family models](../how-to/fine-tune-model-llama.md) | `Meta-Llama-2-70b`<br/>`Meta-Llama-2-7b`<br/>`Meta-Llama-2-13b` | West US3 |
109+
| [Meta Llama 3.1 family models](../how-to/fine-tune-model-llama.md) | `Meta-Llama-3.1-70b-Instruct`<br/>`Meta-Llama-3.1-8b-Instruct` | West US3 |
152110

153111
## Related content
154112

0 commit comments

Comments
 (0)