Skip to main content
Glama
lpenguin
by lpenguin

get_shader

Retrieve WGSL source code for a ShaderModule object from a WebGPU capture. Provide the objectId and optional captureId to access shader code for debugging and analysis.

Instructions

Return the WGSL source code of a ShaderModule object in a capture.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
objectIdYesNumeric id of the ShaderModule object.
captureIdNoCapture id (default: most recent).
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It accurately discloses that the tool returns source code and is read-only in nature, but it does not mention edge cases like missing source data, invalid object IDs, or error behavior. This is adequate for a simple getter but not deeply transparent.

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?

The description is a single, front-loaded sentence with no wasted words. It states the action, the resource, and the scope ('in a capture') efficiently.

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 simple read-only getter, the description plus the complete schema covers what an agent needs to invoke it. The only minor gap is lack of detail about failure modes or unavailable source, but that is not essential for this tool's basic usage.

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 itself does not add parameter-level detail, but the schema already documents objectId and captureId clearly. No additional semantic value is provided by the description.

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 uses a specific verb ('Return') and names the exact resource ('WGSL source code of a ShaderModule object in a capture'). It clearly identifies what the tool does and is distinguishable from sibling tools like get_object or decode_vertex_buffer.

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 the tool should be used when the agent needs WGSL source for a ShaderModule, but it does not explicitly state when not to use it or mention alternatives such as get_object. The usage context is clear enough, though no exclusions or comparisons are provided.

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/lpenguin/webgpu_inspector_mcp'

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