Agent skill · Microsoft (.NET)

Optimize EF Core Queries skill for Claude Code, Codex and Cursor

Reviews Entity Framework Core data access for slow, memory-heavy or incorrect queries.

Officialname: optimizing-ef-core-queries★ 5.7k (repo)pushed 2026-10-24MITSKILL.md on GitHubchecked 2026-11-07

What it does, in the publisher's words

Review and optimize application data access that uses Entity Framework Core (EF Core). Use for EF Core performance and correctness reviews of services, repositories, imports, and background jobs: slow or memory-heavy queries, excessive round-trips, hidden SaveChanges, premature materialization, dynamic query construction, result-graph tracking, bulk writes, DbContext lifetime or overlapping operations, search...

The description field of the SKILL.md. The agent reads only this at startup and decides from it when to load the full skill.

Install Optimize EF Core Queries

The skills CLI copies the skill into the folder of each agent you pick (Claude Code, Codex, Cursor, Copilot, Gemini CLI, OpenCode, Windsurf...). Add -g for all projects. Needs Node.js 22.20+. docs

npx skills add dotnet/skills --skill optimizing-ef-core-queries

Works with

Claude Code, Claude.ai and Claude Desktop, Codex, GitHub Copilot, Cursor, Gemini CLI, OpenCode, Windsurf and other agents that read the open Agent Skills format.

What's in the SKILL.md

22 sections
  • When to Use
  • When Not to Use
  • Source review workflow
  • Gate source-only findings on evidence
  • Capture SQL and query counts
  • Fixes
  • Trace materialization and result bounds
  • Keep predicates compatible with indexes
  • Compile hot, frequently-executed queries
  • Control SQL parameterization and database plan reuse
  • Stabilize dynamically constructed query shapes
  • Choose tracking for the actual result graph
  • Remove N+1 and avoid lazy loading
  • Separate join multiplication from wide-row duplication
  • Filter and paginate; prefer keyset over offset
  • Add missing indexes
  • Trace persistence through repositories
  • Bound change detection in growing imports
  • Set-based bulk updates and deletes
  • Keep DbContext operations non-overlapping
  • Common Pitfalls
  • References

Facts

Skill name
optimizing-ef-core-queries
Publisher
Microsoft (.NET) (official)
Repo
dotnet/skills
License
MIT
SKILL.md size
3,012 words, 276 lines
Repo stars
5.7k (as of 2026-10-24)
SKILL.md checked
2026-11-07

More skills from dotnet/skills

Related backend & databases skills

FAQ

What does the optimizing-ef-core-queries skill do?+

Reviews Entity Framework Core data access for slow, memory-heavy or incorrect queries. In its own SKILL.md, Microsoft (.NET) describes it as: "Review and optimize application data access that uses Entity Framework Core (EF Core). Use for EF Core performance and correctness reviews of services, repositories, imports, and background jobs: slow or memory-heavy queries, excessive round-trips, hidden SaveChanges, premature materialization,..."

How do I install the optimizing-ef-core-queries skill?+

Run npx skills add dotnet/skills --skill optimizing-ef-core-queries and pick your agents, or use the tab for your agent above. In Claude Code the skill ends up in ~/.claude/skills/optimizing-ef-core-queries/SKILL.md; in Codex and Cursor in .agents/skills/optimizing-ef-core-queries/.

Does Optimize EF Core Queries work in Codex, Cursor and Copilot, or only Claude?+

It's a standard SKILL.md, so any agent that reads the Agent Skills format can use it: Claude Code, the Claude apps, Codex, GitHub Copilot, Cursor, Gemini CLI, OpenCode, Windsurf and more.

Who maintains Optimize EF Core Queries?+

Microsoft (.NET), the company or project behind it, in the dotnet/skills repo on GitHub, last pushed 2026-10-24. License: MIT.

Read a skill's SKILL.md and scripts before you install it: skills aren't verified by any agent vendor. Claude skills marketplace · How to install skills · MCP servers