agentleFS
MicrosoftKnown publishermicrosoft/skills/.github/copilot-instructions.md

skills

Copilot instructions3.1k starsChanged 9 months agoMITView on GitHub

Agent Skills is a repository of skills, prompts, and MCP configurations for AI coding agents working with Azure SDKs and Microsoft AI Foundry services. Azure SDKs and Foundry APIs change constantly. Never work with stale knowledge. Before implementing anything with Azure/Foundry SDKs: If you skip this step and use outdated patterns, you will produce broken code. Apply these principles to every task. Don't assume. Don't hide confusion. Surface tradeoffs. Minimum code that solves the problem. Nothing speculative. The test: Would…

  • Installs packages
  • Commits and pushes

Trending

Quiet since July.thin dataabout the whole repository

Dec 2025: 0 mentionsJan 2026: 0 mentionsFeb 2026: 1 mentionMar 2026: 0 mentionsApr 2026: 0 mentionsMay 2026: 0 mentionsJun 2026: 0 mentionsJul 2026: 1 mentionAug 2026: 0 mentionsSep 2026: 0 mentionsOct 2026: 0 mentionsNov 2026: 0 mentions
Dec 2025Jun 2026Nov 2026
Mentions a month of the microsoft/skills repository that our weekly crawl found: only 2 in all, so this is a hint, not a trend. There is no adoption data for this file yet.

The file

Show its rules and text

We split this copilot-instructions.md into the rules it gives an agent

27 rules. About 0 are common, 15 are distinctive, and 12 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈15

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 12

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Before implementing anything with Azure/Foundry SDKs:

    line 11
  2. Distinctive:

    If multiple interpretations exist, present them — don't pick silently.

    line 30
  3. Distinctive:

    If a simpler approach exists, say so.

    line 31
  4. Distinctive:

    If something is unclear, stop.

    line 32
  5. Distinctive:

    No features beyond what was asked.

    line 38
  6. Distinctive:

    No abstractions for single-use code.

    line 39
  7. Distinctive:

    If you write 200 lines and it could be 50, rewrite it.

    line 41
  8. Distinctive:

    Don't "improve" adjacent code, comments, or formatting.

    line 49
  9. Distinctive:

    Don't refactor things that aren't broken.

    line 50
  10. Distinctive:

    If you notice unrelated dead code, mention it — don't delete it.

    line 52
  11. Very specific:

    Remove imports/variables/functions that YOUR changes made unused.

    line 53
  12. Distinctive:

    Don't remove pre-existing dead code unless asked.

    line 54
  13. Distinctive:

    The test: Every changed line should trace directly to the user's request.

    line 56
  14. Very specific:

    Only load skills relevant to the current task.

    line 144
  15. Very specific:

    Always use DefaultAzureCredential for production:

    line 192
  16. Very specific:

    Prefer async/await for all Azure SDK I/O

    line 218
  17. Very specific:

    Use context managers: with client: or async with client:

    line 219
  18. Very specific:

    Use create_or_update_* for idempotent operations

    line 221
  19. Distinctive:

    Use type hints on all function signatures

    line 222
  20. Very specific:

    Always use gh CLI for GitHub operations (PRs, issues, etc.) — never the MCP github-create_pull_request tool

    line 226
  21. Very specific:

    Use gh pr create for pull requests, gh issue create for issues

    line 227
  22. Distinctive:

    Before completing any code change:

    line 231
  23. Very specific:

    Create a new directory under .github/skills/<skill-name>/

    line 258
  24. Very specific:

    Use language suffix: -py, -dotnet, -ts, -java

    line 259
  25. Very specific:

    Add a SKILL.md file with YAML frontmatter:

    line 262
  26. Distinctive:

    Add detailed instructions in the markdown body

    line 269
  27. Very specific:

    Keep skills focused on a single domain

    line 270

≈ “Common” is an estimate: at least 1 in 5 of the 1,644 Copilot instructions files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
copilot-instructions.md

Copilot Instructions for Agent Skills

Project Overview

Agent Skills is a repository of skills, prompts, and MCP configurations for AI coding agents working with Azure SDKs and Microsoft AI Foundry services.

⚠️ Fresh Information First

Azure SDKs and Foundry APIs change constantly. Never work with stale knowledge.

Before implementing anything with Azure/Foundry SDKs:

  1. Search official docs first — Use the Microsoft Docs MCP (microsoft-docs) to get current API signatures, parameters, and patterns
  2. Verify SDK versions — Check pip show <package> for installed versions; APIs differ between versions
  3. Don't trust cached knowledge — Your training data is outdated. The SDK you "know" may have breaking changes.

