Skip to main content
Glama
ansys

Ansys CFX-MCP

Official
by ansys

validate_code

Validate generated Python code before execution. Returns parse, type, and semantic feedback to catch errors without side effects.

Instructions

Dry-run / validate the generated code without applying side effects. Returns parse / type / semantic feedback for the LLM.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesPython source code submitted for validation, grounding, or execution.
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It explicitly states that no side effects are applied and describes the kind of feedback returned (parse/type/semantic), which are important behavioral traits. It could go further by noting failure modes or constraints, but the core safety-critical aspect is covered.

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?

Two concise sentences front-load the purpose and key limitation. Every word adds value, and there is no redundancy or irrelevant detail.

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 a single parameter, a well-covered schema, and a simple validation use case, the description is largely sufficient. It explains the purpose, the no-side-effect guarantee, and the nature of the output. It could include a brief example or explicit exclusions, but for this level of complexity, the description covers the essential context.

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?

The input schema has 100% coverage with a descriptive 'code' parameter ('Python source code submitted for validation, grounding, or execution'), so the schema already provides strong semantics. The tool description does not add further parameter detail, warranting the baseline score of 3.

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 a specific action ('Dry-run / validate'), the resource ('generated code'), and the scope ('without applying side effects'). It also distinguishes itself from likely siblings like run_code by emphasizing no side effects and from codegen by focusing on validation rather than generation.

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 implies the tool should be used to check generated code before executing it, indicated by 'Dry-run' and 'without applying side effects.' It does not explicitly name alternatives or state when not to use it, but the context of validation vs. execution is clear enough for an agent to make an appropriate selection.

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/ansys/pycfx-mcp'

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