Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1st Version to get the URL for the samplefiles #3

Merged
merged 1 commit into from
Oct 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions samples/da-CareerCoach/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# TeamsFx files
env/.env.*.user
env/.env.local
.localConfigs
appPackage/build

# dependencies
node_modules/

# misc
.env
.deployment
.DS_Store
5 changes: 5 additions & 0 deletions samples/da-CareerCoach/.vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"recommendations": [
"TeamsDevApp.ms-teams-vscode-extension"
]
}
27 changes: 27 additions & 0 deletions samples/da-CareerCoach/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Preview in Copilot (Edge)",
"type": "msedge",
"request": "launch",
"url": "https://www.office.com/chat?auth=2",
"presentation": {
"group": "remote",
"order": 1
},
"internalConsoleOptions": "neverOpen"
},
{
"name": "Preview in Copilot (Chrome)",
"type": "chrome",
"request": "launch",
"url": "https://www.office.com/chat?auth=2",
"presentation": {
"group": "remote",
"order": 2
},
"internalConsoleOptions": "neverOpen"
}
]
}
11 changes: 11 additions & 0 deletions samples/da-CareerCoach/.vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"debug.onTaskErrors": "abort",
"json.schemas": [
{
"fileMatch": [
"/aad.*.json"
],
"schema": {}
}
]
}
55 changes: 55 additions & 0 deletions samples/da-CareerCoach/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Overview of the Career Coach declarative agent sample
![CareerCoach Start Screen](assets/CareerCoach1.png)

The "Career Coach" Declarative Agent is an open-source AI-driven tool designed to assist professionals in their career development. This agent provides personalized suggestions and actionable plans to help users learn and grow in their careers. By leveraging data such as the user's current role, skills, and career aspirations, the Career Coach offers tailored advice on skill development, learning opportunities, and career transitions. It maintains a professional and supportive tone, ensuring that interactions are contextual and relevant. The agent integrates with OneDrive, SharePoint, and Graph Connectors to enhance its capabilities. Key features include creating detailed career development plans, performing skill gap analyses, recommending learning resources, and offering networking strategies. This open-source project aims to empower individuals to achieve their career goals through structured guidance and support.


## Build a basic declarative agent

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.

## Get started with the template

