Skip to main content
Glama
Kadihx
by Kadihx

RAG noise filter & re-ranker (feature #12)

jev_rerank

Re-rank retrieved passages by relevance to your query, keeping only the top-K results and discarding irrelevant noise.

Instructions

Re-rank retrieved passages with Jev Noul relevance and keep the top-K, dropping the noise.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topKNoHow many passages to keep (default 3).
queryYesThe question the passages should answer.
documentsYesCandidate passages.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations provided, the description carries the behavioral burden. It discloses the key behavior of keeping top-K and discarding noise, which is useful. Still, it omits details like whether the input is modified, whether the output is ordered by relevance, and what happens when fewer than topK documents are supplied.

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?

The description is a single, front-loaded sentence that explains the purpose and outcome with no filler or repetition. Every word contributes meaning.

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?

For a simple re-ranking tool, the description gives enough context: input passages, a query, and a top-K selection behavior. The lack of an output schema is partially mitigated by 'keep the top-K', which implies the returned ranked subset. Minor gaps around ordering and edge cases prevent a perfect score.

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%, and every parameter is already documented clearly. The description adds only the top-K and 'noise' framing, which does not substantially enrich the schema-provided parameter meaning.

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 uses a specific verb ('Re-rank') with a clear resource ('retrieved passages') and states the concrete outcome ('keep the top-K, dropping the noise'). It is distinct from the sibling tools, which focus on evaluation, planning, and research rather than passage re-ranking.

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?

The description implies when to use the tool: after retrieval, when you want to filter irrelevant passages and retain only the most relevant ones. However, it does not explicitly state exclusions or contrast itself with any alternative re-ranking tool.

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