Skip to main content
Glama

Search poems by meaning

gj_semantic_search
Read-onlyIdempotent

Find classical Persian poems by meaning or theme using embedding search; returns match scores, summaries, and opening couplets, and falls back to full-text search when the semantic index is unavailable.

Instructions

Find poems by meaning or theme (embedding search), with score, summary and first couplets.

Falls back to full-text search when the semantic index is down.

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": {
      "query": "<query>"
    },
    "name": "gj_semantic_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesWhat the poem is about, in Persian or English.
top_kNoHow many poems to return.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already cover read-only, idempotent, non-destructive, open-world. The description adds two pieces of real behavioral context: the response includes score, summary and first couplets, and the tool silently degrades to full-text search when the index is unavailable — a meaningful caveat about result quality the annotations cannot convey.

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?

Two short sentences, zero filler; the primary capability and return contents come first, and the fallback caveat follows. Nothing is repeated from the schema or annotations.

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?

There is no output schema, and the description partly compensates by naming the returned fields (score, summary, first couplets) and the degraded fallback mode. For a simple two-parameter search tool this is close to sufficient, though ranking behavior and what the score means are left unspecified.

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%, with both parameters (query, top_k with default 5, max 20) fully documented, including that the query may be Persian or English. The description adds no extra parameter meaning, so baseline 3 applies.

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?

States a concrete verb and resource ('Find poems by meaning or theme') and identifies the mechanism ('embedding search'), which differentiates it from a keyword/text search sibling. The only gap is that it never names the sibling it complements, so the agent must infer that gj_search handles exact-text lookup.

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?

Usage is implied by 'by meaning or theme' rather than stated as a rule (e.g. 'use this for conceptual queries; use gj_search for exact words/phrases'). The fallback sentence describes internal behavior when the index is down, not when the agent should prefer this tool over alternatives.

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