Skip to main content
Glama

wincode_prepare_context

Generates a focused code context snapshot for AI agents, extracting relevant symbols and architecture while packing essential files to support task decisions.

Instructions

Prepares concise, high-semantic, decision-ready context snapshot for an agent task using Repomix and semantic distillation. Extracts relevant symbols, architectures, and packs essential files.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskYesDescription of the coding task or query the agent is working on (e.g. "分析这个项目架构").
compressNoWhether to extract essential code structures (classes, methods, interfaces) using Tree-sitter compression.
focusAreasNoOptional subdirectories or glob patterns to focus on (e.g. ["src/Core"]).
outputFormatNoOutput format of packed snapshot (default: markdown).
candidateFilesNoOptional list of candidate file paths to prioritize.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

No annotations are provided, so the description carries the burden of explaining behavior. It does disclose the process: Repomix-based packing and semantic distillation, and what is extracted: 'relevant symbols, architectures, and essential files.' However, it does not state whether the tool writes files to disk, returns the snapshot inline, requires external dependencies, or has side effects.

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 two sentences and front-loads the primary purpose before explaining the method. It is reasonably concise, though phrases like 'high-semantic' and 'semantic distillation' are somewhat jargon-heavy. No unnecessary filler is present.

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

Completeness3/5

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

All parameters are documented and the core purpose is clear, but there is no output schema and the description does not describe what the agent will actually receive or where the packed snapshot goes. Given the tool is meant to prepare context, return format and side effects are relevant missing pieces. Still, the description is adequate for a basic first selection.

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 the baseline is 3. The description does not add parameter-specific detail beyond what the schema already provides; it only loosely maps to task and candidateFiles. It does not clarify how compress, focusAreas, or outputFormat affect the resulting snapshot beyond their schema descriptions.

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 states a specific verb and resource: it 'Prepares' a 'context snapshot' for an agent task, using Repomix and semantic distillation. This makes it distinguishable from siblings like wincode_analyze_workspace and wincode_diagnose_project, which are more analytical. However, it does not explicitly call out any sibling to differentiate itself from.

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 when to use the tool: when an agent needs a 'decision-ready context snapshot' before working on a task. There is no explicit guidance on when not to use it or how it compares to alternatives like wincode_find_code_symbol or wincode_plan_refactoring. The usage context is clear but not fully explicit.

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