
Security News
OpenCode User Hit with Hostile Backlash After Reporting Free AI Loophole
An OpenCode user faced harassment after reporting a free AI usage loophole, drawing a bitter backlash in a GitHub thread that has since been deleted.
reranker-ts is a lightweight TypeScript library for re-ranking search results from retreival systems.
Install rerank using npm:
npm install rerank
Available Providers:
ProviderGroqProviderOpenAIExample Usage:
import { LLMReranker, ProviderGroq } from "rerank";
const provider = new ProviderGroq("llama3-8b-8192", API_KEY);
const reranker = new LLMReranker(provider);
// Replace with your own list of objects to rerank.
const list = [
{ key: "bc8fe338", value: "I hate vegetables" },
{ key: "236386f2", value: "I love mangoes" },
];
const query = "I love apples";
const result = await reranker.rerank(list, "key", "value", query);
// ["236386f2", "bc8fe338"]
Combine multiple rank lists by assigning scores based on reciprocal ranks, effectively prioritizing higher-ranked items across all lists. Paper
Example Usage:
import { reciprocalRankFusion } from "rerank";
interface ImageSearchResult {
url: string;
width: string;
height: string;
score: number;
}
// assume you are searching 3 different queries
const rankedLists: ImageSearchResult[][] = await Promise.all([
searchIndex("imageEmbeddingIndex", "person riding skateboard"),
searchIndex("imageEmbeddingIndex", "person skating on the sidewalk"),
searchIndex("imageIndex", "skateboard trick"),
]);
// perform reciprocal rank fusion on all of the results and specify key id, in this case "url"
// this will return a map of all urls now ranked with rrf score
const rankedURLs = reciprocalRankFusion(rankedLists, "url");
// build map of results keyed by url
const resultsMap = new Map<string, ImageSearchResult>();
rankedLists.flat().forEach((result) => {
resultsMap.set(result.url, result);
});
// get single sorted results list from rrf
const sortedResults = Array.from(rankedUrls.keys()).map((url) => {
return resultsMap.get(url);
});
FAQs
rerank library for easy reranking of results
The npm package rerank receives a total of 1,329 weekly downloads. As such, rerank popularity was classified as popular.
We found that rerank demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.

Security News
An OpenCode user faced harassment after reporting a free AI usage loophole, drawing a bitter backlash in a GitHub thread that has since been deleted.

Threat Research
/Security News
319 browser extensions installed by 13.4 million users hijack searches, capture queries, and collect referral payments from Yahoo and Bing.

Threat Research
Malicious Firefox extensions mimic Phantom, Jupiter, and Bitget wallets to steal recovery phrases and private keys, with one fetching its payload remotely.