agentleFS
codewithmukeshcodewithmukesh/dotnet-agent-kit/.opencode/AGENTS.md

dotnet-agent-kit

AGENTS.md853 starsChanged yesterdayMITView on GitHub

This project uses dotnet-agent-kit for .NET development intelligence. OpenCode reads the root AGENTS.md natively. This file is loaded via the instructions array in opencode.json and surfaces the kit's agents, skills, MCP tools, and rules so OpenCode can route work the same way Claude Code does. The cwm-roslyn-navigator MCP server is registered in opencode.json under the mcp key. It provides Roslyn-powered, read-only code intelligence: Always prefer MCP tools over reading full source files to conserve context window. Install the server first…

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this AGENTS.md into the rules it gives an agent

2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Always prefer MCP tools over reading full source files to conserve context window.

    line 29
  2. Very specific:

    Always-applied coding conventions are consolidated for OpenCode in .cursor/rules/dotnet-rules.md (loaded via opencode.json).

    line 62

≈ “Common” is an estimate: at least 1 in 5 of the 43,423 AGENTS.md 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
AGENTS.md

OpenCode Configuration

This project uses dotnet-agent-kit for .NET development intelligence.

OpenCode reads the root AGENTS.md natively. This file is loaded via the instructions array in opencode.json and surfaces the kit's agents, skills, MCP tools, and rules so OpenCode can route work the same way Claude Code does.

MCP Server

The cwm-roslyn-navigator MCP server is registered in opencode.json under the mcp key. It provides Roslyn-powered, read-only code intelligence:

ToolPurpose
find_symbolLocate where a type, method, or property is defined
find_referencesFind all usages of a symbol across the solution
find_implementationsFind types implementing an interface or deriving from a base class
find_callersFind all methods calling a specific method
find_overridesFind overrides of virtual/abstract methods
find_dead_codeIdentify unused types, methods, and properties
get_symbol_detailGet full signature, parameters, return type, XML docs
get_public_apiGet public members of a type without reading the file
get_type_hierarchyGet inheritance chain, interfaces, and derived types
get_project_graphGet solution dependency tree with frameworks and references
get_dependency_graphGet recursive call graph for a method
get_diagnosticsGet compiler and analyzer diagnostics (errors, warnings)
get_test_coverage_mapHeuristic test coverage by naming convention
detect_antipatternsFind .NET anti-patterns via Roslyn analysis
detect_circular_dependenciesFind cycles in project or type dependencies

Always prefer MCP tools over reading full source files to conserve context window.

Install the server first so the cwm-roslyn-navigator command resolves on PATH — see the main README.

Agents

Three agents. The full agent definition (role, skills, boundaries) lives in agents/<name>.md and can be loaded directly or adapted into an OpenCode subagent under .opencode/agents/. Domain knowledge (architecture, APIs, EF Core, testing, DevOps, desktop) lives in skills, listed below.

AgentFileWhen to Use
code-revieweragents/code-reviewer.mdRead-only code review: correctness, maintainability, security, performance, PR review
build-error-resolveragents/build-error-resolver.mdAutonomous build error fixing, iterative compilation repair
refactor-cleaneragents/refactor-cleaner.mdDead code removal, systematic cleanup, safe refactoring

Skills

Skills live in skills/<skill-name>/SKILL.md and follow the Agent Skills open standard. Reference them by path when you need the opinionated pattern for a topic.

.NET Domain Skills

architecture-advisor, aspire, authentication, caching, ci-cd, configuration, console-cli, dependency-injection, desktop-mvvm, docker, ef-core, error-handling, logging, messaging, minimal-api, modern-csharp, modular-slices, native-aot, openapi, opentelemetry, resilience, testing

Workflow Skills (each registers a slash command and carries its methodology inline)

build-fix, code-review, de-sloppify, dotnet-init, migrate, scaffold, spec, tdd, verify, wrap-up

/verify has health, security and architecture modes. /migrate has a packages mode. /wrap-up has a checkpoint mode.

Learning Skills

instinct-system

Workflow skills map naturally onto OpenCode custom commands (.opencode/commands/<name>.md). Create thin command wrappers that point at the matching skill's methodology when you want /verify, /scaffold, /tdd, etc.

Rules

Always-applied coding conventions are consolidated for OpenCode in .cursor/rules/dotnet-rules.md (loaded via opencode.json). The canonical per-topic source lives in .claude/rules/:

  • coding-style.md — C# 14 style, naming, file organization
  • architecture.md — Modular slices, dependency direction, feature folders, data access
  • security.md — Secrets, input validation, auth, transport security
  • testing.md — Integration-first, xUnit v3, Testcontainers, AAA
  • performance.md — CancellationToken, TimeProvider, caching, async
  • error-handling.md — TypedResults unions, ProblemDetails with stable codes, exception boundaries
  • packages.md — Latest stable NuGet versions, central package management
  • workflow.md — MCP-first tools, subagent and model selection, conventional commits, hooks

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.