Skip to main content
Glama
SongJiangzhou

C++ Style Guide MCP Server

check_const_correctness

Analyze C++ code to identify missing const qualifiers and provide improvement suggestions for const correctness.

Instructions

检查 C++ 代码中的 const 正确性

参数:
    code: 要检查的 C++ 代码

返回:
    const 正确性检查报告,包括缺少 const 的地方和改进建议

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool performs a '检查' (check) and returns a report, implying a read-only analysis without side effects. However, it lacks details on error handling, performance characteristics (e.g., time complexity for large code), input limitations (e.g., code size or language version support), or whether it requires external dependencies. The description is minimal and doesn't provide rich behavioral context.

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 concise and well-structured with three clear sections: purpose, parameters, and returns. Each sentence earns its place by providing essential information without redundancy. However, it could be more front-loaded by integrating the parameter and return details into the main flow for better readability, but it's still efficient.

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 has one parameter, no annotations, and an output schema (implied by the '返回' section), the description is moderately complete. It covers the basic purpose, parameter meaning, and return value, but lacks usage guidelines, behavioral details, and deeper parameter semantics. For a static analysis tool, more context on accuracy, limitations, or integration with other tools would enhance completeness.

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 description adds basic semantics for the single parameter 'code': '要检查的 C++ 代码' (C++ code to check). This clarifies that the input should be C++ source code as a string. However, with 0% schema description coverage (the schema only has a generic 'Code' title), the description doesn't provide additional details like expected format (e.g., raw code vs. file path), encoding, or constraints (e.g., maximum length). It compensates minimally but doesn't fully address the coverage 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: '检查 C++ 代码中的 const 正确性' (Check const correctness in C++ code). It specifies the verb ('检查' - check) and resource ('C++ 代码' - C++ code) with the specific focus on 'const 正确性' (const correctness). However, it doesn't explicitly differentiate from sibling tools like 'analyze_memory_safety' or 'suggest_modern_cpp', which might also involve C++ code analysis.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'suggest_modern_cpp' (which might include const-related suggestions) or 'check_naming' (which focuses on naming conventions). There's no context about prerequisites, typical use cases, or exclusions (e.g., whether it works with C code or specific C++ versions).

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/SongJiangzhou/cpp_guidelines'

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