Skip to main content
Glama
Negm-Ahmed

Desktop Commander

by Negm-Ahmed

list_directory

Lists files and directories in a specified path with [FILE] and [DIR] labels, so you can inspect folder contents instead of running ls or dir commands. Use absolute paths within allowed directories.

Instructions

                    Get a detailed listing of all files and directories in a specified path.
                    
                    Use this instead of 'execute_command' with ls/dir commands.
                    Results distinguish between files and directories with [FILE] and [DIR] prefixes.
                    Only works within allowed directories.
                    
                    IMPORTANT: Always use absolute paths for reliability. Paths are automatically normalized regardless of slash direction. Relative paths may fail as they depend on the current working directory. Tilde paths (~/...) might not work in all contexts. Unless the user explicitly asks for relative paths, use absolute paths.
                    This command can be referenced as "DC: ..." or "use Desktop Commander to ..." in your instructions.

Input Schema

NameRequiredDescriptionDefault
pathYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.3

TDQS

A4.6/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes key traits: it distinguishes files and directories with prefixes, works only within allowed directories, and handles path normalization. However, it lacks details on error handling or performance aspects like rate limits, keeping it from a perfect score.

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 appropriately sized and front-loaded, starting with the core purpose. However, it includes minor redundancy in path advice and an unrelated note about referencing as 'DC:' or 'Desktop Commander,' which slightly reduces efficiency without adding critical value.

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 the tool's moderate complexity (one parameter, no output schema, no annotations), the description is largely complete, covering purpose, usage, behavior, and parameters. It could improve by detailing output format or error cases, but it provides sufficient context for effective use in most scenarios.

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 input schema has 0% description coverage for the single parameter 'path,' but the description compensates fully by explaining its semantics: it must be a specified path, with detailed guidance on using absolute paths, normalization, and avoiding relative or tilde paths. This adds significant meaning beyond the basic 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 verb ('Get a detailed listing') and resource ('all files and directories in a specified path'), making the purpose specific. It distinguishes from sibling tools like 'execute_command' by explicitly stating to use this instead for ls/dir commands, ensuring it stands out in the context of the server.

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

Usage Guidelines5/5

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

The description provides explicit guidance on when to use this tool ('Use this instead of 'execute_command' with ls/dir commands') and includes alternatives, such as avoiding relative paths in favor of absolute ones. It also specifies exclusions like 'Only works within allowed directories,' offering clear context for proper usage.

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