Skip to main content
Glama

get_system_info

Retrieve detailed operating system information including type, version, architecture, and system specifications to provide accurate technical guidance and system-specific instructions.

Instructions

【建议调用】获取用户操作系统的详细信息。

⚠️ 重要:不要假设用户的操作系统,调用此工具获取准确的系统信息。

强制调用场景:

  • 用户询问系统信息("我的系统"、"操作系统版本")

  • 提供安装/配置指令前(不同系统命令不同)

  • 诊断系统相关问题或错误

  • 讨论软件兼容性、系统要求

  • 用户提到"安装"、"配置"、"运行"、"部署"任何软件

  • 提供命令行指令时(Windows/macOS/Linux 命令不同)

返回信息:操作系统类型(Windows/macOS/Linux)、版本号、架构(x64/ARM/ARM64)、内核版本、主机名、系统运行时间等。

⚠️ 在提供技术建议前必须调用此工具,确保指令适用于用户的系统!

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that implements the get_system_info tool logic. It uses the 'systeminformation' library and Node.js 'os' module to gather comprehensive system details including OS info, hardware, UUID, and user info.
    export async function getSystemInfo() {
      try {
        const osInfo = await si.osInfo();
        const system = await si.system();
        const uuid = await si.uuid();
        
        return {
          platform: os.platform(),
          type: os.type(),
          release: os.release(),
          version: os.version(),
          arch: os.arch(),
          hostname: os.hostname(),
          uptime: os.uptime(),
          
          // 详细系统信息
          distro: osInfo.distro,
          codename: osInfo.codename,
          kernel: osInfo.kernel,
          build: osInfo.build,
          
          // 系统制造商信息
          manufacturer: system.manufacturer,
          model: system.model,
          serial: system.serial,
          
          // UUID
          uuid: uuid.os,
          
          // 用户信息
          username: os.userInfo().username,
          homedir: os.homedir(),
          tmpdir: os.tmpdir(),
        };
      } catch (error) {
        if (error instanceof Error) {
          throw new Error(`获取系统信息失败: ${error.message}`);
        }
        throw error;
      }
    }
  • The tool schema as provided in the ListTools response, including name, detailed description, and empty inputSchema (no parameters required).
          {
            name: "get_system_info",
            description: `【建议调用】获取用户操作系统的详细信息。
    
    ⚠️ 重要:不要假设用户的操作系统,调用此工具获取准确的系统信息。
    
    强制调用场景:
    - 用户询问系统信息("我的系统"、"操作系统版本")
    - 提供安装/配置指令前(不同系统命令不同)
    - 诊断系统相关问题或错误
    - 讨论软件兼容性、系统要求
    - 用户提到"安装"、"配置"、"运行"、"部署"任何软件
    - 提供命令行指令时(Windows/macOS/Linux 命令不同)
    
    返回信息:操作系统类型(Windows/macOS/Linux)、版本号、架构(x64/ARM/ARM64)、内核版本、主机名、系统运行时间等。
    
    ⚠️ 在提供技术建议前必须调用此工具,确保指令适用于用户的系统!`,
            inputSchema: {
              type: "object",
              properties: {},
            },
          },
  • src/index.ts:211-221 (registration)
    The registration in the CallToolRequestSchema handler switch statement that invokes the getSystemInfo function and formats the response.
    case "get_system_info": {
      const result = await getSystemInfo();
      return {
        content: [
          {
            type: "text",
            text: JSON.stringify(result, null, 2),
          },
        ],
      };
    }
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 what the tool returns (OS type, version, architecture, kernel version, hostname, uptime) and emphasizes its importance for providing accurate technical advice. However, it doesn't mention potential limitations like rate limits, authentication requirements, or error conditions, which would be helpful for a tool with no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately front-loaded with the core purpose, but contains some redundancy in the usage scenarios list and uses multiple warning symbols (⚠️) that could be streamlined. While all content is relevant, the structure could be more efficient with better grouping of similar scenarios and less repetitive emphasis.

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 complexity (0 parameters, no output schema, no annotations), the description provides strong contextual completeness by clearly explaining what information the tool returns and when to use it. The main gap is the lack of output schema, which means the description must fully explain return values - it does this adequately by listing the specific data points returned, though a structured output schema would be more precise.

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 has 0 parameters with 100% schema description coverage, so the baseline would be 4 even with no parameter information in the description. The description appropriately doesn't discuss parameters since none exist, maintaining focus on the tool's purpose and usage guidelines.

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 tool's purpose as '获取用户操作系统的详细信息' (get detailed information about the user's operating system), which is a specific verb+resource combination. It distinguishes itself from sibling tools like get_hardware_info, get_location, and get_time by focusing specifically on operating system details rather than hardware, location, or time information.

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 versus making assumptions, listing six specific scenarios including user inquiries about system info, before providing installation/configuration instructions, diagnosing system issues, discussing compatibility, when users mention installation/configuration/running/deployment, and before providing command-line instructions. It also includes a strong warning not to assume the user's OS and to call this tool for accurate information.

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/pepedd864/agent-sense'

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