redis-core

Design efficient Redis data models with proper types and colon-separated naming conventions.

94|22|Updated Jan 29, 2026
One-click install
npx skills add https://github.com/redis/agent-skills --skill redis-core
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: redis-core
Source: https://github.com/redis/agent-skills/tree/main/skills/redis-core
Command: npx skills add https://github.com/redis/agent-skills --skill redis-core

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Redis modeling often struggles with choosing the right data type and maintaining consistent key naming, which directly impacts memory usage, performance, and maintainability.

Core Features & Use Cases

  • Guidelines for selecting the correct data structure (String, Hash, List, Set, Sorted Set, JSON, Stream, Vector Set) based on access patterns.
  • Clear key-naming conventions with colon-separated prefixes to enable efficient scans and predictable memory layout.
  • Practical examples (caching, leaderboards, memberships, sessions) and cross-references for deeper rationale.

Quick Start

Apply these guidelines to model a user profile using a Hash and a concise key like user:123:profile.

Frequently Asked Questions about redis-core

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

FAQPage Schema
How do I choose the right Redis data structure for my use case?

Selecting the right Redis data structure requires matching access patterns to types like String, Hash, List, Set, or Sorted Set. This modeling process ensures optimal memory usage and query performance for specific scenarios like caching or leaderboards.

When should I use a Redis Hash versus JSON for modeling data?

Use a Redis Hash for flat records with partial field updates, and JSON for nested or hierarchical data. Choosing correctly between Hash and JSON impacts memory efficiency and update performance based on your data's complexity and access patterns.

What is the best key naming convention for Redis?

The best Redis key naming convention uses colon-separated prefixes, such as user:123:profile. This structure enables efficient key scans, predictable memory layout, and easier maintainability across typical Redis deployments.

How do I model a user session in Redis efficiently?

Model a user session in Redis by using a Hash with a concise key like user:123:session. This approach groups related session fields together, minimizing memory overhead while allowing partial updates to individual session attributes.

Does Redis work well for storing hierarchical data?

Redis handles hierarchical data effectively using the JSON data structure or combinations of Sets and Hashes. Modeling hierarchical data in Redis requires selecting the proper data types to maintain nested relationships and efficient access.

What are the limitations of using Strings for complex Redis data models?

Using Strings for complex Redis data models limits partial updates and increases serialization overhead, reducing performance. Constraint issues arise when scaling, making Hash or JSON structures necessary for granular field access and memory efficiency.