If you skip this step and use outdated patterns, you will produce broken code.


Core Principles

Apply these principles to every task.

1. Think Before Coding

Don't assume. Don't hide confusion. Surface tradeoffs.

  • State assumptions explicitly. If uncertain, ask.
  • If multiple interpretations exist, present them — don't pick silently.
  • If a simpler approach exists, say so. Push back when warranted.
  • If something is unclear, stop. Name what's confusing. Ask.

2. Simplicity First

Minimum code that solves the problem. Nothing speculative.

  • No features beyond what was asked.
  • No abstractions for single-use code.
  • No "flexibility" or "configurability" that wasn't requested.
  • If you write 200 lines and it could be 50, rewrite it.

The test: Would a senior engineer say this is overcomplicated? If yes, simplify.

3. Surgical Changes

Touch only what you must. Clean up only your own mess.

  • Don't "improve" adjacent code, comments, or formatting.
  • Don't refactor things that aren't broken.
  • Match existing style, even if you'd do it differently.
  • If you notice unrelated dead code, mention it — don't delete it.
  • Remove imports/variables/functions that YOUR changes made unused.
  • Don't remove pre-existing dead code unless asked.

The test: Every changed line should trace directly to the user's request.

4. Goal-Driven Execution (TDD)

Define success criteria. Loop until verified.

Instead of...Transform to...
"Add validation""Write tests for invalid inputs, then make them pass"
"Fix the bug""Write a test that reproduces it, then make it pass"
"Refactor X""Ensure tests pass before and after"

Repository Structure

AGENTS.md                # Agent configuration template

.github/
├── skills/              # Backward-compat symlinks to plugin skills
│   └── */SKILL.md       # Each skill has YAML frontmatter + markdown body
├── plugins/             # Language-based plugin bundles (azure-sdk-python, etc.)
│   └── azure-sdk-*/     # Each bundle has skills/, commands/, agents/
├── prompts/             # Reusable prompt templates
├── agents/              # Agent persona definitions (backend, frontend, infrastructure, planner, presenter)
├── scripts/             # Automation scripts (doc scraping)
├── workflows/           # GitHub Actions (daily doc updates)
└── copilot-instructions.md

docs/                    # Generated llms.txt files (daily workflow) - GitHub Pages hosted
├── llms.txt             # Links + summaries
└── llms-full.txt        # Full content

skills/                  # Symlinks for backward compatibility
├── python/              # -> ../.github/skills/*-py
├── dotnet/              # -> ../.github/skills/*-dotnet
├── typescript/          # -> ../.github/skills/*-ts
├── java/                # -> ../.github/skills/*-java
└── rust/                # -> ../.github/skills/*-rust

.vscode/
└── mcp.json             # MCP server configurations

Skills

Skills are domain-specific knowledge packages in .github/skills/. Each skill has a SKILL.md with:

  • YAML frontmatter (name, description) — triggers skill loading
  • Markdown body — loaded only when skill activates

Skill Naming Convention

Skills use language suffixes for discoverability:

LanguageSuffixExamples
Core—mcp-builder, skill-creator, copilot-sdk
Python-pyazure-ai-inference-py, azure-cosmos-db-py, azure-ai-projects-py
.NET-dotnetazure-ai-inference-dotnet, azure-resource-manager-cosmosdb-dotnet
TypeScript-tsazure-ai-inference-ts, azure-ai-agents-ts, frontend-ui-dark-ts
Java-javaazure-ai-inference-java, azure-cosmos-java
Rust-rustazure-identity-rust, azure-cosmos-rust

Featured Skills

