database-patterns

Document reusable database patterns for PostgreSQL, Redis, and SQLAlchemy.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/skomax/skills --skill database-patterns-skomax
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-patterns
Source: https://github.com/skomax/skills/tree/main/.claude/skills/database-patterns
Command: npx skills add https://github.com/skomax/skills --skill database-patterns-skomax

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

PostgreSQL, Redis, and ORM integrations often require ad-hoc patterns, leading to inconsistency and maintenance overhead.

Core Features & Use Cases

  • Schema design & migrations: standardized approaches for tables, indexes, and versioned changes.
  • Async ORM patterns: recommended SQLAlchemy 2.x async models and sessions.
  • Caching & data modeling: strategies for Redis-based caching and JSONB data modeling.
  • Migration practices: guidelines and examples for safe, incremental migrations.

Quick Start

Apply PostgreSQL, Redis, and SQLAlchemy best practices to a sample project and generate optimized schemas, models, and queries.

Frequently Asked Questions about database-patterns

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

FAQPage Schema
What are the best practices for async SQLAlchemy 2.x session management?

Async SQLAlchemy 2.x session management best practices involve using recommended async models and sessions for concurrent database operations. This skill provides documented patterns and ready-to-adapt code examples to guide architecture decisions and practical implementation of scalable async database layers.

How do I design safe and incremental PostgreSQL database migrations?

Safe and incremental PostgreSQL migrations require standardized approaches for tables, indexes, and versioned changes. This skill provides guidelines and practical examples for structured migration practices to ensure incremental schema evolution.

What is the best way to implement Redis caching strategies with PostgreSQL?

Implementing Redis caching strategies alongside PostgreSQL involves dedicated data modeling approaches for cache layers. This skill guides architecture decisions for Redis-based caching and JSONB data modeling, providing best-practice recommendations embedded in the content.

Does this database patterns skill work with both PostgreSQL and Redis?

Yes, this database patterns skill works with both PostgreSQL and Redis. It solves the need for reusable database practices across PostgreSQL, Redis, and ORM layers, providing standardized approaches for schema design, caching strategies, and async SQLAlchemy patterns.

How do I model JSONB data in PostgreSQL for scalable applications?

Modeling JSONB data in PostgreSQL for scalable applications requires specific caching and data modeling strategies. This skill provides documented patterns and ready-to-adapt code examples to guide JSONB data modeling and architecture decisions for robust apps.