Skip to main content
Glama
reflex-search

Reflex

Official

find_hotspots

Identify the most-imported files in your codebase to find critical dependencies and plan refactoring priorities.

Instructions

Find the most-imported files in the codebase (dependency hotspots).

Purpose: Identify files that many other files depend on.

Pagination: Default limit of 200 results per page. Check response.pagination.has_more to fetch more pages.

Sorting: Default order is descending (most imports first). Use sort parameter to change.

Returns: Object with pagination metadata and array of {path, import_count} objects sorted by import count.

Use this when:

  • Finding critical files

  • Identifying potential bottlenecks

  • Understanding architecture

  • Planning refactoring priorities

IMPORTANT: Only counts static imports (string literals). Dynamic imports are filtered. See CLAUDE.md section "Dependency/Import Extraction" for details.

Example output: {"pagination": {...}, "results": [{"path": "src/models.rs", "import_count": 27}]}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum number of hotspots per page (default: 200)
min_dependentsNoMinimum number of dependents to include (default: 2)
offsetNoPagination offset (skip first N results). Use with limit for pagination.
sortNoSort order: 'asc' (least imports first) or 'desc' (most imports first, default)
Behavior5/5

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

With no annotations, the description carries full burden and does well: it explains pagination (default 200, has_more), sorting (default desc), return format (path, import_count), and the critical limitation of only counting static imports.

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 well-structured with clear sections (purpose, pagination, sorting, returns, use cases, important note, example). It is front-loaded and concise with no wasted sentences.

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?

For a tool with 4 params, no output schema, and no annotations, the description covers all necessary aspects: purpose, parameter behavior, pagination, sorting, return format, and a crucial limitation. It is fully actionable.

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% and has descriptions. The description adds defaults (limit=200, min_dependents=2) and clarifies pagination and sort usage 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 it finds the most-imported files (dependency hotspots). This is a specific verb+resource that distinguishes it from sibling tools like find_references or get_dependencies.

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 provides explicit use cases (finding critical files, bottlenecks, etc.) and an important constraint (static imports only). However, it does not mention when not to use or suggest alternatives among the many sibling tools.

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/reflex-search/reflex'

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