Skip to main content
Glama
liang04
by liang04

execute_interactive_command

Execute interactive shell commands on remote SSH servers with input data support for automated workflows and scripted interactions.

Instructions

执行交互式命令(可以发送输入数据)

Args:
    command: 要执行的shell命令
    input_data: 要发送给命令的输入数据
    timeout: 命令执行超时时间(秒),默认30秒
    max_output_size: 最大输出大小(字节),默认8192(8KB)。
                    设置为0表示不限制(注意可能导致内存问题)。
                    超过限制的输出会被截断。
    connection_name: SSH连接名称,如果不指定则使用默认连接

Returns:
    Dict包含执行结果(同execute_command)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commandYes
input_dataNo
timeoutNo
max_output_sizeNo
connection_nameNo
Behavior4/5

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

With no annotations provided, the description carries full burden and does well by disclosing key behaviors: it mentions timeout defaults, output size limits with truncation warnings, memory risks for unlimited output, and SSH connection fallback. It also references return format consistency with 'execute_command'. However, it doesn't cover error handling, security implications, or execution environment details.

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 with the core purpose first. The Args/Returns structure is clear, though slightly verbose in Chinese. Every sentence adds value: purpose statement, parameter explanations with defaults and warnings, and return format reference. Minor improvement possible by tightening the language.

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 5 parameters with 0% schema coverage, no annotations, and no output schema, the description does an excellent job compensating. It explains all parameters thoroughly, mentions behavioral traits like truncation and memory risks, and references the return format. For a complex interactive execution tool, it's nearly complete but could benefit from more on error cases or security notes.

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?

Schema description coverage is 0%, so the description must compensate fully. It successfully adds meaning for all 5 parameters: explains 'command' as shell command, 'input_data' as data to send, 'timeout' as execution timeout in seconds with default, 'max_output_size' as byte limit with default and truncation warning, and 'connection_name' as SSH connection with default fallback. This provides comprehensive semantic context beyond the bare schema.

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?

The description clearly states the tool '执行交互式命令(可以发送输入数据)' which translates to 'Execute interactive commands (can send input data)'. This specifies the verb 'execute' and resource 'interactive commands', distinguishing it from the sibling 'execute_command' by emphasizing interactive capability with input data. However, it doesn't explicitly differentiate from all siblings like SSH-related tools.

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 description implies usage for interactive commands that require input data, suggesting when to use this over 'execute_command'. However, it doesn't provide explicit guidance on when NOT to use it or mention alternatives like 'execute_command' for non-interactive scenarios. The context is clear but lacks comprehensive exclusion criteria.

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/liang04/ssh-mcp'

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