With the declarative agent, you can build a custom version of Copilot that can be used for specific scenarios, such as for specialized knowledge, implementing specific processes, or simply to save time by reusing a set of AI prompts. For example, a grocery shopping Copilot declarative agent can be used to create a grocery list based on a meal plan that you send to Copilot.
You can extend declarative agents using plugins to retrieve data and execute tasks on external systems. A declarative agent can utilize multiple plugins at the same time.
Prerequisites
To run this app template in your local dev machine, you will need:
- Node.js, supported versions: 18, 20, 22
- A Microsoft 365 account for development.
- Microsoft 365 Agents Toolkit Visual Studio Code Extension version 5.0.0 and higher or Microsoft 365 Agents Toolkit CLI
- Microsoft 365 Copilot license
- First, select the Microsoft 365 Agents Toolkit icon on the left in the VS Code toolbar.
- In the Account section, sign in with your Microsoft 365 account if you haven't already.
- Create app by clicking
Provisionin "Lifecycle" section. - Select
Preview in Copilot (Edge)orPreview in Copilot (Chrome)from the launch configuration dropdown. - Select your declarative agent from the
Copilotapp. - Send a prompt.
| Folder | Contents |
|---|---|
.vscode |
VSCode files for debugging |
appPackage |
Templates for the application manifest, the plugin manifest and the API specification |
env |
Environment files |
The following files can be customized and demonstrate an example implementation to get you started.
| File | Contents |
|---|---|
appPackage/declarativeCopilot.json |
Define the behaviour and configurations of the declarative agent. |
appPackage/manifest.json |
application manifest that defines metadata for your declarative agent. |
The following are Microsoft 365 Agents Toolkit specific project files. You can visit a complete guide on Github to understand how Microsoft 365 Agents Toolkit works.
| File | Contents |
|---|---|
m365agents.yml |
This is the main Microsoft 365 Agents Toolkit project file. The project file defines two primary things: Properties and configuration Stage definitions. |
