Share via


Use Copilot Tuning to fine-tune models for use in Microsoft 365 Copilot (preview)

This article describes how to use Copilot Tuning to create fine-tuned models in Copilot Studio you can use with declarative agents for Microsoft 365 Copilot. Fine-tuning is a process that lets you customize a pretrained model for a specific task on your own tenant data. You can use these fine-tuned models to build agents that are expert at performing domain-specific tasks and serve them in Microsoft 365 Copilot.

Fine-tuning helps your model perform better on tasks relevant to your organization. A fine-tuned model is especially useful for organizations with unique data or specialized requirements.

This article provides a basic overview of the Copilot Tuning process in Copilot Studio. For more detailed task-specific guidance to help you get best results from fine-tuning for your organization and tasks, see Copilot Tuning overview.

Benefits of Copilot Tuning

Model fine-tuning is a powerful technique used to tailor large language models to your specific needs. Fine-tuning complements other generative AI optimization techniques, such as Retrieval Augmented Generation (also known as RAG) and prompt optimization. Fine-tuning is well-suited when you want to tightly direct the behavior of your model.

Fine-tuning usually requires a team of expert data scientists to curate datasets and build task-specific data preparation and training pipelines.

Copilot Tuning in Copilot Studio greatly simplifies this process, turning it into a tool that just about any subject matter expert can use.

Copilot Studio abstracts away much of the complexity of the process. The Copilot Studio Copilot Tuning process is low-code, transforming fine-tuning from a complex, resource-heavy project into a streamlined, self-service experience.

Automated data preparation powered by AI turns noisy enterprise content into high-quality training sets with minimal effort. This automation minimizes the need to manually label by requesting human input only where model confidence is low. The automation lets you cut down on data labeling effort.

Finally, This feature saves you the effort of creating specialized data processing and training pipelines.

Security

Copilot Tuning offers enhanced security compared with conventional fine-tuning techniques by ensuring that only users with the right access controls—defined by your existing Microsoft Entra Security Groups—can use the model when building Microsoft 365 Copilot agents. Admins can also quickly remove models from production, further enhancing security.

Nobody sees your data, not even during training. All training and inference happen in tenant-isolated environments.

What kind of tasks can Copilot Tuning perform?

Currently, you can use Copilot Tuning for the following tasks:

  1. Q&A: Expert question and answer can accurately answer questions in complex knowledge domains such as HR and professional services scenarios where RAG alone would be insufficient.
  2. Document generation: Document generation excels in creating complex, structured documents that must follow specific formats, such as agreements, contracts, and technical documentation.
  3. Document summarization: Document summarization precisely distills complex information—such as regulatory or legislative analyses—into tailored summaries.

Eligibility

Copilot Tuning is an Early Access Program (EAP). See Introducing Microsoft 365 Copilot Tuning for more details on EAP eligibility.

In an organization where Copilot Tuning is available, a Microsoft 365 admin controls access. The admin can activate Copilot Tuning for the organization or tenant level. The admin can also limit access to this feature for specific users in the organization.

Access Copilot Tuning in Copilot Studio

Once your Microsoft 365 admin makes Copilot Tuning available in your tenant and grants you model-making permissions, you receive an email inviting you to start building your first model with Microsoft Copilot Studio.

To access Copilot Tuning, do the following:

  1. Sign in to Copilot Studio using a user account with the Model Maker role.

  2. In the left navigation, select the three dots (...) and then select Copilot Tuning.

    The Copilot Tuning page opens.

    If you don't see this option, Copilot Tuning isn't available for your tenant or you don't have permissions to create fine-tuned models.

Create a fine-tuned model

Copilot Tuning is a multi-step training process. As with any machine learning training process, the quality and quantity of training data are critical to the success of the model.

Note

Copilot Tuning currently only supports Sharepoint files and is limited to Word documents, PDFs, and text files.

Configure basic model parameters

