Skip to main content
Glama

check-well-formed

Validate logical statement syntax to catch errors before reasoning operations, ensuring formulas follow first-order logic rules for predicates, quantifiers, and operators.

Instructions

Check if logical statements are well-formed with detailed syntax validation.

When to use: Before calling prove/find-model to catch syntax errors early. When NOT to use: You already know the formula syntax is correct.

Example: statements: ["all x (P(x) -> Q(x))"] → Returns: { valid: true, statements: [...] }

Common syntax issues:

  • Use lowercase for predicates/functions: man(x), not Man(x)

  • Quantifiers: "all x (...)" or "exists x (...)"

  • Operators: -> (implies), & (and), | (or), - (not), <-> (iff)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
statementsYesLogical statements to check
verbosityNoResponse verbosity: 'minimal' (token-efficient), 'standard' (default), 'detailed' (debug info)
Behavior4/5

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

With no annotations provided, the description carries full burden and does well by explaining the tool's behavior: it validates syntax, returns a structured result with validity status and processed statements, and lists common syntax issues. It doesn't cover all behavioral aspects like error handling or performance, but provides substantial context beyond basic purpose.

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

Conciseness5/5

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

The description is well-structured and front-loaded with the core purpose, followed by usage guidelines, example, and common issues. Every sentence earns its place by providing actionable information without redundancy, making it efficient and easy to parse.

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 no annotations and no output schema, the description does a good job covering the tool's context: it explains the validation purpose, usage scenarios, example output, and syntax rules. It could be more complete by detailing the output structure or error cases, but it's largely sufficient for a validation tool with clear parameters.

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 both parameters thoroughly. The description doesn't add significant meaning beyond the schema—it mentions 'statements' in the example but doesn't elaborate on syntax rules beyond the common issues list, and doesn't discuss 'verbosity' at all. 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.

Purpose5/5

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

The description clearly states the specific purpose: 'Check if logical statements are well-formed with detailed syntax validation.' This explicitly identifies the verb ('check'), resource ('logical statements'), and scope ('syntax validation'), distinguishing it from siblings like prove or find-model which perform different operations on statements.

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

Usage Guidelines5/5

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

The description provides explicit guidance with dedicated 'When to use' and 'When NOT to use' sections. It specifies to use this tool 'Before calling prove/find-model to catch syntax errors early' and avoid it when 'You already know the formula syntax is correct,' clearly differentiating it from alternative tools.

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/autonull/mcplogic'

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