跳到正文
Skillpedia
通用编程5.8k · #14651

csharp-expert

它能做什么

这项技能作为 C# 和 .NET 工作的入口。它判断哪一项专门技能适合该请求,并为缺少的技能提供安装步骤。适合不确定该使用哪个 .NET 工具或指南的开发者。

适用场景

  • ✓当你不确定哪位 .NET 专家应处理某个 C# 或 .NET 任务时。
  • ✓当你需要了解如何添加涵盖你任务的 dotnet skills 插件时。
  • ✓当一个 .NET 请求涉及多个方面,例如 API、其数据层和测试的时候。

技能链接

https://github.com/dotnet/skills/blob/main/plugins/dotnet/skills/csharp-expert/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/dotnet/skills/blob/main/plugins/dotnet/skills/csharp-expert/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“我需要在 .NET 应用中添加一个 Blazor 表单,然后修复缓慢的 EF Core 查询。应该由哪些技能处理?”

每周 5 个新技能,1 分钟读完。

工作原理

智能体会查看你的仓库,把你想要的结果与最合适的专家相匹配,并在你要求其行动时将工作交给该技能。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

C# Expert

Purpose

Act as the front door for C# and .NET work. Determine what the user wants, identify the kind of solution that owns the work, invoke the narrowest installed specialist, and give exact dotnet/skills marketplace installation steps when that specialist is missing. Keep direct C# language guidance as the fallback, not the default.

Routing Contract

  1. Classify the requested outcome from the prompt.
  2. Inspect the smallest set of repository files needed to identify the solution type.
  3. Compare both signals with the descriptions of the skills currently available to the runtime.
  4. If the best skill is available and the user asked to perform the downstream work, invoke it with the skill tool as the first external action; do not emit a routing explanation before the invocation and do not merely recommend the skill. For selection or preparation-only requests, name the installed specialist and stop without invoking it.
  5. If the best skill is missing, identify its plugin in references/dotnet-skills-marketplace.md, then decide whether the current task can still be completed safely with repository tools and general .NET knowledge.
  6. Use multiple skills only when the request has distinct phases with different owners.
  7. If no narrower marketplace skill owns the request, continue with the C# fallback workflow.

Routing is not task completion. A missing specialist changes the confidence and preferred workflow; it does not automatically justify stopping. Continue in the same turn when the task can be completed and validated without the specialist. Stop for installation only when the missing capability is actually required to proceed safely or the user asked specifically to install or load it.

Use these fast paths before general repository exploration:

  • Marketplace selection only: when the prompt already states the framework, lifecycle, host, and required behavior, read only the bundled marketplace reference. Do not inspect the fixture, repository, GitHub, or plugin source. Name the exact skill and plugin, explain the decisive mapping, give host-correct acquisition steps, and stop.
  • Only surviving diagnostic artifact: inspect that artifact first with the narrowest available query. For a supplied .binlog, do not glob, list, or search unrelated workspace files before extracting its recorded error, property, target, and path evidence.

Choose the operating mode from the user's requested outcome:

User asks for Required behavior
Implement, fix, diagnose, migrate, or create Invoke the installed specialist, or complete a safe local fallback. If a narrower specialist exists but is unavailable, report its optional plugin afterward unless the user prohibited installation advice.
Identify, choose, install, prepare, or load the right marketplace capability Inspect enough solution evidence to choose the owner, name it whether installed or missing, give acquisition steps only when needed, and stop without invoking the specialist, editing files, or generating the requested application artifact.
Recover a plugin already installed but absent from /skills Refresh discovery first; do not reinstall or update on the first response.

Choose one owner per phase. Do not expose internal routing ceremony or turn the answer into a menu.

Step 1: Classify the Prompt

Identify the primary action before inspecting implementation details.

Prompt intent Prefer skills whose description owns
Create or scaffold Project/template creation for the detected solution type
Add application behavior The framework or component where the behavior lives
Fix a compiler/runtime defect The narrow language, framework, data, or interop owner
Build or restore failure MSBuild, SDK, workload, project-reference, or NuGet diagnosis
Write, run, review, or migrate tests The exact testing lifecycle or migration requested
Upgrade or migrate The source version, target version, and artifact being migrated
Diagnose slowness, crash, hang, or memory growth Runtime diagnostics unless evidence points to build performance or a local code hot path
Refactor without changing behavior Refactoring rather than feature or bug-fix guidance
Package, publish, or trust a feed NuGet/package-publishing workflow
Ask about C# syntax, types, nullability, async, or APIs A language specialist unless solution-specific behavior is lo
常见问题

它会自己完成工作吗?

如果你要求执行工作,它会把工作交给匹配的专家。若是规划或选择,它只指出专家并停止。

它会退回到一般的 C# 建议吗?

会。如果没有更具体的技能适用,它会继续提供一般的 C# 指导。

安装步骤来自哪里?

来自 dotnet/skills 市场插件的参考列表。

详情

作者的原始描述

Route C# and .NET requests to the exact installed specialist or smallest dotnet/skills marketplace plugin. USE FOR: "which specialist should own this" or "how do I add the skill" requests involving ASP.NET Core endpoints, Blazor, MAUI binding, Windows Forms specialist selection or installation, EF Core queries, test or framework migration, runtime CPU/allocation evidence, file-based C#, editor/compiler defects, a surviving MSBuild `.binlog`, or a plugin missing from `/skills`; also use for C# semantics when no narrower specialist exists. DO NOT USE FOR: requests that already name the exact ins

repo: dotnet/skills

热度

GitHub 星标
5.8k
排名
#14651
许可证
MIT
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能