wiiiktor/chopper_demo
Preview • Updated • 339
0.14B parameters · about 36 ms per question on an RTX 3090 (20 snippets, ~2,400 tokens) · MIT
Reads the passages your retriever found and, in a single forward pass, (1) scores every passage, like a reranker, and (2) cuts out chops: the exact sentences that answer the question, typically 2–5% of the text, never rewritten.
This repository holds the same weights as the mmbert-small/ folder of wiiiktor/chopper_mmbert
(the main repository: all variants, full results), packaged on its own so leaderboards can list it by size.
# pip install chopper-rag
from chopper_rag import Chopper
ch = Chopper.from_pretrained(repo="wiiiktor/chopper-small-0.14B", variant="small")
question = "Who founded the company that makes the drink?"
out = ch.run(question, passages) # passages: list of strings from your retriever
out.chops # exact quotes
ch.rerank(question, passages) # [(passage_index, score), ...], best first
Code, training recipe and benchmarks: github.com/wiiiktor/chopper_demo.
Base model
jhu-clsp/mmBERT-small