Skip to main content
Glama

cos_graph_doctor

Read-onlyIdempotent

Diagnose knowledge graph health by detecting orphans, dangling edges, duplicates, and backend status. Run report-only mode to review issues, then optionally fix dangling edges.

Instructions

Graph health snapshot — orphans, dangling edges, duplicates, backend status.

Call when graph queries return nothing or meta.backend_fallback=true.

Args: fix: If True, attempt safe repairs (delete dangling edges). Default False — use the report-only mode to see what would change first.

Returns: JSON envelope with healthy boolean, issues list, stats dict.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fixNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior1/5

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

The description states that setting fix=true will 'attempt safe repairs (delete dangling edges)', which is a destructive/write operation. However, annotations declare readOnlyHint=true and destructiveHint=false, creating a direct contradiction. This is a severe inconsistency that could mislead the agent into thinking the tool is safe and read-only when it can modify data.

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 extremely concise and well-structured: purpose is front-loaded, usage trigger is given, parameters and returns are clearly bulleted. Every sentence earns its place with no waste.

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

Completeness5/5

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

Given the tool's simplicity (one optional parameter) and the presence of an output schema, the description covers all necessary aspects: purpose, when to call, parameter semantics, and return envelope. It even mentions the safe usage pattern (report-only first), making it complete for an agent to invoke correctly.

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

Parameters5/5

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

The schema only provides the parameter name 'fix' with a default, but the description fully explains its meaning, including conditional behavior (repair vs. report-only mode) and a recommendation to use report-only first. This adds significant value beyond the schema.

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's purpose as a 'Graph health snapshot' and lists specific issue types (orphans, dangling edges, duplicates, backend status). This distinguishes it from sibling graph tools like cos_graph_query or cos_health by focusing on integrity diagnostics rather than querying or general health.

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?

It provides explicit trigger conditions: 'Call when graph queries return nothing or meta.backend_fallback=true.' This gives clear context for when to use it, though it doesn't explicitly mention alternatives or when not to use it, so it falls short of a 5.

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/kouroshez/coding-os'

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