SkillPurpose
azure-search-documents-pySearch SDK patterns, vector/hybrid search, agentic retrieval
azure-ai-agents-pyLow-level agents SDK for CRUD, threads, streaming, tools
azure-ai-voicelive-pyReal-time voice AI with Azure AI Voice Live SDK
azure-ai-projects-pyHigh-level Foundry project client, versioned agents, evals
frontend-ui-dark-tsDark theme UI patterns (Vite + React + Tailwind + Framer Motion)
agent-framework-azure-ai-pyAgent Framework SDK for persistent Azure agents
mcp-builderBuilding MCP servers (Python/Node/C#)
azure-cosmos-db-pyCosmos DB NoSQL with Python/FastAPI
fastapi-router-pyFastAPI routers with CRUD, auth, response models
pydantic-models-pyPydantic v2 multi-model patterns
zustand-store-tsZustand stores with TypeScript and subscribeWithSelector
react-flow-node-tsReact Flow custom nodes with TypeScript
podcast-generationPodcast generation workflows
skill-creatorGuide for creating new skills
github-issue-creatorGitHub issue creation patterns

📖 See README.md#skill-catalog for all 130 skills

Skill Selection

Only load skills relevant to the current task. Loading all skills causes context rot — diluted attention and conflated patterns.


MCP Servers

Pre-configured Model Context Protocol servers in .vscode/mcp.json provide additional capabilities:

Documentation & Search

MCPPurpose
microsoft-docsSearch Microsoft Learn — Official Azure/Foundry docs. Use this FIRST.
context7Indexed documentation with semantic search
deepwikiAsk questions about GitHub repositories

Development Tools

MCPPurpose
githubGitHub API operations
playwrightBrowser automation and testing
terraformInfrastructure as code
eslintJavaScript/TypeScript linting

Utilities

MCPPurpose
sequentialthinkingStep-by-step reasoning for complex problems
memoryPersistent memory across sessions
markitdownConvert documents to markdown

Usage: MCPs are available when configured in your editor. Use microsoft-docs to search official documentation before implementing Azure SDK code.


SDK Quick Reference

PackagePurposeInstall
azure-ai-projectsFoundry project client, agents, evals, connectionspip install azure-ai-projects
azure-ai-agentsStandalone agents client (use via projects)pip install azure-ai-agents
azure-search-documentsAzure AI Search SDKpip install azure-search-documents
azure-identityAuthenticationpip install azure-identity

Authentication Pattern

Always use DefaultAzureCredential for production:

from azure.identity import DefaultAzureCredential
from azure.ai.projects import AIProjectClient

credential = DefaultAzureCredential()
client = AIProjectClient(
    endpoint="https://<resource>.services.ai.azure.com/api/projects/<project>",
    credential=credential
)

Environment Variables

AZURE_AI_PROJECT_ENDPOINT=https://<resource>.services.ai.azure.com/api/projects/<project>
AZURE_AI_MODEL_DEPLOYMENT_NAME=gpt-4o-mini

Conventions

Code Style

  • Prefer async/await for all Azure SDK I/O
  • Use context managers: with client: or async with client:
  • Close clients explicitly or use context managers
  • Use create_or_update_* for idempotent operations
  • Use type hints on all function signatures

Git & GitHub

  • Always use gh CLI for GitHub operations (PRs, issues, etc.) — never the MCP github-create_pull_request tool
  • Use gh pr create for pull requests, gh issue create for issues

Clean Code Checklist

Before completing any code change:

  • Functions do one thing
  • Names are descriptive and intention-revealing
  • No magic numbers or strings (use constants)
  • Error handling is explicit (no empty catch blocks)
  • No commented-out code
  • Tests cover the change

Testing Patterns

# Arrange
service = ProjectService()
expected = Project(id="123", name="test")

# Act  
result = await service.get_project("123")

# Assert
assert result == expected

Creating New Skills

  1. Create a new directory under .github/skills/<skill-name>/
    • Use language suffix: -py, -dotnet, -ts, -java
    • Core/cross-language skills have no suffix
    • Example: azure-cosmos-db-py, azure-ai-inference-dotnet, mcp-builder
  2. Add a SKILL.md file with YAML frontmatter:
    ---
    name: skill-name-py
    description: Brief description of what the skill does and when to use it
    ---
  3. Add detailed instructions in the markdown body
  4. Keep skills focused on a single domain
  5. Reference official docs via microsoft-docs MCP for current API patterns

Do's and Don'ts

Do

  • ✅ Use DefaultAzureCredential for authentication
  • ✅ Use async/await for all Azure SDK operations
  • ✅ Write tests before or alongside implementation
  • ✅ Keep functions small and focused
  • ✅ Match existing patterns in the codebase
  • ✅ Use gh CLI for all GitHub operations (PRs, issues, releases)

Don't

  • ❌ Hardcode credentials or endpoints
  • ❌ Suppress type errors (as any, @ts-ignore, # type: ignore)
  • ❌ Leave empty exception handlers
  • ❌ Refactor unrelated code while fixing bugs
  • ❌ Add dependencies without justification
  • ❌ Use GitHub MCP tools for write operations (enterprise token restrictions)

Success Indicators

These principles are working if you see:

  • Fewer unnecessary changes in diffs
  • Fewer rewrites due to overcomplication
  • Clarifying questions come before implementation (not after mistakes)
  • Clean, minimal PRs without drive-by refactoring
  • Tests that document expected behavior

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.