prisma-expert

Diagnose and fix Prisma ORM schema, migration, and query performance issues.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/hvngroup/directus_b2b_crm --skill prisma-expert-hvngroup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prisma-expert
Source: https://github.com/hvngroup/directus_b2b_crm/tree/main/.agent/skills/prisma-expert
Command: npx skills add https://github.com/hvngroup/directus_b2b_crm --skill prisma-expert-hvngroup

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Prisma ORM issues such as poorly designed schemas, migration drift, and slow queries across PostgreSQL, MySQL, and SQLite are addressed by an expert who can diagnose and fix schema, migrations, and performance problems proactively and safely.

Core Features & Use Cases

  • Schema Design and best practices: explicit relations with correct data types, normalization, and clear naming.
  • Migrations and workflow guidance: validate, format, and apply migrations with safe, reversible strategies.
  • Query Optimization: identify N+1 queries, optimize selects, and improve overall Prisma Client performance.

Use cases include complex data models with many relations, migration drift in evolving projects, and performance bottlenecks in data access layers, where this skill guides you to a robust Prisma setup.

Quick Start

Run a Prisma diagnostic to identify and fix schema, migrations, and query performance issues.

Frequently Asked Questions about prisma-expert

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix Prisma schema migration drift in my PostgreSQL project?

To fix Prisma schema migration drift, you need to validate your schema against the database and apply safe, reversible migration strategies. This process diagnoses synchronization issues and aligns your PostgreSQL database state with your schema definition safely.

How do I optimize slow Prisma ORM queries and resolve N+1 problems?

Optimizing slow Prisma ORM queries involves identifying N+1 relationship queries and refining your select statements. This performance tuning process analyzes data access bottlenecks and implements efficient Prisma Client queries to reduce database load.

What are the best practices for designing a Prisma schema with many relations?

Best practices for designing a complex Prisma schema involve using explicit relations, correct data types, and clear naming conventions. Proper schema design ensures normalization and maintains data integrity across models with many interconnected relations.

Can I use Prisma migrations safely with an existing SQLite database?

Yes, you can safely use Prisma migrations with an existing SQLite database by following progressive, reversible migration strategies. This workflow validates and formats migration files to ensure safe schema evolution without risking existing data.

Why does my Prisma ORM schema validation fail during deployment?

Prisma ORM schema validation fails during deployment when your schema definition drifts from the applied migration history. Running a diagnostic identifies formatting errors and missing migrations, guiding you to apply progressive fixes using the Prisma CLI.