Skip to main content
Glama

opencode_policy

Shows the delegation policy opencode_start enforces for a directory—active routing mode, allowed agents, tier and verification rules—so you pick the right mode before delegating.

Instructions

READ-ONLY. Show the delegation policy that opencode_start enforces: the ACTIVE routing mode for a directory and where it was detected, the agents allowed in that mode, the tier rules (what to delegate / keep), the verification rules and the roster. Call it before delegating if unsure which mode applies.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "opencode_policy"
  }
}

Input Schema

NameRequiredDescriptionDefault
cwdNodirectory to evaluate (default: the bridge root)
modeNopreview what an explicit mode would do

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.5.0

TDQS

A4.1/5.0
Behavior4/5

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

No annotations are supplied, so the description carries the full burden, and it leads with 'READ-ONLY', making the non-mutating nature unambiguous. It also frames the mode parameter as a preview of what an explicit mode would do, reinforcing that no state changes. It does not address permissions, caching, or output size, which keeps it short of a 5.

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?

Front-loads the most important constraint (READ-ONLY) and then lists what is reported in a single dense sentence, followed by a short usage cue. The enumeration is long but each item is a distinct piece of returned information, so little is wasted.

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?

With no output schema, the description compensates by enumerating what the tool reports, and with zero required parameters it makes clear the call is safe and cheap. The only gap is that it does not describe the response shape or how the tier/verification rules are formatted.

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 both cwd and mode are already documented in the schema, including the default root for cwd and the preview semantics of mode. The description adds no parameter-level detail beyond that, so the baseline 3 applies.

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?

States a specific verb and resource ('Show the delegation policy that opencode_start enforces') and enumerates the payload: active routing mode, detection location, allowed agents, tier rules, verification rules, roster. This clearly distinguishes it from the execution siblings like opencode_start.

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

Usage Guidelines4/5

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

Gives an explicit trigger: 'Call it before delegating if unsure which mode applies.' That ties usage to a concrete decision point. It stops short of naming when not to call it (e.g. once mode is known) or pointing at a preferred alternative for other inspection needs.

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