Skip to main content
Glama

get_doc

Read-onlyIdempotent

Retrieve Pine Script v6 documentation files to access function references, syntax details, and code examples for accurate trading indicator development.

Instructions

Read a specific Pine Script v6 documentation file.

For large files (ta.md, strategy.md, collections.md, drawing.md, general.md) prefer list_sections() + get_section() to avoid loading 1000-2800 line files into context.

Args: path: Relative path to the documentation file (e.g., "reference/functions/ta.md") limit: Maximum characters to return. Use 30000 for large files to avoid token limits. offset: Character offset to start reading from (default: 0)

Returns the contents with metadata header showing total size and current slice.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
limitNo
offsetNo
Behavior4/5

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

Annotations already declare readOnlyHint=true and idempotentHint=true, indicating safe, repeatable reads. The description adds valuable context beyond this: it warns about token limits for large files, recommends specific limit values (30000), and describes the return format (contents with metadata header). This enhances behavioral understanding without contradicting annotations.

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 front-loaded with the core purpose, followed by usage guidelines and parameter details in a structured format. Every sentence earns its place: the first states the purpose, the second gives critical usage advice, and the parameter explanations are concise yet informative. No wasted words.

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?

Given the tool's complexity (file reading with slicing), lack of output schema, and 0% schema coverage, the description is highly complete. It covers purpose, usage alternatives, parameter semantics, behavioral constraints (token limits), and return format. No significant gaps remain for an agent to understand and use the tool effectively.

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?

With 0% schema description coverage, the description fully compensates by explaining all three parameters: 'path' (relative path to file), 'limit' (maximum characters, with usage advice), and 'offset' (character offset). It provides practical examples (e.g., 'reference/functions/ta.md') and default values, adding significant meaning beyond the bare schema.

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 clearly states the specific action ('Read a specific Pine Script v6 documentation file') and resource ('documentation file'), distinguishing it from siblings like get_section (which reads sections) or list_docs (which lists files). The verb 'Read' is precise and the resource scope is well-defined.

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?

Explicit guidance is provided on when to use alternatives: for large files, prefer list_sections() + get_section() to avoid loading large files into context. This directly addresses sibling tools (list_sections and get_section) and specifies exclusion criteria based on file size.

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/paulieb89/pinescript-mcp'

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