Discover Database
rand/cc-polymath
Automatically discover database skills when working with SQL, PostgreSQL, MongoDB, Redis, database schema design, query optimization, migrations, connection pooling, ORMs, or database selection.
Database guidance for PostgreSQL, MongoDB, Redis and Oracle plus Neon, Supabase and Firestore: schema design, indexing, query tuning and cloud database choice.
$ npx skills add modu-ai/moai-adk --skill moai-domain-database -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install modu-ai/moai-adk moai-domain-database --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/moai-domain-database .claude/skills/moai-domain-database && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "moai-domain-database" agent skill from https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-database into .claude/skills/moai-domain-database/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "moai-domain-database", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-databaseType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add modu-ai/moai-adk --skill moai-domain-database -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install modu-ai/moai-adk moai-domain-database --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.claude/skills/moai-domain-database .agents/skills/moai-domain-database && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "moai-domain-database" agent skill from https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-database into .agents/skills/moai-domain-database/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "moai-domain-database", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add modu-ai/moai-adk --skill moai-domain-database -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install modu-ai/moai-adk moai-domain-database --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.claude/skills/moai-domain-database .cursor/skills/moai-domain-database && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "moai-domain-database" agent skill from https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-database into .cursor/skills/moai-domain-database/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "moai-domain-database", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/modu-ai/moai-adk.git --path .claude/skills/moai-domain-database--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add modu-ai/moai-adk --skill moai-domain-database -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install modu-ai/moai-adk moai-domain-database --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.claude/skills/moai-domain-database .gemini/skills/moai-domain-database && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "moai-domain-database" agent skill from https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-database into .gemini/skills/moai-domain-database/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "moai-domain-database", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install modu-ai/moai-adk moai-domain-databaseInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add modu-ai/moai-adk --skill moai-domain-database -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .github/skills && cp -r skills-src/.claude/skills/moai-domain-database .github/skills/moai-domain-database && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "moai-domain-database" agent skill from https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-database into .github/skills/moai-domain-database/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "moai-domain-database", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add modu-ai/moai-adk --skill moai-domain-database -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install modu-ai/moai-adk moai-domain-database --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.claude/skills/moai-domain-database .opencode/skills/moai-domain-database && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "moai-domain-database" agent skill from https://github.com/modu-ai/moai-adk/tree/main/.claude/skills/moai-domain-database into .opencode/skills/moai-domain-database/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "moai-domain-database", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
moai-domain-databaseDatabase guidance for PostgreSQL, MongoDB, Redis and Oracle plus Neon, Supabase and Firestore: schema design, indexing, query tuning and cloud database choice.
Covers relational, document and in-memory databases in one skill. PostgreSQL topics include schema constraints, window functions, CTEs, partitioning and materialized views; MongoDB covers document modeling, aggregation pipelines and sharding; Redis covers caching layers, locking, pub/sub and streams; Oracle covers PL/SQL, partitioning and hierarchical queries.
Further sections cover connection pooling, migrations, monitoring and hybrid setups that combine several databases. A cloud vendor guide on Neon, Supabase and Firestore, merged in from another skill, helps with picking a platform. Tool permissions allow only specific database command line clients such as psql, mongosh and redis-cli.
Read from SKILL.md and the folder at commit 2aab5f7. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
ReadWriteEditBash(psql:*)Bash(mysql:*)Bash(sqlite3:*)Bash(mongosh:*)Bash(redis-cli:*)Bash(npm:*)Bash(npx:*)…and 6 more on the same allowed-tools line.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
npmFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use npm, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Designed for Claude Code
From compatibility in the SKILL.md frontmatter.
Database Domain Specialist loads about 2.8k tokens when it runs. Until then it costs about 79 tokens; SKILL.md has 1,145 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from modu-ai/moai-adk at commit 2aab5f7, republished under its Apache-2.0 licence (© modu-ai). 1,145 words, ~2,835 tokens.
.claude/skills/moai-domain-database/SKILL.md (or your agent's skills folder).Enterprise Database Expertise - Comprehensive database patterns and implementations covering PostgreSQL, MongoDB, Redis, Oracle, and advanced data management for scalable modern applications.
Core Capabilities:
When to Use:
Database Stack Initialization:
Create a DatabaseManager instance and configure multiple database connections. Set up PostgreSQL with connection string, pool size of 20, and query logging enabled. Configure MongoDB with connection string, database name, and sharding enabled. Configure Redis with connection string, max connections of 50, and clustering enabled. Use the unified interface to query user data with profile and analytics across all database types.
Single Database Operations:
Run PostgreSQL schema migrations using the migration command with the database type and migration file path. Execute MongoDB aggregation pipelines by specifying the collection name and pipeline JSON file. Warm Redis cache by specifying key patterns and TTL values.
PostgreSQL Module:
MongoDB Module:
Redis Module:
Oracle Module:
Polyglot Persistence Pattern:
Create a DataRouter class that initializes connections to PostgreSQL, MongoDB, Redis, and Oracle. Implement get_user_profile method that retrieves structured user data from PostgreSQL or Oracle, flexible profile data from MongoDB, and real-time status from Redis, then merges all data sources. Implement update_user_data method that routes structured data updates to PostgreSQL/Oracle, profile data updates to MongoDB, and real-time data updates to Redis, followed by cache invalidation.
Data Synchronization:
Create a DataSyncManager class that synchronizes user data across databases. Implement sync_user_data method that retrieves user from PostgreSQL, creates a search document for MongoDB, upserts to the MongoDB search collection, creates cache data, and updates Redis cache with TTL.
Query Performance Analysis:
For PostgreSQL, execute EXPLAIN ANALYZE BUFFERS on queries and use a QueryAnalyzer to generate optimization suggestions. For MongoDB, create an AggregationOptimizer to analyze and optimize aggregation pipelines. For Redis, retrieve info metrics and use a PerformanceAnalyzer to generate recommendations.
Scaling Strategies:
Configure PostgreSQL read replicas by providing replica connection URLs. Set up MongoDB sharding with shard key and number of shards. Configure Redis clustering by providing node URLs for the cluster.
Complementary Skills:
Technology Integration:
Relational Database:
NoSQL Database:
In-Memory Database:
Enterprise Database:
Supporting Tools:
Performance Features:
Status: Production Ready Maintained by: MoAI-ADK Database Team
<!-- moai:evolvable-start id="rationalizations" -->
| Rationalization | Reality |
|---|---|
| "I do not need an index, the table is small" | Tables grow. The missing index that is invisible at 1K rows becomes a production incident at 1M rows. |
| "I will add the migration later" | Schema changes without migrations are unreproducible. Every change must have a reversible migration script. |
| "This query works fine in development" | Development databases have tiny datasets. Production query plans differ dramatically at scale. Explain analyze first. |
| "NoSQL does not need schema design" | Schemaless does not mean designless. Document structure decisions affect every query and index. |
| "I will just add a column, it is non-breaking" | Adding a NOT NULL column without a default breaks existing inserts. Column additions need default values or migration backfills. |
| "Connection pooling is handled by the framework" | Framework defaults are generic. Pool size, timeout, and idle limits must be tuned to the workload. |
<!-- moai:evolvable-end -->
<!-- moai:evolvable-start id="red-flags" -->
<!-- moai:evolvable-end -->
<!-- moai:evolvable-start id="verification" -->
<!-- moai:evolvable-end -->
Cloud database platform selection and configuration for Neon, Supabase, and Firebase Firestore.
| Need | Platform |
|---|---|
| Serverless PostgreSQL with auto-scaling | Neon |
| Database branching for CI/CD previews | Neon branching |
| Edge-compatible connection pooling | Neon + Neon Proxy |
| Vector search (pgvector) for AI/ML | Supabase |
| Row-Level Security for multi-tenant apps | Supabase RLS |
| Real-time subscriptions + full-stack | Supabase |
| Mobile-first with offline sync | Firebase Firestore |
| Cross-platform (iOS/Android/Web) | Firebase Firestore |
Key features: Auto-scaling compute, scale-to-zero, database branching, pg_bouncer pooling.
Setup:
npm install @neondatabase/serverless
# Connection string: postgresql://user:pass@ep-xxx.neon.tech/dbname?sslmode=requireBranch workflow: Create a branch per PR (neonctl branches create --name pr-123), run migrations, test, delete on merge. Zero cost during idle periods.
Key features: pgvector, Row-Level Security, real-time subscriptions, built-in auth/storage.
RLS policy pattern:
CREATE POLICY "users_own_data" ON items
FOR ALL USING (auth.uid() = user_id);pgvector search: SELECT * FROM embeddings ORDER BY embedding <-> $1 LIMIT 10;
Key features: Real-time sync, offline caching, Security Rules, mobile SDKs.
Security Rules pattern:
match /users/{userId} {
allow read, write: if request.auth.uid == userId;
}Offline persistence: Enable via enableIndexedDbPersistence(db) (web) or SDK default (mobile).
© modu-ai, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .claude/skills/moai-domain-database of modu-ai/moai-adk.
Open the folder on GitHubat commit 2aab5f7
Database Domain Specialist next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Database Domain Specialist this skillmodu-ai/moai-adk | 1.2k | — | ~2.8k | Automated safety check: Pass | Apache-2.0 | |
| Discover Databaserand/cc-polymath | 181 | — | ~2k | Automated safety check: Pass | MIT | |
| DB SculptorEliasOulkadi/shokunin | 114 | — | ~3.1k | Automated safety check: Notes | MIT | |
| Firebaseericrisco/rsc-harness | 174 | — | ~3.3k | Automated safety check: Pass | MIT | |
| Database Schema DesignerOneWave-AI/claude-skills | 328 | — | ~1.6k | Automated safety check: Pass | MIT | |
| DatabasesMicrock/ordinary-claude-skills | 404 | — | ~1.9k | Automated safety check: Notes | MIT |
rand/cc-polymath
Automatically discover database skills when working with SQL, PostgreSQL, MongoDB, Redis, database schema design, query optimization, migrations, connection pooling, ORMs, or database selection.
EliasOulkadi/shokunin
Design database schemas with Prisma/Drizzle, PostgreSQL index strategy (B-tree, GIN, GiST, BRIN, Hash), query optimization (EXPLAIN ANALYZE), migration safety (expand/contract, zero-downtime), and…
ericrisco/rsc-harness
A skill your agent uses when building on Firebase — Firestore data modeling, Security Rules, Auth and custom claims, Cloud Functions, Storage, modular Web/Admin SDK imports — including symptoms like…
OneWave-AI/claude-skills
Designs relational and document database schemas from requirements or an existing app - tables and collections, keys, relationships, constraints, indexes driven by real query patterns, ERDs, and…
Microck/ordinary-claude-skills
Work with MongoDB (document database, BSON documents, aggregation pipelines, Atlas cloud) and PostgreSQL (relational database, SQL queries, psql CLI, pgAdmin).
supabase/agent-skills
Gives the agent Postgres rules to consult before writing or changing tables, queries, indexes, RLS policies or migrations, and when diagnosing slow queries.
modu-ai/moai-adk
Builds hand-editable SVG diagrams from computed layout coordinates, lints the source and renders a 2x PNG, with rules for when mermaid is the better choice.
modu-ai/moai-adk
Reference for MoAI-ADK's core development principles: TRUST 5 quality gates, SPEC-first domain-driven workflow, agent delegation and token budgeting.
modu-ai/moai-adk
Manages SPEC documents for MoAI-ADK development, with GEARS or EARS requirement notation, acceptance criteria and a link into the Plan-Run-Sync workflow.
modu-ai/moai-adk
Drives test-first development through the RED, GREEN, REFACTOR cycle, with a config switch that selects between TDD and a DDD workflow for existing code.
modu-ai/moai-adk
Gives each SPEC its own Git worktree with a registry of active workspaces, base-branch sync and cleanup of merged ones, inside the MoAI-ADK workflow.
modu-ai/moai-adk
Watches a pull request's CI checks after creation, separates required from auxiliary failures, applies limited safe fixes and escalates anything semantic to you.
Categories
Database guidance for PostgreSQL, MongoDB, Redis and Oracle plus Neon, Supabase and Firestore: schema design, indexing, query tuning and cloud database choice. Covers relational, document and in-memory databases in one skill. PostgreSQL topics include schema constraints, window functions, CTEs, partitioning and materialized views; MongoDB covers document modeling, aggregation pipelines and sharding; Redis covers caching layers, locking, pub/sub and streams; Oracle covers PL/SQL, partitioning and hierarchical queries.
Database Domain Specialist fits situations like: designing a schema or data model; choosing indexes and tuning slow queries; planning a Redis caching layer; picking a cloud database for a new project.
Run `npx skills add modu-ai/moai-adk --skill moai-domain-database -a claude-code`. Or copy the skill folder (.claude/skills/moai-domain-database in modu-ai/moai-adk) into .claude/skills/moai-domain-database in your project. Claude Code loads it when a task matches its description.
Run `npx skills add modu-ai/moai-adk --skill moai-domain-database -a codex`. Or copy the skill folder (.claude/skills/moai-domain-database in modu-ai/moai-adk) into .agents/skills/moai-domain-database in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add modu-ai/moai-adk --skill moai-domain-database -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/moai-domain-database, .gemini/skills/moai-domain-database, .github/skills/moai-domain-database and .opencode/skills/moai-domain-database in your project.
Going by SKILL.md and its folder, Database Domain Specialist needs the command-line tools its instructions call (npm). Our summary lists: Database CLIs such as psql, mongosh or redis-cli for hands-on work. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash(psql:*), Bash(mysql:*), Bash(sqlite3:*), Bash(mongosh:*), Bash(redis-cli:*), Bash(npm:*), Bash(npx:*), Bash(prisma:*), Bash(neonctl:*), Bash(firebase:*), Bash(supabase:*), Grep, Glob. Compatibility (from SKILL.md): Designed for Claude Code.
SKILL.md contains no URLs. Its commands use npm, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Database Domain Specialist is published under the Apache-2.0 licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.8k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Database Domain Specialist: Discover Database (rand/cc-polymath, 181 stars), DB Sculptor (EliasOulkadi/shokunin, 114 stars), Firebase (ericrisco/rsc-harness, 174 stars) and Database Schema Designer (OneWave-AI/claude-skills, 328 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
modu-ai (a GitHub organization) maintains it in modu-ai/moai-adk, which has 1,232 GitHub stars. The repository holds 48 skills in this directory. The repository was last updated on October 9, 2026.
Source: modu-ai/moai-adk on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.