
optimizing-ef-core-queries
Review and optimize application data access that uses Entity Framework Core
by dotnetFree
Description
Optimizing EF Core Queries is an agent skill for diagnosing and fixing slow or incorrect data access built on Entity Framework Core. In a source-only review it traces the code without running it, and it separates what the code proves from runtime assumptions. When SQL, logs or query plans are available, it uses them to confirm the bottleneck. The skill favors changes that cut round trips, duplicated rows, table scans or per-call translation cost over micro-optimizations. Its triggers include queries that run far more SQL statements than expected, an N+1 pattern where a query repeats once per row through lazy loading, multiple collection Include calls that multiply rows, deep paging that slows as Skip grows, bulk updates that load rows only to modify them, sorting or filtering that scans even though the column is indexed, and hot queries that pay LINQ translation cost on every call. The skill does not apply to projects that use Dapper or raw ADO.NET. For those, it answers the SQL, indexing or query plan question directly. The skill is published by dotnet/skills on skills.sh with about 7.1K installs.…
Highlights
- Finds N+1 patterns and too many SQL statements
- Flags duplicated rows from multiple collection Includes
- Targets slow deep paging and bulk update patterns
- Checks indexes for filtered and sorted columns
- Stays out of Dapper and raw ADO.NET projects
Ratings & Reviews
No ratings yet
Be the first to rate optimizing-ef-core-queries.
People also visit
optimizing-ef-core-queries FAQ
What is the Optimizing EF Core Queries skill?
It is an instruction set for an AI coding agent that reviews and speeds up data access written with Entity Framework Core.
How do I install it?
Run npx skills add https://github.com/dotnet/skills --skill optimizing-ef-core-queries in your project.
Does it need a database connection?
No. In a source-only review it traces the code without executing it. SQL, logs or query plans make the diagnosis firmer when they are available.
Does it work with Dapper or raw ADO.NET?
No. The skill says those projects are outside its scope and answers the SQL or indexing question directly.
Does the skill pass its security audits?
Yes. On skills.sh the audits show Gen Agent Trust Hub Pass, Socket Pass and Snyk Pass.
What are the best optimizing-ef-core-queries alternatives?
Popular alternatives to optimizing-ef-core-queries include ef-core, ef-core and migrate. See all optimizing-ef-core-queries alternatives
