> **Prerequisites**
>
> To run this app template in your local dev machine, you will need:
>
> - [Node.js](https://nodejs.org/), supported versions: 16, 18
> - A [Microsoft 365 account for development](https://docs.microsoft.com/microsoftteams/platform/toolkit/accounts).
> - [Teams Toolkit Visual Studio Code Extension](https://aka.ms/teams-toolkit) version 5.0.0 and higher or [Teams Toolkit CLI](https://aka.ms/teamsfx-toolkit-cli)
> - [Microsoft 365 Copilot license](https://learn.microsoft.com/microsoft-365-copilot/extensibility/prerequisites#prerequisites)

![CareerCoach in Action](assets/CareerCoach2.png)

1. First, select the Teams Toolkit icon on the left in the VS Code toolbar.
2. In the Account section, sign in with your [Microsoft 365 account](https://docs.microsoft.com/microsoftteams/platform/toolkit/accounts) if you haven't already.
3. Create Teams app by clicking `Provision` in "Lifecycle" section.
4. Select `Preview in Copilot (Edge)` or `Preview in Copilot (Chrome)` from the launch configuration dropdown.
5. Once the Copilot app is loaded in the browser, click on the "…" menu and select "Copilot chats". You will see your declarative agent on the right rail. Clicking on it will change the experience to showcase the logo and name of your declarative agent.
6. Ask a question to your declarative agent and it should respond based on the instructions provided.

## What's included in the template

| Folder | Contents |
| ------------ | ---------------------------------------------------------------------------------------- |
| `.vscode` | VSCode files for debugging |
| `appPackage` | Templates for the Teams application manifest, the GPT 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/declarativeAgent.json` | Define the behaviour and configurations of the declarative agent. |
| `appPackage/instruction.txt` | Specific instruction for the declarative agent. In a TXT file for ease of edition automatically scafold by TTK when solution is provisionned. |
| `appPackage/manifest.json` | Teams application manifest that defines metadata for your declarative agent. |

The following are Teams Toolkit specific project files. You can [visit a complete guide on Github](https://github.com/OfficeDev/TeamsFx/wiki/Teams-Toolkit-Visual-Studio-Code-v5-Guide#overview) to understand how Teams Toolkit works.

| File | Contents |
| -------------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| `teamsapp.yml` | This is the main Teams Toolkit project file. The project file defines two primary things: Properties and configuration Stage definitions. |

## Addition information and references

- [Declarative agents for Microsoft 365](https://aka.ms/teams-toolkit-declarative-agent)
Binary file added samples/da-CareerCoach/appPackage/color.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
41 changes: 41 additions & 0 deletions samples/da-CareerCoach/appPackage/declarativeAgent.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"$schema": "https://aka.ms/json-schemas/copilot/declarative-agent/v1.0/schema.json",
"version": "v1.0",
"name": "Career Coach",
"description": "Career Coach is a declarative Agent that provides professionals with personalized suggestions on how they can continue to learn and grow in their careers.",
"instructions": "$[file('instruction.txt')]",
"capabilities": [
{
"name": "OneDriveAndSharePoint"
},
{
"name": "GraphConnectors"
}
],
"conversation_starters": [
{
"title": "Career development plan",
"text": "Help me create a detailed career development plan based on my current role and future goals."
},
{
"title": "Skill gap analysis",
"text": "Analyze my current skills and identify any gaps that I need to fill to advance in my career."
},
{
"title": "Learning opportunities",
"text": "What courses, certifications, or workshops would you recommend for someone in my role to grow professionally?"
},
{
"title": "Career transition advice",
"text": "I am considering a career transition. How can I make this change successfully?"
},
{
"title": "Networking strategies",
"text": "How can I leverage my professional network to help?"
},
{
"title": "Performance improvement",
"text": "How can I improve my performance in my current role to prepare for future opportunities?"
}
]
}
22 changes: 22 additions & 0 deletions samples/da-CareerCoach/appPackage/instruction.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
Purpose:
You are an expert Career Coach. Your role is to provide professionals with personalized suggestions on how they can continue to learn and grow in their careers.

Goals:
* Understand user's current role: You will use all available data such as user's title and other corporate information to learn about the user current role and provide that as a first response. You will tailor your advice based on the user current role, considering the future steps that are possible in their career path, and help them create a plan of action. Start by asking the user to describe their current role, including their responsibilities, skills, and any challenges they face.
* Identify Career Goals: Ask the user about their short-term and long-term career goals. What positions or roles are they aiming for in the future?
* Assess Skills and Gaps: Evaluate the skills the user currently possesses and identify any gaps that need to be filled to achieve their career goals.
* Suggest Learning Opportunities: Provide recommendations using internal resources for courses, certifications, workshops, or other learning opportunities that can help the user acquire the necessary skills and ensure these are tailored to the user.
* Create a Plan of Action: Help the user develop a step-by-step plan to achieve their career goals. This plan should include specific actions, timelines, and milestones. Start by asking the user to describe their current role and career aspirations. If asked to provide a detailed career development plan, always provide a very detailed plan with Immediate Actions, Next 3 Months, Next 6 Months, Next 1-2 Years and Ongoing.
* Career transition: When asked to give career transition advice, your first question should be: What new position is the user looking to achieve? Your second question should be: In what timeframe? Based on the answers, create a detailed career transition plan that aligns with the specified timeframe. Your response should include a Company Support section that includes specific company information and links to documents on how the company will support career transitions.

Overall direction:
* Always make your responses contextual and relevant to the role the user is currently working on, or the types of roles I want to work in.
* Never overwhelm me with multiple questions at once.
* Make sure to ask clarifying and follow-up questions.
* Always be encouraging.
* Maintain a professional and supportive tone throughout our interactions.
* Keep context across the entire conversation, ensuring that the ideas and responses are related to all the previous turns of conversation.
* After discussing each subtopic, you will ask if I have any follow-up questions or need any further help.
* If greeted or asked what you can do, please briefly explain your purpose. Keep it concise and to the point, giving some short examples.
* If you are asked to answer questions unrelated to your purpose, you can answer but try to get the user back to focus on your purpose and goals. Always try to keep the focus of the conversation about career and career progression.
* At end of each conversation ask how you did and encourage the use of the thumbs up or down option for feedback.
39 changes: 39 additions & 0 deletions samples/da-CareerCoach/appPackage/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/teams/v1.19/MicrosoftTeams.schema.json",
"manifestVersion": "1.19",
"version": "1.0.0",
"id": "${{TEAMS_APP_ID}}",
"developer": {
"name": "Teams App, Inc.",
"websiteUrl": "https://www.example.com",
"privacyUrl": "https://www.example.com/privacy",
"termsOfUseUrl": "https://www.example.com/termofuse"
},
"icons": {
"color": "color.png",
"outline": "outline.png"
},
"name": {
"short": "Career Coach",
"full": "Career Coach"
},
"description": {
"short": "Elevate your career with Career Coach",
"full": "Career Coach is designed to guide you through every step of your professional journey. Whether you're looking to advance in your current role, explore new opportunities, or bridge skill gaps, Career Coach provides personalized, actionable advice tailored to your unique career path. Career Coach is designed to work with Microsoft 365 Copilot."
},
"accentColor": "#FFFFFF",
"composeExtensions": [],
"permissions": [
"identity",
"messageTeamMembers"
],
"copilotAgents": {
"declarativeAgents": [
{
"id": "declarativeAgent",
"file": "declarativeAgent.json"
}
]
},
"validDomains": []
}
Binary file added samples/da-CareerCoach/appPackage/outline.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added samples/da-CareerCoach/assets/CareerCoach1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added samples/da-CareerCoach/assets/CareerCoach2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
68 changes: 68 additions & 0 deletions samples/da-CareerCoach/assets/sample.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
[
{
"name": "pnp-copilot-pro-dev-CareerCoach",
"source": "pnp",
"title": "Career Coach Declarative Agent for Microsoft 365 Copilot Sample",
"shortDescription": "First Party Declarative Agent Career Coach shared as a sample",
"url": "https://github.com/pnp/copilot-pro-dev-samples/tree/main/samples/da-repairs-oauth",
"downloadUrl": "https://pnp.github.io/download-partial/?url=https://github.com/pnp/copilot-pro-dev-samples/tree/main/samples/da-repairs-oauth",
"longDescription": [
"The \"Career Coach\" Declarative Agent is an open-source AI-driven tool designed to assist professionals in their career development. This agent provides personalized suggestions and actionable plans to help users learn and grow in their careers. By leveraging data such as the user's current role, skills, and career aspirations, the Career Coach offers tailored advice on skill development, learning opportunities, and career transitions. It maintains a professional and supportive tone, ensuring that interactions are contextual and relevant. The agent integrates with OneDrive, SharePoint, and Graph Connectors to enhance its capabilities. Key features include creating detailed career development plans, performing skill gap analyses, recommending learning resources, and offering networking strategies. This open-source project aims to empower individuals to achieve their career goals through structured guidance and support. 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. To run this app template in your local dev machine, you will need Node.js (supported versions: 16, 18), a Microsoft 365 account for development, Teams Toolkit Visual Studio Code Extension version 5.0.0 and higher or Teams Toolkit CLI, and a Microsoft 365 Copilot license. First, select the Teams 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 Teams app by clicking `Provision` in \"Lifecycle\" section. Select `Preview in Copilot (Edge)` or `Preview"
],
"creationDateTime": "2024-10-04",
"updateDateTime": "2024-10-04",
"products": [
"Microsoft 365 Copilot"
],
"metadata": [
{
"key": "PLATFORM",
"value": "Node.js"
},
{
"key": "LANGUAGE",
"value": "TypeScript"
},
{
"key": "API-PLUGIN",
"value": "Yes"
},
{
"key": "GRAPH-CONNECTOR",
"value": "No"
}
],
"thumbnails": [
{
"type": "image",
"order": 100,
"url": "https://github.com/pnp/copilot-pro-dev-samples/raw/main/samples/da-repairs-oauth/assets/screenshot.png",
"alt": "Declarative agent answering questions about repairs using the information from an API secured with OAuth"
}
],
"authors": [
{
"gitHubAccount": "waldekmastykarz",
"pictureUrl": "https://github.com/waldekmastykarz.png",
"name": "Waldek Mastykarz"
}
],
"references": [
{
"name": "Microsoft 365 Copilot extensibility",
"description": "Learn more about what Microsoft 365 Copilot and how you can extend it.",
"url": "https://learn.microsoft.com/microsoft-365-copilot/extensibility/"
},
{
"name": "Declarative agents for Microsoft 365 Copilot overview",
"description": "Learn more about what declarative agents for Microsoft 365 Copilot are.",
"url": "https://learn.microsoft.com/microsoft-365-copilot/extensibility/overview-declarative-agent"
},
{
"name": "Build a declarative agent for Microsoft 365 Copilot",
"description": "Learn how to build a declarative agent for Microsoft 365 Copilot.",
"url": "https://learn.microsoft.com/microsoft-365-copilot/extensibility/build-declarative-agents"
}
]
}
]
8 changes: 8 additions & 0 deletions samples/da-CareerCoach/env/.env.dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# This file includes environment variables that will be committed to git by default.

# Built-in environment variables
TEAMSFX_ENV=dev
APP_NAME_SUFFIX=dev

# Generated during provision, you can also add your own variables.
TEAMS_APP_ID=
Loading
Loading