Skip to main content
Glama

Graph health

graph_stats
Read-only

Count entities, relations, facts, notes, orphan entities, and top entities; enable check mode to flag old low-importance items and file entities with missing paths for cleanup.

Instructions

Counts of entities, relations, facts and notes, orphan entities (no relations) and the top entities. With check: also old low-importance entities and notes, and file entities whose path no longer exists.

Input Schema

NameRequiredDescriptionDefault
checkNoAlso list cleanup candidates
max_age_daysNoAge threshold for check, default 90

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, so safety is covered by structured data. The description adds genuine context beyond that: what check enumerates (old low-importance entities, stale notes, file entities whose path no longer exists), which is the kind of behavioral detail an agent cannot get from annotations.

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 sentences, no filler, and the default return content is front-loaded ahead of the conditional check behavior. Every clause carries information.

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?

With no output schema, the description correctly enumerates the returned metrics, which is the essential missing piece. Minor gaps remain: 'top entities' does not say how many or by what ranking, and the counts' scope (whole graph vs project) is unstated.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description meaningfully expands 'check' beyond the schema's terse 'Also list cleanup candidates' by naming the actual cleanup categories. max_age_days is left entirely to the schema, which is acceptable given full coverage.

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?

States a specific verb (counts) and resource (graph: entities, relations, facts, notes, orphans, top entities), and the 'With check' clause clarifies the extended mode. No sibling tool covers graph health, so it is unambiguously distinguishable.

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

Usage Guidelines3/5

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

The 'With check:' clause implies when to enable the extended mode, but there is no explicit guidance on when to call graph_stats at all versus other tools, nor any exclusions. Usage is left to be inferred from the name and the word 'health'.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.