Skip to main content
Glama

analyze_database_queries

Analyze database queries in code for performance, security, and best practices to identify issues and assess technical debt.

Instructions

Analyze database queries for performance, security, and best practices in code files or entire projects

WORKFLOW: Perfect for understanding complex code, identifying issues, and technical debt assessment TIP: Use Desktop Commander to read files, then pass content here for analysis SAVES: Claude context for strategic decisions

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
analysisDepthNoLevel of analysis detaildetailed
analysisTypeNoType of database analysis to performcomprehensive
codeNoThe code to analyze for database queries (for single-file analysis)
contextNoDatabase and framework context for specialized analysis
filePathNoPath to single file to analyze for database queries
filesNoArray of specific file paths (for multi-file analysis)
languageNoProgramming languagephp
maxDepthNoMaximum directory depth for multi-file discovery (1-5)
projectPathNoPath to project root (for multi-file database analysis)
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden of behavioral disclosure. It mentions the tool 'SAVES: Claude context for strategic decisions' which adds useful behavioral context about state persistence. However, it doesn't disclose other important traits like whether this is a read-only analysis tool, potential performance impact, error handling, or output format expectations. The description adds some value but leaves significant behavioral aspects unspecified.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is efficiently structured with clear sections (purpose, workflow, tip, saves) using minimal sentences. Each section adds value: the first states purpose, the second provides usage context, the third gives a practical tip, and the fourth discloses behavioral trait. However, the formatting with all-caps headings could be more polished, and the workflow section could be integrated more smoothly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (9 parameters, no output schema, no annotations), the description provides adequate but incomplete coverage. It explains the purpose and basic workflow well, but doesn't address important contextual aspects like what the analysis output looks like, error conditions, or how different parameters interact. For a tool with this many parameters and no output schema, more completeness would be expected regarding what users can expect from the analysis results.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all 9 parameters thoroughly with descriptions, defaults, and enums. The description doesn't add any parameter-specific information beyond what's in the schema. It mentions analyzing 'code files or entire projects' which aligns with the filePath/projectPath parameters but doesn't provide additional semantic context. Baseline 3 is appropriate when schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool analyzes database queries for performance, security, and best practices in code files or projects. It specifies the resource (database queries) and scope (code files/projects) with specific analysis dimensions. However, it doesn't explicitly differentiate from siblings like 'analyze_code_quality' or 'security_audit' which might overlap in analyzing code or security aspects.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context for usage: 'Perfect for understanding complex code, identifying issues, and technical debt assessment' and includes a workflow tip to use Desktop Commander for file reading. It implies this tool is for database-specific analysis in code, but doesn't explicitly state when to use alternatives like 'analyze_code_quality' for non-database code analysis or 'security_audit' for broader security checks.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/houtini-ai/houtini-lm'

If you have feedback or need assistance with the MCP directory API, please join our Discord server