Index Suggester for Openclaw

Generate smart database index suggestions by analyzing query patterns in your source code.

lxgicstudios
v1.0.1
Jan 29, 2026
0
0
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install index-gen

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install index-gen using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Index Suggester?

Index Suggester is a high-performance utility designed to identify and resolve database bottlenecks. As a key component of the Openclaw Skills ecosystem, it scans your codebase to understand exactly how data is being queried. By analyzing WHERE clauses, JOIN conditions, and sorting patterns, the tool provides actionable advice on which indexes will yield the highest performance gains while warning against the pitfalls of over-indexing.

Index Suggester Use Cases

  • Identifying missing indexes in legacy SQL repositories to improve application responsiveness.
  • Automating database audits for Prisma-based applications during the CI/CD pipeline.
  • Optimizing complex queries with AI-suggested composite indexes to handle large datasets efficiently.
  • Reducing database latency during new feature development by ensuring efficient data access paths are defined early.

How Index Suggester Works

  1. The user provides a directory path containing query-related files, such as SQL, TypeScript, or Prisma schemas.
  2. The utility extracts database interaction patterns, focusing on filtering, joining, and ordering logic.
  3. AI logic evaluates these patterns against indexing best practices, considering selectivity and query frequency.
  4. The tool outputs specific CREATE INDEX commands and provides a technical explanation for each suggestion.

Index Suggester Setup

To get started with this tool from the Openclaw Skills collection, ensure you have Node.js 18 or higher installed on your system.

# Set your required environment variable
export OPENAI_API_KEY='your-key-here'

# Run the analyzer on your query directory without installation
npx @lxgicstudios/ai-index ./src/queries/

# Help command to see all options
npx @lxgicstudios/ai-index --help

Index Suggester Data Schema & Taxonomy

The tool processes source code and generates optimization metadata to guide database administrators.

Data Component Description
Supported Inputs .sql, .ts, .js, and .prisma files
Extraction Logic Identification of WHERE, JOIN, ORDER BY, and GROUP BY clauses
Recommendation Format Standard SQL CREATE INDEX syntax or CLI-based performance reports
Metadata Context Explanations regarding index selectivity and write-performance trade-offs

Index Suggester Advanced Features

  • Intelligent composite index generation with optimized column ordering based on query patterns.
  • Seamless integration with Openclaw Skills workflows for automated performance monitoring.
  • Direct export to SQL files to facilitate easy database migrations and version control.
  • Selective analysis modes for targeting specific files or entire project directories recursively.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*