Recommend indexes
recommend_indexesIdentifies large PostgreSQL tables with high sequential scans that may benefit from indexing. Returns schema, statistics, and reasoning for each candidate.
Instructions
Recommend tables that may benefit from indexing — large tables read mostly by sequential scan. Returns a list of objects with schema, table, live_tuples, sequential_scans, index_scans, and a reason explaining why the table is a candidate.
Example: recommend_indexes(min_live_tuples=10000)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| database | No | Optional: target a configured secondary (read-only) database by name; omit for the primary. Call list_databases to see the configured ids. | |
| min_live_tuples | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |