Skip to main content
Glama

set_priority

Idempotent

Adjust a process's priority by PID to limit background CPU use or boost responsiveness, from idle to realtime; realtime can starve other processes and requires consent.

Instructions

Sets a process' priority class: idle, below_normal, normal, above_normal, high or realtime (realtime can starve the rest of the system).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "pid": "<pid>",
      "priority": "<priority>"
    },
    "name": "set_priority"
  }
}

Input Schema

NameRequiredDescriptionDefault
pidYesThe process ID (list_processes gives it).
forceNoTrue only after the user agreed to the risk this tool described.
priorityYesidle, below_normal, normal, above_normal, high or realtime.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.6.0
    • addedInput schema / properties / force / description
      Added value: +"True only after the user agreed to the risk this tool described."
    • addedInput schema / properties / pid / description
      Added value: +"The process ID (list_processes gives it)."
  2. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare a non-readonly, idempotent, non-destructive mutation, and the description adds a genuine behavioral caveat the annotations do not capture: realtime can starve the rest of the system. It stops short of explaining permission requirements or that the 'force' acknowledgement gates risky values, which the schema handles instead.

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?

A single sentence with the operation front-loaded and the risk warning placed in a tight parenthetical right where the risky value appears. No filler, nothing to cut.

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?

For a three-parameter mutation with full schema coverage, no output schema and complete annotations, this is nearly sufficient: the agent knows what it changes and the one dangerous value. Only the permission/force precondition and the effect on a running process are left implicit.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so all three parameters are already documented, and the description's enumeration of priority strings largely duplicates the schema. The only added meaning is the risk note attached to 'realtime', which is a marginal but real contribution above the schema baseline.

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 ('Sets a process' priority class') and enumerates the six valid classes, so an agent immediately knows the operation. It does not name or distinguish itself from adjacent mutators like limit_process, set_affinity or set_efficiency_mode, so it falls short of full sibling differentiation.

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?

Usage is implied rather than stated: the parenthetical warning about realtime effectively discourages that value, but there is no explicit when-to-use framing, no mention of needing elevated privileges, and no routing to alternatives such as set_efficiency_mode or limit_process when throttling rather than priority is intended.

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