suggest-awesome-github-copilot-instructions
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSuggest Awesome GitHub Copilot Instructions
推荐优质GitHub Copilot指令
Analyze current repository context and suggest relevant copilot-instruction files from the GitHub awesome-copilot repository that are not already available in this repository.
基于当前仓库上下文,从GitHub awesome-copilot仓库中推荐尚未在本仓库中存在的相关copilot-instruction文件。
Process
流程
- Fetch Available Instructions: Extract instruction list and descriptions from awesome-copilot README.instructions.md. Must use tool.
#fetch - Scan Local Instructions: Discover existing instruction files in folder
.github/instructions/ - Extract Descriptions: Read front matter from local instruction files to get descriptions and patterns
applyTo - Fetch Remote Versions: For each local instruction, fetch the corresponding version from awesome-copilot repository using raw GitHub URLs (e.g., )
https://raw.githubusercontent.com/github/awesome-copilot/main/instructions/<filename> - Compare Versions: Compare local instruction content with remote versions to identify:
- Instructions that are up-to-date (exact match)
- Instructions that are outdated (content differs)
- Key differences in outdated instructions (description, applyTo patterns, content)
- Analyze Context: Review chat history, repository files, and current project needs
- Compare Existing: Check against instructions already available in this repository
- Match Relevance: Compare available instructions against identified patterns and requirements
- Present Options: Display relevant instructions with descriptions, rationale, and availability status including outdated instructions
- Validate: Ensure suggested instructions would add value not already covered by existing instructions
- Output: Provide structured table with suggestions, descriptions, and links to both awesome-copilot instructions and similar local instructions AWAIT user request to proceed with installation or updates of specific instructions. DO NOT INSTALL OR UPDATE UNLESS DIRECTED TO DO SO.
- Download/Update Assets: For requested instructions, automatically:
- Download new instructions to folder
.github/instructions/ - Update outdated instructions by replacing with latest version from awesome-copilot
- Do NOT adjust content of the files
- Use tool to download assets, but may use
#fetchusingcurltool to ensure all content is retrieved#runInTerminal - Use tool to track progress
#todos
- Download new instructions to
- 获取可用指令:从awesome-copilot README.instructions.md中提取指令列表及描述。必须使用工具。
#fetch - 扫描本地指令:发现文件夹中的现有指令文件
.github/instructions/ - 提取描述信息:读取本地指令文件的前置元数据(front matter),获取描述及匹配模式
applyTo - 获取远程版本:对于每个本地指令,使用GitHub原始URL(例如:)从awesome-copilot仓库获取对应的远程版本
https://raw.githubusercontent.com/github/awesome-copilot/main/instructions/<filename> - 版本对比:对比本地指令内容与远程版本,识别:
- 已更新至最新版本的指令(完全匹配)
- 过时的指令(内容存在差异)
- 过时指令中的关键差异点(描述、applyTo模式、内容)
- 上下文分析:查看聊天历史、仓库文件及当前项目需求
- 对比现有指令:检查本仓库中已有的指令,避免重复
- 匹配相关性:将可用指令与识别出的模式及需求进行匹配
- 展示推荐选项:显示相关指令的描述、推荐理由及可用性状态(包括过时指令)
- 验证:确保推荐的指令能够提供现有指令未覆盖的价值
- 输出:提供结构化表格,包含推荐指令、描述、指向awesome-copilot指令及相似本地指令的链接 等待用户请求以继续安装或更新特定指令。除非收到明确指示,否则请勿进行安装或更新操作。
- 下载/更新资源:对于用户请求的指令,自动执行以下操作:
- 将新指令下载至文件夹
.github/instructions/ - 用awesome-copilot中的最新版本替换过时的指令
- 请勿修改文件内容
- 使用工具下载资源,也可使用
#fetch通过curl工具确保获取全部内容#runInTerminal - 使用工具跟踪进度
#todos
- 将新指令下载至
Context Analysis Criteria
上下文分析标准
🔍 Repository Patterns:
- Programming languages used (.cs, .js, .py, .ts, etc.)
- Framework indicators (ASP.NET, React, Azure, Next.js, etc.)
- Project types (web apps, APIs, libraries, tools)
- Development workflow requirements (testing, CI/CD, deployment)
🗨️ Chat History Context:
- Recent discussions and pain points
- Technology-specific questions
- Coding standards discussions
- Development workflow requirements
🔍 仓库模式:
- 使用的编程语言(.cs、.js、.py、.ts等)
- 框架标识(ASP.NET、React、Azure、Next.js等)
- 项目类型(Web应用、API、库、工具)
- 开发流程需求(测试、CI/CD、部署)
🗨️ 聊天历史上下文:
- 近期讨论的内容及痛点
- 特定技术相关的问题
- 编码规范讨论
- 开发流程需求
Output Format
输出格式
Display analysis results in structured table comparing awesome-copilot instructions with existing repository instructions:
| Awesome-Copilot Instruction | Description | Already Installed | Similar Local Instruction | Suggestion Rationale |
|---|---|---|---|---|
| blazor.instructions.md | Blazor development guidelines | ✅ Yes | blazor.instructions.md | Already covered by existing Blazor instructions |
| reactjs.instructions.md | ReactJS development standards | ❌ No | None | Would enhance React development with established patterns |
| java.instructions.md | Java development best practices | ⚠️ Outdated | java.instructions.md | applyTo pattern differs: remote uses |
以结构化表格展示分析结果,对比awesome-copilot指令与本仓库现有指令:
| Awesome-Copilot指令 | 描述 | 是否已安装 | 相似本地指令 | 推荐理由 |
|---|---|---|---|---|
| blazor.instructions.md | Blazor开发指南 | ✅ 已安装且最新 | blazor.instructions.md | 现有Blazor指令已覆盖该内容 |
| reactjs.instructions.md | ReactJS开发规范 | ❌ 未安装 | 无 | 可通过成熟模式增强React开发 |
| java.instructions.md | Java开发最佳实践 | ⚠️ 已安装但过时 | java.instructions.md | applyTo模式存在差异:远程使用 |
Local Instructions Discovery Process
本地指令发现流程
- List all files in the
*.instructions.mddirectoryinstructions/ - For each discovered file, read front matter to extract and
descriptionpatternsapplyTo - Build comprehensive inventory of existing instructions with their applicable file patterns
- Use this inventory to avoid suggesting duplicates
- 列出目录下所有
instructions/文件*.instructions.md - 对于每个发现的文件,读取YAML前置元数据以提取描述及匹配模式
applyTo - 构建现有指令的完整清单,包含其适用的文件匹配模式
- 利用该清单避免推荐重复指令
Version Comparison Process
版本对比流程
- For each local instruction file, construct the raw GitHub URL to fetch the remote version:
- Pattern:
https://raw.githubusercontent.com/github/awesome-copilot/main/instructions/<filename>
- Pattern:
- Fetch the remote version using the tool
#fetch - Compare entire file content (including front matter and body)
- Identify specific differences:
- Front matter changes (description, applyTo patterns)
- Content updates (guidelines, examples, best practices)
- Document key differences for outdated instructions
- Calculate similarity to determine if update is needed
- 对于每个本地指令文件,构造获取远程版本的GitHub原始URL:
- 格式:
https://raw.githubusercontent.com/github/awesome-copilot/main/instructions/<filename>
- 格式:
- 使用工具获取远程版本
#fetch - 对比整个文件内容(包括前置元数据和正文)
- 识别具体差异:
- 前置元数据变更(描述、applyTo模式)
- 内容更新(指南、示例、最佳实践)
- 记录过时指令的关键差异点
- 计算相似度以确定是否需要更新
File Structure Requirements
文件结构要求
Based on GitHub documentation, copilot-instructions files should be:
- Repository-wide instructions: (applies to entire repository)
.github/copilot-instructions.md - Path-specific instructions: (applies to specific file patterns via
.github/instructions/NAME.instructions.mdfrontmatter)applyTo - Community instructions: (for sharing and distribution)
instructions/NAME.instructions.md
根据GitHub文档,copilot-instructions文件应遵循以下结构:
- 仓库全局指令:(适用于整个仓库)
.github/copilot-instructions.md - 路径特定指令:(通过
.github/instructions/NAME.instructions.md前置元数据适用于特定文件匹配模式)applyTo - 社区共享指令:(用于分享和分发)
instructions/NAME.instructions.md
Front Matter Structure
前置元数据结构
Instructions files in awesome-copilot use this front matter format:
markdown
---
description: 'Brief description of what this instruction provides'
applyTo: '**/*.js,**/*.ts' # Optional: glob patterns for file matching
---awesome-copilot中的指令文件使用以下前置元数据格式:
markdown
---
description: 'Brief description of what this instruction provides'
applyTo: '**/*.js,**/*.ts' # Optional: glob patterns for file matching
---Requirements
要求
- Use tool to get content from awesome-copilot repository instructions folder
githubRepo - Scan local file system for existing instructions in directory
.github/instructions/ - Read YAML front matter from local instruction files to extract descriptions and patterns
applyTo - Compare local instructions with remote versions to detect outdated instructions
- Compare against existing instructions in this repository to avoid duplicates
- Focus on gaps in current instruction library coverage
- Validate that suggested instructions align with repository's purpose and standards
- Provide clear rationale for each suggestion
- Include links to both awesome-copilot instructions and similar local instructions
- Clearly identify outdated instructions with specific differences noted
- Consider technology stack compatibility and project-specific needs
- Don't provide any additional information or context beyond the table and the analysis
- 使用工具从awesome-copilot仓库的指令文件夹获取内容
githubRepo - 扫描本地文件系统,查找目录中的现有指令
.github/instructions/ - 读取本地指令文件的YAML前置元数据,提取描述及匹配模式
applyTo - 对比本地指令与远程版本,检测过时指令
- 与本仓库现有指令对比,避免重复推荐
- 聚焦当前指令库覆盖的空白领域
- 验证推荐的指令是否与仓库的用途及标准相符
- 为每个推荐提供清晰的理由
- 包含指向awesome-copilot指令及相似本地指令的链接
- 明确标记过时指令并注明具体差异点
- 考虑技术栈兼容性及项目特定需求
- 除表格和分析内容外,请勿提供任何额外信息或上下文
Icons Reference
图标参考
- ✅ Already installed and up-to-date
- ⚠️ Installed but outdated (update available)
- ❌ Not installed in repo
- ✅ 已安装且为最新版本
- ⚠️ 已安装但过时(有可用更新)
- ❌ 未在仓库中安装
Update Handling
更新处理
When outdated instructions are identified:
- Include them in the output table with ⚠️ status
- Document specific differences in the "Suggestion Rationale" column
- Provide recommendation to update with key changes noted
- When user requests update, replace entire local file with remote version
- Preserve file location in directory
.github/instructions/
当识别出过时指令时:
- 在输出表格中用⚠️标记其状态
- 在“推荐理由”列中记录具体差异
- 提供更新建议并注明关键变更点
- 当用户请求更新时,用远程版本替换整个本地文件
- 保留文件在目录中的位置
.github/instructions/