-
Notifications
You must be signed in to change notification settings - Fork 60.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Copilot Extensions - 3P Skillsets (public preview) (#53141)
Co-authored-by: Dimitrios Philliou <[email protected]> Co-authored-by: hubwriter <[email protected]>
- Loading branch information
1 parent
0e2ccc3
commit 0ff4b8c
Showing
33 changed files
with
355 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
56 changes: 56 additions & 0 deletions
56
...ilding-a-copilot-skillset-for-your-copilot-extension/about-copilot-skillsets.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
--- | ||
title: About Copilot skillsets | ||
intro: 'Learn what {% data variables.product.prodname_copilot_skillsets %} are and how they simplify integrating third-party tools and functions into your {% data variables.product.prodname_copilot_short %} experience.' | ||
versions: | ||
feature: copilot-extensions | ||
topics: | ||
- Copilot | ||
shortTitle: About {% data variables.product.prodname_copilot_skillsets_short %} | ||
type: overview | ||
--- | ||
|
||
{% data reusables.copilot.copilot-extensions.public-preview-note %} | ||
|
||
A skill within {% data variables.product.prodname_copilot %} is a tool that the model calls to perform a specific task in response to a user query. A skillset is a collection of these skills (up to five per skillset). {% data variables.product.prodname_copilot_skillsets %} provide a streamlined way to extend {% data variables.product.prodname_copilot_short %}’s functionality, allowing builders to integrate external services or custom API endpoints into their {% data variables.product.prodname_copilot_short %} workflow. With skillsets, builders can enable {% data variables.product.prodname_copilot_short %} to perform tasks—such as retrieving data or executing actions in third-party services—without needing to manage complex workflows or architecture. | ||
|
||
For a quickstart example of a skillset, see the "[skillset-example](https://github.com/copilot-extensions/skillset-example)" repository. For information on building a skillset, see "[AUTOTITLE](/copilot/building-copilot-extensions/building-a-copilot-skillset-for-your-copilot-extension/building-copilot-skillsets)." | ||
|
||
## How skillsets and agents differ | ||
|
||
{% data reusables.copilot.copilot-extensions.differences-between-agents-and-skillsets-1 %} | ||
{% data reusables.copilot.copilot-extensions.differences-between-agents-and-skillsets-2 %} | ||
|
||
## The extensibility platform | ||
|
||
Skillsets and agents both operate on the {% data variables.product.prodname_copilot_extensibility_platform %}, which manages the flow of user requests and function evaluations. With {% data variables.product.prodname_copilot_skillsets_short %}, the platform handles routing, prompt crafting, function calls and prompt generation. | ||
|
||
### Workflow overview | ||
|
||
The extensibility platform follows a structured workflow to process user requests and generate responses: | ||
|
||
1. **User request** | ||
A user issues a request in the {% data variables.product.prodname_copilot_chat_short %} interface, such as asking for data or executing a specific action. | ||
|
||
1. **Routing** | ||
The request is routed to the appropriate extension. For skillsets, this means the platform agent identifies and invokes the corresponding skillset based on the user’s intent. Each skill’s inference description helps the platform determine which skill to call. | ||
|
||
1. **Dynamic Prompt Crafting** | ||
{% data variables.product.prodname_copilot %} generates a prompt using: | ||
* The user’s query. | ||
* Relevant thread history. | ||
* Available functions within the skillset. | ||
* Results from any prior function calls. | ||
|
||
1. **LLM Completion** | ||
The language model (LLM) processes the prompt and determines: | ||
* Whether the user’s intent matches a skillset function. | ||
* Which function(s) to call and with what arguments. | ||
* If required, the LLM may send additional function calls to gather more context. | ||
|
||
1. **Function Evaluation** | ||
The extension invokes the selected function(s), which may involve: | ||
* Gathering relevant context, such as {% data variables.product.prodname_copilot_skillsets_short %} repository or user metadata. | ||
* Making an API call to an external service to retrieve data or execute an action. | ||
|
||
1. **Response generation** | ||
The platform iteratively refines the output, looping through prompt crafting, LLM completion, and function evaluation as needed. Once the process is complete, {% data variables.product.prodname_copilot_short %} streams a final response back to the user in the chat interface. |
82 changes: 82 additions & 0 deletions
82
...ing-a-copilot-skillset-for-your-copilot-extension/building-copilot-skillsets.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
--- | ||
title: Building Copilot skillsets | ||
intro: 'Learn the steps to build {% data variables.product.prodname_copilot_skillsets %} and integrate custom tools and functions into your Copilot environment.' | ||
versions: | ||
feature: copilot-extensions | ||
topics: | ||
- Copilot | ||
shortTitle: Build {% data variables.product.prodname_copilot_skillsets_short %} | ||
type: how_to | ||
--- | ||
|
||
{% data reusables.copilot.copilot-extensions.public-preview-note %} | ||
|
||
## Introduction | ||
|
||
{% data variables.product.prodname_copilot_skillsets %} are a streamlined way to extend {% data variables.product.prodname_copilot %}'s functionality by defining API endpoints that {% data variables.product.prodname_copilot_short %} can call. When you create a skillset, {% data variables.product.prodname_copilot_short %} handles all the AI interactions while your endpoints provide the data or functionality. This guide walks you through configuring and deploying a skillset within your {% data variables.product.prodname_github_app %}. | ||
|
||
## Prerequisites | ||
|
||
Before you begin, make sure you have the following: | ||
|
||
1. **A configured {% data variables.product.prodname_github_app %}**: You’ll need a {% data variables.product.prodname_github_app %} to act as the container for your skillset. If you haven’t already set one up, refer to "[AUTOTITLE](/copilot/building-copilot-extensions/creating-a-copilot-extension/creating-a-github-app-for-your-copilot-extension)" and "[AUTOTITLE](/copilot/building-copilot-extensions/creating-a-copilot-extension/configuring-your-github-app-for-your-copilot-extension)". | ||
1. **API endpoints**: You need one endpoint per skill. Each endpoint must: | ||
* Accept POST requests with the `application/json` MIME type | ||
* Be able to verify the signature of requests from {% data variables.product.github %} to authenticate their origin and prevent unauthorized access | ||
* Be publicly accessible via HTTPS | ||
|
||
For more information about signature verification, see "[Verifying that payloads are coming from Github](/copilot/building-copilot-extensions/building-a-copilot-agent-for-your-copilot-extension/configuring-your-copilot-agent-to-communicate-with-github#verifying-that-payloads-are-coming-from-github)". | ||
|
||
## Configuration requirements | ||
|
||
Each skillset is defined within a {% data variables.product.prodname_github_app %}. A single{% data variables.product.prodname_github_app %} can contain up to five skills. Each individual skill needs: | ||
* **Name**: A clear and descriptive name (for example, "Get Issues"). | ||
* **Inference description**: A detailed explanation of what the skill does and when to use it (for example, "Searches for external issues matching specific criteria like status and labels"). | ||
* **API endpoint**: A POST endpoint that accepts JSON requests. | ||
* **JSON schema**: The structure of data your endpoint expects. | ||
|
||
### Example JSON schema | ||
|
||
This example demonstrates a skill that requires two parameters: a status string and a label string. If no parameters are provided, an empty object with the type 'object' must be passed in as the request body. | ||
|
||
```json | ||
{ | ||
"type": "object", | ||
"properties": { | ||
"status": { | ||
"type": "string", | ||
"description": "filter issues by status (open, closed)", | ||
"enum": ["open", "closed"] | ||
}, | ||
"label": { | ||
"type": "string", | ||
"description": "filter issues by label" | ||
} | ||
} | ||
} | ||
``` | ||
|
||
This format lets users make natural-language requests like `find open security issues` and {% data variables.product.prodname_copilot_short %} will structure the appropriate API call. | ||
|
||
## Using your skillset | ||
|
||
To use your skillset: | ||
1. Type `@` followed by your extension's name. | ||
1. Type your prompt in natural language. | ||
|
||
For example: | ||
* `@skillset-example generate a lorem ipsum` | ||
* `@skillset-example give me sample data with 100 words` | ||
|
||
Copilot interprets your request and calls the appropriate skill with the right parameters. There's no need to specify which skill to use—{% data variables.product.prodname_copilot_short %} determines this from your natural-language request and the inference descriptions provided. | ||
|
||
## Setting up a skillset | ||
|
||
{% data reusables.apps.settings-step-personal-orgs %} | ||
{% data reusables.user-settings.developer_settings %} | ||
{% data reusables.user-settings.github_apps %} | ||
1. In the list of {% data variables.product.prodname_github_apps %}, click the {% data variables.product.prodname_github_app %} you want to configure for your skillset. | ||
1. In the navigation menu on the left, select **{% data variables.product.prodname_copilot_short %}**. | ||
1. Under **App Type**, select **Skillset** from the dropdown menu. | ||
1. Optionally, in the **Pre-authorization URL** field, enter the URL where users will be redirected to start the authentication process. This step is necessary if your API requires users to connect their GitHub account to access certain features or data. | ||
{% data reusables.copilot.copilot-extensions.skillsets-configuration-steps %} |
13 changes: 13 additions & 0 deletions
13
...ilot-extensions/building-a-copilot-skillset-for-your-copilot-extension/index.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
title: Building a Copilot skillset for your Copilot Extension | ||
shortTitle: Build a Copilot skillset | ||
intro: 'Learn how to build a custom {% data variables.product.prodname_copilot_skillset_short %} to combine custom skills and extend the capabilities of {% data variables.product.prodname_copilot_short %}.' | ||
versions: | ||
feature: copilot | ||
topics: | ||
- Copilot | ||
children: | ||
- /about-copilot-skillsets | ||
- /building-copilot-skillsets | ||
--- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
50 changes: 0 additions & 50 deletions
50
...ating-a-copilot-extension/configuring-your-github-app-for-your-copilot-agent.md
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.