Skip to main content
Glama
Ganjoor MCP Server

Ganjoor MCP Server

Official
by ganjoor

Find Similar Poems By Metre And Rhyme

ganjoor_find_similar_poems
Read-onlyIdempotent

Find poems sharing a prosodic metre and rhyme letter to discover related poems and reply-poetry, letting you trace how one poet answered another. Filter by poet, category, or couplet count.

Instructions

Find poems that share a poem's prosodic metre and rhyme letter — the basis of Ganjoor's "related poems" (شعرهای مرتبط) pages.

Two Persian poems matching in metre and rhyme can be read as answers to each other (reply-poetry), so this is also how you trace how one poet answered another.

Args:

  • metre (string): The prosodic metre pattern, exactly as listed by ganjoor_list_rhythms

  • rhyme (string): Optional rhyme letter filter (e.g. 'ا', 'ب'). Empty means any.

  • poet_id (number): Restrict to a poet id. 0 = all poets (default: 0)

  • cat_id (number): Restrict to a category id. 0 = all categories (default: 0)

  • couplet_count_min (number): Only poems with at least this many couplets (default: 0)

  • couplet_count_max (number): Only poems with at most this many couplets (default: 0, meaning no cap)

  • page (number): Page number, starting from 1 (default: 1)

  • page_size (number): Results per page, 1-100 (default: 20)

  • response_format ('markdown' | 'json'): Output format (default: 'markdown')

Returns: For JSON: { count, page, page_size, has_more, next_page, poems: [{ id, title, full_title, full_url, plain_text }] }

Examples:

  • "Which Hafez poems share metre 'فاعلاتن مفاعلن فعلن'?" -> metre='فاعلاتن مفاعلن فعلن', poet_id=2

  • "Poems in metre X rhyming on ب" -> metre='...', rhyme='ب'

Notes:

  • metre must match the metre notation exactly; call ganjoor_list_rhythms to get valid values.

  • A metre with no rhyme filter returns a very large set — always page.

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": {
      "metre": "<metre>"
    },
    "name": "ganjoor_find_similar_poems"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageNoPage number, starting from 1.
metreYesProsodic metre pattern exactly as returned by ganjoor_list_rhythms, e.g. 'فاعلاتن مفاعلن فعلن'.
rhymeNoOptional rhyme letter, e.g. 'ا' or 'ب'. Empty matches any rhyme.
cat_idNoRestrict to a category id. 0 = all categories.
poet_idNoRestrict to a poet id. 0 = all poets.
page_sizeNoMaximum items to return per page (1-100, default 20).
response_formatNoOutput format: 'markdown' for human-readable text (default) or 'json' for machine-readable structured data.markdown
couplet_count_maxNoOnly poems with at most this many couplets. 0 disables the filter.
couplet_count_minNoOnly poems with at least this many couplets. 0 disables the filter.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, openWorld), so the description focuses usefully on runtime behavior: the exact-match requirement on metre, the meaning of an empty rhyme, the 0-disables convention for filters, and the expectation of very large result sets requiring pagination. Return shape is also disclosed for JSON mode, though pagination edge behavior beyond 'has_more/next_page' is not elaborated.

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?

Front-loaded with the highest-value sentence (purpose plus the reply-poetry framing) before the structured Args/Returns/Examples/Notes blocks. The Args list largely duplicates the 100%-covered schema and could be trimmed, but the examples and the paging note earn their space and nothing misleads.

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?

With 9 parameters and no output schema, the description carries the burden well: it supplies the return object shape, default and range behavior for paging, the cross-tool prerequisite for valid metre values, and the practical warning about result volume. An agent can invoke this correctly without further discovery.

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 description coverage is 100%, so the baseline is 3; the description goes beyond it by tying `metre` to its authoritative source (ganjoor_list_rhythms) and spelling out the 'empty means any' and '0 = all/no cap' conventions in one place. Most remaining parameter text restates the schema, which caps the score below 5.

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 opens with a specific verb and resource ('Find poems that share a poem's prosodic metre and rhyme letter') and adds conceptual grounding — Ganjoor's 'related poems' pages and reply-poetry — so the agent understands both the mechanics and the intent. It is clearly distinguishable from siblings like ganjoor_search_poems or ganjoor_analyze_poem_rhyme.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states real preconditions: metre must match notation exactly and must be sourced from ganjoor_list_rhythms, and it warns that an unfiltered metre returns a very large set so callers should always page. It stops short of explicitly contrasting with sibling search tools (e.g. text search vs. metre/rhyme matching), so it is clear context without full alternative routing.

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