SkillAgentSearch skills...

ef-core

Get best practices for Entity Framework Core

Install / Use

npx skills add github/awesome-copilot --skill ef-core

Installs into whichever agent you are using.

About this skill
📄

SKILL.md

Installable skill definition

Quality Score

81/100

Supported Platforms

Universal

Our assessment of ef-core

ef-core scores 81/100 on our quality scale, 993rd of 2,189 Development & Engineering skills we index (top 46%).

Its SKILL.md is 2.6 KB long, well organised into 9 sections and no code examples: a solid amount of guidance for an agent.

With 39,348 GitHub stars, it is one of the more widely adopted skills in the catalogue.

Substance
26/30
Structure
13/20
Description
8/15
Adoption
20/20
Freshness
15/15

Maintenance, license and trust

  • The repository was last updated 2 days ago, so ef-core is actively maintained.
  • It is released under the MIT license, a permissive license that allows use, modification and commercial use with attribution.
  • Its trust signals score 100/100, with no cautions. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.

Safety scan

No issues found

Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands.

Automated pattern scan on 2026-09-26. It catches known dangerous patterns, not every risk — read a skill before letting an agent act on it.

ef-core compared with similar skills

All 4 of these similar skills score higher than ef-core; compare them before choosing.

SkillScoreStarsUpdatedFormat
ef-core (this skill)by github8139.3k2d agoSKILL.md
Agent-Reachby Panniantong10085.6k11d agoCLAUDE.md
headroomby headroomlabs-ai10073.9ktodayCLAUDE.md
ai-job-searchby MadsLorentzen10044.0k5d agoCLAUDE.md
claude-howtoby luongnv8910041.7ktodayCLAUDE.md

Frequently asked questions

How do I install ef-core?
Run npx skills add github/awesome-copilot --skill ef-core. The install tabs above show the steps for each supported agent.
Which AI agents does ef-core work with?
It is written for Universal, as a SKILL.md file. Other agents that read the same format can often use it too.
Is ef-core safe to use?
Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. It is MIT-licensed and scores 100/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
Is ef-core still maintained?
The repository was last updated 2 days ago, so ef-core is actively maintained.

name: ef-core description: 'Get best practices for Entity Framework Core'

Entity Framework Core Best Practices

Your goal is to help me follow best practices when working with Entity Framework Core.

Data Context Design

  • Keep DbContext classes focused and cohesive
  • Use constructor injection for configuration options
  • Override OnModelCreating for fluent API configuration
  • Separate entity configurations using IEntityTypeConfiguration
  • Consider using DbContextFactory pattern for console apps or tests

Entity Design

  • Use meaningful primary keys (consider natural vs surrogate keys)
  • Implement proper relationships (one-to-one, one-to-many, many-to-many)
  • Use data annotations or fluent API for constraints and validations
  • Implement appropriate navigational properties
  • Consider using owned entity types for value objects

Performance

  • Use AsNoTracking() for read-only queries
  • Implement pagination for large result sets with Skip() and Take()
  • Use Include() to eager load related entities when needed
  • Consider projection (Select) to retrieve only required fields
  • Use compiled queries for frequently executed queries
  • Avoid N+1 query problems by properly including related data

Migrations

  • Create small, focused migrations
  • Name migrations descriptively
  • Verify migration SQL scripts before applying to production
  • Consider using migration bundles for deployment
  • Add data seeding through migrations when appropriate

Querying

  • Use IQueryable judiciously and understand when queries execute
  • Prefer strongly-typed LINQ queries over raw SQL
  • Use appropriate query operators (Where, OrderBy, GroupBy)
  • Consider database functions for complex operations
  • Implement specifications pattern for reusable queries

Change Tracking & Saving

  • Use appropriate change tracking strategies
  • Batch your SaveChanges() calls
  • Implement concurrency control for multi-user scenarios
  • Consider using transactions for multiple operations
  • Use appropriate DbContext lifetimes (scoped for web apps)

Security

  • Avoid SQL injection by using parameterized queries
  • Implement appropriate data access permissions
  • Be careful with raw SQL queries
  • Consider data encryption for sensitive information
  • Use migrations to manage database user permissions

Testing

  • Use in-memory database provider for unit tests
  • Create separate testing contexts with SQLite for integration tests
  • Mock DbContext and DbSet for pure unit tests
  • Test migrations in isolated environments
  • Consider snapshot testing for model changes

When reviewing my EF Core code, identify issues and suggest improvements that follow these best practices.

Related Skills

View on GitHub
GitHub Stars39.3k
CategoryDevelopment
Updated2d ago
Forks5.0k

Languages

JavaScript

Trust signals

100/100

From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.

No cautions