Skip to main content
Glama

Semantic Search

search_semantic
Read-onlyIdempotent

Search Pāli tipiṭaka by semantic similarity. Adjust threshold for strict or broad matches, independent of keyword search.

Instructions

Semantic search — match by meaning, not exact words.

Uses vector similarity (cosine distance) over text_pali embedded with a multilingual MiniLM model.

🤔 In most cases you should use search_hybrid instead — it combines this semantic search with keyword search and ranks better. Use this tool only when you need:

  • Pure semantic results (no keyword influence)

  • Fine-grained threshold tuning (hybrid uses RRF which is harder to tune)

  • To debug what semantic alone picks up vs keyword

⚠️ Known limitations:

  • The index is Pāli only (English/Thai queries pass through the multilingual embedding but the model isn't tuned on Pāli)

  • English queries usually embed better than Thai (model is EN-primary)

  • For specific Pāli terms (appamāda, dukkha), exact match is better — use search_by_keyword instead

  • Pāli stock phrases recur in many suttas → similarity scores cluster; read the top 10, don't trust rank 1 alone

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesQuery text (English works best, then Pāli, Thai is weakest).
languageNoOutput language — "pali", "thai", "english", or "all" (Thai disabled → null).pali
limitNoMaximum results (default: 5, max: 20).
thresholdNoMaximum cosine distance (smaller = stricter match). Default 0.7; lower to 0.5 for tighter matches, raise to 0.9 for broader.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Discloses limitations: Pāli-only index, language effectiveness, clustering of stock phrases, caution about not trusting rank 1. All consistent with readOnlyHint and idempotentHint annotations.

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?

Well-structured with emojis and sections, front-loaded with purpose. Slightly long but each sentence carries useful info; no fluff.

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?

Covers all aspects: purpose, usage guidelines, behavioral nuances, limitations, parameter tuning advice. Output schema exists, so return values are not needed. Fully complete for the tool's complexity.

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 coverage is 100%, but description adds significant value: explains query language effectiveness (English > Pāli > Thai), threshold tuning advice, and language parameter hint about Thai being disabled. Elevates beyond baseline 3.

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?

Clearly states 'Semantic search — match by meaning, not exact words.' Distinguishes from siblings by referencing search_hybrid and search_by_keyword explicitly.

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?

Explicitly recommends search_hybrid for most cases, specifies when to use this tool (pure semantic, threshold tuning, debugging), and advises against using for specific Pāli terms (better with keyword search).

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/dhamma-seeker/tripitaka-mcp'

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