First, configure high level parameters for what you want your model to do, how it should behave, and the appropriate data sources to use.

  1. Go to the Copilot Tuning page and select Create a new model. You're taken to a Customize your model to your task page.

  2. Enter a meaningful name and a description for your model.

    Describe the model in a way that users in your organization can quickly understand how it can help them in their work.

  3. Under Choose knowledge sources, select Add knowledge.

    The Add knowledge to your model page appears.

    1. Select a knowledge type. Currently, SharePoint is available.

    2. Select a knowledge source. Browse on your computer for a SharePoint file or enter a URL for the source, and then select Add.

    3. Repeat the previous step as needed to add more knowledge sources.

    4. When you're done adding knowledge sources, select Add to proceed.

  4. Under Permissions, specify the Microsoft Entra security groups that should have access to the model when it deploys.

    Copilot Tuning automatically excludes from training any files that your selected security groups can't access. Copilot Studio also automatically suggests other security groups to maximize the breadth of knowledge you can securely incorporate in your model.

  5. Under Task type, select the desired task type.

  6. In the Model Instructions section that appears, answer the questions as directed. Enter instruction information as directed. For full details, consult the detailed task-specific guidance in the Microsoft 365 Copilot Tuning documentation.

    The model instructions help Copilot Studio identify and prepare the most relevant data from your knowledge sources. Good model instructions provide the model with cues for how to interpret data during the training process.

  7. Select Save draft to save your progress, or, if you're ready to proceed with the fine-tuning process, select Prepare labeling data.

    Copilot Studio starts preparing the data for labeling.

    Copilot Studio informs you if some of your chosen knowledge sources aren't available for the chosen security groups. Copilot Studio automatically suggests other security groups to maximize the breadth of knowledge you can securely incorporate in your model.

  8. Make adjustments to the security groups to expand coverage as desired, and then select Proceed with selection.

    Copilot Studio prepares the data for labeling.

    Important

    Depending on the size of your data, the preparation can take up to 24 hours to complete. While the preparation is happening, you can continue to work in Copilot Studio or close the browser tab and return later. You receive an email notification once this step is complete. You can check status at any time by returning to Copilot Studio and refreshing the model list.

Label the training samples

Once your data is processed, Copilot Studio sends an email notification indicating that your data is ready for labeling.

Copilot Studio presents you with generated training examples relevant to the task and the data you provided. You must review the examples and provide feedback on sample quality.

Labeling is a crucial step as it would essentially teaching the model how to identify ideal training examples. Make sure individuals with domain expertise perform this task. If you aren't a domain expert, you can delegate labeling tasks to subject matter experts via a built-in labeling management workflow.

The labeling process generally goes through multiple batches. Training a model can require up to four to five batches of labels.

Once the labeling is complete, you’re ready to train your model. Select Start Training to continue.

Train the model

Copilot Studio trains the model using the labeled data. Training is a fully automated process that requires no further input from you.

Important

Depending on the size of your data, the training process can take up to 24 hours.

You receive an email notification once the training is complete. You can also check status at any time by returning to Copilot Studio and refreshing the model list.

Evaluate the model

In the final phase, you get a set of side-by-side comparisons between what results from the fine-tuned model output versus results from the baseline, non-fine-tuned model. If you want to continue to improve the quality of the model's responses, you can begin a new model training run.

To improve model outputs in your next training run, ensure your dataset is well-aligned to your model's specific task and that your data are labeled by domain experts.

Publish the model to Microsoft 365 Copilot

Once you're satisfied with the model’s output, publish the model to your Microsoft 365 tenant catalog.

Your model is now available for use by your tenant’s agents for Copilot.

Note

Only members of the security groups you selected at the start of the fine-tuning process can use the model in agents.

For more information about how to use the model in agents for Copilot, see the Microsoft 365 Copilot documentation.

Limitations and restrictions

There are some limitations and restrictions to be aware of when creating fine-tuned models:

  • If you add knowledge sources after training the model, you must restart the fine-tuning process from scratch.
  • Copilot Studio doesn't yet support model versioning.
  • If a user whose data has been used in training a model submits a valid deletion request under GDPR (or similar regulations), you must retrain the model.
  • When you fine-tune a model, the model weights are adjusted based on the training data. You can delete the fine-tuned model at any time.
  • You're responsible for how data is collected, stored, and used within your tenant environment.
  • You must ensure that your data practices meet legal requirements for transparency, consent, access, and deletion.
  • You're responsible for verifying the accuracy, appropriateness, and compliance of any outputs generated from this system before using them. Verification might require reviewing with the subject matter experts.