Skip to main content
Glama

plan_turn

Read-onlyIdempotent

Routes new tasks by combining search and session history to return insertion targets, scaffold hints, and recommended next tools. Call this first to prevent empty-result hallucinations.

Instructions

Opening-move router for new tasks. Combines BM25/PageRank search + session journal (negative evidence + focus signals) + framework-aware insertion-point suggestions + change-risk + turn-budget advisor into ONE call. Returns verdict (exists/partial/missing/ambiguous), confidence, ranked targets with provenance, scaffold hints when missing, and recommended next tool calls. Call this FIRST on a new task to break the empty-result hallucination chain. Read-only. For broader task context with source code use get_task_context instead. Returns JSON: { verdict, confidence, targets, scaffoldHints, nextSteps }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskYesNatural-language task description (e.g. "add a webhook endpoint for stripe payments")
intentNoOptional intent hint; auto-classified from task if omitted
max_targetsNoCap on returned targets (default 5)
skip_riskNoSkip change-risk assessment for the top target (default false)
Behavior5/5

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

Annotations already indicate read-only, non-destructive, idempotent, closed-world. The description adds rich behavioral details like combining search, journal, risk assessment, and returning verdict, confidence, targets, scaffoldHints, nextSteps. No contradictions.

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?

Reasonably concise for the complexity. Front-loaded with purpose. Could be slightly tighter but no extraneous content.

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

Completeness5/5

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

Despite no output schema, the description specifies the return JSON structure with fields. It also mentions sibling tool context. Sufficiently complete for a complex tool with clear annotations.

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?

Schema coverage is 100% with good descriptions. The description adds context (e.g., intent auto-classification, purpose of max_targets and skip_risk) beyond the schema. Minor additional value.

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 explicitly states it's an 'Opening-move router for new tasks' and lists its specific functionality. It distinguishes itself from get_task_context, clarifying when to use which tool.

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?

Provides explicit guidance: 'Call this FIRST on a new task to break the empty-result hallucination chain.' Also specifies an alternative: 'For broader task context with source code use get_task_context instead.'

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/nikolai-vysotskyi/trace-mcp'

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