Audits ORM and data-layer configuration across multiple stacks (EF Core, Prisma, TypeORM, Drizzle, SQLAlchemy, Django, Hibernate, GORM) for correctness and performance pitfalls. Checks tracking defaults, lazy loading, SQL logging, pooling, connection lifetime, schema auto-sync in production, and missing mapping configuration.
Ships in AI for Developers Toolkit. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Review how the ORM and its connection/session are set up - the settings that quietly cause performance problems, data leaks, or surprising behavior. This is configuration, not individual query bodies (use orm-query-optimizer for those).
Works on a target: a file, folder, project/repo, or GitHub URL. Report which config files you read.
| Manifest | ORM | Read these |
|---|---|---|
*.csproj | EF Core | AddDbContext/AddDbContextPool registration, DbContext class, OnModelCreating, IEntityTypeConfiguration<T> classes, appsettings*.json |
package.json | Prisma / TypeORM / Drizzle / Sequelize | schema.prisma + new PrismaClient(...); DataSource/ormconfig; drizzle.config.ts + drizzle(...) |
pyproject.toml, requirements*.txt | SQLAlchemy / Django ORM | create_engine, sessionmaker, model relationship(...); settings.py DATABASES, model Meta, on_delete |
pom.xml, build.gradle(.kts) | Hibernate / JPA / Spring Data | application.yml/properties (spring.jpa.*, spring.datasource.*), @Entity mappings |
go.mod | GORM / sqlx / ent | gorm.Open(..., &gorm.Config{...}), sql.DB pool settings, model tags |
grep -rln "DbContext\|OnModelCreating\|IEntityTypeConfiguration\|AddDbContext" --include=*.cs <target>
grep -rln "new PrismaClient\|new DataSource\|createConnection\|drizzle(" <target>/src
grep -rn "create_engine\|sessionmaker\|DATABASES\s*=" --include=*.py <target>
grep -rn "spring.jpa\|spring.datasource\|hibernate\." <target>/src/main/resources
grep -rn "gorm.Open\|gorm.Config\|SetMaxOpenConns" --include=*.go <target>
synchronize: true, Hibernate ddl-auto=update/create, GORM AutoMigrate on boot, EF EnsureCreated). Use reviewed migrations.db-resiliency-setup).db-resiliency-setup.EnableSensitiveDataLogging() / EnableDetailedErrors() unconditional - gate behind IsDevelopment().UseLazyLoadingProxies() - prefer explicit Include / projection.UseQueryTrackingBehavior(QueryTrackingBehavior.NoTracking) as default, opt into tracking for writes.AddDbContextPool (or AddPooledDbContextFactory) cuts allocation cost; keep no per-request state in the context.OnModelCreating - move to IEntityTypeConfiguration<T> + ApplyConfigurationsFromAssembly.HasMaxLength, HasPrecision (or ConfigureConventions for global defaults), IsRequired, OnDelete(DeleteBehavior.Restrict/Cascade) chosen deliberately.EnableRetryOnFailure not set (see db-resiliency-setup).IDbContextFactory for background services and Blazor Server.PrismaClient per process (a new client per request exhausts connections; in dev hot-reload cache it on globalThis); log: ['query'] only in dev; connection_limit set for serverless; onDelete/onUpdate explicit on relations; @db.VarChar(n) / @db.Decimal(p, s) where size matters.synchronize: false and migrationsRun deliberate in prod; logging limited; eager: true / lazy: true relations reviewed (eager on many relations = huge joins); cascade explicit; precision/scale/length on columns.logger off in prod; pool created once and reused.echo=False in prod; one Engine per process; sessionmaker scoped to request/unit of work (not module-global sessions); expire_on_commit chosen deliberately (async sessions usually need False); relationship lazy= defaults reviewed ("raise" catches accidental lazy loads); pool_pre_ping/pool_recycle set.DEBUG = False (DEBUG keeps every SQL query in memory); CONN_MAX_AGE set; on_delete deliberate on every FK; DecimalField(max_digits, decimal_places) for money; USE_TZ = True.spring.jpa.hibernate.ddl-auto = validate or none in prod.spring.jpa.open-in-view=false - the default true keeps a session open for the whole request and hides lazy-loading N+1 (Spring Boot logs a warning about it).@ManyToOne/@OneToOne default to FetchType.EAGER in JPA - switch to LAZY and fetch explicitly.spring.jpa.show-sql / org.hibernate.orm.jdbc.bind (Hibernate 6) parameter logging off in prod.hibernate.default_batch_fetch_size and JDBC batching (hibernate.jdbc.batch_size, order_inserts) configured for write-heavy apps.CascadeType.ALL / orphanRemoval only where the child is truly owned.Logger: logger.Default.LogMode(logger.Silent/Warn) in prod (Info logs every statement).AutoMigrate not run on every boot in prod; use golang-migrate/goose/Atlas.PrepareStmt: true for hot repeated queries; SkipDefaultTransaction: true when single writes don't need the implicit transaction.sql.DB pool settings applied (db.DB() then SetMaxOpenConns, SetConnMaxLifetime).constraint:OnDelete: tags explicit on associations.## Summary
<stack + ORM detected; config files reviewed>
## Findings (ranked)
🔴 [Sensitive logging] <file:line> - <risk> -> <fix>
🟡 ...
## Suggested configuration
<corrected setup in the project's idiom + one sample per-entity mapping>
"Review my DbContext setup", "is my Prisma/TypeORM config production-ready", "why is Hibernate doing extra queries", "audit my SQLAlchemy engine and session setup", "split OnModelCreating into per-entity config". Pairs with orm-query-optimizer and db-resiliency-setup.
What SKILL.md sets; muted values are Claude Code's defaults
/ai-dev-toolkit:orm-config-auditorfrom AI for Developers Toolkit
npx claudepluginhub stefanthecode/ai-for-developers --plugin ai-dev-toolkit45 skills in this plugin
/api-endpoint-scaffolderScaffold HTTP API endpoints in any stack - ASP.NET Core Minimal APIs or controllers, Express, Fastify, NestJS, FastAPI, Django REST Framework, Spring Boot controllers, Go net/http, chi, Gin - one feature per endpoint (REPR style) with request validation, typed responses, route grouping, auth, and OpenAPI metadata. Use this skill whenever the user wants to add an endpoint or route, convert controllers to minimal APIs, structure routes or routers, set up endpoint groups, TypedResults, route handlers, request DTOs/schemas (zod, Pydantic, Bean Validation, binding tags), or asks "how do I add an endpoint / structure my API routes". Always use this skill for endpoint scaffolding; it generates a complete, validated endpoint that matches the project's conventions./architecture-test-generatorGenerate architecture tests / fitness functions that fail the build when architectural rules are violated - layer dependencies, module boundaries, cycles, naming, and visibility conventions - in any stack: NetArchTest or ArchUnitNET (.NET), ArchUnit or Konsist (Java/Kotlin), dependency-cruiser or eslint-plugin-boundaries (TypeScript/JavaScript), import-linter (Python), go-arch-lint or depguard (Go). Use this skill whenever the user wants architecture tests, to enforce layering or the dependency rule, dependency rules as tests, import rules, forbidden imports, no circular dependencies, naming conventions, fitness functions, or asks "how do I stop people breaking the architecture / enforce my layers / keep modules from importing each other". Always use this skill for architecture-test requests; it generates rules matching the project's real structure./async-await-auditorAudit async and concurrent code in any language for correctness and performance bugs - C#/.NET (async/await, Task), JavaScript/TypeScript (Promises, async/await), Python (asyncio), Java/Kotlin (CompletableFuture, virtual threads, coroutines), Go (goroutines, channels, context), Rust (tokio/async). Use this skill whenever the user shares async or concurrent code, or asks about deadlocks, hangs, blocking calls, .Result/.Wait(), async void, ConfigureAwait, floating or unhandled promises, await in a loop vs Promise.all, blocking the event loop, forgotten await, asyncio.gather/TaskGroup, CompletableFuture.join, virtual thread pinning, goroutine leaks, context cancellation, WaitGroup/errgroup, holding a lock across .await, fire-and-forget tasks, cancellation tokens, or "why does my async code hang". Always use this skill for async/concurrency reviews instead of answering from memory; it applies a fixed checklist and rewrites the code./authorization-setupDesign API authorization in any stack - policy-based, role-based, claims/permission-based, and resource-based (ownership) checks. Covers ASP.NET Core policies and AuthorizationHandler, NestJS guards, Express middleware and CASL, FastAPI dependencies/scopes, Django and DRF permission classes, Spring Security (@PreAuthorize, SecurityFilterChain), Go middleware, and Casbin/OPA. Use this skill whenever the user wants authorization policies, role/claim/permission checks, RBAC/ABAC, custom authorization rules, resource-based authorization, IDOR protection, "deny by default", or asks "how do I authorize this / policy vs role / restrict this endpoint to X / stop users seeing other users' data". Always use this skill for authorization requests; it generates policies, handlers, and endpoint wiring./benchmark-setupSet up correct micro-benchmarks in any stack and interpret the results - BenchmarkDotNet (.NET), JMH (Java/Kotlin), pytest-benchmark / pyperf (Python), Vitest bench / tinybench / mitata (JavaScript/TypeScript), Go testing.B + benchstat, Rust criterion. Use this skill whenever the user wants to benchmark code, measure performance, compare two implementations or functions, set up a benchmark harness, or asks "which is faster", "benchmark these two functions", "how do I benchmark this", "is this optimization worth it", or "interpret these benchmark results". Always use this skill for micro-benchmarking requests; it writes correct benchmarks, avoids the classic pitfalls, and explains the numbers./caching-strategy-setupAdd the right caching to an app in any stack - in-process, distributed (Redis/Valkey/Memcached), two-level, or HTTP/output caching - with correct keys, expiration, stampede protection, and invalidation. Covers HybridCache / IMemoryCache / IDistributedCache / output caching in .NET, lru-cache / keyv / cache-manager / ioredis in Node, functools / cachetools / redis-py / Django cache in Python, Spring Cache with Caffeine or Redis in Java/Kotlin, and ristretto / groupcache / singleflight / go-redis in Go. Use this skill whenever the user wants caching, to cache a query/response, Redis caching, @Cacheable, lru_cache, HybridCache, cache-aside, output caching, or asks "how do I cache this / add caching / avoid cache stampede / invalidate this cache". Always use this skill for caching requests; it picks the right layer and wires expiration + invalidation correctly.Other plugins' skills for the same job