Skip to main content
Glama

check_database_design

Validate database models against custom design rules to catch missing primary keys, naming violations, and column issues. Returns passed, errors, warnings, and skipped rules for clear compliance reporting.

Instructions

Check a model against YOUR design rules. rules: [{id, description, type, params?, severity?}]. Machine-checkable types: TABLE_HAS_PK, TABLE_CODE_PATTERN, TABLE_NAME_STYLE, COLUMN_HAS_COMMENT, COLUMN_CODE_PATTERN, COLUMN_MANDATORY, REQUIRED_COLUMNS, PK_NAME_PATTERN, FK_NAME_PATTERN, INDEX_NAME_PATTERN, DATA_TYPE_ALLOWED, NO_DUPLICATE_INDEX, NO_EMPTY_COMMENT_TABLE, REGEX. Rules with unknown types are reported in 'skipped' (never silently ignored). Returns passed/errors/warnings/violations.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
rulesYes
model_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the burden of behavioral disclosure. It reveals that rules with unknown types are not silently ignored, which is a key behavior. It also lists return categories (passed/errors/warnings/violations), but does not detail error handling, side effects, or operational requirements. Given the absence of annotations, this is adequate but not rich.

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 moderately concise, packing essential information about rules handling in a single paragraph. It starts with the core purpose and then details the rules parameter. It could be slightly more structured but is free of fluff and front-loads the main action.

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

Completeness4/5

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

Given the tool's complexity (array of rule types, unknown-type handling) and the sparse schema (0% coverage), the description covers most necessary ground: it explains the rules structure, type handling, and return categories. It misses only the model_id semantics, but overall is sufficiently complete for correct invocation.

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

Parameters2/5

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

Since schema description coverage is 0%, the description must fully explain parameters. It describes 'rules' in detail, including the structure and types. However, 'model_id' is only defined by its title; the description does not explain what a model_id is or how it relates to the model being checked. This is a notable gap.

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's purpose: checking a model against user-defined design rules. It specifies the resource (a model) and the action (check), which distinguishes it from validation tools. However, it doesn't directly contrast with siblings like validate_model, so it gets a 4 rather than a 5.

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 elaborates on the rules parameter, explaining the types and how unknown types are handled ('reported in skipped'). This gives context on how to construct the rules. However, it doesn't explicitly discuss when to use this tool versus other validation or inspection tools, which would require a 5.

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