Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/managedcode/dotnet-skills/microsoft-extensions-ainpx skills add managedcode/dotnet-skills --skill microsoft-extensions-aigit clone --depth 1 https://github.com/managedcode/dotnet-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/managedcode/dotnet-skills/microsoft-extensions-ai)<a href="https://agentmods.dev/skills/managedcode/dotnet-skills/microsoft-extensions-ai"><img src="https://agentmods.dev/badge/skills/managedcode/dotnet-skills/microsoft-extensions-ai.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00128 | $0.02781 |
| Opus 5 | $0.00064 | $0.01391 |
| Sonnet 5 | $0.00026 | $0.00556 |
| Haiku 4.5 | $0.00013 | $0.00278 |
Grade A, and why
microsoft-extensions-ai scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
Copies of this mod
1 near-identical copy found in the catalogue:
- dotnet-microsoft-extensions-ai — 88% identical, 23 lines differ
How it starts
The opening of the file, as written. The whole thing — 119 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Microsoft.Extensions.AI
Trigger On
- building or reviewing
.NETcode that usesMicrosoft.Extensions.AI,Microsoft.Extensions.AI.Abstractions,IChatClient,IEmbeddingGenerator,ChatOptions, orAIFunction - adding
IImageGenerator, local-model chat via Ollama, AI app templates, or the.NET AIquickstarts for assistants and MCP - choosing between low-level AI abstractions, provider SDKs, vector-search composition, evaluation libraries, and a fuller agent framework
- adding streaming chat, structured output, embeddings, tool calling, telemetry, caching, or DI-based AI middleware
- wiring
Microsoft.Extensions.VectorData,Microsoft.Extensions.DataIngestion, MCP tooling, or evaluation packages around a provider-agnostic AI app
Workflow
- Classify the request first: plain model access, tool calling, embeddings/vector search, evaluation, image generation, local-model prototyping, MCP bootstrap, or true agent orchestration.
- Default to
Microsoft.Extensions.AIfor application and service code that needs provider-agnostic chat, embeddings, middleware, structured output, and testability. - Reference
Microsoft.Extensions.AI.Abstractionsdirectly only when authoring provider libraries or lower-level reusable integration packages. - Model
IChatClientandIEmbeddingGeneratorcomposition explicitly in DI. Keep options, caching, telemetry, logging, and tool invocation inspectable in the pipeline. - Treat chat state deliberately. For stateless providers, resend history. For stateful providers, propagate
ConversationIdrather than assuming all providers behave the same way. - Use
Microsoft.Extensions.VectorDataandMicrosoft.Extensions.DataIngestionas adjacent building blocks for RAG instead of hand-rolling store abstractions prematurely. Treat the embedding model, vector dimensions, and collection schema as one owned contract: changing any of them means reindexing rather than reusing old vector data. Keep vector API source-breaking notes version-aware; in the 10.5+ line, named-argument usage ofVectorStoreVectorAttributeusesdimensions:. - Treat the
.NET AIquickstarts as bootstrap paths, not finished architecture. They now cover minimal assistants, MCP client/server flows, local models, app templates, and image generation. Start there for a vertical slice, then harden the DI, telemetry, and evaluation story here. - Escalate to
microsoft-agent-frameworkwhen the requirement becomes agent threads, multi-agent orchestration, higher-order workflows, durable execution, or remote agent hosting. - Validate with real providers, realistic prompts, and evaluation gates so the abstraction layer actually buys portability and reliability.
What ships with it
60 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- manifest.json 92 B
- references/evaluation.md 3.7 KB
- references/examples.md 4.6 KB
- references/official-docs-index.md 10 KB
- references/official-docs/azure-ai-services-authentication.md 8.9 KB
- references/official-docs/conceptual/agents.md 3.7 KB
- references/official-docs/conceptual/calling-tools.md 5.5 KB
- references/official-docs/conceptual/chain-of-thought-prompting.md 2.7 KB
- references/official-docs/conceptual/data-ingestion.md 9.1 KB
- references/official-docs/conceptual/embeddings.md 5.3 KB
- references/official-docs/conceptual/how-genai-and-llms-work.md 8.4 KB
- references/official-docs/conceptual/medi-library.md 4.2 KB
- references/official-docs/conceptual/mevd-library.md 2.4 KB
- references/official-docs/conceptual/prompt-engineering-dotnet.md 4.8 KB
- references/official-docs/conceptual/rag.md 2.7 KB
- references/official-docs/conceptual/understanding-tokens.md 6.7 KB
- references/official-docs/conceptual/zero-shot-learning.md 4.8 KB
- references/official-docs/dotnet-ai-ecosystem.md 9.7 KB
- references/official-docs/evaluation/evaluate-ai-response.md 6.9 KB
- references/official-docs/evaluation/evaluate-safety.md 13 KB
- references/official-docs/evaluation/evaluate-with-reporting.md 15 KB
- references/official-docs/evaluation/libraries.md 12 KB
- references/official-docs/evaluation/responsible-ai.md 2.3 KB
- references/official-docs/get-started-app-chat-template.md 19 KB
- references/official-docs/get-started-mcp.md 7.3 KB
- references/official-docs/how-to/access-data-in-functions.md 5.9 KB
- references/official-docs/how-to/app-service-aoai-auth.md 8.7 KB
- references/official-docs/how-to/content-filtering.md 2.7 KB
- references/official-docs/how-to/handle-invalid-tool-input.md 4.2 KB
- references/official-docs/how-to/use-tokenizers.md 5.5 KB
- references/official-docs/ichatclient.md 19 KB
- references/official-docs/iembeddinggenerator.md 4.9 KB
- references/official-docs/microsoft-extensions-ai.md 6.3 KB
- references/official-docs/overview.md 4.0 KB
- references/official-docs/quickstarts/ai-templates.md 2.0 KB
- references/official-docs/quickstarts/build-chat-app.md 4.8 KB
- references/official-docs/quickstarts/build-mcp-client.md 3.1 KB
- references/official-docs/quickstarts/build-mcp-server.md 24 KB
- references/official-docs/quickstarts/chat-local-model.md 6.3 KB
- references/official-docs/quickstarts/create-assistant.md 5.8 KB
- references/official-docs/quickstarts/generate-images.md 4.2 KB
- references/official-docs/quickstarts/includes/ai-templates-azure-openai.md 6.1 KB
- references/official-docs/quickstarts/includes/ai-templates-explore-app.md 1.0 KB
- references/official-docs/quickstarts/includes/ai-templates-ollama.md 3.8 KB
- references/official-docs/quickstarts/includes/ai-templates-openai.md 3.9 KB
- references/official-docs/quickstarts/includes/create-ai-service.md 691 B
- references/official-docs/quickstarts/includes/prerequisites-azure-openai.md 447 B
- references/official-docs/quickstarts/includes/prerequisites-openai.md 318 B
- references/official-docs/quickstarts/process-data.md 8.2 KB
- references/official-docs/quickstarts/prompt-model.md 5.2 KB
- references/official-docs/quickstarts/publish-mcp-registry.md 12 KB
- references/official-docs/quickstarts/snippets/mcp-server/README.md 2.4 KB
- references/official-docs/quickstarts/snippets/process-data/data/sample.md 373 B
- references/official-docs/quickstarts/snippets/prompt-completion/azure-openai/benefits.md 1.8 KB
- references/official-docs/quickstarts/snippets/prompt-completion/openai/benefits.md 1.8 KB
- references/official-docs/quickstarts/structured-output.md 6.1 KB
- references/official-docs/quickstarts/text-to-image.md 11 KB
- references/official-docs/quickstarts/use-function-calling.md 5.0 KB
- references/official-docs/resources/azure-ai.md 622 B
- references/official-docs/resources/mcp-servers.md 3.7 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 119 lines · 128 tokens per session scan A d99a3bb896ec
microsoft-extensions-ai is a skill published in the GitHub repository managedcode/dotnet-skills (477 stars, last pushed 4d ago), licensed MIT. It adds 128 tokens to every session and 2,781 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
close-task-commit-push-pr
Close the active backlog task (detected from branch name), commit all changes, push to remote, and open a pull request. Use when the user says "close task and ship it", "close task commit push pr", or invokes /close-task-commit-push-pr.
git-commit-push-pr
Commit all changes, push to remote, and open a pull request in one go. Use when the user says "commit push pr", "ship it", "open a pr", or invokes /git-commit-push-pr.
mutation-testing
Use when running mutation testing, killing mutants, verifying test quality, checking mutation score, or analyzing survivors after the test baseline is green.
generate-microcks-openapi-samples
Use when creating OpenAPI mock examples for Microcks, setting up request/response routing with dispatchers, or mapping request fields to mock responses.
setup-husky-dotnet
Use when configuring Git hooks in .NET projects before team commits occur, to enforce commit message standards and code formatting automatically.
analyzing-code
Use when understanding project composition by language, measuring code change impact, or generating code statistics for CI/CD metrics.