Skip to main content
Glama

roslyn:get_diagnostics

Get compiler errors, warnings, and info messages for any file or entire project. Use before committing to catch code issues.

Instructions

Get compiler errors, warnings, and info messages for a file or entire project. Returns: list of diagnostics with id, message, severity, and location. Use before committing to catch issues.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filePathNoOptional: path to specific file, omit for all files
projectPathNoOptional: path to specific project
severityNoOptional: filter by severity (Error, Warning, Info)
includeHiddenNoInclude hidden diagnostics (default: false)
Behavior3/5

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

No annotations are provided, so the description must convey behavioral traits. It states the tool returns a list of diagnostics with details, but does not disclose potential side effects, prerequisites (e.g., loaded solution), or whether it triggers compilation. The 'use before committing' hint suggests a read-only check, but this is not explicit.

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: the first covers purpose and return format, the second gives usage guidance. No unnecessary words, and the core information is front-loaded.

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 output schema and four optional parameters, the description is fairly complete. It explains what is returned and when to use it. However, it does not address cases like overlapping parameters or what happens if no diagnostics are found. Still adequate for most use cases.

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 description itself does not add significant meaning beyond what the parameters already convey. The main description does not elaborate on parameter usage; it relies on the schema, making a baseline score of 3 appropriate.

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 tool retrieves compiler diagnostics (errors, warnings, info) for a file or project. It distinguishes from sibling tools like analyze_control_flow or analyze_data_flow, which are more specific analyses.

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 advises using the tool 'before committing to catch issues,' providing a clear usage context. It does not explicitly say when not to use it or mention alternatives, but the context of sibling tools implies alternatives for more targeted analysis.

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/pzalutski-pixel/sharplens-mcp'

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