Typespec Create Agent
GitHubOfficialOriginally contributed by @troystaylor as prompts/typespec-create-agent.prompt.md; moved into a skill by pull request #761Distributed by GitHub
- Skill
- Content generator
- Software development
- MIT
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill assists developers in creating declarative agents for Microsoft 365 Copilot using the TypeSpec language. It guides the user through defining agent metadata, behavioral instructions, conversation starters, and specific capabilities, resulting in a structured main.tsp file ready for implementation.
What it does
- Generates TypeSpec code for Microsoft 365 Copilot agents.
- Structures agent declarations with names and descriptions.
- Drafts behavioral instructions and role-based guidelines.
- Configures conversation starters to showcase agent capabilities.
- Maps specific capabilities like WebSearch, Email, or Dataverse to the agent definition.
When to use it
- When you need to build a custom declarative agent for Microsoft 365 Copilot.
- When you want to ensure your agent definition follows standard TypeSpec syntax.
- When you need to quickly scaffold the structure of an agent including its capabilities.
Advantages
- Ensures consistent structure for agent definitions.
- Simplifies the integration of various M365 Copilot capabilities.
- Promotes best practices by encouraging scoped capabilities and clear instructions.
Usage examples
- “Create a TypeSpec agent for a project manager that can access SharePoint documents and Teams messages.”
- The agent generates a main.tsp file with the @agent decorator, instructions for a project management role, and the necessary capability operations for OneDriveAndSharePoint and TeamsMessages.
Install
Download the skill as a ZIP:
https://mp-staging.autogineer.com/agent-skills/github/typespec-create-agent/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip typespec-create-agent.zip -d .agents/skills
Documentation by troystaylor
Create TypeSpec Declarative Agent
Create a complete TypeSpec declarative agent for Microsoft 365 Copilot with the following structure:
Requirements
Generate a main.tsp file with:
Agent Declaration
Use
@agentdecorator with a descriptive name and descriptionName should be 100 characters or less
Description should be 1,000 characters or less
Instructions
Use
@instructionsdecorator with clear behavioral guidelinesDefine the agent's role, expertise, and personality
Specify what the agent should and shouldn't do
Keep under 8,000 characters
Conversation Starters
Include 2-4
@conversationStarterdecoratorsEach with a title and example query
Make them diverse and showcase different capabilities
Capabilities (based on user needs)
WebSearch- for web content with optional site scopingOneDriveAndSharePoint- for document access with URL filteringTeamsMessages- for Teams channel/chat accessEmail- for email access with folder filteringPeople- for organization people searchCodeInterpreter- for Python code executionGraphicArt- for image generationGraphConnectors- for Copilot connector contentDataverse- for Dataverse data accessMeetings- for meeting content access
Template Structure
import "@typespec/http";
import "@typespec/openapi3";
import "@microsoft/typespec-m365-copilot";
using TypeSpec.Http;
using TypeSpec.M365.Copilot.Agents;
@agent({
name: "[Agent Name]",
description: "[Agent Description]"
})
@instructions("""
[Detailed instructions about agent behavior, role, and guidelines]
""")
@conversationStarter(#{
title: "[Starter Title 1]",
text: "[Example query 1]"
})
@conversationStarter(#{
title: "[Starter Title 2]",
text: "[Example query 2]"
})
namespace [AgentName] {
// Add capabilities as operations here
op capabilityName is AgentCapabilities.[CapabilityType]<[Parameters]>;
}Best Practices
Use descriptive, role-based agent names (e.g., "Customer Support Assistant", "Research Helper")
Write instructions in second person ("You are...")
Be specific about the agent's expertise and limitations
Include diverse conversation starters that showcase different features
Only include capabilities the agent actually needs
Scope capabilities (URLs, folders, etc.) when possible for better performance
Use triple-quoted strings for multi-line instructions
Examples
Ask the user:
What is the agent's purpose and role?
What capabilities does it need?
What knowledge sources should it access?
What are typical user interactions?
Then generate the complete TypeSpec agent definition.
Files
- ATTRIBUTION.mdAdded by AutoGineer1.1 KiB
- LICENSELicence file added by AutoGineer1.0 KiB
- SKILL.md2.9 KiB
ATTRIBUTION.md
Attribution
This folder is an unmodified copy of the Agent Skill "typespec-create-agent", distributed by AutoGineer (https://autogineer.com/agent-skills).
Commit: 797337f33f73e35d08d82f840e21c4b8c4932d88
Originally contributed by: @troystaylor (https://github.com/troystaylor) as prompts/typespec-create-agent.prompt.md (history: https://github.com/github/awesome-copilot/commits/9efb8cd3885ad3a445e11de2b6cc7ab3abcbdef6/prompts/typespec-create-agent.prompt.md); moved into a skill by pull request #761 (https://github.com/github/awesome-copilot/pull/761)
Publisher: GitHub (https://github.com/github)
Licence: MIT License (https://github.com/github/awesome-copilot/blob/797337f33f73e35d08d82f840e21c4b8c4932d88/LICENSE)
Licence evidence: repository licence LICENSE
Retrieved: 2026-11-07
The skill's own files are unmodified copies. AutoGineer is not affiliated with or endorsed by the author or the publisher.
Files added by AutoGineer
ATTRIBUTION.md: this file, written by AutoGineer
LICENSE: copied from LICENSE
Requirements and compatibility
Written for: GitHub Copilot, Claude Code
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Names Claude Code tools
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Originally contributed by
@troystayloras prompts/typespec-create-agent.prompt.mdmoved into a skill by pull request #761
- Publisher
- GitHub (Official)
- Distributed by
- GitHub
- Source
- github/awesome-copilot · skills/typespec-create-agent · commit 797337f
- Licence
- MIT License (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
- Contributors
- troystaylor
AutoGineer is not affiliated with or endorsed by troystaylor or GitHub.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download typespec-create-agent.zip