Skip to main content
Glama

RyRank — rerank documents by a query

rerank
Read-onlyIdempotent

Prioritize a list of documents by relevance to a query, returning scored results for RAG retrieval. Drop-in Cohere-compatible response for existing pipelines.

Instructions

Rerank a list of documents/passages by relevance to a query. Cohere-compatible response (results: [{index, relevance_score}]), so it drops into an existing rerank call. One pass, no GPU, no model download, NO ACCOUNT - $0.001 USDC per call over x402 (about half of Cohere Rerank) or a free tier. Documents are supplied per call and discarded - this is NOT a persistent index (for a standing tool/service catalog use snap_router). Best when the candidates already share vocabulary with the query (typical RAG retrieval output); it favours shared wording over deep pairwise scoring. Up to 1000 docs per call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesthe query to rank against
top_nNoreturn only the top N (default: all)
documentsYes2-1000 documents (strings)
return_documentsNoinclude the document text in each result

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
metaNo
resultsYes

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.0.5

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already signal read-only, idempotent, non-destructive behavior. The description goes further by disclosing that documents are discarded per call, there is no GPU or model download, there is a 1000-doc limit, and there is a specific billing model. These are meaningful behavioral facts beyond what annotations can express, and they are consistent with the 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?

Every sentence earns its place: purpose, response compatibility, cost/model constraints, non-persistence, snap_router alternative, optimal use case, and document cap. The core action is front-loaded and the whole description is compact relative to the amount of decision-relevant information it provides.

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 a rich output schema and safety annotations already provided, the description still supplies all necessary selection and invocation context: use case, caveats, limits, alternatives, and behavior. Nothing an agent needs to choose or call this tool correctly appears to be missing.

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%, so the schema already documents every parameter. The description adds useful context about documents being supplied per call and discarded, but it does not need to explain parameter syntax. Baseline 3 is appropriate for a high-coverage schema with only modest extra semantic context.

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: 'Rerank a list of documents/passages by relevance to a query.' It names the Cohere-compatible response format and explicitly distinguishes itself from snap_router by stating this is not a persistent index. The title also reinforces the operation, leaving no ambiguity about what the tool does.

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?

It gives clear when-to-use guidance: 'Best when the candidates already share vocabulary with the query (typical RAG retrieval output).' It also tells the agent when not to use it by naming snap_router as the alternative for a standing tool/service catalog. This is explicit routing guidance between siblings.

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

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/trigeochiral/rgx-mcp'

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