Skip to content

Jev directory

Jev Reranker — hotchpotch

A Python library that reranks search results and filters retrieved documents with Jev, scoring each candidate's usefulness as evidence and dropping those below a configurable threshold before RAG context is assembled.
Stars
46
Language
Python
License
MIT
Reading time
4 min
Published by
Community
Author
hotchpotch
Last verified
Sep 2026

hotchpotch/jev-reranker

User repository on GitHub

View on GitHub

Jev-powered relevance filtering and reranking for RAG in Python.

Forks
2
Last pushed
Updated Sep 2026

Repo stats from the GitHub API, cached Oct 2026.

About this project

jev-reranker is a Python library for reranking search results and filtering retrieved documents with TypeSafe.AI's Jev. It provides prompts for both tasks and handles concurrent requests, splitting long candidate lists, and retries. For a walkthrough with examples, read Introducing jev-reranker: Reranking and Relevance Filtering for RAG.

Quoted from the project's README. Read the full README.

Highlights

  • relevance_rerank() scores documents by their contribution to an answer, sorts them, and removes those below a threshold such as the default 0.2.
  • rerank() reorders candidates without filtering by default; both modes take a query and a list of documents and score through the Jev API.
  • Supports listwise, pointwise, and pairwise modes, and split budgets can count characters, tokens via an optional tokenizer, or a custom length function.
  • Sync and async methods share concurrency limits, exponential backoff with jitter that respects Retry-After up to 60 seconds, and automatic HTTP cleanup.
  • Each result carries its original document_index, and detail=True records every score including excluded documents, prompts, model, and usage.

Quickstart

python
from jev_reranker import JevReranker

query = "How long do I have to return an online order to ACME Shop?"
documents = [
    "ACME Shop accepts online returns within 30 days of delivery.",
    "ACME Shop in-store purchases can be returned within 14 days of purchase.",
]
reranker = JevReranker(api_key="YOUR_API_KEY")
evidence = reranker.relevance_rerank(query, documents, threshold=0.2)
for item in evidence["results"]:
    print(f"{item['score']:.2f}  {item['text']}")

Watch out

MIT-licensed and needs Python 3.11+ plus a TypeSafe API key; Jev usage is billed, documents are sent to the API for scoring, and the optional tokenizer extra pulls in PyTorch and Sentence Transformers.

Questions about this entry

Short answers drawn from the linked project or page.

Reactions & coverage

Posts, threads, and videos about this entry from around the web.

X: Search and tagging on keep.md

X: Jev reranks station suggestions in TrainLCD

YouTube: Jev in the reranking step of a RAG pipeline: why cosine similarity fails and how a steerable reranker compares. A Colab notebook comes with it.

X: LinkedIn bookmarks search

Other listings of this project

Forks and copies of this project in the directory. This entry is the canonical one.

4GitHub stars
A CLI that reranks, filters, or extractively compresses JSON retrieval results by asking Jev separate Noul questions, then lets Rust apply the order and thresholds, reading stdin and writing stdout.
Jev Tools & CLIs#community#rust#cli
Node.js CLI that pipes a JSON array of retrieved documents through Jev to rerank, filter, or compress them before they reach an LLM. Supports text and context field selection, a top-N cap, and pass-through of IDs, sources, and retrieval scores.
Jev Tools & CLIs#cli#javascript#routing
Community

From the Jev guides

Original write-ups on what this entry is for.

From the Jev AI model community

Posts from builders shipping with Jev right now.

Follow @typesafeai