Skip to main content
Glama

shell_cwd

Retrieves the current working directory of a persistent PowerShell session, enabling tracking of file system context during AI-driven Windows operations.

Instructions

获取持久化会话的当前工作目录。

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.2

TDQS

B3.3/5.0
Behavior3/5

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

No annotations are provided, so the description carries the burden. It implies a harmless read via '获取' and clarifies that the directory belongs to the persistent session rather than a transient one, but it says nothing about what happens if no session exists yet, whether a session is implicitly created, or the return form.

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?

A single sentence with no filler and the key scope qualifier ('persistent session') placed before the noun it modifies. Appropriately sized for a trivial getter, though it is arguably too terse to carry the missing behavioral detail.

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

Completeness3/5

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

For a zero-parameter getter with no output schema, the description covers the essential. It does not say what is returned (a path string?) or whether the call fails when no persistent session has been established, which an agent needs to know before relying on it.

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?

The tool takes zero parameters, so the schema is trivially complete and there is nothing for the description to disambiguate. Baseline of 4 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: retrieves the current working directory, scoped to the persistent session. That scope wording implicitly separates it from shell_cd and shell_exec, though it never names them explicitly.

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

Usage Guidelines2/5

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

No guidance on when to call this versus shell_cd or shell_exec — e.g. checking the cwd before issuing relative-path commands, or verifying the effect of a shell_cd. The use case is only inferable from the name and the word 'persistent session'.

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