Skip to main content
Glama

Open Sutta Viewer

open_sutta_viewer
Read-onlyIdempotent

Open an interactive sutta viewer inside the chat — Pāli + English, plus an optional third row in the user's own language translated BY YOU.

Renders each segment as: Pāli on top (canonical), the bilara-data English below it (verification anchor), and — when you supply translations — your translation in the user's language, clearly badged as AI-generated. Prefer this over dumping raw segments when the user wants to read a sutta.

  • sutta_id — standard SuttaCentral id, e.g. sn56.11, mn10, dn22.

  • around — a segment_id (e.g. dn22:18.1, from a search hit) to centre on; that segment is highlighted and scrolled into view. Use this after a search so the reader lands on the exact cited line.

  • offset — 0-based segment index for paging long suttas (use next_offset from the previous result). Do NOT combine with around.

  • window — segments before/after around to include (default 12).

🌐 Translating for the user (important): when the conversation language is neither English nor Pāli, you SHOULD translate the displayed segments and pass them via translations so the user reads in their own language while still seeing the originals:

  1. Fetch the segments first (get_sutta with the same selector) so you have the exact Pāli + English text. (Already called this tool without translations? The result contains the segments — translate them and call this tool AGAIN with the same selector plus translations to upgrade the view.) Your translation must travel through the translations parameter to appear in the viewer — writing it as a normal chat message leaves the viewer bilingual and looks broken; the tool always accepts translations, so never report it as missing.

  2. Translate from the Pāli as the source, using the English as a semantic guide — never relay-translate from English alone. Preserve untranslatable doctrinal terms (dukkha, jhāna, taṇhā…) as loanwords with a brief gloss instead of forcing equivalents.

  3. Call this tool with translations=[{segment_id, text}, ...] covering ONLY the segments being displayed (never a whole long sutta), translation_language (BCP-47, e.g. "th", "es"), and translation_disclaimer — one short line IN THE USER'S LANGUAGE saying the translation is AI-generated in this conversation and should be checked against the Pāli/English above. Translations are conversation-ephemeral: nothing is stored server-side; the canon stays Pāli + English only. Translations whose segment_id is not in the displayed window are dropped (reported in translations_dropped).

Without around, shows the sutta from the top (capped for long suttas).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "sutta_id": "<sutta_id>"
    },
    "name": "open_sutta_viewer"
  }
}

Input Schema

NameRequiredDescriptionDefault
aroundNo
offsetNo
windowNo
sutta_idYes
translationsNo
translation_languageNo
translation_disclaimerNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / offset
      Added value: +{
      +  "default": 0,
      +  "type": "integer"
      +}
  2. Added

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive, closed-world), and the description adds substantial context they cannot: translations are conversation-ephemeral with nothing persisted server-side, out-of-window segment_ids are dropped and reported in `translations_dropped`, and long suttas are capped when `around` is omitted. It even flags a failure mode (translation written as a chat message leaves the viewer looking broken) and its remedy.

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?

Purpose and the read-vs-dump rule are front-loaded, then parameters, then a numbered translation workflow — a sound structure for a 7-param tool with a multi-step protocol. It is long and repeats the 'never report translations as missing' instruction, though that emphasis targets a specific observed failure and mostly earns its space.

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?

An output schema exists, so return values need not be spelled out, and the description still covers the one output detail an agent must act on (translations_dropped). Together with full parameter and workflow coverage, nothing needed to invoke this tool correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must carry all seven parameters — and it does: sutta_id format with examples (sn56.11, mn10), around as a segment_id with search-hit provenance, offset's 0-based semantics and next_offset chaining, window's before/after meaning and default of 12, plus the exact translations payload shape, BCP-47 translation_language, and the purpose of translation_disclaimer.

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 + resource (open an interactive sutta viewer inside the chat) and immediately describes the rendered output (Pāli top, English below, optional AI-badged translation row). It also differentiates from siblings by saying to prefer it over dumping raw segments when the user wants to read, and it names get_sutta as its companion.

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 when-to-use conditions are given for each mode: use `around` after a search so the reader lands on the cited line, use `offset` with next_offset for paging long suttas, and an explicit exclusion (do NOT combine around with offset). It also prescribes the full translation workflow and when to call the tool a second time to upgrade the view.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources