typespec-create-agent by github/awesome-copilot
npx skills add https://github.com/github/awesome-copilot --skill typespec-create-agent为 Microsoft 365 Copilot 创建一个完整的 TypeSpec 声明式智能体,结构如下:
生成一个 main.tsp 文件,包含:
@agent 装饰器,并附带描述性名称和描述
* 名称应不超过 100 个字符
* 描述应不超过 1,000 个字符@instructions 装饰器,附带清晰的行为准则
* 定义智能体的角色、专业领域和个性
* 明确智能体应该做什么和不应该做什么
* 保持在 8,000 个字符以内@conversationStarter 装饰器
* 每个启动器包含一个标题和一个示例查询
* 使其多样化,展示不同的能力WebSearch - 用于网络内容搜索,可指定网站范围
* OneDriveAndSharePoint - 用于文档访问,可进行 URL 过滤
* TeamsMessages - 用于 Teams 频道/聊天访问
* - 用于邮件访问,可进行文件夹过滤
* - 用于组织内人员搜索
* - 用于执行 Python 代码
* - 用于图像生成
* - 用于 Copilot 连接器内容
* - 用于 Dataverse 数据访问
* - 用于会议内容访问广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
EmailPeopleCodeInterpreterGraphicArtGraphConnectorsDataverseMeetingsimport "@typespec/http";
import "@typespec/openapi3";
import "@microsoft/typespec-m365-copilot";
using TypeSpec.Http;
using TypeSpec.M365.Copilot.Agents;
@agent({
name: "[智能体名称]",
description: "[智能体描述]"
})
@instructions("""
[关于智能体行为、角色和准则的详细说明]
""")
@conversationStarter(#{
title: "[启动器标题 1]",
text: "[示例查询 1]"
})
@conversationStarter(#{
title: "[启动器标题 2]",
text: "[示例查询 2]"
})
namespace [AgentName] {
// 在此处添加能力作为操作
op capabilityName is AgentCapabilities.[CapabilityType]<[Parameters]>;
}
询问用户:
然后生成完整的 TypeSpec 智能体定义。
每周安装量
7.3K
代码仓库
GitHub 星标数
26.9K
首次出现
2026年2月25日
安全审计
安装于
codex7.2K
gemini-cli7.2K
opencode7.2K
cursor7.2K
github-copilot7.2K
kimi-cli7.2K
Create a complete TypeSpec declarative agent for Microsoft 365 Copilot with the following structure:
Generate a main.tsp file with:
Agent Declaration
@agent decorator with a descriptive name and descriptionInstructions
@instructions decorator with clear behavioral guidelinesConversation Starters
@conversationStarter decoratorsCapabilities (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 accessimport "@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]>;
}
Ask the user:
Then generate the complete TypeSpec agent definition.
Weekly Installs
7.3K
Repository
GitHub Stars
26.9K
First Seen
Feb 25, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
codex7.2K
gemini-cli7.2K
opencode7.2K
cursor7.2K
github-copilot7.2K
kimi-cli7.2K
React 组合模式指南:Vercel 组件架构最佳实践,提升代码可维护性
102,200 周安装
Meetings - for meeting content access